/* TinyReel landing site. Dark and light themes, colors from the app's asset catalog. The page follows the
   system setting until the header's theme button picks one; layout.js stores that choice as <html data-theme>. */
:root {
  color-scheme: dark;
  --bg: #070b14;            /* navy black, like the app's dark mode */
  --surface: #0f1522;
  --surface-2: #161e2f;
  --line: #222d42;
  --text: #f1f5fb;
  --muted: #94a1b6;
  --accent: #5fb0ff;        /* AccentColor (dark): text and outlines */
  --grad-1: #6fa8ff;        /* GradientOneAccentColor (dark): gradient text */
  --grad-2: #4fe3d2;        /* GradientTwoAccentColor (dark) */
  --fill-1: #2e6bff;        /* Theme.brandTop: fills with white content */
  --fill-2: #0e9c90;        /* Theme.brandBottom */
  --teal: #21ccd1;          /* the teal glow in BrandGlowBackground */
  --line-strong: #33466a;   /* card hover border */
  --nav-bg: rgba(7,11,20,.72);
  --float-bg: rgba(15,21,34,.86);
  --shadow: rgba(0,0,0,.8);
  --trim-1: #1f2b40;
  --trim-2: #172133;
  --trim-dim: rgba(0,0,0,.5);
  --free-line: #2b3f62;
  --legal: #c4cddb;
  --orange: #ff9f2e;
  --radius: 22px;
  --max: 1120px;
  --font: "Inter Tight", system-ui, -apple-system, "Segoe UI", sans-serif;
}
/* Light: the system's light mode unless the visitor picked dark, or the visitor picked light. */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    color-scheme: light;
    --bg: #f4f7fb;            /* the app's light grouped background, a touch of blue */
    --surface: #ffffff;
    --surface-2: #edf1f7;
    --line: #dde4ee;
    --text: #0b1220;
    --muted: #5a6678;
    --accent: #1769e0;        /* AccentColor (light), about 5:1 on white */
    --grad-1: #1f5fe0;        /* GradientOneAccentColor (light) */
    --grad-2: #0a7f78;        /* GradientTwoAccentColor (light) */
    --teal: #0e9c90;
    --line-strong: #b5c6e2;
    --nav-bg: rgba(244,247,251,.78);
    --float-bg: rgba(255,255,255,.9);
    --shadow: rgba(16,24,40,.18);
    --trim-1: #dbe4f2;
    --trim-2: #cfdaeb;
    --trim-dim: rgba(255,255,255,.6);
    --free-line: #c3d3ee;
    --legal: #2c3646;
  }
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f4f7fb;            /* the app's light grouped background, a touch of blue */
  --surface: #ffffff;
  --surface-2: #edf1f7;
  --line: #dde4ee;
  --text: #0b1220;
  --muted: #5a6678;
  --accent: #1769e0;        /* AccentColor (light), about 5:1 on white */
  --grad-1: #1f5fe0;        /* GradientOneAccentColor (light) */
  --grad-2: #0a7f78;        /* GradientTwoAccentColor (light) */
  --teal: #0e9c90;
  --line-strong: #b5c6e2;
  --nav-bg: rgba(244,247,251,.78);
  --float-bg: rgba(255,255,255,.9);
  --shadow: rgba(16,24,40,.18);
  --trim-1: #dbe4f2;
  --trim-2: #cfdaeb;
  --trim-dim: rgba(255,255,255,.6);
  --free-line: #c3d3ee;
  --legal: #2c3646;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; }
img { display: block; max-width: 100%; }
.wrap { width: min(var(--max), 100% - 32px); margin-inline: auto; }
.eyebrow {
  display: inline-block;
  font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  color: var(--accent);
}
.grad-text {
  background: linear-gradient(100deg, var(--grad-1), var(--grad-2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
h1, h2, h3 { line-height: 1.05; letter-spacing: -0.03em; margin: 0; }
h2 { font-size: clamp(34px, 5vw, 56px); font-weight: 700; }
h3 { font-size: 22px; letter-spacing: -0.015em; line-height: 1.2; }
p { margin: 0; }
.muted { color: var(--muted); }
section { padding: 110px 0; }
.section-head { max-width: 680px; margin-bottom: 52px; display: grid; gap: 14px; }
.section-head.center { margin-inline: auto; text-align: center; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 24px; border-radius: 999px;
  font-weight: 600; font-size: 16px; text-decoration: none;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: linear-gradient(135deg, var(--fill-1), var(--fill-2)); color: #fff; box-shadow: 0 8px 30px -8px rgba(46,107,255,.55); }
.btn-primary:hover { box-shadow: 0 12px 40px -8px rgba(46,107,255,.75); }
.btn-ghost { border: 1px solid var(--line); background: var(--surface); }
.btn svg { width: 20px; height: 20px; }

/* Nav. The shared elements from layout.js add no box of their own, so the header stays sticky to the page. */
site-header, site-footer { display: contents; }
.nav {
  position: sticky; top: 0; z-index: 20;
  backdrop-filter: saturate(160%) blur(16px); -webkit-backdrop-filter: saturate(160%) blur(16px);
  background: var(--nav-bg);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease;
}
.nav.scrolled { border-bottom-color: var(--line); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 20px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 19px; letter-spacing: -0.02em; }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
.nav-links { display: flex; gap: 4px; list-style: none; margin: 0; padding: 4px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.nav-links a { display: block; padding: 7px 16px; border-radius: 999px; text-decoration: none; font-size: 14.5px; color: var(--muted); transition: color .15s, background .15s; }
.nav-links a:hover, .nav-links a.active { color: var(--text); background: var(--surface-2); }
.nav .btn { padding: 9px 18px; font-size: 14.5px; }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.theme-toggle {
  width: 40px; height: 40px; flex: none; display: grid; place-items: center; padding: 0; cursor: pointer;
  border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--text);
  transition: background .15s, border-color .15s;
}
.theme-toggle:hover { background: var(--surface-2); border-color: var(--line-strong); }
.theme-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.theme-toggle svg { width: 19px; height: 19px; }
/* The button shows the theme it switches to: a moon while light, a sun while dark. */
.theme-toggle .sun { display: block; }
.theme-toggle .moon { display: none; }
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .theme-toggle .sun { display: none; }
  :root:not([data-theme="dark"]) .theme-toggle .moon { display: block; }
}
:root[data-theme="light"] .theme-toggle .sun { display: none; }
:root[data-theme="light"] .theme-toggle .moon { display: block; }

/* Hero */
.hero { padding: 72px 0 40px; position: relative; text-align: center; }
.hero::before {
  content: ""; position: absolute; inset: -120px 0 auto; height: 720px; z-index: -1;
  background:
    radial-gradient(520px 300px at 50% 28%, rgba(46,107,255,.20), transparent 70%),
    radial-gradient(380px 260px at 72% 52%, rgba(33,204,209,.12), transparent 70%);
}
.hero h1 { font-size: clamp(48px, 8.4vw, 104px); font-weight: 800; letter-spacing: -0.045em; line-height: .95; }
.hero .lede { max-width: 600px; margin: 24px auto 34px; font-size: clamp(17px, 2vw, 20px); color: var(--muted); }
.hero-cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-meta { margin-top: 16px; font-size: 14px; color: var(--muted); }

/* Phone mock */
.stage { position: relative; margin: 70px auto 0; width: min(880px, 100%); height: 600px; }
.phone {
  /* The mock is an iPhone in dark mode in both themes. */
  --surface: #0f1522; --surface-2: #161e2f; --line: #222d42; --text: #f1f5fb; --muted: #94a1b6; --accent: #5fb0ff; --teal: #21ccd1;
  color: var(--text);
  position: absolute; left: 50%; top: 0; transform: translateX(-50%);
  width: 300px; height: 610px; border-radius: 52px; padding: 12px;
  background: linear-gradient(160deg, #262d3b, #10141d);
  box-shadow: 0 0 0 1px #2f384a, 0 60px 120px -30px var(--shadow), 0 0 120px -40px rgba(46,107,255,.45);
}
.screen {
  position: relative; height: 100%; border-radius: 41px; overflow: hidden;
  background: #000; padding: 54px 18px 18px; text-align: left;
  display: flex; flex-direction: column; gap: 14px;
}
.screen::before { content: ""; position: absolute; top: 12px; left: 50%; transform: translateX(-50%); width: 92px; height: 28px; border-radius: 20px; background: #0d0d0d; }
.scr-title { font-size: 26px; font-weight: 700; letter-spacing: -0.02em; }
.scr-sub { font-size: 13px; color: var(--muted); margin-top: -10px; }
.thumb {
  height: 150px; border-radius: 16px; position: relative; overflow: hidden;
  background:
    radial-gradient(120px 80px at 30% 70%, rgba(255,159,46,.55), transparent 70%),
    radial-gradient(160px 100px at 75% 30%, rgba(70,130,221,.6), transparent 70%),
    linear-gradient(180deg, #24324a, #3c2a20);
}
.thumb::after { content: "4K · 2:14"; position: absolute; right: 10px; bottom: 9px; font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 8px; background: rgba(0,0,0,.55); }
.bars { display: grid; gap: 10px; }
.bar-row { display: grid; gap: 5px; }
.bar-label { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--muted); }
.bar-label b { color: var(--text); font-weight: 600; }
.bar { height: 12px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: inherit; }
.bar.before i { width: 100%; background: var(--accent); }
.bar.after i { width: 7%; background: var(--teal); transition: width 1.4s cubic-bezier(.2,.8,.2,1); }
.saved { border-radius: 16px; padding: 14px; background: var(--surface); border: 1px solid var(--line); }
.saved .big { font-size: 34px; font-weight: 800; letter-spacing: -0.03em; line-height: 1; }
.saved .small { font-size: 12.5px; color: var(--muted); margin-top: 4px; }
.scr-buttons { margin-top: auto; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.scr-buttons span { text-align: center; font-size: 13.5px; font-weight: 600; padding: 11px 0; border-radius: 14px; background: var(--surface-2); }
.scr-buttons span:last-child { background: linear-gradient(100deg, var(--fill-1), var(--fill-2)); color: #fff; }

.float-card {
  position: absolute; padding: 14px 16px; border-radius: 18px; text-align: left;
  background: var(--float-bg); border: 1px solid var(--line);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 30px 60px -20px var(--shadow);
  font-size: 14px; animation: bob 6s ease-in-out infinite;
}
.float-card b { display: block; font-size: 15px; }
.float-card .k { display: block; color: var(--muted); font-size: 12.5px; }
.fc-1 { left: 0; top: 90px; }
.fc-2 { right: 0; top: 230px; animation-delay: -2s; }
.fc-3 { left: 40px; top: 390px; animation-delay: -4s; }
.chip { display: inline-flex; align-items: center; gap: 6px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 10px var(--teal); }
@keyframes bob { 50% { transform: translateY(-8px); } }

/* Send-anywhere strip */
.strip { padding: 40px 0 10px; text-align: center; }
.strip p { color: var(--muted); font-size: 14px; margin-bottom: 16px; }
.pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.pills span { padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 14.5px; }

/* Features: bento */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.card {
  position: relative; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; display: flex; flex-direction: column; gap: 10px;
  transition: border-color .2s ease, transform .2s ease;
}
.card:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.card p { color: var(--muted); font-size: 15.5px; }
.card .icon {
  width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; margin-bottom: 6px;
  background: linear-gradient(140deg, var(--fill-1), var(--fill-2)); color: #fff;
}
.card .icon svg { width: 24px; height: 24px; }
.span-3 { grid-column: span 3; }
.span-2 { grid-column: span 2; }
.card.tall { min-height: 300px; }
.tag { align-self: flex-start; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 99px; border: 1px solid var(--line); color: var(--muted); }

/* mini visuals inside cards */
.presets { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: auto; }
.presets div { padding: 12px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.presets div b { display: block; color: var(--text); font-size: 15px; }
.presets div.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.ratios { display: flex; gap: 8px; margin-top: auto; align-items: flex-end; }
.ratios i { border: 1.5px solid var(--muted); border-radius: 5px; }
.ratios i.on { border-color: var(--accent); background: rgba(95,176,255,.12); }
.trim { margin-top: auto; height: 44px; border-radius: 10px; position: relative; overflow: hidden;
  background: repeating-linear-gradient(90deg, var(--trim-1) 0 30px, var(--trim-2) 30px 60px); }
.trim::after { content: ""; position: absolute; inset: 0 22% 0 28%; border: 3px solid var(--accent); border-radius: 10px; box-shadow: 0 0 0 999px var(--trim-dim); }

/* Estimator */
.estimator { display: grid; grid-template-columns: 1.05fr 1fr; gap: 16px; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; }
.field { display: grid; gap: 10px; margin-bottom: 26px; }
.field label { font-size: 14px; color: var(--muted); display: flex; justify-content: space-between; }
.field label output { color: var(--text); font-weight: 600; }
.seg { display: flex; gap: 6px; padding: 5px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line); flex-wrap: wrap; }
.seg button {
  flex: 1; min-width: 0; padding: 10px 8px; border: 0; border-radius: 10px; cursor: pointer;
  background: transparent; color: var(--muted); font: inherit; font-size: 14.5px; font-weight: 600;
}
.seg button[aria-pressed="true"] { background: var(--bg); color: var(--text); box-shadow: inset 0 0 0 1px var(--accent); }
input[type=range] { width: 100%; accent-color: var(--accent); height: 28px; }
.result { display: flex; flex-direction: column; justify-content: space-between; gap: 24px; }
.result .num { font-size: clamp(54px, 7vw, 84px); font-weight: 800; letter-spacing: -0.045em; line-height: .95; }
.compare { display: grid; gap: 14px; }
.compare .bar { height: 16px; }
.compare .bar.after i { width: 10%; transition: width .5s cubic-bezier(.2,.8,.2,1); }
.fineprint { font-size: 13px; color: var(--muted); }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: step; }
.step { padding: 28px; border-radius: var(--radius); border: 1px solid var(--line); background: linear-gradient(180deg, var(--surface), transparent); }
.step::before { counter-increment: step; content: "0" counter(step); display: block; font-size: 14px; font-weight: 700; color: var(--accent); margin-bottom: 18px; }
.step p { color: var(--muted); margin-top: 8px; font-size: 15.5px; }

/* Privacy */
.privacy-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.privacy-hero {
  border-radius: 32px; padding: 64px 48px; margin-bottom: 16px; text-align: center; position: relative; overflow: hidden;
  border: 1px solid var(--line);
  background: radial-gradient(600px 260px at 50% 0%, rgba(33,204,209,.16), transparent 70%), var(--surface);
}
.privacy-hero h2 { margin: 12px 0 16px; }
.privacy-hero p { max-width: 560px; margin-inline: auto; color: var(--muted); font-size: 18px; }
.shield { width: 64px; height: 64px; margin: 0 auto 18px; color: var(--teal); }

/* Free */
.free {
  border-radius: 32px; padding: 56px; display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: center;
  background: linear-gradient(135deg, rgba(46,107,255,.18), rgba(33,204,209,.07) 60%, transparent), var(--surface);
  border: 1px solid var(--free-line);
}
.free .price { font-size: clamp(64px, 9vw, 112px); font-weight: 800; letter-spacing: -0.05em; line-height: .9; }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.checks li { display: flex; gap: 12px; align-items: flex-start; }
.checks li::before { content: ""; flex: none; width: 22px; height: 22px; margin-top: 1px; border-radius: 50%;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center/14px no-repeat, linear-gradient(135deg, var(--fill-1), var(--fill-2)); }

/* FAQ */
.faq { max-width: 780px; margin-inline: auto; display: grid; gap: 10px; }
.faq details { border: 1px solid var(--line); border-radius: 18px; background: var(--surface); padding: 0 22px; }
.faq summary { cursor: pointer; list-style: none; padding: 20px 0; font-weight: 600; font-size: 17px; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 24px; line-height: 1; color: var(--accent); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 0 20px; color: var(--muted); }

/* Contact + footer */
.contact { text-align: center; }
.contact .btn { margin-top: 28px; }
.final {
  margin-top: 30px; padding: 80px 24px; text-align: center; border-radius: 36px;
  background: radial-gradient(500px 240px at 50% 100%, rgba(46,107,255,.24), transparent 70%), var(--surface);
  border: 1px solid var(--line);
}
.final img { width: 88px; height: 88px; border-radius: 22px; margin: 0 auto 24px; box-shadow: 0 20px 50px -10px rgba(46,107,255,.45); }
.final h2 { margin-bottom: 28px; }
footer { padding: 40px 0 50px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 28px; }
footer nav { display: flex; gap: 22px; flex-wrap: wrap; }
footer a { text-decoration: none; }
footer a:hover { color: var(--text); }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .float-card { animation: none; }
  html { scroll-behavior: auto; }
}

/* Legal pages */
.legal { max-width: 760px; margin: 0 auto; padding: 60px 0 100px; }
.legal h1 { font-size: clamp(40px, 6vw, 60px); font-weight: 800; margin-bottom: 10px; }
.legal h2 { font-size: 24px; margin: 40px 0 12px; letter-spacing: -0.02em; }
.legal p, .legal li { color: var(--legal); }
.legal p + p { margin-top: 12px; }
.legal ul { padding-left: 20px; display: grid; gap: 6px; }

/* Responsive */
@media (max-width: 920px) {
  .nav-links { display: none; }
  .span-3, .span-2 { grid-column: span 6; }
  .estimator, .free { grid-template-columns: 1fr; }
  .steps, .privacy-grid { grid-template-columns: 1fr; }
  .free { padding: 36px 26px; }
  .privacy-hero { padding: 48px 24px; }
  section { padding: 80px 0; }
}
@media (max-width: 720px) {
  .stage { height: 620px; margin-top: 50px; }
  .float-card { display: none; }
}
