/* ---------- variables ---------- */
:root {
  --bg: #131211;
  --bg-alt: #191816;
  --surface: #1d1c19;
  --ink: #f4f2ec;
  --ink-dim: #a7a498;
  --ink-faint: #6c6a5f;
  --line: rgba(244,242,236,0.09);
  --accent: #ff7a30;
  --accent-ink: #131211;
  --radius: 4px;
  --maxw: 1180px;
  --font-display: "Archivo", sans-serif;
  --font-body: "Space Grotesk", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  position: relative;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
::selection { background: var(--accent); color: var(--accent-ink); }

/* ---------- custom cursor ---------- */
.has-custom-cursor, .has-custom-cursor a, .has-custom-cursor button { cursor: none; }
.cursor-dot {
  position: fixed;
  top: 0; left: 0;
  width: 18px; height: 18px;
  margin: -9px 0 0 -9px;
  border-radius: 50%;
  border: 1px solid var(--ink);
  pointer-events: none;
  z-index: 2000;
  mix-blend-mode: difference;
  transform: translate3d(-100px, -100px, 0) scale(1);
  transition: width .25s ease, height .25s ease, margin .25s ease, background .25s ease, border-color .25s ease, opacity .2s ease;
  opacity: 0;
}
.has-custom-cursor .cursor-dot { opacity: 1; }
.cursor-dot.is-active {
  width: 10px; height: 10px;
  margin: -5px 0 0 -5px;
  background: var(--ink);
}
.cursor-dot.is-big {
  width: 64px; height: 64px;
  margin: -32px 0 0 -32px;
  background: var(--accent);
  border-color: var(--accent);
  mix-blend-mode: normal;
  opacity: 0.9;
}
.cursor-label {
  position: fixed;
  top: 0; left: 0;
  transform: translate3d(-100px, -100px, 0) scale(0.6);
  pointer-events: none;
  z-index: 2001;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  color: var(--accent-ink);
  opacity: 0;
  transition: opacity .2s ease, transform .2s ease;
}
.cursor-label.is-visible { opacity: 1; }
@media (pointer: coarse), (prefers-reduced-motion: reduce) {
  .cursor-dot, .cursor-label { display: none; }
}

/* ---------- texture: grain + grid lines ---------- */
.texture { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
.texture::before {
  content: "";
  position: absolute; inset: 0;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.dot-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
main, .nav, .footer, .lightbox { position: relative; z-index: 1; }

.section-inner { max-width: var(--maxw); margin: 0 auto; padding: 0 32px; }
.kicker {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 20px;
}
.section-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  margin-bottom: 48px;
  letter-spacing: -0.01em;
}
.mark {
  background: var(--accent);
  color: var(--accent-ink);
  padding: 0 10px;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

/* ---------- reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 15px 28px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.92rem;
  border: 1px solid var(--ink);
  transition: background .2s ease, color .2s ease, border-color .2s ease, transform .2s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn-primary:hover { transform: translateY(-2px); background: var(--ink); border-color: var(--ink); }
.btn-line { background: transparent; color: var(--ink); }
.btn-line:hover { border-color: var(--accent); color: var(--accent); }
.btn-lg { padding: 18px 32px; font-size: 1rem; }

/* ---------- nav ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 24px 0;
  transition: padding .3s ease, background .3s ease, border-color .3s ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(19,18,17,0.85);
  backdrop-filter: blur(10px);
  padding: 16px 0;
  border-color: var(--line);
}
.nav-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  gap: 24px;
}
.nav-mark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: -0.02em;
  margin-right: auto;
}
.nav-mark .dot { color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-link {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--ink-dim);
  transition: color .2s ease;
}
.nav-link:hover, .nav-link.active { color: var(--ink); }
.nav-resume {
  font-size: 0.85rem;
  font-weight: 700;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 9px 18px;
  border-radius: var(--radius);
  transition: background .2s ease;
}
.nav-resume:hover { background: var(--ink); }
.nav-toggle { display: none; flex-direction: column; gap: 5px; width: 26px; }
.nav-toggle span { display: block; height: 2px; width: 100%; background: var(--ink); transition: transform .25s ease, opacity .25s ease; }

/* ---------- hero ---------- */
.hero { padding: 170px 0 110px; }
.hero-inner {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 60px;
  align-items: center;
}
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-dim);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 16px 7px 12px;
  margin-bottom: 26px;
}
.status-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 3px rgba(74,222,128,0.18);
}
.eyebrow {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 24px;
}
.hero-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.4rem, 5.4vw, 4.1rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: 28px;
}
.hero-sub { color: var(--ink-dim); font-size: 1.08rem; max-width: 480px; margin-bottom: 38px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 42px; }
.hero-social { display: flex; gap: 22px; }
.hero-social a {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-dim);
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
  transition: color .2s ease, border-color .2s ease;
}
.hero-social a:hover { color: var(--accent); border-color: var(--accent); }

.hero-figure {
  justify-self: end;
  width: 100%;
  max-width: 320px;
}
.hero-figure img {
  width: 100%;
  aspect-ratio: 4/5;
  object-fit: cover;
  border-radius: 6px;
}

/* ---------- about ---------- */
.about { padding: 110px 0; }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: start; }
.about-lead { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.7rem, 3vw, 2.3rem); line-height: 1.25; }
.about-body p { color: var(--ink-dim); margin-bottom: 18px; font-size: 1.02rem; }

/* ---------- specialties ---------- */
.specialties { padding: 0 0 110px; }
.specialty-row {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 30px;
  padding: 30px 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
}
.specialty-row h3 { font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; }
.specialty-row p { color: var(--ink-dim); font-size: 1rem; max-width: 520px; }

.skills-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  margin-top: 70px;
}
.skills-disclaimer {
  margin-top: 26px;
  font-size: 0.76rem;
  color: var(--ink-faint);
  font-style: italic;
}
.skills-heading {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
  margin-bottom: 24px;
}
.skill-bar { margin-bottom: 18px; }
.skill-bar-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 0.88rem;
  margin-bottom: 7px;
}
.skill-bar-top span:first-child { font-weight: 600; }
.skill-bar-pct { color: var(--ink-faint); font-size: 0.78rem; font-weight: 500; }
.skill-bar-track {
  display: block;
  height: 4px;
  background: var(--line);
  border-radius: 2px;
  overflow: hidden;
}
.skill-bar-fill {
  display: block;
  height: 100%;
  width: 0;
  background: var(--accent);
  border-radius: 2px;
  transition: width 1.1s cubic-bezier(.22, .61, .36, 1);
}
.reveal.in-view .skill-bar-fill { width: var(--pct); }

/* ---------- work ---------- */
.work { padding: 110px 0; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 46px; }
.filter-btn {
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--ink-dim);
  padding: 9px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  transition: all .2s ease;
}
.filter-btn:hover { color: var(--ink); border-color: var(--ink-dim); }
.filter-btn.active { color: var(--accent-ink); background: var(--accent); border-color: var(--accent); }

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-flow: dense;
  align-items: start;
  gap: 34px 26px;
}
.card { position: relative; cursor: pointer; }
.card.hide { display: none; }
.card-featured { grid-column: span 2; }
.card-featured .card-frame { aspect-ratio: 16/9; }
.card-frame {
  position: relative;
  aspect-ratio: 4/3;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 6px;
}
.card-frame img, .card-frame video {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: top;
  transition: transform .5s ease;
}
.card:hover .card-frame img, .card:hover .card-frame video { transform: scale(1.045); }
.card-index {
  position: absolute; top: 12px; left: 12px;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--accent-ink);
  background: var(--accent);
  padding: 3px 8px;
  border-radius: 3px;
}
.card-play {
  position: absolute; top: 12px; right: 12px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--ink);
  background: rgba(19,18,17,0.7);
  padding: 3px 9px;
  border-radius: 3px;
}
.card-case {
  position: absolute; top: 12px; right: 12px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--accent-ink);
  background: var(--accent);
  padding: 3px 9px;
  border-radius: 3px;
}
.card-meta { display: flex; justify-content: space-between; align-items: baseline; margin-top: 14px; gap: 12px; }
.card-title { font-family: var(--font-display); font-weight: 700; font-size: 0.98rem; }
.card-tag { font-size: 0.72rem; font-weight: 500; color: var(--ink-faint); white-space: nowrap; }

/* ---------- experience ---------- */
.experience { padding: 110px 0; }
.timeline-row {
  display: grid;
  grid-template-columns: 180px 1fr auto;
  gap: 20px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
}
.timeline-date { font-size: 0.85rem; color: var(--ink-faint); font-weight: 500; }
.timeline-role { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; }
.timeline-org { color: var(--ink-dim); font-size: 0.95rem; text-align: right; }

/* ---------- contact ---------- */
.contact { padding: 130px 0; text-align: center; }
.contact-inner { display: flex; flex-direction: column; align-items: center; }
.contact-sub { color: var(--ink-dim); max-width: 460px; margin: 0 auto 40px; font-size: 1.05rem; }
.contact-social { display: flex; gap: 22px; font-weight: 500; font-size: 0.86rem; margin-top: 30px; }
.contact-social a { color: var(--ink-dim); border-bottom: 1px solid transparent; padding-bottom: 2px; transition: color .2s ease, border-color .2s ease; }
.contact-social a:hover { color: var(--accent); border-color: var(--accent); }

/* ---------- footer ---------- */
.footer { padding: 30px 0 50px; }
.footer-inner { display: flex; justify-content: space-between; font-size: 0.8rem; color: var(--ink-faint); }

/* ---------- lightbox ---------- */
.lightbox {
  position: fixed; inset: 0;
  background: rgba(10,9,8,0.94);
  z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  padding: 40px 20px;
  opacity: 0; pointer-events: none;
  transition: opacity .3s ease;
}
.lightbox.open { opacity: 1; pointer-events: auto; }
.lightbox-content {
  max-width: 1000px; width: 100%;
  max-height: 88vh;
  display: flex; flex-direction: column;
  background: var(--surface);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.lightbox-media { background: #000; display: flex; align-items: center; justify-content: center; max-height: 68vh; overflow: hidden; }
.lightbox-media img, .lightbox-media video { width: 100%; height: 100%; object-fit: contain; max-height: 68vh; }
.lightbox-info { padding: 22px 28px; }
.lightbox-tag {
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--accent);
}
.lightbox-info h3 { font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; margin: 8px 0 10px; }
.lightbox-info p { color: var(--ink-dim); }
.cs-block { margin-top: 16px; }
.cs-block:first-of-type { margin-top: 2px; }
.cs-label {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 4px;
}
.cs-block p { color: var(--ink-dim); font-size: 0.94rem; }
.lightbox-close, .lightbox-nav {
  position: absolute;
  color: var(--ink);
  display: flex; align-items: center; justify-content: center;
  transition: opacity .2s ease;
}
.lightbox-close:hover, .lightbox-nav:hover { opacity: 0.6; }
.lightbox-close { top: 26px; right: 32px; font-size: 0.82rem; font-weight: 600; letter-spacing: 0.04em; }
.lightbox-nav { font-size: 2.2rem; font-weight: 300; width: 44px; height: 44px; }
.lightbox-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 12px; top: 50%; transform: translateY(-50%); }

/* ---------- responsive ---------- */
@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; gap: 34px; }
  .hero-figure { order: -1; justify-self: start; max-width: 200px; }
  .about-grid { grid-template-columns: 1fr; gap: 30px; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .specialty-row, .timeline-row { grid-template-columns: 1fr; gap: 8px; }
  .skills-block { grid-template-columns: 1fr; gap: 40px; margin-top: 50px; }
  .timeline-org { text-align: left; }
}

@media (max-width: 720px) {
  .nav-links { position: fixed; top: 66px; left: 0; right: 0; bottom: 0; background: var(--bg); flex-direction: column; align-items: flex-start; padding: 30px 32px; gap: 24px; transform: translateX(100%); transition: transform .3s ease; }
  .nav-links.open { transform: translateX(0); }
  .nav-toggle { display: flex; }
  .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); }
  .grid { grid-template-columns: 1fr; }
  .card-featured { grid-column: span 1; }
  .card-featured .card-frame { aspect-ratio: 4/3; }
  .lightbox-nav { width: 36px; height: 36px; font-size: 1.8rem; }
  .lightbox-close { top: 16px; right: 16px; }
}
