/* PlayLens site — landing, blog, privacy. Tokens first; components below use tokens only. */
:root {
  --bg: #fafbf9;
  --surface: #ffffff;
  --fg: #0e1a14;
  --muted: #52605a;
  --line: #e0e7e2;
  --accent: #0a7d52;
  --accent-fg: #ffffff;
  --accent-soft: #e4f3eb;
  --ink: #0e1a14;
  --ink-fg: #eaf2ec;
  --ink-muted: #9db0a5;
  --fresh: #1e8e3e;
  --aging: #a15c00;
  --stale: #c5221f;
  --shadow: 0 1px 2px rgba(14, 26, 20, 0.05), 0 12px 32px rgba(14, 26, 20, 0.08);
  --f-display: 'Bricolage Grotesque', 'Segoe UI', system-ui, sans-serif;
  --f-body: 'Instrument Sans', 'Segoe UI', system-ui, sans-serif;
  --f-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --bg: #0a110e;
    --surface: #111b16;
    --fg: #e8f0ea;
    --muted: #93a69b;
    --line: #223029;
    --accent: #43d19a;
    --accent-fg: #04281a;
    --accent-soft: #12281e;
    --ink: #0f1d17;
    --ink-fg: #eaf2ec;
    --ink-muted: #93a69b;
    --fresh: #6dd58c;
    --aging: #fcc934;
    --stale: #f28b82;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 32px rgba(0, 0, 0, 0.35);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.65 var(--f-body);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-underline-offset: 3px; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
img { max-width: 100%; height: auto; }
h1, h2, h3 { font-family: var(--f-display); letter-spacing: -0.02em; text-wrap: balance; margin: 0; }
code { font: 0.88em var(--f-mono); background: var(--accent-soft); border-radius: 5px; padding: 1px 6px; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }
.eyebrow { font: 600 12px/1 var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }

/* nav */
.nav { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.nav .wrap { display: flex; align-items: center; gap: 28px; height: 60px; }
.brand { display: inline-flex; align-items: center; gap: 9px; font: 700 18px var(--f-display); color: var(--fg); text-decoration: none; letter-spacing: -0.02em; }
.brand svg { width: 26px; height: 26px; }
.links { display: flex; gap: 22px; margin-left: 8px; font-size: 14.5px; }
.links a { color: var(--muted); text-decoration: none; }
.links a:hover, .links a[aria-current] { color: var(--fg); }
.nav .btn { margin-left: auto; }
@media (max-width: 720px) { .links { display: none; } .nav .wrap { gap: 12px; } }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 20px; border-radius: 10px; font: 600 14.5px var(--f-body); text-decoration: none; border: 1px solid var(--line); color: var(--fg); background: var(--surface); }
.btn:hover { border-color: var(--accent); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--accent-fg); }
.btn-primary:hover { filter: brightness(1.07); }
.btn-sm { padding: 8px 14px; font-size: 13.5px; }
.btn-lg { padding: 14px 26px; font-size: 16px; }

/* hero */
.hero { padding: 76px 0 24px; text-align: center; }
.hero h1 { font-size: clamp(36px, 6.4vw, 66px); line-height: 1.04; font-weight: 700; max-width: 17ch; margin: 18px auto 0; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lead { max-width: 60ch; margin: 22px auto 0; font-size: 18px; color: var(--muted); }
.cta-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 30px; }
.trust { display: flex; gap: 8px 22px; justify-content: center; flex-wrap: wrap; margin: 22px 0 0; padding: 0; list-style: none; font-size: 13.5px; color: var(--muted); }
.trust li::before { content: '✓ '; color: var(--accent); font-weight: 700; }
.frame { margin: 52px auto 0; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); box-shadow: var(--shadow); overflow: hidden; }
.frame .bar { display: flex; gap: 6px; align-items: center; height: 36px; padding: 0 14px; border-bottom: 1px solid var(--line); }
.frame .bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.frame .bar span { margin-left: 10px; font: 12px var(--f-mono); color: var(--muted); }
.frame img { display: block; width: 100%; }

/* card-line sample */
.sample { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: center; }
.sample-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 22px; box-shadow: var(--shadow); font-size: 14px; }
.sample-card .row { display: flex; gap: 14px; align-items: center; }
.sample-card .ic { width: 56px; height: 56px; border-radius: 14px; background: linear-gradient(135deg, var(--accent), color-mix(in srgb, var(--accent) 35%, var(--bg))); flex: none; }
.sample-card b { font-family: var(--f-display); font-size: 16px; }
.sample-card .sub { color: var(--muted); font-size: 12.5px; }
.sample-card .lines { margin-top: 16px; display: grid; gap: 6px; font: 13px var(--f-mono); }
.sample-card .lines span { display: flex; gap: 10px; }
.sample-card .lines em { font-style: normal; color: var(--muted); min-width: 92px; }
.fresh { color: var(--fresh); } .aging { color: var(--aging); } .stale { color: var(--stale); }
@media (max-width: 820px) { .sample { grid-template-columns: 1fr; } }

/* sections */
.sec { padding: 88px 0 0; }
.sec-head { max-width: 640px; }
.sec-head h2 { font-size: clamp(28px, 4vw, 40px); line-height: 1.1; margin-top: 12px; }
.sec-head p { margin: 14px 0 0; color: var(--muted); font-size: 17px; }
.sec-head.center { margin: 0 auto; text-align: center; }

.feat { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin-top: 40px; background: var(--line); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.feat > div { background: var(--surface); padding: 26px; }
.feat .tag { font: 600 11.5px var(--f-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.feat h3 { margin: 10px 0 8px; font-size: 19px; }
.feat p { margin: 0; font-size: 14.5px; color: var(--muted); }
.feat a.more { display: inline-block; margin-top: 12px; font-size: 13.5px; font-weight: 600; }
@media (max-width: 900px) { .feat { grid-template-columns: 1fr 1fr; } }
@media (max-width: 580px) { .feat { grid-template-columns: 1fr; } }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin: 40px 0 0; padding: 0; list-style: none; counter-reset: s; }
.steps li { counter-increment: s; border-top: 2px solid var(--fg); padding-top: 16px; }
.steps li::before { content: counter(s); font: 600 13px var(--f-mono); color: var(--accent); }
.steps h3 { margin: 6px 0 6px; font-size: 20px; }
.steps p { margin: 0; color: var(--muted); font-size: 15px; }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }

.uses { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 40px; }
.use { border: 1px solid var(--line); border-radius: 16px; padding: 24px; background: var(--surface); }
.use h3 { font-size: 19px; }
.use p { margin: 8px 0 0; color: var(--muted); font-size: 15px; }
@media (max-width: 700px) { .uses { grid-template-columns: 1fr; } }

/* pricing */
.plans { display: grid; grid-template-columns: 1fr 1.15fr; gap: 18px; margin-top: 40px; align-items: stretch; }
.plan { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 28px; display: flex; flex-direction: column; }
.plan.pro { border: 2px solid var(--accent); position: relative; }
.plan .badge { position: absolute; top: -13px; right: 22px; background: var(--accent); color: var(--accent-fg); font: 600 11.5px var(--f-mono); letter-spacing: 0.05em; text-transform: uppercase; padding: 5px 11px; border-radius: 999px; }
.plan h3 { font-size: 22px; }
.plan .price { margin: 4px 0 18px; color: var(--muted); font-size: 14px; }
.plan ul { margin: 0; padding: 0; list-style: none; font-size: 14.5px; }
.plan li { padding: 6px 0 6px 26px; position: relative; }
.plan li::before { content: '✓'; position: absolute; left: 2px; color: var(--accent); font-weight: 700; }
.plan li small { display: block; color: var(--muted); font-size: 13px; }
.tiers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 22px 0 10px; }
.tier { display: flex; flex-direction: column; gap: 2px; padding: 12px 8px; border: 1px solid var(--line); border-radius: 12px; text-align: center; color: var(--fg); text-decoration: none; font-size: 13px; }
.tier strong { font: 700 20px var(--f-display); }
.tier em { font-style: normal; font-size: 12px; color: var(--muted); }
.tier .tag { font-size: 11.5px; font-weight: 600; color: var(--accent); }
.tier[aria-disabled='true'] { cursor: default; opacity: 0.72; }
.tier:not([aria-disabled='true']):hover { background: var(--accent-soft); border-color: var(--accent); }
.fine { margin: 14px 0 0; font-size: 13px; color: var(--muted); }
@media (max-width: 860px) { .plans { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .tiers { grid-template-columns: 1fr; } }

/* blog teaser + index */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 36px; }
.pcard { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); overflow: hidden; text-decoration: none; color: var(--fg); }
.pcard:hover { border-color: var(--accent); }
.pcard img { aspect-ratio: 16/10; object-fit: cover; object-position: top left; border-bottom: 1px solid var(--line); width: 100%; }
.pcard .b { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.pcard .k { font: 600 11.5px var(--f-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.pcard h3 { font-size: 19px; line-height: 1.2; }
.pcard p { margin: 0; color: var(--muted); font-size: 14.5px; }
.pcard .m { margin-top: auto; padding-top: 6px; font-size: 12.5px; color: var(--muted); }
@media (max-width: 900px) { .cards { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .cards { grid-template-columns: 1fr; } }

/* faq */
.faq { display: grid; gap: 10px; margin-top: 36px; max-width: 800px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; }
.faq summary { cursor: pointer; font-weight: 600; font-size: 15.5px; }
.faq summary::marker { color: var(--accent); }
.faq p { margin: 10px 0 2px; color: var(--muted); font-size: 15px; }

/* closing band */
.band { margin-top: 96px; background: var(--ink); color: var(--ink-fg); text-align: center; padding: 80px 0; }
.band h2 { font-size: clamp(28px, 4.4vw, 44px); max-width: 20ch; margin: 0 auto; }
.band p { color: var(--ink-muted); margin: 14px auto 0; max-width: 52ch; }
.band .btn { margin-top: 26px; }

/* footer */
.foot { background: var(--bg); border-top: 1px solid var(--line); padding: 52px 0 36px; font-size: 14px; color: var(--muted); }
.foot .cols { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 32px; }
.foot h4 { margin: 0 0 12px; font: 600 12px var(--f-mono); letter-spacing: 0.07em; text-transform: uppercase; color: var(--fg); }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.foot a { color: var(--muted); text-decoration: none; }
.foot a:hover { color: var(--accent); }
.foot .about { max-width: 34ch; margin: 12px 0 0; }
.foot .legal { margin: 40px 0 0; padding-top: 20px; border-top: 1px solid var(--line); font-size: 12.5px; }
@media (max-width: 760px) { .foot .cols { grid-template-columns: 1fr 1fr; } .foot .cols > :first-child { grid-column: 1 / -1; } }

/* blog index head */
.page-head { padding: 64px 0 8px; }
.page-head h1 { font-size: clamp(34px, 5.4vw, 54px); line-height: 1.05; margin-top: 14px; }
.page-head p { color: var(--muted); font-size: 18px; max-width: 56ch; margin: 16px 0 0; }

/* post */
.crumbs { padding: 28px 0 0; font-size: 13.5px; color: var(--muted); }
.crumbs a { color: var(--muted); text-decoration: none; } .crumbs a:hover { color: var(--accent); }
.post-head { padding: 18px 0 26px; }
.post-head h1 { font-size: clamp(32px, 5vw, 50px); line-height: 1.06; max-width: 20ch; }
.post-head .lede { font-size: 19px; color: var(--muted); max-width: 60ch; margin: 18px 0 0; }
.meta { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 20px; font: 12.5px var(--f-mono); color: var(--muted); }
.post-grid { display: grid; grid-template-columns: 220px minmax(0, 700px); gap: 56px; padding-bottom: 40px; }
.toc { position: sticky; top: 84px; align-self: start; font-size: 13.5px; }
.toc h4 { margin: 0 0 10px; font: 600 11.5px var(--f-mono); letter-spacing: 0.07em; text-transform: uppercase; color: var(--fg); }
.toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; border-left: 1px solid var(--line); }
.toc a { display: block; padding-left: 14px; color: var(--muted); text-decoration: none; line-height: 1.4; }
.toc a:hover { color: var(--accent); }
@media (max-width: 960px) { .post-grid { grid-template-columns: 1fr; gap: 20px; } .toc { position: static; } .toc ol { border: 0; } .toc a { padding-left: 0; } }
.prose { font-size: 17px; }
.prose h2 { font-size: 29px; line-height: 1.15; margin: 52px 0 14px; }
.prose h3 { font-size: 21px; margin: 32px 0 8px; }
.prose p { margin: 0 0 16px; }
.prose ul, .prose ol { padding-left: 22px; margin: 0 0 18px; }
.prose li { margin: 6px 0; }
.prose figure { margin: 28px 0; }
.prose figure img { border: 1px solid var(--line); border-radius: 12px; display: block; box-shadow: var(--shadow); }
.prose figcaption { font-size: 13.5px; color: var(--muted); margin-top: 10px; }
.callout { border: 1px solid var(--line); border-left: 4px solid var(--accent); background: var(--accent-soft); border-radius: 10px; padding: 14px 18px; margin: 24px 0; font-size: 15.5px; }
.callout p { margin: 0; } .callout p + p { margin-top: 8px; }
.callout.warn { border-left-color: var(--aging); }
.tablewrap { overflow-x: auto; margin: 22px 0; border: 1px solid var(--line); border-radius: 12px; }
.prose table { border-collapse: collapse; width: 100%; font-size: 14.5px; background: var(--surface); }
.prose th, .prose td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { font: 600 12px var(--f-mono); letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); background: var(--bg); }
.prose tr:last-child td { border-bottom: 0; }
kbd { font: 12px var(--f-mono); background: var(--surface); border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; padding: 1px 6px; }
.cta-box { margin: 48px 0 0; padding: 30px; border-radius: 16px; background: var(--ink); color: var(--ink-fg); }
.cta-box h3 { font-size: 24px; margin: 0; }
.cta-box p { color: var(--ink-muted); margin: 8px 0 18px; font-size: 15.5px; }
.related { padding: 8px 0 0; }
.related h2 { font-size: 24px; }
.updated { font-size: 13.5px; color: var(--muted); }

/* privacy and other plain pages */
.plain { padding: 56px 0 24px; }
.plain h1 { font-size: 40px; }
.plain h2 { font-size: 22px; margin: 36px 0 10px; }
.plain p, .plain li { color: var(--fg); }
.plain .sub { color: var(--muted); margin: 10px 0 28px; }
