/* Shared styles for the free tool pages (speed test, online reader). Same tokens as index.html. */
:root {
  --bg: #0A0A0B; --bg-2: #121214; --bg-3: #0F0F0F; --line: rgba(255,255,255,.08);
  --text: #F2F2F2; --muted: rgba(235,235,245,.6); --faint: rgba(235,235,245,.38);
  --acc: #F36B4A; --acc-deep: #E24F2F; --acc-soft: rgba(243,107,74,.14);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: Inter, -apple-system, system-ui, sans-serif; -webkit-font-smoothing: antialiased; line-height: 1.55; overflow-x: clip; }
a { color: inherit; }
.wrap { width: min(980px, 100% - 32px); margin: 0 auto; }
.narrow { width: min(720px, 100% - 32px); margin: 0 auto; }
.acc { color: var(--acc); }
:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }
[hidden] { display: none !important; }

/* header / footer */
.top { position: sticky; top: 0; z-index: 20; background: rgba(10,10,11,.75); backdrop-filter: saturate(160%) blur(18px); -webkit-backdrop-filter: saturate(160%) blur(18px); border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; align-items: center; gap: 22px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 19px; letter-spacing: -.03em; text-decoration: none; }
.brand img { width: 30px; height: 30px; border-radius: 7px; }
.top nav { display: flex; gap: 22px; margin-left: auto; font-size: 15px; color: var(--muted); }
.top nav a { text-decoration: none; } .top nav a:hover, .top nav a[aria-current] { color: var(--text); }
@media (max-width: 680px) { .top nav { display: none; } .top .btn { margin-left: auto; } }
.foot { margin-top: 110px; padding: 40px 0 50px; border-top: 1px solid var(--line); color: var(--faint); font-size: 14px; }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 14px 26px; }
.foot a { text-decoration: none; } .foot a:hover { color: var(--text); }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 50px; padding: 0 24px; border-radius: 25px; border: 0; cursor: pointer;
  font: 600 16px/1 Inter, -apple-system, sans-serif; letter-spacing: -.01em; text-decoration: none; transition: transform .15s, background .2s, box-shadow .2s; white-space: nowrap; }
.btn-primary { background: var(--acc-deep); color: #fff; box-shadow: 0 14px 40px -14px rgba(226,79,47,.75); }
.btn-primary:hover { transform: translateY(-1px); }
.btn-ghost { background: rgba(255,255,255,.04); color: var(--text); border: 1px solid var(--line); }
.btn-ghost:hover { background: rgba(255,255,255,.08); }
.btn-sm { height: 40px; padding: 0 16px; font-size: 14px; }
.store-badge { display: inline-block; line-height: 0; filter: drop-shadow(0 14px 30px rgba(226,79,47,.35)); transition: transform .2s; }
.store-badge img { height: 52px; width: auto; }
.store-badge:hover { transform: translateY(-2px); }

/* page head */
.hero { text-align: center; padding: 70px 0 34px; position: relative; overflow-x: clip; }
.hero::before { content: ""; position: absolute; left: 50%; top: -160px; width: 900px; height: 560px; translate: -50% 0; pointer-events: none; background: radial-gradient(closest-side, rgba(243,107,74,.14), transparent); }
.kicker { position: relative; font-size: 13px; font-weight: 600; letter-spacing: .28em; text-transform: uppercase; color: var(--acc); }
h1 { position: relative; font-size: clamp(40px, 7vw, 76px); line-height: 1; letter-spacing: -.05em; font-weight: 800; margin: 16px auto 18px; max-width: 15ch; }
.lead { position: relative; font-size: clamp(17px, 2.2vw, 20px); color: var(--muted); max-width: 46ch; margin: 0 auto; }

/* panels */
.panel { border-radius: 30px; background: var(--bg-2); border: 1px solid var(--line); padding: 28px; }
@media (max-width: 600px) { .panel { padding: 20px; border-radius: 24px; } }

/* RSVP stage (same look as the app's reader: ORP letter + guide ticks) */
.stage { position: relative; height: clamp(240px, 36vw, 360px); display: grid; place-items: center; border-radius: 26px; background: var(--bg-3); border: 1px solid var(--line);
  cursor: pointer; user-select: none; -webkit-user-select: none; touch-action: pan-y; overflow: hidden; }
.stage::before { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 80% at 50% 50%, rgba(243,107,74,.10), transparent 70%); pointer-events: none; }
.word { position: relative; font: 700 clamp(44px, 8.4vw, 92px)/1.15 -apple-system, "SF Pro Display", Inter, sans-serif; letter-spacing: -.02em; white-space: pre; padding: .4em 0; max-width: 96%; }
.word .o { color: var(--acc); position: relative; }
.word .o::before, .word .o::after { content: ""; position: absolute; left: 50%; width: 3px; margin-left: -1.5px; height: .24em; background: var(--acc); opacity: .55; }
.word .o::before { top: -.38em; } .word .o::after { bottom: -.38em; }
.stage-hint { position: absolute; bottom: 16px; left: 0; right: 0; text-align: center; font-size: 13px; color: var(--faint); transition: opacity .3s; }
.boost { position: absolute; top: 16px; right: 18px; font-size: 12px; font-weight: 600; color: var(--acc); background: var(--acc-soft); padding: 4px 10px; border-radius: 99px; opacity: 0; transition: opacity .2s; }
.is-boosted .boost { opacity: 1; }
.progress { height: 4px; border-radius: 2px; background: rgba(235,235,245,.14); overflow: hidden; }
.progress i { display: block; height: 100%; width: 0; background: var(--acc); }
.play { width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--acc-deep); display: grid; place-items: center; cursor: pointer; flex: none; transition: transform .15s; }
.play:active { transform: scale(.92); }
.play .pa { display: none; } .is-playing .play .pa { display: block; } .is-playing .play .pl { display: none; }
input[type=range] { -webkit-appearance: none; appearance: none; width: 150px; height: 4px; border-radius: 2px; background: rgba(235,235,245,.18); }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.4); cursor: pointer; }
input[type=range]::-moz-range-thumb { width: 20px; height: 20px; border: 0; border-radius: 50%; background: #fff; cursor: pointer; }
output { font-weight: 600; color: var(--acc); font-variant-numeric: tabular-nums; }

/* app upsell */
.upsell { margin-top: 28px; display: flex; gap: 22px; align-items: center; flex-wrap: wrap; padding: 26px 28px; border-radius: 26px;
  background: linear-gradient(160deg, rgba(243,107,74,.15), rgba(243,107,74,.03) 60%), var(--bg-2); border: 1px solid rgba(243,107,74,.32); }
.upsell img.icon { width: 64px; height: 64px; border-radius: 15px; flex: none; }
.upsell div { flex: 1; min-width: 220px; }
.upsell b { display: block; font-size: 19px; letter-spacing: -.02em; margin-bottom: 4px; }
.upsell p { margin: 0; color: var(--muted); font-size: 15px; }

/* article content under the tool (helps people and search engines) */
.content { margin-top: 90px; }
.content h2 { font-size: clamp(28px, 4vw, 40px); letter-spacing: -.04em; line-height: 1.08; margin: 54px 0 14px; }
.content h3 { font-size: 19px; letter-spacing: -.02em; margin: 26px 0 6px; }
.content p, .content li { color: var(--muted); font-size: 17px; }
.content p { margin: 0 0 14px; }
.content ul { padding-left: 20px; }
.content small { color: var(--faint); font-size: 13px; }
details { border-bottom: 1px solid var(--line); }
summary { list-style: none; cursor: pointer; padding: 20px 36px 20px 0; font-size: 18px; font-weight: 600; letter-spacing: -.02em; position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 4px; top: 50%; translate: 0 -50%; font-size: 24px; font-weight: 400; color: var(--acc); transition: rotate .25s; }
details[open] summary::after { rotate: 45deg; }
details p { margin: 0 0 20px !important; }

.toast { position: fixed; left: 50%; bottom: 28px; translate: -50% 20px; padding: 12px 20px; border-radius: 14px; background: #2A2A2E; color: #fff; font-size: 15px;
  opacity: 0; pointer-events: none; transition: opacity .25s, translate .25s; z-index: 50; }
.toast.show { opacity: 1; translate: -50% 0; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
