/* Perfect — the marketing pages. The app's two styles: Steam (default) —
   Steam's Oct 2026 achievement pages, navy with purple progress and gold for
   rare, filled rounded cards — and Classic, Perfect's own near-black and steel
   blue with outlined cards (data-style="classic", set by /style.js). Headings
   in the system font, mixed case, as the app has drawn them since build 32.
   System fonts only: a font CDN would hand every visitor's IP to a third
   party, which the privacy policy rules out. */

:root {
  --bg: #1B2838;
  --bg2: #16202D;
  --surface: #202D3D;
  --surface2: #25344A;
  --line: #2A3747;
  --ink: #F1F2F3;
  --muted: #ACB2B8;
  --dim: #939AA2;
  --steel: #66C0F4;
  --good: #5BC48C;
  --progress: #B658C4;
  --done: #C774D3;
  --legendary: #FFD60A;
  --epic: #E8A04C;
  --rare: #C2A275;
  --uncommon: #9AA6B4;
  --common: #939AA2;
  --radius: 12px;
  --card-bg: var(--surface);
  --card-line: transparent;
  --nav-bg: rgba(27, 40, 56, .78);
  --glow: rgba(182, 88, 196, .22);
  --glow2: rgba(102, 192, 244, .10);
  --cta: linear-gradient(90deg, #06BFFF, #2D73FF);
  --cta-hover: linear-gradient(90deg, #3ACCFF, #4D88FF);
  --cta-ink: #FFFFFF;
  --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --body: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --gutter: clamp(16px, 4vw, 48px);
  color-scheme: dark;
}
:root[data-style="classic"] {
  --bg: #080B10;
  --bg2: #0C1219;
  --surface: #101720;
  --surface2: #151E29;
  --line: #1E2833;
  --ink: #EDF2F8;
  --muted: #8195AC;
  --dim: #7589A0;
  --steel: #4C9AE8;
  --good: #4CC38A;
  --progress: #4C9AE8;
  --done: #4CC38A;
  --legendary: #F5C263;
  --epic: #D99B3F;
  --rare: #A88B5C;
  --uncommon: #8496AB;
  --common: #788AA2;
  --radius: 8px;
  --card-bg: #0E141C;
  --card-line: var(--line);
  --nav-bg: rgba(8, 11, 16, .72);
  --glow: rgba(245, 194, 99, .16);
  --glow2: rgba(76, 154, 232, .07);
  --cta: var(--legendary);
  --cta-hover: #FFD27E;
  --cta-ink: #1A1206;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.6 var(--body); -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: var(--steel); text-decoration: none; }
a:hover { text-decoration: underline; }
/* height: auto — the screenshots carry width and height attributes, and
   without it they kept the attribute's height at any width (stretched). */
img { max-width: 100%; height: auto; display: block; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 var(--gutter); }
.label { font: 600 .74rem/1 var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.gold { color: var(--legendary); }
.accent { color: var(--done); }

/* ---- nav ---- */
nav.top { position: sticky; top: 0; z-index: 40; backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); background: var(--nav-bg); border-bottom: 1px solid var(--line); }
nav.top .wrap { display: flex; align-items: center; gap: 28px; height: 60px; }
.wordmark { font: 800 1.2rem/1 var(--display); letter-spacing: .26em; color: var(--ink); }
.wordmark:hover { text-decoration: none; }
nav.top .links { margin-left: auto; display: flex; gap: 24px; align-items: center; }
nav.top .links a { color: var(--muted); font: 500 .95rem/1 var(--body); }
nav.top .links a:hover { color: var(--ink); text-decoration: none; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 13px 22px; border-radius: var(--radius);
  font: 600 1rem/1 var(--body);
  border: 1px solid var(--card-line); color: var(--ink); background: var(--surface2);
  transition: transform .15s ease, filter .15s ease, background .15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); filter: brightness(1.12); }
.btn.primary { background: var(--cta); border-color: transparent; color: var(--cta-ink); }
.btn.primary:hover { background: var(--cta-hover); filter: none; }
nav.top .btn { padding: 9px 16px; font-size: .9rem; white-space: nowrap; }
nav.top .links a.btn { color: var(--ink); }

/* ---- hero ---- */
.hero { position: relative; padding: clamp(56px, 9vw, 120px) 0 clamp(64px, 8vw, 110px); overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto auto; width: 70vw; height: 70vw; max-width: 900px; max-height: 900px;
  background: radial-gradient(closest-side, var(--glow), var(--glow2) 55%, transparent 72%);
  pointer-events: none;
}
.hero .wrap { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(32px, 5vw, 80px); align-items: center; position: relative; }
.hero h1 { font: 800 clamp(2.8rem, 7vw, 5.6rem)/1 var(--display); letter-spacing: -.025em; margin: 18px 0 0; }
.hero h1 .gold { color: var(--legendary); }
.hero h1 .soft { color: var(--muted); }
.hero p.lede { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: var(--muted); max-width: 34rem; margin: 26px 0 34px; }
.hero p.lede strong { color: var(--ink); font-weight: 600; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.cta .note { color: var(--dim); font-size: .88rem; width: 100%; margin-top: 6px; }

/* The stack of notifications: each one lands in turn, the rarest last. */
.toasts { position: relative; display: grid; gap: 14px; }
.toast {
  display: grid; grid-template-columns: 52px 1fr auto; gap: 14px; align-items: center;
  padding: 14px 16px; background: var(--card-bg); border: 1px solid var(--card-line); border-radius: calc(var(--radius) + 4px);
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .7);
  opacity: 0; transform: translateY(18px) scale(.98);
  animation: land .7s cubic-bezier(.2, .8, .2, 1) forwards;
}
.toast:nth-child(1) { animation-delay: .25s; }
.toast:nth-child(2) { animation-delay: .65s; margin-left: 6%; }
.toast:nth-child(3) { animation-delay: 1.05s; margin-left: 12%; }
.toast:nth-child(4) { animation-delay: 1.55s; margin-left: 3%; }
.toast .icon {
  width: 52px; height: 52px; border-radius: var(--radius); display: grid; place-items: center;
  background: var(--bg2); border: 2px solid var(--tier, var(--line)); font: 700 1.4rem/1 var(--display); color: var(--tier, var(--muted));
}
.toast img.icon { padding: 0; object-fit: cover; }
.toast .what { min-width: 0; }
.toast .kicker { font: 600 .7rem/1 var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--tier, var(--muted)); }
.toast .name { font-weight: 600; margin-top: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.toast .game { color: var(--dim); font-size: .85rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.toast .pct { font: 600 1rem/1 var(--mono); color: var(--tier, var(--muted)); }
.toast.perfect { background: linear-gradient(100deg, color-mix(in srgb, var(--done) 26%, var(--card-bg)), var(--card-bg) 65%); }
.toast.perfect .name { font: 800 1.5rem/1.1 var(--display); color: var(--done); }
@keyframes land { to { opacity: 1; transform: none; } }

/* ---- ticker of facts ---- */
.ticker { border-block: 1px solid var(--line); background: var(--bg2); overflow: hidden; }
.ticker .row { display: flex; gap: 56px; padding: 16px 0; width: max-content; animation: slide 46s linear infinite; }
.ticker span { font: 600 .8rem/1 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); white-space: nowrap; }
.ticker span b { color: var(--done); font-weight: 600; }
@keyframes slide { to { transform: translateX(-50%); } }

/* ---- sections ---- */
section { padding: clamp(72px, 10vw, 128px) 0; }
.head { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: end; margin-bottom: 44px; }
.head h2 { font: 800 clamp(2rem, 4.4vw, 3.4rem)/1.05 var(--display); letter-spacing: -.02em; margin: 14px 0 0; }
.head p { color: var(--muted); margin: 0; max-width: 32rem; }

/* Features: filled cards (outlined in Classic), as the app draws them. */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.card { background: var(--card-bg); border: 1px solid var(--card-line); border-radius: var(--radius); padding: 26px 24px 28px; transition: transform .2s ease, filter .2s ease; }
.card:hover { transform: translateY(-2px); filter: brightness(1.08); }
.card .where { color: var(--done); }
.card h3 { font: 700 1.35rem/1.15 var(--display); letter-spacing: -.01em; margin: 14px 0 10px; }
.card p { color: var(--muted); margin: 0; font-size: .98rem; }

/* ---- screenshots ---- */
.shots { display: flex; gap: 22px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px var(--gutter) 28px; margin: 0 calc(-1 * var(--gutter)); }
.shots figure { margin: 0; flex: 0 0 auto; width: clamp(220px, 24vw, 290px); scroll-snap-align: center; }
.shots img { width: 100%; aspect-ratio: 1320 / 2868; object-fit: cover; border-radius: 30px; border: 1px solid var(--line); box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .8); background: var(--bg2); }
.shots figcaption { margin-top: 14px; color: var(--muted); font-size: .92rem; }
.shots figcaption b { display: block; color: var(--ink); font: 700 1.05rem/1.3 var(--display); }

/* ---- facts-only manifesto ---- */
.manifesto { background: var(--bg2); border-block: 1px solid var(--line); }
.manifesto .wrap { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(32px, 6vw, 96px); }
.manifesto blockquote { margin: 0; font: 800 clamp(2rem, 4.4vw, 3.4rem)/1.05 var(--display); letter-spacing: -.02em; }
.manifesto blockquote em { font-style: normal; color: var(--legendary); }
.manifesto ol { list-style: none; margin: 0; padding: 0; counter-reset: f; }
.manifesto li { counter-increment: f; display: grid; grid-template-columns: 52px 1fr; padding: 18px 0; border-top: 1px solid var(--line); color: var(--muted); }
.manifesto li::before { content: counter(f, decimal-leading-zero); font: 600 .9rem/1.7 var(--mono); color: var(--dim); }
.manifesto li b { color: var(--ink); font-weight: 600; }

/* ---- closing ---- */
.closing { text-align: center; }
.closing h2 { font: 800 clamp(2.4rem, 6vw, 4.4rem)/1 var(--display); letter-spacing: -.025em; margin: 0 0 18px; }
.closing h2 .gold { color: var(--legendary); }
.closing p { color: var(--muted); max-width: 34rem; margin: 0 auto 30px; }
.closing .cta { justify-content: center; }

footer.site { border-top: 1px solid var(--line); padding: 34px 0 44px; color: var(--dim); font-size: .88rem; }
footer.site .wrap { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; }
footer.site .legal { width: 100%; margin-top: 6px; }

/* The style switch: two segments, like the app's Settings → Appearance. */
.styleswitch { display: inline-flex; align-items: center; gap: 4px; padding: 3px; border-radius: 999px; background: var(--surface); border: 1px solid var(--card-line); }
.styleswitch span { padding: 0 8px 0 10px; color: var(--dim); font-size: .82rem; }
.styleswitch button { background: none; border: 0; border-radius: 999px; padding: 6px 14px; font: 500 .85rem/1 var(--body); color: var(--muted); cursor: pointer; }
.styleswitch button[aria-pressed="true"] { background: var(--surface2); color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .3); }
footer.site .styleswitch { margin-left: auto; }

/* ---- document pages (privacy, support) ---- */
main.doc { max-width: 44rem; margin: 0 auto; padding: 56px var(--gutter) 72px; }
main.doc h1 { font: 800 clamp(2.2rem, 5vw, 3.2rem)/1.05 var(--display); letter-spacing: -.02em; margin: 10px 0 6px; }
main.doc h2 { font: 700 1.25rem/1.3 var(--display); color: var(--ink); margin: 40px 0 10px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
main.doc h3 { font-size: 1.02rem; margin: 26px 0 4px; }
main.doc .sub { color: var(--muted); }
main.doc ul { padding-left: 1.2rem; }

@media (max-width: 900px) {
  .hero .wrap, .head, .manifesto .wrap { grid-template-columns: 1fr; }
  .cards { grid-template-columns: 1fr 1fr; }
  .toast:nth-child(n) { margin-left: 0; }
}
@media (max-width: 600px) {
  .cards { grid-template-columns: 1fr; }
  nav.top .links a:not(.btn) { display: none; }
  .toast { grid-template-columns: 44px 1fr auto; }
  .toast .icon { width: 44px; height: 44px; }
  footer.site .styleswitch { margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .toast { animation: none; opacity: 1; transform: none; }
  .ticker .row { animation: none; }
  .card, .btn { transition: none; }
  html { scroll-behavior: auto; }
}
