/* ==========================================================================
   Apostrophy 2026
   ========================================================================== */

:root {
  --bg: #0b0b0b;
  --ink: #ffffff;
  --muted: #8b8b8b;
  --line: rgba(255, 255, 255, 0.18);
  --blue: #1340f1;
  --blue-bright: #0062ff;
  --paper: #ffffff;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);
  --display: "Zalando Sans Expanded", "Archivo", "Helvetica Neue", Arial, sans-serif;
  --text: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;
  --gutter: clamp(16px, 3.33vw, 48px);
}

*, *::before, *::after { box-sizing: border-box; }

html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

html, body { margin: 0; padding: 0; }
html { background: var(--bg); } /* Safari 26 tints its toolbars from this, not from theme-color */
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
::selection { background: var(--blue); color: #fff; }

.display { font-family: var(--display); font-weight: 300; text-transform: uppercase; letter-spacing: -0.01em; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 24px;
  font-family: var(--display); font-size: 10px; letter-spacing: 0.02em; text-transform: uppercase;
}
.eyebrow::before {
  content: ""; width: 12px; height: 12px; border-radius: 50%; background: var(--blue);
  box-shadow: 0 0 0 0 rgba(19, 64, 241, 0.6);
  animation: pulse 2.4s var(--ease-out) infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(19, 64, 241, 0.55); }
  70% { box-shadow: 0 0 0 12px rgba(19, 64, 241, 0); }
  100% { box-shadow: 0 0 0 0 rgba(19, 64, 241, 0); }
}

/* ---------- Grain / page chrome ---------- */
.grain {
  position: fixed; inset: -50%; z-index: 90; pointer-events: none; opacity: 0.05;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  animation: grain 1.2s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); } 20% { transform: translate(-3%, 2%); } 40% { transform: translate(2%, -3%); }
  60% { transform: translate(-2%, -1%); } 80% { transform: translate(3%, 3%); } 100% { transform: translate(0, 0); }
}

/* Subtle dotted grid like the Figma background */
.dotgrid {
  background-image: radial-gradient(rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* ---------- Cursor ---------- */
.cursor {
  position: fixed; left: 0; top: 0; z-index: 200; pointer-events: none;
  width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%;
  background: #fff; mix-blend-mode: difference;
  transition: width .45s var(--ease-out), height .45s var(--ease-out), margin .45s var(--ease-out), background .3s;
}
.cursor-label {
  position: fixed; left: 0; top: 0; z-index: 201; pointer-events: none;
  width: 96px; height: 96px; margin: -48px 0 0 -48px; border-radius: 50%;
  display: grid; place-items: center; text-align: center;
  background: var(--blue); color: #fff;
  font-family: var(--display); font-size: 10px; letter-spacing: .04em; text-transform: uppercase;
  transform: scale(0); transition: transform .5s var(--ease-out);
}
.cursor-label.is-on { transform: scale(1); }
.cursor-label.is-muted { background: #4a4a4a; } /* not clickable yet, e.g. "Coming soon" on Work */
body.cursor-hover .cursor { width: 44px; height: 44px; margin: -22px 0 0 -22px; }
body.cursor-hidden .cursor { width: 0; height: 0; margin: 0; }
@media (hover: none) { .cursor, .cursor-label { display: none; } }

/* ---------- Nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 60;
  display: flex; justify-content: space-between; align-items: flex-start;
  padding: var(--gutter);
  pointer-events: none;
  transition: transform .7s var(--ease-out);
}
.nav > * { pointer-events: auto; }

.pill {
  position: relative; width: 320px; border-radius: 24px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.10);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  overflow: hidden;
  transition: width .6s var(--ease-out), background .4s, border-color .4s, box-shadow .5s var(--ease-out), opacity .4s, transform .6s var(--ease-out);
}
.pill:hover { border-color: rgba(255,255,255,.28); box-shadow: 0 10px 40px rgba(19,64,241,.18); }
body.on-light .pill { background: rgba(0,0,0,0.05); border-color: rgba(0,0,0,.08); color: #111; }
.pill-row { display: flex; align-items: center; justify-content: space-between; padding: 12px 24px 12px 32px; }
.burger { width: 32px; height: 32px; position: relative; }
.burger span { position: absolute; left: 3px; right: 3px; height: 1px; background: var(--muted); transition: transform .5s var(--ease-out), top .5s var(--ease-out); }
.burger span:nth-child(1) { top: 12px; } .burger span:nth-child(2) { top: 20px; }
.pill.menu-open .burger span:nth-child(1) { top: 16px; transform: rotate(45deg); }
.pill.menu-open .burger span:nth-child(2) { top: 16px; transform: rotate(-45deg); }
.pill-links {
  display: grid; grid-template-rows: 0fr; transition: grid-template-rows .6s var(--ease-out);
}
.pill.menu-open .pill-links { grid-template-rows: 1fr; }
.pill-links > div { overflow: hidden; }
.pill-links ul { list-style: none; margin: 0; padding: 0 24px 18px 24px; display: flex; flex-wrap: wrap; gap: 6px; }
.pill-links a {
  display: inline-block; padding: 10px 16px; border-radius: 999px; font-size: 13px;
  background: rgba(255,255,255,.06); transition: background .3s, color .3s;
}
.pill-links a:hover, .pill-links a.is-active { background: var(--blue); color: #fff; }
/* Desktop: the open menu widens so every link sits on one row; phones keep the wrap */
@media (min-width: 901px) {
  .pill.menu-open { width: 572px; }
  .pill-links ul { flex-wrap: nowrap; }
  .pill-links a { white-space: nowrap; }
}

/* Fixed side furniture */
.side-label {
  position: fixed; left: var(--gutter); top: 50%; z-index: 40;
  font-size: 12px; text-transform: uppercase; letter-spacing: .02em;
  transform: translateY(-50%) rotate(-90deg); transform-origin: left center; translate: 6px 0;
  mix-blend-mode: difference;
}
.side-cta {
  position: fixed; left: var(--gutter); bottom: var(--gutter); z-index: 40;
  font-family: var(--display); font-size: 12px; text-transform: uppercase;
  display: inline-flex; flex-direction: column; gap: 4px; mix-blend-mode: difference;
}
.side-cta .tail { display: flex; align-items: center; }
.side-cta .tail i { height: 1px; background: currentColor; width: 94px; transform-origin: left; transition: width .6s var(--ease-out); }
.side-cta .tail b { width: 8px; height: 8px; border-radius: 50%; border: 1px solid currentColor; }
.side-cta:hover .tail i { width: 130px; }

.anchors {
  position: fixed; right: var(--gutter); top: 50%; transform: translateY(-50%); z-index: 40;
  display: flex; flex-direction: column; gap: 20px; mix-blend-mode: difference;
}
.anchors button { width: 10px; height: 10px; border-radius: 50%; position: relative; }
.anchors button::before { content: ""; position: absolute; inset: 2px; border-radius: 50%; background: rgba(255,255,255,.4); transition: transform .5s var(--ease-out), background .3s; }
.anchors button.is-active::before { background: #fff; transform: scale(1.7); }
.anchors button span {
  position: absolute; right: 22px; top: 50%; transform: translate(8px, -50%); opacity: 0; white-space: nowrap;
  font-family: var(--display); font-size: 10px; text-transform: uppercase; transition: .4s var(--ease-out);
}
.anchors button:hover span { opacity: 1; transform: translate(0, -50%); }

/* ---------- Buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; gap: 10px;
  padding: 16px 24px; border-radius: 999px; background: var(--blue); color: #fff;
  font-family: var(--display); font-size: 12px; line-height: 14px; text-transform: uppercase; letter-spacing: -0.01em;
  overflow: hidden; isolation: isolate; will-change: transform;
}
.btn::after {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: #fff;
  transform: translateY(101%); transition: transform .6s var(--ease-out);
}
.btn:hover::after { transform: translateY(0); }
.btn:hover { color: var(--blue); }
.btn .tail { display: flex; align-items: center; width: 32px; }
.btn .tail i { height: 1px; flex: 1; background: currentColor; transform-origin: left; transition: transform .6s var(--ease-out); }
.btn .tail b { width: 8px; height: 8px; border-radius: 50%; border: 1px solid currentColor; flex: none; }
.btn:hover .tail i { transform: scaleX(1.5); }
.btn .label { position: relative; overflow: hidden; display: inline-block; }
.btn .label span { display: block; transition: transform .6s var(--ease-out); }
.btn .label span + span { position: absolute; inset: 0; transform: translateY(110%); }
.btn:hover .label span:first-child { transform: translateY(-110%); }
.btn:hover .label span + span { transform: translateY(0); }

/* ---------- Text reveal helpers ---------- */
.w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.wi { display: inline-block; will-change: transform; }
.line-mask { display: block; overflow: hidden; }
.line-mask > span { display: inline-block; will-change: transform; }

/* ---------- Background pattern + dots ---------- */
.bg-layer { position: absolute; pointer-events: none; z-index: 0; }
.pattern { left: 50%; width: 1500px; max-width: none; margin-left: -750px; opacity: .9; }
.dots { right: 24px; top: 24px; width: 514px; max-width: 60vw; }

/* ---------- Sections ---------- */
main { position: relative; }
section { position: relative; }
.wrap { position: relative; z-index: 1; padding: 0 var(--gutter); }

/* Hero */
.hero {
  min-height: 100vh; min-height: 100svh; padding-top: clamp(120px, 14vw, 212px); padding-bottom: 140px; overflow: hidden;
}
.hero-title {
  position: relative; z-index: 2; margin: 0; text-align: center;
  font-size: clamp(38px, 6.94vw, 100px); line-height: 1; font-weight: 300; letter-spacing: -0.01em;
}
.hero-title .row { display: block; white-space: nowrap; }
.hero-title .row > .line-mask { display: inline-block; vertical-align: top; }
.hero-title .blue { color: var(--blue); }
.hero-title .r1 { transform: translateX(-13.7vw); }
.hero-title .r2 { transform: translateX(11.35vw); }
.hero-title .r3 { transform: translateX(-13.7vw); }
.hero-title .r4 { transform: translateX(5.5vw); }
.hero-title .r5 { transform: translateX(-6.94vw); }
.hero-title .r6 { transform: translateX(6.35vw); }
.hero-title .glyph { display: inline-block; height: .95em; width: auto; vertical-align: -0.08em; margin-right: .1em; }
.hero-title .star { animation: spin 18s linear infinite; }
/* Sits outside the line mask so it is never clipped, overlapping the end of "HUMAN" */
.hero-title .hero-cat { position: relative; z-index: 3; display: inline-block; margin: -0.22em 0 -0.13em -0.32em; vertical-align: -0.24em; pointer-events: none; } /* GSAP moves this; negative margins keep the row height */
.hero-title .hero-cat img { display: block; height: 1.35em; width: auto; animation: float 5s ease-in-out infinite; } /* CSS floats this */
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes float { 0%, 100% { transform: translateY(0) rotate(-3deg); } 50% { transform: translateY(-10px) rotate(3deg); } }
.scroll-hint {
  position: absolute; left: 50%; bottom: 36px; transform: translateX(-50%); z-index: 2;
  width: 1px; height: 64px; background: rgba(255,255,255,.15); overflow: hidden;
}
.scroll-hint::after { content: ""; position: absolute; left: 0; top: -40%; width: 1px; height: 40%; background: #fff; animation: drip 2.2s var(--ease-in-out) infinite; }
@keyframes drip { to { top: 100%; } }

/* Proposition */
.prop { padding: 200px 0; }
.prop .wrap { max-width: 1440px; margin: 0 auto; padding: 0 clamp(16px, 11.1vw, 160px); }
.prop-copy { max-width: 1004px; }
.prop h2 {
  margin: 58px 0 16px; font-family: var(--display); font-weight: 300;
  font-size: clamp(28px, 3.65vw, 52.6px); line-height: 1.24; letter-spacing: -0.01em;
}
.prop p.sub { max-width: 663px; margin: 0 0 48px; color: var(--muted); font-size: 16px; line-height: 1.2; }
.prop-foot { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.big-arrow { width: 64px; height: 64px; transition: transform .8s var(--ease-out); }
.big-arrow:hover { transform: translate(8px, -8px) rotate(8deg); }

/* Carousel */
.carousel-sec { padding: 150px 0; }
.carousel-sec h2 {
  margin: 0 0 60px; padding-left: calc(94px + 20px + var(--gutter));
  font-family: var(--display); font-weight: 300; font-size: clamp(28px, 3.65vw, 52.6px); line-height: 1; letter-spacing: -0.01em;
}
.carousel { position: relative; display: flex; gap: 20px; padding-left: var(--gutter); }
.counter {
  flex: none; width: 94px; display: flex; align-items: center; gap: 8px; height: 14px;
  font-family: var(--display); font-size: 12px; line-height: 14px;
}
.counter i { width: 12px; height: 1px; background: rgba(255,255,255,.5); }
.counter .cur { display: inline-block; min-width: 16px; overflow: hidden; height: 14px; }
.counter .cur span { display: block; transition: transform .6s var(--ease-out); }
.viewport { flex: 1; overflow: hidden; cursor: grab; touch-action: pan-y; }
.viewport.is-dragging { cursor: grabbing; }
.track { display: flex; gap: 16.3px; will-change: transform; padding-right: var(--gutter); }
.card {
  position: relative; flex: none; width: clamp(260px, 30.3vw, 436px); aspect-ratio: 436 / 567;
  border-radius: 16px; overflow: hidden; background: #151515; isolation: isolate;
  transform: translateZ(0);
}
.card .media { position: absolute; inset: -6% -6%; will-change: transform; }
.card img { width: 100%; height: 100%; object-fit: cover; user-select: none; -webkit-user-drag: none; pointer-events: none;
  transform: scale(1.02); transition: transform 1.4s var(--ease-out), filter 1s var(--ease-out); }
.card:hover img { transform: scale(1.1); }
/* Framed cards carry composed artwork that runs to the edge (HSBC's logo band, Mastercard's phone): no bleed, drift or zoom, so nothing is cropped */
.card.is-framed .media { inset: 0; transform: none !important; }
.card.is-framed img, .card.is-framed:hover img { transform: none; }
.card .shine {
  position: absolute; inset: 0; z-index: 2; pointer-events: none; opacity: 0; transition: opacity .6s;
  background: radial-gradient(500px circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,.16), transparent 45%);
}
.card:hover .shine { opacity: 1; }
.card .meta {
  position: absolute; left: 20px; right: 20px; bottom: 20px; z-index: 3;
  display: flex; justify-content: space-between; align-items: flex-end;
  font-family: var(--display); font-size: 11px; text-transform: uppercase; letter-spacing: .02em;
  transform: translateY(14px); opacity: 0; transition: transform .7s var(--ease-out), opacity .5s;
}
.card .meta b { font-weight: 400; font-size: 18px; letter-spacing: -0.01em; text-transform: none; }
.card::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: 0; transition: opacity .6s;
  background: linear-gradient(to top, rgba(0,0,0,.7), transparent 45%);
}
.card:hover::after, .card:hover .meta { opacity: 1; }
.card:hover .meta { transform: translateY(0); }

.progress { display: flex; align-items: center; gap: 12px; margin: 20px var(--gutter) 0 calc(var(--gutter) + 114px);
  font-family: var(--display); font-size: 12px; line-height: 14px; }
.progress .first { color: var(--blue); }
.progress .bar { flex: 1; height: 1px; background: rgba(255,255,255,.3); position: relative; }
.progress .bar i { position: absolute; left: 0; top: -0.5px; height: 2px; width: 20%; background: var(--blue); transform-origin: left; }
.carousel-cta { margin: 60px 0 0 calc(var(--gutter) + 114px); }

/* Video / city */
.city { height: 140vh; }
.city-sticky { position: sticky; top: 0; height: 100vh; overflow: hidden; display: grid; place-items: center; }
.city-frame { position: absolute; inset: 0; overflow: hidden; will-change: clip-path; clip-path: inset(18% 22% round 24px); }
.city-frame img, .city-frame video { display: block; width: 100%; height: 100%; object-fit: cover; transform: scale(1.25); will-change: transform; }
.city-frame::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(11,11,11,.35), transparent 40%, rgba(11,11,11,.4)); }
.play-btn {
  position: absolute; right: var(--gutter); bottom: var(--gutter); z-index: 3;
  display: flex; align-items: center; gap: 14px; font-family: var(--display); font-size: 11px; text-transform: uppercase;
}
.play-btn i { width: 54px; height: 54px; border-radius: 50%; border: 1px solid rgba(255,255,255,.5); display: grid; place-items: center; transition: background .4s, transform .6s var(--ease-out); }
.play-btn:hover i { background: #fff; color: #000; transform: scale(1.1); }

/* Play / Pivot / Pause */
.ppp { background: var(--paper); color: #000; padding: 300px 0; overflow: hidden; display: flex; flex-direction: column; align-items: center; gap: 56px; }
.ppp-track { display: flex; align-items: center; gap: 24px; white-space: nowrap; will-change: transform; }
.ppp-track .word { font-family: var(--display); font-weight: 700; font-size: clamp(80px, 12.5vw, 180px); line-height: 1; letter-spacing: -0.01em; text-transform: uppercase; }
.ppp-track .word.o-wrap { position: relative; }
.ppp-track .word .o-cat { position: absolute; width: .8em; left: 2.05em; top: 0.08em; animation: float 4.5s ease-in-out infinite; }
.ppp-track .icon { width: clamp(60px, 7.8vw, 112px); height: auto; flex: none; }
.ppp-track .icon.star { animation: spin 14s linear infinite; }
.ppp-track .icon.smile { transition: transform .6s var(--ease-out); }
.ppp-track .icon.smile:hover { transform: rotate(20deg) scale(1.1); }

/* Logos */
.logos { background: var(--paper); color: #000; padding: 150px var(--gutter); text-align: center; }
.logos h3 { margin: 0 0 80px; font-family: var(--display); font-weight: 300; font-size: 32px; letter-spacing: -0.01em; }
.logo-rows { display: flex; flex-direction: column; gap: 40px; align-items: center; }
.logo-row { display: flex; gap: 50px; justify-content: center; flex-wrap: wrap; }
.client { width: clamp(120px, 14.66vw, 211px); height: 70px; display: grid; place-items: center; padding: 9px; }
.client img { grid-area: 1 / 1; max-width: 100%; max-height: 52px; object-fit: contain; opacity: .4; filter: grayscale(1);
  transition: opacity .5s, filter .5s, transform .7s var(--ease-out); }
/* True-colour logo stacked on the grey one, cross-faded in on hover */
.client img.color { opacity: 0; filter: none; }
.client:hover { position: relative; z-index: 1; }
.client:hover img { opacity: 0; transform: scale(1.75); }
.client:hover img.color { opacity: 1; }

/* Contact / footer */
.contact { min-height: 940px; padding: 372px 0 60px; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; }
.contact .wrap { max-width: 1440px; margin: 0 auto; width: 100%; padding: 0 clamp(16px, 11.1vw, 160px); }
.contact h2 { margin: 58px 0 0; font-family: var(--display); font-weight: 300; text-transform: uppercase;
  font-size: clamp(30px, 4.44vw, 64px); line-height: 1.15; letter-spacing: -0.01em; }
.contact h2 .ghost { color: transparent; -webkit-text-stroke: 1px rgba(255,255,255,.35); position: relative; display: inline-block; cursor: pointer;
  background: linear-gradient(90deg, #fff 50%, transparent 50%) right / 200% 100% no-repeat; -webkit-background-clip: text; background-clip: text;
  transition: background-position 1s var(--ease-out), -webkit-text-stroke-color .6s; }
.contact h2 .ghost:hover { background-position: left; -webkit-text-stroke-color: transparent; }
.foot-links { display: flex; justify-content: center; align-items: center; gap: 32px; margin-top: 200px; flex-wrap: wrap; }
.foot-links a { font-size: 12px; line-height: 14px; letter-spacing: .1em; text-transform: uppercase; opacity: .4; transition: opacity .3s; position: relative; }
.foot-links a::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .5s var(--ease-out); }
.foot-links a:hover { opacity: 1; }
.foot-links a:hover::after { transform: scaleX(1); transform-origin: left; }
.foot-links .sep { width: 1px; height: 14px; background: #272727; }

/* ---------- Careers ---------- */
.c-hero { padding-top: 160px; min-height: 760px; overflow: hidden; }
.c-title { margin: 0; text-align: center; font-size: clamp(38px, 6.94vw, 100px); line-height: 1; font-weight: 300; }
.c-title .row { display: block; white-space: nowrap; }
.c-title .row > .line-mask { display: inline-block; }
.c-title .r1 { transform: translateX(2.4vw); }
.c-title .r2 { transform: translateX(2.4vw); }
.c-title .r3 { transform: translateX(10.2vw); }
.c-title .r4 { transform: translateX(-0.5vw); color: var(--blue); }
.c-intro { position: relative; z-index: 1; width: min(438px, calc(100% - 32px)); margin: 75px auto 0; font-size: 16px; line-height: 1.2; letter-spacing: -0.01em; }
.c-intro p { margin: 0; }

.path-head { padding: 0 var(--gutter); margin-bottom: 40px; position: relative; z-index: 1; }
.path-head h2 { margin: 0; display: inline-flex; flex-direction: column; gap: 3px; font-family: var(--display); font-weight: 400; font-size: 18px; line-height: 14px; text-transform: uppercase; }
.path-head .tail { display: flex; align-items: center; width: 102px; }
.path-head .tail i { flex: 1; height: 1px; background: var(--blue); transform-origin: left; }
.path-head .tail b { width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--blue); }

.path-sec { padding: 100px 0 150px; }
.card.path { cursor: none; }
.card.path .go {
  position: absolute; z-index: 3; left: 50%; top: 22px; transform: translate(-50%, -10px); opacity: 0;
  padding: 10px 16px; border-radius: 999px; white-space: nowrap;
  background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.3);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  font-family: var(--display); font-size: 10px; text-transform: uppercase; letter-spacing: .04em;
  transition: opacity .5s, transform .7s var(--ease-out);
}
.card.path:hover .go { opacity: 1; transform: translate(-50%, 0); }
.card.path img { filter: grayscale(1) contrast(1.05); }
.card.path:hover img { filter: grayscale(.2) contrast(1.05); }
.card.path::after { background: linear-gradient(to top, rgba(19,64,241,.35), transparent 50%); }

.c-foot { padding: 120px 0 60px; overflow: hidden; text-align: center; }
.wordmark { width: 104.5vw; max-width: none; margin-left: -2.25vw; will-change: transform; }
.tagline { margin-top: 24px; font-family: var(--display); font-weight: 300; font-size: 24px; text-transform: uppercase; letter-spacing: -0.01em; white-space: pre; }

/* ---------- Page transition ---------- */
.curtain {
  position: fixed; inset: 0; z-index: 150; pointer-events: none;
  background: #0b0b0b; opacity: 0;
  display: grid; place-items: center;
  visibility: hidden; /* idle full-screen fixed layers get sampled into Safari's toolbar tint */
}
/* Reached through a transition (flag set in <head>): open covered and lit from the first paint, so the page
   never shows before main.js takes over. The failsafe uncovers it if the script never runs; main.js cancels it. */
.is-arriving .curtain { opacity: 1; visibility: visible; animation: curtainFailsafe .6s 6s forwards; }
.is-arriving .curtain .splash-bloom { opacity: .55; }
.is-arriving .curtain :is(.splash-glow, .splash-rim) { opacity: 1; }
@keyframes curtainFailsafe { to { opacity: 0; visibility: hidden; } }

/* ---------- Glowing mark: the black logomark backlit in the brand colours (home splash + page curtain) ---------- */
.splash-logo { position: relative; height: clamp(180px, 30vh, 300px); aspect-ratio: 28 / 45; }
.splash-logo svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
/* No CSS `scale` here: GSAP folds it into `transform` and overwrites it on the first tween, so it would only show
   on the first paint of an arriving page and the glow would visibly shrink once main.js takes over */
.splash-bloom { filter: blur(90px) saturate(1.4); opacity: 0; }                  /* the wide wash of colour */
.splash-glow { filter: blur(28px) saturate(1.4) brightness(1.15); opacity: 0; } /* the halo around the silhouette */
.splash-rim { filter: blur(3px) saturate(1.5) brightness(1.3); opacity: 0; }    /* the crisp light catching its edge */

/* ---------- AI Chat (glass) ---------- */
.chat-scrim {
  position: fixed; inset: 0; z-index: 70; background: rgba(5,5,10,.35);
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
  opacity: 0; pointer-events: none; visibility: hidden; /* same toolbar-tint reason as .curtain */
  transition: opacity .6s var(--ease-out), visibility 0s .6s;
}
body.chat-open .chat-scrim { opacity: 1; pointer-events: auto; visibility: visible; transition-delay: 0s; }
.chat {
  --r: 28px;
  position: fixed; z-index: 80; top: var(--gutter); right: var(--gutter);
  width: min(440px, calc(100vw - 2 * var(--gutter))); height: min(720px, calc(100vh - 2 * var(--gutter)));
  border-radius: var(--r); color: #fff;
  display: flex; flex-direction: column; overflow: hidden;
  background:
    linear-gradient(135deg, rgba(255,255,255,.16), rgba(255,255,255,.04) 40%, rgba(255,255,255,.02)),
    rgba(18, 20, 30, .38);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid rgba(255,255,255,.16);
  box-shadow: 0 30px 80px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.25), inset 0 -1px 0 rgba(255,255,255,.05);
  transform-origin: top right;
  clip-path: inset(0 0 calc(100% - 57px) calc(100% - 320px) round 24px);
  opacity: 0; pointer-events: none; visibility: hidden;
  transition: clip-path .9s var(--ease-out), opacity .35s, visibility 0s .9s;
}
body.chat-open .chat {
  clip-path: inset(0 0 0 0 round var(--r)); opacity: 1; pointer-events: auto; visibility: visible;
  transition: clip-path .9s var(--ease-out), opacity .25s, visibility 0s;
}
body.chat-open .pill { opacity: 0; transform: scale(.96); }
.chat::before { /* blue glow orb */
  content: ""; position: absolute; width: 380px; height: 380px; right: -140px; top: -160px; border-radius: 50%;
  background: radial-gradient(circle, rgba(19,64,241,.55), transparent 65%); filter: blur(20px); pointer-events: none; z-index: 0;
  animation: orb 9s ease-in-out infinite alternate;
}
@keyframes orb { to { transform: translate(-60px, 60px) scale(1.15); } }
.chat > * { position: relative; z-index: 1; }

.chat-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 18px 14px 24px; border-bottom: 1px solid rgba(255,255,255,.08); }
.chat-id { display: flex; align-items: center; gap: 12px; }
.chat-id .av { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--blue); box-shadow: 0 0 24px rgba(19,64,241,.6); }
.chat-id .av img { width: 11px; filter: brightness(10); }
.chat-id strong { display: block; font-family: var(--display); font-weight: 400; font-size: 13px; letter-spacing: -0.01em; }
.chat-id small { display: flex; align-items: center; gap: 6px; font-size: 11px; color: rgba(255,255,255,.6); }
.chat-id small::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #3ddc84; box-shadow: 0 0 8px #3ddc84; }
.chat-actions { display: flex; gap: 6px; }
.icon-btn { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08); transition: background .3s, transform .5s var(--ease-out); }
.icon-btn:hover { background: rgba(255,255,255,.16); transform: rotate(90deg); }
.icon-btn.restart:hover { transform: rotate(-180deg); }

.chat-body { flex: 1; overflow-y: auto; padding: 20px 20px 8px; scroll-behavior: smooth; scrollbar-width: none; }
.chat-body::-webkit-scrollbar { display: none; }

.welcome h3 { margin: 6px 4px 6px; font-family: var(--display); font-weight: 300; font-size: 24px; line-height: 1.15; letter-spacing: -0.01em; }
.welcome h3 em { font-style: normal; color: #7d98ff; }
.welcome p { margin: 0 4px 18px; font-size: 14px; color: rgba(255,255,255,.7); line-height: 1.4; }
.tracks { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.track-opt {
  position: relative; overflow: hidden; border-radius: 18px; aspect-ratio: 1 / 1.08; text-align: left;
  border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.04);
  transform: translateY(16px); opacity: 0;
  transition: transform .7s var(--ease-out), opacity .6s, border-color .4s, box-shadow .5s;
}
body.chat-open .track-opt { transform: none; opacity: 1; }
body.chat-open .track-opt:nth-child(1) { transition-delay: .25s, .25s, 0s, 0s; }
body.chat-open .track-opt:nth-child(2) { transition-delay: .32s, .32s, 0s, 0s; }
body.chat-open .track-opt:nth-child(3) { transition-delay: .39s, .39s, 0s, 0s; }
body.chat-open .track-opt:nth-child(4) { transition-delay: .46s, .46s, 0s, 0s; }
.track-opt img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 20%; filter: grayscale(1); opacity: .55; transform: scale(1.15); transition: transform 1.2s var(--ease-out), opacity .5s, filter .6s; }
.track-opt::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(8,10,20,.9), rgba(8,10,20,.1) 70%); }
.track-opt span { position: absolute; z-index: 1; left: 14px; right: 14px; bottom: 12px; }
.track-opt b { display: block; font-family: var(--display); font-weight: 400; font-size: 14px; letter-spacing: -0.01em; }
.track-opt small { display: block; margin-top: 3px; font-size: 11px; color: rgba(255,255,255,.65); }
.track-opt .ini { position: absolute; z-index: 1; top: 12px; left: 14px; font-family: var(--display); font-weight: 700; font-size: 11px; letter-spacing: .06em; padding: 4px 8px; border-radius: 999px; background: rgba(255,255,255,.12); backdrop-filter: blur(6px); }
.track-opt:hover { border-color: rgba(125,152,255,.7); box-shadow: 0 10px 30px rgba(19,64,241,.3); }
.track-opt:hover img { transform: scale(1.05); opacity: .85; filter: grayscale(.3); }

.suggest { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 8px; }

.msg { display: flex; margin: 10px 0; animation: msgIn .6s var(--ease-out) both; }
@keyframes msgIn { from { opacity: 0; transform: translateY(12px) scale(.98); } }
.msg .bubble { max-width: 86%; padding: 12px 16px; border-radius: 20px; font-size: 14px; line-height: 1.45; }
.msg.bot .bubble { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.1); border-top-left-radius: 6px; }
.msg.user { justify-content: flex-end; }
.msg.user .bubble { background: var(--blue); border-top-right-radius: 6px; box-shadow: 0 8px 24px rgba(19,64,241,.35); }
.msg .bubble strong { font-weight: 600; }
.msg .bubble ul { margin: 8px 0 0; padding-left: 18px; }
.msg .bubble li { margin: 4px 0; }
.msg.track-card .bubble { padding: 0; overflow: hidden; display: flex; gap: 12px; align-items: center; padding-right: 16px; }
.msg.track-card img { width: 64px; height: 72px; object-fit: cover; object-position: center 20%; filter: grayscale(1); }
.msg.track-card b { display: block; font-family: var(--display); font-weight: 400; font-size: 13px; }
.msg.track-card small { color: rgba(255,255,255,.65); font-size: 12px; }

.typing { display: inline-flex; gap: 4px; padding: 16px 18px !important; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,.7); animation: bob 1.1s infinite ease-in-out; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes bob { 0%, 80%, 100% { transform: translateY(0); opacity: .4; } 40% { transform: translateY(-5px); opacity: 1; } }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 10px; animation: msgIn .6s var(--ease-out) both; }
.chip {
  padding: 9px 14px; border-radius: 999px; font-size: 13px;
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.18);
  transition: background .3s, border-color .3s, transform .4s var(--ease-out);
}
.chip:hover { background: rgba(19,64,241,.5); border-color: rgba(125,152,255,.8); transform: translateY(-2px); }
.chips.used { opacity: .35; pointer-events: none; }

.chat-input { padding: 12px 14px 16px; border-top: 1px solid rgba(255,255,255,.08); }
.chat-input form { display: flex; align-items: center; gap: 8px; padding: 6px 6px 6px 18px; border-radius: 999px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.14); transition: border-color .3s, box-shadow .4s; }
.chat-input form:focus-within { border-color: rgba(125,152,255,.8); box-shadow: 0 0 0 4px rgba(19,64,241,.2); }
.chat-input input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: #fff; font: inherit; font-size: 14px; }
.chat-input input::placeholder { color: rgba(255,255,255,.45); }
.send { width: 38px; height: 38px; border-radius: 50%; background: var(--blue); display: grid; place-items: center; transition: transform .5s var(--ease-out), background .3s; }
.send:hover { transform: rotate(-45deg) scale(1.05); background: #2b55ff; }
.chat-foot { margin-top: 8px; text-align: center; font-size: 10px; color: rgba(255,255,255,.4); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .pill { width: auto; min-width: 0; }
  .pill-row { padding: 10px 14px 10px 20px; gap: 10px; }
  .anchors, .side-label { display: none; }
  .hero-title .row, .c-title .row { transform: none !important; }
  .carousel-sec h2 { padding-left: var(--gutter); }
  .counter { display: none; }
  .progress, .carousel-cta { margin-left: var(--gutter); }
  .prop { padding: 120px 0; }
  .ppp { padding: 160px 0; }
  .contact { min-height: 0; padding-top: 160px; }
  .foot-links { gap: 16px; margin-top: 120px; }
  .tagline { font-size: 16px; }
  .logo-row { gap: 12px 24px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

/* Figma crops some square logo files to a 190×41 band */
.client img { width: 190px; height: 52px; }
.client.cover img { height: 41px; object-fit: cover; max-height: none; }
/* Wide wordmarks Figma sets at 150px (Land Department) */
.client.narrow img { width: 150px; }

/* Crop portraits to faces: the source cards carry baked-in initials lower down */
.track-opt img { height: 175%; bottom: auto; object-position: center top; }
.msg.track-card img { object-fit: cover; object-position: center top; height: 72px; }
.card.path .media { inset: 0 -3%; }
.card.path img { object-position: center 100%; }

/* Keep oversized background art from widening the layout (clip keeps sticky working) */
html, body, section { overflow-x: clip; }
@media (max-width: 900px) {
  .pill { width: min(240px, calc(100vw - 100px)); }
  .side-cta { display: none; }
  .chat { top: 12px; right: 12px; width: calc(100vw - 24px); height: calc(100svh - 24px); }
  .city { height: 120vh; }
}
.msg.track-card img { transform: scale(1.7); transform-origin: center 12%; }

/* Chat: site links always visible, no burger while the panel is open */
body.chat-open .burger { display: none; }
.chat-nav {
  display: flex; gap: 4px; padding: 10px 14px; overflow-x: auto; scrollbar-width: none;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.chat-nav::-webkit-scrollbar { display: none; }
.chat-nav a {
  flex: 1 0 auto; text-align: center; padding: 8px 12px; border-radius: 999px; font-size: 12px;
  color: rgba(255,255,255,.75); background: rgba(255,255,255,.05); border: 1px solid transparent;
  transition: background .3s, color .3s, border-color .3s;
}
.chat-nav a:hover { color: #fff; background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.15); }
.chat-nav a.is-active { color: #fff; background: var(--blue); }

/* Interactive WebGL starfield (home hero) */
.starfield { inset: 0; width: 100%; height: 100%; pointer-events: none; }

/* Chat: 50% larger panel, bigger type, more breathing room */
.chat { --r: 32px; width: min(660px, calc(100vw - 2 * var(--gutter))); height: calc(100vh - 2 * var(--gutter)); max-height: 1000px; }
.chat-head { padding: 24px 24px 20px 32px; }
.chat-id { gap: 16px; }
.chat-id .av { width: 46px; height: 46px; }
.chat-id .av img { width: 15px; }
.chat-id strong { font-size: 17px; }
.chat-id small { font-size: 13px; }
.icon-btn { width: 44px; height: 44px; }
.chat-nav { gap: 6px; padding: 14px 24px; }
.chat-nav a { padding: 11px 16px; font-size: 14px; }
.chat-body { padding: 32px 32px 12px; }
.welcome h3 { font-size: 34px; margin-bottom: 12px; }
.welcome p { font-size: 17px; margin-bottom: 24px; }
.suggest { gap: 10px; }
.msg { margin: 14px 0; }
.msg .bubble { font-size: 17px; line-height: 1.55; padding: 16px 22px; border-radius: 24px; }
.msg.track-card img { width: 84px; height: 96px; }
.msg.track-card b { font-size: 16px; }
.msg.track-card small { font-size: 14px; }
.chip { font-size: 15px; padding: 12px 18px; }
.chips { gap: 10px; margin: 6px 0 14px; }
.chat-input { padding: 16px 24px 20px; }
.chat-input form { padding: 8px 8px 8px 24px; }
.chat-input input { font-size: 17px; }
.send { width: 46px; height: 46px; }
.chat-foot { font-size: 12px; margin-top: 10px; }
@media (max-width: 900px) {
  .chat-body { padding: 22px 18px 10px; }
  .welcome h3 { font-size: 26px; }
  .msg .bubble, .chat-input input { font-size: 16px; }
}
.msg.track-card .thumb { flex: none; width: 84px; height: 96px; overflow: hidden; }
.msg.track-card .thumb img { width: 100%; height: 100%; display: block; }

/* ==========================================================================
   Site header (Figma "00. Homepage 4"), the same on every page: a 57px glass
   menu button on the left, the brand on the right. Kept last so it wins over
   the older pill rules above, including their phone overrides.
   ========================================================================== */
.nav { align-items: center; }
/* Open, the links slide out sideways on the same line as the close icon */
.nav .pill { display: flex; align-items: center; width: auto; min-width: 0; max-width: calc(100vw - 2 * var(--gutter)); border-radius: 29px; background: rgba(0,0,0,.05); }
.nav .pill.menu-open { width: auto; }
.nav .pill-row { flex: none; justify-content: center; padding: 12px; }
.nav .burger span { background: #fff; }
body.on-light .nav .burger span { background: #111; }
.nav .pill-links { grid-template-rows: 1fr; grid-template-columns: 0fr; transition: grid-template-columns .6s var(--ease-out); min-width: 0; }
.nav .pill.menu-open .pill-links { grid-template-columns: 1fr; }
.nav .pill-links > div { min-width: 0; }
.nav .pill-links ul { flex-wrap: nowrap; padding: 0 12px 0 0; }
.nav .pill-links a { white-space: nowrap; }

/* Brand: the wordmark at the top of the page, the logomark once you scroll (main.js sets .is-scrolled).
   Both are 28px tall and pinned to the right edge, so the swap doesn't move anything.
   Each swap drops the incoming mark in from above with a little bounce while the outgoing one
   falls away below. .brand-anim (main.js) holds the animations back until the first real swap */
.brand { position: relative; display: block; width: 119px; height: 28px; transition: opacity .3s; }
.brand img { position: absolute; top: 0; right: 0; height: 28px; width: auto; transform-origin: 50% 0; }
.brand-mark { opacity: 0; visibility: hidden; }
.nav.is-scrolled .brand-word { opacity: 0; visibility: hidden; }
.nav.is-scrolled .brand-mark { opacity: 1; visibility: visible; }
.nav.is-scrolled .brand { pointer-events: none; }
.nav.is-scrolled .brand-mark { pointer-events: auto; }
.nav.brand-anim .brand img { animation: brandOut .45s cubic-bezier(.5, 0, .75, 0) both; }
.nav.brand-anim:not(.is-scrolled) .brand-word,
.nav.brand-anim.is-scrolled .brand-mark { animation: brandIn .9s cubic-bezier(.34, 1.56, .64, 1) .12s both; }
@keyframes brandIn {
  from { opacity: 0; visibility: visible; transform: translateY(-160%) rotate(-14deg) scale(.85); }
  45% { opacity: 1; }
  to { opacity: 1; visibility: visible; transform: none; }
}
@keyframes brandOut {
  from { opacity: 1; visibility: visible; transform: none; }
  to { opacity: 0; visibility: hidden; transform: translateY(70%) rotate(6deg) scale(.9); }
}
@media (prefers-reduced-motion: reduce) { .nav.brand-anim .brand img { animation: none !important; } }
.brand:hover { opacity: .7; }
body.on-light .brand img { filter: invert(1); }

@media (max-width: 600px) {
  /* The open menu needs the full row, so the brand steps aside */
  .nav .pill { flex: none; }
  .nav:has(.pill.menu-open) .brand { opacity: 0; pointer-events: none; }
  .nav .pill-links ul { gap: 4px; padding-right: 8px; }
  .nav .pill-links a { padding: 9px 10px; font-size: 12px; }
}

/* ==========================================================================
   Phones (Figma mobile frames, 393px wide: 1708:17328 Home, 1726:19382 Work,
   1726:21290 About, 1787:26426 Contact). Every frame sits on a 24px gutter,
   with a 16px / 24px header: the 57px glass menu button and a 30px wordmark.
   ========================================================================== */
@media (max-width: 600px) {
  :root { --gutter: 24px; }
  .nav { padding: 16px var(--gutter); }
  .nav .pill-row { padding: 11.5px; }
  .brand { width: 127.5px; height: 30px; }
  .brand img { height: 30px; }
}
