/* ──────────────────────────────────────────────────────────
   SOLARI — Launching Soon · v2 "observatory" restyle
   Built on site/tokens.css (Solari v2: dark-first, editorial).
   Display: Instrument Serif · Labels: IBM Plex Mono · Body: IBM Plex Sans
   ────────────────────────────────────────────────────────── */

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { height: auto; min-height: 100%; }

body {
  background: var(--bg-0);
  color: var(--fg-1);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  overflow-x: hidden;
  transition: background 0.4s ease, color 0.4s ease;
}

/* faint grain so the dark isn't a dead flat */
.sol-grain::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: 0.05;
  background-image: url("../assets/grain.svg");
  background-size: 300px 300px;
}

::selection { background: var(--sol-25); }

/* ─── type helpers ─── */
.mono {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg-3);
}
.serif { font-family: var(--font-serif); font-weight: 400; }

/* ─── Loader ─── */
#loader {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--bg-0);
  cursor: pointer;
  transition: opacity 0.9s ease, visibility 0.9s ease;
}
#loader.done { opacity: 0; visibility: hidden; }
#loader.gone { display: none; }
.loader-inner {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 22px;
}
.loader-star {
  width: 74px;
  height: 74px;
  animation: sol-star-pulse 2.4s ease-in-out infinite;
}
.loader-status {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 19px;
  color: var(--fg-3);
  min-height: 26px;
  white-space: nowrap;
}
.loader-pct {
  position: absolute;
  bottom: 26px;
  left: 30px;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.1em;
  color: var(--fg-2);
  font-variant-numeric: tabular-nums;
}
.loader-pct::after { content: ' %'; color: var(--fg-4); }
.loader-hint {
  position: absolute;
  bottom: 26px;
  right: 30px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--fg-5);
}
.loader-bar {
  position: absolute;
  top: 0;
  left: 0;
  height: 2px;
  width: 100%;
  background: var(--bd-1);
}
.loader-bar i { display: block; height: 100%; width: 0%; background: var(--sol); }

@keyframes sol-star-pulse {
  0%, 100% { opacity: 0.88; }
  50%      { opacity: 1; }
}

/* ─── Header ─── */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 30px;
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.brand img { width: 22px; height: 22px; animation: sol-star-pulse 4s ease-in-out infinite; }
.brand span {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.34em;
  color: var(--fg-1);
}
.header-right { display: flex; align-items: center; gap: 26px; }
.status-chip {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-3);
}
.status-chip i {
  display: inline-block;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--sol);
  margin-right: 9px;
  vertical-align: 2px;
  animation: sol-star-pulse 2s ease-in-out infinite;
}
.header-contact {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-1);
  text-decoration: none;
  border-bottom: 1px solid var(--bd-2);
  padding-bottom: 3px;
  transition: border-color 150ms ease, color 150ms ease;
}
.header-contact:hover { border-color: var(--sol); color: var(--sol); }

body[data-herotext="none"]:not(.scrolled) .site-header {
  opacity: 0;
  transform: translateY(-10px);
  pointer-events: none;
}
body[data-herotext="none"] .hero-content,
body[data-herotext="none"] .hero-headline { display: none; }
body[data-herotext="headline"] .hero-content { display: none; }
body[data-herotext="wordmark"] .hero-headline { display: none; }

/* ─── Hero ─── */
.hero {
  position: relative;
  height: 100vh;
  height: 100svh;
  min-height: 480px;
  overflow: hidden;
}
#hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

/* small corner headline — the visual owns the screen */
.hero-headline {
  position: absolute;
  left: 30px;
  bottom: 34px;
  z-index: 2;
  pointer-events: none;
  max-width: min(560px, 80vw);
}
.hero-headline .eyebrow {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--fg-3);
  margin-bottom: 14px;
}
.hero-headline .eyebrow b { color: var(--sol); font-weight: 500; }
.hero-headline h1 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(28px, 3.6vw, 46px);
  line-height: 1.12;
  letter-spacing: 0.005em;
  color: var(--fg-1);
  text-wrap: balance;
}
.hero-headline h1 em {
  font-style: italic;
  color: var(--sol);
}
.hero-meta {
  position: absolute;
  right: 30px;
  bottom: 38px;
  z-index: 2;
  pointer-events: none;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--fg-4);
  text-align: right;
}

/* wordmark variant (kept as a tweak) */
.hero-content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  pointer-events: none;
  padding: 0 24px;
}
.hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--fg-3);
  margin-bottom: 22px;
}
.hero-title {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(72px, 14vw, 210px);
  letter-spacing: 0.01em;
  line-height: 0.95;
  color: var(--fg-1);
  display: flex;
  align-items: center;
  user-select: none;
}
.hero-title .o-star {
  display: inline-block;
  width: 1.2em;
  height: 1.2em;
  margin: 0 -0.26em;
  animation: sol-star-pulse 4s ease-in-out infinite;
}
.hero-sub {
  margin-top: 26px;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(16px, 1.6vw, 21px);
  color: var(--fg-2);
}
.hero-sub .sol-dot { color: var(--sol); font-style: normal; }

.hero-scrollcue {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  width: 1px;
  height: 64px;
  overflow: hidden;
}
.hero-scrollcue::after {
  content: '';
  display: block;
  width: 1px;
  height: 100%;
  background: linear-gradient(transparent, var(--fg-3));
  animation: cue-drop 2.4s cubic-bezier(0.22, 1, 0.36, 1) infinite;
}
@keyframes cue-drop {
  0%   { transform: translateY(-100%); }
  60%  { transform: translateY(0); }
  100% { transform: translateY(100%); }
}

/* hero entrance */
.hero-headline, .hero-meta, .hero-content > * {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 1.1s cubic-bezier(0.22, 1, 0.36, 1), transform 1.1s cubic-bezier(0.22, 1, 0.36, 1);
}
body.revealed .hero-headline,
body.revealed .hero-meta,
body.revealed .hero-content > * { opacity: 1; transform: none; }
body.revealed .hero-meta { transition-delay: 0.35s; }
body.revealed .hero-headline { transition-delay: 0.15s; }

/* ─── Marquee ─── */
.marquee-band {
  padding: clamp(40px, 8vh, 90px) 0;
  border-top: 1px solid var(--bd-1);
  border-bottom: 1px solid var(--bd-1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: clamp(4px, 1.5vh, 18px);
}
.marquee { overflow: hidden; white-space: nowrap; }
.marquee-track {
  display: inline-flex;
  align-items: baseline;
  gap: 0.55em;
  will-change: transform;
  animation: marq var(--marq-dur, 30s) linear infinite;
}
.marquee.rev .marquee-track { animation-name: marq-rev; }
@keyframes marq     { from { transform: translateX(0); }    to { transform: translateX(-50%); } }
@keyframes marq-rev { from { transform: translateX(-50%); } to { transform: translateX(0); } }
.marquee-track span {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(42px, 7vw, 104px);
  line-height: 1.1;
  color: var(--fg-1);
}
.marquee-track span.hollow {
  font-style: italic;
  color: var(--fg-4);
}
.marquee-track span.sep {
  color: var(--sol);
  font-size: clamp(16px, 2.2vw, 32px);
  transform: translateY(-0.5em);
}

/* ─── Statements — editorial, left-aligned ─── */
.statement {
  min-height: 78vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 16vh clamp(24px, 8vw, 140px);
  border-top: 1px solid var(--bd-1);
  position: relative;
}
.statement .num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--fg-3);
  margin-bottom: 34px;
}
.statement .num b { color: var(--sol); font-weight: 500; }
.statement h2 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(44px, 7vw, 110px);
  line-height: 1.04;
  letter-spacing: 0.005em;
  max-width: 16ch;
  color: var(--fg-1);
  text-wrap: balance;
}
.statement h2 em { font-style: italic; color: var(--fg-3); }
.statement h2 .sol-text { font-style: italic; color: var(--sol); }
.statement .aside {
  margin-top: 36px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--fg-3);
}
.statement.right { align-items: flex-end; text-align: right; }
.statement.right h2 { max-width: 15ch; }

/* ─── Platforms strip ─── */
.platforms {
  display: flex;
  flex-direction: column;
  gap: 36px;
  padding: clamp(60px, 12vh, 120px) clamp(24px, 8vw, 140px);
  border-top: 1px solid var(--bd-1);
}
.platforms .mono { letter-spacing: 0.3em; }
.platform-row {
  display: flex;
  align-items: baseline;
  gap: clamp(28px, 6vw, 90px);
  flex-wrap: wrap;
}
.platform-badge {
  font-family: var(--font-serif);
  font-size: clamp(28px, 3.4vw, 48px);
  color: var(--fg-2);
  display: inline-flex;
  align-items: baseline;
  gap: 14px;
  transition: color 150ms ease;
}
.platform-badge:hover { color: var(--fg-1); }
.platform-badge i {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
  align-self: center;
}
.platform-badge.meta i   { background: var(--data-meta); }
.platform-badge.tiktok i { background: var(--data-tiktok); }
.platform-badge.google i { background: var(--data-google); }

/* ─── The work — full-bleed reel of studio output ─── */
.work {
  padding: clamp(60px, 12vh, 120px) 0;
  border-top: 1px solid var(--bd-1);
  overflow: hidden;
}
.work .num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--fg-3);
  margin-bottom: 44px;
  padding: 0 clamp(24px, 8vw, 140px);
}
.work .num b { color: var(--sol); font-weight: 500; }
.work-strip {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.work-track {
  display: inline-flex;
  align-items: stretch;
  gap: 14px;
  padding-left: 14px;
  will-change: transform;
  animation: marq 64s linear infinite;
}
.work-strip:hover .work-track { animation-play-state: paused; }
.work-tile {
  flex: 0 0 auto;
  height: clamp(240px, 42vh, 380px);
  border: 1px solid var(--bd-2);
  background: var(--bg-2);
  overflow: hidden;
  /* resting state: half-asleep, like the rest of the night sky */
  filter: saturate(0.75) brightness(0.8);
  transition: filter 450ms cubic-bezier(0.22, 1, 0.36, 1);
}
.work-tile:hover { filter: none; }
.work-tile img,
.work-tile video {
  height: 100%;
  width: auto;
  max-width: none;
  display: block;
}
.work-aside {
  margin-top: 40px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--fg-3);
  text-align: right;
  padding: 0 clamp(24px, 8vw, 140px);
}

/* ─── Contact ─── */
.contact {
  padding: clamp(70px, 14vh, 150px) clamp(24px, 8vw, 140px);
  border-top: 1px solid var(--bd-1);
}
.contact-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 6vw, 110px);
  align-items: start;
  max-width: 1180px;
}
.contact h2 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(52px, 6.5vw, 100px);
  line-height: 1;
  color: var(--fg-1);
}
.contact h2 em { font-style: italic; color: var(--sol); }
.contact .lede {
  margin-top: 22px;
  font-size: 15px;
  line-height: 1.7;
  color: var(--fg-2);
  max-width: 36ch;
}
.contact form { display: flex; flex-direction: column; gap: 34px; }
.field label {
  display: block;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--fg-3);
  margin-bottom: 10px;
}
.field input,
.field textarea {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--bd-2);
  border-radius: 0;
  padding: 8px 0 12px;
  font-family: var(--font-serif);
  font-size: 22px;
  color: var(--fg-1);
  outline: none;
  transition: border-color 200ms ease;
  resize: vertical;
}
.field input::placeholder,
.field textarea::placeholder { color: var(--fg-4); font-style: italic; }
.field input:focus,
.field textarea:focus { border-color: var(--sol); }
.field.invalid input,
.field.invalid textarea { border-color: var(--err); }
.field .err {
  display: none;
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--err);
}
.field.invalid .err { display: block; }
.contact button[type="submit"] {
  align-self: flex-start;
  background: var(--sol);
  color: var(--on-sol);
  border: none;
  border-radius: var(--r-2);
  padding: 14px 40px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  cursor: pointer;
  transition: opacity 150ms ease;
}
.contact button[type="submit"]:hover { opacity: 0.9; }
.contact button[type="submit"]:active { transform: translateY(1px); }
.contact button[type="submit"]:disabled { opacity: 0.55; cursor: default; transform: none; }
/* honeypot — off-screen, never display:none (bots check) */
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
/* general submit error (rate-limit / server) */
.form-err { display: none; color: var(--err); letter-spacing: 0.08em; text-transform: none; }
form.failed .form-err { display: block; }
.form-done {
  display: none;
  padding: 30px 0;
  border-top: 1px solid var(--bd-focus);
}
.form-done .mono { color: var(--sol); }
.form-done p {
  margin-top: 12px;
  font-family: var(--font-serif);
  font-size: 22px;
  font-style: italic;
  color: var(--fg-2);
}
.contact.sent form { display: none; }
.contact.sent .form-done { display: block; }

/* POPIA consent microcopy below submit button */
.form-consent {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.10em;
  text-transform: none;
  color: var(--fg-4);
  line-height: 1.6;
}
.form-consent a {
  color: var(--fg-3);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.form-consent a:hover { color: var(--fg-1); }

/* ─── Footer ─── */
.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 26px 30px;
  border-top: 1px solid var(--bd-1);
}
.site-footer .stamp,
.site-footer .soon {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--fg-4);
}
.footer-privacy {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--fg-4);
  text-decoration: none;
}
.footer-privacy:hover { color: var(--fg-2); }
.site-footer .soon i {
  display: inline-block;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--sol);
  margin-right: 9px;
  vertical-align: 2px;
  animation: sol-star-pulse 2s ease-in-out infinite;
}

/* ─── Scroll reveal ─── */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1s cubic-bezier(0.22, 1, 0.36, 1), transform 1s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.in { opacity: 1; transform: none; }
.reveal-d1 { transition-delay: 0.12s; }
.reveal-d2 { transition-delay: 0.24s; }

/* ─── Reduced motion ─── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .marquee-track { animation: none; }
  .reveal, .hero-headline, .hero-meta, .hero-content > * { opacity: 1; transform: none; transition: none; }
  .hero-scrollcue::after { animation: none; }
  /* reel: stop drifting, allow manual swipe instead */
  .work-track { animation: none; }
  .work-strip { overflow-x: auto; -webkit-mask-image: none; mask-image: none; }
  .work-tile { filter: none; }
}

@media (max-width: 760px) {
  .site-header { padding: 16px 18px; }
  .status-chip { display: none; }
  .hero-headline { left: 18px; bottom: 26px; }
  .hero-meta { display: none; }
  .contact-inner { grid-template-columns: 1fr; }
  .statement.right { align-items: flex-start; text-align: left; }
  .work-tile { height: clamp(200px, 34vh, 280px); }
  .work .num, .work-aside { padding: 0 18px; }
}
