header {
  background: #333;
  color: #fff;
  padding: 1rem 0;
  text-align: center;
}

body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  background: #333;
  color: #d4d4d4;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

footer {
  text-align: center;
  color: #444;
  background: #f4f4f4;
  width: 100%;
  position: static;
  margin-top: auto;
  padding: 0.5rem 0;
}

/* profile photo */
.avatar {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  margin: 2rem 0;
  border: 4px solid #333;
  box-shadow: 0 0 0 1px #f5f5f5; /* outer darker ring */
}

.profile-name {
  font-family: "Space Mono", monospace;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0rem 0 0.5rem;
  color: #fff;
}

.info {
  margin: 0.25rem 0 0;
}

.container {
  color: #d4d4d4;
  display: flex;
  align-items: flex-start;
  gap: 3rem;
  justify-content: space-between;
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 2rem;
  flex: 1;
}

.sidebar {
  position: sticky;
  top: 20px;
  align-self: flex-start;
  width: 280px;
  flex-shrink: 0;
}

.sidebar a {
  color: #d4d4d4;
  text-decoration: none;
}

.sidebar a:visited {
  color: #d4d4d4;
}

.sidebar a:hover {
  text-decoration: underline;
}

.social-links {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
}

.social-links li {
  margin-bottom: 0.75rem;
}

.social-links i {
  margin-right: 0.5rem;
  font-size: 1.1rem;
}

.content {
  flex: 1;
  padding: 1rem 0;
  min-width: 0;
}

.projects h2 {
  margin-top: 0;
  color: #fff;
  font-family: "Space Mono", monospace;
}

.projects {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.section-block {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.projects p {
  margin-bottom: 0;
}

.project-card {
  display: inline-block;
  padding: 1rem 1.5rem;
  border: 1px solid #444;
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.project-card:hover {
  border-color: #fff;
  transform: translateY(-2px);
}

.project-img {
  max-width: 320px;
  width: 100%;
  border-radius: 6px;
  display: block;
  margin-bottom: 0.75rem;
}

.project-img {
  width: 180px;
  height: 120px;
  object-fit: cover;
  border-radius: 8px;
}
.project-card {
  display: flex;
  gap: 1.5rem;
  padding: 1.5rem;
  margin-bottom: 2rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  transition: 0.2s ease;
}
.project-card:hover {
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-4px);
}

.Writings {
  margin: 0;
}

/* media query: mobile view */
@media (max-width: 800px) {
  .container {
    flex-direction: column;
    padding: 1;
    gap: 1.5rem;
    justify-content: flex-start;
  }
  .project_title {
    padding: 0 rem;
    padding: 0;
    margin-left: 0;
    font-family: "Space Mono", monospace;
    margin-top: 1.5rem;
  }
  .content {
    width: 100%;
    display: block;
    padding: 0;
    margin-top: 1.5rem;
  }
  .sidebar {
    width: 100%;
    position: static;
    margin-bottom: 2rem;
  }
  .project-card {
    display: flex;
    flex-direction: column;
    padding: 1rem 1rem;
    width: 90%;
    margin: 0 auto;
    box-sizing: border-box;
    margin-top: 1rem;
    margin-bottom: 1rem;
  }
  .projects {
    gap: 2.5rem;
  }
  .section-block {
    gap: 1.25rem;
  }
  .project-img {
    width: 90%;
    margin: 0 auto;
    align-items: center;
  }
  .sidebar {
    display: contents;
  }
  .sidebar > *:not(.social-links) {
    order: 1;
  }
  .content {
    order: 2;
  }
  .social-links {
    order: 3;
    width: 90%;
    padding: 0;
    margin-bottom: 4rem;
  }
}
