/* Trade Like Shrimp landing page: layout and landing-only components.
   Colours, type, spacing, motion and the shared components (buttons, cards,
   chips, skeletons, scroll reveals) come from shared/css/tls-tokens.css and
   tls-base.css. Motion only animates transform and opacity. */
:root {
  --max: 1200px;
  --gutter: 16px;
  --nav-h: 60px;
  --card-pad: clamp(18px, 14px + 1vw, 24px);
  --btn-h: 48px; --btn-py: 12px; --btn-px: 20px; --btn-fs: 15px;   /* the landing's buttons run a size up */
}
@media (min-width: 768px) { :root { --gutter: 24px; } }
@media (min-width: 1280px) { :root { --gutter: 32px; } }

/* ---------- base ---------- */
/* --bg-deep at the edges: the pull-down bounce above the hero matches its black */
html { background: var(--bg-deep); color: var(--fg); scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + var(--safe-t) + 12px);
  -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.55 var(--font); -webkit-font-smoothing: antialiased; overflow-x: clip; background: var(--bg); }
img, video, svg { display: block; max-width: 100%; }
a { color: inherit; }
:focus-visible { outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { margin: 0; letter-spacing: -.02em; line-height: 1.12; font-weight: 650; }
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); letter-spacing: -.01em; line-height: 1.3; }
p { margin: 0; }
.center { text-align: center; justify-content: center; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 10px 14px; border-radius: var(--r-btn); background: var(--gold); color: var(--gold-ink); }
.skip:focus { top: calc(12px + var(--safe-t)); }

.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto;
  padding-inline: max(var(--gutter), var(--safe-l)) max(var(--gutter), var(--safe-r)); }
.section { padding-block: clamp(64px, 48px + 5vw, 128px); }
.head { margin-bottom: clamp(28px, 20px + 2vw, 48px); }
.head > * { max-width: 760px; }
.eyebrow { margin-bottom: var(--s3); }
.sub { margin-top: var(--s4); font-size: clamp(1rem, .95rem + .3vw, 1.15rem); color: var(--fg-2); max-width: 640px; }
.lead { font-size: var(--fs-lead); color: var(--fg-2); }
.fine { font-size: 12.5px; color: var(--muted); margin-top: var(--s4); line-height: 1.6; }
.link { display: inline-flex; align-items: center; min-height: 44px; background: none; border: 0; padding: 0; color: var(--gold-hi); font-weight: 600; text-decoration: none; }
.link:hover { text-decoration: underline; }
ul.cards3, ul.feature-grid, ul.trust-list, .how-steps, .sc-steps { list-style: none; margin-block: 0; }
ul.feature-grid, .how-steps { margin-inline: 0; }

/* ---------- call-to-action rows (buttons themselves are in tls-base.css) ---------- */
.cta-row { display: flex; flex-wrap: wrap; gap: var(--s3); }
.cta-row .btn { flex: 1 1 180px; }
@media (min-width: 600px) { .cta-row .btn { flex: 0 0 auto; min-width: 180px; } }
/* ---------- nav ---------- */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 40; padding-top: var(--safe-t); transition: transform var(--t-slow) var(--ease-out); }
/* phones: steps out of the way while you read down, back the moment you scroll up */
.nav.hide { transform: translate3d(0, -100%, 0); }
.nav::before { content: ""; position: absolute; inset: 0; background: rgba(13, 15, 18, .86); border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px) saturate(140%); -webkit-backdrop-filter: blur(16px) saturate(140%); opacity: 0; transition: opacity var(--t-slow) var(--ease-out); }
.nav.solid::before { opacity: 1; }
/* logo left, links centred, "Launch app" right */
.nav-in { position: relative; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: var(--s4); height: var(--nav-h); }
.nav-brand { justify-self: start; display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 650; letter-spacing: -.01em; min-height: 44px; min-width: 44px; }
.nav-brand img { width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line-2); background: #000; }
.nav-links { display: none; gap: var(--s1); }
.nav-links a { position: relative; display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; border-radius: 8px; color: var(--fg-2); text-decoration: none; font-size: 14px; font-weight: 500;
  transition: color var(--t-base) var(--ease-out); }
.nav-links a::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: 9px; height: 1px; background: var(--gold); transform: scaleX(0); transform-origin: 0 50%;
  transition: transform var(--t-slow) var(--ease-out); }
.nav-links a:hover { color: var(--fg); }
.nav-links a:hover::after { transform: scaleX(1); }
.nav-cta { justify-self: end; }
/* sub-pages (Daily Analysis): a visible way back to the landing page; on wide screens "Home" is in the links */
.nav-end { justify-self: end; display: flex; align-items: center; gap: 8px; }
@media (min-width: 900px) { .nav-home { display: none; } }
@media (max-width: 520px) { .nav-in:has(.nav-end) .nav-brand span { display: none; } }   /* phones: logo only, room for Home + Launch app */
.nav .btn.outline { background: rgba(13, 15, 18, .35); }
@media (min-width: 900px) { .nav-in { grid-template-columns: 1fr auto 1fr; } .nav-links { display: flex; } }
@media (max-width: 380px) { .nav-brand span { display: none; } }
.btn.pill { border-radius: var(--r-pill); }

/* ---------- a. hero slide-show ---------- */
/* Pinned while the rest of the page (.over) slides up over it. svh: the height
   with the browser's toolbars showing, so nothing is ever under them; dvh would
   re-flow the whole page each time Safari's toolbar slides. */
.hero { position: sticky; top: 0; z-index: 0; height: 100vh; height: 100svh; min-height: 540px; background: var(--bg); overflow: hidden; }
.hero.covered { visibility: hidden; }            /* fully under the page: nothing to draw */
.hero-frame { position: absolute; inset: 0; overflow: hidden; background: var(--bg-deep); transform-origin: 50% 35%; touch-action: pan-y; --corner: 0; }
/* as the hero settles back it dims a little, for depth */
.hero-frame::after { content: ""; position: absolute; inset: 0; z-index: 5; background: #000; opacity: calc(var(--corner) * .45); pointer-events: none; }

/* scenes: crossfade, the new one settling from 1.06 to 1 (js/hero.js) */
.hero-bg { position: absolute; inset: -16px; z-index: 0; }   /* own layer (slides stack inside it); room for the 8 px mouse parallax */
.hero-slide { position: absolute; inset: 0; opacity: 0; }
.hero-slide.on { opacity: 1; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
/* type stays readable on any scene; the calm centre is left alone */
.hero-shade { position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(180deg, rgba(4, 4, 4, .78) 0, rgba(4, 4, 4, .2) 30%, rgba(4, 4, 4, 0) 48%, rgba(4, 4, 4, .35) 64%, rgba(4, 4, 4, .9) 100%); }
@media (min-width: 1024px) and (min-aspect-ratio: 1/1) {
  .hero-shade { background:
    linear-gradient(90deg, rgba(4, 4, 4, .84) 0, rgba(4, 4, 4, .6) 22%, rgba(4, 4, 4, 0) 41%, rgba(4, 4, 4, 0) 59%, rgba(4, 4, 4, .6) 78%, rgba(4, 4, 4, .84) 100%),
    linear-gradient(180deg, rgba(4, 4, 4, .55) 0, rgba(4, 4, 4, 0) 22%, rgba(4, 4, 4, 0) 70%, rgba(4, 4, 4, .8) 100%); }
  .hero-desc { text-shadow: 0 1px 14px rgba(0, 0, 0, .7); }
}

/* Phones: words on top, logo in the middle, description and button below, then the bar. */
.hero-ui { position: absolute; inset: 0; z-index: 2; display: grid; gap: var(--s4); align-content: stretch;
  grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr) auto auto; grid-template-areas: "left" "mid" "right" "bar";
  padding-top: calc(var(--nav-h) + var(--safe-t) + 14px); padding-bottom: calc(10px + var(--safe-b)); }
.hero-left { grid-area: left; display: flex; flex-direction: column; gap: 10px; }
.hero-eyebrow { margin: 0; }
.hero-title { font-size: clamp(2.3rem, 1.5rem + 3.6vw, 3.4rem); line-height: 1.02; letter-spacing: -.035em; font-weight: 700; }
/* each line slides through its own mask */
.hero .hl { display: block; overflow: hidden; padding-bottom: .1em; margin-bottom: -.1em; }
.hero .hl > span { display: inline-block; white-space: nowrap; }
.hero-desc .hl > span { white-space: normal; }
.hero-count { display: flex; align-items: baseline; margin-top: 4px; font-size: 14px; font-weight: 600; letter-spacing: .06em; font-variant-numeric: tabular-nums; }
.cnt { display: inline-flex; color: var(--fg); }
.cnt-of { color: var(--muted); }
/* counter digits roll: a 0-9 strip per digit, moved by js/hero.js */
.roll { display: inline-block; height: 1em; line-height: 1; overflow: hidden; }
.strip { display: flex; flex-direction: column; transition: transform 700ms var(--ease-out); }
.strip > span { height: 1em; line-height: 1; }

.hero-mid { grid-area: mid; display: grid; place-items: center; min-height: 0; }
.hero-logo { position: relative; display: block; width: min(74vw, 400px, 62svh); padding: 0; border: 0; background: none; cursor: pointer;
  -webkit-tap-highlight-color: transparent; perspective: 900px; }
.hero-logo:focus-visible { outline: 2px solid var(--gold); outline-offset: 12px; border-radius: 16px; }
/* the soft glow behind it takes the slide's accent (crossfaded) */
.logo-glow { position: absolute; left: -24%; right: -24%; top: 50%; aspect-ratio: 1; transform: translateY(-50%); pointer-events: none; }
.logo-glow i { position: absolute; inset: 0; border-radius: 50%; opacity: 0; transition: opacity 900ms var(--ease-out); }
.logo-glow .g-gold { background: radial-gradient(closest-side, rgba(212, 168, 75, .34), rgba(212, 168, 75, .1) 48%, transparent 72%); }
.logo-glow .g-silver { background: radial-gradient(closest-side, rgba(201, 206, 214, .26), rgba(201, 206, 214, .08) 48%, transparent 72%); }
.logo-glow .g-blue { background: radial-gradient(closest-side, rgba(47, 107, 255, .3), rgba(47, 107, 255, .09) 48%, transparent 72%); }
.hero:not([data-accent]) .g-gold, .hero[data-accent="gold"] .g-gold, .hero[data-accent="silver"] .g-silver, .hero[data-accent="blue"] .g-blue { opacity: 1; }
.logo-float { position: relative; display: block; animation: logoFloat 6s var(--ease-in-out) infinite; }
.logo-flip { display: block; transform-style: preserve-3d; }
.logo-flip img { width: 100%; height: auto; filter: drop-shadow(0 22px 34px rgba(0, 0, 0, .55)); }
@keyframes logoFloat { 0%, 100% { transform: translate3d(0, -7px, 0); } 50% { transform: translate3d(0, 7px, 0); } }

.hero-right { grid-area: right; display: flex; flex-direction: column; align-items: flex-start; gap: var(--s4); }
.hero-desc { max-width: 36ch; color: var(--fg-2); font-size: clamp(15px, 14px + .3vw, 17px); line-height: 1.5; }
.hero-cta { min-width: 176px; }

/* bottom: dots left, hint centre, socials right */
.hero-bar { grid-area: bar; display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: var(--s2); }
.hero-dots { display: flex; }
.hdot { width: 44px; height: 44px; display: grid; place-items: center; padding: 0; border: 0; background: none; cursor: pointer; }
.hdot i { position: relative; width: 24px; height: 6px; }
.hdot i::before, .hdot i::after { content: ""; position: absolute; top: 0; height: 6px; border-radius: 3px;
  transition: opacity var(--t-slow) var(--ease-out), transform var(--t-slow) var(--ease-out); }
.hdot i::before { left: 9px; width: 6px; background: var(--fg); opacity: .45; }                          /* the dot... */
.hdot i::after { left: 0; width: 24px; background: var(--gold); opacity: 0; transform: scaleX(.25); }     /* ...stretches into the pill */
.hdot[aria-current="true"] i::before { opacity: 0; }
.hdot[aria-current="true"] i::after { opacity: 1; transform: none; }
.hdot:hover i::before { opacity: .8; }
/* "Tap the logo to switch": a glass pill with a pinging gold dot, so it reads at a glance */
.hero-hint { justify-self: center; display: inline-flex; align-items: center; gap: 10px; margin: 0; padding: 9px 16px 9px 13px; border-radius: var(--r-pill);
  border: 1px solid rgba(212, 168, 75, .5); background: rgba(13, 15, 18, .58); box-shadow: 0 0 26px rgba(212, 168, 75, .16);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  font: 600 13.5px/1.2 var(--font); letter-spacing: .01em; color: var(--fg); white-space: nowrap; }
.tap { position: relative; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--gold-hi); }
.tap::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--gold); animation: tls-ping 1.8s var(--ease-out) infinite; }
.hero-hint-under { display: none; cursor: pointer; min-height: 44px; }
/* phones and tablets: under the logo; laptops: centred in the bottom bar */
@media not all and (min-width: 1024px) and (min-aspect-ratio: 1/1) {
  .hero-mid { align-content: center; gap: clamp(12px, 3svh, 26px); }
  .hero-hint-under { display: inline-flex; }
  .hero-hint-bar { display: none; }
  .hero-bar { grid-template-columns: auto minmax(0, 1fr); }
}
@media (orientation: landscape) and (max-height: 520px) { .hero-hint-under { display: none; } .hero-hint-bar { display: inline-flex; } .hero-bar { grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); } }
.hero-socials { justify-self: end; }
.hero-socials a { background: rgba(13, 15, 18, .45); }
.hero.single .hero-bar .hero-dots, .hero.single .hero-hint, .hero.single .hero-progress, .hero.single .hero-count, .hero.single .logo-ring { visibility: hidden; }

/* A gold ripple keeps pulsing out from the logo until it's first used. */
.logo-ring { position: absolute; left: 50%; top: 50%; width: 104%; aspect-ratio: 2.1; border-radius: 50%; border: 2px solid rgba(230, 194, 122, .85);
  box-shadow: 0 0 18px rgba(212, 168, 75, .25), inset 0 0 18px rgba(212, 168, 75, .15);
  transform: translate(-50%, -50%) scale(.84); opacity: 0; pointer-events: none; animation: logoPing 3s var(--ease-out) infinite; }
.logo-ring.r2 { animation-delay: 1.5s; }
@keyframes logoPing { 0% { opacity: 0; transform: translate(-50%, -50%) scale(.84); } 18% { opacity: .75; } 100% { opacity: 0; transform: translate(-50%, -50%) scale(1.24); } }
.hero.touched .logo-ring { animation: none; }
.hero-logo:hover .logo-flip picture { transform: scale(1.03); }
.logo-flip picture { display: block; transition: transform var(--t-slow) var(--ease-out); }

/* thin progress bar for the autoplay */
.hero-progress { position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; height: 2px; background: rgba(255, 255, 255, .08); }
.hero-progress i { position: absolute; inset: 0; background: linear-gradient(90deg, var(--gold), var(--gold-hi)); transform: scaleX(0); transform-origin: 0 50%; }

/* rounded corners as it settles back: page-coloured corner pieces fade in */
.hero-corner { position: absolute; z-index: 6; width: 28px; height: 28px; opacity: var(--corner); pointer-events: none; }
.hero-corner.c1 { left: 0; top: 0; background: radial-gradient(circle at 100% 100%, transparent 27px, var(--bg) 28px); }
.hero-corner.c2 { right: 0; top: 0; background: radial-gradient(circle at 0 100%, transparent 27px, var(--bg) 28px); }
.hero-corner.c3 { left: 0; bottom: 0; background: radial-gradient(circle at 100% 0, transparent 27px, var(--bg) 28px); }
.hero-corner.c4 { right: 0; bottom: 0; background: radial-gradient(circle at 0 0, transparent 27px, var(--bg) 28px); }

/* Short phones: tighter, so the button and the bar stay on screen. */
@media (orientation: portrait) and (max-height: 700px) {
  .hero-ui { gap: var(--s3); padding-top: calc(var(--nav-h) + var(--safe-t) + 6px); }
  .hero-title { font-size: clamp(2rem, 1.3rem + 3vw, 2.5rem); }
  .hero-desc { font-size: 14.5px; }
}
/* Phones sideways: words left, logo centre, description right. */
@media (orientation: landscape) and (max-height: 520px) {
  .hero { min-height: 0; }
  .hero-ui { grid-template-columns: minmax(0, 1fr) minmax(0, 30vw) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) auto;
    grid-template-areas: "left mid right" "bar bar bar"; align-items: center; gap: var(--s2) var(--s4); padding-top: calc(var(--nav-h) + 4px); }
  .hero-title { font-size: clamp(1.6rem, .8rem + 4vh, 2.2rem); }
  .hero-desc { font-size: 14px; }
  .hero-logo { width: 100%; }
}
/* Laptops and up: three columns around the logo. */
@media (min-width: 1024px) and (min-aspect-ratio: 1/1) {
  .hero-ui { grid-template-columns: minmax(0, 1fr) minmax(300px, 34vw) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) auto;
    grid-template-areas: "left mid right" "bar bar bar"; align-items: center; gap: var(--s4) clamp(24px, 3vw, 48px);
    padding-top: calc(var(--nav-h) + var(--safe-t)); padding-bottom: 18px; }
  .hero-title { font-size: clamp(2.6rem, .9rem + 2.7vw, 4.4rem); }
  .hero-left { gap: 14px; }
  .hero-right { justify-self: end; max-width: 320px; }
  .hero-logo { width: min(100%, 560px); }
  .hero-count { font-size: 15px; margin-top: 10px; }
}

/* Scroll: the hero scales to .94 with rounded corners as the page slides over it.
   Scroll-driven where supported; js/hero.js does the same otherwise. */
@keyframes heroBack { to { transform: scale(.94); } }
@keyframes heroDim { to { opacity: .45; } }
@keyframes cornerIn { to { opacity: 1; } }
@supports (animation-timeline: scroll()) {
  .hero-frame { animation: heroBack linear both; animation-timeline: scroll(root block); animation-range: 0 100vh; }
  .hero-frame::after { opacity: 0; animation: heroDim linear both; animation-timeline: scroll(root block); animation-range: 0 100vh; }
  .hero-corner { opacity: 0; animation: cornerIn linear both; animation-timeline: scroll(root block); animation-range: 0 40vh; }
}

/* Everything after the hero: one sheet that slides up over it. */
/* overflow-x: clip keeps the side-sliding entrances from widening the page on phones
   (clip, unlike hidden, leaves the sticky showcase phone working) */
.over { position: relative; z-index: 1; background: var(--bg); border-radius: 28px 28px 0 0; box-shadow: 0 -28px 60px rgba(0, 0, 0, .5); overflow-x: clip; }
.no-js .hero { position: relative; }

/* ---------- b. trust strip ---------- */
.trust { border-bottom: 1px solid var(--line); position: relative; }
.trust-list { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s3) var(--s4); padding-block: 18px; }
.trust-list li { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 500; color: var(--fg-2); min-height: 28px; }
.trust-list svg { flex: none; width: 20px; height: 20px; fill: none; stroke: var(--silver); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
@media (min-width: 768px) { .trust-list { grid-template-columns: repeat(4, auto); justify-content: space-between; } }

/* ---------- c. tool showcase ---------- */
.sc-grid { display: block; }
.sc-phone-col { display: none; }
/* Phones/tablets: a swipe carousel, each card with its own screen. */
.sc-steps { display: grid; grid-auto-flow: column; grid-auto-columns: min(82%, 340px); gap: var(--s3); padding: 0 var(--gutter) var(--s2);
  margin: 0 calc(-1 * var(--gutter)); overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gutter); scrollbar-width: none; }
.sc-steps::-webkit-scrollbar { display: none; }
.sc-step { scroll-snap-align: start; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); padding: var(--s4) var(--s4) var(--s5); }
.sc-step h3 { margin-bottom: var(--s2); }
.sc-step p:not(.eyebrow) { color: var(--fg-2); font-size: 15px; }
.sc-step .eyebrow { margin-bottom: 6px; }
/* each card shows the whole phone (the tool sits at a different height in each screenshot) */
.sc-mini { display: flex; justify-content: center; align-items: center; margin-bottom: var(--s4); padding: var(--s4) 0; border-radius: 10px; height: 380px;
  background: radial-gradient(70% 55% at 50% 45%, rgba(212, 168, 75, .14), transparent 70%), var(--bg-sunk); overflow: hidden; }
.sc-mini picture, .sc-mini img { height: 100%; width: auto; }
/* The card in the middle is full size; its neighbours sit back a little.
   Tied to the carousel's own scroll, so it tracks the finger exactly. */
@keyframes cardFocus { 0% { opacity: .7; transform: scale(.95); } 30%, 70% { opacity: 1; transform: none; } 100% { opacity: .7; transform: scale(.95); } }   /* .7 keeps text readable */
@media (max-width: 1023px) {
  @supports (animation-timeline: view()) { .sc-step { animation: cardFocus linear both; animation-timeline: view(inline); } }
}
.sc-dots { display: flex; justify-content: center; gap: var(--s2); margin-top: var(--s2); }
.sc-dots button { width: 44px; height: 44px; display: grid; place-items: center; padding: 0; border: 0; background: none; }
.sc-dots button::after { content: ""; width: 8px; height: 8px; border-radius: 4px; background: var(--fg-2); opacity: .28;
  transition: transform var(--t-slow) var(--ease-out), opacity var(--t-slow) var(--ease-out); }
.sc-dots button[aria-current="true"]::after { opacity: 1; transform: scaleX(2.6); background: var(--gold); }
/* Phones sideways: card = small phone on the left, words on the right. */
@media (orientation: landscape) and (max-height: 520px) and (max-width: 1023px) {
  .sc-steps { grid-auto-columns: min(80%, 560px); }
  .sc-step { display: grid; grid-template-columns: 172px 1fr; column-gap: var(--s4); align-content: center; padding: var(--s3); }
  .sc-mini { grid-row: 1 / span 4; height: 260px; margin: 0; padding: 10px 0; }
}

@media (min-width: 1024px) {
  .sc-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
  .sc-phone-col { display: flex; justify-content: center; align-items: center; position: sticky; top: calc(50vh - 320px); height: 640px; }
  .sc-steps { display: block; grid-auto-flow: initial; overflow: visible; margin: 0; padding: 0; }
  .sc-step { min-height: 72vh; display: flex; flex-direction: column; justify-content: center; background: none; border: 0; padding: 0; max-width: 460px; }
  .sc-step h3 { font-size: clamp(1.4rem, 1rem + 1vw, 2rem); }
  .sc-step p:not(.eyebrow) { font-size: 17px; }
  .sc-mini, .sc-dots { display: none; }
  /* the step in the middle of the screen is the bright one */
  @supports (animation-timeline: view()) {
    .sc-step { animation: stepFocus linear both; animation-timeline: view(); animation-range: cover 10% cover 90%; }
  }
  @supports not (animation-timeline: view()) {
    .js .sc-step { opacity: .65; transition: opacity var(--t-slow) var(--ease-out); }
    .js .sc-step.active { opacity: 1; }
  }
}
@keyframes stepFocus { 0%, 100% { opacity: .65; } 32%, 68% { opacity: 1; } }   /* .65 keeps dimmed text readable (contrast) */

/* Desktop: the real app screenshots (in a phone frame), stacked; the step in view picks one. */
.sc-phone { position: relative; width: 294px; aspect-ratio: 321 / 700; }
.sc-glow { position: absolute; inset: 8% -36%; border-radius: 50%; background: radial-gradient(closest-side, rgba(212, 168, 75, .2), transparent 72%); pointer-events: none; }
.sc-shot { position: absolute; inset: 0; opacity: 0; transform: translate3d(0, 18px, 0) scale(.985);
  transition: opacity 520ms var(--ease-out), transform 520ms var(--ease-out); }
.sc-shot.on { opacity: 1; transform: none; }
.sc-shot img { width: 100%; height: auto; }

.more-title { margin: clamp(48px, 40px + 3vw, 88px) 0 var(--s5); font-size: clamp(1.2rem, 1rem + .8vw, 1.6rem); }
.feature-grid { display: grid; grid-template-columns: 1fr; gap: var(--s3); padding: 0; }
.feature-grid li { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); }
.feature-grid svg { grid-row: span 2; width: 22px; height: 22px; margin-top: 2px; fill: none; stroke: var(--silver); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.feature-grid b { font-weight: 600; }
.feature-grid span { color: var(--fg-2); font-size: 14.5px; }
@media (min-width: 768px) { .feature-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .feature-grid { grid-template-columns: repeat(3, 1fr); } }

/* ---------- d. how it works ---------- */
/* the gold ambient loop drifts behind it, faded into the page at every edge */
.how { position: relative; overflow: hidden; }
.how > .wrap { position: relative; z-index: 1; }
.how-media { position: absolute; inset: 0; pointer-events: none;
  -webkit-mask-image: radial-gradient(75% 70% at 50% 50%, #000 30%, transparent 100%); mask-image: radial-gradient(75% 70% at 50% 50%, #000 30%, transparent 100%); }
.how-video { width: 100%; height: 100%; object-fit: cover; opacity: .4; }
.how-track { position: relative; }

/* ---------- d2. built for speed ---------- */
/* the globe loop behind, under a dark wash so the numbers stay readable */
.speed { position: relative; overflow: hidden; isolation: isolate; }
.speed > .wrap { position: relative; z-index: 1; }
.speed-media { position: absolute; inset: 0; z-index: 0; pointer-events: none; background: #000; }
.speed-media::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, var(--bg) 0%, rgba(8, 9, 12, .55) 22%, rgba(8, 9, 12, .55) 78%, var(--bg) 100%); }
.speed-video { width: 100%; height: 100%; object-fit: cover; opacity: .75; }
.speed-stats { display: flex; flex-wrap: wrap; align-items: flex-end; gap: var(--s5) clamp(28px, 6vw, 72px); margin-top: var(--s6, 40px); }
.speed-stat { display: grid; gap: 4px; }
.speed-stat b { font-size: clamp(2.6rem, 2rem + 4vw, 4.5rem); font-weight: 750; line-height: 1; letter-spacing: -.02em; color: var(--gold-hi); }
.speed-stat > span { color: var(--fg-2); font-size: .95rem; }
.speed-tag { flex-basis: 100%; display: inline-flex; align-items: center; gap: 8px; margin: 0; font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--fg-2); }
.speed-tag i { width: 8px; height: 8px; border-radius: 50%; background: var(--fg-2); }
.speed-tag.live { color: var(--gold-hi); }
.speed-tag.live i { background: var(--gold); animation: nhBlink 2s ease-in-out infinite; }
.how-steps { display: grid; gap: var(--s5); padding: 0; position: relative; }
.how-steps li { position: relative; padding-left: 64px; }
.how-steps h3 { margin: 6px 0 var(--s2); }
.how-steps p { color: var(--fg-2); margin-bottom: var(--s2); }
.how-num { position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  background: var(--surface); border: 1px solid rgba(212, 168, 75, .5); color: var(--gold-hi); font-weight: 650; }
/* The line draws as the section scrolls by (scroll-driven, or js/site.js sets --p). */
.how-line { position: absolute; left: 21px; top: 22px; bottom: 22px; width: 2px; background: var(--line-2); border-radius: 2px; overflow: hidden; }
.how-line i { position: absolute; inset: 0; background: linear-gradient(180deg, var(--gold), var(--gold-hi)); transform-origin: 50% 0; transform: scaleY(var(--p, 0)); }
@keyframes drawY { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes drawX { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@media (min-width: 900px) {
  .how-steps { grid-template-columns: repeat(3, 1fr); gap: clamp(24px, 4vw, 56px); }
  .how-steps li { padding: 68px 0 0; }
  .how-line { left: 22px; right: 22px; top: 21px; bottom: auto; width: auto; height: 2px; }
  .how-line i { transform-origin: 0 50%; transform: scaleX(var(--p, 0)); background: linear-gradient(90deg, var(--gold), var(--gold-hi)); }
}
@supports (animation-timeline: view()) {
  .how-track { view-timeline: --how block; }
  .how-line i { animation: drawY linear both; animation-timeline: --how; animation-range: entry 40% cover 65%; }
  @media (min-width: 900px) { .how-line i { animation-name: drawX; } }
}

/* ---------- e. education library ---------- */
.lib-featured:empty { display: none; }
.lib-featured { margin-bottom: clamp(28px, 20px + 2vw, 48px); }
.feat { display: grid; gap: var(--s4); text-align: left; width: 100%; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); overflow: hidden; }
.feat .thumb { border-radius: 0; }
.feat-body { padding: 0 var(--s4) var(--s5); display: flex; flex-direction: column; gap: var(--s2); }
.feat-body h3 { font-size: clamp(1.2rem, 1rem + 1vw, 1.75rem); }
.feat-body p { color: var(--fg-2); }
@media (min-width: 900px) {
  .feat { grid-template-columns: 1.4fr 1fr; align-items: center; gap: 0; }
  .feat-body { padding: var(--s5) clamp(24px, 3vw, 40px); }
}
.lib-controls { display: flex; flex-direction: column; gap: var(--s3); margin-bottom: var(--s4); }
.search { position: relative; display: block; max-width: 420px; }
.search svg { position: absolute; left: 14px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
.search input { width: 100%; min-height: 48px; padding: 12px 14px 12px 42px; border-radius: var(--r-btn); border: 1px solid var(--line-2); background: var(--bg-sunk); font-size: 16px; outline: none; }
.search input:focus { border-color: rgba(212, 168, 75, .65); }
.chips { display: flex; gap: var(--s2); overflow-x: auto; scrollbar-width: none; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); overscroll-behavior-x: contain; }
.chips::-webkit-scrollbar { display: none; }
@media (min-width: 768px) { .chips { flex-wrap: wrap; overflow: visible; margin-inline: 0; padding-inline: 0; } }
.lib-count { font-size: 13px; color: var(--muted); margin-bottom: var(--s3); }
.lib-grid { display: grid; grid-template-columns: 1fr; gap: var(--s4); }
@media (min-width: 640px) { .lib-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .lib-grid { grid-template-columns: repeat(3, 1fr); } }
.lib-empty { padding: 40px 0; text-align: center; color: var(--muted); }
.vcard { display: flex; flex-direction: column; text-align: left; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card);
  overflow: hidden; transition: transform var(--t-fast) var(--ease-out); }
.vcard:active { transform: scale(.985); }
.vcard-body { display: flex; flex-direction: column; gap: 6px; padding: 14px var(--s4) 18px; }
.vcard-body h3 { font-size: 16px; }
.vcard-body p { color: var(--muted); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 11px; font-weight: 600; letter-spacing: .04em; padding: 3px 8px; border-radius: 6px; border: 1px solid var(--line-2); color: var(--fg-2); }
.tag.ph { border-color: rgba(230, 160, 40, .45); color: #F2CF8E; }
.thumb { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: radial-gradient(90% 90% at 30% 20%, rgba(212, 168, 75, .16), transparent 60%), radial-gradient(70% 80% at 90% 100%, rgba(47, 107, 255, .14), transparent 60%), #0A0B0E; }
.thumb picture { display: contents; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.js .thumb img { opacity: 0; transition: opacity 500ms var(--ease-out); }   /* fades in once loaded, never pops */
.js .thumb img.ready { opacity: 1; }
/* the brand thumbnails leave their left side empty for the topic */
.thumb-cap { position: absolute; left: 6%; top: 50%; max-width: 44%; transform: translateY(-50%); font-size: clamp(13px, 11px + .6vw, 17px); font-weight: 650;
  line-height: 1.2; letter-spacing: .08em; text-transform: uppercase; color: var(--fg); text-shadow: 0 2px 12px rgba(0, 0, 0, .8); }
.feat .thumb-cap { font-size: clamp(16px, 12px + 1.2vw, 26px); }
.thumb .dur { position: absolute; right: 8px; bottom: 8px; padding: 2px 7px; border-radius: 6px; background: rgba(0, 0, 0, .72); font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.thumb .play { position: absolute; left: 50%; top: 50%; width: 52px; height: 52px; margin: -26px 0 0 -26px; border-radius: 50%; background: rgba(13, 15, 18, .7);
  border: 1px solid rgba(255, 255, 255, .18); display: grid; place-items: center; transition: transform var(--t-base) var(--ease-out); }
.thumb .play::after { content: ""; margin-left: 4px; border-left: 14px solid var(--fg); border-block: 9px solid transparent; }
.vcard:hover .play, .feat:hover .play { transform: scale(1.06); }
.watched { position: absolute; left: 8px; top: 8px; display: inline-flex; align-items: center; gap: 5px; padding: 3px 8px 3px 6px; border-radius: 6px;
  background: rgba(0, 0, 0, .72); font-size: 12px; font-weight: 600; color: var(--fg); }
.watched::before { content: ""; width: 5px; height: 9px; margin: 0 2px 2px 2px; border: solid var(--good); border-width: 0 2px 2px 0; transform: rotate(45deg); }

/* Player: a centred modal on wide screens, full screen on phones. */
.player { width: min(960px, calc(100vw - 48px)); max-width: none; max-height: calc(100dvh - 48px); padding: 0; border: 1px solid var(--line-2); border-radius: var(--r-card);
  background: var(--surface); color: var(--fg); overflow: auto; opacity: 0; transform: translate3d(0, 16px, 0) scale(.98);
  transition: opacity var(--t-slow) var(--ease-out), transform var(--t-slow) var(--ease-out), overlay var(--t-slow) allow-discrete, display var(--t-slow) allow-discrete; }
.player[open] { opacity: 1; transform: none; }
@starting-style { .player[open] { opacity: 0; transform: translate3d(0, 16px, 0) scale(.98); } }
.player::backdrop { background: rgba(0, 0, 0, .78); }
.player-frame { position: relative; aspect-ratio: 16 / 9; background: #000; }
.player-frame iframe, .player-frame video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.player-soon { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 24px; color: var(--fg-2); }
.player-meta { padding: var(--s4) var(--s5) var(--s5); }
.player-meta p { color: var(--fg-2); margin-top: var(--s2); }
.player-close { position: absolute; z-index: 2; top: calc(10px + var(--safe-t)); right: 10px; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%;
  border: 1px solid var(--line-2); background: rgba(13, 15, 18, .8); }
.player-close svg { width: 20px; height: 20px; fill: none; stroke: var(--fg); stroke-width: 2; stroke-linecap: round; }
.player-box { position: relative; }
/* Phones: the player takes the whole screen (dvh: it is an overlay, so it should
   track Safari's toolbar exactly). Sideways, the video alone fills it. */
@media (max-width: 767px), (orientation: landscape) and (max-height: 520px) {
  .player { width: 100vw; height: 100dvh; max-width: none; max-height: none; border: 0; border-radius: 0; margin: 0; background: #000; }
  .player-box { min-height: 100%; display: flex; flex-direction: column; justify-content: center; padding-bottom: var(--safe-b); }
  .player-meta { background: var(--bg); padding-inline: max(var(--s5), var(--safe-l)) max(var(--s5), var(--safe-r)); }
  .player-close { right: max(10px, var(--safe-r)); }
}
@media (orientation: landscape) and (max-height: 520px) {
  .player-box { padding: 0; }
  .player-frame { aspect-ratio: auto; height: 100dvh; }
  .player-meta { display: none; }
}

/* ---------- latest analysis ---------- */
.an-card { display: grid; text-decoration: none; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); overflow: hidden;
  transition: border-color var(--t-base) var(--ease-out); }
.an-card:hover { border-color: rgba(212, 168, 75, .4); }
.an-cover { aspect-ratio: 1200 / 630; overflow: hidden; background: #0A0B0E; }
.an-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform 900ms var(--ease-out); }
.an-card:hover .an-cover img { transform: scale(1.03); }
.an-body { display: flex; flex-direction: column; gap: var(--s2); padding: var(--s5) var(--s5) var(--s5); }
.an-body h3 { font-size: clamp(1.3rem, 1rem + 1vw, 1.9rem); }
.an-sum { color: var(--fg-2); }
.an-body .tags { margin-top: var(--s1); }
.an-go { margin-top: var(--s2); }
.an-go i { font-style: normal; margin-left: 6px; transition: transform var(--t-base) var(--ease-out); }
.an-card:hover .an-go i { transform: translateX(4px); }
@media (min-width: 900px) { .an-card { grid-template-columns: 1.15fr 1fr; align-items: center; } .an-body { padding: var(--s5) clamp(24px, 3vw, 44px); } }
.an-cover img[src$=".png"] { object-fit: contain; background: #0A0B0E; }   /* a real chart is never cropped */
.an-pair { display: inline-flex; align-items: center; gap: 6px; }
.an-key { padding: 8px 12px; border-radius: var(--r-btn); border: 1px solid rgba(217, 68, 58, .45); background: rgba(217, 68, 58, .1); font-size: 14px; color: var(--fg); }
.an-key b { margin-right: 6px; color: #FFB4AE; }
.an-key span { font-variant-numeric: tabular-nums; color: var(--fg-2); }
.an-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); }
.an-dot.bull { background: var(--gold); }
.an-dot.bear { background: var(--blue); }

/* ---------- textures behind alternating sections (very low opacity) ---------- */
.tex { position: relative; isolation: isolate; }
.tex::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .5; background-size: 900px auto;
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 18%, #000 82%, transparent); mask-image: linear-gradient(180deg, transparent, #000 18%, #000 82%, transparent); }
.tex-mesh::before { background-image: url("../shared/assets/textures/gold-mesh.webp"); opacity: .22; }
.tex-hex::before { background-image: url("../shared/assets/textures/chrome-hex.webp"); opacity: .2; }

/* ---------- f. tools ---------- */
.tools-grid { display: grid; grid-template-columns: 1fr; gap: var(--s4); }
@media (min-width: 768px) { .tools-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1200px) { .tools-grid { grid-template-columns: repeat(3, 1fr); } .tools-grid .clock { grid-column: span 2; } }
.tool h3 { margin-bottom: var(--s4); }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s3); }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field span { font-size: 12px; font-weight: 600; color: var(--fg-2); }
.field input, .field select { width: 100%; min-height: 48px; padding: 10px 12px; border-radius: var(--r-btn); border: 1px solid var(--line-2); background: var(--bg-sunk);
  font-size: 16px; outline: none; font-variant-numeric: tabular-nums; }
.field select { appearance: none; -webkit-appearance: none; padding-right: 32px;
  background: var(--bg-sunk) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238E949E' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") right 10px center / 16px no-repeat; }
.field input:focus, .field select:focus { border-color: rgba(212, 168, 75, .65); }
.result { display: block; margin-top: var(--s4); padding: 14px var(--s4); border-radius: var(--r-btn); background: var(--bg-sunk); border: 1px solid var(--line); min-height: 76px; }
.result .big { font-size: 26px; font-weight: 650; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.result .big small { font-size: 14px; font-weight: 600; color: var(--muted); margin-left: 4px; }
.result .rows { display: grid; gap: 2px; margin-top: 6px; font-size: 13.5px; color: var(--fg-2); font-variant-numeric: tabular-nums; }
.result .hint { color: var(--muted); font-size: 14px; }
.result .err { color: var(--bad); font-size: 14px; }

.tl { position: relative; height: 60px; margin: var(--s3) 0 0; border-radius: 8px; background: var(--bg-sunk); border: 1px solid var(--line); overflow: hidden; }
.tl-hours { position: absolute; inset: 0; background-image: linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: calc(100% / 24) 100%; }
.tl-row { position: absolute; left: 0; right: 0; height: 8px; }
.tl-seg { position: absolute; top: 0; bottom: 0; border-radius: 4px; background: rgba(201, 206, 214, .22); }
.tl-seg.open { background: var(--gold); }
.tl-now { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--blue); left: 0; }
.tl-labels { position: relative; height: 18px; margin-bottom: var(--s2); font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.tl-labels span { position: absolute; top: 2px; transform: translateX(-50%); }
.tl-labels span:first-child { transform: none; } .tl-labels span:last-child { transform: translateX(-100%); }
.modal-open { overflow: hidden; }
.sessions { list-style: none; margin: var(--s3) 0 0; padding: 0; display: grid; gap: var(--s2); }
@media (min-width: 560px) { .sessions { grid-template-columns: 1fr 1fr; } }
.sessions li { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--r-btn); background: var(--bg-sunk); border: 1px solid var(--line); }
.sessions li b { font-weight: 600; }
.sessions li span { margin-left: auto; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; text-align: right; }
.sessions .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); flex: none; }
.sessions li.open { border-color: rgba(212, 168, 75, .4); }
.sessions li.open .dot { background: var(--gold); }
.sessions li.open span { color: var(--gold-hi); }
.calendar-slot { min-height: 160px; display: grid; place-items: center; border-radius: var(--r-btn); border: 1px dashed var(--line-2); background: var(--bg-sunk); }
.calendar-slot iframe { width: 100%; min-height: 420px; border: 0; }

/* ---------- g/h. why + community ---------- */
.cards3 { display: grid; grid-template-columns: 1fr; gap: var(--s4); padding-block: 0; }
@media (min-width: 768px) { .cards3 { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .cards3 { grid-template-columns: repeat(3, 1fr); } }
.cards3 svg { width: 28px; height: 28px; margin-bottom: var(--s4); fill: none; stroke: var(--gold); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.cards3 h3 { margin-bottom: var(--s2); }
.cards3 p { color: var(--fg-2); }
.why .center { display: flex; margin-top: clamp(28px, 20px + 2vw, 48px); }
/* ---------- d1. install the app ---------- */
.install .center { display: flex; margin-top: clamp(28px, 20px + 2vw, 48px); }
.ins-list { counter-reset: ins; display: grid; gap: 10px; margin: var(--s3) 0 0; padding: 0; list-style: none; }
.ins-list li { counter-increment: ins; position: relative; padding-left: 34px; color: var(--fg-2); line-height: 1.5; }
.ins-list li::before { content: counter(ins); position: absolute; left: 0; top: 1px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  background: rgba(212, 168, 75, .16); border: 1px solid rgba(212, 168, 75, .45); color: var(--gold-hi); font-size: 12px; font-weight: 800; }
.ins-list b { color: var(--fg); font-weight: 650; }
.ins-list a { color: var(--gold-hi); }
.ins-card p { margin-top: 0; }
/* the same animated scenes as the app's install guide (keep in step with public/app.css) */
.ins-scenes { display: flex; gap: 10px; margin-bottom: var(--s4); }
.ins-tile { display: grid; place-items: center; width: 58px; height: 58px; border-radius: 14px; background: rgba(212, 168, 75, .1); color: var(--gold-hi); }
.ins-scenes .ins-sc { width: 44px; height: 44px; margin: 0; stroke: currentColor; stroke-width: 1.8; }
/* install-guide scenes: one 2.8 s loop each, steps a beat apart (--k); still with reduce-motion */
.ins-sc { width: 44px; height: 44px; overflow: visible; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
  --sc-d: calc(var(--k, 0) * 350ms); }
.ins-sc .sc-dim { stroke: rgba(236, 237, 239, .32); }
.ins-sc .sc-fill { fill: rgba(236, 237, 239, .12); }
.ins-sc .sc-gold { fill: currentColor; stroke: none; }
.ins-sc .sc-dot { fill: currentColor; stroke: none; }
.ins-sc .sc-row { fill: rgba(212, 168, 75, .16); stroke: none; animation: scRow 2.8s ease-in-out var(--sc-d) infinite; }
.ins-sc .sc-tap { fill: currentColor; stroke: none; opacity: 0; transform-box: fill-box; transform-origin: center;
  animation: scTap 2.8s ease-out var(--sc-d) infinite; }
.ins-sc .sc-late { animation-delay: calc(var(--sc-d) + 700ms); }
.ins-sc .sc-bob { animation: scBob 2.8s ease-in-out var(--sc-d) infinite; }
.ins-sc .sc-slide { animation: scSlide 2.8s cubic-bezier(.2, .8, .2, 1) var(--sc-d) infinite; }
.ins-sc .sc-drop { transform-box: fill-box; transform-origin: top right; animation: scDrop 2.8s cubic-bezier(.2, .8, .2, 1) var(--sc-d) infinite; }
.ins-sc .sc-pop { transform-box: fill-box; transform-origin: center; animation: scPop 2.8s cubic-bezier(.34, 1.56, .64, 1) var(--sc-d) infinite; }
.ins-sc .sc-spin { transform-origin: 24px 24px; animation: scSpin 2.8s ease-in-out var(--sc-d) infinite; }
@keyframes scTap { 0%, 38% { opacity: 0; transform: scale(.2); } 46% { opacity: .5; } 70%, 100% { opacity: 0; transform: scale(1.5); } }
@keyframes scBob { 0%, 100% { transform: none; } 25% { transform: translateY(-2.5px); } 42% { transform: translateY(1px); } }
@keyframes scSlide { 0%, 10% { opacity: 0; transform: translateY(9px); } 30%, 88% { opacity: 1; transform: none; } 100% { opacity: 0; transform: none; } }
@keyframes scDrop { 0%, 40% { opacity: 0; transform: scale(.6); } 58%, 90% { opacity: 1; transform: none; } 100% { opacity: 0; } }
@keyframes scPop { 0%, 30% { opacity: 0; transform: scale(0); } 50%, 88% { opacity: 1; transform: none; } 100% { opacity: 0; transform: none; } }
@keyframes scSpin { 0%, 15% { transform: rotate(-70deg); } 45%, 85% { transform: rotate(45deg); } 100% { transform: rotate(-70deg); } }
@keyframes scRow { 0%, 45% { fill: rgba(212, 168, 75, .16); } 55%, 80% { fill: rgba(212, 168, 75, .45); } 100% { fill: rgba(212, 168, 75, .16); } }
@media (prefers-reduced-motion: reduce) {
  .ins-sc *, .ins-sc .sc-tap { animation: none !important; }
  .ins-sc .sc-tap { opacity: 0; }
  .ins-sc .sc-spin { transform: rotate(45deg); }
}

/* ---------- g2. already trading with HFM? ---------- */
.sw-card { display: flex; flex-direction: column; align-items: flex-start; gap: var(--s2); }
.sw-card svg { width: 28px; height: 28px; margin-bottom: var(--s2); fill: none; stroke: var(--gold); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.sw-card p { color: var(--fg-2); margin-bottom: var(--s3); }
.sw-card .btn { margin-top: auto; }
.sw-panel { margin-top: var(--s4); }
.sw-steps { display: grid; gap: var(--s3); margin: 0 0 var(--s4); padding-left: 1.3em; }
.sw-steps li::marker { color: var(--gold-hi); font-weight: 700; }
.sw-steps b { display: block; } .sw-steps span { color: var(--fg-2); font-size: 15px; }
.sw-fields { display: grid; gap: var(--s3); margin-bottom: var(--s4); }
@media (min-width: 768px) { .sw-fields { grid-template-columns: 1fr 1fr; } }
.sw-mail { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 0 0 var(--s2); font-size: 14px; }
.sw-mail dt { color: var(--muted); } .sw-mail dd { margin: 0; overflow-wrap: anywhere; }
.sw-body { max-height: 260px; overflow: auto; margin: 0 0 var(--s4); padding: 12px 14px; border-radius: var(--r-btn); border: 1px solid var(--line-2);
  background: var(--bg-sunk); font: 14px/1.55 inherit; font-family: inherit; white-space: pre-wrap; overflow-wrap: anywhere; }
.sw-actions { display: flex; flex-wrap: wrap; gap: var(--s3); }
.sw-portal { display: grid; gap: var(--s3); margin-bottom: var(--s2); }
.sw-code { display: flex; align-items: center; gap: var(--s3); padding: 12px 16px; border-radius: var(--r-btn); border: 1px solid rgba(212, 168, 75, .45); background: var(--bg-sunk); }
.sw-code span { font-size: 13px; color: var(--muted); }
.sw-code b { flex: 1; font-size: 24px; font-weight: 750; letter-spacing: .04em; color: var(--gold-hi); user-select: all; }
@media (min-width: 768px) { .sw-portal { grid-template-columns: 1fr auto; align-items: center; } }
.sw-actions .btn { flex: 1 1 180px; }
.cards2 { display: grid; grid-template-columns: 1fr; gap: var(--s4); }
@media (min-width: 768px) { .cards2 { grid-template-columns: 1fr 1fr; } }
.join { display: flex; align-items: center; gap: var(--s4); text-decoration: none; min-height: 88px; transition: transform var(--t-fast) var(--ease-out); }
.join:active { transform: scale(.985); }
.join svg { flex: none; width: 36px; height: 36px; fill: none; stroke: var(--silver); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.join span { display: flex; flex-direction: column; }
.join b { font-size: 18px; font-weight: 600; }
.join small { color: var(--muted); font-size: 14px; }
.join i { margin-left: auto; font-style: normal; font-size: 20px; color: var(--gold-hi); transition: transform var(--t-base) var(--ease-out); }
.join:hover i { transform: translateX(4px); }

/* ---------- i. FAQ ---------- */
.faq-list { display: grid; gap: var(--s2); }
.faq-list > * { max-width: 860px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); }
.faq summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: var(--s4); min-height: 56px; padding: 14px 18px; cursor: pointer; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 10px; height: 10px; border: solid var(--muted); border-width: 0 2px 2px 0; transform: translateY(-3px) rotate(45deg);
  transition: transform var(--t-base) var(--ease-out); }
.faq details[open] summary::after { transform: translateY(2px) rotate(-135deg); }
.faq-a { padding: 0 18px 18px; color: var(--fg-2); }
.faq details[open] .faq-a { animation: faqIn var(--t-slow) var(--ease-out); }
@keyframes faqIn { from { opacity: 0; transform: translate3d(0, -6px, 0); } }

/* ---------- j. final ---------- */
.final { background: radial-gradient(60% 70% at 50% 100%, rgba(212, 168, 75, .1), transparent 70%); border-top: 1px solid var(--line); }
.final-in { display: flex; flex-direction: column; align-items: center; text-align: center; gap: var(--s4); }
.final-logo { width: min(240px, 60vw); }
.final-logo img { width: 100%; height: auto; filter: drop-shadow(0 16px 30px rgba(0, 0, 0, .5)); }
.final .cta-row { justify-content: center; width: 100%; margin-top: var(--s2); }

/* ---------- k. footer ---------- */
.footer { border-top: 1px solid var(--line); padding: 48px 0 calc(32px + var(--safe-b)); background: var(--bg-sunk); }
.foot-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s4); }
.foot-links { display: flex; flex-wrap: wrap; gap: var(--s2); }
.foot-links a { padding: 10px 10px; color: var(--fg-2); text-decoration: none; font-size: 14px; min-height: 44px; display: inline-flex; align-items: center; }
.foot-links a:hover { color: var(--fg); }
.socials { display: flex; gap: var(--s2); }
.socials a { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line-2); }
.socials svg { width: 18px; height: 18px; fill: none; stroke: var(--fg-2); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.risk { margin-top: var(--s5); padding: var(--s4) 18px; border-radius: var(--r-card); border: 1px solid rgba(230, 160, 40, .4); background: rgba(230, 160, 40, .07); }
.risk b { display: block; color: #F2CF8E; margin-bottom: 4px; }
.risk p { color: var(--fg); font-size: 15px; }

/* ---------- sticky "Open account" bar (phones, after the hero) ---------- */
.mbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 10px max(var(--gutter), var(--safe-l)) calc(10px + var(--safe-b)) max(var(--gutter), var(--safe-r));
  background: rgba(13, 15, 18, .9); border-top: 1px solid var(--line); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  transform: translate3d(0, 110%, 0); transition: transform var(--t-slow) var(--ease-out); }
.mbar.on { transform: none; }
/* typing: the bar steps aside so it can never sit over the field or ride the keyboard */
.kb .mbar, .kb .mbar.on { transform: translate3d(0, 110%, 0); }
@media (min-width: 900px) { .mbar { display: none; } }
@media (max-width: 899px) { .footer { padding-bottom: calc(96px + var(--safe-b)); } }

/* placeholder links show what still needs filling in */
a.is-placeholder { outline: 1px dashed rgba(230, 160, 40, .7); outline-offset: 2px; }

/* ---------- reduced motion: no movement, everything simply visible ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal, .js .reveal.on { opacity: 1; transform: none; transition: none; }
  .hero-frame, .hero-frame::after, .hero-corner { animation: none !important; transform: none !important; }
  .hero-frame::after { opacity: 0 !important; }
  .logo-float, .logo-ring, .tap::after { animation: none; }
  .logo-flip picture { transition: none; transform: none !important; }
  .strip { transition: none; }
  .sc-step { animation: none !important; opacity: 1 !important; }
  .sc-shot { transition: opacity 200ms linear; transform: none; }
  .an-cover img, .an-go i { transition: none; transform: none !important; }
  .how-line i { animation: none !important; transform: none !important; }
  .speed-tag.live i { animation: none; }
  .player, .player[open] { transition: none; transform: none; }
  .faq details[open] .faq-a { animation: none; }
  .btn:active, .chip:active, .vcard:active, .join:active { transform: none; }
  .mbar, .nav, .sc-dots button::after, .js .thumb > img { transition: none; }
  .sc-step { animation: none !important; }
}

/* ---------- Latest news on the home page: ticker + 6 cards (Phase 5C) ---------- */
.news-home { margin-top: var(--s6, 40px); }
.nh-head { display: flex; align-items: center; gap: var(--s3); margin-bottom: var(--s3); }
.nh-head h3 { font-size: clamp(1.2rem, 1rem + .8vw, 1.5rem); }
.nh-live { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gold-hi); }
.nh-live i { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); animation: nhBlink 2s ease-in-out infinite; }
@keyframes nhBlink { 50% { opacity: .3; } }
.ticker { position: relative; overflow: hidden; margin-bottom: var(--s4); padding: 10px 0; border-block: 1px solid var(--line);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.ticker-track { display: flex; width: max-content; gap: 40px; animation: nhTick var(--dur, 80s) linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
@keyframes nhTick { to { transform: translateX(-50%); } }
.tk-item { white-space: nowrap; font-size: 14px; color: var(--fg-2); }
.tk-item b { margin-right: 6px; font-size: 12px; font-weight: 700; color: var(--muted); }
.tk-item b.own { color: var(--gold-hi); }
.nh-cards { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s3); }
@media (min-width: 700px) { .nh-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .nh-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.nh-card { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px; border-radius: var(--r-btn); background: var(--surface); border: 1px solid var(--line); min-width: 0; }
.nh-card.own { border-color: rgba(212, 168, 75, .3); }
.nh-card.arrive { animation: nhArrive 520ms cubic-bezier(.22, 1, .36, 1) calc(var(--k, 0) * 60ms) both; }
@keyframes nhArrive { from { opacity: 0; transform: translateY(10px); } }
.nh-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 12.5px; color: var(--muted); }
.nh-meta time { margin-left: auto; font-variant-numeric: tabular-nums; }
.nh-card .nf-src { padding: 2px 8px; border-radius: var(--r-pill); border: 1px solid var(--line-2); font-weight: 650; color: var(--fg-2); }
.nh-card.own .nf-src { border-color: rgba(212, 168, 75, .5); color: var(--gold-hi); }
.nh-card .nf-new { padding: 2px 7px; border-radius: var(--r-pill); background: var(--gold); color: var(--gold-ink); font-size: 11px; font-weight: 800; letter-spacing: .08em; }
.nh-title { font-weight: 600; line-height: 1.45; color: var(--fg); text-decoration: none; overflow-wrap: anywhere;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.nh-title:hover { color: var(--gold-hi); }
.nh-card .nf-credit { margin-top: auto; font-size: 12.5px; color: var(--muted); }
.nh-card .nf-credit a { color: var(--fg-2); }
.nh-actions { display: flex; flex-wrap: wrap; gap: var(--s2); margin-top: var(--s4); }
.news-home > .fine { margin-top: var(--s3); }
@media (prefers-reduced-motion: reduce) {
  .ticker { overflow-x: auto; }
  .ticker-track, .nh-live i, .nh-card.arrive { animation: none; }
}

/* Phones: the lessons are a row you swipe through, one card at a time (Phase 6). */
@media (max-width: 639px) {
  .lib-grid { grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: min(82%, 320px); gap: var(--s3);
    overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter); scrollbar-width: none;
    margin-inline: calc(-1 * var(--gutter)); padding: 0 var(--gutter) var(--s2); }
  .lib-grid::-webkit-scrollbar { display: none; }
  .lib-grid > * { scroll-snap-align: start; }
}

/* legal links in the footer */
.foot-legal a, .risk-more { color: var(--fg-2); }
.risk-more { white-space: nowrap; }
