/* ============================================
   ProductNation creator storefront.
   PREMIUM TECH MEDIA. Deep near-black canvas, hairline rules,
   a faint CSS grain, refined easing, a single near-white accent.
   Reference mood: a confident global tech-media brand. Clean, modern, intentional.

   Mobile-first, designed at 390px. Desktop = centered app column.
   Plain vanilla CSS. No framework, no build step.
   Type: Space Grotesk (display, loaded via one Google Fonts link) + system sans body.
   ============================================ */

:root {
  /* ---- Palette (documented in AGENTS.md) ---- */
  --bg: #08090A;              /* deep near-black canvas */
  --bg-2: #0C0D0F;            /* a half-step up, for inset bands */
  --surface: #101113;         /* card surface, barely lifted off black */
  --surface-2: #15171A;       /* nested / pressed surface */
  --text: #F2F1ED;            /* near-white, the brand ink */
  --muted: #8A8C90;           /* secondary text */
  --faint: #5A5C61;           /* tertiary / hints */
  --line: #1C1E22;            /* hairline borders */
  --line-strong: #2A2D33;     /* slightly stronger hairline */
  /* MONOCHROME: white is the single accent, used sparingly on the near-black base. */
  --accent: #F2F1ED;          /* near-white accent */
  --accent-soft: rgba(242, 241, 237, 0.08);
  --accent-line: rgba(242, 241, 237, 0.28);
  --accent-ink: #08090A;      /* near-black ink that reads on the light accent */

  /* ---- Radius scale (tighter, more architectural) ---- */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-pill: 999px;

  /* ---- Spacing scale ---- */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 36px;
  --space-7: 56px;

  /* ---- Type ---- */
  --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font: -apple-system, BlinkMacSystemFont, 'Inter', 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --fs-xs: 11.5px;
  --fs-sm: 13px;
  --fs-md: 15px;
  --fs-lg: 19px;
  --fs-xl: 25px;
  --fs-2xl: 34px;
  --lh: 1.6;

  /* eyebrow / label tracking */
  --track-wide: 0.18em;

  /* ---- App column width on desktop ---- */
  --app-max: 480px;

  /* ---- Height reserved for the fixed bottom nav (plus safe area added inline) ---- */
  --nav-h: 64px;

  /* ---- Cinematic easing ---- */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

/* The hidden attribute must always win, even over component display rules.
   This keeps the logo-fallback wordmark truly hidden once /logo.png loads. */
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: var(--lh);
  font-size: var(--fs-md);
  -webkit-overflow-scrolling: touch;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  position: relative;
}

/* ---- Faint CSS film grain (pure CSS, very low opacity, no image request) ---- */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.035;
  /* Layered repeating gradients form a fine, animated-free static grain field. */
  background-image:
    repeating-radial-gradient(circle at 17% 33%, rgba(255,255,255,0.9) 0, rgba(255,255,255,0.9) 0.4px, transparent 0.5px, transparent 2.4px),
    repeating-radial-gradient(circle at 71% 68%, rgba(255,255,255,0.7) 0, rgba(255,255,255,0.7) 0.4px, transparent 0.5px, transparent 3.1px),
    repeating-radial-gradient(circle at 44% 91%, rgba(255,255,255,0.6) 0, rgba(255,255,255,0.6) 0.3px, transparent 0.5px, transparent 2.7px);
  mix-blend-mode: screen;
}
/* very subtle top-light vignette, like a projector throw */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(120% 80% at 50% -10%, rgba(242,241,237,0.04) 0%, transparent 55%);
}

/* keep real content above the grain/vignette layers */
.wrap, .bottom-nav, .login-wrap { position: relative; z-index: 2; }

/* The whole app lives in a centered column, like a phone app on desktop. */
.wrap {
  width: 100%;
  max-width: var(--app-max);
  margin: 0 auto;
  padding:
    calc(env(safe-area-inset-top, 0px) + var(--space-5))
    var(--space-5)
    calc(var(--nav-h) + env(safe-area-inset-bottom, 0px) + var(--space-6))
    var(--space-5);
  min-height: 100vh;
}

/* On wide screens, frame the app column with hairline edges so it reads as an app. */
@media (min-width: 600px) {
  .wrap {
    border-left: 1px solid var(--line);
    border-right: 1px solid var(--line);
    min-height: 100vh;
  }
}

/* ---- Entrance: a quiet, cinematic fade-and-rise on load ---- */
@keyframes rise-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}
.wrap > * {
  animation: rise-in 0.7s var(--ease-out) both;
}
.wrap > *:nth-child(2) { animation-delay: 0.06s; }
.wrap > *:nth-child(3) { animation-delay: 0.12s; }
.wrap > *:nth-child(4) { animation-delay: 0.18s; }
.wrap > *:nth-child(5) { animation-delay: 0.24s; }
.wrap > *:nth-child(6) { animation-delay: 0.30s; }

/* ============================================
   Typography
   ============================================ */
h1, h2, h3 {
  font-family: var(--font-display);
  font-optical-sizing: auto;
  color: var(--text);
}
h1 { font-size: var(--fs-xl); font-weight: 500; letter-spacing: -0.01em; margin-bottom: var(--space-3); line-height: 1.12; }
h2 { font-size: var(--fs-lg); font-weight: 500; letter-spacing: -0.005em; margin-bottom: var(--space-4); line-height: 1.2; }
h3 { font-size: var(--fs-md); font-weight: 600; font-family: var(--font); letter-spacing: 0.01em; margin-bottom: var(--space-2); }
p { color: var(--text); }
a { color: var(--accent); text-decoration: none; }

.sub { color: var(--muted); font-size: var(--fs-sm); margin-bottom: var(--space-4); line-height: 1.65; }
.meta { color: var(--muted); font-size: var(--fs-xs); font-weight: 500; }
.hint { color: var(--faint); font-size: var(--fs-xs); margin-top: var(--space-2); }

/* Eyebrow label: tiny tracked-out caps with a hairline. A core cinematic motif. */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: var(--track-wide);
  text-transform: uppercase;
  color: var(--faint);
  margin-bottom: var(--space-3);
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--line-strong);
}

ul { padding-left: 1.1em; }
li { margin-bottom: var(--space-2); color: var(--text); }

/* Thin letterbox rule, used to separate sections with cinematic restraint. */
.rule {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line-strong) 18%, var(--line-strong) 82%, transparent);
  border: none;
  margin: var(--space-5) 0;
}

/* Inline line-icons: consistent thin-stroke, 24 grid, currentColor. */
.icon {
  display: inline-block;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  vertical-align: middle;
}

/* ============================================
   HUB (storefront landing)
   ============================================ */
.hub { text-align: left; }

.hub-profile {
  padding: var(--space-6) 0 var(--space-6);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.hub-avatar {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: radial-gradient(120% 120% at 32% 26%, #1B1D21 0%, #0C0D0F 72%);
  border: 1px solid var(--line-strong);
  box-shadow: 0 0 0 1px rgba(242,241,237,0.08), 0 10px 30px -12px rgba(0,0,0,0.8);
  margin-bottom: var(--space-4);
  position: relative;
  overflow: hidden;
}
/* When a profile/logo image is dropped into .hub-avatar later, it fills the round mark. */
.hub-avatar .brand-logo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 10px;
  border-radius: 50%;
}
/* aperture mark inside the avatar, drawn in pure CSS (hidden once an image loads) */
.hub-avatar:has(.brand-logo)::after { display: none; }
.hub-avatar::after {
  content: "";
  position: absolute;
  inset: 24px;
  border-radius: 50%;
  border: 1px solid var(--accent-line);
}
.hub-name {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: var(--space-2);
}
/* Hub brand logo slot: when /logo.svg exists it renders here at wordmark height,
   otherwise its onerror reveals the .hub-name wordmark. */
.hub-logo {
  display: block;
  height: 34px;
  width: auto;
  max-width: 240px;
  margin-bottom: var(--space-2);
}
.hub-bio { color: var(--muted); font-size: var(--fs-sm); max-width: 34ch; line-height: 1.6; }

.hub-grid {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-top: var(--space-2);
}

.product-card {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  color: var(--text);
  text-decoration: none;
  transition: transform 0.4s var(--ease-out), border-color 0.4s var(--ease-out), background 0.4s var(--ease-out);
  min-height: 76px;
  position: relative;
  overflow: hidden;
}
/* thin top hairline highlight, like light catching an edge */
.product-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.05), transparent);
}
.product-card:hover {
  border-color: var(--line-strong);
  background: var(--surface-2);
}
.product-card:active {
  transform: scale(0.99);
  background: var(--surface-2);
}

/* Glyph tile holds an inline SVG line-icon. Also used for JS-injected emoji
   (library.js): we hide any text glyph and draw an icon via mask instead. */
.product-emoji {
  flex-shrink: 0;
  width: 46px; height: 46px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  color: var(--accent);
}
.product-emoji .icon { width: 22px; height: 22px; }
/* When library.js injects an emoji character into .product-emoji, suppress the
   emoji and render a consistent line-icon via mask so the page stays icon-pure. */
.product-emoji:not(:has(.icon)) {
  font-size: 0;
  color: transparent;
}
.product-emoji:not(:has(.icon))::after {
  content: "";
  width: 22px; height: 22px;
  background: var(--accent);
  -webkit-mask: var(--icon-package) center / contain no-repeat;
  mask: var(--icon-package) center / contain no-repeat;
}

.product-title {
  flex: 1;
  font-weight: 600;
  font-size: var(--fs-md);
  letter-spacing: -0.005em;
}
.product-price {
  color: var(--muted);
  font-size: var(--fs-sm);
  font-weight: 500;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.product-cta {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  color: var(--accent);
  font-weight: 600;
  font-size: var(--fs-sm);
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--accent-line);
  border-radius: var(--radius-pill);
  transition: background 0.3s var(--ease-out);
}
.product-card:hover .product-cta { background: var(--accent-soft); }

/* "Coming soon" cards read as quiet and inert */
.product-soon { opacity: 0.5; cursor: default; }
.product-soon:hover { border-color: var(--line); background: var(--surface); }
.product-soon:active { transform: none; background: var(--surface); }
.product-soon .product-title { color: var(--muted); }
.product-soon .product-emoji { color: var(--faint); }

/* ============================================
   PRODUCT / SALES PAGE (LUT, course)
   ============================================ */
.hero {
  padding: var(--space-6) 0 var(--space-5);
  text-align: left;
}
.hero h1 { font-size: var(--fs-2xl); line-height: 1.08; margin-bottom: var(--space-4); font-weight: 400; }
.hero .sub { font-size: var(--fs-md); max-width: 36ch; margin: 0 0 var(--space-5); line-height: 1.62; }
.hero .product-price {
  display: block;
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  color: var(--text);
  margin-bottom: var(--space-4);
  font-weight: 500;
}

/* Primary CTA: a confident, full-width brass action. */
.cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  width: 100%;
  text-align: center;
  background: var(--accent);
  color: var(--accent-ink);
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: var(--fs-md);
  letter-spacing: 0.01em;
  text-decoration: none;
  border: none;
  cursor: pointer;
  min-height: 54px;
  transition: transform 0.3s var(--ease-out), filter 0.3s var(--ease-out);
}
.cta:hover { filter: brightness(1.06); }
.cta:active { transform: scale(0.985); filter: brightness(0.96); }
.cta .icon { width: 18px; height: 18px; stroke-width: 1.75; }

.cta-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  width: 100%;
  text-align: center;
  background: transparent;
  color: var(--text);
  padding: var(--space-3) var(--space-5);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: var(--fs-sm);
  text-decoration: none;
  min-height: 50px;
  cursor: pointer;
  transition: transform 0.3s var(--ease-out), background 0.3s var(--ease-out), border-color 0.3s var(--ease-out);
}
.cta-secondary:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.cta-secondary:active { transform: scale(0.985); }
.cta-secondary .icon { width: 18px; height: 18px; }

/* ---- Slot counter (urgency, kept understated) ---- */
.slot-counter {
  padding: var(--space-4) 0 var(--space-5);
  text-align: left;
}
.slot-bar {
  width: 100%;
  height: 3px;
  background: var(--line);
  border-radius: var(--radius-pill);
  overflow: hidden;
  margin-bottom: var(--space-3);
}
.slot-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), rgba(242,241,237,0.55));
  width: 0%;
  transition: width 0.8s var(--ease-out);
}
.slot-text, #slot-text { font-size: var(--fs-sm); color: var(--muted); font-weight: 500; }
#slot-text strong { color: var(--accent); font-weight: 600; }
#price-label { color: var(--accent); font-weight: 600; }

/* ---- Features / reviews ---- */
.features, .reviews {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  margin-bottom: var(--space-4);
}
.features ul { list-style: none; padding: 0; }
.features li {
  position: relative;
  padding-left: 28px;
  color: var(--text);
  font-size: var(--fs-sm);
  line-height: 1.55;
  margin-bottom: var(--space-3);
}
.features li:last-child { margin-bottom: 0; }
/* hairline check mark drawn in pure CSS */
.features li::before {
  content: "";
  position: absolute;
  left: 2px; top: 6px;
  width: 6px; height: 10px;
  border: solid var(--accent);
  border-width: 0 1.5px 1.5px 0;
  transform: rotate(40deg);
}
.reviews { color: var(--muted); }

/* ---- Checkout (Pattern A + B) ---- */
.checkout {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  margin-bottom: var(--space-4);
}

.checkout-trust {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  margin: var(--space-4) 0;
  padding: var(--space-4);
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}
.trust-item-row { display: flex; gap: var(--space-3); align-items: flex-start; }
.trust-icon-circle {
  flex-shrink: 0;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px solid var(--line-strong);
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--accent);
}
.trust-icon-circle .icon { width: 19px; height: 19px; }
.trust-item-row strong { display: block; font-size: var(--fs-sm); font-weight: 600; color: var(--text); }
.trust-sub { font-size: var(--fs-xs); color: var(--muted); margin-top: 3px; line-height: 1.5; }
.trust-sub a { color: var(--accent); }

.checkout-social-proof {
  display: flex; align-items: center; gap: var(--space-3);
  margin: 0 0 var(--space-4);
  padding: var(--space-3) var(--space-4);
  background: var(--accent-soft);
  border: 1px solid var(--line);
  border-left: 2px solid var(--accent);
  border-radius: var(--radius-sm);
  font-size: var(--fs-sm);
  color: var(--text);
  font-weight: 500;
}
.dot-pulse {
  flex-shrink: 0;
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
  animation: dot-pulse 2.4s ease-out infinite;
}
@keyframes dot-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(242,241,237,0.45); }
  70%  { box-shadow: 0 0 0 9px rgba(242,241,237,0); }
  100% { box-shadow: 0 0 0 0 rgba(242,241,237,0); }
}

/* Stripe Embedded Checkout mount point. */
#stripe-checkout {
  min-height: 60px;
  border-radius: var(--radius-md);
  overflow: hidden;
}

/* ---- Telegram CTA (Pattern O) ---- */
.telegram-cta {
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  margin-bottom: var(--space-4);
}
.telegram-cta p { color: var(--muted); font-size: var(--fs-sm); margin-bottom: var(--space-4); }

/* ---- Footer ---- */
footer, .footer {
  text-align: left;
  color: var(--faint);
  font-size: var(--fs-xs);
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  border-top: 1px solid var(--line);
  letter-spacing: 0.01em;
}
footer a, .footer a { color: var(--muted); transition: color 0.3s var(--ease-out); }
footer a:hover, .footer a:hover, footer a:active, .footer a:active { color: var(--accent); }

/* ============================================
   BOTTOM TAB BAR (app shell nav)
   ============================================ */
.bottom-nav {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: 100%;
  max-width: var(--app-max);
  display: flex;
  background: rgba(8, 9, 10, 0.78);
  backdrop-filter: saturate(160%) blur(18px);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  z-index: 50;
}
@media (min-width: 600px) {
  .bottom-nav { border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
}
.nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 58px;
  padding: var(--space-2) 0;
  color: var(--faint);
  text-decoration: none;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: color 0.35s var(--ease-out), transform 0.2s var(--ease-out);
}
.nav-item:active { transform: scale(0.94); }
.nav-icon { display: inline-flex; }
.nav-icon .icon { width: 22px; height: 22px; }
.nav-item.active { color: var(--accent); }

/* Brand mark lives inside the nav markup. Hidden on mobile (the bottom tab bar
   has no brand); revealed as the left-aligned brand on the desktop top nav. */
.nav-brand { display: none; }

/* ============================================
   OWNER DASHBOARD
   ============================================ */
.section {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  margin-bottom: var(--space-4);
}
.cards { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-2); margin-bottom: var(--space-4); }
@media (min-width: 600px) { .cards { grid-template-columns: repeat(3, 1fr); } }
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: var(--space-3);
}
.card .label { font-size: var(--fs-xs); font-weight: 600; text-transform: uppercase; color: var(--muted); letter-spacing: var(--track-wide); }
.card .value { font-family: var(--font-display); font-size: var(--fs-xl); font-weight: 500; margin-top: var(--space-1); color: var(--text); font-variant-numeric: tabular-nums; }
.card .sub-value { font-size: var(--fs-xs); color: var(--muted); margin-top: 2px; }

/* dashboard heading uses display face but stays compact */
.wrap > h1 { font-family: var(--font-display); }

/* Tab bar (dashboard) */
.tab-bar {
  display: flex; gap: 0;
  background: var(--surface);
  padding: var(--space-1);
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  margin-bottom: var(--space-4);
  position: sticky;
  top: calc(env(safe-area-inset-top, 0px) + var(--space-2));
  z-index: 20;
}
.tab-bar button {
  flex: 1; padding: var(--space-3);
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  background: transparent; border: none; border-radius: var(--radius-sm);
  font-size: var(--fs-sm); font-weight: 600; color: var(--muted); cursor: pointer;
  min-height: 44px;
  transition: background 0.3s var(--ease-out), color 0.3s var(--ease-out);
}
.tab-bar button .icon { width: 18px; height: 18px; }
.tab-bar button.active { background: var(--accent); color: var(--accent-ink); }

[data-tab="content"], [data-tab="admin"] { display: none; }
body.tab-content [data-tab="today"] { display: none; }
body.tab-content [data-tab="content"] { display: block; }
body.tab-admin [data-tab="today"] { display: none; }
body.tab-admin [data-tab="admin"] { display: block; }
body.tab-content .period-bar, body.tab-admin .period-bar,
body.tab-content .metric-cards, body.tab-admin .metric-cards { display: none; }

/* Period bar */
.period-bar {
  display: flex; gap: var(--space-1);
  background: var(--surface);
  padding: var(--space-1);
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  margin-bottom: var(--space-4);
  overflow-x: auto;
}
.period-bar button {
  flex: 1; padding: var(--space-2) var(--space-3);
  background: transparent; border: none;
  border-radius: var(--radius-sm); font-size: var(--fs-sm); font-weight: 500;
  color: var(--muted); cursor: pointer; white-space: nowrap; min-height: 40px;
  transition: background 0.3s var(--ease-out), color 0.3s var(--ease-out);
}
.period-bar button.active { background: var(--accent); color: var(--accent-ink); font-weight: 600; }

/* Tiers */
.tier { border-radius: var(--radius-sm); padding: var(--space-3) var(--space-4); margin-bottom: var(--space-3); border: 1px solid var(--line); background: var(--surface-2); }
.tier summary { font-weight: 600; cursor: pointer; color: var(--text); }
.tier-1 { border-color: var(--accent-line); }
.tier-1 summary { color: var(--accent); }
.tier-2 summary { color: var(--text); }
.tier-3 summary { color: var(--muted); }

/* Tables */
table { width: 100%; border-collapse: collapse; }
th, td { padding: var(--space-2) var(--space-3); text-align: left; font-size: var(--fs-sm); border-bottom: 1px solid var(--line); color: var(--text); }
th { color: var(--muted); font-size: var(--fs-xs); font-weight: 600; text-transform: uppercase; letter-spacing: var(--track-wide); }
td.right, th.right { text-align: right; font-variant-numeric: tabular-nums; }
.empty { color: var(--muted); font-style: italic; text-align: center; }

.chart-wrap { position: relative; width: 100%; }

/* Login gate */
.login-wrap {
  max-width: 360px; margin: 80px auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: var(--space-5);
}
.login-wrap h1 { display: flex; align-items: center; gap: var(--space-2); }
.login-wrap h1 .icon { width: 22px; height: 22px; color: var(--accent); }
.login-wrap input {
  width: 100%; padding: var(--space-3);
  background: var(--bg); color: var(--text);
  border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  margin: var(--space-3) 0;
}
.login-wrap input:focus { outline: none; border-color: var(--accent); }
.login-wrap button {
  width: 100%; padding: var(--space-3);
  background: var(--accent); color: var(--accent-ink);
  border: none; border-radius: var(--radius-sm); font-weight: 700; cursor: pointer;
  min-height: 44px;
  transition: filter 0.3s var(--ease-out);
}
.login-wrap button:hover { filter: brightness(1.06); }
.login-error { color: #E08C8C; font-size: var(--fs-sm); margin-top: var(--space-2); }

.health { display: flex; flex-direction: column; gap: var(--space-2); }
.orders-list { display: flex; flex-direction: column; gap: var(--space-2); }
.order-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: var(--space-3);
  font-size: var(--fs-sm);
}

/* ============================================
   COURSE (sales page curriculum + preview player)
   ============================================ */
.course-player { margin-bottom: var(--space-5); }
.video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
/* faint letterbox bars top and bottom of the preview frame */
.video-frame::before, .video-frame::after {
  content: "";
  position: absolute; left: 0; right: 0;
  height: 7%;
  background: rgba(0,0,0,0.55);
  pointer-events: none;
  z-index: 1;
}
.video-frame::before { top: 0; }
.video-frame::after { bottom: 0; }
.video-frame iframe { position: relative; z-index: 2; }

.video-play {
  position: relative;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  background: rgba(8,9,10,0.55);
  color: var(--text);
  border: 1px solid var(--accent-line);
  font-weight: 600;
  font-size: var(--fs-sm);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-pill);
  cursor: pointer;
  min-height: 48px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: background 0.3s var(--ease-out), transform 0.3s var(--ease-out);
}
.video-play::before {
  content: "";
  width: 30px; height: 30px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  background: var(--icon-play) center / 13px no-repeat;
  -webkit-mask: none;
}
.video-play:hover { background: rgba(8,9,10,0.75); }
.video-play:active { transform: scale(0.97); }

.meta.video-label, .course-player .meta { color: var(--muted); margin-top: var(--space-3); }

.unit { margin-bottom: var(--space-5); }
.unit:last-child { margin-bottom: 0; }
.unit-title {
  font-family: var(--font);
  font-weight: 600; font-size: var(--fs-xs);
  text-transform: uppercase; letter-spacing: var(--track-wide);
  color: var(--faint); margin-bottom: var(--space-3);
}
.lesson-list { list-style: none; padding: 0; margin: 0; }
.lesson-row {
  display: flex; align-items: center; gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--line);
}
.lesson-row:last-child { border-bottom: none; }
.lesson-num {
  flex-shrink: 0; width: 26px; height: 26px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: var(--fs-xs); font-weight: 600; color: var(--muted);
  background: var(--bg-2); border: 1px solid var(--line-strong); border-radius: 50%;
  font-variant-numeric: tabular-nums;
}
.lesson-name { flex: 1; font-size: var(--fs-sm); color: var(--text); }
.lesson-dur { font-size: var(--fs-xs); color: var(--faint); white-space: nowrap; font-variant-numeric: tabular-nums; }

/* lesson-lock holds a JS-injected lock emoji; render a line padlock via mask. */
.lesson-lock {
  display: inline-flex;
  width: 16px; height: 16px;
  font-size: 0; color: transparent;
  flex-shrink: 0;
}
.lesson-lock::after {
  content: "";
  width: 15px; height: 15px;
  background: var(--faint);
  -webkit-mask: var(--icon-lock) center / contain no-repeat;
  mask: var(--icon-lock) center / contain no-repeat;
}
.lesson-free {
  font-size: 10px; font-weight: 600; color: var(--accent);
  text-transform: uppercase; letter-spacing: 0.1em;
  border: 1px solid var(--accent-line);
  background: var(--accent-soft);
  padding: 2px var(--space-2); border-radius: var(--radius-pill);
}
.lesson-freerow .lesson-name { color: var(--text); }

/* ============================================
   LEARN (course player) + ACCOUNT + LIBRARY
   ============================================ */
.learn-head { padding: var(--space-4) 0 var(--space-4); }
.back-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: var(--fs-xs); color: var(--muted);
  margin-bottom: var(--space-3);
  text-transform: uppercase; letter-spacing: 0.08em; font-weight: 600;
}
.back-link::before {
  content: "";
  width: 14px; height: 14px;
  background: var(--muted);
  -webkit-mask: var(--icon-arrow-left) center / contain no-repeat;
  mask: var(--icon-arrow-left) center / contain no-repeat;
  transition: background 0.3s var(--ease-out);
}
.back-link:hover, .back-link:active { color: var(--accent); }
.back-link:hover::before, .back-link:active::before { background: var(--accent); }

.learn-controls { display: flex; gap: var(--space-2); margin: var(--space-4) 0; }
.learn-controls .cta-secondary { flex: 1; }

.progress-row { display: flex; align-items: center; gap: var(--space-3); margin-bottom: var(--space-4); }
.progress-row .slot-bar { flex: 1; margin-bottom: 0; }

.lessons-wrap { margin-bottom: var(--space-5); }
.lesson-clickable { cursor: pointer; border-radius: var(--radius-sm); transition: background 0.3s var(--ease-out); }
.lesson-clickable:hover { background: var(--surface); }
.lesson-clickable:active { background: var(--surface-2); }
.lesson-row.active { background: var(--accent-soft); border-radius: var(--radius-sm); padding-left: var(--space-3); border-bottom-color: transparent; }
.lesson-row.active .lesson-name { color: var(--accent); font-weight: 600; }
.lesson-done .lesson-num { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

.account-form { display: flex; flex-direction: column; gap: var(--space-3); }
.account-form input {
  width: 100%; padding: var(--space-4);
  background: var(--bg-2); color: var(--text);
  border: 1px solid var(--line-strong); border-radius: var(--radius-md);
  font-size: var(--fs-md); min-height: 54px;
}
.account-form input:focus { outline: none; border-color: var(--accent); }
.account-form input::placeholder { color: var(--faint); }

/* ============================================
   Icon source tokens (SVG data URIs used by mask/background)
   Thin-stroke, 24 grid, currentColor look (drawn white, recolored via mask).
   ============================================ */
:root {
  --icon-package: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="%23ffffff" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M12 2 3 7v10l9 5 9-5V7z"/><path d="M3 7l9 5 9-5"/><path d="M12 12v10"/></svg>');
  --icon-lock: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="%23ffffff" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><rect x="5" y="11" width="14" height="10" rx="2"/><path d="M8 11V7a4 4 0 0 1 8 0v4"/></svg>');
  --icon-arrow-left: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="%23ffffff" stroke-width="1.6" stroke-linecap="round" stroke-linejoin="round"><path d="M15 5l-7 7 7 7"/></svg>');
  --icon-play: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="%23F2F1ED" stroke-width="1.6" stroke-linecap="round" stroke-linejoin="round"><path d="M9 7l9 5-9 5z"/></svg>');
  --icon-aperture: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="%23F2F1ED" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="9"/><circle cx="12" cy="12" r="3.5"/></svg>');
}

/* ============================================
   DESKTOP + TABLET LAYOUT (additive, min-width only)
   Mobile-first base above stays untouched. Everything below lives in
   min-width media queries, so narrow widths render exactly as before.
   Reference mood for desktop: a cinematic, editorial layout, not a
   stretched phone. Wider centered canvas, top header nav, multi-area pages.
   ============================================ */

/* ---- TABLET (a gentle mid step before full desktop) ---- */
@media (min-width: 768px) {
  :root { --app-max: 680px; }

  .hero h1 { font-size: 40px; }
  .hero .sub { max-width: 44ch; }

  /* product cards relax into a two-up grid on tablet */
  .hub-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-4);
  }
}

/* ============================================
   DESKTOP (>= 1024px): the real layout
   ============================================ */
@media (min-width: 1024px) {
  :root {
    --app-max: 1140px;
    /* height reserved for the desktop top header */
    --topnav-h: 72px;
  }

  /* ---- Wider, cinematic canvas. Drop the phone-column side rules. ---- */
  .wrap {
    max-width: var(--app-max);
    border-left: none;
    border-right: none;
    padding-top: calc(var(--topnav-h) + var(--space-7));
    padding-left: var(--space-6);
    padding-right: var(--space-6);
    padding-bottom: var(--space-7);
  }
  /* a page WITHOUT the app top nav (the owner dashboard) keeps a normal top */
  body:not(:has(.bottom-nav)) .wrap { padding-top: var(--space-6); }

  /* ---- Top navigation bar: reuse the .bottom-nav markup, restyled. ---- */
  body:has(.bottom-nav) { /* anchor for header offset, nothing visual */ }

  .bottom-nav {
    top: 0;
    bottom: auto;
    left: 0;
    right: 0;
    transform: none;
    width: 100%;
    max-width: none;
    height: var(--topnav-h);
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: var(--space-2);
    padding: 0 var(--space-6);
    border-top: none;
    border-bottom: 1px solid var(--line);
    background: rgba(8, 9, 10, 0.72);
    backdrop-filter: saturate(160%) blur(20px);
    -webkit-backdrop-filter: saturate(160%) blur(20px);
  }
  /* brand mark on the left of the header. Real logo-image slot with a
     graceful fallback to the "ProductNation" wordmark text (see .brand-logo). */
  .bottom-nav .nav-brand {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    margin-right: auto;
    text-decoration: none;
  }
  .bottom-nav .nav-brand .brand-logo {
    display: block;
    height: 26px;
    width: auto;
    max-width: 200px;
  }
  .bottom-nav .nav-brand .brand-wordmark {
    display: inline-flex;
    align-items: center;
    font-family: var(--font-display);
    font-size: var(--fs-lg);
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--text);
  }

  /* nav links become horizontal pill-style top links, not stacked tab icons */
  .bottom-nav .nav-item {
    flex: 0 0 auto;
    flex-direction: row;
    gap: var(--space-2);
    min-height: 40px;
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-pill);
    font-size: var(--fs-xs);
    letter-spacing: 0.08em;
    transition: color 0.3s var(--ease-out), background 0.3s var(--ease-out);
  }
  .bottom-nav .nav-item:hover { color: var(--text); background: var(--surface-2); }
  .bottom-nav .nav-item:active { transform: none; }
  .bottom-nav .nav-item.active { color: var(--accent); background: var(--accent-soft); }
  .bottom-nav .nav-icon .icon { width: 18px; height: 18px; }

  /* ---- HUB: larger profile + responsive card grid ---- */
  .hub-profile {
    padding: var(--space-7) 0 var(--space-6);
    align-items: center;
    text-align: center;
  }
  .hub-profile .eyebrow::before { display: none; }
  .hub-avatar { width: 96px; height: 96px; margin-bottom: var(--space-5); }
  .hub-avatar::after { inset: 32px; }
  .hub-name { font-size: var(--fs-2xl); }
  .hub-logo { height: 46px; }
  .hub-bio { max-width: 48ch; text-align: center; font-size: var(--fs-md); }

  .hub-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: var(--space-4);
    max-width: 900px;
    margin: var(--space-5) auto 0;
  }
  /* substantial, vertically-set cards that do not look stretched */
  .hub .product-card {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-4);
    min-height: 168px;
    padding: var(--space-5);
  }
  .hub .product-card .product-emoji { width: 54px; height: 54px; }
  .hub .product-card .product-emoji .icon { width: 26px; height: 26px; }
  .hub .product-card .product-title { flex: 0 0 auto; font-size: var(--fs-lg); }
  .hub .product-card .product-price { align-self: flex-start; }
  .hub .product-card .product-cta { margin-top: auto; align-self: flex-start; }
  .hub .product-card:hover { transform: translateY(-3px); }

  /* ---- SALES PAGES (course, lut): a two-area cinematic layout ---- */
  .hero { padding: var(--space-7) 0 var(--space-6); max-width: 60ch; }
  .hero h1 { font-size: 52px; line-height: 1.04; }
  .hero .sub { font-size: var(--fs-lg); max-width: 50ch; }

  /* COURSE: hero/preview + curriculum on the left, checkout column on the right */
  body:has(#curriculum) .wrap {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(340px, 1fr);
    column-gap: var(--space-7);
    align-items: start;
  }
  body:has(#curriculum) .hero { grid-column: 1 / -1; }
  body:has(#curriculum) .course-player,
  body:has(#curriculum) #curriculum-section,
  body:has(#curriculum) .slot-counter { grid-column: 1; }
  /* checkout rides the right column and stays in view as you read */
  body:has(#curriculum) #buy {
    grid-column: 2;
    grid-row: 2 / span 6;
    position: sticky;
    top: calc(var(--topnav-h) + var(--space-5));
  }
  body:has(#curriculum) footer { grid-column: 1 / -1; }

  /* LUT page: keep a comfortable reading column, do not stretch full width */
  body:has(.telegram-cta) .wrap { max-width: 720px; }

  /* the entrance stagger fights a grid; keep it simple/quick on desktop */
  .wrap > * { animation-duration: 0.5s; }

  /* ---- LEARN PLAYER: ysjf split. Player left, lesson rail right. ---- */
  .learn-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
    gap: var(--space-6);
    align-items: start;
  }
  .learn-stage { min-width: 0; }
  .learn-rail {
    position: sticky;
    top: calc(var(--topnav-h) + var(--space-5));
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    max-height: calc(100vh - var(--topnav-h) - var(--space-6));
  }
  .learn-rail .learn-controls { margin: 0; flex-direction: column; }
  .learn-rail .progress-row { margin: 0; }
  /* the lesson list scrolls inside the rail like a real player side panel */
  .learn-rail .lessons-wrap {
    margin-bottom: 0;
    overflow-y: auto;
    padding-right: var(--space-2);
  }
  /* learn page wrap is a focused stage, not full 1140 */
  body:has(.learn-grid) .wrap { max-width: 1180px; }

  /* ---- ACCOUNT + LIBRARY: intentional centered columns ---- */
  /* Account: a single, centered, comfortable column (the .wrap centers via margin auto). */
  body:has(#login-card) .wrap { max-width: 560px; text-align: center; }
  body:has(#login-card) .hero { max-width: none; }
  body:has(#login-card) .checkout { text-align: left; }
  /* Library: a centered area with a responsive card grid. */
  body:has(#library) .wrap { max-width: 880px; }
  body:has(#library) .hub-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    max-width: none;
    margin-top: var(--space-5);
  }
}

/* ============================================
   LUT LANDING: conversion sections (additive)
   Mobile-first. Lives within the centered app column. Monochrome system.
   ============================================ */

/* hero supporting bits */
.hero-proof { display: flex; align-items: center; gap: var(--space-2); margin: 0 0 var(--space-4); flex-wrap: wrap; }
.stars { color: var(--accent); letter-spacing: 2px; font-size: var(--fs-sm); }
.hero-proof .meta { max-width: 40ch; }
.hero-micro { color: var(--faint); font-size: var(--fs-xs); margin-top: var(--space-3); letter-spacing: 0.01em; }

/* hero product mockup: sits on its own light render bg inside a framed card,
   with a soft glow so it reads as an intentional product shot on the dark page */
.hero-mockup {
  margin: var(--space-5) 0 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line-strong);
  box-shadow: 0 30px 80px -40px rgba(0,0,0,0.9);
  position: relative;
}
.hero-mockup img { display: block; width: 100%; height: auto; }

/* payment card: frame the white Stripe module so it reads as a deliberate
   secure-checkout card rather than an abrupt white block on the dark page */
.pay-card {
  background: #ffffff;
  border-radius: var(--radius-md);
  padding: var(--space-2);
  border: 1px solid var(--line-strong);
  box-shadow: 0 20px 50px -30px rgba(0,0,0,0.85);
  overflow: hidden;
}
.pay-card-head {
  display: flex; align-items: center; gap: var(--space-2);
  padding: var(--space-2) var(--space-3) var(--space-3);
  font-size: var(--fs-xs); font-weight: 700; letter-spacing: var(--track-wide);
  text-transform: uppercase; color: #6b7280;
}
.pay-card-head .icon { width: 15px; height: 15px; stroke: #6b7280; }
.pay-card #stripe-checkout { min-height: 60px; }

/* shared section heading spacing for the new bands */
.ba-showcase, .why, .steps, .proof-band, .faq, .testimonials { margin-bottom: var(--space-6); }
.ba-showcase > .sub, .why > .sub { max-width: 42ch; }

/* before / after showcase */
.ba-frame { margin: 0 0 var(--space-3); }
.ba-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line-strong);
  background: #000;
}
.ba-frame figcaption { margin-top: var(--space-2); }

/* why band */
.why h2 { max-width: 24ch; }

/* steps */
.step-list { list-style: none; padding: 0; margin: var(--space-4) 0 0; display: flex; flex-direction: column; gap: var(--space-3); }
.step-list li {
  display: flex; gap: var(--space-3); align-items: flex-start;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-md); padding: var(--space-4); margin: 0;
}
.step-list li > div { display: flex; flex-direction: column; gap: 3px; }
.step-list strong { font-size: var(--fs-sm); font-weight: 600; color: var(--text); }
.step-num {
  flex-shrink: 0; width: 30px; height: 30px;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 600; font-size: var(--fs-sm);
  color: var(--accent-ink); background: var(--accent);
  border-radius: 50%; font-variant-numeric: tabular-nums;
}

/* proof band */
.proof-band {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
}
.proof-band h2 { max-width: 26ch; }
.proof-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-3); margin: var(--space-4) 0; }
.proof-stat { display: flex; flex-direction: column; gap: 2px; text-align: left; }
.proof-num { font-family: var(--font-display); font-size: var(--fs-xl); font-weight: 600; color: var(--text); letter-spacing: -0.01em; }

/* checkout price recap */
.buy-price { margin: 0 0 var(--space-4); display: flex; align-items: baseline; gap: var(--space-2); }
.buy-price .product-price { display: inline; font-family: var(--font-display); font-size: var(--fs-lg); font-weight: 600; color: var(--text); }

/* testimonials (revealed once real quotes exist) */
.review-grid { display: flex; flex-direction: column; gap: var(--space-3); margin-top: var(--space-4); }
.review-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); padding: var(--space-4); }
.review-stars { color: var(--accent); letter-spacing: 2px; font-size: var(--fs-sm); margin-bottom: var(--space-2); }
.review-text { font-size: var(--fs-sm); line-height: 1.6; color: var(--text); margin-bottom: var(--space-3); }
.review-author { font-size: var(--fs-xs); color: var(--muted); font-weight: 600; }

/* review submission form (account page) */
.review-form { display: flex; flex-direction: column; gap: var(--space-3); }
.review-form input, .review-form textarea {
  width: 100%; padding: var(--space-3);
  background: var(--bg-2); color: var(--text);
  border: 1px solid var(--line-strong); border-radius: var(--radius-md);
  font-size: var(--fs-md); font-family: var(--font);
}
.review-form input:focus, .review-form textarea:focus { outline: none; border-color: var(--accent); }
.review-form textarea { resize: vertical; min-height: 90px; }
.star-pick { display: flex; gap: 4px; }
.star-btn {
  background: none; border: none; cursor: pointer;
  font-size: 28px; line-height: 1; color: var(--line-strong); padding: 0;
  transition: color 0.15s var(--ease-out);
}
.star-btn.on { color: var(--accent); }

/* faq */
.faq-item {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  padding: 0 var(--space-4);
  margin-bottom: var(--space-2);
}
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: var(--space-4) 0;
  font-weight: 600; font-size: var(--fs-sm); color: var(--text);
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-3);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: ""; flex-shrink: 0;
  width: 11px; height: 11px;
  border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted);
  transform: rotate(45deg); transition: transform 0.3s var(--ease-out);
}
.faq-item[open] summary::after { transform: rotate(-135deg); }
.faq-item p { font-size: var(--fs-sm); color: var(--muted); line-height: 1.6; padding: 0 0 var(--space-4); margin: 0; }

/* social follow row (reuses the .telegram-cta shell) */
.social-row { display: flex; gap: var(--space-2); }
.social-row .cta-secondary { flex: 1; }

/* ---- STICKY BUY BAR ---- */
.buy-bar {
  position: fixed;
  left: 0; right: 0;
  bottom: calc(var(--nav-h) + env(safe-area-inset-bottom, 0px));
  z-index: 45;
  transform: translateY(140%);
  transition: transform 0.4s var(--ease-out);
  pointer-events: none;
}
.buy-bar.show { transform: translateY(0); pointer-events: auto; }
.buy-bar-inner {
  width: 100%;
  max-width: var(--app-max);
  margin: 0 auto;
  display: flex; align-items: center; gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  background: rgba(12, 13, 15, 0.92);
  backdrop-filter: saturate(160%) blur(18px);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  border-top: 1px solid var(--line-strong);
}
.buy-bar-info { display: flex; flex-direction: column; line-height: 1.2; }
.buy-bar-name { font-weight: 600; font-size: var(--fs-sm); color: var(--text); }
.buy-bar-price { font-size: var(--fs-xs); color: var(--muted); }
.buy-bar .cta.buy-bar-cta {
  width: auto; flex-shrink: 0; margin-left: auto;
  min-height: 44px; padding: var(--space-3) var(--space-5);
}

/* ---- LUT desktop refinements ---- */
@media (min-width: 1024px) {
  .proof-stats { gap: var(--space-5); }
  .proof-num { font-size: var(--fs-2xl); }
  .ba-showcase .ba-frame img { border-radius: var(--radius-lg); }
  /* top nav lives at the top on desktop, so the bar can sit at the very bottom */
  .buy-bar { bottom: 0; }
  .buy-bar-inner { max-width: 720px; border: 1px solid var(--line-strong); border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
}

/* ============================================
   Reduced motion: respect user preference
   ============================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .wrap > * { animation: none !important; opacity: 1 !important; transform: none !important; }
  .buy-bar { transition: none !important; }
}

/* === Before/after wipe slider (shared by /lut and /pocket-cinematic) === */
.wipe { position: relative; overflow: hidden; border-radius: 14px; touch-action: pan-y; cursor: ew-resize; }
.wipe img { display: block; width: 100%; height: auto; border-radius: 0; }
.wipe .wipe-after { position: absolute; inset: 0; }
.wipe .wipe-after img { position: absolute; inset: 0; height: 100%; object-fit: cover; }
.wipe .wipe-bar { position: absolute; top: 0; bottom: 0; width: 2px; background: rgba(255,255,255,.9); box-shadow: 0 0 12px rgba(0,0,0,.45); }
.wipe .wipe-knob { position: absolute; top: 50%; transform: translate(-50%,-50%); width: 34px; height: 34px; border-radius: 50%; background: rgba(20,20,22,.85); border: 1.5px solid rgba(255,255,255,.85); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 13px; letter-spacing: 1px; user-select: none; }
.wipe .wipe-tag { position: absolute; bottom: 10px; padding: 4px 10px; border-radius: 999px; font-size: 11px; font-weight: 700; letter-spacing: .06em; background: rgba(12,12,14,.66); color: #E9E9EC; pointer-events: none; }
.wipe .wipe-tag.before { left: 10px; }
.wipe .wipe-tag.after { right: 10px; color: #E8B873; }

/* === Course sales page extras === */
.module-grid { display: grid; gap: 14px; }
.module-card { background: var(--surface, #121316); border: 1px solid var(--line, #1F2126); border-radius: 14px; padding: 18px; }
.module-card img { width: 100%; border-radius: 10px; margin-bottom: 12px; display: none; }
.module-card img.loaded { display: block; }
.module-card .module-kicker { font-size: 11px; font-weight: 700; letter-spacing: .08em; color: #E8B873; text-transform: uppercase; }
.module-card h3 { margin: 6px 0 6px; font-size: 17px; }
.module-card p { margin: 0; color: var(--muted, #9A9AA0); font-size: 14px; line-height: 1.55; }
.hosts-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; }
.host-card { text-align: center; background: var(--surface, #121316); border: 1px solid var(--line, #1F2126); border-radius: 14px; padding: 18px; }
.host-card img { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; margin: 0 auto 10px; display: block; }
.host-card h3 { margin: 0 0 4px; font-size: 15px; }
.host-card p { margin: 0; font-size: 13px; color: var(--muted, #9A9AA0); line-height: 1.5; }
.pack-list { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 10px; }
.pack-list li { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; line-height: 1.5; }
.pack-list li::before { content: ""; flex: 0 0 8px; width: 8px; height: 8px; margin-top: 7px; border-radius: 50%; background: #E8B873; }
.pack-shelf { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-top: 16px; }
.pack-chip { background: var(--surface, #121316); border: 1px solid var(--line, #1F2126); border-radius: 14px; padding: 16px 14px; display: flex; flex-direction: column; gap: 6px; }
.pack-chip strong { font-size: 13.5px; }
.pack-chip span:last-child { font-size: 12px; color: var(--muted, #9A9AA0); line-height: 1.45; }
.pack-icon { width: 34px; height: 34px; border-radius: 10px; background: rgba(232,184,115,.12); color: #E8B873; display: flex; align-items: center; justify-content: center; margin-bottom: 4px; }
.pack-icon svg { width: 20px; height: 20px; }
.pack-chip-accent { border-color: rgba(232,184,115,.45); }
