/* ==========================================================================
   Bloked — landing page
   Palette and type deliberately mirror the extension popup (popup.css)
   ========================================================================== */

:root {
  --bg: #ffffff;
  --surface: #f6f8fa;
  --surface-2: #eef1f4;
  --border: #d0d7de;
  --ink: #1f2328;
  --ink-2: #57606a;
  --ink-3: #8b949e;
  --accent: #1a7f37;
  --accent-hi: #15682d;
  --danger: #cf222e;
  --shadow: 0 1px 2px rgba(31, 35, 40, 0.06), 0 8px 24px rgba(31, 35, 40, 0.08);
  --shadow-lg: 0 2px 4px rgba(31, 35, 40, 0.07), 0 24px 48px rgba(31, 35, 40, 0.12);
  --radius: 10px;
  --wrap: 1080px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d1117;
    --surface: #161b22;
    --surface-2: #21262d;
    --border: #30363d;
    --ink: #e6edf3;
    --ink-2: #9198a1;
    --ink-3: #6e7681;
    --accent: #2da44e;
    --accent-hi: #3fb950;
    --danger: #f85149;
    --shadow: 0 1px 2px rgba(1, 4, 9, 0.4), 0 8px 24px rgba(1, 4, 9, 0.5);
    --shadow-lg: 0 2px 4px rgba(1, 4, 9, 0.5), 0 24px 48px rgba(1, 4, 9, 0.6);
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

/* keep anchored sections clear of the 60px sticky nav */
[id] {
  scroll-margin-top: 72px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
  font-size: 0.88em;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 0.1em 0.36em;
}

a {
  color: inherit;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}

.wrap.narrow {
  max-width: 720px;
}

.skip-link {
  position: absolute;
  left: -9999px;
}
.skip-link:focus {
  left: 12px;
  top: 12px;
  z-index: 100;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 12px;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ── buttons ─────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 9px 16px;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s, transform 0.1s;
  white-space: nowrap;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
  border-color: rgba(27, 31, 36, 0.15);
}
.btn-primary:hover {
  background: var(--accent-hi);
}

.btn-ghost {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--border);
}
.btn-ghost:hover {
  background: var(--surface-2);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 14px;
}
.btn-lg {
  padding: 12px 22px;
  font-size: 16px;
}
.btn-block {
  width: 100%;
}

.btn.is-disabled {
  background: var(--surface-2);
  color: var(--ink-3);
  border-color: var(--border);
  cursor: not-allowed;
  pointer-events: none;
}

/* ── nav ─────────────────────────────────────────────────────────────── */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  height: 60px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.brand-mark {
  height: 24px;
  width: 24px;
  border-radius: 5px;
}

.nav-links {
  display: flex;
  gap: 22px;
  margin-left: auto;
  font-size: 14px;
}

.nav-links a {
  color: var(--ink-2);
  text-decoration: none;
}
.nav-links a:hover {
  color: var(--ink);
}

/* ── hero ────────────────────────────────────────────────────────────── */

.hero {
  position: relative;
  padding: 84px 0 56px;
  background: var(--bg);
  background:
    radial-gradient(60% 60% at 18% 0%, color-mix(in srgb, var(--accent) 9%, transparent), transparent 70%),
    var(--bg);
  border-bottom: 1px solid var(--border);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}

.eyebrow {
  margin: 0 0 14px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  line-height: 1.06;
  letter-spacing: -0.03em;
  font-weight: 800;
}

.lede {
  margin: 0 0 28px;
  font-size: 1.1rem;
  color: var(--ink-2);
  max-width: 46ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 26px;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 13px;
  color: var(--ink-2);
}

.hero-badges li::before {
  content: "✓";
  color: var(--accent);
  font-weight: 700;
  margin-right: 7px;
}

/* popup recreation */

.hero-art {
  display: flex;
  justify-content: center;
}

.popup-frame {
  width: 320px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  transform: rotate(-1.2deg);
}

.popup {
  padding: 14px 16px 12px;
  font-size: 13px;
}

.popup-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.popup-logo {
  height: 26px;
  width: 26px;
  border-radius: 4px;
}

.switch {
  width: 36px;
  height: 20px;
  border-radius: 20px;
  background: var(--border);
  position: relative;
  display: inline-block;
}
.switch.on {
  background: var(--accent);
}
.switch .knob {
  position: absolute;
  height: 16px;
  width: 16px;
  border-radius: 50%;
  background: #fff;
  top: 2px;
  left: 2px;
}
.switch.on .knob {
  left: auto;
  right: 2px;
}

.popup-section {
  margin-bottom: 14px;
}

.popup-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 6px;
}

.popup-select,
.popup-input {
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg);
  padding: 6px 8px;
}

.popup-select::after {
  content: "⌄";
  float: right;
  color: var(--ink-3);
  line-height: 1;
}

.popup-input {
  flex: 1;
  color: var(--ink-3);
}

.popup-row {
  display: flex;
  gap: 6px;
}

.popup-btn {
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  padding: 6px 10px;
}
.popup-btn.wide {
  text-align: center;
}

.popup-list {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
}
.popup-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 8px;
  border-radius: 6px;
}
.popup-list li:nth-child(odd) {
  background: var(--surface);
}
.popup-list .x {
  color: var(--danger);
}

.popup-foot {
  font-size: 11px;
  color: var(--ink-3);
  text-align: center;
}

.scroll-cue {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 56px;
  font-size: 13px;
  color: var(--ink-3);
  text-decoration: none;
}
.scroll-cue:hover {
  color: var(--ink-2);
}
.scroll-cue svg {
  animation: nudge 1.8s ease-in-out infinite;
}

@keyframes nudge {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(4px); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .scroll-cue svg { animation: none; }
}

/* ── bands ───────────────────────────────────────────────────────────── */

.band {
  padding: 84px 0;
  border-bottom: 1px solid var(--border);
  scroll-margin-top: 60px;
}

.band.alt {
  background: var(--surface);
}

.section-title {
  margin: 0 0 10px;
  font-size: clamp(1.6rem, 3.2vw, 2.2rem);
  letter-spacing: -0.02em;
  font-weight: 700;
  line-height: 1.15;
}

.section-sub {
  margin: 0 0 40px;
  color: var(--ink-2);
  max-width: 58ch;
}

/* ── steps ───────────────────────────────────────────────────────────── */

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.steps li {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.step-n {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 14px;
}

.steps h3,
.feature h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
}

.steps p,
.feature p {
  margin: 0;
  color: var(--ink-2);
  font-size: 0.95rem;
}

/* ── demo ────────────────────────────────────────────────────────────── */

.demo {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.demo-tabs input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.demo-tabs > label {
  display: inline-block;
  padding: 12px 18px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-2);
  cursor: pointer;
  border-bottom: 2px solid transparent;
}

.demo-tabs > label:hover {
  color: var(--ink);
}

#m-off:checked ~ label[for="m-off"],
#m-hide:checked ~ label[for="m-hide"],
#m-blur:checked ~ label[for="m-blur"] {
  color: var(--ink);
  border-bottom-color: var(--accent);
}

.demo-tabs input:focus-visible + label {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.demo-feed {
  border-top: 1px solid var(--border);
  padding: 18px;
  display: grid;
  gap: 14px;
  background: var(--surface);
}

.card {
  display: flex;
  gap: 14px;
  align-items: center;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px;
  transition: filter 0.2s ease, opacity 0.2s ease;
}

.thumb {
  flex: none;
  width: 116px;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--surface-2), var(--border));
}

.card .meta h4 {
  margin: 0 0 4px;
  font-size: 0.95rem;
  letter-spacing: -0.01em;
}
.card .meta p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--ink-3);
}

/* the two filter styles, driven by the radios above */
#m-hide:checked ~ .demo-feed .card.match {
  display: none;
}
#m-blur:checked ~ .demo-feed .card.match {
  filter: blur(7px);
  opacity: 0.85;
}

.demo-note {
  margin: 14px 0 0;
  font-size: 13px;
  color: var(--ink-3);
}

/* ── features ────────────────────────────────────────────────────────── */

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  background: var(--bg);
}

/* ── download ────────────────────────────────────────────────────────── */

.download {
  background: var(--bg);
  background:
    radial-gradient(70% 70% at 50% 0%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 72%),
    var(--bg);
}

.dl-head {
  text-align: center;
}
.dl-head .section-sub {
  margin-inline: auto;
}

.dl-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  align-items: start;
  max-width: 860px;
  margin: 0 auto;
}

.dl-card {
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  background: var(--bg);
  box-shadow: var(--shadow);
}

.dl-card.featured {
  border-color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 45%, var(--border));
}

.dl-tag {
  position: absolute;
  top: -11px;
  left: 26px;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 20px;
}

.dl-card h3 {
  margin: 0 0 6px;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
}

.dl-card > p {
  margin: 0 0 18px;
  color: var(--ink-2);
  font-size: 0.95rem;
}

.dl-fine {
  margin: 12px 0 0;
  font-size: 12.5px;
  color: var(--ink-3);
  text-align: center;
}

.dl-steps {
  margin: 20px 0 0;
  padding-left: 20px;
  color: var(--ink-2);
  font-size: 0.92rem;
}
.dl-steps li {
  margin-bottom: 6px;
}

/* ── privacy ─────────────────────────────────────────────────────────── */

.check {
  list-style: none;
  margin: 0 0 26px;
  padding: 0;
}

.check li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 12px;
  color: var(--ink-2);
}

.check li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: -1px;
  color: var(--accent);
  font-weight: 700;
}

.aside {
  margin: 0;
  border-left: 3px solid var(--border);
  padding: 2px 0 2px 18px;
  color: var(--ink-3);
  font-size: 0.95rem;
}

/* ── faq ─────────────────────────────────────────────────────────────── */

details {
  border-bottom: 1px solid var(--border);
  padding: 4px 0;
}
details:first-of-type {
  border-top: 1px solid var(--border);
}

summary {
  cursor: pointer;
  padding: 16px 34px 16px 0;
  font-weight: 600;
  list-style: none;
  position: relative;
}
summary::-webkit-details-marker {
  display: none;
}
summary::after {
  content: "+";
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--ink-3);
  line-height: 1;
}
details[open] summary::after {
  content: "−";
}

details p {
  margin: 0 0 18px;
  color: var(--ink-2);
  max-width: 62ch;
}

/* ── closer + footer ─────────────────────────────────────────────────── */

.closer {
  padding: 92px 0;
  text-align: center;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.closer h2 {
  margin: 0 0 26px;
  font-size: clamp(1.7rem, 4vw, 2.6rem);
  letter-spacing: -0.025em;
  font-weight: 800;
}

.foot {
  padding: 40px 0;
  font-size: 14px;
  color: var(--ink-3);
}

.foot-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.foot-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  color: var(--ink);
}
.foot-brand img {
  height: 20px;
  width: 20px;
  border-radius: 4px;
}

.foot-links {
  display: flex;
  gap: 18px;
  margin-left: auto;
}
.foot-links a {
  color: var(--ink-3);
  text-decoration: none;
}
.foot-links a:hover {
  color: var(--ink);
}

.foot-fine {
  margin: 0;
  width: 100%;
}

/* ── responsive ──────────────────────────────────────────────────────── */

@media (max-width: 900px) {
  .hero {
    padding-top: 56px;
  }
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 44px;
  }
  .steps,
  .grid,
  .dl-cards {
    grid-template-columns: 1fr;
  }
  .band {
    padding: 60px 0;
  }
  .nav-links {
    display: none;
  }
  .brand {
    margin-right: auto;
  }
}

@media (max-width: 560px) {
  .wrap {
    padding: 0 18px;
  }
  .popup-frame {
    width: 100%;
    max-width: 320px;
    transform: none;
  }
  .demo-tabs > label {
    padding: 10px 13px;
    font-size: 13px;
  }
  .thumb {
    width: 84px;
  }
  .hero-actions .btn {
    width: 100%;
  }
  .foot-links {
    margin-left: 0;
  }
}

/* ── download verification block ─────────────────────────────────────── */

.dl-verify {
  margin-top: 18px;
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  background: var(--surface);
  padding: 16px 18px;
}

.dl-verify-h {
  margin: 0 0 8px;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink);
}

.dl-verify p {
  margin: 0 0 10px;
  font-size: 0.87rem;
  color: var(--ink-2);
  line-height: 1.55;
}

.dl-verify pre {
  margin: 0 0 12px;
  padding: 9px 11px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow-x: auto;
}

.dl-verify pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: 12px;
  color: var(--ink);
  white-space: pre;
}

/* the hash must be selectable and readable, but must not force the card wide */
.dl-verify pre code.hash {
  word-break: break-all;
  white-space: pre-wrap;
  color: var(--accent);
}

.dl-verify-f {
  margin: 0;
  font-size: 0.8rem;
  color: var(--ink-3);
}

.dl-verify-f a {
  color: var(--accent);
}
