:root {
  --bg: #f7f6f2;
  --surface: #ffffff;
  --text: #1c1d21;
  --muted: #5d6068;
  --line: #e1dfd8;
  --accent: #1f5f8b;
  --accent-text: #ffffff;
  --pass: #1d7a46;
  --pass-bg: #e6f4ec;
  --warn: #8a5a00;
  --warn-bg: #fdf1d8;
  --fail: #b3261e;
  --fail-bg: #fbe4e2;
  --radius: 12px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, "Liberation Mono", monospace;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #15171b;
    --surface: #1e2126;
    --text: #ecebe7;
    --muted: #a3a6ad;
    --line: #33373e;
    --accent: #6fb3e0;
    --accent-text: #0d1620;
    --pass: #6fd49b;
    --pass-bg: #173022;
    --warn: #f0c060;
    --warn-bg: #352a12;
    --fail: #f2928a;
    --fail-bg: #3a1c1a;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.55 var(--font);
}
.wrap { max-width: 720px; margin: 0 auto; padding: 0 16px; }
a { color: var(--accent); }
h1, h2, h3 { line-height: 1.2; }
h1 { font-size: clamp(1.75rem, 6vw, 2.5rem); margin: .25rem 0 .75rem; letter-spacing: -0.01em; }
h2 { font-size: 1.4rem; margin: 0 0 .75rem; }
h3 { font-size: 1.05rem; margin: 1.5rem 0 .5rem; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 8px; background: var(--surface); padding: 8px; z-index: 2; }

.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.site-header .wrap { padding-top: 12px; padding-bottom: 12px; }
.brand { font-weight: 700; letter-spacing: .01em; }

.hero { padding: 32px 0 8px; }
.eyebrow { text-transform: uppercase; font-size: .8rem; letter-spacing: .08em; color: var(--accent); font-weight: 600; margin: 0; }
.lead { font-size: 1.08rem; color: var(--muted); margin: 0 0 1.25rem; }

input[type="text"], textarea {
  width: 100%;
  font: inherit;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
}
textarea { font-family: var(--mono); font-size: .88rem; resize: vertical; }
input:focus, textarea:focus, button:focus-visible, summary:focus-visible, a:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 45%, transparent);
  outline-offset: 2px;
}
label { display: block; font-weight: 600; font-size: .92rem; margin: 14px 0 6px; }

button, .btn {
  display: inline-block;
  font: inherit;
  font-weight: 600;
  border: 0;
  border-radius: 10px;
  padding: 12px 20px;
  background: var(--accent);
  color: var(--accent-text);
  cursor: pointer;
  text-decoration: none;
  margin-top: 14px;
}
button.secondary { background: transparent; color: var(--accent); border: 1px solid var(--accent); }
button[disabled] { opacity: .6; cursor: progress; }

.check-form { display: flex; flex-direction: column; gap: 10px; }
.check-form button { margin-top: 0; }
@media (min-width: 560px) {
  .check-form { flex-direction: row; }
  .check-form input { flex: 1; }
}
.status { min-height: 1.5em; margin: 10px 0; }
.status.error { color: var(--fail); }

.paste, .more {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 16px;
  margin: 16px 0;
}
.paste summary, .more summary { cursor: pointer; font-weight: 600; }
.hint { color: var(--muted); font-size: .92rem; }

section { margin: 28px 0; }
.report, .maker, .limits, .cta {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 16px;
}
@media (min-width: 560px) { .report, .maker, .limits, .cta { padding: 24px; } }

.tally { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 4px; }
.chip { border-radius: 999px; padding: 4px 12px; font-weight: 600; font-size: .92rem; }
.chip.pass { background: var(--pass-bg); color: var(--pass); }
.chip.warn { background: var(--warn-bg); color: var(--warn); }
.chip.fail { background: var(--fail-bg); color: var(--fail); }

.checks { list-style: none; padding: 0; margin: 0; }
.checks li {
  border-left: 4px solid var(--line);
  padding: 8px 12px;
  margin: 8px 0;
  background: var(--bg);
  border-radius: 0 8px 8px 0;
}
.checks li.pass { border-color: var(--pass); }
.checks li.warn { border-color: var(--warn); }
.checks li.fail { border-color: var(--fail); }
.checks .label { font-weight: 600; display: block; }
.checks .tag { font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; margin-right: 6px; }
.checks li.pass .tag { color: var(--pass); }
.checks li.warn .tag { color: var(--warn); }
.checks li.fail .tag { color: var(--fail); }
.checks .extra { font-size: .85rem; color: var(--muted); margin: 4px 0 0; word-break: break-word; }
.fixes li { margin: 8px 0; }
.empty { color: var(--muted); font-style: italic; }

.table-scroll { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: .88rem; margin-top: 10px; }
th, td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
td.ok { color: var(--pass); font-weight: 600; }
td.no { color: var(--fail); font-weight: 600; }
#fetched { word-break: break-all; }

fieldset { border: 1px solid var(--line); border-radius: 10px; margin: 18px 0 0; padding: 4px 14px 14px; }
legend { font-weight: 700; padding: 0 6px; }
.link-choices { list-style: none; padding: 0; margin: 8px 0; max-height: 320px; overflow-y: auto; }
.link-choices li { display: flex; gap: 8px; align-items: flex-start; padding: 6px 0; border-bottom: 1px solid var(--line); }
.link-choices label { font-weight: 400; margin: 0; word-break: break-all; }
.link-choices input { margin-top: 5px; }
.add-link { display: grid; gap: 8px; margin-top: 8px; }
.add-link button { margin-top: 0; }
@media (min-width: 560px) { .add-link { grid-template-columns: 1fr 1.4fr auto; } }

.llms-out { margin-top: 18px; }
.row { display: flex; flex-wrap: wrap; gap: 10px; }
.ok-text { color: var(--pass); }
.warn-text { color: var(--warn); }

.limits ul { padding-left: 1.2rem; }
.cta { border-color: var(--accent); }

.site-footer { border-top: 1px solid var(--line); padding: 20px 0 32px; font-size: .92rem; }
.site-footer p { margin: 4px 0; }
