/* ============================================================
   CAIO FORLI BARONI — Personal Portfolio
   style.css — v3 Refined Minimalism
   ============================================================ */

/* ── Custom Properties ────────────────────────────────────── */
:root {
  --bg:          #08080B;
  --surface:     #0D0D12;
  --elevated:    #111118;
  --accent:      #00C57A;
  --accent-8:    rgba(0, 197, 122, 0.08);
  --accent-20:   rgba(0, 197, 122, 0.20);
  --text-hi:     #EAEAEE;
  --text-lo:     #72728A;
  --text-dim:    #3A3A50;

  --line:        rgba(255, 255, 255, 0.05);
  --line-hi:     rgba(255, 255, 255, 0.09);

  --type-d:    'Instrument Serif', serif;
  --type-b:    'IBM Plex Sans', sans-serif;
  --type-mono: 'JetBrains Mono', monospace;

  --max-w: 1120px;
  --nav-h: 64px;
  --ease:  cubic-bezier(0.16, 1, 0.3, 1);
  --pad:   clamp(24px, 5vw, 72px);
}

/* ── Reset ────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--text-hi);
  font-family: var(--type-b);
  font-size: 1rem;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Very subtle grain overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.018;
  pointer-events: none;
  z-index: 9999;
}

img  { display: block; max-width: 100%; }
a    { color: inherit; text-decoration: none; }
ul   { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ── Selection ────────────────────────────────────────────── */
::selection {
  background: rgba(0, 197, 122, 0.12);
  color: var(--accent);
}

/* ── Scrollbar ────────────────────────────────────────────── */
::-webkit-scrollbar       { width: 2px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line-hi); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: rgba(0, 197, 122, 0.3); }

/* ── Typography helpers ───────────────────────────────────── */
h1, h2, h3, h4 {
  font-family: var(--type-d);
  font-weight: 400;
  line-height: 1.08;
}

.section-label {
  font-family: var(--type-mono);
  font-size: 0.6rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  display: block;
  margin-bottom: 20px;
}
.section-label::after { display: none; }

.section-title {
  font-family: var(--type-d);
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 400;
  letter-spacing: -0.025em;
  line-height: 1.05;
}

/* ── Layout ───────────────────────────────────────────────── */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--pad);
}

section { padding: clamp(72px, 10vw, 128px) 0; }

/* ================================================================
   NAVIGATION
   ================================================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 100;
  transition: background 0.4s var(--ease), border-color 0.4s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(8, 8, 11, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-color: var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.nav-logo {
  font-family: var(--type-mono);
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  color: var(--text-lo);
  transition: color 0.2s;
}
.nav-logo:hover { color: var(--text-hi); }
.nav-logo .dot { color: var(--accent); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-links a {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-dim);
  letter-spacing: 0.02em;
  transition: color 0.2s;
}
.nav-links a::after { display: none; }
.nav-links a:hover,
.nav-links a.active { color: var(--text-hi); }

.nav-cta {
  color: var(--accent) !important;
  border: none !important;
  padding: 0 !important;
  background: transparent !important;
  border-radius: 0 !important;
}
.nav-cta:hover { color: var(--text-hi) !important; background: transparent !important; }
.nav-cta::after { display: none !important; }

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px; height: 36px;
  padding: 4px;
  color: var(--text-hi);
}
.nav-toggle span {
  display: block;
  width: 100%; height: 1px;
  background: currentColor;
  transition: transform 0.3s var(--ease), opacity 0.2s;
  transform-origin: center;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Mobile drawer */
.nav-mobile {
  display: none;
  position: fixed;
  top: var(--nav-h); left: 0; right: 0;
  background: rgba(8, 8, 11, 0.97);
  backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--line);
  padding: 16px var(--pad) 24px;
  z-index: 99;
  flex-direction: column;
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  padding: 13px 0;
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-lo);
  border-bottom: 1px solid var(--line);
  transition: color 0.2s;
}
.nav-mobile a:last-child { border: none; }
.nav-mobile a:hover { color: var(--text-hi); }

/* ================================================================
   HERO
   ================================================================ */
.hero {
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding-top: var(--nav-h);
  padding-bottom: clamp(64px, 9vw, 104px);
  position: relative;
  overflow: hidden;
  background: var(--bg);
}

/* Subtle ambient glow — only in corner, not a grid */
.hero::after {
  content: '';
  position: absolute;
  top: -15%; right: -5%;
  width: 55%; height: 65%;
  background: radial-gradient(ellipse, rgba(0, 197, 122, 0.04) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

.hero-inner {
  position: relative;
  z-index: 1;
}

/* Availability tag */
.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--type-mono);
  font-size: 0.6rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 44px;
  animation: slideDown 0.6s var(--ease) 0.1s both;
}
.hero-tag-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  animation: pulse 3s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.35; }
}

/* The name — editorial serif, no outline tricks */
.display-name {
  font-family: var(--type-d);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 0.9;
  margin-bottom: 44px;
  animation: revealUp 1.0s var(--ease) 0.2s both;
}
.display-name .first {
  display: block;
  font-size: clamp(4.5rem, 11vw, 10.5rem);
  color: var(--text-hi);
}
.display-name .last {
  display: block;
  font-size: clamp(3rem, 7.2vw, 6.8rem);
  color: var(--text-lo);
  font-style: italic;
  -webkit-text-stroke: 0;
}

/* Hide the decorative rule */
.hero-rule { display: none; }

.hero-headline {
  font-family: var(--type-b);
  font-size: clamp(0.95rem, 1.6vw, 1.08rem);
  font-weight: 400;
  color: var(--text-lo);
  max-width: 420px;
  line-height: 1.8;
  animation: fadeBlurUp 0.9s var(--ease) 0.55s both;
}
.hero-headline em {
  font-style: normal;
  color: var(--text-hi);
}

.hero-sub {
  font-size: clamp(0.875rem, 1.3vw, 0.95rem);
  color: var(--text-dim);
  max-width: 420px;
  line-height: 1.75;
  margin-top: 10px;
  animation: fadeBlurUp 0.9s var(--ease) 0.7s both;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 44px;
  animation: fadeBlurUp 0.8s var(--ease) 0.85s both;
}

/* Scroll indicator */
.hero-scroll {
  position: absolute;
  bottom: 36px;
  right: var(--pad);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-family: var(--type-mono);
  font-size: 0.56rem;
  letter-spacing: 0.14em;
  color: var(--text-dim);
  writing-mode: vertical-rl;
  user-select: none;
  animation: fadeBlurUp 1.0s var(--ease) 1.1s both;
}
.hero-scroll::before {
  content: '';
  width: 1px; height: 40px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: scrollLine 2.4s ease-in-out infinite;
}
@keyframes scrollLine {
  0%   { opacity: 0; transform: scaleY(0); transform-origin: top; }
  45%  { opacity: 1; transform: scaleY(1); transform-origin: top; }
  100% { opacity: 0; transform: scaleY(1); transform-origin: bottom; }
}

/* ================================================================
   BUTTONS
   ================================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--type-b);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  padding: 12px 22px;
  border-radius: 2px;
  transition: all 0.25s var(--ease);
}
.btn svg { width: 14px; height: 14px; flex-shrink: 0; }

.btn-primary {
  background: var(--accent);
  color: #06060A;
}
.btn-primary:hover {
  background: #1FFFAC;
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--text-lo);
  border: 1px solid var(--line-hi);
}
.btn-secondary:hover {
  color: var(--text-hi);
  border-color: rgba(255,255,255,0.14);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-lo);
  padding: 0;
  font-size: 0.82rem;
  gap: 6px;
}
.btn-ghost:hover { color: var(--text-hi); }

/* ================================================================
   ABOUT PREVIEW
   ================================================================ */
.about-preview { border-top: 1px solid var(--line); }

.about-preview-inner {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: clamp(48px, 7vw, 112px);
  align-items: start;
  margin-top: 56px;
}

.about-preview-text {
  font-size: clamp(0.97rem, 1.5vw, 1.05rem);
  line-height: 1.85;
  color: var(--text-lo);
}
.about-preview-text p + p { margin-top: 18px; }
.about-preview-text strong { color: var(--text-hi); font-weight: 400; }
.about-preview-text .cta-row { margin-top: 32px; }

.meta-cards { display: flex; flex-direction: column; }

.meta-card {
  border-top: 1px solid var(--line);
  padding: 20px 0;
  transition: border-color 0.2s;
  position: relative;
  overflow: hidden;
  background: transparent;
}
.meta-card:last-child { border-bottom: 1px solid var(--line); }

.meta-card-label {
  font-family: var(--type-mono);
  font-size: 0.58rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 7px;
}
.meta-card-value {
  font-family: var(--type-b);
  font-size: 0.87rem;
  font-weight: 400;
  color: var(--text-hi);
  line-height: 1.55;
}
.meta-card-value .accent { color: var(--accent); }

/* ================================================================
   SKILLS — HOME CHIPS
   ================================================================ */
.skills { border-top: 1px solid var(--line); }

.skills-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 44px;
}
.skill-chip {
  font-family: var(--type-mono);
  font-size: 0.65rem;
  font-weight: 400;
  color: var(--text-dim);
  border: 1px solid var(--line);
  padding: 6px 14px;
  border-radius: 2px;
  transition: all 0.2s var(--ease);
  letter-spacing: 0.02em;
  background: transparent;
}
.skill-chip:hover {
  color: var(--text-lo);
  border-color: var(--line-hi);
}

/* ================================================================
   FEATURED PROJECTS
   ================================================================ */
.featured-projects { border-top: 1px solid var(--line); }

.projects-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 48px;
}
.projects-header-link {
  font-size: 0.76rem;
  font-weight: 400;
  color: var(--text-dim);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: color 0.2s;
}
.projects-header-link svg { width: 13px; height: 13px; }
.projects-header-link:hover { color: var(--text-hi); }

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
}

.project-card {
  background: var(--bg);
  padding: clamp(28px, 4vw, 48px);
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: background 0.3s var(--ease);
  position: relative;
  overflow: hidden;
}
.project-card::before { display: none; }
.project-card:hover { background: var(--surface); }

.project-card-tag {
  font-family: var(--type-mono);
  font-size: 0.58rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  color: var(--text-dim);
}
.project-card-title {
  font-family: var(--type-d);
  font-size: 1.35rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.project-card-desc {
  font-size: 0.87rem;
  line-height: 1.75;
  color: var(--text-lo);
  flex: 1;
}
.project-card-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.tech-tag {
  font-family: var(--type-mono);
  font-size: 0.6rem;
  font-weight: 400;
  color: var(--text-dim);
  padding: 3px 9px;
  border-radius: 2px;
  border: 1px solid var(--line);
  letter-spacing: 0.03em;
  background: transparent;
}
.project-card-link {
  font-size: 0.76rem;
  font-weight: 400;
  color: var(--text-dim);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 4px;
  transition: color 0.2s, gap 0.2s;
}
.project-card-link svg { width: 12px; height: 12px; }
.project-card-link:hover { color: var(--text-hi); gap: 8px; }

/* ================================================================
   FOOTER
   ================================================================ */
footer {
  border-top: 1px solid var(--line);
  padding: 40px 0;
  position: static;
  overflow: visible;
}
footer::before { display: none; }

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  position: static;
}
.footer-left { display: flex; flex-direction: column; gap: 5px; }
.footer-logo {
  font-family: var(--type-b);
  font-size: 0.82rem;
  font-weight: 400;
  color: var(--text-lo);
  letter-spacing: 0.01em;
}
.footer-copy {
  font-family: var(--type-mono);
  font-size: 0.6rem;
  color: var(--text-dim);
  letter-spacing: 0.04em;
}
.footer-links {
  display: flex;
  align-items: center;
  gap: 24px;
}
.footer-links a {
  font-size: 0.78rem;
  color: var(--text-dim);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s;
}
.footer-links a svg { width: 14px; height: 14px; }
.footer-links a:hover { color: var(--text-lo); }

/* ================================================================
   ABOUT PAGE — PAGE HERO
   ================================================================ */
.page-hero {
  padding-top: calc(var(--nav-h) + clamp(56px, 8vw, 88px));
  padding-bottom: clamp(56px, 8vw, 96px);
  border-bottom: 1px solid var(--line);
}
.page-hero h1 {
  font-family: var(--type-d);
  font-size: clamp(2.8rem, 6vw, 5.5rem);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.0;
  margin-top: 20px;
}
.page-hero p {
  margin-top: 24px;
  font-size: clamp(0.92rem, 1.4vw, 1rem);
  color: var(--text-lo);
  max-width: 520px;
  line-height: 1.8;
}
.page-hero p a { color: var(--text-hi); }

/* ================================================================
   STORY
   ================================================================ */
.story { border-top: 1px solid var(--line); }

.story-grid {
  display: grid;
  grid-template-columns: 1fr 2.4fr;
  gap: clamp(48px, 7vw, 112px);
  align-items: start;
  margin-top: 56px;
}

.story-sidebar {
  position: sticky;
  top: calc(var(--nav-h) + 32px);
}
.story-sidebar-label {
  font-family: var(--type-mono);
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 16px;
  display: block;
}
.story-sidebar p {
  font-size: 0.82rem;
  line-height: 1.75;
  color: var(--text-lo);
}
.story-sidebar p + p { margin-top: 10px; }
.story-sidebar strong { color: var(--text-hi); font-weight: 400; }

.story-body p {
  font-size: clamp(0.97rem, 1.5vw, 1.05rem);
  line-height: 1.88;
  color: var(--text-lo);
}
.story-body p + p { margin-top: 24px; }
.story-body strong { color: var(--text-hi); font-weight: 400; }

/* ================================================================
   TIMELINE
   ================================================================ */
.timeline { border-top: 1px solid var(--line); }

.timeline-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(48px, 7vw, 96px);
  margin-top: 56px;
}
.timeline-col-title {
  font-family: var(--type-mono);
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 32px;
}
.timeline-list {
  display: flex;
  flex-direction: column;
  position: static;
}
.timeline-list::before { display: none; }

.timeline-item {
  padding-bottom: 36px;
  padding-left: 24px;
  position: relative;
  border-left: 1px solid var(--line);
}
.timeline-item:last-child { padding-bottom: 0; }

.tl-dot {
  position: absolute;
  left: -4px; top: 6px;
  width: 7px; height: 7px;
  border-radius: 50%;
  border: 1px solid var(--text-dim);
  background: var(--bg);
  transition: border-color 0.2s;
}
.tl-dot.current {
  border-color: var(--accent);
  background: var(--accent);
}

@keyframes dotPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0, 197, 122, 0.4); }
  60%       { box-shadow: 0 0 0 7px rgba(0, 197, 122, 0); }
}
.tl-dot.current { animation: dotPulse 2.6s ease-out infinite; }

.tl-year {
  font-family: var(--type-mono);
  font-size: 0.58rem;
  letter-spacing: 0.07em;
  color: var(--text-dim);
  margin-bottom: 7px;
}
.tl-title {
  font-family: var(--type-d);
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.tl-sub {
  font-size: 0.8rem;
  color: var(--text-lo);
  margin-top: 3px;
}
.tl-desc {
  font-size: 0.82rem;
  line-height: 1.7;
  color: var(--text-dim);
  margin-top: 10px;
}
.tl-badge {
  display: inline-block;
  font-family: var(--type-mono);
  font-size: 0.56rem;
  letter-spacing: 0.07em;
  color: var(--accent);
  border: 1px solid var(--accent-20);
  padding: 2px 8px;
  border-radius: 2px;
  margin-top: 9px;
}

/* ================================================================
   DETAILED PROJECTS
   ================================================================ */
.projects-detailed { border-top: 1px solid var(--line); }

.project-cards-list {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--line);
  margin-top: 56px;
}

.project-detail-card {
  background: var(--bg);
  padding: clamp(32px, 4.5vw, 56px);
  transition: background 0.25s var(--ease);
  position: relative;
  overflow: hidden;
}
.project-detail-card:hover { background: var(--surface); }

.pdc-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}
.pdc-number {
  font-family: var(--type-mono);
  font-size: 0.6rem;
  letter-spacing: 0.07em;
  color: var(--text-dim);
  flex-shrink: 0;
  margin-top: 4px;
}
.pdc-tag {
  font-family: var(--type-mono);
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  color: var(--text-dim);
  margin-bottom: 9px;
}
.pdc-title {
  font-family: var(--type-d);
  font-size: clamp(1.3rem, 2.4vw, 1.8rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.pdc-desc {
  font-size: 0.9rem;
  line-height: 1.82;
  color: var(--text-lo);
  max-width: 680px;
}
.pdc-highlights {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-top: 24px;
}
.pdc-highlight {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--text-lo);
}
.pdc-highlight::before {
  content: '—';
  color: var(--text-dim);
  font-size: 0.75rem;
  flex-shrink: 0;
  margin-top: 2px;
}
.pdc-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 24px;
}

/* ================================================================
   SKILLS — ABOUT PAGE (grouped)
   ================================================================ */
.skills-full { border-top: 1px solid var(--line); }

.skills-categories {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1px;
  background: var(--line);
  margin-top: 56px;
}
.skill-category {
  background: var(--bg);
  padding: 28px 24px;
  transition: background 0.2s;
  position: relative;
  overflow: visible;
}
.skill-category:hover { background: var(--surface); }

.skill-category-name {
  font-family: var(--type-mono);
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 18px;
  display: block;
}
.skill-item-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.skill-item {
  font-size: 0.85rem;
  color: var(--text-lo);
  font-weight: 400;
  display: flex;
  align-items: center;
  gap: 0;
}
.skill-item::before { display: none; }

/* ================================================================
   LANGUAGES & INTERESTS
   ================================================================ */
.extras { border-top: 1px solid var(--line); }

.extras-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(48px, 7vw, 96px);
  margin-top: 56px;
}
.extras-col-title {
  font-family: var(--type-d);
  font-size: 1.1rem;
  font-weight: 400;
  letter-spacing: -0.01em;
  margin-bottom: 24px;
  color: var(--text-hi);
}

.language-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.language-item:first-of-type { border-top: 1px solid var(--line); }
.lang-name { font-size: 0.9rem; font-weight: 400; color: var(--text-hi); }
.lang-level {
  font-family: var(--type-mono);
  font-size: 0.6rem;
  color: var(--text-dim);
  letter-spacing: 0.04em;
}

.interest-list { display: flex; flex-direction: column; gap: 18px; }
.interest-item {
  font-size: 0.87rem;
  line-height: 1.68;
  color: var(--text-lo);
}
.interest-item strong { color: var(--text-hi); font-weight: 400; }

/* ================================================================
   CONTACT CTA (ABOUT PAGE)
   ================================================================ */
.contact-cta {
  border-top: 1px solid var(--line);
  text-align: center;
}
.contact-cta .section-label {
  justify-content: center;
  text-align: center;
}
.contact-cta .section-label::after,
.contact-cta .section-label::before { display: none; }

.contact-cta-title {
  font-family: var(--type-d);
  font-size: clamp(2.4rem, 5.5vw, 4.2rem);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin: 20px 0 16px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}
.contact-cta-sub {
  font-size: 0.92rem;
  color: var(--text-lo);
  max-width: 400px;
  margin: 0 auto 40px;
  line-height: 1.78;
}
.contact-links-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

/* ================================================================
   SCROLL REVEAL
   ================================================================ */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.rv1 { transition-delay: 0.07s; }
.rv2 { transition-delay: 0.14s; }
.rv3 { transition-delay: 0.21s; }
.rv4 { transition-delay: 0.28s; }

/* ================================================================
   SCROLL PROGRESS BAR
   ================================================================ */
.scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 1px; width: 100%;
  background: var(--accent);
  z-index: 10000;
  transform-origin: left center;
  transform: scaleX(0);
  will-change: transform;
  opacity: 0.6;
}


/* ================================================================
   HERO ENTRANCE ANIMATIONS
   ================================================================ */
@keyframes revealUp {
  from { clip-path: inset(105% 0 0 0); transform: translateY(8px); }
  to   { clip-path: inset(0% 0 0 0);   transform: none; }
}
@keyframes fadeBlurUp {
  from { opacity: 0; filter: blur(4px); transform: translateY(6px); }
  to   { opacity: 1; filter: none;      transform: none; }
}
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-5px); }
  to   { opacity: 1; transform: none; }
}

.page-hero .section-label { animation: slideDown  0.6s var(--ease) 0.10s both; }
.page-hero h1             { animation: revealUp   1.0s var(--ease) 0.22s both; }
.page-hero p              { animation: fadeBlurUp 0.9s var(--ease) 0.54s both; }

@media (prefers-reduced-motion: reduce) {
  .hero-tag, .display-name, .hero-headline, .hero-sub, .hero-actions, .hero-scroll,
  .page-hero .section-label, .page-hero h1, .page-hero p {
    animation: none !important;
  }
  .reveal { transition: none !important; }
}

/* ================================================================
   SUPPORT / CONTACT FORM
   ================================================================ */
.support-section { border-top: 1px solid var(--line); }

.support-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: clamp(48px, 7vw, 112px);
  align-items: start;
  margin-top: 56px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-bottom: 20px;
}

.form-label {
  font-family: var(--type-mono);
  font-size: 0.6rem;
  font-weight: 400;
  letter-spacing: 0.09em;
  color: var(--text-dim);
}

.form-input,
.form-select,
.form-textarea {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 2px;
  color: var(--text-hi);
  font-family: var(--type-b);
  font-size: 0.9rem;
  padding: 11px 14px;
  transition: border-color 0.2s;
  width: 100%;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--text-dim);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: rgba(0, 197, 122, 0.28);
}

.form-select {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%233A3A50' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-color: var(--surface);
  padding-right: 40px;
}

.form-select option {
  background: var(--surface);
  color: var(--text-hi);
}

.form-textarea {
  resize: vertical;
  min-height: 144px;
  line-height: 1.65;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.btn[aria-busy="true"] {
  opacity: 0.5;
  pointer-events: none;
}

.form-status {
  display: none;
  padding: 12px 16px;
  border-radius: 2px;
  font-size: 0.84rem;
  line-height: 1.55;
  margin-top: 14px;
}
.form-status.success {
  display: block;
  background: rgba(0, 197, 122, 0.06);
  border: 1px solid var(--accent-20);
  color: var(--accent);
}
.form-status.error {
  display: block;
  background: rgba(248, 113, 113, 0.06);
  border: 1px solid rgba(248, 113, 113, 0.2);
  color: #f87171;
}

.support-info {
  position: sticky;
  top: calc(var(--nav-h) + 32px);
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--line);
}

.support-info-block {
  background: var(--bg);
  padding: 22px 24px;
  transition: background 0.2s;
  position: relative;
  overflow: hidden;
}
.support-info-block:hover { background: var(--surface); }

.support-info-label {
  font-family: var(--type-mono);
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 10px;
  display: block;
}

.support-info-text {
  font-size: 0.85rem;
  color: var(--text-lo);
  line-height: 1.72;
}

.support-info-text a {
  color: var(--text-hi);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--line-hi);
  transition: text-decoration-color 0.2s;
}

.support-info-text a:hover {
  text-decoration-color: var(--text-lo);
}

.support-info-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

.support-info-item {
  font-size: 0.83rem;
  color: var(--text-lo);
  display: flex;
  align-items: flex-start;
  gap: 10px;
  line-height: 1.55;
}
.support-info-item::before {
  content: '—';
  color: var(--text-dim);
  font-size: 0.72rem;
  flex-shrink: 0;
  margin-top: 1px;
}

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 900px) {
  .about-preview-inner { grid-template-columns: 1fr; }
  .story-grid          { grid-template-columns: 1fr; }
  .story-sidebar       { position: static; }
  .timeline-cols       { grid-template-columns: 1fr; }
  .extras-grid         { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .nav-links   { display: none; }
  .nav-toggle  { display: flex; }
  .projects-grid   { grid-template-columns: 1fr; }
  .projects-header { flex-direction: column; align-items: flex-start; gap: 10px; }
  .hero-scroll     { display: none; }
  .pdc-header      { flex-direction: column-reverse; }
}

@media (max-width: 480px) {
  .skills-categories  { grid-template-columns: 1fr; }
  .hero-actions       { flex-direction: column; align-items: flex-start; }
  .btn                { width: 100%; justify-content: center; }
  .contact-links-row .btn { width: auto; }
  .support-grid       { grid-template-columns: 1fr; }
  .support-info       { position: static; }
  .form-row           { grid-template-columns: 1fr; }
}
