/* Grok Home page only. Not used by the Studio hub.
   colors, type scale, spacing, radii, shadows
*/

:root {
  /* colors */
  /* Kept from the live page */
  --bg: #060908;
  --card-bg: #101814;
  --border: rgba(16, 185, 129, 0.2);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --text: #f8fafc;
  --text-sub: #cbd5e1;
  --text-dim: #8a96a8;            /* was #64748b, raised to 6.7:1 for AA */
  --emerald-bright: #34d399;
  --emerald-soft: rgba(16, 185, 129, 0.14);
  --grad-emerald: linear-gradient(135deg, #34d399 0%, #10b981 100%);
  /* type scale */
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  /* New, taken from the Grok Home app itself */
  --stage: #000000;
  --panel: #191c20;
  --panel-stroke: #34383e;
  --spot: #9bb5ca;
  --unread: #b9e5ff;
  --app-text-2: #a7adb6;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "Roboto Mono", Menlo, Consolas, monospace;
  /* radii */
  --radius-lg: 28px;
  --radius-md: 20px;
  /* spacing */
  --shell: 1180px;
  --gutter: 24px;
  /* shadows */
  --shadow-device: 0 60px 120px rgba(0, 0, 0, 0.65);
  --ease-out: cubic-bezier(.2,.8,.2,1);
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
h1, h2, h3 { text-wrap: balance; }
html { background: var(--bg); color: var(--text); font-family: var(--font); -webkit-font-smoothing: antialiased; scroll-behavior: smooth; }
body { min-height: 100dvh; display: flex; flex-direction: column; background: var(--bg); overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
img, video, canvas { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--emerald-bright); outline-offset: 3px; border-radius: 8px; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 200; background: #fff; color: #000; padding: 8px 12px; border-radius: 8px; }
.skip:focus { left: 8px; }
.shell { max-width: var(--shell); margin: 0 auto; padding: 0 var(--gutter); width: 100%; }
.eyebrow { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--emerald-bright); }

/* Header (structure kept: brand, breadcrumb, back to Studio, GitHub) */
header { padding: 14px 0; border-bottom: 1px solid var(--border-subtle); background: rgba(6, 9, 8, 0.78); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); position: sticky; top: 0; z-index: 100; }
.header-inner { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.brand-group { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 600; min-width: 0; }
.brand-link { display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.brand-icon { width: 26px; height: 26px; border-radius: 7px; }
.brand-divider { color: var(--text-dim); }
.crumb-current { color: var(--emerald-bright); white-space: nowrap; }
.header-nav { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; }
.header-nav .anchor { display: inline-flex; align-items: center; min-height: 44px; padding: 7px 10px; color: var(--text-sub); border-radius: 999px; }
.header-nav .anchor:hover { color: var(--text); }
.nav-back-pill { display: inline-flex; align-items: center; min-height: 44px; padding: 7px 14px; border-radius: 999px; background: rgba(255,255,255,0.05); border: 1px solid var(--border-subtle); white-space: nowrap; }
.nav-gh-btn { display: inline-flex; align-items: center; min-height: 44px; padding: 7px 15px; border-radius: 999px; background: var(--grad-emerald); color: #04130c; font-weight: 700; white-space: nowrap; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px; border-radius: 999px; font-size: 15px; font-weight: 700; transition: transform .18s var(--ease-out), background-color .18s, box-shadow .18s; }
.btn-primary { background: var(--grad-emerald); color: #04130c; box-shadow: 0 8px 30px rgba(16,185,129,.28); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 12px 36px rgba(16,185,129,.38); }
.btn-ghost { background: rgba(255,255,255,.06); border: 1px solid var(--border-subtle); color: var(--text); }
.btn-ghost:hover { background: rgba(255,255,255,.10); }

/* Hero */
.hero { position: relative; padding: 72px 0 0; text-align: center; isolation: isolate; }
.hero::before { content: ""; position: absolute; inset: -120px 0 auto; height: 760px; z-index: -1;
  background: radial-gradient(60% 50% at 50% 20%, rgba(16,185,129,.16), transparent 70%), radial-gradient(40% 40% at 50% 70%, rgba(155,181,202,.10), transparent 70%); }
.hero .eyebrow { display: inline-flex; gap: 10px; align-items: center; padding: 6px 12px; border: 1px solid var(--border); background: var(--emerald-soft); border-radius: 999px; margin-bottom: 22px; }
.hero h1 { font-size: clamp(2.6rem, 1.2rem + 5.6vw, 5.6rem); line-height: .98; letter-spacing: -0.045em; font-weight: 800; }
.hero h1 .line2 { display: block; background: linear-gradient(180deg, #ffffff 0%, #a9b8c6 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero h1 .accent { color: var(--emerald-bright); white-space: nowrap; }
.hero-lead { max-width: 620px; margin: 22px auto 30px; font-size: clamp(16px, 15px + .3vw, 19px); line-height: 1.55; color: var(--text-sub); }
.hero-ctas { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-note { margin-top: 14px; font-family: var(--mono); font-size: 12px; color: var(--text-dim); }

/* Tablet frame */
.device-wrap { margin: 56px auto 0; max-width: 1040px; }
.device { position: relative; margin: 0 auto; max-width: 1040px; padding: 14px; border-radius: 40px; background: linear-gradient(160deg, #2a2f35, #0e1114 40%, #1b1f24); box-shadow: 0 0 0 1px rgba(255,255,255,.08) inset, var(--shadow-device), 0 0 120px rgba(52,211,153,.07); }
.device::after { content: ""; position: absolute; top: 50%; left: 6px; width: 4px; height: 4px; border-radius: 50%; background: #2b3138; transform: translateY(-50%); }
.screen { position: relative; aspect-ratio: 16 / 10; border-radius: 26px; overflow: hidden; background: #000; container-type: inline-size; }
.screen-still { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.screen canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; transition: opacity .4s; }
.screen canvas.is-ready { opacity: 1; }
.ui { position: absolute; font-size: max(9px, 1.35cqw); font-weight: 600; color: #fff; pointer-events: none; }
.ui-pill { background: #17191c; border: 1px solid #34383e; border-radius: 999px; padding: .55em 1.1em; }
.ui-tl { top: 3.2cqw; left: 3.2cqw; }
.ui-bl { bottom: 3.2cqw; left: 3.2cqw; }
.ui-br { bottom: 3.2cqw; right: 3.2cqw; }
.ui-bc { bottom: 3.2cqw; left: 50%; transform: translateX(-50%); display: flex; gap: 1.2cqw; }
.ui-dot { width: 3.4cqw; height: 3.4cqw; border-radius: 50%; background: #17191c; border: 1px solid #34383e; display: grid; place-items: center; }
.ui-dot svg { width: 45%; height: 45%; stroke: #d2d6db; fill: none; stroke-width: 2; }
.ui-status { top: 76%; left: 50%; transform: translateX(-50%); text-align: center; white-space: nowrap; }
.ui-status b { display: block; font-size: 1.15em; font-weight: 600; }
.ui-status span { color: var(--app-text-2); font-size: .8em; font-weight: 500; }
.device-caption { margin-top: 18px; font-family: var(--mono); font-size: 12px; color: var(--text-dim); text-align: center; }

/* Facts strip */
.facts { text-align: left; margin: 72px auto 0; display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--border-subtle); border-bottom: 1px solid var(--border-subtle); }
.fact { padding: 26px 22px; border-left: 1px solid var(--border-subtle); }
.fact:first-child { border-left: 0; }
.fact b { display: block; font-size: 15px; font-weight: 700; margin-bottom: 6px; }
.fact span { font-size: 14px; line-height: 1.5; color: var(--text-sub); }

/* Section heads */
section { scroll-margin-top: 80px; }
.sec { padding: 120px 0 0; }
.sec-head { max-width: 720px; margin-bottom: 48px; }
.sec-head h2 { font-size: clamp(2rem, 1.3rem + 2.6vw, 3.4rem); line-height: 1.04; letter-spacing: -0.035em; font-weight: 800; margin-top: 12px; }
.sec-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.sec-head p { margin-top: 16px; font-size: 17px; line-height: 1.6; color: var(--text-sub); }

/* Feature rows */
.feature { display: grid; grid-template-columns: 5fr 7fr; gap: 56px; align-items: center; padding: 40px 0; }
.feature + .feature { border-top: 1px solid var(--border-subtle); }
.feature:nth-child(even) { grid-template-columns: 7fr 5fr; }
.feature:nth-child(even) .f-copy { order: 2; }
.f-num { font-family: var(--mono); font-size: 12px; color: var(--text-dim); letter-spacing: .08em; }
.f-copy h3 { font-size: clamp(1.6rem, 1.2rem + 1.3vw, 2.2rem); line-height: 1.1; letter-spacing: -0.025em; font-weight: 750; margin: 10px 0 14px; }
.f-copy p { font-size: 16.5px; line-height: 1.62; color: var(--text-sub); }
.f-copy p + p { margin-top: 12px; }
.f-copy q { quotes: "\201C" "\201D"; color: var(--text); font-weight: 600; }
.badge-soon { display: inline-block; margin-left: 8px; padding: 3px 9px; border-radius: 999px; background: rgba(185,229,255,.10); border: 1px solid rgba(185,229,255,.3); color: var(--unread); font-family: var(--mono); font-size: 11px; letter-spacing: .06em; vertical-align: middle; text-transform: uppercase; }
.f-visual { position: relative; aspect-ratio: 16 / 10; border-radius: var(--radius-md); overflow: hidden; background: #000; border: 1px solid rgba(255,255,255,.08); box-shadow: 0 30px 80px rgba(0,0,0,.5); container-type: inline-size; }
.f-visual canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.f-tag { position: absolute; left: 14px; top: 14px; font-family: var(--mono); font-size: 11px; color: var(--app-text-2); background: rgba(25,28,32,.85); border: 1px solid var(--panel-stroke); padding: 5px 9px; border-radius: 999px; }
.caption { position: absolute; left: 50%; bottom: 7%; transform: translateX(-50%); background: rgba(25,28,32,.92); border: 1px solid var(--panel-stroke); border-radius: 14px; padding: .7em 1.1em; font-size: max(12px, 2.1cqw); white-space: nowrap; color: #fff; }
.caption span { color: var(--app-text-2); }
/* Chat mock (HTML, matches TextChatPanel tokens) */
.chat { position: absolute; top: 5%; right: 3.5%; bottom: 5%; width: 46%; background: var(--panel); border: 1px solid var(--panel-stroke); border-radius: 16px; padding: 3.2cqw 2.6cqw; display: flex; flex-direction: column; gap: 1.6cqw; font-size: max(10px, 1.7cqw); }
.chat-h { display: flex; align-items: center; gap: 1.2cqw; font-weight: 600; }
.chat-h i { width: 2.6cqw; height: 2.6cqw; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ffffff, #f1f2f5 30%, #d1d7dd 65%, #78828d); }
.chat-h small { display: block; color: var(--app-text-2); font-weight: 500; font-size: .8em; }
.msg { background: #22262b; border-radius: 12px; padding: .8em 1em; line-height: 1.4; color: #e8ebee; max-width: 92%; }
.msg.you { align-self: flex-end; background: #2c3138; }
.msg small { display: block; color: var(--app-text-2); font-size: .78em; margin-bottom: .25em; }
.act { display: flex; align-items: center; gap: .7em; border: 1px solid var(--panel-stroke); border-radius: 12px; padding: .6em .9em; color: #d2d6db; font-size: .9em; }
.act i { width: .9em; height: .9em; border-radius: 50%; background: #ffffff; }
.act span { margin-left: auto; color: #a7adb6; }
.compose { margin-top: auto; border: 1px solid var(--panel-stroke); border-radius: 12px; padding: .8em 1em; color: var(--app-text-2); display: flex; justify-content: space-between; }
.chat-stage { position: absolute; left: 0; top: 0; bottom: 0; width: 52%; }
/* Hand card */
.qcard { position: absolute; right: 4%; top: 50%; transform: translateY(-50%); width: 40%; background: var(--panel); border: 1px solid var(--panel-stroke); border-radius: 16px; padding: 2.4cqw; font-size: max(10px, 1.6cqw); display: grid; gap: 1.2cqw; }
.qcard b { font-size: 1.15em; }
.qcard p { color: #fff; line-height: 1.4; }
.qcard .a { border: 1px solid #6b7079; border-radius: 999px; padding: .7em 1em; text-align: center; }
.qcard .a.rec { background: #eeeeee; color: #111; border-color: #eeeeee; font-weight: 600; }
.qcard small { color: var(--app-text-2); }
.hand-stage { position: absolute; inset: 0 44% 0 0; }

/* Video */
.film { max-width: 980px; margin: 0 auto; position: relative; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid rgba(52,211,153,.22); background: #000; aspect-ratio: 16 / 10; }
.film picture { display: block; width: 100%; height: 100%; }
.film video, .film img { width: 100%; height: 100%; object-fit: contain; }
.film-play { position: absolute; inset: 0; display: grid; place-items: center; background: linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,.55)); border: 0; cursor: pointer; color: #fff; font: inherit; }
.film-play span { display: inline-flex; align-items: center; gap: 12px; padding: 14px 22px; border-radius: 999px; background: rgba(25,28,32,.82); border: 1px solid var(--panel-stroke); backdrop-filter: blur(8px); font-weight: 700; }
.film-play svg { width: 18px; height: 18px; fill: #fff; }
.film-note { text-align: center; max-width: 980px; margin: 12px auto 0; font-family: var(--mono); font-size: 12px; color: var(--text-dim); }

/* How it works */
.flow { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; position: relative; }
.step { background: linear-gradient(180deg, #0f1613, #0b100e); border: 1px solid var(--border-subtle); border-radius: var(--radius-md); padding: 28px; position: relative; }
.step .n { font-family: var(--mono); font-size: 12px; color: var(--emerald-bright); }
.step h3 { font-size: 20px; letter-spacing: -0.01em; margin: 14px 0 8px; }
.step p { font-size: 15px; line-height: 1.55; color: var(--text-sub); }
.step .ico { width: 44px; height: 44px; border-radius: 12px; background: var(--emerald-soft); border: 1px solid var(--border); display: grid; place-items: center; }
.step .ico svg { width: 22px; height: 22px; stroke: var(--emerald-bright); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.pipe { margin-top: 18px; display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; font-family: var(--mono); font-size: 12.5px; color: var(--text-sub); }
.pipe span { padding: 7px 12px; border-radius: 999px; border: 1px solid var(--border-subtle); background: rgba(255,255,255,.03); }
.pipe em { display: inline-flex; font-style: normal; color: var(--text-dim); }

/* Privacy */
.privacy { display: grid; grid-template-columns: 1.1fr 1fr; gap: 16px; }
.p-card { border-radius: var(--radius-lg); border: 1px solid var(--border-subtle); padding: 36px; background: #0b100e; }
.p-card.lead { background: radial-gradient(120% 90% at 0% 0%, rgba(52,211,153,.14), transparent 60%), #0b100e; border-color: var(--border); }
.p-list { list-style: none; display: grid; gap: 18px; margin-top: 22px; }
.p-list li { display: grid; grid-template-columns: 22px 1fr; gap: 12px; font-size: 16px; line-height: 1.55; color: var(--text-sub); }
.p-list li b { color: var(--text); font-weight: 650; }
.p-list svg { width: 20px; height: 20px; margin-top: 2px; stroke: var(--emerald-bright); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.p-card h3 { font-size: 24px; letter-spacing: -0.02em; }
.p-card.honest p { margin-top: 14px; font-size: 15.5px; line-height: 1.6; color: var(--text-sub); }

/* FAQ */
.faq { max-width: 860px; }
.faq details { border-top: 1px solid var(--border-subtle); }
.faq details:last-child { border-bottom: 1px solid var(--border-subtle); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 22px 4px; font-size: 18px; font-weight: 650; min-height: 48px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--mono); font-size: 20px; color: var(--emerald-bright); transition: transform .2s var(--ease-out); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 4px 22px; font-size: 16px; line-height: 1.6; color: var(--text-sub); max-width: 720px; }

/* Final CTA */
.final { margin: 140px 0 0; position: relative; border-radius: 36px; overflow: hidden; border: 1px solid var(--border); background: #000; text-align: center; padding: 72px 24px 0; isolation: isolate; }
.final::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(60% 60% at 50% 0%, rgba(52,211,153,.18), transparent 70%); }
.final h2 { font-size: clamp(2.2rem, 1.4rem + 3vw, 4rem); letter-spacing: -0.04em; line-height: 1; font-weight: 800; margin-top: 14px; }
.final p { margin: 18px auto 28px; max-width: 520px; color: var(--text-sub); font-size: 17px; line-height: 1.55; }
.final .mini { margin: 40px -24px 0; height: 240px; position: relative; -webkit-mask-image: linear-gradient(90deg, transparent, #000 18%, #000 82%, transparent); mask-image: linear-gradient(90deg, transparent, #000 18%, #000 82%, transparent); }
.final .mini canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

/* Footer (kept, plus JourneyDeck legal links) */
footer { margin-top: 96px; border-top: 1px solid var(--border-subtle); padding: 28px 0 36px; font-size: 13px; color: var(--text-dim); }
.footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px 24px; }
.footer-nav { display: flex; gap: 6px 18px; flex-wrap: wrap; }
.footer-nav a { display: inline-flex; align-items: center; min-height: 44px; padding: 6px 0; }
.footer-nav a:hover { color: var(--emerald-bright); }
.footer-legal { width: 100%; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px 18px; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.04); }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s var(--ease-out), transform .7s var(--ease-out); }
.reveal.in { opacity: 1; transform: none; }

@media (max-width: 960px) {
  .feature { grid-template-columns: 1fr; gap: 28px; padding: 32px 0; }
  .feature:nth-child(even) { grid-template-columns: 1fr; }
  .feature:nth-child(even) .f-copy { order: 0; }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .fact:nth-child(3) { border-left: 0; }
  .fact:nth-child(n+3) { border-top: 1px solid var(--border-subtle); }
  .flow, .privacy { grid-template-columns: 1fr; }
  .header-nav .anchor { display: none; }
}
@media (max-width: 640px) {
  :root { --gutter: 18px; }
  .brand-link span, .brand-divider { display: none; }
  .brand-link { min-width: 44px; min-height: 44px; margin-left: -9px; justify-content: center; }
  .hero { padding-top: 44px; }
  .hero-ctas .btn { width: 100%; }
  .device-wrap { margin-top: 36px; }
  .device { padding: 7px; border-radius: 22px; }
  .hero h1 { font-size: 2.45rem; }
  .chat .act { display: none; }
  .screen { border-radius: 16px; }
  .ui-status, .ui-bc { display: none; }
  .facts { grid-template-columns: 1fr; margin-top: 48px; }
  .fact { border-left: 0 !important; border-top: 1px solid var(--border-subtle); padding: 20px 4px; }
  .fact:first-child { border-top: 0; }
  .sec { padding-top: 84px; }
  .sec-head { margin-bottom: 28px; }
  .chat { width: 58%; }
  .chat-stage { width: 44%; }
  .qcard { width: 52%; }
  .hand-stage { inset: 0 50% 0 0; }
  .p-card { padding: 26px 22px; }
  .final { margin-top: 96px; border-radius: 24px; padding-top: 52px; }
  .final .mini { height: 150px; }
  .faq summary { font-size: 16.5px; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .pipe { flex-direction: column; }
  .pipe em { transform: rotate(90deg); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .faq summary::after, .screen canvas { transition: none; }
}
  