/* ThrottleScope website: same dark palette as the app. No external fonts; the only external script is AdSense (ads.js). */
:root {
  --bg: #14171d;
  --panel: #1c2029;
  --panel-alt: #222733;
  --border: #2e3442;
  --text: #e6eaf0;
  --muted: #8a93a6;
  --accent: #4fa3ff;
  --hot: #e5484d;
  --ok: #2fb36b;
  --radius: 8px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 "Segoe UI", system-ui, -apple-system, sans-serif;
}

a { color: var(--accent); }
a:hover { color: #7dbcff; }

code {
  font-family: Consolas, "Cascadia Mono", monospace;
  font-size: 0.9em;
  background: var(--panel-alt);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1px 5px;
}

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px; }
.wrap.narrow { max-width: 820px; }

section { padding: 56px 0; }
section + section { border-top: 1px solid var(--border); }

h1, h2, h3 { line-height: 1.25; margin: 0 0 14px; }
h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.1rem; }
h3.sub { margin-top: 40px; }

.small { font-size: 0.9rem; color: var(--muted); }

/* Hidden on screen but still read by screen readers and search engines (not display:none, which hides it from both). */
.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(20, 23, 29, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--border);
}
.header-row { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 600; font-size: 1.2rem; }
nav { display: flex; gap: 22px; }
nav a { color: var(--muted); text-decoration: none; font-weight: 600; }
nav a:hover { color: var(--text); }

/* Intro */
.intro { background: radial-gradient(900px 400px at 85% 20%, rgba(34, 211, 238, 0.10), transparent 70%); }
.intro-grid { display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: center; }
.lead { font-size: 1.15rem; }
.hero-icon { filter: drop-shadow(0 10px 40px rgba(34, 211, 238, 0.25)); }

.cta-row { display: flex; align-items: center; flex-wrap: wrap; gap: 14px 18px; margin-top: 26px; }
.cta-note { color: var(--muted); font-size: 0.95rem; }

.button {
  display: inline-block;
  padding: 12px 22px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--panel-alt);
  color: var(--text);
  font-weight: 600;
  text-decoration: none;
}
.button.primary { background: var(--accent); border-color: var(--accent); color: #0b1220; }
.button.primary:hover { background: #7dbcff; color: #0b1220; }
.button.wide { display: block; text-align: center; margin-top: 18px; }

/* Screenshot */
.shot { padding-top: 0; border-top: 0 !important; }
.shot figure { margin: 0; }
.shot img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}
.shot figcaption { color: var(--muted); font-size: 0.92rem; margin-top: 12px; }

/* Features */
.features { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.features article {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
}
.features article h3 { color: var(--text); }
.features article h3::before {
  content: "";
  display: inline-block;
  width: 10px; height: 10px;
  margin-right: 9px;
  border-radius: 2px;
  background: linear-gradient(135deg, var(--accent), var(--hot));
  vertical-align: 1px;
}
.features p { margin: 0; color: #c3c9d4; }

/* Download */
.download { background: var(--panel); }
.download-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.card { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px 24px; }

.facts { width: 100%; border-collapse: collapse; }
.facts th { text-align: left; color: var(--muted); font-weight: 600; padding: 6px 16px 6px 0; vertical-align: top; white-space: nowrap; }
.facts td { padding: 6px 0; }
.hash { display: inline-block; word-break: break-all; font-size: 0.8rem; }

.steps { margin: 0; padding-left: 22px; }
.steps li { margin-bottom: 8px; }

.support { width: 100%; border-collapse: collapse; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.support th, .support td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--border); }
.support thead th { background: var(--panel-alt); color: var(--muted); font-weight: 600; }
.support tr:last-child td { border-bottom: 0; }

.changes dt { font-weight: 700; }
.changes dt span { color: var(--muted); font-weight: 400; margin-left: 8px; }
.changes dd { margin: 4px 0 0; color: #c3c9d4; }

/* Privacy page */
.prose h2 { font-size: 1.3rem; margin-top: 32px; }
.prose li { margin-bottom: 8px; }

/* FAQ */
details {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 18px;
  margin-bottom: 10px;
}
summary { cursor: pointer; font-weight: 600; }
details p { margin: 10px 0 0; color: #c3c9d4; }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 26px 0; color: var(--muted); }
.footer-row { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px 30px; }

/* Ads. The top banner sits under the header; the side rails sit outside the 1120 px content column
   and only appear when the window is wide enough for them (1120 + 2 × (160 + 24 gap) + margins). */
main { position: relative; }

.ad-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  background: var(--panel);
  border: 1px dashed var(--border);
  border-radius: 4px;
  color: var(--muted);
  font-size: 0.8rem;
}
.ad-slot.live { background: none; border: 0; border-radius: 0; }

/* Ads are hidden unless ads.js turns them on (ENABLED) by adding "ads-on" to <html>. */
.ad-top { display: none; justify-content: center; padding: 0 20px 38px; }
.ads-on .ad-top { display: flex; }
.ads-on .intro { padding-top: 18px; } /* the top banner sits inside the intro, so they share its background */
.ad-top .ad-narrow { display: none; }

.ad-rail { position: absolute; top: 18px; bottom: 0; width: 160px; display: none; }
.ad-rail.left  { right: calc(50% + 560px + 24px); }
.ad-rail.right { left:  calc(50% + 560px + 24px); }
.ad-rail .ad-slot { position: sticky; top: 88px; } /* stays beside the content below the 64 px header */

@media (min-width: 1540px) {
  .ads-on .ad-rail { display: block; }
}
@media (max-width: 779px) {
  .ad-top .ad-wide { display: none; }
  .ad-top .ad-narrow { display: flex; }
}

/* Grid and flex children may shrink below their content's width (long words wrap instead of widening the page). */
.intro-grid > *, .download-grid > *, .features > * { min-width: 0; }
p, li, td, dd { overflow-wrap: anywhere; }

/* Phones and narrow windows */
@media (max-width: 760px) {
  nav a:not([href="#download"]) { display: none; } /* keep the header to one line: just Download */
  .intro-grid { grid-template-columns: 1fr; }
  .hero-icon { display: none; }
  .download-grid { grid-template-columns: 1fr; }
  .support thead { display: none; }
  .support td { display: block; border-bottom: 0; padding: 4px 14px; }
  .support tr { display: block; padding: 8px 0; border-bottom: 1px solid var(--border); }
  .support td:first-child { font-weight: 600; }
  section { padding: 40px 0; }
}
