/* Privacy Devices — shared design system
   Same layout/typography as the original — only the colours changed:
   red accent → neon PURPLE, with neon GREEN as the "verified/on" accent. */
:root {
  /* primary accent — purple (was red #cc0000) */
  --red: #a855f7;
  --red-h: #9333ea;
  --red-faint: rgba(168,85,247,.14);
  --bg: #0b0a0f;
  --surface: #141220;
  --surface-2: #1b1830;
  --surface-3: #241f3a;
  --border: #241f33;
  --border-2: #322a48;
  --border-3: #453a5f;
  --text: #ece8f5;
  --muted: #8b83a6;
  --dim: #4a4360;
  --green: #39ff9e;
  --green-bg: #06231a;
  --yellow: #eab308;
  --yellow-bg: #1c1500;
  --r: 8px;
  --r-lg: 12px;
  --shadow: 0 2px 12px rgba(0,0,0,.5);
  /* aliases so any --purple/--pink references keep resolving */
  --purple: var(--red);
  --purple-h: var(--red-h);
  --pink: var(--red);
  --pink-h: var(--red-h);
  --magenta: #f0347e;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 15px;
  line-height: 1.65;
  min-height: 100vh;
}

h1, h2, h3, h4 { line-height: 1.2; font-weight: 700; letter-spacing: -.01em; }
p { color: var(--text); }
a { color: #c084fc; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Buttons ─────────────────────────────────────────── */
/* STYLE 2 · outline buttons — transparent with a violet edge, fill on hover */
.btn, button {
  display: inline-flex; align-items: center; gap: .4rem;
  background: transparent; color: var(--red);
  border: 1px solid var(--red); border-radius: 7px;
  padding: .55rem 1.2rem; font-size: .875rem; font-weight: 600;
  cursor: pointer; transition: background .12s, color .12s, border-color .12s;
  white-space: nowrap; text-decoration: none;
  font-family: inherit;
}
.btn:hover:not(:disabled), button:hover:not(:disabled) { background: var(--red); color: #fff; }
.btn:disabled, button:disabled { background: var(--surface-2); color: var(--dim); cursor: default; }
.btn-ghost { background: transparent; border: 1px solid var(--border-2); color: var(--text); }
.btn-ghost:hover:not(:disabled) { background: var(--surface-2); }
.btn-sm { padding: .35rem .8rem; font-size: .78rem; }
.btn-lg { padding: .85rem 2rem; font-size: 1rem; }
.btn-xl { padding: 1rem 2.5rem; font-size: 1.1rem; border-radius: var(--r-lg); }
.btn-green { background: #15803d; }
.btn-green:hover:not(:disabled) { background: #166534; }

/* ── Progress ─────────────────────────────────────────── */
progress {
  -webkit-appearance: none; appearance: none;
  display: block; width: 100%; height: 5px;
  border: none; border-radius: 3px; background: var(--border); overflow: hidden;
}
progress::-webkit-progress-bar { background: var(--border); }
progress::-webkit-progress-value { background: var(--red); }
progress::-moz-progress-bar { background: var(--red); }

/* ── Tags / chips ─────────────────────────────────────── */
.tag {
  display: inline-block; font-size: .65rem; font-weight: 700;
  letter-spacing: .07em; text-transform: uppercase;
  padding: 2px 7px; border-radius: 4px;
  background: var(--red); color: #fff;
}
.tag-green { background: #06231a; color: var(--green); }
.tag-yellow { background: #422006; color: var(--yellow); }
.tag-dim { background: var(--surface-2); color: var(--muted); }
.tag-blue { background: #1e3a5f; color: #60a5fa; }

/* ── Cards ────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 1.25rem 1.4rem;
}
.card-sm { padding: .9rem 1rem; border-radius: var(--r); }

/* ── Status line ──────────────────────────────────────── */
.status-line {
  margin-top: .6rem; font-size: .85rem;
  min-height: 1.2em;
}
.status-line.error { color: #ff6b6b; }
.status-line.ok { color: var(--green); }

/* ── Toggle switch ────────────────────────────────────── */
.toggle-row {
  display: flex; align-items: center; gap: 1rem;
  padding: .75rem 0; border-bottom: 1px solid var(--border);
}
.toggle-row:last-child { border-bottom: none; }
.toggle-info { flex: 1; }
.toggle-info strong { display: block; font-size: .9rem; }
.toggle-info span { font-size: .8rem; color: var(--muted); }
.toggle-switch {
  position: relative; width: 40px; height: 22px; flex-shrink: 0;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.toggle-slider {
  position: absolute; inset: 0; cursor: pointer;
  background: var(--surface-3); border-radius: 11px;
  transition: background .2s;
}
.toggle-slider::before {
  content: ''; position: absolute;
  width: 16px; height: 16px; border-radius: 50%;
  left: 3px; top: 3px; background: var(--muted);
  transition: transform .2s, background .2s;
}
.toggle-switch input:checked + .toggle-slider { background: var(--green-bg); }
.toggle-switch input:checked + .toggle-slider::before {
  transform: translateX(18px); background: var(--green);
}
.toggle-status { font-size: .72rem; color: var(--muted); min-width: 52px; text-align: right; }
.toggle-status.applied { color: var(--green); }

/* ── Step progress badge ──────────────────────────────── */
.step-badge {
  width: 22px; height: 22px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: .65rem; font-weight: 700;
  background: var(--surface-3); color: var(--muted);
  border: 1px solid var(--border-2);
}
.step-badge.active { background: var(--red); color: #fff; border-color: var(--red); }
.step-badge.done { background: var(--green-bg); color: var(--green); border-color: #14532d; }

/* ── Code block ───────────────────────────────────────── */
.code-block {
  background: var(--surface-2); border: 1px solid var(--border-2);
  border-radius: var(--r); padding: .75rem 1rem; margin: .5rem 0;
  font-family: 'Cascadia Code', 'Fira Code', 'Consolas', monospace;
  font-size: .8rem; color: #d4d4d4; overflow-x: auto;
  white-space: pre-wrap; word-break: break-all;
}

/* ── Guided step list ─────────────────────────────────── */
.guide-steps { list-style: none; counter-reset: gs; padding: 0; }
.guide-steps li {
  counter-increment: gs; display: flex; align-items: flex-start;
  gap: .75rem; padding: .6rem 0; border-bottom: 1px solid var(--border);
  font-size: .88rem;
}
.guide-steps li:last-child { border-bottom: none; }
.guide-steps li::before {
  content: counter(gs); display: flex; align-items: center;
  justify-content: center; flex-shrink: 0;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--surface-3); color: var(--muted);
  font-size: .7rem; font-weight: 700; border: 1px solid var(--border-2);
}

/* ── Utility ──────────────────────────────────────────── */
.flex { display: flex; }
.flex-col { display: flex; flex-direction: column; }
.gap-sm { gap: .5rem; }
.gap-md { gap: 1rem; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.mt-sm { margin-top: .5rem; }
.mt-md { margin-top: 1rem; }
.mt-lg { margin-top: 1.5rem; }
.mb-sm { margin-bottom: .5rem; }
.mb-md { margin-bottom: 1rem; }
.text-muted { color: var(--muted); }
.text-sm { font-size: .85rem; }
.text-xs { font-size: .75rem; }
.text-green { color: var(--green); }
.text-yellow { color: var(--yellow); }
.text-red { color: #c084fc; }
[hidden] { display: none !important; }
