:root {
  --bg: #0e141b;
  --bg-2: #121a23;
  --card: #171f29;
  --line: #2a3644;
  --text: #e8eef4;
  --muted: #93a0ae;
  --accent: #3ecf8e;
  --accent-2: #7dd3fc;
  --warn: #f0b429;
  --danger: #e85d4c;
  --ok: #3ecf8e;
  --shadow: 0 12px 40px rgba(0, 0, 0, .28);
  --radius: 18px;
  --font: "Segoe UI", system-ui, -apple-system, sans-serif;
}
html[data-theme="light"] {
  --bg: #f4f1ea;
  --bg-2: #fff;
  --card: #fff;
  --line: #e2d9cc;
  --text: #1c2430;
  --muted: #5c6774;
  --shadow: 0 10px 30px rgba(28, 36, 48, .08);
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  background: radial-gradient(1200px 600px at 10% -10%, #1c3344 0%, var(--bg) 55%);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.55;
}
a { color: var(--accent-2); text-decoration: none; }
a:hover { text-decoration: underline; }
.top, .foot {
  max-width: 1120px;
  margin: 0 auto;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.brand { display: flex; gap: 12px; align-items: center; color: inherit; text-decoration: none; }
.brand:hover { text-decoration: none; color: inherit; }
.brand small { display: block; color: var(--muted); font-size: 12px; }
.logo {
  width: 42px; height: 42px; border-radius: 50%;
  object-fit: cover; display: block; flex-shrink: 0;
}
nav { display: flex; gap: 14px; align-items: center; }
main { max-width: 1120px; margin: 0 auto; padding: 8px 24px 64px; }
.hero {
  text-align: center;
  padding: 48px 0 24px;
  max-width: 760px;
  margin: 0 auto;
}
.hero h1 { font-size: clamp(32px, 5vw, 52px); line-height: 1.15; margin: 0 0 18px; letter-spacing: -0.03em; }
.lead { font-size: 18px; color: var(--muted); margin: 0 auto 8px; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: 12px; color: var(--accent); margin: 0 0 8px; }
.audit-form {
  margin: 28px auto 12px;
  display: flex; gap: 10px; width: 100%;
  background: var(--card); padding: 8px; border-radius: 16px; border: 1px solid var(--line);
  box-shadow: var(--shadow);
  text-align: left;
}
.hint { max-width: 560px; margin: 0 auto; }
.audit-form input {
  flex: 1; border: 0; background: transparent; color: var(--text);
  font-size: 16px; padding: 12px 14px; outline: none;
}
button, .btn {
  appearance: none; border: 0; cursor: pointer;
  background: var(--accent); color: #062016; font-weight: 700;
  padding: 12px 18px; border-radius: 12px; font-size: 15px;
  text-decoration: none; display: inline-flex; align-items: center;
  justify-content: center; line-height: 1.2; box-sizing: border-box;
}
button:hover, .btn:hover { filter: brightness(1.05); text-decoration: none; }
.ghost {
  background: transparent; color: var(--text); border: 1px solid var(--line);
}
a.ghost:hover { text-decoration: none; color: var(--text); }
.hint, .muted { color: var(--muted); }
.sr { position: absolute; left: -9999px; }
.progress { margin: 28px auto 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 24px; text-align: left; }
.progress ol { padding-left: 20px; }
.progress li { margin: 6px 0; }
.progress li.running { color: var(--accent-2); }
.progress li.done { color: var(--ok); }
.progress li.warn { color: var(--warn); }
.hidden { display: none !important; }
.error { color: var(--danger); background: color-mix(in srgb, var(--danger) 12%, transparent); padding: 12px 14px; border-radius: 12px; }
.about { margin-top: 56px; }
.grid { display: grid; gap: 16px; }
.features { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.two { grid-template-columns: 1fr 1fr; }
main > .card,
main > .grid {
  margin-bottom: 20px;
}
.kp {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.features article, .card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px;
}
.features h3 { margin: 0 0 8px; font-size: 16px; }
.features p { margin: 0; color: var(--muted); }
.report-head { display: flex; justify-content: space-between; gap: 24px; align-items: start; margin-bottom: 20px; }
.score { min-width: 220px; text-align: center; }
.score-num { font-size: 56px; font-weight: 800; line-height: 1; }
.score.good { border-color: color-mix(in srgb, var(--ok) 50%, var(--line)); }
.score.mid { border-color: color-mix(in srgb, var(--warn) 50%, var(--line)); }
.score.bad { border-color: color-mix(in srgb, var(--danger) 50%, var(--line)); }
.meta, .toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.toolbar { margin: 8px 0 20px; }
.tag, .pill {
  display: inline-block; padding: 2px 8px; border-radius: 999px;
  border: 1px solid var(--line); font-size: 12px; color: var(--muted);
}
.tag.warn, .pill { text-transform: lowercase; }
.tag.warn { color: var(--warn); border-color: var(--warn); }
.tag.ok { color: var(--ok); border-color: var(--ok); }
.findings { display: grid; gap: 12px; }
.finding { border-left: 3px solid var(--line); padding-left: 12px; }
.finding.sev-high, .finding.sev-critical { border-color: var(--danger); }
.finding.sev-medium { border-color: var(--warn); }
.finding.sev-low, .finding.sev-info { border-color: var(--accent-2); }
.finding header { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.finding h3 { margin: 0; font-size: 18px; }
.rec { background: var(--bg-2); padding: 10px 12px; border-radius: 10px; }
.law { font-size: 13px; color: var(--muted); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.mono { font-family: ui-monospace, Consolas, monospace; word-break: break-all; }
.plain { padding-left: 18px; }
.disclaimer { color: var(--muted); font-size: 13px; margin-top: 28px; }
.packages {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
  gap: 20px;
  align-items: stretch;
}
.packages article {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 100%;
  padding: 20px 20px 18px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 16px;
}
.packages h3 {
  margin: 0 0 10px;
  font-size: 17px;
  line-height: 1.3;
  min-height: 2.6em;
  text-wrap: balance;
}
.pkg-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 3px 8px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 18%, transparent);
  color: var(--accent);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .02em;
  line-height: 1.2;
}
.pkg-desc {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
  min-height: 4.35em;
}
.pkg-list {
  margin: 0;
  padding: 0;
  list-style: none;
  flex: 1;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}
.pkg-list li {
  position: relative;
  margin: 0 0 8px;
  padding-left: 1.1em;
}
.pkg-list li:last-child { margin-bottom: 0; }
.pkg-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .55em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.price {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 20px;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.2;
}
.pkg-featured {
  border-color: color-mix(in srgb, var(--accent) 50%, var(--line));
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 22%, transparent);
  background: color-mix(in srgb, var(--accent) 6%, var(--bg-2));
}
.pkg-featured h3 { padding-right: 5.5em; }
.prose { max-width: 720px; }
.prose h2 { margin-top: 1.8em; font-size: 1.15rem; }
.prose p, .prose li { color: var(--muted); }
.prose h1, .prose h2 { color: var(--text); }
.foot { border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; flex-wrap: wrap; }
.foot-links { display: flex; gap: 14px; flex-wrap: wrap; }
.compare-added { color: var(--danger); }
.compare-removed { color: var(--ok); }
.to-top {
  display: none;
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 40;
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: 50%;
  font-size: 22px;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease;
}
.page-audit .to-top { display: inline-flex; }
.to-top.is-visible { opacity: 1; pointer-events: auto; }
@media (max-width: 800px) {
  .audit-form, .report-head, .two, .top, .foot { flex-direction: column; }
  .two { grid-template-columns: 1fr; }
}
@media print {
  body { background: #fff; color: #111; }
  .top nav, .toolbar.noprint, .foot, #theme-toggle, .to-top { display: none !important; }
  .card, .features article, .packages article { break-inside: avoid; border-color: #ddd; box-shadow: none; }
}
