/* ============================================================
   Damian Smerdon — Video Editor, Adelaide
   styles.css  (2026 redesign)
   ------------------------------------------------------------
   Contents
   01  Tokens
   02  Base / reset
   03  Utilities (container, labels, buttons, reveal)
   04  Nav + mobile menu
   05  Hero
   06  Timeline strip
   07  Work cards + featured tile
   08  About / stats / clients
   09  Services
   10  Process
   11  Contact
   12  Footer
   13  Work page (samples.html)
   14  Thanks page
   15  Video modal + form modal
   17  Responsive
   18  Reduced motion
   ============================================================ */

/* ------------------------------------------------------------
   01  Tokens
   ------------------------------------------------------------ */
:root {
  --bg:         #0B0B0A;
  --bg-2:       #111110;
  --surface:    #171716;
  --surface-2:  #1E1E1C;
  --line:       rgba(242, 238, 232, 0.08);
  --line-2:     rgba(242, 238, 232, 0.16);
  --text:       #F2EEE8;
  --muted:      #A39E96;
  --dim:        #6E6962;
  --accent:     #C9924F;
  --accent-2:   #E6C08C;
  --accent-ink: #1A1208;

  --font-sans:  'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-serif: 'Instrument Serif', 'Iowan Old Style', Georgia, serif;
  --font-mono:  'DM Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;

  --container:  1360px;
  --gutter:     clamp(1.25rem, 4vw, 3.5rem);
  --section:    clamp(5rem, 11vw, 9.5rem);
  --nav-h:      4.5rem;
  --radius:     14px;
  --radius-sm:  8px;

  --ease-out:    cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  background: var(--bg);
}

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

/* Film grain — one fixed layer, very low opacity */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 2000;
  pointer-events: none;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 240 240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 240px 240px;
}

img, picture, svg, video { display: block; max-width: 100%; }
img { height: auto; }

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul { list-style: none; }

::selection { background: var(--accent); color: var(--accent-ink); }

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

h1, h2, h3, h4 {
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

p { text-wrap: pretty; }

em.serif, .serif {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  color: var(--accent-2);
  letter-spacing: 0;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  z-index: 3000;
  padding: 0.6rem 1rem;
  background: var(--accent);
  color: var(--accent-ink);
  border-radius: 999px;
  font-weight: 500;
}
.skip-link:focus { top: 1rem; }

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hidden { display: none !important; }

/* ------------------------------------------------------------
   03  Utilities
   ------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  padding-block: var(--section);
  scroll-margin-top: var(--nav-h);
}

.section--tight { padding-block: calc(var(--section) * 0.7); }

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

.section-title {
  font-size: clamp(2rem, 4.2vw, 3.4rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
  max-width: 18ch;
}

.label {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Runtime / metadata in mono */
.rt {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  color: var(--dim);
  text-transform: none;
}
.lede {
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  line-height: 1.6;
  color: var(--muted);
  max-width: 48ch;
}

/* Text link with arrow */
.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--text);
  white-space: nowrap;
  padding-bottom: 0.2rem;
  border-bottom: 1px solid var(--line-2);
  transition: border-color 0.3s, color 0.3s;
}
.arrow-link svg { width: 14px; height: 14px; transition: transform 0.4s var(--ease-out); }
.arrow-link:hover { border-color: var(--accent); color: var(--accent-2); }
.arrow-link:hover svg { transform: translateX(4px); }

/* Buttons */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.95rem 1.6rem 0.95rem 1.75rem;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1;
  white-space: nowrap;
  border: 1px solid transparent;
  transition: background 0.35s var(--ease-out), color 0.35s, border-color 0.35s, transform 0.35s var(--ease-out);
  isolation: isolate;
  overflow: hidden;
}
.btn svg { width: 16px; height: 16px; flex: none; transition: transform 0.4s var(--ease-out); }
.btn:hover svg { transform: translateX(3px); }
.btn:active { transform: scale(0.98); }

.btn--primary {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
}
.btn--primary::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--accent-2);
  transform: translateY(101%);
  transition: transform 0.45s var(--ease-out);
}
.btn--primary:hover::before { transform: translateY(0); }

.btn--ghost {
  color: var(--text);
  border-color: var(--line-2);
  background: rgba(11, 11, 10, 0.35);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.btn--ghost:hover { border-color: var(--text); background: rgba(242, 238, 232, 0.06); }

.btn--small { padding: 0.7rem 1.1rem 0.7rem 1.25rem; font-size: 0.8rem; }

/* Scroll reveal (only when JS is present) */
html.js [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
  transition-delay: calc(var(--i, 0) * 90ms);
}
html.js [data-reveal].in { opacity: 1; transform: none; }

/* ------------------------------------------------------------
   04  Nav
   ------------------------------------------------------------ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 500;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  transition: background 0.4s, border-color 0.4s, backdrop-filter 0.4s;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled {
  background: rgba(11, 11, 10, 0.72);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom-color: var(--line);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.brand {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
  gap: 0.2rem;
}
.brand__name {
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.brand__role {
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 2rem;
}
.nav__links a {
  position: relative;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.3s;
  padding: 0.4rem 0;
}
.nav__links a::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s var(--ease-out);
}
.nav__links a:hover,
.nav__links a[aria-current="page"] { color: var(--text); }
.nav__links a:hover::after,
.nav__links a[aria-current="page"]::after { transform: scaleX(1); transform-origin: left; }

.nav__links .nav__cta {
  margin-left: 0.5rem;
  padding: 0.7rem 1.1rem 0.7rem 1.25rem;
  color: var(--accent-ink);
}
.nav__links .nav__cta:hover { color: var(--accent-ink); }
.nav__links .nav__cta::after { display: none; }

/* Burger */
.burger {
  display: none;
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line-2);
  place-items: center;
  position: relative;
  z-index: 701;
}
.burger span {
  position: absolute;
  left: 13px;
  width: 18px; height: 1.5px;
  background: var(--text);
  transition: transform 0.4s var(--ease-out), opacity 0.3s, top 0.3s;
}
.burger span:nth-child(1) { top: 17px; }
.burger span:nth-child(2) { top: 22px; }
.burger span:nth-child(3) { top: 27px; }
.burger[aria-expanded="true"] span:nth-child(1) { top: 22px; transform: rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { top: 22px; transform: rotate(-45deg); }

/* Full-screen mobile menu */
.menu {
  position: fixed;
  inset: 0;
  z-index: 700;
  background: rgba(11, 11, 10, 0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--gutter);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s, visibility 0s 0.4s;
}
.menu.is-open { opacity: 1; visibility: visible; transition: opacity 0.4s; }

.menu__links { display: grid; gap: 0.25rem; }
.menu__links a {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  font-size: clamp(2.4rem, 9vw, 3.6rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.15;
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--line);
  transform: translateY(20px);
  opacity: 0;
  transition: transform 0.6s var(--ease-out), opacity 0.6s;
}
.menu__links a .serif { font-size: 0.45em; }
.menu.is-open .menu__links a { transform: none; opacity: 1; }
.menu.is-open .menu__links a:nth-child(2) { transition-delay: 0.06s; }
.menu.is-open .menu__links a:nth-child(3) { transition-delay: 0.12s; }
.menu.is-open .menu__links a:nth-child(4) { transition-delay: 0.18s; }

.menu__foot {
  margin-top: 2.5rem;
  font-size: 0.8rem;
  color: var(--dim);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

body.menu-open { overflow: hidden; }

/* ------------------------------------------------------------
   05  Hero
   ------------------------------------------------------------ */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  padding: calc(var(--nav-h) + 3rem) 0 clamp(2rem, 5vh, 3.5rem);
  overflow: hidden;
  isolation: isolate;
}

.hero__frames {
  position: absolute;
  inset: 0;
  z-index: -2;
  background: #050504;
}

/* Optional self-hosted showreel loop (see the comment in index.html) */
.hero__video {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.85) brightness(0.62);
}
.hero__video ~ .hero__frames { display: none; }
.hero__frames img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1);
  filter: saturate(0.85) brightness(0.62);
  transition: opacity 1.8s var(--ease-in-out), transform 9s linear;
  will-change: opacity, transform;
}
.hero__frames img.is-active {
  opacity: 1;
  transform: scale(1.09);
}

.hero__scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(to top, rgba(11,11,10,0.98) 0%, rgba(11,11,10,0.75) 28%, rgba(11,11,10,0.25) 60%, rgba(11,11,10,0.35) 100%),
    linear-gradient(to right, rgba(11,11,10,0.75) 0%, rgba(11,11,10,0.2) 55%, rgba(11,11,10,0) 100%);
}

.hero__inner {
  display: grid;
  gap: clamp(1.5rem, 3vw, 2.5rem);
}

.hero__eyebrow {
  color: var(--muted);
}

.hero__title {
  font-size: clamp(2.9rem, 8vw, 7.4rem);
  line-height: 0.97;
  letter-spacing: -0.04em;
  font-weight: 500;
  max-width: 11.5ch;
}
.hero__title .line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.18em;
  margin-bottom: -0.18em;
}
.hero__title .line > span { display: inline-block; }
html.js .hero__title .line > span {
  transform: translateY(110%);
  animation: rise 1.1s var(--ease-out) forwards;
}
html.js .hero__title .line:nth-child(2) > span { animation-delay: 0.12s; }
html.js .hero__title .line:nth-child(3) > span { animation-delay: 0.24s; }
@keyframes rise { to { transform: translateY(0); } }

.hero__title em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  color: var(--accent-2);
  letter-spacing: -0.01em;
  padding-right: 0.06em;
}

.hero__lede {
  max-width: 46ch;
  font-size: clamp(1.05rem, 1.45vw, 1.25rem);
  color: var(--muted);
  line-height: 1.55;
}

.hero__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem 2rem;
  margin-top: 0.5rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.hero__status {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--muted);
  text-transform: uppercase;
}
.hero__status .rec {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--accent-2);
}
.hero__status .rec::before {
  content: '';
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 rgba(201, 146, 79, 0.6);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(201, 146, 79, 0.55); }
  70%  { box-shadow: 0 0 0 8px rgba(201, 146, 79, 0); }
  100% { box-shadow: 0 0 0 0 rgba(201, 146, 79, 0); }
}
.hero__status .sep { color: var(--dim); }
.hero__now { color: var(--text); text-transform: none; letter-spacing: 0.02em; }

/* ------------------------------------------------------------
   06  Timeline strip
   ------------------------------------------------------------ */
.timeline {
  position: relative;
  background: var(--bg-2);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  --clip-w: 232px;
  --clip-gap: 6px;
}

.timeline__ruler {
  position: relative;
  height: 26px;
  border-bottom: 1px solid var(--line);
  background-image:
    repeating-linear-gradient(to right, var(--line-2) 0 1px, transparent 1px calc((var(--clip-w) + var(--clip-gap)) / 4)),
    repeating-linear-gradient(to right, var(--line-2) 0 1px, transparent 1px calc(var(--clip-w) + var(--clip-gap)));
  background-size: 100% 7px, 100% 14px;
  background-repeat: repeat-x;
  background-position: left bottom, left bottom;
}

.timeline__tc {
  position: absolute;
  top: 5px;
  left: calc(50% + 14px);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: var(--accent-2);
  z-index: 4;
}

.timeline__label {
  position: absolute;
  top: 5px;
  left: var(--gutter);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim);
}

.timeline__viewport {
  overflow-x: auto;
  overflow-y: hidden;
  padding: 10px 0 12px;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  cursor: grab;
}
.timeline__viewport::-webkit-scrollbar { display: none; }
.timeline__viewport.is-dragging { cursor: grabbing; }

.timeline__track {
  display: flex;
  width: max-content;
}

.clip {
  position: relative;
  flex: none;
  width: var(--clip-w);
  aspect-ratio: 16 / 9;
  margin-right: var(--clip-gap);
  border-radius: 6px;
  overflow: hidden;
  background: var(--surface);
  border-top: 3px solid var(--line-2);
  padding: 0;
  text-align: left;
  transition: border-color 0.3s;
}
.clip:hover, .clip:focus-visible { border-top-color: var(--accent); }
.clip img {
  width: 100%; height: 100%;
  object-fit: cover;
  filter: saturate(0.8) brightness(0.8);
  transition: filter 0.4s, transform 0.8s var(--ease-out);
  user-select: none;
  -webkit-user-drag: none;
}
.clip:hover img, .clip:focus-visible img { filter: none; transform: scale(1.04); }
.clip::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(11,11,10,0.8), transparent 55%);
  pointer-events: none;
}
.clip__label {
  position: absolute;
  left: 10px; right: 10px; bottom: 8px;
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
}
.clip__label .rt { color: var(--muted); }

.playhead {
  position: absolute;
  top: 0; bottom: 0;
  left: 50%;
  width: 2px;
  margin-left: -1px;
  background: var(--accent-2);
  z-index: 3;
  pointer-events: none;
}
.playhead::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  width: 14px; height: 14px;
  transform: translateX(-50%);
  background: var(--accent-2);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
}

/* ------------------------------------------------------------
   07  Work cards + featured tile
   ------------------------------------------------------------ */
.work {
  position: relative;
  display: block;
  width: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
  aspect-ratio: 16 / 9;
  text-align: left;
  isolation: isolate;
  transform: translateZ(0);
}

/* The one featured tile on the home page */
.work--featured { aspect-ratio: 16 / 9; }
.work--featured .work__shade {
  background: linear-gradient(to top, rgba(11,11,10,0.92) 0%, rgba(11,11,10,0.45) 40%, rgba(11,11,10,0.05) 100%);
}
.work--featured .work__meta {
  left: clamp(1.25rem, 3vw, 2.5rem);
  right: clamp(1.25rem, 3vw, 2.5rem);
  bottom: clamp(1.25rem, 3vw, 2.25rem);
  gap: 0.5rem;
}
.work--featured .work__title {
  font-size: clamp(1.5rem, 3.4vw, 2.8rem);
  letter-spacing: -0.025em;
  max-width: 22ch;
}
.work__desc {
  display: block;
  font-size: clamp(0.9rem, 1.1vw, 1.05rem);
  color: var(--muted);
  line-height: 1.5;
  max-width: 60ch;
}
.work--featured .work__year { top: 1.25rem; right: 1.25rem; }

.work img {
  width: 100%; height: 100%;
  object-fit: cover;
  transform: scale(1.001);
  transition: transform 1.2s var(--ease-out), filter 0.6s;
}
.work:hover img, .work:focus-visible img { transform: scale(1.055); }

.work__shade {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(to top, rgba(11,11,10,0.9) 0%, rgba(11,11,10,0.35) 45%, rgba(11,11,10,0.05) 100%);
  transition: opacity 0.5s;
}

.work__meta {
  position: absolute;
  left: clamp(1rem, 2vw, 1.5rem);
  right: clamp(1rem, 2vw, 1.5rem);
  bottom: clamp(0.9rem, 1.8vw, 1.4rem);
  z-index: 2;
  display: grid;
  gap: 0.3rem;
}
.work__client {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
.work__client .rt { color: var(--dim); }
.work__title {
  font-size: clamp(1rem, 1.35vw, 1.25rem);
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--text);
  text-wrap: balance;
}
.work__year {
  position: absolute;
  top: 0.9rem; right: 0.9rem;
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  padding: 0.35rem 0.55rem;
  border-radius: 999px;
  color: var(--text);
  background: rgba(11,11,10,0.55);
  border: 1px solid rgba(242,238,232,0.12);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.work__play {
  position: absolute;
  top: 50%; left: 50%;
  z-index: 2;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: rgba(242,238,232,0.12);
  border: 1px solid rgba(242,238,232,0.3);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: grid;
  place-items: center;
  transform: translate(-50%, -50%) scale(0.7);
  opacity: 0;
  transition: transform 0.5s var(--ease-out), opacity 0.4s;
}
.work__play svg { width: 20px; height: 20px; margin-left: 3px; fill: var(--text); }
.work:hover .work__play, .work:focus-visible .work__play { transform: translate(-50%, -50%) scale(1); opacity: 1; }

/* ------------------------------------------------------------
   08  About / stats / clients
   ------------------------------------------------------------ */
.about {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: start;
}

.about__statement {
  font-size: clamp(1.6rem, 3vw, 2.6rem);
  line-height: 1.22;
  letter-spacing: -0.025em;
  font-weight: 400;
  max-width: 24ch;
}
.about__statement em {
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--accent-2);
  font-size: 1.06em;
}

.about__copy {
  margin-top: 1.75rem;
  color: var(--muted);
  max-width: 52ch;
  display: grid;
  gap: 1rem;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.stat {
  background: var(--bg);
  padding: clamp(1.25rem, 2vw, 1.75rem) clamp(1rem, 1.6vw, 1.5rem);
  display: grid;
  gap: 0.5rem;
  align-content: start;
}
.stat__value {
  font-family: var(--font-serif);
  font-size: clamp(2.4rem, 4vw, 3.4rem);
  line-height: 0.95;
  letter-spacing: -0.02em;
  color: var(--text);
}
.stat__value i { font-style: italic; color: var(--accent-2); }
.stat__label {
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.4;
}

.clients { margin-top: 2rem; }
.clients__title {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--dim);
  margin-bottom: 1rem;
}
.clients ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.clients li {
  font-size: 0.82rem;
  color: var(--muted);
  padding: 0.4rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  transition: color 0.3s, border-color 0.3s;
}
.clients li:hover { color: var(--text); border-color: var(--line-2); }

/* ------------------------------------------------------------
   09  Services
   ------------------------------------------------------------ */
.services {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.5rem, 3vw, 3rem);
  border-top: 1px solid var(--line);
}
.service {
  padding-top: clamp(1.5rem, 2.5vw, 2.25rem);
  position: relative;
}
.service::before {
  content: '';
  position: absolute;
  top: -1px; left: 0;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width 0.8s var(--ease-out);
}
.service.in::before, .service:hover::before { width: 100%; }

.service__title {
  font-size: clamp(1.35rem, 1.9vw, 1.7rem);
  margin: 0 0 0.4rem;
}
.service__desc {
  color: var(--muted);
  font-size: 0.95rem;
  margin-bottom: 1.25rem;
  max-width: 34ch;
}
.service ul li {
  padding: 0.7rem 0;
  border-top: 1px solid var(--line);
  font-size: 0.95rem;
  color: var(--text);
}

/* ------------------------------------------------------------
   10  Process
   ------------------------------------------------------------ */
.process {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr);
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: start;
}
.process__sticky {
  position: sticky;
  top: calc(var(--nav-h) + 2rem);
}
.process__sticky .lede { margin-top: 1.25rem; }

.steps { display: grid; }
.step {
  padding: clamp(1.75rem, 3vw, 2.5rem) 0;
  border-top: 1px solid var(--line);
}
.step:last-child { border-bottom: 1px solid var(--line); }
.step h3 {
  font-size: clamp(1.35rem, 2vw, 1.8rem);
  margin-bottom: 0.7rem;
}
.step p {
  color: var(--muted);
  max-width: 52ch;
}

/* ------------------------------------------------------------
   11  Contact
   ------------------------------------------------------------ */
.contact {
  background: var(--bg-2);
  border-top: 1px solid var(--line);
  position: relative;
  overflow: hidden;
}
.contact::before {
  content: '';
  position: absolute;
  width: 60vw; height: 60vw;
  max-width: 900px; max-height: 900px;
  right: -20vw; top: -30vw;
  background: radial-gradient(circle, rgba(201,146,79,0.14) 0%, rgba(201,146,79,0) 60%);
  pointer-events: none;
}
.contact__grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: start;
}
.contact__title {
  font-size: clamp(2.2rem, 5vw, 4.2rem);
  line-height: 1;
  letter-spacing: -0.035em;
  max-width: 14ch;
}
.contact__title em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  color: var(--accent-2);
}
.contact__copy { margin-top: 1.5rem; }
.contact__details {
  margin-top: 2.5rem;
  display: grid;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: var(--muted);
}
.contact__details dt {
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dim);
  margin-bottom: 0.15rem;
}
.contact__details dd { color: var(--text); }

.form { display: grid; gap: 0.5rem; }
.field { position: relative; }
.field input,
.field textarea {
  width: 100%;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line-2);
  border-radius: 0;
  padding: 1.5rem 0 0.75rem;
  font: inherit;
  font-size: 1.05rem;
  color: var(--text);
  outline: none;
  transition: border-color 0.3s;
  appearance: none;
}
.field textarea { min-height: 7.5rem; resize: vertical; }
.field label {
  position: absolute;
  left: 0; top: 1.45rem;
  font-size: 1.02rem;
  color: var(--dim);
  pointer-events: none;
  transition: transform 0.35s var(--ease-out), color 0.3s, font-size 0.35s;
  transform-origin: left top;
}
.field input:focus,
.field textarea:focus { border-color: var(--accent); }
.field input:focus + label,
.field textarea:focus + label,
.field input:not(:placeholder-shown) + label,
.field textarea:not(:placeholder-shown) + label {
  transform: translateY(-1.25rem);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
.field__bar {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s var(--ease-out);
}
.field input:focus ~ .field__bar,
.field textarea:focus ~ .field__bar { transform: scaleX(1); }

.form__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}
.form__note { font-size: 0.78rem; color: var(--dim); max-width: 30ch; }
.form button:disabled { opacity: 0.55; cursor: progress; }

/* ------------------------------------------------------------
   12  Footer
   ------------------------------------------------------------ */
.footer {
  position: relative;
  padding: clamp(3rem, 6vw, 5rem) 0 2rem;
  border-top: 1px solid var(--line);
  overflow: hidden;
}
.footer__word {
  font-size: clamp(3rem, 13.5vw, 13rem);
  line-height: 0.8;
  letter-spacing: -0.05em;
  font-weight: 600;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(242,238,232,0.14);
  user-select: none;
  pointer-events: none;
  margin-bottom: clamp(2rem, 4vw, 3.5rem);
}
.footer__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
  font-size: 0.82rem;
  color: var(--dim);
}
.footer__row a { color: var(--muted); transition: color 0.3s; }
.footer__row a:hover { color: var(--text); }
.footer__links { display: flex; gap: 1.5rem; }
.to-top {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.to-top svg { width: 14px; height: 14px; }

/* ------------------------------------------------------------
   13  Work page
   ------------------------------------------------------------ */
.page-hero {
  padding: calc(var(--nav-h) + clamp(3.5rem, 8vw, 7rem)) 0 clamp(2rem, 4vw, 3rem);
}
.page-hero__title {
  font-size: clamp(3rem, 9vw, 7.5rem);
  line-height: 0.92;
  letter-spacing: -0.045em;
}
.page-hero__title .count {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 0.42em;
  color: var(--accent-2);
  vertical-align: top;
  margin-left: 0.2em;
  line-height: 1;
  display: inline-block;
  padding-top: 0.3em;
}
.page-hero .lede { margin-top: 1.5rem; }

.filters {
  position: sticky;
  top: var(--nav-h);
  z-index: 50;
  background: rgba(11, 11, 10, 0.78);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin-bottom: clamp(2rem, 4vw, 3rem);
}
.filters__inner {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.8rem 0;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.filters__inner::-webkit-scrollbar { display: none; }
.chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.3s, border-color 0.3s, background 0.3s;
}
.chip small {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--dim);
}
.chip:hover { color: var(--text); border-color: var(--line-2); }
.chip[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.chip[aria-pressed="true"] small { color: rgba(26,18,8,0.7); }

.filters__count {
  margin-left: auto;
  flex: none;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
  padding-left: 1rem;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.25rem, 2.5vw, 2.25rem) clamp(0.9rem, 1.6vw, 1.5rem);
  padding-bottom: var(--section);
}

.card { display: grid; gap: 0.9rem; align-content: start; }
.card.is-hidden { display: none; }
.card .work { aspect-ratio: 16 / 9; }
.card .work__shade { background: linear-gradient(to top, rgba(11,11,10,0.55), transparent 50%); opacity: 0.6; }
.card .work:hover .work__shade { opacity: 1; }
.card__body { display: grid; gap: 0.3rem; padding: 0 0.15rem; }
.card__meta {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.card__meta .year { font-family: var(--font-mono); color: var(--dim); letter-spacing: 0.1em; font-weight: 400; }
.card__meta .rt { margin-left: auto; }
.card__title {
  font-size: 1.08rem;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.card__title button {
  text-align: left;
  transition: color 0.3s;
}
.card__title button:hover { color: var(--accent-2); }
.card__desc {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.55;
}
.card__link {
  margin-top: 0.3rem;
  font-size: 0.78rem;
  color: var(--dim);
  display: inline-flex;
  gap: 0.35rem;
  align-items: center;
  transition: color 0.3s;
}
.card__link:hover { color: var(--text); }

.empty {
  grid-column: 1 / -1;
  padding: 4rem 0;
  text-align: center;
  color: var(--dim);
}

/* View-transition polish for filtering */
::view-transition-old(root),
::view-transition-new(root) { animation-duration: 0.35s; }

/* ------------------------------------------------------------
   14  Thanks page
   ------------------------------------------------------------ */
.thanks {
  min-height: 100svh;
  display: grid;
  align-items: center;
  padding: calc(var(--nav-h) + 3rem) 0 4rem;
}
.thanks__title {
  font-size: clamp(2.6rem, 7vw, 5.5rem);
  letter-spacing: -0.04em;
  line-height: 0.98;
}
.thanks__title em { font-family: var(--font-serif); font-style: italic; font-weight: 400; color: var(--accent-2); }
.thanks .lede { margin: 1.5rem 0 2.5rem; }

/* ------------------------------------------------------------
   15  Modals
   ------------------------------------------------------------ */
.vm {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: clamp(1rem, 4vw, 3rem);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s, visibility 0s 0.35s;
}
.vm.is-open { opacity: 1; visibility: visible; transition: opacity 0.35s; }

.vm__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 5, 4, 0.86);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.vm__dialog {
  position: relative;
  width: min(1120px, 100%);
  transform: translateY(18px) scale(0.985);
  transition: transform 0.55s var(--ease-out);
}
.vm.is-open .vm__dialog { transform: none; }

.vm__frame {
  position: relative;
  aspect-ratio: 16 / 9;
  width: 100%;
  background: #000;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(242,238,232,0.08);
}
.vm__frame iframe {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  border: 0;
}
.vm__frame::before {
  /* loading spinner */
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 36px; height: 36px;
  margin: -18px 0 0 -18px;
  border-radius: 50%;
  border: 2px solid rgba(242,238,232,0.15);
  border-top-color: var(--accent-2);
  animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.vm__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}
.vm__title {
  font-size: 0.95rem;
  color: var(--text);
}
.vm__title > span {
  display: block;
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.2rem;
}
.vm__title .rt { display: inline; margin-left: 0.6rem; text-transform: none; letter-spacing: 0.08em; }
.vm__ext {
  font-size: 0.78rem;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: color 0.3s;
}
.vm__ext:hover { color: var(--text); }
.vm__ext svg { width: 12px; height: 12px; }

.vm__close {
  position: absolute;
  top: -3.25rem;
  right: 0;
  width: 42px; height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(242,238,232,0.2);
  background: rgba(11,11,10,0.7);
  color: var(--text);
  display: grid;
  place-items: center;
  transition: border-color 0.3s, transform 0.4s var(--ease-out);
}
.vm__close svg { width: 16px; height: 16px; }
.vm__close:hover { border-color: var(--accent); transform: rotate(90deg); }

body.modal-open { overflow: hidden; }

/* Form success modal */
.fm {
  position: fixed;
  inset: 0;
  z-index: 1100;
  display: grid;
  place-items: center;
  padding: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s, visibility 0s 0.35s;
}
.fm.is-open { opacity: 1; visibility: visible; transition: opacity 0.35s; }
.fm__backdrop {
  position: absolute; inset: 0;
  background: rgba(5,5,4,0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.fm__dialog {
  position: relative;
  width: min(460px, 100%);
  background: var(--surface);
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  padding: 2.75rem 2.25rem 2.25rem;
  box-shadow: 0 30px 90px rgba(0,0,0,0.6);
  transform: translateY(14px);
  transition: transform 0.5s var(--ease-out);
}
.fm.is-open .fm__dialog { transform: none; }
.fm__dialog h2 {
  font-size: 2rem;
  letter-spacing: -0.03em;
  margin-bottom: 0.6rem;
}
.fm__dialog h2 em { font-family: var(--font-serif); font-style: italic; font-weight: 400; color: var(--accent-2); }
.fm__dialog p { color: var(--muted); }
.fm__close {
  position: absolute;
  top: 1rem; right: 1rem;
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line-2);
  color: var(--muted);
  display: grid; place-items: center;
  transition: color 0.3s, border-color 0.3s;
}
.fm__close svg { width: 14px; height: 14px; }
.fm__close:hover { color: var(--text); border-color: var(--accent); }

/* ------------------------------------------------------------
   17  Responsive
   ------------------------------------------------------------ */
@media (min-width: 1100px) {
  .work--featured { aspect-ratio: 21 / 9; }
}

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

@media (max-width: 860px) {
  :root { --nav-h: 4rem; }
  .nav__links { display: none; }
  .burger { display: grid; }
  .about, .process, .contact__grid { grid-template-columns: 1fr; }
  .process__sticky { position: static; }
  .section-head { flex-direction: column; align-items: flex-start; gap: 1.25rem; }
  .timeline { --clip-w: 170px; }
  .timeline__label { display: none; }
}

@media (max-width: 640px) {
  .hero { min-height: 92svh; padding-top: calc(var(--nav-h) + 2.5rem); }
  .hero__title { font-size: clamp(2.7rem, 13vw, 4.2rem); max-width: none; }
  .hero__eyebrow { font-size: 0.64rem; letter-spacing: 0.14em; }
  .hero__status { display: none; }
  .hero__actions .btn { padding-inline: 1.35rem; }
  .work__desc { display: none; }
  .grid { grid-template-columns: 1fr; }
  .services { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stats .stat:last-child { grid-column: span 2; }
  .vm__close { top: -3rem; }
  .footer__word { font-size: 21vw; white-space: normal; line-height: 0.85; }
  .form__foot { flex-direction: column; align-items: flex-start; }
}

/* ------------------------------------------------------------
   18  Reduced motion
   ------------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  html.js [data-reveal] { opacity: 1; transform: none; }
  html.js .hero__title .line > span { transform: none; animation: none; }
  .hero__frames img { transition: none; }
  .hero__frames img.is-active { transform: none; }
}
