/* ── Fonts ──────────────────────────────────────────────────────────────── */
@font-face {
  font-family: 'Almarai';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('fonts/Almarai-300.ttf') format('truetype');
}
@font-face {
  font-family: 'Almarai';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/Almarai-400.ttf') format('truetype');
}
@font-face {
  font-family: 'Almarai';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('fonts/Almarai-700.ttf') format('truetype');
}
@font-face {
  font-family: 'Almarai';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url('fonts/Almarai-800.ttf') format('truetype');
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/InstrumentSerif-Regular.ttf') format('truetype');
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/InstrumentSerif-Italic.ttf') format('truetype');
}

/* ── Reset ──────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: #000;
  color: #E1E0CC;
  font-family: 'Almarai', -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
video { display: block; }

/* ── Variables ──────────────────────────────────────────────────────────── */
:root {
  --cream: #E1E0CC;
  --cream-dim: rgba(225,224,204,0.65);
}

/* ── Word pull-up animation ─────────────────────────────────────────────── */
.pull-up {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0 0.25em;
}
.pull-up-word-wrap {
  overflow: hidden;
  display: inline-flex;
}
.pull-up-word {
  display: inline-block;
  transform: translateY(110%);
  transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.pull-up-word.visible { transform: translateY(0); }

/* Gap variant for multi-style (centered) */
.pull-up-multi {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0 0.22em;
}

/* ── Nav ────────────────────────────────────────────────────────────────── */
.nav-bar {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 10;
  display: flex;
  justify-content: center;
}
.nav-pill {
  background: #000;
  border-radius: 0 0 1rem 1rem;
  padding: 12px 20px;
  max-width: 100vw;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.nav-pill::-webkit-scrollbar { display: none; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  list-style: none;
  white-space: nowrap;
}
.nav-links a {
  font-size: 0.875rem;
  color: var(--cream-dim);
  transition: color 0.2s;
  padding: 6px 0;
  display: inline-block;
}
.nav-links a:hover { color: var(--cream); }

@media (min-width: 768px) {
  .nav-pill { padding: 10px 40px; border-radius: 0 0 1.5rem 1.5rem; overflow-x: visible; }
  .nav-links { gap: 48px; }
  .nav-links a { font-size: 0.875rem; padding: 0; }
}

/* ── Hero ───────────────────────────────────────────────────────────────── */
.hero {
  height: 100vh;
  padding: 16px;
}
@media (min-width: 768px) { .hero { padding: 20px; } }

.hero-inner {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 1rem;
  overflow: hidden;
  background: #000;
}
@media (min-width: 768px) { .hero-inner { border-radius: 2rem; } }

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.hero-noise {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 180px;
  opacity: 0.6;
  mix-blend-mode: overlay;
}
.hero-gradient {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(0,0,0,0.25) 0%, transparent 40%, rgba(0,0,0,0.65) 100%);
}
.hero-content {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 16px 16px 24px;
  gap: 10px;
}
@media (min-width: 640px) {
  .hero-content {
    padding: 20px 20px 32px;
    gap: 12px;
  }
}
@media (min-width: 768px) {
  .hero-content {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    align-items: end;
    padding: 32px 32px 40px;
    gap: 16px;
  }
}

.hero-title-col { width: 100%; }
.hero-desc-col {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}
@media (min-width: 768px) {
  .hero-title-col { grid-column: span 8; width: auto; }
  .hero-desc-col {
    grid-column: span 4;
    gap: 20px;
    padding-bottom: 8px;
    width: auto;
  }
}

.hero-title {
  font-size: clamp(48px, 16vw, 240px);
  font-weight: 500;
  line-height: 0.85;
  letter-spacing: -0.06em;
  color: var(--cream);
  opacity: 0;
  transition: opacity 0.4s ease;
}
.hero-title.loaded { opacity: 1; }

.hero-desc {
  font-size: 0.875rem;
  line-height: 1.4;
  color: var(--cream-dim);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.5s, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.5s;
}
.hero-desc.loaded { opacity: 1; transform: translateY(0); }
@media (min-width: 768px) { .hero-desc { font-size: 1rem; } }

.hero-cta {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.7s, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.7s;
}
.hero-cta.loaded { opacity: 1; transform: translateY(0); }

/* ── Pill Button ────────────────────────────────────────────────────────── */
.pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 9999px;
  padding: 4px 4px 4px 20px;
  background: var(--cream);
  color: #000;
  font-weight: 500;
  font-size: 0.9rem;
  transition: gap 0.2s ease;
}
.pill-btn:hover { gap: 12px; }

/* Small pill variant (social links, download button) */
.pill-btn--sm {
  font-size: 0.8rem;
  padding: 4px 4px 4px 16px;
}
.pill-btn-icon--sm {
  width: 30px;
  height: 30px;
}

.pill-btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 9999px;
  background: #000;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}
.pill-btn:hover .pill-btn-icon { transform: scale(1.1); }
.pill-btn-icon svg { color: var(--cream); }

/* ── About ──────────────────────────────────────────────────────────────── */
.about-section {
  background: #000;
  padding: 80px 16px;
}
@media (min-width: 768px) { .about-section { padding: 80px 24px; } }

.about-card {
  background: #101010;
  border-radius: 1rem;
  max-width: 72rem;
  margin: 0 auto;
  padding: 64px 32px;
  text-align: center;
}
@media (min-width: 768px) {
  .about-card { border-radius: 2rem; padding: 96px 64px; }
}

.about-label {
  font-size: 0.625rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--cream);
  margin-bottom: 32px;
}
@media (min-width: 768px) { .about-label { font-size: 0.75rem; } }

.about-heading {
  font-size: clamp(1.5rem, 3.8vw, 3.5rem);
  font-weight: 400;
  line-height: 1.05;
  color: var(--cream);
  max-width: 52rem;
  margin: 0 auto 56px;
}

.font-serif-italic {
  font-family: 'Instrument Serif', serif;
  font-style: italic;
}

/* ── Animated paragraph (scroll reveal) ────────────────────────────────── */
.scroll-reveal-para {
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--cream);
  max-width: 42rem;
  margin: 0 auto;
}
@media (min-width: 768px) { .scroll-reveal-para { font-size: 1rem; } }

.anim-char { display: inline; white-space: normal; opacity: 0.15; }

/* ── Section Divider ─────────────────────────────────────────────────────── */
.section-divider {
  position: relative;
  width: 100%;
  height: 1px;
  overflow: visible;
  z-index: 1;
}
.section-divider::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
  width: 60%;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(225,224,204,0.08) 15%,
    rgba(225,224,204,0.28) 50%,
    rgba(225,224,204,0.08) 85%,
    transparent 100%);
}
.section-divider::after {
  content: '';
  position: absolute;
  left: 50%;
  top: -3px;
  transform: translateX(-50%);
  width: 30%;
  height: 7px;
  background: radial-gradient(ellipse at center,
    rgba(225,224,204,0.18) 0%,
    transparent 70%);
  filter: blur(2px);
}

/* ── Profile & Resume ───────────────────────────────────────────────────── */
.profile-section {
  background: #000;
  padding: 80px 16px;
}
@media (min-width: 768px) { .profile-section { padding: 130px 24px; } }

.profile-inner {
  max-width: 72rem;
  margin: 0 auto;
}

.profile-label {
  font-size: 0.625rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--cream-dim);
  margin-bottom: 48px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.profile-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(225,224,204,0.2) 0%, transparent 100%);
  max-width: 240px;
}

.profile-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}
@media (min-width: 768px) {
  .profile-grid { grid-template-columns: 1fr 1.7fr; align-items: stretch; gap: 20px; }
}

/* ─ Photo card ─ */
.profile-photo-card {
  background: #0d0d0d;
  border-radius: 1.5rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s cubic-bezier(0.16,1,0.3,1), transform 0.7s cubic-bezier(0.16,1,0.3,1);
}
.profile-photo-card.visible { opacity: 1; transform: translateY(0); }

.profile-photo-wrap {
  position: relative;
  overflow: hidden;
  flex: 1;
  min-height: 260px;
}
@media (min-width: 640px) { .profile-photo-wrap { min-height: 320px; } }
@media (min-width: 768px) { .profile-photo-wrap { min-height: 400px; } }

.profile-photo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  transition: transform 0.6s cubic-bezier(0.16,1,0.3,1);
}
.profile-photo-card:hover .profile-photo-wrap img { transform: scale(1.03); }

/* Subtle gradient at bottom of photo */
.profile-photo-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(13,13,13,0.85) 0%, transparent 45%);
  pointer-events: none;
}

.profile-photo-info {
  padding: 20px 24px 24px;
}
.profile-name {
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--cream);
  line-height: 1.2;
}
.profile-meta {
  font-size: 0.75rem;
  color: var(--cream-dim);
  margin-top: 4px;
}
.profile-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}
.profile-badge {
  font-size: 0.65rem;
  padding: 3px 9px;
  border-radius: 9999px;
  border: 1px solid rgba(225,224,204,0.2);
  color: var(--cream-dim);
  letter-spacing: 0.05em;
}

/* ─ Resume card ─ */
.profile-resume-card {
  background: #0d0d0d;
  border-radius: 1.5rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s cubic-bezier(0.16,1,0.3,1) 0.12s, transform 0.7s cubic-bezier(0.16,1,0.3,1) 0.12s;
  box-shadow:
    0 0 0 1px rgba(225,224,204,0.07),
    0 0 40px rgba(225,224,204,0.04),
    0 24px 64px rgba(0,0,0,0.5);
}
.profile-resume-card.visible { opacity: 1; transform: translateY(0); }
.profile-resume-card:hover {
  box-shadow:
    0 0 0 1px rgba(225,224,204,0.13),
    0 0 60px rgba(225,224,204,0.07),
    0 24px 80px rgba(0,0,0,0.6);
  transition: box-shadow 0.5s ease, opacity 0.7s cubic-bezier(0.16,1,0.3,1) 0.12s, transform 0.7s cubic-bezier(0.16,1,0.3,1) 0.12s;
}

.resume-preview-wrap {
  flex: 1;
  position: relative;
  min-height: 260px;
  background: #0e0e0e;
}
@media (min-width: 640px) { .resume-preview-wrap { min-height: 380px; } }
@media (min-width: 768px) { .resume-preview-wrap { min-height: 640px; } }

/* Subtle scanline overlay for futuristic feel */
.resume-preview-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 3px,
    rgba(0,0,0,0.08) 3px,
    rgba(0,0,0,0.08) 4px
  );
  pointer-events: none;
  z-index: 2;
}

.resume-preview-wrap embed,
.resume-preview-wrap iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
  z-index: 1;
}

/* On small screens PDF embeds don't render — hide and show fallback instead */
@media (max-width: 639px) {
  .resume-preview-wrap embed,
  .resume-preview-wrap iframe {
    display: none;
  }
  .resume-fallback {
    display: flex !important;
  }
}

/* Fallback message when embed not supported */
.resume-fallback {
  display: none;
  position: absolute;
  inset: 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 16px;
  color: var(--cream-dim);
  font-size: 0.875rem;
  text-align: center;
  padding: 32px 24px;
  background: #0e0e0e;
}
.resume-fallback svg {
  opacity: 0.5;
}
.resume-fallback span {
  max-width: 200px;
  line-height: 1.5;
  color: rgba(225,224,204,0.45);
}

.resume-footer {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  border-top: 1px solid rgba(225,224,204,0.06);
}
@media (min-width: 640px) { .resume-footer { padding: 20px 24px; flex-wrap: nowrap; } }

.resume-footer-label {
  font-size: 0.75rem;
  color: var(--cream-dim);
  min-width: 0;
}
.resume-footer-label strong {
  display: block;
  color: var(--cream);
  font-size: 0.875rem;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Skills ─────────────────────────────────────────────────────────────── */
.skills-section {
  background: #000;
  padding: 120px 16px;
}
@media (min-width: 768px) { .skills-section { padding: 130px 24px; } }

.skills-inner {
  max-width: 72rem;
  margin: 0 auto;
}

.skills-label {
  font-size: 0.625rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--cream-dim);
  margin-bottom: 48px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.skills-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(225,224,204,0.2) 0%, transparent 100%);
  max-width: 240px;
}

.skills-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 640px) { .skills-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .skills-grid { grid-template-columns: repeat(3, 1fr); } }

.skill-group {
  background: #0d0d0d;
  border-radius: 1rem;
  padding: 24px 28px;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.55s cubic-bezier(0.16, 1, 0.3, 1), transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
}
.skill-group.visible { opacity: 1; transform: translateY(0); }
.skill-group:hover { background: #131313; }

.skill-group-title {
  font-size: 0.625rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--cream-dim);
  margin-bottom: 16px;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.skill-tag {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 9999px;
  border: 1px solid rgba(225,224,204,0.15);
  font-size: 0.75rem;
  color: var(--cream);
  background: transparent;
  transition: border-color 0.2s, background 0.2s;
}
.skill-group:hover .skill-tag { border-color: rgba(225,224,204,0.3); }

/* ── Projects ───────────────────────────────────────────────────────────── */
.projects-section {
  background: #000;
  min-height: 100vh;
  padding: 120px 16px;
  position: relative;
}
@media (min-width: 768px) { .projects-section { padding: 130px 24px; } }

.projects-noise {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 128px;
  opacity: 0.12;
}

.projects-inner {
  max-width: 72rem;
  margin: 0 auto;
  position: relative;
  z-index: 10;
}

.projects-header { margin-bottom: 56px; }
.projects-title {
  font-size: clamp(1.25rem, 3vw, 2.25rem);
  font-weight: 400;
  line-height: 1.3;
  color: var(--cream);
}
.projects-subtitle {
  font-size: clamp(1.25rem, 3vw, 2.25rem);
  font-weight: 400;
  color: #6b7280;
  margin-top: 4px;
}

.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 768px) {
  .projects-grid { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 1024px) {
  .projects-grid {
    grid-template-columns: repeat(4, 1fr);
    height: 500px;
  }
}

/* Feature card */
.feature-card {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
.feature-card.visible { opacity: 1; transform: scale(1); }
@media (min-width: 1024px) { .feature-card { height: 100%; } }

/* Video feature card */
.video-card-inner {
  position: relative;
  width: 100%;
  height: 256px;
  border-radius: 1rem;
  overflow: hidden;
  background: #111;
}
@media (min-width: 1024px) { .video-card-inner { height: 100%; } }

.video-card-inner video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.video-card-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
}
.video-card-label {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 20px;
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.2;
  color: var(--cream);
}

/* GitHub stat card — CSS-only replacement for the duplicate video */
.github-stat-card {
  background: radial-gradient(ellipse at 40% 60%, #0d1117 0%, #010409 100%);
}
.github-stat-glow {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 40% at 30% 40%, rgba(63,185,80,0.12) 0%, transparent 70%),
    radial-gradient(ellipse 40% 60% at 70% 70%, rgba(88,166,255,0.08) 0%, transparent 70%);
  animation: githubPulse 5s ease-in-out infinite alternate;
}
@keyframes githubPulse {
  from { opacity: 0.6; }
  to   { opacity: 1; }
}

/* Project card */
.proj-card-inner {
  height: 256px;
  border-radius: 1rem;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: #212121;
}
@media (min-width: 1024px) { .proj-card-inner { height: 100%; } }

.proj-num {
  font-size: 0.625rem;
  color: #6b7280;
  letter-spacing: 0.2em;
  margin-bottom: 20px;
}
.proj-title {
  font-size: 1.125rem;
  font-weight: 500;
  line-height: 1.2;
  color: var(--cream);
  margin-bottom: 20px;
}
.proj-items {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}
.proj-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.proj-check {
  flex-shrink: 0;
  margin-top: 2px;
  width: 14px;
  height: 14px;
  color: var(--cream);
}
.proj-item-text {
  font-size: 0.75rem;
  color: #9ca3af;
  line-height: 1.4;
}
.proj-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  color: var(--cream);
  margin-top: 16px;
  opacity: 1;
  transition: opacity 0.2s;
}
.proj-link:hover { opacity: 0.7; }
.proj-link svg { transform: rotate(-45deg); }

/* ── Experience ─────────────────────────────────────────────────────────── */
.experience-section {
  background: #000;
  padding: 120px 16px;
}
@media (min-width: 768px) { .experience-section { padding: 130px 24px; } }

.experience-inner { max-width: 72rem; margin: 0 auto; }

.exp-label {
  font-size: 0.625rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--cream-dim);
  margin-bottom: 48px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.exp-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(225,224,204,0.2) 0%, transparent 100%);
  max-width: 240px;
}

.exp-list {
  display: flex;
  flex-direction: column;
  border-top: 1px solid rgba(225,224,204,0.1);
}
.exp-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px 16px;
  padding: 24px 0;
  border-bottom: 1px solid rgba(225,224,204,0.1);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: default;
}
.exp-row.visible { opacity: 1; transform: translateY(0); }

.exp-left { display: flex; align-items: baseline; gap: 16px; }
.exp-role {
  font-size: clamp(1.125rem, 3vw, 1.875rem);
  font-weight: 500;
  color: var(--cream);
  transition: opacity 0.2s;
}
.exp-row:hover .exp-role { opacity: 0.7; }
.exp-company { font-size: 0.875rem; color: var(--cream-dim); }
@media (min-width: 768px) { .exp-company { font-size: 1rem; } }
.exp-period { font-size: 0.75rem; color: #4b5563; }
@media (min-width: 768px) { .exp-period { font-size: 0.875rem; } }

/* ── Contact ────────────────────────────────────────────────────────────── */
.contact-section {
  background: #000;
  padding: 120px 16px 160px;
  overflow: hidden;
}
@media (min-width: 768px) { .contact-section { padding: 130px 24px 180px; } }

.contact-inner {
  max-width: 72rem;
  margin: 0 auto;
  text-align: center;
  position: relative;
}

/* Radial glow behind the heading for depth */
.contact-inner::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -60%);
  width: min(700px, 100%);
  height: 400px;
  background: radial-gradient(ellipse at center,
    rgba(225,224,204,0.05) 0%,
    transparent 65%);
  pointer-events: none;
  z-index: 0;
}

.contact-label {
  font-size: 0.625rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--cream-dim);
  margin-bottom: 40px;
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
}
.contact-label::before,
.contact-label::after {
  content: '';
  width: 64px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(225,224,204,0.25));
}
.contact-label::before {
  background: linear-gradient(270deg, transparent, rgba(225,224,204,0.25));
}

.contact-heading {
  font-size: clamp(2.5rem, 7vw, 5rem);
  font-weight: 500;
  line-height: 0.9;
  letter-spacing: -0.04em;
  color: var(--cream);
  max-width: 48rem;
  margin: 0 auto 56px;
  position: relative;
  z-index: 1;
}

/* Social links row */
.contact-links {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 48px;
  position: relative;
  z-index: 1;
}

/* Contact form */
.contact-form {
  max-width: 640px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
  z-index: 1;
  text-align: left;
}

.contact-form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 640px) {
  .contact-form-row { grid-template-columns: 1fr 1fr; }
}

.contact-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact-field-label {
  font-size: 0.625rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--cream-dim);
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
  width: 100%;
  background: #0d0d0d;
  border: 1px solid rgba(225,224,204,0.1);
  border-radius: 0.75rem;
  padding: 14px 18px;
  color: var(--cream);
  font-family: inherit;
  font-size: 0.875rem;
  line-height: 1.5;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  resize: none;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: rgba(225,224,204,0.3);
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: rgba(225,224,204,0.35);
  box-shadow: 0 0 0 3px rgba(225,224,204,0.05);
}

.contact-form textarea {
  min-height: 150px;
}

.contact-form-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.contact-form-note {
  font-size: 0.75rem;
  color: rgba(225,224,204,0.35);
}
.contact-form-note a {
  color: rgba(225,224,204,0.55);
  border-bottom: 1px solid rgba(225,224,204,0.2);
  transition: color 0.2s, border-color 0.2s;
}
.contact-form-note a:hover {
  color: var(--cream);
  border-color: rgba(225,224,204,0.5);
}

/* ── Footer ─────────────────────────────────────────────────────────────── */
footer {
  border-top: 1px solid rgba(225,224,204,0.08);
  padding: 32px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.6875rem;
  color: var(--cream-dim);
}
.footer-mid { display: none; }
@media (min-width: 768px) { .footer-mid { display: block; } }
