/* Trifocal Media — site styles (redesign, 2026) */

:root {
  --paper: #f2efe9;
  --paper-2: #e9e5dd;
  --ink: #161412;
  --muted: #5c5750;
  --line: rgba(22, 20, 18, .14);
  --night: #0f0e0d;
  --night-2: #1a1816;
  --night-ink: #f4f1ec;
  --night-muted: #a59f96;
  --night-line: rgba(244, 241, 236, .14);
  --rec: #c8361d;          /* tally-light red: the one accent */
  --rec-hi: #ff5a3c;

  --gut: 80px;
  --nav: 72px;
  --padt: 120px;
  --padb: 120px;
  --r: 10px;

  --f-display: "Archivo", system-ui, sans-serif;
  --f-text: "Archivo", system-ui, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, monospace;

  --t-h1: clamp(40px, 5.6vw, 84px);
  --t-h2: clamp(32px, 3.6vw, 54px);
  --t-h3: clamp(22px, 1.7vw, 28px);
  --t-lead: clamp(18px, 1.35vw, 21px);

  --ease: cubic-bezier(.2, .7, .2, 1);
}
@media (max-width: 1023px) { :root { --gut: 48px; --padt: 104px; --padb: 104px; } }
@media (max-width: 639px)  { :root { --gut: 20px; --nav: 60px; --padt: 80px; --padb: 80px; } }

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: var(--nav); }
body {
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.6 var(--f-text);
  font-variation-settings: "wdth" 100;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, video { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--rec); color: #fff; }
:focus-visible { outline: 2px solid var(--rec-hi); outline-offset: 3px; border-radius: 4px; }

.wrap { width: min(100% - 2 * var(--gut), 1280px); margin-inline: auto; position: relative; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: var(--gut); top: -100px; z-index: 30; background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 6px; text-decoration: none; }
.skip-link:focus { top: 12px; }

/* ---------- type ---------- */
h1, h2, h3 { font-family: var(--f-display); font-weight: 500; margin: 0; letter-spacing: -.02em; line-height: 1.04; hyphens: manual; }
h1 { font-size: var(--t-h1); font-variation-settings: "wdth" 112; letter-spacing: -.035em; line-height: .98; }
h2 { font-size: var(--t-h2); font-variation-settings: "wdth" 108; letter-spacing: -.03em; max-width: 20ch; }
h3 { font-size: var(--t-h3); font-variation-settings: "wdth" 104; letter-spacing: -.015em; line-height: 1.15; }
h2 .muted { color: var(--muted); }
.ground-night h2 .muted { color: var(--night-muted); }
p { margin: 0; }
.lead { font-size: var(--t-lead); line-height: 1.55; max-width: 46ch; }
.mono, .tag { font-family: var(--f-mono); font-size: 13px; letter-spacing: 0; font-weight: 500; }
.tag { color: var(--muted); display: inline-flex; align-items: center; gap: 8px; }
.ground-night .tag { color: var(--night-muted); }
.head { display: grid; gap: 20px; margin-bottom: 56px; }
.head .lead { color: var(--muted); }
.ground-night .head .lead { color: var(--night-muted); }
@media (max-width: 639px) { .head { margin-bottom: 36px; } }

/* ---------- buttons and links ---------- */
.btn {
  --h: 50px;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: var(--h); padding: 0 24px; border-radius: 999px;
  font: 500 16px/1 var(--f-text); text-decoration: none; white-space: nowrap;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .18s var(--ease), background-color .18s, border-color .18s, color .18s;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(1px) scale(.98); }
.btn--rec { background: var(--rec); color: #fff; }
.btn--rec:hover { background: #b02e17; }
.btn--rec .dot { width: 8px; height: 8px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 3px rgba(255,255,255,.25); }
.btn--line { border-color: currentColor; background: transparent; }
.btn--line:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.on-dark .btn--line:hover, .ground-night .btn--line:hover { background: var(--night-ink); color: var(--night); border-color: var(--night-ink); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
@media (max-width: 639px) { .btn-row .btn { flex: 1 1 100%; } }

.link {
  text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size .3s var(--ease); padding-bottom: 2px;
}
.link:hover { background-size: 100% 1px; }
.arrow { display: inline-block; transition: transform .25s var(--ease); }
a:hover .arrow, button:hover .arrow { transform: translateX(4px); }

/* ---------- nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 20; height: var(--nav);
  background: rgba(242, 239, 233, .96); border-bottom: 1px solid var(--line);
  transition: background-color .3s, border-color .3s, color .3s;
}
.nav .wrap { height: 100%; display: flex; align-items: center; gap: 32px; }
.nav.is-over { background: transparent; border-color: transparent; color: var(--night-ink); }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 500 18px/1 var(--f-display); font-variation-settings: "wdth" 110; letter-spacing: -.01em; }
.logo svg { width: 34px; height: auto; fill: currentColor; }
.nav__links { display: flex; gap: 28px; margin-left: auto; }
.nav__links a { font-size: 15px; font-weight: 500; text-decoration: none; position: relative; padding: 6px 0; }
.nav__links a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease); }
.nav__links a:hover::after, .nav__links a[aria-current="page"]::after { transform: scaleX(1); }
.nav .btn { --h: 42px; padding: 0 18px; font-size: 15px; }
.nav__toggle { display: none; width: 44px; height: 44px; border-radius: 999px; border: 1px solid currentColor; background: none; cursor: pointer; align-items: center; justify-content: center; }
.nav__toggle span { display: block; width: 16px; height: 1.5px; background: currentColor; box-shadow: 0 5px 0 currentColor; transform: translateY(-2.5px); }
@media (max-width: 899px) {
  .nav__links { display: none; }
  .nav__toggle { display: inline-flex; margin-left: auto; }
  .nav .btn { order: 2; }
}
@media (max-width: 479px) { .nav .btn { display: none; } }

.sheet {
  position: fixed; inset: 0; z-index: 40; background: var(--night); color: var(--night-ink);
  display: flex; flex-direction: column; padding: 0 var(--gut) 32px;
  opacity: 0; visibility: hidden; transition: opacity .25s, visibility 0s .25s;
}
.sheet.is-open { opacity: 1; visibility: visible; transition: opacity .25s; }
.sheet__top { height: var(--nav); display: flex; align-items: center; justify-content: space-between; }
.sheet__close { width: 44px; height: 44px; border-radius: 999px; border: 1px solid currentColor; background: none; cursor: pointer; font-size: 20px; line-height: 1; }
.sheet nav { display: grid; margin-top: 24px; }
.sheet nav a { font: 500 34px/1 var(--f-display); font-variation-settings: "wdth" 110; letter-spacing: -.02em; text-decoration: none; padding: 14px 0; border-bottom: 1px solid var(--night-line); }
.sheet .btn { margin-top: auto; }

/* ---------- sections ---------- */
.section { padding: var(--padt) 0 var(--padb); position: relative; }
.ground-night { background: var(--night); color: var(--night-ink); }
.ground-alt { background: var(--paper-2); }

/* ---------- hero (reel) ---------- */
.hero { position: relative; height: 100svh; min-height: 560px; overflow: hidden; background: var(--night); color: var(--night-ink); }
.hero__film, .hero__film video, .hero__film img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero__film .tall { display: none; }
@media (max-aspect-ratio: 4/5) { .hero__film .wide { display: none; } .hero__film .tall { display: block; } }
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(120% 80% at 0% 100%, rgba(10,9,8,.78) 0%, rgba(10,9,8,.45) 45%, rgba(10,9,8,0) 75%),
    linear-gradient(180deg, rgba(10,9,8,.55) 0%, rgba(10,9,8,0) 20%, rgba(10,9,8,0) 45%, rgba(10,9,8,.7) 100%);
}
.hero__body { position: relative; z-index: 2; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; padding-bottom: 56px; }
.hero h1, .hero .lead { text-shadow: 0 1px 24px rgba(10,9,8,.35); }
.hero h1 { max-width: 13ch; }
.hero .lead { margin-top: 24px; color: rgba(244, 241, 236, .86); }
.hero .btn-row { margin-top: 32px; }
.hero .btn--line { color: var(--night-ink); }
.hud { position: absolute; z-index: 2; left: 0; right: 0; top: calc(var(--nav) + 20px); }
.hud .wrap { display: flex; justify-content: flex-end; align-items: center; }
.hud .mono { color: rgba(244,241,236,.85); display: inline-flex; align-items: center; gap: 10px; }
.rec { width: 9px; height: 9px; border-radius: 50%; background: var(--rec-hi); animation: rec 1.6s steps(1) infinite; }
@keyframes rec { 50% { opacity: .25; } }
.hero__foot { position: absolute; z-index: 2; right: 0; left: 0; bottom: 56px; pointer-events: none; }
.hero__foot .wrap { display: flex; justify-content: flex-end; align-items: center; gap: 14px; }
.now { color: rgba(244,241,236,.8); text-align: right; transition: opacity .3s; }
.pause { pointer-events: auto; width: 44px; height: 44px; border-radius: 999px; border: 1px solid rgba(244,241,236,.6); background: rgba(10,9,8,.3); color: var(--night-ink); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.pause svg { width: 14px; height: 14px; fill: currentColor; }
@media (max-width: 899px) {
  .hero__foot { bottom: auto; top: calc(var(--nav) + 12px); }
  .hud .now-wrap { display: none; }
  .hero__foot .now { display: none; }
  .hud .wrap { justify-content: flex-start; }
  .hero__body { padding-bottom: 40px; }
}

/* entrance: once, on load */
.enter > * { opacity: 0; transform: translateY(18px); animation: enter .9s var(--ease) forwards; }
.enter > *:nth-child(2) { animation-delay: .12s; }
.enter > *:nth-child(3) { animation-delay: .24s; }
.enter > *:nth-child(4) { animation-delay: .36s; }
@keyframes enter { to { opacity: 1; transform: none; } }

/* ---------- films ---------- */
.films { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; }
.film { grid-column: span 6; display: grid; gap: 14px; align-content: start; }
.film--tall { grid-column: span 3; }
.film__frame {
  position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--r);
  background: var(--night-2); border: 0; padding: 0; width: 100%; cursor: pointer; display: block;
}
.film--tall .film__frame { aspect-ratio: 9 / 16; }
.film__frame img, .film__frame video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease), opacity .35s; }
.film__frame .preview { opacity: 0; }
.film__frame.is-previewing .preview { opacity: 1; }
.film__frame:hover img, .film__frame:hover .preview { transform: scale(1.03); }
.film__frame .full { position: relative; z-index: 2; background: #000; object-fit: contain; }
.film__play {
  position: absolute; z-index: 1; left: 16px; bottom: 16px; display: inline-flex; align-items: center; gap: 8px;
  height: 36px; padding: 0 14px 0 12px; border-radius: 999px; background: rgba(15,14,13,.72); color: #fff;
  font: 500 14px/1 var(--f-text); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  transition: background-color .2s;
}
.film__play svg { width: 12px; height: 12px; fill: currentColor; }
.film__frame:hover .film__play { background: var(--rec); }
.film__frame.is-playing .film__play { display: none; }
.film__meta { display: flex; justify-content: space-between; gap: 16px; align-items: baseline; }
.film__meta strong { font-weight: 500; font-size: 17px; }
.film__meta .mono { color: var(--muted); white-space: nowrap; }
.ground-night .film__meta .mono { color: var(--night-muted); }
.film__meta span.what { display: block; color: var(--muted); font-size: 15px; }
.ground-night .film__meta span.what { color: var(--night-muted); }
.films + .more { margin-top: 48px; }
@media (max-width: 1023px) {
  .film { grid-column: span 12; }
  .film--tall { grid-column: span 6; }
}
@media (max-width: 639px) {
  .films { gap: 28px 12px; }
  .film--tall { grid-column: span 6; }
  .film__meta { display: block; }
  .film__meta .mono { display: block; margin-top: 4px; }
  .film__meta strong { font-size: 16px; }
}

/* ---------- clients (type moment) ---------- */
.clients { font: 500 clamp(30px, 4.2vw, 64px)/1.12 var(--f-display); font-variation-settings: "wdth" 104; letter-spacing: -.03em; margin: 0; padding: 0; list-style: none; }
.clients li { display: inline; }
.clients li + li::before { content: " / "; color: var(--line); color: rgba(22,20,18,.22); }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .clients li span { animation: lightup linear both; animation-timeline: view(); animation-range: entry 40% cover 45%; }
    @keyframes lightup { from { color: rgba(22,20,18,.24); } to { color: var(--ink); } }
  }
}
.clients-note { margin-top: 48px; color: var(--muted); max-width: 52ch; }

/* ---------- services ---------- */
.tracks { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.track { border-top: 2px solid var(--ink); padding-top: 20px; display: grid; align-content: start; gap: 8px; }
.track header { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 18px; }
.track h3 { font-size: clamp(28px, 2.4vw, 36px); }
.svc { display: grid; gap: 6px; padding: 20px 0 22px; border-bottom: 1px solid var(--line); text-decoration: none; }
.svc strong { font: 500 20px/1.25 var(--f-display); font-variation-settings: "wdth" 104; display: flex; justify-content: space-between; gap: 12px; }
.svc span { color: var(--muted); font-size: 16px; line-height: 1.55; }
.svc:hover strong { color: var(--rec); }
@media (max-width: 899px) { .tracks { grid-template-columns: 1fr; gap: 48px; } }

/* ---------- process timeline ---------- */
.timeline { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-top: 8px; }
.ruler { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, 1fr); height: 28px; margin-bottom: 14px;
  background: repeating-linear-gradient(90deg, var(--line) 0 1px, transparent 1px 32px) 0 100% / 100% 8px no-repeat; border-bottom: 1px solid var(--line); }
.ruler span { font: 500 12px/1 var(--f-mono); color: var(--muted); }
.clip { height: 44px; border-radius: 6px; margin-right: 4px; display: flex; align-items: center; padding: 0 14px; font: 500 14px/1 var(--f-mono); color: #fff; overflow: hidden; }
.clip--1 { background: #3f5d7a; }
.clip--2 { background: #4f6b4a; }
.clip--3 { background: var(--rec); }
.clip--4 { background: #8a6a2c; }
.step { padding: 22px 24px 0 0; }
.step h3 { font-size: 22px; margin-bottom: 10px; }
.step p { color: var(--muted); font-size: 16px; line-height: 1.6; }
@media (max-width: 899px) {
  .timeline { grid-template-columns: 1fr 1fr; row-gap: 32px; }
  .ruler { display: none; }
  .timeline > .step-col { display: grid; }
}
@media (max-width: 539px) { .timeline { grid-template-columns: 1fr; } }

.stills { display: grid; grid-template-columns: repeat(12, 1fr); gap: 12px; margin-top: 72px; }
.stills figure { margin: 0; overflow: hidden; border-radius: var(--r); background: var(--paper-2); }
.stills img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.stills figure:hover img { transform: scale(1.03); }
.stills .s-a { grid-column: span 5; aspect-ratio: 4 / 5; }
.stills .s-b { grid-column: span 7; aspect-ratio: 7 / 5; }
.stills .s-c { grid-column: span 4; aspect-ratio: 4 / 3; }
.stills .s-d { grid-column: span 4; aspect-ratio: 4 / 3; }
.stills .s-e { grid-column: span 4; aspect-ratio: 4 / 3; }
.stills .s-a, .stills .s-b { aspect-ratio: auto; height: clamp(320px, 40vw, 580px); }
@media (max-width: 639px) {
  .stills { gap: 8px; margin-top: 48px; }
  .stills .s-a, .stills .s-b { grid-column: span 12; aspect-ratio: 4 / 3; height: auto; }
  .stills .s-c, .stills .s-d { grid-column: span 6; aspect-ratio: 1; }
  .stills .s-e { display: none; }
}

/* ---------- about split ---------- */
.split { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; align-items: start; }
.split__text { grid-column: 1 / span 6; display: grid; gap: 24px; }
.split__text p { max-width: 50ch; }
.split__text .big { font: 500 clamp(24px, 2.2vw, 32px)/1.25 var(--f-display); font-variation-settings: "wdth" 104; letter-spacing: -.015em; }
.split__pic { grid-column: 8 / span 5; margin: 0; border-radius: var(--r); overflow: hidden; aspect-ratio: 4 / 5; }
.split__pic img { width: 100%; height: 100%; object-fit: cover; }
.facts { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: 40px; margin-top: 16px; padding-top: 24px; border-top: 1px solid var(--line); }
.facts dt { font: 500 13px/1 var(--f-mono); color: var(--muted); margin-bottom: 8px; }
.facts dd { margin: 0; font: 500 22px/1.2 var(--f-display); font-variation-settings: "wdth" 104; }
@media (max-width: 899px) {
  .split__text, .split__pic { grid-column: 1 / -1; }
  .split__pic { aspect-ratio: 4 / 3; }
}
@media (max-width: 479px) { .facts { grid-template-columns: 1fr 1fr; gap: 24px; } }

/* ---------- page hero (inner pages) ---------- */
.page-hero { padding: calc(var(--nav) + 96px) 0 80px; }
.page-hero h1 { max-width: 15ch; }
.page-hero .lead { margin-top: 24px; color: var(--muted); }
.page-hero .btn-row { margin-top: 36px; }
.page-hero .tag { margin-bottom: 24px; }
.page-pic { margin: 0; border-radius: var(--r); overflow: hidden; aspect-ratio: 21 / 9; background: var(--paper-2); }
.page-pic img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 639px) { .page-hero { padding: calc(var(--nav) + 56px) 0 56px; } .page-pic { aspect-ratio: 4 / 3; } }

.steps { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 64px; counter-reset: s; }
.steps li { list-style: none; border-top: 1px solid var(--line); padding: 28px 0 40px; display: grid; grid-template-columns: 64px 1fr; gap: 0 16px; }
.steps li::before { counter-increment: s; content: "0" counter(s); font: 500 13px/1.9 var(--f-mono); color: var(--rec); }
.steps h3 { font-size: 24px; margin-bottom: 10px; }
.steps p { color: var(--muted); }
.steps { padding: 0; margin: 0; }
@media (max-width: 899px) { .steps { grid-template-columns: 1fr; } .steps li { grid-template-columns: 48px 1fr; } }

/* ---------- forms ---------- */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 24px; max-width: 760px; }
.field { display: grid; gap: 8px; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: 14px; font-weight: 500; }
.field input, .field select, .field textarea {
  font: 400 16px/1.4 var(--f-text); color: var(--ink); background: #fbfaf7; border: 1px solid rgba(22,20,18,.22); border-radius: 8px; padding: 13px 14px; min-height: 50px; width: 100%;
}
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--rec); outline-offset: 1px; border-color: transparent; }
.checks { display: flex; flex-wrap: wrap; gap: 10px; }
.checks label { display: inline-flex; align-items: center; gap: 8px; border: 1px solid rgba(22,20,18,.22); border-radius: 999px; padding: 10px 16px; font-weight: 400; cursor: pointer; min-height: 44px; }
.checks input { accent-color: var(--rec); width: 16px; height: 16px; min-height: 0; }
.form .btn { justify-self: start; }
.form__note { grid-column: 1 / -1; color: var(--muted); font-size: 15px; }
@media (max-width: 639px) { .form { grid-template-columns: 1fr; } .form .btn { justify-self: stretch; } }

.booking { background: #fff; border-radius: var(--r); min-height: 640px; padding: 8px; }

/* ---------- footer / close ---------- */
.closing { background: var(--night); color: var(--night-ink); padding: var(--padt) 0 40px; }
.closing__cta { display: grid; gap: 28px; padding-bottom: 96px; border-bottom: 1px solid var(--night-line); }
.closing__cta h2 { font-size: clamp(44px, 7.4vw, 116px); font-variation-settings: "wdth" 112; letter-spacing: -.04em; line-height: .95; max-width: 13ch; }
.closing__cta p { color: var(--night-muted); max-width: 44ch; font-size: var(--t-lead); }
.closing__cols { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 24px; padding: 48px 0; }
.closing__cols h3 { font: 500 13px/1 var(--f-mono); color: var(--night-muted); letter-spacing: 0; margin-bottom: 18px; }
.closing__cols ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.closing__cols a { text-decoration: none; }
.closing__cols .contact a { font: 500 22px/1.3 var(--f-display); font-variation-settings: "wdth" 104; }
.closing__legal { display: flex; justify-content: space-between; gap: 16px; padding-top: 24px; border-top: 1px solid var(--night-line); color: var(--night-muted); font-size: 14px; }
@media (max-width: 899px) { .closing__cols { grid-template-columns: 1fr 1fr; gap: 40px 24px; } .closing__cols .contact { grid-column: 1 / -1; } }
@media (max-width: 479px) { .closing__legal { flex-direction: column; } }

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .enter > * { opacity: 1; transform: none; }
  .rec { animation: none; }
}
