/* ============================================================
   THE BOYZ KE — GLOBAL DESIGN SYSTEM
   Broadcast Culture: warm-espresso studio dark + flame + cream
   Shared across every page (tokens, nav, footer, components)
   ============================================================ */

:root {
  /* --- Surfaces (warm, not cold-black) --- */
  --espresso: #16111A;
  --bg: #16111A;
  --bg-2: #1E1722;
  --bg-3: #f1ebd5;
  --surface: #251B2C;
  --surface-2: #2F2338;
  --cream: #F5ECDD;
  --cream-2: #E9DBC6;
  --ink: #191016;          /* text on cream */

  /* --- Text --- */
  --text: #F6EFE6;
  --muted: #B4A6B0;
  --faint: #7C6F79;
  --line: rgba(245, 236, 221, 0.10);
  --line-strong: rgba(245, 236, 221, 0.18);
  --btn: #e4dae1;

  /* --- Flame system --- */
  --flame-1: #FF5B3E;
  --flame-2: #FFB020;
  --pink: #FF3E7F;
  --violet: #A85CFF;
  --grad-flame: linear-gradient(105deg, #FF5B3E 0%, #FFB020 100%);
  --grad-heat: linear-gradient(120deg, #FF5B3E 0%, #FF3E7F 48%, #A85CFF 100%);
  --grad-ember: radial-gradient(120% 120% at 20% 10%, rgba(255,91,62,.35), transparent 55%),
                radial-gradient(120% 120% at 90% 20%, rgba(168,92,255,.28), transparent 55%),
                radial-gradient(140% 140% at 60% 100%, rgba(255,62,127,.24), transparent 55%);

  /* --- Radii --- */
  --r-xs: 8px;
  --r-sm: 12px;
  --r: 18px;
  --r-lg: 26px;
  --r-xl: 38px;

  /* --- Shadow (warm-tinted) --- */
  --sh-1: 0 2px 8px rgba(0,0,0,.35);
  --sh-2: 0 18px 50px -18px rgba(0,0,0,.65);
  --sh-flame: 0 22px 60px -20px rgba(255,91,62,.45);

  /* --- Type --- */
  --display: "Unbounded", system-ui, sans-serif;
  --body: "Space Grotesk", system-ui, sans-serif;
  --mono: "Space Mono", ui-monospace, monospace;

  /* --- Layout --- */
  --maxw: 1240px;
  --gutter: clamp(20px, 5vw, 64px);
  --nav-h: 72px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
body {
  font-family: var(--body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  font-weight: 400;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; background: none; border: none; }
input, textarea, select { font: inherit; color: inherit; }
ul { list-style: none; }
::selection { background: var(--pink); color: #fff; }

/* ---------- Type primitives ---------- */
.eyebrow {
  font-family: var(--mono);
  font-size: .74rem;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--flame-2);
  display: inline-flex;
  align-items: center;
  gap: .6em;
}
.eyebrow::before {
  content: "";
  width: 26px; height: 2px;
  background: var(--grad-flame);
  display: inline-block;
}
.display {
  font-family: var(--display);
  font-weight: 800;
  line-height: .96;
  letter-spacing: -.02em;
}
.flame-text {
  background: var(--grad-heat);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.section-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2rem, 5.2vw, 3.6rem);
  line-height: 1.02;
  letter-spacing: -.02em;
}
.lead { color: var(--muted); font-size: clamp(1rem, 1.4vw, 1.18rem); max-width: 60ch; }

/* ---------- Layout helpers ---------- */
/* Full-width (edge to edge) with a small responsive side padding.
   Inner text blocks keep their own ch-based max-widths for readability. */
.container { width: 100%; max-width: none; margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(72px, 11vw, 148px); position: relative; }
.section--cream { background: var(--cream); color: var(--ink); }
.section--cream .lead { color: #5b4d55; }
.section--cream .eyebrow { color: var(--flame-1); }
.stack { display: flex; flex-direction: column; }
.center { text-align: center; }

/* ============================================================
   BROADCAST TOP-STRIP + NAV
   ============================================================ */
.ticker {
  background: var(--grad-flame);
  color: #1b0f08;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  overflow: hidden;
  white-space: nowrap;
  height: 30px;
  display: flex;
  align-items: center;
}
.ticker__track { display: inline-flex; gap: 2.5rem; padding-left: 2.5rem; animation: ticker 32s linear infinite; }
.ticker__track span { display: inline-flex; align-items: center; gap: .6rem; font-weight: 700; }
.ticker__track span::before { content: "◆"; font-size: .6rem; }
@keyframes ticker { to { transform: translateX(-50%); } }
.ticker:hover .ticker__track { animation-play-state: paused; }

.nav {
  position: sticky; top: 0; z-index: 100;
  height: var(--nav-h);
  display: flex; align-items: center;
  background: color-mix(in oklab, var(--bg) 78%, transparent);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--line);
  transition: background .3s var(--ease), border-color .3s;
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; width: 100%; }
.nav__end { display: flex; align-items: center; gap: .5rem; }
.brand { display: inline-flex; align-items: center; gap: .65rem; }
.brand__mark { width: 38px; height: 38px; flex: none; filter: drop-shadow(0 4px 12px rgba(255,91,62,.35)); }
.brand__name { font-family: var(--display); font-weight: 800; font-size: 1.06rem; letter-spacing: -.01em; line-height: 1; }
.brand__name em { font-style: normal; color: var(--flame-2); }
.brand__tag { display:block; font-family: var(--mono); font-size:.56rem; letter-spacing:.34em; color: var(--faint); margin-top:3px; }

.nav__links { display: flex; align-items: center; gap: .35rem; }
.nav__links a {
  font-size: .9rem; font-weight: 500; color: var(--muted);
  padding: .5rem .8rem; border-radius: 999px;
  position: relative; transition: color .2s;
}
.nav__links a:hover, .nav__links a.is-active { color: var(--text); }
.nav__links a.is-active::after {
  content: ""; position: absolute; left: 50%; bottom: 2px; transform: translateX(-50%);
  width: 5px; height: 5px; border-radius: 50%; background: var(--grad-flame);
}
.nav__cta { margin-left: .5rem; }

.nav__burger { display: none; width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line-strong); align-items: center; justify-content: center; }
.nav__burger span { display: block; width: 20px; height: 2px; background: var(--text); position: relative; transition: .3s var(--ease); }
.nav__burger span::before, .nav__burger span::after { content: ""; position: absolute; left: 0; width: 20px; height: 2px; background: var(--text); transition: .3s var(--ease); }
.nav__burger span::before { top: -6px; } .nav__burger span::after { top: 6px; }
body.menu-open .nav__burger span { background: transparent; }
body.menu-open .nav__burger span::before { top: 0; transform: rotate(45deg); }
body.menu-open .nav__burger span::after { top: 0; transform: rotate(-45deg); }

/* ---------- Mobile drawer (hidden on desktop) ---------- */
.nav__drawer, .nav__scrim { display: none; }
.nav__drawer-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--line); }
.nav__close { width: 40px; height: 40px; flex: none; border-radius: 10px; border: 1px solid var(--line-strong); display: grid; place-items: center; color: var(--text); }
.nav__close svg { width: 18px; height: 18px; }
.nav__close:hover { border-color: var(--flame-2); color: var(--flame-2); }
.nav__drawer-links { display: flex; flex-direction: column; gap: .2rem; margin-top: 1rem; }
.nav__drawer-links a { display: block; padding: .85rem 1rem; border-radius: 12px; font-size: 1.05rem; font-weight: 500; color: var(--muted); transition: background .2s, color .2s; }
.nav__drawer-links a:hover, .nav__drawer-links a.is-active { background: var(--surface); color: var(--text); }
.nav__drawer-cta { margin-top: 1.4rem; width: 100%; }

/* Below 1285px: collapse the header menu into a right-side drawer */
@media (max-width: 1285px) {
  .nav__links { display: none; }
  .nav__burger { display: inline-flex; }

  .nav__drawer {
    display: flex; flex-direction: column;
    position: fixed; top: 0; right: 0; bottom: 0; z-index: 1210;
    width: min(340px, 86vw);
    padding: 1rem 1.1rem 1.6rem;
    background: var(--bg-2); border-left: 1px solid var(--line);
    box-shadow: var(--sh-2); overflow-y: auto;
    transform: translateX(100%); transition: transform .35s var(--ease);
  }
  body.menu-open .nav__drawer { transform: none; }

  .nav__scrim {
    display: block; position: fixed; inset: 0; z-index: 1200;
    background: rgba(8,5,10,.55); backdrop-filter: blur(2px);
    opacity: 0; visibility: hidden; transition: opacity .3s, visibility .3s;
  }
  body.menu-open .nav__scrim { opacity: 1; visibility: visible; }
  body.menu-open { overflow: hidden; }
}

/* ============================================================
   AUTH WIDGET (Google sign-in) — sits in the nav, right of the CTA
   ============================================================ */
.nav__auth { position: relative; display: flex; align-items: center; }
.auth { position: relative; display: flex; align-items: center; }
/* [hidden] must win over the display rules below (login/user toggle) */
.auth [hidden] { display: none; }

.auth__login,
.auth__chip {
  display: inline-flex; align-items: center; gap: .55rem;
  border-radius: 999px; border: 1px solid var(--line-strong);
  background: rgba(255,255,255,.03); color: var(--text);
  font-family: var(--body); font-weight: 600; font-size: .9rem;
  transition: border-color .2s, background .2s, transform .2s var(--ease);
}
.auth__login { padding: .5rem 1.05rem; }
.auth__login:hover { border-color: var(--flame-2); transform: translateY(-2px); }
.auth__gicon { width: 18px; height: 18px; flex: none; display: block; }

.auth__chip { padding: .28rem .7rem .28rem .3rem; }
.auth__chip:hover { background: rgba(255,255,255,.06); }
.auth__chev { width: 16px; height: 16px; opacity: .7; transition: transform .25s var(--ease); }
.auth__chip[aria-expanded="true"] .auth__chev { transform: rotate(180deg); }
.auth__fname { max-width: 10ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.auth__avatar {
  width: 32px; height: 32px; flex: none; border-radius: 50%;
  display: grid; place-items: center; overflow: hidden;
  background: linear-gradient(135deg, #FF3E7F, #C2185B);
  color: #fff; font-family: var(--display); font-weight: 800; font-size: .95rem; line-height: 1;
}
.auth__avatar img { width: 100%; height: 100%; object-fit: cover; }
.auth__avatar--lg { width: 52px; height: 52px; font-size: 1.5rem; }

.auth__menu {
  position: absolute; top: calc(100% + 10px); right: 0; z-index: 200;
  width: min(300px, 84vw);
  background: var(--bg-2); border: 1px solid var(--line-strong);
  border-radius: var(--r); box-shadow: var(--sh-2); padding: 1.1rem;
  animation: authIn .22s var(--ease);
}
@keyframes authIn { from { opacity: 0; transform: translateY(-6px); } }
.auth__id { display: flex; align-items: center; gap: .9rem; }
.auth__meta { display: flex; flex-direction: column; min-width: 0; }
.auth__meta b { font-family: var(--display); font-weight: 700; font-size: 1.02rem; line-height: 1.15; }
.auth__meta span { font-size: .82rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.auth__sep { height: 1px; background: var(--line); margin: 1rem 0; }
.auth__admin {
  display: flex; align-items: center; justify-content: center; gap: .5rem; width: 100%;
  padding: .8rem 1rem; border-radius: var(--r-sm); margin-bottom: .6rem;
  border: 1px solid rgba(255,176,32,.35); background: rgba(255,176,32,.07);
  color: var(--flame-2); font-family: var(--body); font-weight: 600; font-size: .95rem;
  transition: background .2s, border-color .2s;
}
.auth__admin svg { width: 18px; height: 18px; }
.auth__admin:hover { background: rgba(255,176,32,.14); border-color: rgba(255,176,32,.6); }
.auth__signout {
  display: flex; align-items: center; justify-content: center; gap: .5rem; width: 100%;
  padding: .8rem 1rem; border-radius: var(--r-sm);
  border: 1px solid rgba(255,62,127,.35); background: rgba(255,62,127,.06);
  color: var(--pink); font-family: var(--body); font-weight: 600; font-size: .95rem;
  transition: background .2s, border-color .2s;
}
.auth__signout svg { width: 18px; height: 18px; }
.auth__signout:hover { background: rgba(255,62,127,.12); border-color: rgba(255,62,127,.6); }

/* In the top bar on mobile: compact, icon-only to save space */
@media (max-width: 900px) {
  .auth__fname, .auth__chev { display: none; }   /* hide name + chevron */
  .auth__login span { display: none; }           /* Google button -> icon only */
  .auth__login { padding: .5rem; }
  .auth__chip { padding: .28rem; }               /* just the avatar */
  .auth__menu { right: 0; width: min(280px, 88vw); }
}

/* ---------- Live badge ---------- */
.live { display: inline-flex; align-items: center; gap: .5rem; font-family: var(--mono); font-size: .68rem; letter-spacing: .2em; text-transform: uppercase; color: var(--text); }
.live__dot { width: 8px; height: 8px; border-radius: 50%; background: var(--pink); box-shadow: 0 0 0 0 rgba(255,62,127,.6); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255,62,127,.55);} 70% { box-shadow: 0 0 0 10px rgba(255,62,127,0);} 100% { box-shadow: 0 0 0 0 rgba(255,62,127,0);} }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  --pad-y: .85rem; --pad-x: 1.5rem;
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  padding: var(--pad-y) var(--pad-x);
  font-family: var(--body); font-weight: 600; font-size: .95rem;
  border-radius: 999px; border: 1px solid transparent;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s, color .25s, border-color .25s;
  will-change: transform; white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn:focus-visible { outline: 3px solid var(--violet); outline-offset: 3px; }
.btn-flame { background: var(--grad-flame); color: #1b0f08; box-shadow: var(--sh-flame); font-weight: 700; }
.btn-flame:hover { transform: translateY(-3px); box-shadow: 0 28px 70px -18px rgba(255,91,62,.6); }
.btn-ghost { border-color: var(--line-strong); color: var(--text); background: rgba(255,255,255,.02); }
.btn-ghost:hover { border-color: var(--flame-2); color: var(--flame-2); transform: translateY(-3px); }
.btn-solid { background: var(--text); color: var(--ink); }
.btn-solid:hover { transform: translateY(-3px); box-shadow: var(--sh-2); }
.btn-lg { --pad-y: 1.05rem; --pad-x: 2rem; font-size: 1.02rem; }
.btn .arw { transition: transform .3s var(--ease); }
.btn:hover .arw { transform: translateX(4px); }
.section--cream .btn-ghost { border-color: rgba(25,16,22,.2); color: var(--ink); }
.section--cream .btn-ghost:hover { border-color: var(--flame-1); color: var(--flame-1); }

/* ---------- Chips / pills ---------- */
.chip { display:inline-flex; align-items:center; gap:.45rem; font-family:var(--mono); font-size:.7rem; letter-spacing:.14em; text-transform:uppercase; padding:.4rem .75rem; border:1px solid var(--line-strong); border-radius:999px; color:var(--muted); }

/* ============================================================
   WAVEFORM (brand signature)
   ============================================================ */
.wave { display: flex; align-items: center; gap: 3px; height: 28px; }
.wave i {
  width: 4px; border-radius: 3px; background: var(--grad-flame);
  height: 30%; animation: wave 1.2s ease-in-out infinite;
}
@keyframes wave { 0%,100% { height: 22%; } 50% { height: 100%; } }
.wave i:nth-child(1){animation-delay:0s}.wave i:nth-child(2){animation-delay:.12s}
.wave i:nth-child(3){animation-delay:.24s}.wave i:nth-child(4){animation-delay:.36s}
.wave i:nth-child(5){animation-delay:.48s}.wave i:nth-child(6){animation-delay:.3s}
.wave i:nth-child(7){animation-delay:.18s}.wave i:nth-child(8){animation-delay:.06s}
.wave.is-paused i { animation-play-state: paused; }

/* ---------- Divider (frequency rule) ---------- */
.freq-rule { height: 2px; width: 100%; background:
  repeating-linear-gradient(90deg, var(--line-strong) 0 6px, transparent 6px 12px); border: 0; }

/* ============================================================
   CARDS (base)
   ============================================================ */
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: 1.6rem;
  transition: transform .35s var(--ease), border-color .35s, box-shadow .35s, background .35s;
}
.card:hover { transform: translateY(-6px); border-color: var(--line-strong); box-shadow: var(--sh-2); }

/* ============================================================
   FORMS
   ============================================================ */
.field { display: flex; flex-direction: column; gap: .5rem; }
.field label { font-family: var(--mono); font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.input, .textarea, .select {
  width: 100%; padding: .95rem 1.1rem;
  background: rgba(255,255,255,.03); border: 1px solid var(--line-strong);
  border-radius: var(--r-sm); color: var(--text);
  transition: border-color .2s, background .2s, box-shadow .2s;
}
.input::placeholder, .textarea::placeholder { color: var(--faint); }
.input:focus, .textarea:focus, .select:focus {
  outline: none; border-color: var(--flame-2);
  background: rgba(255,176,32,.05); box-shadow: 0 0 0 4px rgba(255,176,32,.12);
}
.textarea { resize: vertical; min-height: 130px; }
/* Native dropdown list — give options a readable dark bg + light text
   (the popup otherwise inherits the light select colour on a light bg). */
.select option, .select optgroup { background: #1E1722; color: #F6EFE6; }
.section--cream .input, .section--cream .textarea, .section--cream .select { background: #fff; border-color: rgba(25,16,22,.14); color: var(--ink); }
.section--cream .field label { color: #6b5b63; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer { background: #100C14; border-top: 1px solid var(--line); padding-block: 4.5rem 2rem; }
.footer__grid { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 2.5rem; }
.footer__brand p { color: var(--muted); margin-top: 1rem; max-width: 34ch; font-size: .95rem; }
.footer h4 { font-family: var(--mono); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--flame-2); margin-bottom: 1.1rem; }
.footer li { margin-bottom: .6rem; }
.footer li a { color: var(--muted); font-size: .95rem; transition: color .2s, padding .2s; }
.footer li a:hover { color: var(--text); padding-left: 4px; }
.socials { display: flex; gap: .6rem; margin-top: 1.4rem; }
.socials a {
  width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--line-strong);
  display: grid; place-items: center; color: var(--muted);
  transition: .25s var(--ease);
}
.socials a:hover { color: #1b0f08; background: var(--grad-flame); border-color: transparent; transform: translateY(-4px); }
.socials svg { width: 18px; height: 18px; }
.footer__base { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-top: 3.5rem; padding-top: 1.5rem; border-top: 1px solid var(--line); flex-wrap: wrap; }
.footer__base p { font-family: var(--mono); font-size: .74rem; color: var(--faint); letter-spacing: .05em; }
@media (max-width: 860px) { .footer__grid { grid-template-columns: 1fr 1fr; gap: 2rem; } .footer__brand { grid-column: 1 / -1; } }
@media (max-width: 520px) { .footer__grid { grid-template-columns: 1fr; } }

/* ============================================================
   SCROLL REVEAL + MOTION UTILITIES
   ============================================================ */
[data-reveal] { opacity: 0; transform: translateY(28px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
[data-reveal].in { opacity: 1; transform: none; }
[data-reveal][data-delay="1"]{ transition-delay:.08s } [data-reveal][data-delay="2"]{ transition-delay:.16s }
[data-reveal][data-delay="3"]{ transition-delay:.24s } [data-reveal][data-delay="4"]{ transition-delay:.32s }
[data-reveal][data-delay="5"]{ transition-delay:.4s } [data-reveal][data-delay="6"]{ transition-delay:.48s }
@media (prefers-reduced-motion: reduce) { [data-reveal] { opacity: 1; transform: none; } }


/* ---------- Toast ---------- */
.toast-wrap { position: fixed; right: 20px; bottom: 20px; z-index: 9998; display: flex; flex-direction: column; gap: .6rem; }
.toast { background: var(--surface-2); border: 1px solid var(--line-strong); border-left: 3px solid var(--flame-2); color: var(--text); padding: .9rem 1.1rem; border-radius: var(--r-sm); box-shadow: var(--sh-2); font-size: .9rem; display: flex; align-items: center; gap: .6rem; transform: translateX(120%); animation: toastIn .4s var(--ease) forwards; max-width: 320px; }
.toast.out { animation: toastOut .3s var(--ease) forwards; }
@keyframes toastIn { to { transform: none; } }
@keyframes toastOut { to { transform: translateX(120%); opacity: 0; } }

/* ---------- Marquee (reusable) ---------- */
.marquee { overflow: hidden; white-space: nowrap; display: flex; }
.marquee__track { display: inline-flex; gap: 2rem; padding-right: 2rem; animation: marq 28s linear infinite; }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marq { to { transform: translateX(-50%); } }

/* ---------- Utility ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.grad-blob { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .5; pointer-events: none; z-index: 0; }
.noise { position: fixed; inset: 0; pointer-events: none; z-index: 1; opacity: .035; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
