/* Shared page styles, in the original dark design. */
:root {
  --bg: #080F1E;
  --bg2: #0C1628;
  --surface: #0F1D33;
  --card: rgba(15,29,51,.92);
  --raised: #131F35;
  --border: rgba(79,140,255,.15);
  --border-strong: rgba(79,140,255,.28);
  --blue: #4F8CFF;
  --blue2: #3B6FE8;
  --ice: #A8C5FF;
  --teal: #34D399;
  --amber: #FBBF24;
  --rose: #F87171;
  --text: #E8F0FF;
  --muted: #7A96C4;
  --dim: #3E5280;
  --font: 'Inter', sans-serif;
  --head: 'Space Grotesk', sans-serif;
  --mono: 'JetBrains Mono', monospace;
}
*, *::before, *::after { box-sizing: border-box; }
html { font-size: 15px; -webkit-font-smoothing: antialiased; }
body { margin: 0; font-family: var(--font); background: var(--bg); color: var(--text); min-height: 100vh; line-height: 1.55; }
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(79,140,255,.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(79,140,255,.022) 1px, transparent 1px);
  background-size: 56px 56px;
  pointer-events: none;
  z-index: 0;
}
a { color: var(--blue); }
a:hover { color: var(--ice); }
h1, h2, h3 { font-family: var(--head); margin: 0; letter-spacing: -.02em; }
h2 { font-size: 1.2rem; font-weight: 700; }
h3 { font-size: .9rem; font-weight: 700; }
p { margin: 0; }
.wrap { position: relative; z-index: 1; max-width: 960px; margin: 0 auto; padding: 32px 28px 80px; }
.muted { color: var(--muted); }
.small { font-size: .8rem; }
section { margin-top: 36px; }
section > h2 + p { margin-top: 4px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 16px;
  border-radius: 9px;
  background: rgba(79,140,255,.07);
  border: 1px solid var(--border);
  color: var(--muted);
  font: 500 .8rem var(--font);
  text-decoration: none;
  cursor: pointer;
  transition: all .15s;
}
.btn:hover { background: rgba(79,140,255,.13); color: var(--text); }
.btn-main {
  background: linear-gradient(135deg, var(--blue2), var(--blue));
  border: none;
  color: #fff;
  font-family: var(--head);
  font-size: .85rem;
  font-weight: 700;
  padding: 10px 20px;
  box-shadow: 0 4px 20px rgba(79,140,255,.3);
}
.btn-main:hover { color: #fff; background: linear-gradient(135deg, var(--blue2), var(--blue)); opacity: .9; transform: translateY(-1px); }
.btn-small { padding: 6px 12px; font-size: .74rem; border-radius: 8px; }
.btn-danger { color: var(--rose); border-color: rgba(248,113,113,.25); background: rgba(248,113,113,.06); }
.btn-danger:hover { color: var(--rose); background: rgba(248,113,113,.12); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }

/* Verdict card, styled like the original score card */
.verdict {
  position: relative;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 28px 32px;
}
.verdict::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--blue2), var(--blue));
}
.verdict-site {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-family: var(--mono);
  font-size: .73rem;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.verdict-site::before {
  content: '';
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 8px var(--teal);
  flex-shrink: 0;
}
.verdict h1 { font-size: clamp(1.6rem, 3.6vw, 2.2rem); font-weight: 700; letter-spacing: -.03em; line-height: 1.15; max-width: 22em; }
.verdict-line { margin-top: 10px; color: var(--muted); font-size: .9rem; max-width: 46em; }
.verdict-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 22px; }

/* Ordered to-do */
.todo { list-style: none; margin: 14px 0 0; padding: 0; counter-reset: todo; display: flex; flex-direction: column; gap: 8px; }
.todo li {
  counter-increment: todo;
  position: relative;
  padding: 14px 18px 14px 60px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
}
.todo li::before {
  content: counter(todo);
  position: absolute;
  left: 16px;
  top: 14px;
  width: 30px; height: 30px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(79,140,255,.12);
  border: 1px solid rgba(79,140,255,.2);
  color: var(--blue);
  font: 700 .8rem var(--head);
}
.todo h3 { margin-bottom: 3px; }
.link-row { margin-top: 14px; }

/* Lists of checks, websites and history */
.group { margin-top: 22px; }
.group > h3 {
  font-family: var(--font);
  font-size: .65rem;
  font-weight: 700;
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: .1em;
  margin-bottom: 8px;
}
.rows { margin-top: 10px; display: flex; flex-direction: column; gap: 8px; }
.row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 20px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: border-color .2s, box-shadow .2s;
}
.row:hover { border-color: var(--border-strong); box-shadow: 0 6px 28px rgba(79,140,255,.07); }
.row-main { min-width: 0; flex: 1; }
.row-main h3 { overflow-wrap: anywhere; margin-bottom: 2px; }
.row-main .muted.small { font-size: .74rem; line-height: 1.45; }
.row-side { display: flex; gap: 8px; flex-shrink: 0; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.result-text { margin-top: 8px; font-size: .78rem; font-weight: 500; }
.result-text .muted.small { font-family: var(--mono); font-size: .66rem; color: var(--dim); }
.result-good { color: var(--teal); }
.result-warn { color: var(--amber); }
.result-bad { color: var(--rose); }
.running { color: var(--blue); font-family: var(--mono); font-size: .74rem; }
.inline-more { margin-top: 8px; font-size: .76rem; color: var(--muted); }
.inline-more summary { cursor: pointer; font-weight: 600; color: var(--blue); }
.inline-more ul { margin: 8px 0 0; padding-left: 18px; }
.inline-more li { margin-top: 4px; overflow-wrap: anywhere; }

/* Issue accordion */
.fix { background: var(--card); border: 1px solid var(--border); border-radius: 12px; margin-top: 8px; transition: border-color .2s; }
.fix[open] { border-color: var(--border-strong); }
.fix > summary {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  cursor: pointer;
  list-style: none;
}
.fix > summary::-webkit-details-marker { display: none; }
.fix > summary::after { content: "\25BE"; color: var(--dim); }
.fix[open] > summary::after { content: "\25B4"; }
.fix-title { flex: 1; font-size: .86rem; font-weight: 600; }
.fix-count { color: var(--muted); font-family: var(--mono); font-size: .7rem; white-space: nowrap; }
.tag { padding: 2px 8px; border-radius: 5px; font-size: .66rem; font-weight: 700; letter-spacing: .03em; white-space: nowrap; }
.tag-critical { background: rgba(248,113,113,.1); color: var(--rose); }
.tag-high { background: rgba(251,191,36,.1); color: var(--amber); }
.tag-medium { background: rgba(79,140,255,.1); color: var(--blue); }
.tag-low { background: rgba(62,82,128,.15); color: var(--muted); }
.fix-body { padding: 4px 18px 18px; border-top: 1px solid rgba(79,140,255,.08); font-size: .84rem; color: var(--muted); }
.fix-body h4 { margin: 14px 0 4px; font: 700 .72rem var(--font); color: var(--text); text-transform: uppercase; letter-spacing: .07em; }
.page-list { list-style: none; margin: 8px 0 0; padding: 0; }
.page-list li { padding: 9px 0; border-top: 1px solid rgba(79,140,255,.08); font-size: .8rem; overflow-wrap: anywhere; }
.page-list a { font-family: var(--mono); font-size: .74rem; }
.paste {
  margin-top: 6px;
  padding: 10px 12px;
  background: rgba(79,140,255,.05);
  border: 1px solid rgba(79,140,255,.12);
  border-radius: 8px;
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--text);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  max-height: 220px;
  overflow: auto;
}
.good-list { list-style: none; margin: 12px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 8px; }
.good-list li {
  display: flex; gap: 9px; align-items: center;
  padding: 10px 14px;
  border-radius: 10px;
  background: rgba(52,211,153,.05);
  border: 1px solid rgba(52,211,153,.15);
  font-size: .8rem;
}
.good-list li::before { content: '\2713'; color: var(--teal); font-weight: 700; }

/* Forms */
.panel { background: var(--card); border: 1px solid var(--border); border-radius: 14px; padding: 26px; }
.field { margin-top: 16px; }
.field label {
  display: block;
  margin-bottom: 6px;
  font-size: .7rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .07em;
}
.field .hint { font-size: .7rem; color: var(--dim); margin-top: 5px; }
input[type=text], input[type=email], input[type=password], select, textarea {
  width: 100%;
  padding: 10px 13px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(99,120,180,.22);
  border-radius: 10px;
  color: var(--text);
  font: .88rem var(--font);
  outline: none;
  transition: border-color .2s, background .2s, box-shadow .2s;
}
input::placeholder, textarea::placeholder { color: var(--dim); }
input:focus, select:focus, textarea:focus { border-color: var(--blue); background: rgba(79,140,255,.06); box-shadow: 0 0 0 3px rgba(79,140,255,.12); }
select option { background: #111827; }
textarea { font-family: var(--mono); font-size: .8rem; resize: vertical; }
.form-error {
  margin-top: 12px;
  padding: 11px 14px;
  border-radius: 10px;
  background: rgba(255,107,107,.08);
  border: 1px solid rgba(255,107,107,.2);
  color: #FF6B6B;
  font-size: .82rem;
}
.form-actions { display: flex; gap: 10px; margin-top: 22px; flex-wrap: wrap; }

/* Single-question screens */
.ask { max-width: 640px; margin: 8vh auto 0; }
.ask h1 { font-size: clamp(2rem, 5vw, 2.6rem); font-weight: 700; letter-spacing: -.03em; line-height: 1.12; }
.ask > p { margin-top: 12px; font-size: .95rem; color: var(--muted); line-height: 1.7; }
.ask-form { display: flex; gap: 10px; margin-top: 24px; }
.ask-form input { font-size: 1rem; padding: 13px 16px; flex: 1; min-width: 0; }
.ask-form .btn { white-space: nowrap; }

/* Scan progress */
.steps { list-style: none; margin: 28px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.steps li {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px;
  border-radius: 10px;
  border: 1px solid rgba(99,120,180,.12);
  background: rgba(14,22,42,.5);
  color: var(--dim);
  font-size: .85rem;
}
.steps li::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--dim); flex-shrink: 0; }
.steps li.active { color: var(--text); border-color: rgba(79,140,255,.25); }
.steps li.active::before { background: var(--blue); box-shadow: 0 0 8px var(--blue); animation: pulse 1s ease-in-out infinite; }
.steps li.done { color: var(--teal); }
.steps li.done::before { background: var(--teal); box-shadow: 0 0 6px var(--teal); }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .steps li.active::before { animation: none; } }

.empty {
  padding: 28px;
  text-align: center;
  border-radius: 12px;
  background: rgba(79,140,255,.04);
  border: 1px dashed rgba(79,140,255,.18);
  color: var(--muted);
}
.empty h2 { color: var(--text); }
.empty .btn { margin-top: 16px; }

@media (max-width: 640px) {
  .wrap { padding: 22px 16px 64px; }
  .verdict { padding: 24px 20px; }
  .row { flex-direction: column; }
  .row-side { justify-content: flex-start; }
  .ask-form { flex-direction: column; }
  .fix > summary { flex-wrap: wrap; }
}

/* Settings: tabs, notices, tables, links to copy */
.page-title { font-size: 1.7rem; font-weight: 700; letter-spacing: -.03em; }
.tabs { display: flex; gap: 2px; margin: 18px 0 26px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.tabs a {
  padding: 9px 14px;
  margin-bottom: -1px;
  border-bottom: 2px solid transparent;
  color: var(--muted);
  font-size: .8rem;
  font-weight: 600;
  text-decoration: none;
}
.tabs a:hover { color: var(--text); }
.tabs a[aria-current="page"] { color: var(--blue); border-bottom-color: var(--blue); }
.notice {
  margin-bottom: 18px;
  padding: 11px 14px;
  border-radius: 10px;
  background: rgba(79,140,255,.08);
  border: 1px solid rgba(79,140,255,.22);
  color: var(--ice);
  font-size: .82rem;
}
.notice-warn { background: rgba(251,191,36,.08); border-color: rgba(251,191,36,.25); color: var(--amber); }
.notice-good { background: rgba(52,211,153,.07); border-color: rgba(52,211,153,.22); color: var(--teal); }
.table { width: 100%; border-collapse: collapse; font-size: .8rem; }
.table th {
  text-align: left;
  padding: 10px 14px;
  font-size: .65rem;
  font-weight: 700;
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: .08em;
  border-bottom: 1px solid var(--border);
}
.table td { padding: 11px 14px; border-bottom: 1px solid rgba(79,140,255,.07); vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table .mono { font-family: var(--mono); font-size: .7rem; color: var(--muted); }
.table-card { background: var(--card); border: 1px solid var(--border); border-radius: 12px; overflow-x: auto; }
.role {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 5px;
  font-size: .66rem;
  font-weight: 700;
  letter-spacing: .03em;
  background: rgba(79,140,255,.1);
  color: var(--blue);
}
.role-owner { background: rgba(167,139,250,.12); color: #A78BFA; }
.role-member { background: rgba(62,82,128,.18); color: var(--muted); }
.inline-form { display: inline-flex; gap: 6px; align-items: center; margin: 0; }
.inline-form select { width: auto; padding: 6px 10px; font-size: .75rem; }
.copy-box { display: flex; gap: 8px; margin-top: 10px; }
.copy-box input { font-family: var(--mono); font-size: .74rem; }
.settings-grid { display: grid; gap: 16px; }
/* Monitoring settings */
input[type=number] { width: 100%; padding: 10px 13px; background: rgba(255,255,255,.04); border: 1px solid rgba(99,120,180,.22);
  border-radius: 10px; color: var(--text); font: .88rem var(--font); outline: none; }
input[type=number]:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(79,140,255,.12); }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 6px 14px; margin-top: 4px; }
.field label.check, label.check { display: flex; align-items: center; gap: 8px; font-size: .8rem; color: var(--text);
  cursor: pointer; text-transform: none; letter-spacing: 0; font-weight: 500; margin: 0; }
.check input { accent-color: var(--blue); width: 15px; height: 15px; }
.inline-fields { display: flex; gap: 10px; flex-wrap: wrap; }
.inline-fields .field { flex: 1; min-width: 140px; margin-top: 12px; }
.alert-row { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--border); }
.alert-row:first-child { border-top: none; }
.alert-dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; flex-shrink: 0; background: var(--blue); }
.alert-critical .alert-dot { background: var(--rose); }
.alert-warning .alert-dot { background: var(--amber); }
.alert-body { white-space: pre-line; word-break: break-word; }
.panel h2 { font-size: 1rem; margin-bottom: 4px; }
.panel > p.muted { font-size: .82rem; }
.danger { border-color: rgba(248,113,113,.25); }
.danger h2 { color: var(--rose); }
.qr-box { display: inline-block; padding: 10px; background: #fff; border-radius: 12px; line-height: 0; }
.qr-box svg { width: 190px; height: 190px; }
.secret { font-family: var(--mono); font-size: .8rem; letter-spacing: .08em; color: var(--ice); overflow-wrap: anywhere; }
.codes { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 8px; margin: 16px 0; }
.codes code { padding: 10px 12px; border-radius: 8px; background: rgba(79,140,255,.06); border: 1px solid var(--border); font-family: var(--mono); font-size: .85rem; color: var(--text); text-align: center; }
.inline-check { display: flex; gap: 8px; align-items: center; font-size: .82rem; color: var(--muted); text-transform: none; letter-spacing: 0; font-weight: 500; }
.inline-check input { width: auto; }
