:root {
  --bg: #0b0b0c;
  --surface: #141416;
  --line: rgba(255, 255, 255, .09);
  --text: #f4f2ed;
  --muted: #a09f9a;
  --accent: #ff4b2b;
  --radius: 18px;
  --wrap: 1180px;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --serif: "Instrument Serif", Georgia, serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  color-scheme: dark;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
h1, h2, h3, p, dl, dd, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
em { font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: -.01em; }

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

.wrap { width: min(100% - 40px, var(--wrap)); margin-inline: auto; }

/* Top line that follows the scroll, like a playhead on a timeline */
.playhead {
  position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 30;
  background: var(--accent);
  transform: scaleX(0); transform-origin: left;
}

/* Navigation */
.nav {
  position: sticky; top: 0; z-index: 20;
  background: rgba(11, 11, 12, .72);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 20px; }
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; font-weight: 600; letter-spacing: -.01em; white-space: nowrap; }
.brand .dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.nav-links { display: flex; gap: 30px; font-size: .92rem; color: var(--muted); }
.nav-links a:hover { color: var(--text); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 13px 22px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .18);
  font-size: .95rem; font-weight: 500; line-height: 1; white-space: nowrap;
  transition: background .2s, border-color .2s, color .2s;
}
.btn:hover { border-color: var(--text); }
.btn-primary { background: var(--text); color: var(--bg); border-color: var(--text); }
.btn-primary:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-small { padding: 10px 16px; font-size: .85rem; }

/* Hero */
.hero { padding: clamp(64px, 11vw, 140px) 0 clamp(48px, 7vw, 88px); }
.pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 14px; border: 1px solid var(--line); border-radius: 999px;
  font-size: .82rem; color: var(--muted);
}
.pill i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); animation: blink 1.8s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .25; } }

h1 {
  margin-top: 26px; max-width: 15ch;
  font-size: clamp(2.5rem, 7.4vw, 6.2rem); font-weight: 500;
  line-height: 1.02; letter-spacing: -.04em; text-wrap: balance;
}
.lead { margin-top: 26px; max-width: 46ch; font-size: clamp(1.05rem, 1.6vw, 1.3rem); color: var(--muted); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }

.facts {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
  margin-top: clamp(48px, 8vw, 96px); padding-top: 22px;
  border-top: 1px solid var(--line);
}
.facts dt, .eyebrow, .when, .num {
  font-family: var(--mono); font-size: .76rem; letter-spacing: .08em; text-transform: uppercase;
}
.facts dt { color: var(--muted); margin-bottom: 6px; }
.facts dd { font-size: .98rem; }

/* Sections */
.section { padding: clamp(56px, 9vw, 120px) 0 0; }
.section-head { margin-bottom: clamp(16px, 3vw, 32px); }
.eyebrow { display: block; color: var(--accent); margin-bottom: 12px; }
h2 { font-size: clamp(2rem, 4.6vw, 3.6rem); font-weight: 500; line-height: 1.05; letter-spacing: -.035em; }

/* Work: categories with two clips each */
.category { padding: clamp(26px, 4vw, 44px) 0 clamp(40px, 6vw, 76px); border-top: 1px solid var(--line); }
.category-head {
  display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap;
  gap: 10px 40px; margin-bottom: clamp(22px, 3vw, 36px);
}
.category-head > div { display: flex; align-items: baseline; gap: 16px; }
.category-head .num { color: var(--accent); }
.category-head h3 { font-size: clamp(1.5rem, 2.8vw, 2.2rem); font-weight: 500; line-height: 1.1; letter-spacing: -.03em; }
.category-head p { max-width: 44ch; color: var(--muted); }
.clips { display: grid; grid-template-columns: repeat(2, 1fr); align-items: start; gap: clamp(16px, 2.4vw, 28px); }
.clip { margin: 0; }
.clip figcaption { display: grid; gap: 2px; margin-top: 14px; }
.clip figcaption strong { font-weight: 500; }
.clip figcaption span { font-size: .92rem; color: var(--muted); }

.media {
  display: grid; place-items: center;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
}
.media.vertical { padding: clamp(18px, 3vw, 34px); }
.frame { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; overflow: hidden; }
.media.vertical .frame { aspect-ratio: 9 / 16; width: min(100%, 300px); border-radius: 14px; }
.frame > * { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.frame video { object-fit: contain; background: #000; }

.play {
  display: grid; place-items: center; padding: 0; cursor: pointer;
  color: inherit; font: inherit;
  background:
    radial-gradient(120% 90% at 15% 0%, #2b2b31 0, transparent 60%),
    radial-gradient(90% 80% at 95% 100%, rgba(255, 75, 43, .2) 0, transparent 55%),
    #111113;
}
.play img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* viewfinder corners */
.play::after {
  content: ""; position: absolute; inset: 16px; z-index: 1; pointer-events: none;
  --c: rgba(255, 255, 255, .38); --l: 18px; --t: 1.5px;
  background:
    linear-gradient(var(--c), var(--c)) top left / var(--l) var(--t),
    linear-gradient(var(--c), var(--c)) top left / var(--t) var(--l),
    linear-gradient(var(--c), var(--c)) top right / var(--l) var(--t),
    linear-gradient(var(--c), var(--c)) top right / var(--t) var(--l),
    linear-gradient(var(--c), var(--c)) bottom left / var(--l) var(--t),
    linear-gradient(var(--c), var(--c)) bottom left / var(--t) var(--l),
    linear-gradient(var(--c), var(--c)) bottom right / var(--l) var(--t),
    linear-gradient(var(--c), var(--c)) bottom right / var(--t) var(--l);
  background-repeat: no-repeat;
}
.play .icon {
  position: relative; z-index: 2;
  display: grid; place-items: center; width: 74px; height: 74px; border-radius: 50%;
  background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .28);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  transition: transform .25s, background .25s, border-color .25s;
}
.play .icon svg { width: 24px; height: 24px; margin-left: 3px; fill: #fff; }
@media (hover: hover) {
  .play:hover .icon { transform: scale(1.07); background: var(--accent); border-color: transparent; }
}
.play .tc {
  position: absolute; left: 30px; bottom: 28px; z-index: 2;
  font-family: var(--mono); font-size: .76rem; letter-spacing: .06em; color: rgba(255, 255, 255, .9);
  text-shadow: 0 1px 6px rgba(0, 0, 0, .8);
}

/* About */
.about { border-top: 1px solid var(--line); padding-top: clamp(28px, 4vw, 48px); }
.big { max-width: 34ch; font-size: clamp(1.35rem, 2.6vw, 2.1rem); line-height: 1.3; letter-spacing: -.02em; }
.about-more { max-width: 62ch; margin-top: 22px; color: var(--muted); }
.services { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: clamp(32px, 5vw, 56px); }
.services li { padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.services h3 { font-size: 1.05rem; font-weight: 600; margin-bottom: 8px; }
.services p { font-size: .95rem; color: var(--muted); }

/* Experience */
.cv { display: grid; grid-template-columns: 7fr 4fr; gap: clamp(28px, 6vw, 88px); border-top: 1px solid var(--line); }
.timeline > li { display: grid; grid-template-columns: 120px 1fr; gap: 20px; padding: 24px 0; border-bottom: 1px solid var(--line); }
.when { color: var(--muted); padding-top: 5px; }
.timeline h3, .cv-side h3 { font-size: 1.08rem; font-weight: 600; }
.timeline p { margin-top: 6px; font-size: .95rem; color: var(--muted); }
.timeline ul { display: grid; gap: 8px; margin-top: 12px; }
.timeline ul li { position: relative; padding-left: 18px; font-size: .95rem; color: var(--muted); }
.timeline ul li::before { content: ""; position: absolute; left: 0; top: .78em; width: 7px; height: 1.5px; background: var(--accent); }
.cv-side { display: grid; gap: 32px; align-content: start; padding-top: 24px; }
.cv-side h3 { margin-bottom: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { padding: 7px 13px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); font-size: .88rem; }

/* Contact */
.contact { padding-bottom: clamp(56px, 9vw, 120px); }
.mail {
  display: inline-block; margin-top: 28px;
  font-size: clamp(1.05rem, 4.2vw, 3rem); letter-spacing: -.03em; line-height: 1.2;
  border-bottom: 2px solid var(--accent); overflow-wrap: anywhere;
  transition: color .2s;
}
.mail:hover { color: var(--accent); }
.contact-note { margin-top: 26px; font-size: .95rem; color: var(--muted); }
.socials { display: flex; flex-wrap: wrap; gap: 10px 28px; margin-top: 30px; color: var(--muted); }
.socials a:hover { color: var(--text); }

.footer {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 24px 0 36px; border-top: 1px solid var(--line);
  font-size: .85rem; color: var(--muted);
}
.footer a:hover { color: var(--text); }

/* Soft reveal on scroll */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.in { opacity: 1; transform: none; }

@media (max-width: 1000px) {
  .services { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  .nav-links { display: none; }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .cv { grid-template-columns: 1fr; }
  .cv-side { padding-top: 0; }
}

@media (max-width: 700px) {
  .clips { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  .nav .wrap { gap: 12px; }
  .brand { font-size: .95rem; }
  .btn-small { padding: 9px 13px; }
  .facts { grid-template-columns: 1fr; gap: 16px; }
  .services { grid-template-columns: 1fr; }
  .timeline > li { grid-template-columns: 1fr; gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .pill i { animation: none; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
}
