:root {
  --bg: #0b0a09;
  --bg-2: #13110f;
  --wood: #1c1612;
  --ink: #ece6dc;
  --muted: #9a9184;
  --gold: #c9a96e;
  --gold-2: #e6cf9f;
  --line: rgba(201, 169, 110, .22);
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Manrope", system-ui, sans-serif;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --pad: clamp(16px, 5vw, 80px);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: auto; }
body { background: var(--bg); color: var(--ink); font: 300 16px/1.65 var(--sans); overflow-x: hidden; }
body.is-locked { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
em { font-style: italic; font-family: var(--serif); color: var(--gold); }
h2 { font: 300 clamp(40px, 6vw, 84px)/1 var(--serif); letter-spacing: -.01em; }
.kicker { font-size: 11px; letter-spacing: .3em; text-transform: uppercase; color: var(--gold); margin-bottom: 18px; }

/* ---------- Gate ---------- */
.gate { position: fixed; inset: 0; z-index: 100; background: var(--bg); transition: opacity 1.4s var(--ease), visibility 1.4s; }
.gate.is-gone { opacity: 0; visibility: hidden; }
/* Sized so the morphed cone matches the 3D shade: cone = 80% of the box = 16.2% of
   the visible height. --ih is the real visible height (set in index.html), since
   phone browsers count the address bar in vh but not in the 3D canvas. */
.gate__mark { position: absolute; left: 50%; top: 50%; width: calc(var(--ih, 100vh) * .203); height: calc(var(--ih, 100vh) * .203); transform: translate(-50%, -50%); overflow: visible; fill: none; stroke: var(--gold); stroke-width: 1.2; }
.gate__mark * { vector-effect: non-scaling-stroke; }
.gate__draw { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 2.4s var(--ease) forwards; }
#gFrame { animation-delay: .6s; stroke: var(--line); }
.gate__cord { stroke: var(--gold); }
.gate__fill { stroke: none; opacity: 0; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.gate__name, .gate__count { position: absolute; left: 0; right: 0; text-align: center; transition: opacity .8s var(--ease); }
.gate__name { top: calc(50% + var(--ih, 100vh) * .14); font: 300 26px var(--serif); letter-spacing: .04em; }
.gate__count { top: calc(50% + var(--ih, 100vh) * .14 + 48px); font-size: 11px; letter-spacing: .3em; color: var(--muted); }
.gate.is-morphing .gate__name, .gate.is-morphing .gate__count { opacity: 0; }

/* ---------- Scene ---------- */
#scene { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; }
.veil { position: fixed; inset: 0; z-index: 1; opacity: 0; pointer-events: none; }
.veil img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.15); will-change: transform; }
.flash { position: fixed; inset: 0; z-index: 1; opacity: 0; pointer-events: none;
  background: radial-gradient(circle at 50% 50%, #fffdf8 0%, #fff4e0 40%, #f6dfb8 100%); }

/* ---------- Nav ---------- */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 50; display: flex; justify-content: space-between; align-items: center; padding: 22px var(--pad); transition: background .5s, padding .5s; }
.nav::before { content: ""; position: absolute; inset: 0 0 -40px; z-index: -1; background: linear-gradient(rgba(11,10,9,.7), transparent); pointer-events: none; transition: opacity .5s; }
.nav.is-solid::before { opacity: 0; }
.nav.is-solid { background: rgba(11, 10, 9, .82); backdrop-filter: blur(12px); padding-block: 14px; border-bottom: 1px solid var(--line); }
.nav__brand { font: 400 20px var(--serif); letter-spacing: .03em; white-space: nowrap; }
.nav__links { display: flex; gap: 32px; align-items: center; font-size: 12px; letter-spacing: .18em; text-transform: uppercase; }
.nav__links a { opacity: .75; transition: opacity .3s; }
.nav__links a:hover { opacity: 1; }
.nav__cta { border: 1px solid var(--gold); padding: 10px 18px; opacity: 1 !important; color: var(--gold-2); }
@media (max-width: 860px) {
  .nav__links a:not(.nav__cta) { display: none; }
  .nav__brand { font-size: 16px; }
  .nav__cta { padding: 8px 12px; font-size: 10px; }
}

/* ---------- Story ---------- */
.story { position: relative; height: 900vh; z-index: 2; pointer-events: none; }
/* Phones swipe in big flicks: a shorter story, so the plan becomes a building in about one swipe */
@media (max-width: 760px) { .story { height: 500vh; } }
.story__captions { position: sticky; top: 0; height: 100vh; background: linear-gradient(20deg, rgba(11,10,9,.75) 0%, rgba(11,10,9,.25) 38%, transparent 60%); }
.caption { position: absolute; left: var(--pad); bottom: 14vh; max-width: 640px; opacity: 0; transform: translateY(30px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.caption.is-on { opacity: 1; transform: none; }
.is-locked .caption, .is-locked .story__hint { opacity: 0 !important; transform: translateY(30px); }
.caption h1, .caption h2 { font: 300 clamp(44px, 7vw, 104px)/.98 var(--serif); letter-spacing: -.015em; text-shadow: 0 2px 40px rgba(0,0,0,.6); }
.caption p:last-child { margin-top: 20px; color: var(--muted); max-width: 420px; text-shadow: 0 1px 20px #000; }
.story__hint { position: fixed; right: var(--pad); bottom: 40px; display: flex; align-items: center; gap: 14px; font-size: 10px; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); transition: opacity .5s; }
.story__hint i { width: 1px; height: 48px; background: linear-gradient(var(--gold), transparent); animation: hint 2s infinite; transform-origin: top; }
@keyframes hint { 0% { transform: scaleY(0); } 60% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }
.story__desk-tip { position: fixed; top: 96px; left: 50%; transform: translateX(-50%); font-size: 10px; letter-spacing: .3em; text-transform: uppercase; color: var(--gold); opacity: 0; transition: opacity .6s; white-space: nowrap; }
.story__desk-tip.is-on { opacity: .8; }
body.is-hovering-print { cursor: pointer; }

/* ---------- Sections ---------- */
main > section:not(.story) { position: relative; z-index: 3; background: var(--bg); padding: clamp(80px, 12vw, 160px) var(--pad); }
.section-head { margin-bottom: clamp(40px, 6vw, 80px); }
.reveal { opacity: 0; transform: translateY(40px); transition: opacity 1.1s var(--ease), transform 1.1s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- Work: prints on a desk ---------- */
.work { background: radial-gradient(ellipse at 30% 0%, #2a2018 0%, var(--wood) 45%, var(--bg) 100%) !important; }
.work::before { content: ""; position: absolute; inset: 0; opacity: .25; pointer-events: none;
  background: repeating-linear-gradient(92deg, transparent 0 22px, rgba(0,0,0,.25) 22px 23px, transparent 23px 61px); }
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 28px; }
.filters button { padding: 8px 16px; border: 1px solid var(--line); font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); transition: .3s; }
.filters button.is-active, .filters button:hover { border-color: var(--gold); color: var(--gold-2); }
.desk { position: relative; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: clamp(28px, 4vw, 56px); }
.print { position: relative; background: #f3eee6; padding: 12px 12px 46px; box-shadow: 0 30px 50px -20px rgba(0,0,0,.8), 0 2px 4px rgba(0,0,0,.4); transform: rotate(var(--r, 0deg)); transition: transform .7s var(--ease), box-shadow .7s var(--ease), opacity .5s; text-align: left; color: #2a241d; }
.print:hover, .print:focus-visible { transform: rotate(0) translateY(-14px) scale(1.03); box-shadow: 0 50px 70px -20px rgba(0,0,0,.9); z-index: 2; outline: none; }
.print img { aspect-ratio: 4 / 3; width: 100%; object-fit: cover; filter: saturate(.9); transition: filter .6s; }
.print:hover img { filter: saturate(1.05); }
.print__label { position: absolute; left: 14px; right: 14px; bottom: 12px; display: flex; justify-content: space-between; font-size: 10px; letter-spacing: .18em; text-transform: uppercase; }
.print__label b { font: italic 400 17px var(--serif); letter-spacing: 0; text-transform: none; }
.print::after { content: ""; position: absolute; top: -10px; left: 50%; width: 70px; height: 22px; transform: translateX(-50%) rotate(-3deg); background: rgba(230, 207, 159, .55); }
.print.is-hidden { display: none; }

/* ---------- Services ---------- */
.services__list { border-top: 1px solid var(--line); }
.service { display: grid; grid-template-columns: 80px 1fr 1fr; gap: 24px; align-items: center; padding: 36px 0; border-bottom: 1px solid var(--line); position: relative; }
.service__num { font: 300 18px var(--serif); color: var(--gold); }
.service h3 { font: 300 clamp(30px, 4vw, 52px)/1.05 var(--serif); }
.service p { color: var(--muted); max-width: 440px; }
.service__img { position: absolute; right: 8%; top: 50%; width: 280px; aspect-ratio: 4/3; object-fit: cover; opacity: 0; transform: translateY(-50%) scale(.9) rotate(-3deg); transition: .6s var(--ease); pointer-events: none; z-index: 2; box-shadow: 0 30px 60px rgba(0,0,0,.6); }
.service:hover .service__img { opacity: 1; transform: translateY(-50%) scale(1) rotate(2deg); }
.audiences { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 64px; }
.audience { padding: 36px; border: 1px solid var(--line); background: linear-gradient(160deg, rgba(201,169,110,.06), transparent); }
.audience h3 { font: 400 28px var(--serif); margin-bottom: 10px; color: var(--gold-2); }
.audience p { color: var(--muted); }
@media (max-width: 760px) {
  .service { grid-template-columns: 44px 1fr; }
  .service p { grid-column: 2; }
  .service__img { display: none; }
  .audiences { grid-template-columns: 1fr; }
}

/* ---------- Process ---------- */
.process__steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; counter-reset: s; }
.process__steps li { counter-increment: s; padding: 32px 28px 0 0; border-top: 1px solid var(--line); position: relative; }
.process__steps li::before { content: "0" counter(s); display: block; font: 300 64px/1 var(--serif); color: transparent; -webkit-text-stroke: 1px var(--gold); margin-bottom: 24px; }
.process__steps li::after { content: ""; position: absolute; top: -4px; left: 0; width: 7px; height: 7px; background: var(--gold); transform: rotate(45deg); }
.process__steps h3 { font: 400 24px var(--serif); margin-bottom: 8px; }
.process__steps p { color: var(--muted); font-size: 15px; }
@media (max-width: 860px) { .process__steps { grid-template-columns: 1fr 1fr; row-gap: 48px; } }
@media (max-width: 500px) { .process__steps { grid-template-columns: 1fr; } }

/* ---------- About ---------- */
.about { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: center; }
.about__img img { aspect-ratio: 4/5; object-fit: cover; width: 100%; }
.about__text h2 { font-size: clamp(36px, 4.6vw, 64px); margin-bottom: 24px; }
.about__text > p { color: var(--muted); max-width: 520px; }
.clocks { display: grid; grid-template-columns: repeat(5, auto); justify-content: start; gap: 32px; margin-top: 44px; padding-top: 28px; border-top: 1px solid var(--line); }
.clock span { display: block; font-size: 10px; letter-spacing: .25em; text-transform: uppercase; color: var(--muted); }
.clock b { font: 300 30px var(--serif); color: var(--gold-2); }
@media (max-width: 860px) { .about { grid-template-columns: 1fr; } .clocks { grid-template-columns: repeat(3, auto); } }

/* ---------- Contact ---------- */
.contact__lead { color: var(--muted); margin-top: 18px; }
.form { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px 32px; }
.form label { display: flex; flex-direction: column; gap: 8px; font-size: 10px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.form input, .form select, .form textarea { font: 300 17px var(--sans); color: var(--ink); background: transparent; border: 0; border-bottom: 1px solid var(--line); padding: 10px 0; outline: none; transition: border-color .3s; width: 100%; color-scheme: dark; }
.form select option { background: var(--bg-2); }
.form input:focus, .form select:focus, .form textarea:focus { border-color: var(--gold); }
.form__unit { display: flex; gap: 12px; }
.form__unit select { width: 90px; }
.form__wide { grid-column: 1 / -1; }
.btn { grid-column: 1 / -1; justify-self: start; padding: 18px 44px; background: var(--gold); color: var(--bg); font-size: 12px; letter-spacing: .3em; text-transform: uppercase; font-weight: 500; transition: background .3s; }
.btn:hover { background: var(--gold-2); }
.form__status { grid-column: 1 / -1; color: var(--gold-2); min-height: 1.5em; }
.contact__direct { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 64px; padding-top: 32px; border-top: 1px solid var(--line); font-size: 13px; letter-spacing: .15em; text-transform: uppercase; }
.contact__direct a { color: var(--muted); transition: color .3s; }
.contact__direct a:hover { color: var(--gold-2); }
@media (max-width: 860px) { .form { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .form { grid-template-columns: 1fr; } }

.footer { position: relative; z-index: 3; background: var(--bg); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 28px var(--pad); border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); letter-spacing: .1em; }

/* ---------- Case study ---------- */
.case { position: fixed; inset: 0; z-index: 80; background: rgba(8, 7, 6, .97); display: grid; grid-template-columns: 1fr 380px; opacity: 0; visibility: hidden; transition: opacity .6s var(--ease), visibility .6s; }
.case.is-open { opacity: 1; visibility: visible; }
.case__stage { display: grid; place-items: center; padding: 72px 24px 24px; overflow: hidden; }
.case__stage img { max-height: calc(100vh - 100px); object-fit: contain; transition: opacity .4s; }
.case__info { padding: 96px 40px 40px 8px; display: flex; flex-direction: column; overflow-y: auto; }
.case__info h3 { font: 300 44px/1.05 var(--serif); margin-bottom: 18px; }
.case__info > p:not(.kicker) { color: var(--muted); }
.case__thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 32px; }
.case__thumbs button { opacity: .45; transition: opacity .3s; outline-offset: 2px; }
.case__thumbs button.is-active, .case__thumbs button:hover { opacity: 1; }
.case__thumbs img { aspect-ratio: 4/3; object-fit: cover; width: 100%; }
.case__nav { display: flex; align-items: center; gap: 20px; margin-top: 28px; font-size: 12px; letter-spacing: .2em; color: var(--muted); }
.case__nav button { width: 48px; height: 48px; border: 1px solid var(--line); font-size: 18px; transition: border-color .3s; }
.case__nav button:hover { border-color: var(--gold); }
.case__close { position: absolute; top: 18px; right: 24px; font-size: 40px; font-weight: 200; z-index: 2; width: 48px; height: 48px; }
@media (max-width: 900px) {
  .case { grid-template-columns: 1fr; grid-template-rows: auto 1fr; overflow-y: auto; }
  .case__stage { padding: 72px 16px 0; }
  .case__stage img { max-height: 60vh; }
  .case__info { padding: 24px 16px 40px; }
  .case__info h3 { font-size: 34px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
