/* ── CSS Variables ─────────────────────────────── */
:root {
  --bg: #f5f0e8;
  --bg-alt: #ede7d9;
  --ink: #1a1208;
  --ink-light: #5a4e3c;
  --accent: #c9581a;
  --accent2: #4a7c5e;
  --white: #fdfaf4;
  --border: #d4c9b4;
  --shadow: 0 4px 24px rgba(26, 18, 8, 0.1);
  --radius: 10px;
  --ff-head: "Playfair Display", Georgia, serif;
  --ff-body: "DM Sans", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  scroll-behavior: smooth;
}
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--ff-body);
  font-size: 16px;
  line-height: 1.7;
}
a {
  color: var(--accent);
  text-decoration: none;
  transition: opacity 0.2s;
}
a:hover {
  opacity: 0.75;
}
img {
  max-width: 100%;
  display: block;
}
.container {
  max-width: 1060px;
  margin: 0 auto;
  padding: 0 28px;
}
.section-label {
  font-family: var(--ff-body);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
}
.section-title {
  font-family: var(--ff-head);
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 700;
  line-height: 1.2;
  color: var(--ink);
  margin-bottom: 18px;
}
.divider {
  width: 52px;
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
  margin-bottom: 32px;
}
.badge {
  display: inline-block;
  background: var(--accent);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  padding: 3px 10px;
  border-radius: 20px;
}
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 12px rgba(26, 18, 8, 0.07);
}
nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  padding: 0 28px;
  max-width: 1060px;
  margin: 0 auto;
}
.nav-logo {
  font-family: var(--ff-head);
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.nav-logo span {
  color: var(--accent);
}
nav ul {
  display: flex;
  list-style: none;
  gap: 32px;
}
nav ul li a {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--ink-light);
  letter-spacing: 0.02em;
  padding-bottom: 3px;
  border-bottom: 2px solid transparent;
  transition:
    color 0.2s,
    border-color 0.2s;
}
nav ul li a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
  opacity: 1;
}
.btn-cv {
  background: var(--accent);
  color: var(--white);
  font-family: var(--ff-body);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 8px 18px;
  border-radius: 20px;
  border: none;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition:
    background 0.2s,
    transform 0.15s;
}
.btn-cv:hover {
  background: #a84215;
  transform: translateY(-1px);
  opacity: 1;
}
.btn-cv svg {
  width: 14px;
  height: 14px;
}
#home {
  padding: 90px 0 70px;
  position: relative;
  overflow: hidden;
}
#home::before {
  content: "";
  position: absolute;
  top: -60px;
  right: -80px;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(201, 88, 26, 0.13) 0%,
    transparent 70%
  );
  pointer-events: none;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 48px;
  align-items: center;
}
.hero-text .greeting {
  font-family: var(--ff-body);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}
.hero-text h1 {
  font-family: var(--ff-head);
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 900;
  line-height: 1.1;
  color: var(--ink);
  margin-bottom: 16px;
}
.hero-text h1 em {
  font-style: normal;
  color: var(--accent);
}
.hero-text .tagline {
  font-size: 1.05rem;
  color: var(--ink-light);
  margin-bottom: 28px;
  max-width: 480px;
}
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-weight: 500;
  font-size: 0.9rem;
  transition:
    transform 0.15s,
    box-shadow 0.15s;
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  opacity: 1;
}
.btn-primary {
  background: var(--accent);
  color: var(--white);
}
.btn-outline {
  background: transparent;
  border: 2px solid var(--accent);
  color: var(--accent);
  margin-left: 12px;
}
.hero-photo {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  overflow: hidden;
  border: 5px solid var(--bg-alt);
  box-shadow: var(--shadow);
  flex-shrink: 0;
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
#about {
  background: var(--white);
  padding: 80px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.about-top {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 56px;
  align-items: start;
  margin-bottom: 52px;
}
.about-text p {
  color: var(--ink-light);
  margin-bottom: 14px;
}
.about-text h3 {
  font-family: var(--ff-head);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ink);
  margin: 20px 0 10px;
}
.about-text h3:first-child {
  margin-top: 0;
}
.about-meta h3 {
  font-family: var(--ff-head);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ink);
  margin: 24px 0 10px;
}
.about-meta h3:first-child {
  margin-top: 0;
}
.about-meta ul {
  list-style: none;
  padding: 0;
}
.about-meta ul li {
  color: var(--ink-light);
  font-size: 0.92rem;
  padding: 5px 0;
  border-bottom: 1px dashed var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
}
.about-meta ul li::before {
  content: "→";
  color: var(--accent);
  font-size: 0.8rem;
}
.hobby-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-template-rows: auto auto;
  gap: 10px;
  margin-top: 2px;
}
.hobby-tile {
  border-radius: 12px;
  padding: 14px 12px 12px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  border: 1.5px solid transparent;
  cursor: default;
  transition:
    transform 0.18s,
    box-shadow 0.18s,
    border-color 0.18s;
}
.hobby-tile:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 22px rgba(26, 18, 8, 0.11);
  border-color: rgba(26, 18, 8, 0.1);
}
.hobby-tile .h-icon {
  font-size: 1.5rem;
  line-height: 1;
}
.hobby-tile .h-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.25;
}
.hobby-tile.span2 {
  grid-column: span 2;
}
.hobby-tile.span3 {
  grid-column: span 3;
}
.hobby-tile.c1 {
  background: #fff0e6;
}
.hobby-tile.c2 {
  background: #e8f4ec;
}
.hobby-tile.c3 {
  background: #eef3ff;
}
.hobby-tile.c4 {
  background: #fdf5e6;
}
.hobby-tile.c5 {
  background: #f2eeff;
}
.hobby-tile.c6 {
  background: #e6f7f7;
}
.edu-heading {
  font-family: var(--ff-head);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.edu-heading::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}
.edu-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  position: relative;
}
.edu-cards::before {
  display: none;
}
.edu-card {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 24px 22px 20px;
  position: relative;
  transition:
    transform 0.2s,
    box-shadow 0.2s,
    border-color 0.2s;
}
.edu-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 32px rgba(26, 18, 8, 0.12);
  border-color: var(--accent);
}
.edu-card--featured {
  border-top: 3px solid var(--accent);
}
.edu-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.edu-year-inline {
  font-size: 0.78rem;
  color: var(--ink-light);
}
.edu-level {
  font-size: 0.78rem;
  color: var(--ink-light);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.edu-card-tag {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 20px;
  display: inline-block;
}
.tag-ongoing {
  background: #fff0e6;
  color: var(--accent);
}
.tag-done {
  background: #e8f4ec;
  color: #2d7a4a;
}
.edu-card h4 {
  font-family: var(--ff-head);
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 6px;
  line-height: 1.3;
}
.edu-card .edu-school {
  font-size: 0.82rem;
  color: var(--ink-light);
  margin-bottom: 14px;
}
.edu-card-footer-tags {
  border-top: 1px solid var(--border);
  padding-top: 12px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.edu-strand-tag {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 20px;
  background: var(--bg-alt);
  color: var(--ink-light);
  display: inline-block;
}
#skills {
  padding: 80px 0;
}
.skills-layout {
  display: grid;
  grid-template-columns: 1fr 1fr; /* Back to side-by-side */
  gap: 40px;
  margin-top: 10px;
}
.skill-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
}
.skill-card h3 {
  font-family: var(--ff-head);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--accent);
  display: inline-block;
}
.skill-item {
  margin-bottom: 14px;
}
.skill-item label {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 5px;
}
.skill-bar {
  background: var(--bg-alt);
  border-radius: 20px;
  height: 8px;
  overflow: hidden;
}
.skill-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), #e8843a);
  border-radius: 20px;
  transition: width 1s ease;
}
.skills-table-wrap {
  overflow-x: auto;
  margin-top: 8px;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
thead tr {
  background: var(--accent);
  color: var(--white);
}
thead th {
  padding: 10px 14px;
  text-align: left;
  font-weight: 500;
  letter-spacing: 0.03em;
}
tbody tr {
  border-bottom: 1px solid var(--border);
}
tbody tr:last-child {
  border-bottom: none;
}
tbody tr:nth-child(even) {
  background: var(--bg);
}
tbody td {
  padding: 9px 14px;
  color: var(--ink-light);
}
tbody td:first-child {
  color: var(--ink);
  font-weight: 500;
}

/* ── PROJECTS — Portrait Gallery ── */
#projects {
  background: var(--white);
  padding: 80px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
  align-items: stretch;
}
.gallery-card.portrait-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  transition:
    transform 0.2s,
    box-shadow 0.2s;
  text-decoration: none;
  color: inherit;
}
.gallery-card.portrait-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 36px rgba(26, 18, 8, 0.14);
}

.gallery-card-image {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  flex-shrink: 0;
  background: var(--border);
  overflow: hidden;
}
.gallery-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  display: block;
  transition: transform 0.5s ease;
}

.gallery-card.portrait-card:hover .gallery-card-image img {
  transform: scale(1.05);
}

.project-year-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(4px);
  z-index: 2;
}

.project-media-badge {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(26, 18, 8, 0.65);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  padding: 4px 10px;
  border-radius: 20px;
  backdrop-filter: blur(4px);
  z-index: 2;
}

.gallery-card-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex: 1; /* Allows content to push footer down */
}
.project-heading {
  margin-bottom: 12px;
}
.project-heading h4 {
  font-family: var(--ff-head);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 8px;
}
.project-role-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.project-role-pill {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.project-description {
  font-size: 0.9rem;
  color: var(--ink-light);
  line-height: 1.6;
  margin-bottom: 16px;
  flex: 1;
}

.project-languages {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.project-language-pill {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--ink-light);
  background: var(--white);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 6px;
  letter-spacing: 0.03em;
}

.gallery-card-footer {
  border-top: 1px solid var(--border);
  padding-top: 16px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.card-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition:
    background 0.2s,
    color 0.2s,
    border-color 0.2s;
  text-decoration: none;
}
.card-link-btn:hover {
  background: var(--bg);
  border-color: var(--ink);
  color: var(--ink);
}
.card-link-btn svg {
  width: 14px;
  height: 14px;
}

#contact {
  padding: 80px 0;
}
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 60px;
  align-items: start;
}
.contact-info p {
  color: var(--ink-light);
  margin-bottom: 20px;
  font-size: 0.95rem;
}
.contact-info address {
  font-style: normal;
  font-size: 0.88rem;
  color: var(--ink-light);
  line-height: 2;
}
.contact-info address strong {
  color: var(--ink);
}
form {
  display: grid;
  gap: 16px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-group label {
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--ink);
}
.form-group input,
.form-group textarea {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 11px 14px;
  font-family: var(--ff-body);
  font-size: 0.9rem;
  color: var(--ink);
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
  outline: none;
}
.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(201, 88, 26, 0.12);
}
textarea {
  resize: vertical;
  min-height: 120px;
}
.btn-submit {
  background: var(--accent);
  color: var(--white);
  border: none;
  border-radius: var(--radius);
  padding: 13px 28px;
  font-family: var(--ff-body);
  font-size: 0.92rem;
  font-weight: 500;
  cursor: pointer;
  transition:
    background 0.2s,
    transform 0.15s;
  justify-self: start;
}
.btn-submit:hover {
  background: #a84215;
  transform: translateY(-2px);
}
footer {
  background: var(--ink);
  color: var(--bg);
  text-align: center;
  padding: 32px 28px;
  font-size: 0.85rem;
}
footer span {
  color: var(--accent);
}
.social-links {
  display: flex;
  gap: 14px;
  margin-top: 20px;
}
.social-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  background: var(--white);
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 500;
  transition:
    background 0.2s,
    border-color 0.2s,
    color 0.2s,
    transform 0.15s;
  text-decoration: none;
}
.social-link:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
  transform: translateY(-2px);
  opacity: 1;
}
.social-link:hover svg path,
.social-link:hover svg rect,
.social-link:hover svg circle,
.social-link:hover svg polygon {
  fill: var(--white);
}
.social-link svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.footer-socials {
  margin-top: 12px;
  display: flex;
  gap: 16px;
  justify-content: center;
}
.footer-social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(240, 235, 224, 0.25);
  color: var(--bg);
  transition:
    background 0.2s,
    transform 0.15s;
  text-decoration: none;
}
.footer-social-icon:hover {
  background: var(--accent);
  border-color: var(--accent);
  transform: translateY(-2px);
  opacity: 1;
}
.footer-social-icon svg {
  width: 16px;
  height: 16px;
}

/* ── Media Queries ── */
@media (max-width: 760px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }
  .hero-photo {
    margin: 0 auto;
  }
  .about-top,
  .skills-layout,
  .contact-wrap {
    grid-template-columns: 1fr;
  }
  .edu-cards {
    grid-template-columns: 1fr;
  }
  nav ul {
    display: none;
  }

  .gallery {
    grid-template-columns: 1fr;
  }
}
