/* === CrawlReady shared components (single source) === */
/* ==========================================================================
   {{BRAND_NAME}} shared component stylesheet — single source of truth for:
   design tokens, base type, header/nav/footer + hamburger, buttons,
   content primitives, auth screens, report modules, GBP/NAP tools,
   competitor compare, admin panels.
   build.py stamps this in front of each property's own stylesheet at
   build time: dist/*.css = components/shared.css + <site>/<site>.css
   Brand: teal var(--teal) (primary), orange var(--orange) (secondary). NO BLUE.
   ========================================================================== */

:root {
  color-scheme: light;
  --teal: #1e5f7b;
  --teal-dark: #164a61;
  --teal-ink: #0f3c50;
  --orange: #ff7e00;
  --orange-dark: #e56f00;
  --ink: #1a2b33;
  --muted: #5a6f78;
  --bg: #ffffff;
  --bg-soft: #f4f7f8;
  --bg-sage: #eef3f1;
  --border: #dde5e8;
  --red: #c0392b;
  --red-bg: #fde8e8;
  --amber: #b7791f;
  --amber-bg: #fef3e2;
  --green: #1e7e34;
  --green-bg: #e6f4ea;
  --surface: #fff;
  --surface-2: #fbfdff;
  --ink-2: #3a4a52;
  --ink-3: #24333b;
  --doc-ink: #17211f;
  --muted-2: #71828c;
  --line: #dde6ea;
  --line-2: #e3ebee;
  --ok: #1a7a3a;
  --ok-dark: #14522a;
  --ok-bg: #e8f5e9;
  --err-bg: #fdecea;
  --err-line: #f5c6cb;
  --warn-bg: #fff8e1;
  --warn-line: #ffe082;
  --teal-bg: #eaf3f6;
  --teal-2: #1E6F67;
  --soft-2: #eef2f3;
  --soft-3: #e8eef0;
  --radius: 12px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink); background: var(--bg); line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
/* Sticky footer (all properties): every page is header / main / footer, so a
   flex column on body with main flex:1 keeps the footer at the viewport
   bottom on short pages. Replaces the app-only rule formerly in app/app.css. */
body { min-height: 100vh; display: flex; flex-direction: column; }
body > main { flex: 1 0 auto; }
body > header, body > footer { flex-shrink: 0; }
a { text-decoration: none; color: inherit; }
img, svg { display: block; }

/* ---------- Header / nav / hamburger ---------- */
.site-header { background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 100; }
.header-inner { max-width: 1120px; margin: 0 auto; padding: 14px 24px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; align-items: center; gap: 10px; }
.home-icon-link { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; color: var(--muted); }
.home-icon-link svg { width: 22px; height: 22px; }
.home-icon-link:hover { color: var(--teal); background: var(--bg-soft); }
/* Help-site articles toggle: lives in the header on mobile (≤820px),
   where the home icon used to be. Desktop hides it (rail always visible). */
.hamburger.header-menu-btn { align-items: center; justify-content: center; width: 40px; height: 40px; padding: 8px; border-radius: 10px; }
.hamburger.header-menu-btn:hover { background: var(--bg-soft); }
.hamburger.header-menu-btn span { width: 22px; }
.brand-mark { width: 30px; height: 30px; color: var(--teal); }
.brand-mark-img { height: 36px; width: auto; display: block; }
.brand-word { font-size: 20px; font-weight: 800; letter-spacing: -0.5px; color: var(--teal); }
.brand-word em { font-style: normal; color: var(--orange); }
/* Two-tone page titles: same effect as the {{BRAND_NAME}} wordmark —
   first word teal, the rest orange, extrabold. Applied via JS. */
.brand-head { font-weight: 800; letter-spacing: -0.5px; }
.brand-head .w1 { color: var(--teal); }
.brand-head .w2 { color: var(--orange); }
.site-nav { display: flex; gap: 26px; align-items: center; }
.site-nav a { font-size: 14.5px; color: var(--muted); font-weight: 500; }
.site-nav a:hover { color: var(--teal); }
.nav-toggle { display: none; }
.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; padding: 10px; }
.hamburger span { width: 24px; height: 2.5px; background: var(--teal); border-radius: 2px; transition: transform .2s, opacity .2s; }

/* ---------- Language switcher (marketing header) ---------- */
.lang-switcher { position: relative; }
.lang-code { font-size: 13px; font-weight: 800; letter-spacing: .4px; }
.lang-menu {
  position: absolute; top: calc(100% + 8px); right: 0; z-index: 200;
  background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
  box-shadow: 0 16px 40px rgba(15,44,58,.14); padding: 6px; margin: 0;
  list-style: none; min-width: 168px;
}
.lang-menu button {
  display: flex; align-items: center; width: 100%; text-align: left;
  background: none; border: none; cursor: pointer; font: inherit;
  font-size: 14.5px; color: var(--ink); padding: 10px 14px; border-radius: 9px;
}
.lang-menu button:hover { background: var(--bg-soft); }
.lang-menu button.active { color: var(--teal); font-weight: 700; }
.lang-menu button.active::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--teal); margin-left: auto; flex: none; }
.lang-switcher.in-nav { display: none; }
@media (max-width: 820px) {
  .lang-switcher.in-header-bar { display: none; }
  .lang-switcher.in-nav { display: block; margin-top: 6px; }
  .lang-switcher.in-nav .lang-menu { position: static; box-shadow: none; border: 1px solid var(--border); margin-top: 8px; }
}

/* slim app header (logo + token pill + auth nav) */
.app-header { background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 100; }
.app-header-inner { max-width: 1120px; margin: 0 auto; padding: 12px 24px; display: flex; align-items: center; justify-content: space-between; }
.app-head-right { display: flex; align-items: center; gap: 14px; }
.token-pill { display: inline-flex; align-items: center; gap: 8px; background: var(--bg-soft); border: 1px solid var(--border); border-radius: 999px; padding: 8px 18px; font-size: 14.5px; font-weight: 700; color: var(--teal); white-space: nowrap; }
.token-pill svg { width: 15px; height: 15px; color: var(--orange); }
.token-pill a { color: var(--orange-dark); font-weight: 700; }
a.mon-pill { text-decoration: none; }
a.mon-pill:hover { border-color: var(--teal); }
.admin-tag { display: inline-block; font-size: 12px; font-weight: 800; text-transform: capitalize; background: var(--teal-ink); color: #fff; padding: 6px 14px; border-radius: 999px; }

/* auth pages: logo only */
body.auth-page .token-pill, body.auth-page .admin-tag,
body.auth-page .site-nav, body.auth-page .hamburger { display: none !important; }
body.admin-mode .nav-app, body.admin-mode .token-pill { display: none !important; }

/* ---------- Footer ---------- */
.site-footer { background: var(--teal-ink); color: #cfe0e7; }
.footer-inner { max-width: 1120px; margin: 0 auto; padding: 44px 24px 28px; display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.footer-brand .brand-word { color: #fff; }
.footer-brand .brand-mark { color: var(--orange); }
.footer-brand p { margin-top: 10px; font-size: 14.5px; color: #9fb8c2; }
.footer-nav { display: flex; gap: 22px; flex-wrap: wrap; align-items: flex-start; }
.footer-nav a { font-size: 14.5px; color: #cfe0e7; }
.footer-nav a:hover { color: #fff; }
.footer-fine { border-top: 1px solid rgba(255,255,255,.14); text-align: center; padding: 16px 24px; font-size: 13px; color: #9fb8c2; }

/* ---------- Buttons: ONE spec per role (Kuang 2026-10-16, "create one,
   use it everywhere") ----------
   Every button in the portal is one of three roles; each role is defined
   here once and nowhere else. Older class names are mapped onto a role in
   the selector lists below instead of carrying their own rules.
   PRIMARY   .btn-orange (+ .btn-teal, mapped): the orange pill — New scan,
             Save, Buy, Add site, Start monitoring.
   SECONDARY .btn-outline (+ .mons-view, #comp-add-btn, mapped): teal ring.
   QUIET     .btn-link (+ .add-row-btn, .add-item-btn, .paste-toggle,
             .comp-edit, .rm-section, .file-btn, mapped): teal text.
   Primary and secondary share one box: 40px tall (the same height as a
   text input), 13px/600 label, icon + label on one line, never wraps. */
.btn, .mons-view {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  box-sizing: border-box; height: 40px; padding: 0 20px; margin: 0;
  border: 0; border-radius: 999px; box-shadow: none;
  font: inherit; font-size: 13px; font-weight: 600; line-height: 1;
  white-space: nowrap; text-decoration: none; cursor: pointer; flex: none;
}
.btn-orange, .btn-teal { background: var(--orange); color: #fff; }
.btn-orange:hover, .btn-teal:hover { background: var(--orange-dark); color: #fff; }
.btn-outline, .mons-view, .btn#comp-add-btn { background: transparent; color: var(--teal); box-shadow: inset 0 0 0 2px var(--teal); }
.btn-outline:hover, .mons-view:hover, .btn#comp-add-btn:hover { background: var(--teal); color: #fff; }
.btn:disabled, .mons-view:disabled { opacity: .55; cursor: not-allowed; }
.btn-link, .add-row-btn, .add-item-btn, .paste-toggle, .comp-edit, .rm-section, .file-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 0; margin: 0;
  background: none; border: 0; border-radius: 0; box-shadow: none;
  font: inherit; font-size: 13px; font-weight: 600; line-height: 20px;
  color: var(--teal); text-decoration: none; white-space: nowrap; cursor: pointer;
}
.btn-link:hover, .add-row-btn:hover, .add-item-btn:hover, .paste-toggle:hover, .comp-edit:hover, .rm-section:hover, .file-btn:hover { text-decoration: underline; text-underline-offset: 2px; }
.btn-link:disabled, .add-row-btn:disabled { opacity: .55; cursor: not-allowed; text-decoration: none; }

/* ---------- Content primitives ---------- */
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.section { padding: 72px 0; }
.kicker { font-size: 12.5px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; color: var(--orange); margin-bottom: 12px; }
h1 { font-size: clamp(34px, 5vw, 54px); font-weight: 800; letter-spacing: -1.5px; line-height: 1.12; }
h2 { font-size: clamp(26px, 3.4vw, 36px); font-weight: 800; letter-spacing: -0.8px; margin-bottom: 12px; }
.lede { font-size: 14.5px; color: var(--muted); max-width: 620px; }
.u-center .lede { margin-left: auto; margin-right: auto; }
.prose { max-width: 760px; margin: 0 auto; }
.prose h2 { margin-top: 40px; }
.prose p, .prose li { color: var(--muted); font-size: 14.5px; margin-bottom: 14px; }
.prose p.kicker { color: var(--orange); font-size: 12.5px; }
.prose ul { padding-left: 22px; }
.prose pre { background: #0f2b3a; color: #d9e8ef; border-radius: 12px; padding: 18px 20px; overflow-x: auto; font-size: 14.5px; line-height: 1.6; margin: 18px 0 22px; }
.prose pre code { background: none; border: none; padding: 0; color: inherit; font-size: inherit; }
.prose code { background: var(--bg-soft); border: 1px solid var(--border); border-radius: 6px; padding: 2px 7px; font-size: 14.5px; color: var(--teal-ink); }
.page-hero { padding: 64px 0 24px; }

/* ---------- Severity / impact badges ---------- */
.sev { display: inline-flex; align-items: center; height: 24px; font-size: 11.5px; font-weight: 700; text-transform: capitalize; padding: 0 12px; border-radius: 999px; margin-left: 10px; vertical-align: 2px; }
.sev-high { background: var(--red-bg); color: var(--red); }
.sev-med { background: var(--amber-bg); color: var(--amber); }
.sev-low { background: var(--green-bg); color: var(--green); }
.severity { flex-shrink: 0; font-size: 11px; font-weight: 800; text-transform: capitalize; letter-spacing: .5px; padding: 5px 12px; border-radius: 6px; margin-top: 2px; }

/* ---------- Auth screens ---------- */
.auth-wrap { flex: 1; display: flex; align-items: center; justify-content: center; padding: 48px 24px; background: var(--bg-soft); min-height: calc(100vh - 120px); }
.auth-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 44px 40px; width: 100%; max-width: 440px; box-shadow: 0 12px 40px rgba(30,95,123,.08); }
/* FAQ block under auth cards / wizard: plain Q&A for visitors and AI readers. */
.faq-block { max-width: 720px; margin: 0 auto; padding: 8px 24px 64px; }
.faq-block h2 { font-size: 20px; letter-spacing: -0.3px; margin: 0 0 4px; }
.faq-block h3 { font-size: 16px; margin: 22px 0 6px; color: var(--teal); }
.faq-block p { font-size: 14.5px; line-height: 1.65; color: var(--ink); margin: 0; }
.auth-card h1 { font-size: 30px; letter-spacing: -0.5px; margin-bottom: 8px; text-align: center; }
.auth-card .sub { text-align: center; color: var(--muted); font-size: 14.5px; margin-bottom: 28px; }
.auth-error { display: none; background: var(--red-bg); color: var(--red); border-radius: 10px; padding: 12px 16px; font-size: 14.5px; font-weight: 600; margin-bottom: 20px; }
/* Floating labels: only when the label follows its input (auth forms).
   Scoped with input + label so tool pages using .field with plain
   labels (e.g. robots.txt generator) are not affected. */
.show-pw { display: flex; align-items: center; gap: 8px; font-size: 14.5px; color: var(--muted); margin: 2px 0 18px; cursor: pointer; user-select: none; }
.show-pw input { width: 16px; height: 16px; accent-color: var(--teal); }
.divider { display: flex; align-items: center; gap: 12px; margin: 24px 0; color: var(--muted); font-size: 13px; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.btn-google svg { width: 20px; height: 20px; }
.switch { text-align: center; margin-top: 24px; font-size: 14.5px; color: var(--muted); }
.switch a { color: var(--teal); font-weight: 600; }

/* ---------- Report ---------- */
.report-wrap { max-width: 880px; margin: 0 auto; padding: 36px 24px 80px; }
.score-hero { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 40px; text-align: center; margin-bottom: 24px; }
.score-hero .url { font-size: 14.5px; color: var(--muted); }
.score-hero .date { font-size: 13px; color: var(--muted); margin-top: 2px; }
.score-ring { width: 150px; height: 150px; border-radius: 50%; margin: 20px auto; display: flex; align-items: center; justify-content: center; background: conic-gradient(var(--ringc, var(--orange)) 0% var(--pct, 0%), var(--soft-3) var(--pct, 0%) 100%); }
.score-ring .inner { width: 118px; height: 118px; border-radius: 50%; background: var(--surface); display: flex; align-items: center; justify-content: center; flex-direction: column; }
.score-ring .grade { font-size: 42px; font-weight: 800; line-height: 1; }
.score-ring .num { font-size: 20px; font-weight: 700; line-height: 1.2; color: var(--muted); }
.score-ring .lbl { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }
.verdict { font-size: 20px; font-weight: 700; margin-bottom: 6px; }
.verdict-sub { color: var(--muted); max-width: 560px; margin: 0 auto; font-size: 14.5px; }
.section-label { font-size: 20px; font-weight: 800; margin: 32px 0 6px; letter-spacing: -0.3px; }
.section-desc { color: var(--muted); font-size: 14.5px; margin-bottom: 16px; }
.cat-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(108px, 1fr)); gap: 12px; margin-bottom: 16px; }
.cat-chip { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 12px 8px; text-align: center; }
.cat-chip .s { font-size: 20px; font-weight: 800; }
.cat-chip .n { font-size: 11.5px; color: var(--muted); line-height: 1.3; margin-top: 2px; }
.viz-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 16px; }
.viz-card h3 { font-size: 17px; margin-bottom: 4px; }
.viz-card p, .viz-card li { color: var(--muted); font-size: 13px; }
.viz-card p strong, .viz-card li strong { font-weight: 400; color: var(--ink); }
.viz-card .viz-sub { font-size: 13px; color: var(--muted); margin-bottom: 22px; }
/* Industry landscape: 2-col card grid (was unstyled in the portal report — cards stacked with no gap) */
.landscape-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 16px; }
/* horizontal bar chart */
.hbar-row { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.hbar-row:last-child { margin-bottom: 0; }
.hbar-name { flex: 0 0 150px; font-size: 13px; font-weight: 400; color: var(--muted); text-align: right; }
.hbar-track { flex: 1; background: var(--soft-2); border-radius: 999px; height: 22px; overflow: hidden; }
.hbar-fill { width: var(--w, 0%); height: 100%; border-radius: 999px; }
.hbar-fill.teal { background: var(--teal); }
.hbar-fill.orange { background: var(--orange); }
.hbar-fill.red { background: var(--red); }
.hbar-fill.gray { background: #9aa5ad; }
.hbar-score { flex: 0 0 34px; font-size: 13px; font-weight: 400; color: var(--muted); text-align: right; }
/* vertical bar chart (local stacking) */
.vbar-chart { display: flex; align-items: flex-end; justify-content: center; gap: 18px; height: 220px; padding-top: 30px; }
.vbar-col { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; flex: 1; max-width: 110px; }
.vbar-score { font-size: 14.5px; font-weight: 800; margin-bottom: 6px; }
.vbar { width: 100%; border-radius: 8px 8px 0 0; }
.vbar.teal { background: var(--teal); }
.vbar.gray { background: #b9c8cd; }
.vbar.orange { background: var(--orange); }
.vbar-name { font-size: 11.5px; color: var(--muted); text-align: center; margin-top: 8px; line-height: 1.35; min-height: 32px; }
.vbar-name strong { color: var(--ink); }
/* ranked fix cards */
.rank-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 24px; margin-bottom: 16px; display: flex; gap: 20px; }
/* Collapsible fix guidance (2026-10-13, Kuang: shorten the report) */
.fix-collapsible { margin-top: 8px; }
.rank-num { flex: none; width: 40px; height: 40px; border-radius: 12px; background: var(--teal); color: #fff; font-weight: 800; font-size: 17px; display: flex; align-items: center; justify-content: center; }
.rank-card.impact-high .rank-num { background: var(--orange); }
.rank-body { flex: 1; min-width: 0; }
.rank-body h3 { font-size: 20px; margin-bottom: 4px; }
.rank-cat { font-size: 12.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .7px; font-weight: 700; margin-bottom: 8px; }
.rank-body .why { color: var(--muted); font-size: 14.5px; margin-bottom: 12px; }
.fix { background: var(--bg-soft); border-left: 3px solid var(--teal); border-radius: 0 8px 8px 0; padding: 14px 18px; font-size: 13px; color: var(--muted); }
.fix strong { display: block; font-size: 12.5px; text-transform: uppercase; letter-spacing: .7px; color: var(--teal); margin-bottom: 6px; }
.fix code, .snippet code { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 13px; }
.snippet { position: relative; background: var(--teal-ink); color: #d9e8ee; border-radius: 8px; padding: 14px 18px; margin-top: 10px; overflow-x: auto; white-space: pre; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 13px; }
.snippet-copy { position: absolute; top: 8px; right: 8px; border: 1px solid rgba(255,255,255,.25); background: rgba(255,255,255,.08); color: #d9e8ee; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; cursor: pointer; font-family: inherit; }
.snippet-copy:hover { background: var(--teal); border-color: var(--teal); color: #fff; }
/* uplift: shared report component (app + marketing sample report) */
.uplift-banner { border-left: 4px solid var(--teal); margin-bottom: 16px; }
.uplift-badge { display: inline-block; background: #e6f2f5; color: var(--teal); font-size: 12px; font-weight: 800;
  border-radius: 20px; padding: 3px 10px; margin-left: 10px; vertical-align: middle; white-space: nowrap; }
.tier-badge { display: inline-block; font-size: 12px; font-weight: 800; border-radius: 20px; padding: 3px 10px;
  margin-left: 10px; vertical-align: middle; white-space: nowrap; }
.tier-diy { background: var(--green-bg); color: var(--ok); }
.tier-wp { background: #fff4e0; color: #9a6200; }
.tier-split { background: #e8f0fe; color: #1a5fb4; }
.tier-summary { font-size: 14.5px; color: var(--muted); margin: 0 0 20px; }
.tier-summary strong { color: var(--ink); }
/* professional group: one compact header, no per-card tier labels */
.pro-group-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  background: #fff8ec; border: 1px solid #f0dfb8; border-radius: var(--radius);
  padding: 14px 18px; margin: 24px 0 16px; }
.pro-group-label { font-size: 14.5px; color: var(--ink); }
.pro-group-label strong { font-weight: 800; }
.report-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 32px; }
.callout-note { background: #eef5f8; border: 1px solid #cfe0e8; border-radius: var(--radius); padding: 14px 18px; font-size: 14.5px; color: var(--ink); margin-bottom: 18px; }
.callout-note strong { color: var(--teal); }

/* ---------- GBP checklist ---------- */
.meter-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 22px; margin-bottom: 16px; }
.meter-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.meter-label { font-size: 14.5px; font-weight: 700; color: var(--teal); }
.meter-count { font-size: 14.5px; font-weight: 700; color: var(--ink); }
.meter-bar { height: 10px; background: var(--soft-3); border-radius: 999px; overflow: hidden; }
.meter-fill { height: 100%; width: 0%; background: var(--teal); border-radius: 999px; transition: width .3s ease; }
.gbp-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 8px 24px 16px; margin-bottom: 16px; }
.gbp-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--border); }
.gbp-row:last-child { border-bottom: none; }
.gbp-q { font-size: 14.5px; font-weight: 600; }
.gbp-q small { display: block; font-weight: 400; color: var(--muted); font-size: 13px; margin-top: 2px; }
.yn-toggle { display: flex; border: 2px solid var(--border); border-radius: 999px; overflow: hidden; flex-shrink: 0; }
.gbp-fix { display: none; background: #fff8f2; border: 1px solid #f3d9b8; border-radius: 10px; padding: 14px 18px; margin: 4px 0 12px; font-size: 14.5px; }
.gbp-fix.show { display: block; }
.gbp-fix strong { color: var(--orange-dark); }
.gbp-fix ol, .gbp-fix ul { margin: 8px 0 0 20px; }
.gbp-fix li { margin-bottom: 6px; }

/* ---------- NAP consistency check ---------- */
.consist-grid { display: grid; grid-template-columns: 130px 1fr 1fr 1fr; gap: 0; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface); margin-bottom: 18px; }
.consist-grid .cg-head { background: var(--teal); color: #fff; font-size: 12.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; padding: 12px 14px; }
.consist-grid .cg-label { background: var(--bg-soft); font-size: 14.5px; font-weight: 700; padding: 12px 14px; border-top: 1px solid var(--border); display: flex; align-items: center; }
.consist-grid .cg-cell { padding: 8px 10px; border-top: 1px solid var(--border); border-left: 1px solid var(--border); }
.consist-result-row { display: flex; align-items: flex-start; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border); font-size: 14.5px; }
.consist-result-row:last-child { border-bottom: none; }
.cr-icon { width: 26px; height: 26px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 1px; }
.cr-icon svg { width: 14px; height: 14px; }
.cr-pass { background: var(--green-bg); } .cr-pass svg { stroke: var(--green); }
.cr-fail { background: var(--red-bg); } .cr-fail svg { stroke: var(--red); }
.cr-empty { background: var(--bg-soft); } .cr-empty svg { stroke: var(--muted); }
#consist-results { display: none; }
#consist-results.show { display: block; }
.consist-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 6px; }

/* ---------- Competitor compare ---------- */
.compare-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; margin-bottom: 16px; }
.compare-note { font-size: 13px; color: var(--muted); margin-bottom: 18px; }
.compare-note strong { color: var(--orange-dark); }
.comp-add { display: flex; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.comp-add input { flex: 1; min-width: 200px; }
.comp-list { list-style: none; margin-bottom: 18px; }
.comp-list li { display: grid; grid-template-columns: 1fr 150px 70px; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--bg-soft); font-size: 14.5px; }
.comp-list .comp-remove { justify-self: end; }
.comp-list li:last-child { border-bottom: none; }
.comp-list .comp-status { font-size: 13px; color: var(--muted); }
.comp-list .comp-status.scanning { color: var(--orange-dark); font-weight: 600; }
.comp-list .comp-status.done { color: var(--green); font-weight: 700; }
.comp-remove { background: none; border: none; color: var(--muted); cursor: pointer; font-size: 13px; text-decoration: underline; }

/* ---------- Scan history ---------- */
.history-list { display: flex; flex-direction: column; gap: 10px; }
.hist-row { display: flex; align-items: center; gap: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px; text-decoration: none; color: inherit; }
.hist-row:hover { border-color: var(--teal); }
.hist-doc { flex: none; width: 40px; height: 40px; border-radius: 10px; background: var(--bg-soft); display: flex; align-items: center; justify-content: center; color: var(--teal); }
.hist-doc svg { width: 20px; height: 20px; }
.hist-score { font-size: 30px; font-weight: 800; min-width: 64px; text-align: center; }
.hist-score.hist-queued, .hist-score.hist-running { font-size: 13px; font-weight: 600; color: var(--orange-dark); }
.hist-score.hist-error { font-size: 13px; font-weight: 600; color: var(--red); }
.hist-url { flex: 1; font-size: 16px; font-weight: 600; }
.hist-date { display: block; font-size: 13px; font-weight: 400; color: var(--muted); margin-top: 2px; }
.hist-arrow { color: var(--teal); font-size: 20px; }

/* ---------- Settings ---------- */
.settings-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 16px; }
.settings-card h2 { font-size: 20px; margin-bottom: 14px; }
.settings-row { display: flex; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--bg-soft); font-size: 14.5px; }
.settings-row:last-child { border-bottom: none; }
.settings-label { min-width: 140px; color: var(--muted); }
.field-label { display: block; font-size: 13px; font-weight: 600; margin: 14px 0 6px; }
.field-input { width: 100%; max-width: 380px; }
.pw-ok { color: var(--green); font-weight: 600; font-size: 14.5px; margin: 10px 0; }

/* ---------- Billing & invoices ---------- */
.inv-head { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.inv-sub { font-size: 13px; color: var(--muted); margin-top: 6px; }
.inv-meta { text-align: right; display: flex; flex-direction: column; gap: 8px; }
.inv-meta span { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.inv-table { width: 100%; border-collapse: collapse; font-size: 14.5px; margin-bottom: 20px; }
.inv-table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); padding: 10px 8px; border-bottom: 2px solid var(--border); }
.inv-table td { padding: 14px 8px; border-bottom: 1px solid var(--border); }
.inv-total { display: flex; justify-content: space-between; font-size: 20px; padding: 12px 8px; }
.invoice-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 36px; margin-top: 16px; }
@media print {
  .app-header, .report-actions, #invoice-back, .btn-link { display: none !important; }
  .invoice-card { border: none; padding: 0; }
}
.step-kicker { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--teal); margin-bottom: 6px; }
.comp-add-row { display: flex; gap: 10px; margin: 18px 0 6px; }
.comp-add-row input { flex: 1; }
.listings-block { margin: 26px 0 6px; padding-top: 20px; border-top: 1px solid var(--border); }
.listings-title { font-size: 14.5px; font-weight: 700; margin-bottom: 4px; }
.listings-title .opt { font-weight: 500; color: var(--muted); font-size: 13px; }
.listings-sub { font-size: 14.5px; color: var(--muted); margin-bottom: 12px; }
.listings-block input { display: block; width: 100%; margin-bottom: 10px; }
.comp-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--bg-soft); font-size: 14.5px; }
.comp-item .comp-remove { font-size: 20px; text-decoration: none; line-height: 1; padding: 4px 8px; }
.wizard-nav { display: flex; align-items: center; justify-content: space-between; margin-top: 22px; }
.skip-row { text-align: center; margin-top: 10px; }

/* ---------- Scan progress steps (Siftly-style) ---------- */
.pulse-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--green); margin-right: 6px; animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
.scan-steps { list-style: none; margin: 0 0 20px; padding: 0; }
.scan-steps li { display: flex; align-items: center; gap: 12px; padding: 9px 0; font-size: 14.5px; color: var(--muted); }
.scan-steps li .st-ic { width: 22px; height: 22px; flex: none; display: inline-flex; align-items: center; justify-content: center; }
.scan-steps li.done { color: var(--ink); }
.scan-steps li.done .st-ic { color: var(--green); }
.scan-steps li.active { color: var(--ink); font-weight: 600; }
.scan-steps li.active .st-ic { color: var(--orange-dark); }
.scan-steps li.active .st-ic .mini-spin { width: 16px; height: 16px; border: 2.5px solid var(--border); border-top-color: var(--orange-dark); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.scan-steps li.todo .st-ic { color: var(--border); }
.scan-progress { height: 8px; background: var(--bg-soft); border-radius: 999px; overflow: hidden; margin-bottom: 8px; }
.scan-progress-fill { height: 100%; width: 0%; background: linear-gradient(90deg, var(--teal), var(--orange)); border-radius: 999px; transition: width .6s ease; }
.scan-progress-label { font-size: 13px; color: var(--muted); }

/* ---------- Local query test ---------- */
.query-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 16px; }
.query-row { display: flex; gap: 14px; padding: 16px 24px; border-bottom: 1px solid var(--border); font-size: 14.5px; }
.query-row:last-child { border-bottom: none; }
.query-row .q { font-weight: 700; display: block; margin-bottom: 2px; }
.query-row .a { color: var(--muted); }
.query-ic { flex: none; width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin-top: 2px; }
.query-ic svg { width: 14px; height: 14px; }
.query-ic.bad { background: var(--red-bg); } .query-ic.bad svg { stroke: var(--red); }
.query-ic.good { background: var(--green-bg); } .query-ic.good svg { stroke: var(--green); }

/* ---------- Admin ---------- */
.admin-wrap { max-width: 1120px; margin: 0 auto; padding: 36px 24px 80px; }
.admin-wrap h1 { font-size: 30px; letter-spacing: -0.8px; margin-bottom: 6px; }
.admin-sub { color: var(--muted); margin-bottom: 4px; }
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 24px 0; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 20px; }
.stat .v { font-size: 30px; font-weight: 800; color: var(--teal); }
.stat .l { font-size: 13px; color: var(--muted); }
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 24px; margin-bottom: 20px; overflow-x: auto; }
.panel h2 { font-size: 20px; margin-bottom: 14px; }
.panel table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.panel th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); padding: 8px 10px; border-bottom: 2px solid var(--border); }
.panel td { padding: 10px; border-bottom: 1px solid var(--bg-soft); }
.panel tr:last-child td { border-bottom: none; }
.tag { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 2px 10px; border-radius: 999px; background: var(--bg-soft); color: var(--muted); }
.tag.ok { background: var(--green-bg); color: var(--green); }
.tag.err { background: var(--red-bg); color: var(--red); }
.tag.warn { background: var(--amber-bg); color: var(--amber); }
.delta-pos { color: var(--green); font-weight: 700; }
.delta-neg { color: var(--red); font-weight: 700; }
.inline-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 14px; }
.form-msg { font-size: 14.5px; font-weight: 600; color: var(--muted); }
.form-msg.form-ok { color: var(--green); }
.form-msg.form-err { color: var(--red); }
.admin-login-row { display: flex; align-items: center; gap: 12px; }

/* ---------- Service-unavailable / empty states ---------- */
.service-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 48px 40px; text-align: center; max-width: 560px; margin: 80px auto; }
.service-card h1 { font-size: 30px; margin-bottom: 10px; }
.service-card p { color: var(--muted); margin-bottom: 24px; }

/* ---------- Nav dropdown (Resources) ---------- */
.nav-drop { position: relative; }
.nav-drop-btn { font-size: 14.5px; color: var(--muted); font-weight: 500; cursor: default; white-space: nowrap; }
.nav-drop-btn:hover { color: var(--teal); }
.nav-drop-btn .caret { font-size: 11px; }
.nav-drop-menu { display: none; position: absolute; top: calc(100% + 10px); left: 50%; transform: translateX(-50%); background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 8px; min-width: 260px; box-shadow: 0 16px 40px rgba(30,95,123,.12); z-index: 60; }
.nav-drop:hover .nav-drop-menu, .nav-drop:focus-within .nav-drop-menu { display: block; }
.nav-drop-menu a { display: block; padding: 10px 14px; border-radius: 9px; font-size: 14.5px; }
.nav-drop-menu a:hover { background: var(--bg-soft); }
.nav-drop-menu a strong { display: block; font-size: 14.5px; }
.nav-drop-menu a small { display: block; font-size: 13px; color: var(--muted); font-weight: 400; }

/* ---------- Mobile ---------- */
@media (max-width: 820px) {
  .hamburger { display: flex; }
  .header-inner, .app-header-inner { position: relative; }
  .app-header-inner { padding: 12px 16px; max-width: 100%; box-sizing: border-box; }
  .app-head-right { gap: 10px; }
  .site-nav { display: none; position: fixed; top: 0; left: 0; width: 100vw; height: 100dvh; z-index: 90; background: var(--surface); flex-direction: column; align-items: stretch; padding: calc(84px + env(safe-area-inset-top)) 24px calc(24px + env(safe-area-inset-bottom)); gap: 0; overflow-y: auto; box-sizing: border-box; }
  .site-nav a { padding: 14px 0; border-bottom: 1px solid var(--bg-soft); font-size: 20px; }
  .site-nav a:last-child { border-bottom: none; }
  .nav-toggle:checked ~ .site-nav { display: flex; }
  .nav-toggle:checked ~ .hamburger span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  .nav-toggle:checked ~ .hamburger span:nth-child(2) { opacity: 0; }
  .nav-toggle:checked ~ .hamburger span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
  /* Keep the hamburger (now an X) tappable above the full-screen nav overlay. */
  .nav-toggle:checked ~ .hamburger { position: relative; z-index: 95; }
  /* Lock body scroll while the full-screen mobile menu is open. */
  body:has(.nav-toggle:checked) { overflow: hidden; }
  .nav-drop { width: 100%; }
  .nav-drop-btn { display: block; padding: 13px 0; border-bottom: 1px solid var(--bg-soft); font-size: 16px; }
  .nav-drop-menu { position: static; transform: none; display: block; box-shadow: none; border: none; border-radius: 0; padding: 0 0 0 14px; min-width: 0; }
  .nav-drop-menu a { border-bottom: 1px solid var(--bg-soft); border-radius: 0; }
  .section { padding: 52px 0; }
  .token-pill { padding: 6px 12px; font-size: 13px; }
  /* dropdown becomes an inline section on mobile */
  .nav-drop-btn { display: block; padding: 13px 0; border-bottom: 1px solid var(--bg-soft); font-size: 16px; color: var(--ink); font-weight: 700; cursor: default; }
  .nav-drop-btn .caret { display: none; }
  .nav-drop-menu { display: block; position: static; transform: none; border: none; box-shadow: none; padding: 0 0 0 14px; min-width: 0; }
  .nav-drop-menu a { border-bottom: 1px solid var(--bg-soft); border-radius: 0; }
  .cat-strip { grid-template-columns: repeat(3, 1fr); }
  .landscape-grid { grid-template-columns: 1fr; }
  .rank-card { padding: 20px; gap: 14px; }
  .hbar-name { flex: 0 0 108px; font-size: 12px; }
  .vbar-chart { gap: 10px; height: 190px; }
  .vbar-name { font-size: 11px; }
  .gbp-row { flex-direction: column; align-items: flex-start; gap: 10px; }
  .consist-grid { grid-template-columns: 1fr; }
  .consist-grid .cg-head { display: none; }
  .consist-grid .cg-label { border-left: none; }
  .consist-grid .cg-cell { border-left: none; }
  .consist-grid .cg-cell::before { content: attr(data-src); display: block; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); margin-bottom: 4px; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .auth-card { padding: 36px 28px; }
}

/* ---------- Person account menu (app header) ---------- */
.profile-menu { position: relative; }
.profile-toggle { display: none; }
.profile-btn { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid var(--border); background: var(--surface); color: var(--teal); cursor: pointer; transition: border-color .15s, background .15s; }
.profile-btn svg { width: 21px; height: 21px; }
.profile-btn:hover { border-color: var(--teal); background: var(--bg-soft); }
.profile-toggle:checked + .profile-btn { border-color: var(--teal); background: var(--bg-soft); }
.profile-drop { display: none; position: absolute; right: 0; top: calc(100% + 10px); background: var(--surface); border: 1px solid var(--border); border-radius: 14px; min-width: 230px; box-shadow: 0 16px 40px rgba(30,95,123,.14); padding: 8px; z-index: 200; }
.profile-toggle:checked ~ .profile-drop { display: block; }
.profile-drop-email { font-size: 13px; font-weight: 600; color: var(--muted); padding: 8px 14px 10px; border-bottom: 1px solid var(--bg-soft); margin-bottom: 6px; word-break: break-all; }
.profile-drop a { display: block; padding: 10px 14px; border-radius: 9px; font-size: 14.5px; font-weight: 500; color: var(--ink); }
.profile-drop a:hover { background: var(--bg-soft); color: var(--teal); }
.profile-drop-div { border-top: 1px solid var(--bg-soft); margin: 6px 0; }
body.admin-mode .profile-menu { display: none !important; }
.admin-only { display: none !important; }
body.admin-mode .admin-only { display: block !important; }
@media (min-width: 821px) {
  .acct-link { display: none !important; }
}

/* ---------- Account area: left sidebar layout ---------- */
.acct-layout { display: flex; gap: 44px; width: 100%; max-width: 1120px; margin: 0 auto; padding: 40px 24px 88px; align-items: flex-start; box-sizing: border-box; }
.side-nav { flex: none; width: 240px; position: sticky; top: 92px; }
.side-nav-title { font-size: 12.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 1.2px; color: var(--muted); margin-bottom: 10px; padding: 0 12px; }
.side-nav a { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 10px; font-size: 14.5px; font-weight: 500; color: var(--muted); }
.side-nav a svg { width: 18px; height: 18px; flex: none; }
.side-nav a:hover { background: var(--bg-soft); color: var(--ink); }
.side-nav a.active { background: var(--bg-soft); color: var(--teal); font-weight: 700; }
.acct-content { flex: 1; min-width: 0; }
.acct-content > h1 { font-size: 30px; letter-spacing: -0.6px; margin-bottom: 20px; }
@media (max-width: 820px) {
  .acct-layout { flex-direction: column; gap: 20px; padding-top: 28px; align-items: stretch; width: 100%; min-width: 0; }
  .side-nav { width: 100%; min-width: 0; position: static; display: flex; gap: 4px; overflow-x: auto; padding-bottom: 4px; }
  .side-nav-title { display: none; }
  .side-nav a { white-space: nowrap; font-size: 14.5px; padding: 10px 10px; flex: none; }
  .side-nav a svg { display: none; }
  /* Expanded submenus join the horizontal strip instead of widening the page:
     before this, an auto-expanded submenu pushed the layout to ~800px on a
     390px phone (flex items would not shrink below content width). */
  .side-head { white-space: nowrap; font-size: 14.5px; padding: 10px 10px; flex: none; width: auto; }
  .side-head > svg:first-child { display: none; }
  .side-submenu { margin: 0; padding-left: 0; border-left: none; display: flex; gap: 4px; align-items: center; }
  .side-submenu.collapsed { display: none; }
}

/* ---------- Article rails (blog + help): left sidebar nav ---------- */
.page-with-rail { display: flex; gap: 48px; max-width: 1280px; margin: 0 auto; padding: 48px 24px 88px; align-items: flex-start; }
.rail-toggle { display: none; }
.rail-toggle-btn { display: none; }
.rail { flex: none; width: 264px; position: sticky; top: 92px; max-height: calc(100vh - 120px); overflow-y: auto; }
.rail-link { display: block; padding: 9px 12px; border-radius: 9px; font-size: 14.5px; font-weight: 500; color: var(--muted); line-height: 1.45; }
.rail-link:hover { background: var(--bg-soft); color: var(--ink); }
.rail-link.current { background: var(--bg-soft); color: var(--teal); font-weight: 700; }
.rail-group { margin-bottom: 6px; }
.rail-group:last-child { margin-bottom: 0; }
/* Collapsible categories (checkbox-hack, zero JS — same pattern as the header). */
/* Text column: category headers and article links share one clean left edge.
   The chevron lives in its own fixed 24px gutter so it never shifts the text;
   article rows get an empty gutter to match. */
.rail-group-toggle { display: none; }
.rail-cat { display: grid; grid-template-columns: 24px 1fr; align-items: center; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; color: var(--muted); padding: 8px 12px 8px 8px; margin-bottom: 2px; cursor: pointer; border-radius: 8px; user-select: none; }
.rail-cat:hover { color: var(--ink); background: var(--bg-soft); }
.rail-cat > span { overflow: hidden; text-overflow: ellipsis; }
.rail-chevron { width: 14px; height: 14px; justify-self: center; transition: transform .15s ease; }
.rail-group-toggle:checked ~ .rail-cat .rail-chevron { transform: rotate(90deg); }
.rail-group-toggle:checked ~ .rail-cat { color: var(--teal); }
.rail-group-items { display: none; }
.rail-group-toggle:checked ~ .rail-group-items { display: block; }
.rail-group-items .rail-link { display: grid; grid-template-columns: 24px 1fr; align-items: start; padding-left: 8px; padding-right: 12px; }
.rail-group-items .rail-link::before { content: ""; display: block; }
.rail-close { display: none; }
.rail-main { flex: 1; min-width: 0; }
/* Rail layout: the article's own top padding is redundant — .page-with-rail
   already provides it. Zero it so the rail column and article column start
   on the same baseline (rail heading aligned with the article kicker). */
.rail-main .page-hero { padding-top: 0; }
.rail-main .article-wrap { padding-top: 0; }
/* rail filter: progressive enhancement — full list renders with zero JS */
.rail-top { position: sticky; top: 0; background: var(--surface); z-index: 2; padding: 2px 0 10px; }
.rail-search svg { width: 16px; height: 16px; flex: none; color: var(--muted); }
.rail-clear { border: none; background: none; font-size: 20px; line-height: 1; color: var(--muted); cursor: pointer; padding: 0 2px; }
.rail-clear:hover { color: var(--ink); }
.rail-empty { padding: 12px; font-size: 14.5px; color: var(--muted); }
.rail [hidden] { display: none !important; }
@media (max-width: 820px) {
  .page-with-rail { flex-direction: column; gap: 0; padding: 24px 20px 64px; }
  .rail-toggle-btn { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 4px; padding: 10px 16px 10px 12px; border: 1.5px solid var(--border); border-radius: 12px; background: var(--surface); font-size: 14.5px; font-weight: 700; color: var(--teal); cursor: pointer; }
  .rail-toggle-btn::after { content: "Articles"; }
  .rail-toggle-btn span { width: 20px; }
  .rail { display: none; position: fixed; top: 0; left: 0; bottom: 0; width: min(320px, 86vw); z-index: 400; background: var(--surface); border-right: 1px solid var(--border); box-shadow: 24px 0 64px rgba(15,44,58,.18); padding: 16px 16px 32px; max-height: none; }
  .rail-toggle:checked ~ .rail { display: block; }
  .rail-close { display: block; text-align: right; font-size: 30px; line-height: 1; color: var(--muted); cursor: pointer; padding: 0 4px 6px; }
}

/* ---------- Profile cards (Cloudflare-style) ---------- */
.pf-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 0; border-bottom: 1px solid var(--bg-soft); }
.pf-row:last-child { border-bottom: none; }
.pf-label { font-size: 16px; font-weight: 700; }
.pf-value { color: var(--muted); font-size: 14.5px; margin-top: 2px; word-break: break-all; }
.pf-hint { color: var(--muted); font-size: 14.5px; margin-top: 2px; }

/* ---------- Modals ---------- */
.modal-backdrop { position: fixed; inset: 0; background: rgba(15,44,58,.52); display: flex; align-items: center; justify-content: center; padding: 20px; z-index: 500; }
.modal-backdrop[hidden] { display: none; }
.modal { background: var(--surface); border-radius: 18px; width: 100%; max-width: 460px; padding: 28px; box-shadow: 0 24px 64px rgba(0,0,0,.25); max-height: calc(100vh - 60px); overflow-y: auto; }
.modal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.modal-head h2 { font-size: 20px; letter-spacing: -0.4px; margin: 0; }
.modal-x { background: none; border: none; font-size: 30px; line-height: 1; color: var(--muted); cursor: pointer; padding: 2px 6px; }
.modal-x:hover { color: var(--ink); }
.modal-sub { font-size: 14.5px; color: var(--muted); margin-bottom: 16px; }
.modal-sub strong { color: var(--ink); }
.modal .field-input { max-width: none; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }
.req { color: var(--red); }
.location-table { width: 100%; border-collapse: collapse; font-size: 14.5px; table-layout: fixed; }
.location-table th { padding: 10px 16px; text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); border-bottom: 2px solid var(--border); }
.location-table th:first-child { width: 42%; }
.location-table td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: top; line-height: 1.5; text-align: left; word-wrap: break-word; }
.location-table tbody tr:last-child td { border-bottom: none; }
.location-table tbody tr:hover td { background: var(--bg-soft); }
.location-table td a { color: var(--teal); font-weight: 600; text-decoration: none; }
.location-table td a:hover { text-decoration: underline; }
.page-matrix { border-collapse: collapse; font-size: 13px; min-width: 100%; }
.page-matrix th, .page-matrix td { padding: 8px 10px; border-bottom: 1px solid var(--border); text-align: center; }
.page-matrix th:first-child, .page-matrix td:first-child { text-align: left; }
.page-matrix thead th { font-size: 12px; color: var(--muted); border-bottom: 2px solid var(--border); }
.page-matrix thead th a { color: var(--teal); font-weight: 700; text-decoration: none; }
.page-matrix tbody tr:last-child td { border-bottom: none; }
.page-matrix tbody tr:hover td { background: var(--bg-soft); }
.mx-check { display: inline-block; width: 22px; height: 22px; line-height: 22px; border-radius: 50%; background: var(--teal); color: #fff; font-size: 13px; font-weight: 700; }
.platform-steps { margin: 12px 0 0; padding: 0; }
.platform-steps dt { font-weight: 700; color: var(--teal); font-size: 13px; margin-top: 10px; }
.platform-steps dt:first-child { margin-top: 0; }
.platform-steps dd { margin: 2px 0 0; padding: 0; font-size: 14.5px; line-height: 1.55; color: var(--ink); }
.fix p { margin: 0 0 8px; font-size: 13px; line-height: 1.6; color: var(--muted); }

/* ===== merged QA batch qa-css-a.css ===== */
/* ===== QA batch A — {{BRAND_NAME}} wizard fixes (Items 1–4) =====
   Merge AFTER components/shared.css so these rules win ties. */

/* --- ITEM 1: competitor rows — one clean baseline for URL text, Edit, and × --- */
ul.comp-list li.comp-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 2px;
  line-height: 1.45;
}
ul.comp-list li.comp-item .comp-url {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
ul.comp-list li.comp-item .comp-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: none;
}
ul.comp-list li.comp-item .comp-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
  font-size: 20px;
  line-height: 1;
  padding: 0;
  text-decoration: none;
}
ul.comp-list li.comp-item .comp-remove:hover { color: var(--ink); }

/* --- ITEM 2: wizard nav — Back left, Skip + primary grouped right --- */
.wizard .wizard-nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
}
@media (max-width: 480px) {
  .wizard .wizard-nav { flex-wrap: wrap; gap: 12px; }
}

/* --- ITEM 3: listings labels + ~20px spacing between fields --- */
.listings-block .listing-field { margin-bottom: 20px; }
.listings-block .listing-field:last-child { margin-bottom: 0; }
.listings-block .listing-field label {
  display: block;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 8px;
}
/* beat .listings-block input's 10px bottom margin in shared.css */
.listings-block .listing-field input { margin-bottom: 0; }

/* --- ITEM 4: app scan steps match marketing free-preview .fs-step style --- */
.fs-step {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  font-size: 14.5px;
  color: var(--muted);
}
.fs-step .dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--border);
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
}
.fs-step.active { color: var(--ink); font-weight: 600; }
.fs-step.active .dot { border-color: var(--orange); }
.fs-step.active .dot::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--orange);
  animation: fs-pulse 1s infinite;
}
.fs-step.done { color: var(--ink); }
.fs-step.done .dot { border-color: var(--teal); background: var(--teal); color: #fff; }
.fs-step.done .dot::after { content: "✓"; }
@keyframes fs-pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }

/* ===== merged QA batch qa-css-b.css ===== */
/* QA batch B CSS — report page fixes (items 5-8). Merge into shared.css. */

/* ITEM 5: "Where we found it" line matches the description (.why) size (15px),
   never smaller. Replaces the removed inline font-size:13px style. */
.rank-body .finding-location {
  font-size: 14.5px;
  color: var(--muted);
  margin: 0 0 8px;
}

/* ITEM 6: report bottom buttons — Rescan left, Download right. */
#report-root .report-actions {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 32px;
}
/* Report top bar (2026-10-13, Kuang): the action buttons sit at the right
   of the logo/masthead section, as one tight group — not spread across
   their own row. */
.report-topbar {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.report-topbar .wl-masthead {
  flex: 1;
  margin-bottom: 0;
}
#report-root .report-topbar .report-actions {
  justify-content: flex-end;
  margin-top: 0;
  margin-left: auto;
  padding-top: 4px;
  flex-wrap: nowrap;
}
#report-root .wl-masthead .report-actions {
  justify-content: flex-end;
  align-items: center;
  margin-top: 0;
  margin-left: auto;
  flex-wrap: nowrap;
}
.report-topbar { margin-bottom: 14px; }
.rescan-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.rescan-days {
  font-size: 13px;
  color: var(--muted);
  margin: 8px 0 0;
}

/* ITEM 7: monitoring upsell above the bottom buttons. */
.monitor-upsell {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px 28px;
  margin: 32px 0 0;
}
.monitor-upsell h2 {
  font-size: 20px;
  margin: 0 0 10px;
  letter-spacing: -0.3px;
}
.monitor-upsell p {
  font-size: 14.5px;
  color: var(--muted);
  line-height: 1.6;
  margin: 0 0 10px;
  max-width: 640px;
}

/* ITEM 8: "Developer" — two side-by-side cards. */
.pro-tools-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.pro-tool-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px 22px;
  text-decoration: none;
  color: inherit;
  transition: border-color .15s;
}
.pro-tool-card:hover {
  border-color: var(--teal);
}
.pro-tool-card h3 {
  font-size: 16px;
  margin: 0 0 6px;
  color: var(--teal);
}
.pro-tool-card p {
  font-size: 14.5px;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
}
@media (max-width: 640px) {
  .pro-tools-grid {
    grid-template-columns: 1fr;
  }
  .report-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .rescan-wrap {
    align-items: stretch;
  }
}

/* ===== merged QA batch qa-css-c.css ===== */
/* qa-css-c.css — NEW styles for billing/profile/monitoring (batch C, 2026-10-06).
   To be merged by parent into the build. Do NOT duplicate these in shared.css/app.css. */

/* ---------- Item 12: purchase history table (softer ink) ---------- */
.purch-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.purch-table thead th {
  padding: 12px 16px; font-size: 12px; text-transform: uppercase; letter-spacing: .5px;
  color: var(--muted); text-align: left; border-bottom: 1px solid var(--border);
}
.purch-table tbody td {
  padding: 12px 16px; border-top: 1px solid var(--border); color: var(--muted);
}
.purch-table tbody td.amt { color: var(--ink); font-weight: 600; }
.purch-table .inv-dl {
  color: var(--teal); display: inline-flex; padding: 6px; border-radius: 8px; line-height: 0;
}
.purch-table .inv-dl:hover { background: var(--bg-soft); color: var(--teal-dark); }
.purch-table .inv-dl svg { display: block; }

/* ---------- Item 13: invoice bill-to / notes / footer ---------- */
.inv-billto { margin: 0 0 26px; font-size: 14.5px; }
.inv-billto .bill-k {
  display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .06em;
  color: var(--muted); margin-bottom: 4px;
}
.inv-billto strong { font-size: 16px; }
.inv-billto .bill-addr { margin-top: 2px; color: var(--muted); font-size: 13px; }
.inv-notes {
  margin-top: 26px; padding-top: 16px; border-top: 1px solid var(--border);
  font-size: 13px; color: var(--muted);
}
.inv-notes strong {
  display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .06em;
  color: var(--muted); margin-bottom: 6px;
}
.inv-notes p { margin: 4px 0; }
.inv-foot {
  margin-top: 30px; padding-top: 14px; border-top: 2px solid var(--border);
  font-size: 12.5px; color: var(--muted); text-align: center;
}

/* ---------- Item 14: download-all print layout ---------- */
.inv-print-item { margin-bottom: 24px; }
@media print {
  .inv-print-item { break-before: page; }
  .inv-print-item:first-child { break-before: auto; }
  #invoices-print .report-actions { display: none !important; }
}

/* ---------- Item 15: pill file picker (button inside the input) ---------- */
.file-pill {
  display: flex; align-items: center; gap: 12px; box-sizing: border-box; height: 40px;
  border: 1px solid var(--border); border-radius: 10px; background: var(--surface);
  padding: 0 14px; max-width: 440px; transition: border-color .15s, box-shadow .15s;
}
.file-pill:focus-within { border-color: var(--teal); box-shadow: 0 0 0 3px color-mix(in srgb, var(--teal) 22%, transparent); }
.file-pill .file-name {
  flex: 1; min-width: 0; font-size: 14.5px; color: var(--muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.file-pill .file-name.has-file { color: var(--ink); }

/* ---------- Items 10 + 15: logo preview container + corner x ---------- */
.logo-wrap { position: relative; display: inline-block; }
.logo-wrap img {
  display: block; max-height: 64px; max-width: 200px;
  border: 1px solid var(--border); border-radius: 8px; padding: 6px; background: var(--surface);
}
.logo-x {
  position: absolute; top: -10px; right: -10px;
  width: 24px; height: 24px; border-radius: 50%;
  border: 1px solid var(--border); background: var(--surface); color: var(--muted);
  font-size: 14.5px; line-height: 1; padding: 0; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.logo-x:hover { color: var(--red); border-color: var(--red); }

/* ---------- Item 16: active monitoring ---------- */
.mon-sites { list-style: none; margin: 12px 0 0; padding: 0; }
.mon-sites li {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 0; border-bottom: 1px solid var(--bg-soft); font-size: 14.5px;
}
.mon-sites li:last-child { border-bottom: none; }
.mon-sites .mon-url {
  font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.mon-add-row { display: flex; gap: 10px; margin-top: 14px; }
.mon-empty { color: var(--muted); font-size: 14.5px; margin: 8px 0 0; }

/* ===== merged QA batch qa-css-d.css ===== */
/* =====================================================================
   qa-css-d.css — QA batch D: new CSS for the {{BRAND_NAME}} marketing + help sites.
   Merge into the site stylesheets. Uses the site variables:
   --teal var(--teal) · --teal-ink #0f3c50 · --orange var(--orange) · --orange-dark #e56f00
   --ink #1a2b33 · --muted #5a6f78 · --bg-soft #f4f7f8 · --border #dde5e8
   --radius 12px · --green var(--green) · --amber var(--amber)
   ===================================================================== */

/* ---------------- ITEM 9 — sample report: blurred teaser ---------------- */
.report-teaser{position:relative;margin:0 0 28px;}
.teaser-blurred{filter:blur(6px);-webkit-filter:blur(6px);
  user-select:none;-webkit-user-select:none;pointer-events:none;}
.teaser-lock{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;
  padding:24px;border-radius:14px;
  background:linear-gradient(180deg,rgba(255,255,255,.08) 0%,rgba(255,255,255,.68) 55%,rgba(255,255,255,.94) 100%);}
.teaser-lock-card{background: var(--surface);border:1px solid var(--border);border-radius:16px;
  box-shadow:0 16px 48px rgba(15,60,80,.16);padding:34px 38px;text-align:center;max-width:460px;}
.teaser-lock-ic{width:54px;height:54px;border-radius:50%;background:var(--bg-soft);color:var(--teal);
  display:flex;align-items:center;justify-content:center;margin:0 auto 16px;}
.teaser-lock-ic svg{width:25px;height:25px;}
.teaser-lock-card h3{font-size: 20px;letter-spacing:-.3px;margin:0 0 6px;}
.teaser-lock-card p{color:var(--muted);font-size: 14.5px;margin:0 0 20px;}
.teaser-lock-cta{display:flex;gap:10px;justify-content:center;flex-wrap:wrap;}
@media (max-width:560px){
  .teaser-lock-card{padding:26px 22px;}
}

/* Sample report bits that were previously unstyled (QA fix) */
.est-line{margin-top:14px;font-size:14.5px;color:var(--muted);}
.est-line strong{color:var(--ink);}
.mx-chip{display:inline-block;font-size:12px;font-weight:700;padding:3px 12px;border-radius:999px;white-space:nowrap;}
.mx-chip.mx-ok{background:var(--green-bg);color:var(--ok);}
.mx-dot{display:inline-flex;align-items:center;justify-content:center;width:20px;height:20px;border-radius:50%;font-size:12px;font-weight:700;color:#fff;line-height:1;}
.mx-dot-ok{background:#1e7e34;}
.mx-dot-bad{background:#b3362b;}
.mx-dot-warn{background:#d97706;}
.mx-chip.mx-bad{background:var(--red-bg);color:#a93226;}

/* ---------------- ITEM 11 — blog graphics ---------------- */

/* Pull quote */
.pull-quote{border-left:4px solid var(--orange);margin:30px 0;padding:8px 0 8px 24px;
  font-size: 20px;line-height:1.55;font-weight:600;color:var(--ink);}
.pull-quote cite{display:block;margin-top:10px;font-size: 14.5px;font-style:normal;color:var(--muted);font-weight:400;}

/* Stat / key-takeaway callout */
.stat-callout{background:var(--bg-soft);border:1px solid var(--border);border-radius:var(--radius);
  padding:22px 26px;margin:30px 0;display:flex;gap:20px;align-items:center;}
.stat-callout .stat-num{font-size:42px;font-weight:800;color:var(--teal);line-height:1;flex:none;white-space:nowrap;}
.stat-callout .stat-txt{font-size:14.5px;color:var(--muted);line-height:1.55;}
.stat-callout .stat-txt strong{color:var(--ink);font-weight:400;}
@media (max-width:560px){
  .stat-callout{flex-direction:column;align-items:flex-start;gap:8px;}
}

/* Generic graphic wrapper + caption */
.graphic-card{background: var(--surface);border:1px solid var(--border);border-radius:var(--radius);
  padding:28px;margin:30px 0;}
.graphic-card h4{font-size: 14.5px;margin:0 0 18px;text-align:center;color:var(--ink);}
.graphic-cap{font-size: 13px;color:var(--muted);margin:14px 0 0;text-align:center;}

/* 3-step diagram (Crawl → Parse → Cite, etc.) */
.steps-diagram{display:flex;align-items:stretch;justify-content:center;}
.step-node{flex:1 1 0;max-width:210px;text-align:center;padding:0 6px;}
.step-node .dot{width:46px;height:46px;border-radius:50%;background:var(--teal);color:#fff;
  font-weight:800;font-size: 20px;display:flex;align-items:center;justify-content:center;margin:0 auto 10px;}
.step-node .t{font-weight:700;font-size: 14.5px;margin-bottom:4px;}
.step-node .d{font-size:13px;color:var(--muted);line-height:1.45;}
.step-link{flex:0 0 44px;align-self:center;color:#b9c8cd;display:flex;justify-content:center;}
.step-link svg{width:28px;height:28px;}
@media (max-width:560px){
  .steps-diagram{flex-direction:column;gap:18px;}
  .step-node{max-width:none;}
  .step-link{transform:rotate(90deg);align-self:center;}
}

/* Before / after bar pair */
.ba-row{margin:0 0 16px;}
.ba-row:last-child{margin-bottom:0;}
.ba-top{display:flex;justify-content:space-between;align-items:baseline;font-size: 13px;font-weight:600;margin-bottom:6px;}
.ba-top .ba-val{color:var(--teal);font-weight:800;}
.ba-track{background:var(--soft-2);border-radius:999px;height:26px;overflow:hidden;}
.ba-fill{width:var(--w,0%);height:100%;border-radius:999px;display:flex;align-items:center;justify-content:flex-end;
  padding-right:12px;color:#fff;font-size:12.5px;font-weight:700;min-width:52px;box-sizing:border-box;}
.ba-fill.before{background:#9aa5ad;}
.ba-fill.after{background:var(--teal);}

/* Mini score ring (blog-sized; independent of the app's .score-ring) */
.mini-ring{width:124px;height:124px;border-radius:50%;margin:0 auto;display:flex;align-items:center;justify-content:center;
  background:conic-gradient(var(--ringc,var(--orange)) 0% var(--pct,0%),var(--soft-3) var(--pct,0%) 100%);}
.mini-ring .inner{width:94px;height:94px;border-radius:50%;background: var(--surface);
  display:flex;flex-direction:column;align-items:center;justify-content:center;}
.mini-ring .big{font-size: 30px;font-weight:800;line-height:1;}
.mini-ring .cap{font-size: 11px;color:var(--muted);text-transform:uppercase;letter-spacing:1px;margin-top:2px;}
.ring-row{display:flex;gap:28px;justify-content:center;flex-wrap:wrap;align-items:flex-start;}
.ring-item{text-align:center;max-width:170px;}
.ring-item .rl{font-weight:700;font-size: 14.5px;margin-top:10px;}
.ring-item .rd{font-size:12.5px;color:var(--muted);margin-top:2px;}

/* "Label maker" diagram (facts → labels) */
.label-diagram{display:flex;flex-direction:column;gap:12px;max-width:460px;margin:0 auto;text-align:left;}
.label-row{display:flex;align-items:center;gap:12px;background:var(--bg-soft);
  border:1px solid var(--border);border-radius:10px;padding:12px 16px;font-size: 14.5px;}
.label-row .fact{flex:1;font-weight:600;}
.label-row .tag{flex:none;background:var(--teal);color:#fff;font-size:12px;font-weight:700;
  padding:4px 12px;border-radius:999px;white-space:nowrap;}

/* Crawler allow / block mini table */
.crawler-table{width:100%;border-collapse:collapse;font-size: 14.5px;text-align:left;}
.crawler-table th{font-size:12px;text-transform:uppercase;letter-spacing:.5px;color:var(--muted);
  padding:8px 12px;border-bottom:2px solid var(--border);text-align:left;}
.crawler-table td{padding:9px 12px;border-bottom:1px solid var(--border);}
.crawler-table tr:last-child td{border-bottom:none;}
.pill{display:inline-flex;align-items:center;height:24px;font-size:12px;font-weight:700;padding:0 12px;border-radius:999px;white-space:nowrap;}
.pill.allow{background:var(--green-bg);color:var(--ok);}
.pill.block{background:var(--red-bg);color:#a93226;}
.pill.neutral{background:var(--soft-2);color:var(--muted);}

/* llms.txt structure diagram */
.doc-tree{max-width:440px;margin:0 auto;text-align:left;}
.doc-node{border:1px solid var(--border);border-radius:10px;padding:12px 16px;margin-bottom:10px;
  background: var(--surface);font-size:14.5px;}
.doc-node:last-child{margin-bottom:0;}
.doc-node .k{font-size:11.5px;text-transform:uppercase;letter-spacing:.6px;color:var(--muted);
  display:block;margin-bottom:2px;font-weight:700;}
.doc-node.root{background:var(--teal-ink);border-color:var(--teal-ink);color:#fff;font-weight:700;}
.doc-node.root .k{color:#a9c3cd;}
.doc-node.child{margin-left:30px;position:relative;}
.doc-node.child::before{content:"";position:absolute;left:-20px;top:50%;width:20px;height:2px;background:var(--border);}

/* Two-doors diagram (robots.txt vs server) */
.doors{display:grid;grid-template-columns:1fr 1fr;gap:16px;max-width:580px;margin:0 auto;}
@media (max-width:560px){.doors{grid-template-columns:1fr;}}
.door{background: var(--surface);border:2px solid var(--border);border-radius:var(--radius);padding:22px 18px;text-align:center;}
.door.bad{border-color:var(--red);}
.door .door-ic{width:44px;height:44px;margin:0 auto 12px;color:var(--teal);}
.door.bad .door-ic{color:var(--red);}
.door .door-ic svg{width:100%;height:100%;}
.door .door-t{font-weight:800;font-size: 14.5px;margin-bottom:6px;}
.door .door-d{font-size: 13px;color:var(--muted);line-height:1.5;}
.door .door-d code{font-size:12.5px;}

/* Monitoring submenu */
.side-submenu { margin: 2px 0 4px 30px; padding-left: 12px; border-left: 2px solid var(--border); }
.side-submenu.collapsed { display: none; }
/* Section headers work like the help rail: the whole row (icon, text,
   chevron) is one toggle button, styled to match the nav links. */
.side-head { display: flex; align-items: center; gap: 12px; width: 100%; padding: 11px 12px; border: none; border-radius: 10px; background: none; font: inherit; font-size: 14.5px; font-weight: 500; color: var(--muted); text-align: left; cursor: pointer; }
.side-head > svg:first-child { width: 18px; height: 18px; flex: none; }
.side-head:hover { background: var(--bg-soft); color: var(--ink); }
.side-head.active { background: var(--bg-soft); color: var(--teal); font-weight: 700; }
.side-head .side-chev { width: 16px; height: 16px; flex: none; margin-left: auto; transition: transform .15s ease; }
.side-toggle[aria-expanded="true"] .side-chev { transform: rotate(180deg); }
.side-sub-link { display: block !important; padding: 8px 12px !important; font-size: 13px !important; }

/* ---------- Utilities (2026-10-14: inline styles moved to the sheet) ----------
   Single-purpose classes replacing the most common style="..." patterns.
   New markup uses these, never inline styles. */
.u-muted { color: var(--muted); }
.u-sub { font-weight: 400; color: var(--muted); }
.u-teal { color: var(--teal); }
.u-teal-b { color: var(--teal); font-weight: 700; }
.u-teal-6 { color: var(--teal); font-weight: 600; }
.u-center { text-align: center; }
.u-right { text-align: right; }
.u-ox { overflow-x: auto; }
.u-w100 { width: 100%; }
.u-soft { background: var(--bg-soft); }
.u-mb-2 { margin-bottom: 2px; }
.u-mb-6 { margin-bottom: 6px; }
.u-mb-12 { margin-bottom: 12px; }
.u-mb-14 { margin-bottom: 14px; }
.u-mb-16 { margin-bottom: 16px; }
.u-mb-24 { margin-bottom: 24px; }
.u-mt-8 { margin-top: 8px; }
.u-mt-16 { margin-top: 16px; }
.u-mt-28 { margin-top: 28px; }
.u-mt-48 { margin-top: 48px; }
.u-pb-12 { padding-bottom: 12px; }
.u-pt-28 { padding-top: 28px; }
.u-w760 { max-width: 760px; }
.u-w860 { max-width: 860px; }
.u-lead-sm { font-size: 12px; margin-bottom: 2px; }
.u-h3-reset { font-size: 16px; margin: 0 0 12px; }
.u-center-col { text-align: center; max-width: 640px; margin-left: auto; margin-right: auto; }
.input-plain { width: 100%; }
.u-mt-3 { margin-top: 3px; }
.u-mt-10 { margin-top: 10px; }
.u-mt-12 { margin-top: 12px; }
.u-mb-10 { margin-bottom: 10px; }
.u-pb-16 { padding: 0 0 16px; }
.u-pt-0 { padding-top: 0; }
.u-upper { text-transform: uppercase; }
.u-pre { margin: 8px 0 0; white-space: pre-wrap; font-size: 12.5px; max-height: 200px; overflow-y: auto; }
.u-pre-sm { margin: 8px 0 0; font-size: 13px; }
.u-check { margin-top: 3px; accent-color: var(--teal); }
.u-flex240 { flex: 1; min-width: 240px; }
.u-flex1 { flex: 1; }
.u-align-start { align-items: flex-start; }
.u-stack { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.u-check-row { display: flex; gap: 8px; align-items: center; font-size: 14.5px; cursor: pointer; }
.u-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; max-width: 520px; }
.u-m-4-10 { margin: 4px 0 10px; }
.u-mt-18 { margin-top: 18px; }
.u-mt-22 { margin-top: 22px; }
.u-mt-32 { margin-top: 32px; }
.u-mb-8 { margin-bottom: 8px; }
.u-mb-18 { margin-bottom: 18px; }
.u-fs14 { font-size: 14.5px; }
.u-fs145 { font-size: 14.5px; }
.u-fs22 { font-size: 20px; }
.u-fs15 { font-size: 14.5px; }
.u-ink { color: var(--ink); }
.u-muted-145 { color: var(--muted); font-size: 14.5px; }
.u-note-13 { margin-top: 10px; font-size: 13px; color: var(--muted); }
.u-note-14m { margin-top: 18px; font-size: 14.5px; color: var(--muted); }
.u-note-666 { font-size: 12px; color: #666; margin: 6px 0 0; }
.u-hint-lg { font-size: 13px; color: var(--muted); }
.u-label-b { display: block; font-weight: 600; margin-bottom: 8px; font-size: 14.5px; }
.u-label-b2 { display: block; font-weight: 600; font-size: 14.5px; margin-bottom: 6px; }
.u-flex-label { display: flex; align-items: center; gap: 8px; cursor: pointer; font-size: 14.5px; }
.u-cb { width: 16px; height: 16px; }
.u-block { display: block; }
.u-h2-18 { font-size: 20px; margin: 0 0 16px; }
.u-h2-22 { font-size: 20px; margin-bottom: 6px; }
.u-flex-between { display: flex; justify-content: space-between; }
.u-flex-between-c { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.u-m-0 { margin: 0; }
.u-m-40-6 { margin: 40px 0 6px; }
.u-flush { padding: 0; overflow: hidden; }
.u-msg { font-size: 13px; margin-top: 8px; }
.u-msg-14 { margin-top: 10px; font-size: 14.5px; }
.u-note-13m { font-size: 13px; color: var(--muted); margin-top: 6px; }
.u-note-14 { margin-top: 8px; font-size: 14.5px; }
.u-tos { display: flex; gap: 8px; align-items: flex-start; margin: 12px 0; font-size: 14.5px; color: var(--ink-2); }
.u-tos2 { display: flex; gap: 8px; align-items: flex-start; margin: 4px 0 12px; font-size: 14.5px; color: var(--ink-2); }
.st-err { color: var(--red); }
.st-ok2 { color: var(--green); }
.u-verify { max-width: 480px; margin: 80px auto; padding: 0 20px; text-align: center; }
.u-mb-0 { margin-bottom: 0; }
.u-pf-hint { margin: 6px 0 4px; }
.u-grid2b { display: grid; grid-template-columns: 1fr 130px; gap: 12px; max-width: 520px; }
.u-ra-a { margin: 0 0 20px; justify-content: flex-start; }
.u-ra-b { margin-top: 20px; }
.u-co-row { padding-bottom: 0; justify-content: center; }
.u-pt-24 { padding-top: 24px; }
.u-pt-8 { padding-top: 8px; }
.u-mt-14 { margin-top: 14px; }
.u-mt-20 { margin-top: 20px; }
.u-mt-24 { margin-top: 24px; }
.u-w620 { max-width: 620px; }
.u-w680 { max-width: 680px; }
.u-w720 { max-width: 720px; }
.u-w1100 { max-width: 1100px; margin-left: auto; margin-right: auto; }
.u-foot-note { text-align: center; font-size: 14.5px; color: #666; margin: 8px 0 0; }
.u-left-reset { text-align: left; margin-left: 0; margin-right: 0; }
.u-jc-start { justify-content: flex-start; }
.u-lead-17 { font-size: 14.5px; color: var(--muted); line-height: 1.65; }
.u-p15a { font-size: 14.5px; margin: 8px 0; }
.u-p15b { font-size: 14.5px; margin: 12px 0 0; }
.u-anchor-soft { background: var(--bg-soft); scroll-margin-top: 80px; }
.u-soft-pt { background: var(--bg-soft); padding-top: 56px; }
/* Text-color utilities (blog/content pages, 2026-10-14 cleanup) */
.u-c-orange { color: var(--orange); }
.u-c-teal { color: var(--teal); }

.blog-fig { width: 100%; height: auto; background: var(--surface); border-radius: 12px; padding: 16px; box-sizing: border-box; }
.u-c-muted { color: var(--muted); }
.u-c-ok { color: #1e7e34; }
.cat-strip .cat-score { color: var(--c); }

/* ---------- Theme: dark (Kuang 2026-10-14) ----------
   Light is the default. Dark applies only when the user picks it with
   the header toggle (data-theme="dark" on <html>, persisted in
   localStorage 'ui_theme'; set pre-paint by the build-injected init
   script). No OS auto-switching. Print always renders light. The dark
   palette stays in the brand family: deep teal-ink surfaces, brighter
   teal for text, the same orange. */
:root[data-theme="dark"] {
  color-scheme: dark;
  --teal: #4aa8cc;
  --teal-dark: #2e7ea6;
  --orange: #ff7e00;
  --orange-dark: #ffa040;
  --ink: #e9f1f3;
  --muted: #9db4bc;
  --bg: #0b181e;
  --bg-soft: #10222a;
  --bg-sage: #0f2420;
  --border: #22414d;
  --red: #ff9a8a;
  --red-bg: #3a1e1a;
  --amber: #e3ac55;
  --amber-bg: #33290f;
  --green: #4cc38a;
  --green-bg: #11301f;
  --surface: #0f2027;
  --surface-2: #12262e;
  --ink-2: #c2d3d9;
  --ink-3: #d9e5e9;
  --doc-ink: #e9f1f3;
  --muted-2: #87a0a8;
  --line: #22414d;
  --line-2: #1b333d;
  --ok: #4cc38a;
  --ok-dark: #8fe0b0;
  --ok-bg: #11301f;
  --err-bg: #3a1e1a;
  --err-line: #6e352c;
  --warn-bg: #2f2a0e;
  --warn-line: #6b5d1e;
  --teal-bg: #10303d;
  --teal-2: #2ea89b;
  --soft-2: #12262e;
  --soft-3: #16303a;
}
/* Theme toggle (app header): moon in light, sun in dark. */
.theme-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 10px; flex: none;
  background: none; border: 1px solid transparent; cursor: pointer; color: var(--muted);
}
.theme-toggle:hover { color: var(--teal); background: var(--bg-soft); }
.theme-toggle svg { width: 21px; height: 21px; }
.theme-toggle .ic-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .ic-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .ic-moon { display: none; }
/* Dark overrides for shared rules that hardcode light tints (their text
   uses var(--ink), which flips light in dark — Kuang's report screenshot,
   2026-10-14: the "For your web person" bar was unreadable). */
:root[data-theme="dark"] .pro-group-header { background: var(--surface-2); border-color: #5c4d1c; }
:root[data-theme="dark"] .callout-note { background: var(--teal-bg); border-color: var(--border); }
:root[data-theme="dark"] .gbp-fix { background: var(--surface-2); border-color: #5c4d1c; }
:root[data-theme="dark"] .uplift-badge { background: var(--teal-bg); }
:root[data-theme="dark"] .tier-wp { background: var(--surface-2); color: var(--amber); }
:root[data-theme="dark"] .tier-split { background: var(--teal-bg); color: #7cc4e8; }
:root[data-theme="dark"] .teaser-lock { background: linear-gradient(180deg, rgba(11,24,30,.08) 0%, rgba(11,24,30,.68) 55%, rgba(11,24,30,.94) 100%); }
:root[data-theme="dark"] .prose code, :root[data-theme="dark"] .article-body code { color: #7cc4e8; }
@media print {
  :root[data-theme="dark"] {
    color-scheme: light;
    --bg: #ffffff; --surface: #ffffff; --surface-2: #fbfdff;
    --ink: #1a2b33; --ink-2: #3a4a52; --ink-3: #24333b; --doc-ink: #17211f;
    --muted: #5a6f78; --muted-2: #71828c; --border: #dde5e8;
    --line: #dde6ea; --line-2: #e3ebee; --bg-soft: #f4f7f8; --bg-sage: #eef3f1;
  }
}

/* Blog editorial package (2026-10-15): takeaways box, data note, tables */
.takeaways { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px; padding: 18px 22px; margin: 22px 0; }
.takeaways h2 { font-size: 17px; margin: 0 0 8px; }
.takeaways ul { margin: 0; padding-left: 20px; }
.takeaways li { margin: 5px 0; line-height: 1.55; font-size: 14.5px; color: var(--muted); }
.about-data { font-size: 14.5px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 12px; margin-top: 28px; }
.related-reading { font-size: 14.5px; margin-top: 14px; }
.prose h3 { font-size: 16px; margin: 28px 0 8px; }
.prose .chart-label, .prose .chart-val, .article-body .chart-label, .article-body .chart-val { font-size: 14.5px; }

.prose table, .article-body table { border-collapse: collapse; width: 100%; margin: 18px 0; font-size: 14.5px; color: var(--muted); }
.prose th, .prose td, .article-body th, .article-body td { border: 1px solid var(--line); padding: 8px 11px; text-align: left; vertical-align: top; }
.prose th, .article-body th { background: var(--bg-soft); font-size: 12px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); }

.sources { margin-top: 30px; border-top: 1px solid var(--line); padding-top: 14px; }
.sources h2 { font-size: 16px; margin: 0 0 8px; }
.sources ul { margin: 0; padding-left: 20px; }
.sources li { margin: 4px 0; font-size: 14.5px; }

.prose p strong, .prose li strong, .prose td strong, .article-body td strong, .takeaways strong { font-weight: 400; color: var(--ink); }

.h-ico { width: 18px; height: 18px; vertical-align: -3px; margin-right: 7px; color: var(--teal); flex: none; }

.sample-badge { display: inline-block; background: var(--amber-bg); color: var(--amber); font-weight: 700; font-size: 13px; padding: 8px 16px; border-radius: 20px; margin: 8px 0 20px; border: 1px solid var(--line); }
.sample-cta { text-align: center; margin-top: 40px; }
.sample-cta h2 { font-size: 20px; margin-bottom: 8px; }
.sample-cta p { color: var(--muted); font-size: 14.5px; }

.bf-ok { background: var(--green); }
.bf-warn { background: var(--amber); }
.bf-bad { background: var(--red); }
.bf-teal { background: var(--teal); }
.bf-mute { background: var(--muted); }

/* === app property styles === */
body { font-size: 13px; }
/* {{BRAND_NAME}} app + admin site-specific styles.
   Shared system (tokens, app header, buttons, report modules, auth, admin
   panels) comes from components/shared.css, prepended at build time. */

body { background: var(--bg-soft); }

/* The `hidden` attribute must win over display:* rules (e.g. .mon-plan's
   display:flex) or toggled sections stay visible. */
[hidden] { display: none !important; }

/* wizard */
.wizard { max-width: 720px; margin: 0 auto; padding: 48px 24px 80px; }
.wizard h1 { font-size: clamp(28px, 4.5vw, 40px); font-weight: 800; letter-spacing: -1px; text-align: left; margin-bottom: 10px; }
.wizard .sub { text-align: left; color: var(--muted); margin-bottom: 32px; }
.url-hint { text-align: center; font-size: 13px; color: var(--muted); margin-top: 12px; }
.url-error { display: none; text-align: center; color: var(--red); font-size: 14.5px; margin-top: 12px; }

/* progress */
.progress-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 40px; text-align: center; }
.progress-card .spin { width: 46px; height: 46px; border: 4px solid var(--border); border-top-color: var(--orange); border-radius: 50%; margin: 0 auto 20px; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.progress-card p { color: var(--muted); }
.checks-line { margin-top: 18px; font-size: 14.5px; color: var(--teal); font-weight: 600; min-height: 22px; }

/* paywall */
.paywall-card { background: var(--surface); border: 2px solid var(--orange); border-radius: 16px; padding: 40px; text-align: center; }
.paywall-card h2 { font-size: 20px; margin-bottom: 8px; }
.paywall-card p { color: var(--muted); margin-bottom: 24px; }

/* recent scans */
.recent-block { margin-top: 48px; }
.recent-block h2 { font-size: 20px; text-align: left; margin-bottom: 4px; }
.recent-block p { font-size: 14.5px; color: var(--muted); margin-bottom: 12px; }
.recent-list { list-style: none; }
.recent-list li { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; margin-bottom: 8px; }
.recent-list a { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 18px; font-size: 14.5px; }
.recent-list .r-url { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recent-list .r-meta { font-size: 12.5px; color: var(--muted); flex: none; }

/* tokens page */
.tokens-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 40px; max-width: 720px; margin: 0 auto; text-align: center; }
.tokens-card .big { font-size: 54px; font-weight: 800; color: var(--teal); }
.pack-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 28px; }
.pack { border: 2px solid var(--border); border-radius: 12px; padding: 22px 14px; }
.pack .t { font-weight: 700; color: var(--teal); }
.pack .p { font-size: 30px; font-weight: 800; margin: 6px 0 12px; }
.pack-zone { min-height: 212px; }
@media (max-width: 720px) { .pack-zone { min-height: 0; } }

@media (max-width: 720px) {
  .pack-row { grid-template-columns: 1fr; }
}

/* two-section report layout */
.rep-section { margin-bottom: 8px; }
.rep-section-head { display: flex; gap: 14px; align-items: flex-start; margin: 36px 0 20px; }
.rep-section-num { flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--teal); color: #fff;
  font-size: 20px; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.rep-section-head h2 { font-size: 20px; margin: 0 0 4px; }
.rep-section-head p { font-size: 14.5px; color: var(--muted); margin: 0; }

/* platform note + estimated score in hero */
.platform-note { font-size: 14.5px; color: var(--muted); margin-top: 14px; }
.est-line { font-size: 14.5px; margin-top: 6px; }

/* crawler matrix chips */
.mx-chip { display: inline-block; font-size: 12.5px; font-weight: 700; border-radius: 20px; padding: 3px 12px; }
.mx-ok { background: #e3f2e8; color: var(--green); }
.mx-bad { background: #fbe3e3; color: var(--red); }
.mx-warn { background: #fdf0dd; color: var(--amber); }
.mx-mut { background: #eef1f3; color: var(--muted); }

/* rescan policy line */
.rescan-policy { font-size: 13px; color: var(--muted); text-align: center; width: 100%; margin: 8px 0 0; }

@media (max-width: 720px) {
  .rep-section-head h2 { font-size: 20px; }
}

/* agency white-label */
.wl-masthead { display: flex; align-items: center; gap: 18px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 16px; padding: 20px 24px; margin-bottom: 14px; }
@media print {
  .wl-masthead { break-inside: avoid; }
}

/* checkout */
.test-banner { background: #fff8e6; border: 2px solid #e8a13c; color: #7a4d0f; border-radius: 12px; padding: 14px 18px; font-size: 14.5px; margin-bottom: 20px; }
.co-steps { list-style: none; display: flex; gap: 8px; margin: 0 0 28px; padding: 0; }
.co-steps li { display: flex; align-items: center; gap: 8px; font-size: 14.5px; color: var(--muted); font-weight: 600; }
.co-steps li span { width: 26px; height: 26px; border-radius: 50%; background: var(--border); color: var(--muted); display: inline-flex; align-items: center; justify-content: center; font-size: 13px; }
.co-steps li.on { color: var(--ink); }
.co-steps li.on span { background: var(--teal); color: #fff; }
.co-grid { display: grid; grid-template-columns: 1fr 340px; gap: 28px; align-items: start; }
.co-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 8px 24px 24px; margin-bottom: 20px; }
.co-card h2 { font-size: 20px; margin: 16px 0 4px; }
.co-row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.co-row2 .field-input { max-width: none; }
.co-card .field-input { max-width: none; }
.co-hint { font-size: 13px; color: var(--muted); margin-top: 14px; }
.field-err { color: var(--red, var(--red)); font-size: 13px; margin-top: 6px; }
.field-err.ok { color: #2e7d6f; }
.co-coupon-row { display: flex; gap: 10px; padding-bottom: 6px; }
.co-coupon-row .field-input { flex: 1; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.co-error { color: var(--red, var(--red)); font-size: 14.5px; font-weight: 600; margin: 4px 0 12px; }
.co-secure { text-align: center; font-size: 13px; color: var(--muted); margin-top: 12px; display: flex; align-items: center; justify-content: center; gap: 6px; }
.co-summary { position: sticky; top: 24px; }
.co-sum-mobile { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; }
.co-sum-mobile summary { list-style: none; cursor: pointer; padding: 18px 20px; display: flex; justify-content: space-between; align-items: center; font-weight: 700; }
.co-sum-mobile summary::-webkit-details-marker { display: none; }
.co-sum-body { padding: 0 20px 20px; border-top: 1px solid var(--border); }
.sum-line { display: flex; justify-content: space-between; gap: 12px; font-size: 14.5px; padding: 10px 0; }
.sum-line.total { border-top: 1px solid var(--border); margin-top: 6px; padding-top: 14px; font-weight: 800; font-size: 17px; }
.sum-line .disc { color: #2e7d6f; }
.sum-note { font-size: 13px; color: var(--muted); margin-top: 10px; }
@media (max-width: 900px) {
  .co-grid { grid-template-columns: 1fr; }
  .co-summary { position: static; order: -1; }
  .co-row2 { grid-template-columns: 1fr; }
}

/* monitoring */
.mon-plan { background: var(--surface); border: 2px solid var(--teal); border-radius: 14px; padding: 28px; display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; margin-bottom: 24px; }
.mon-price { font-size: 42px; font-weight: 800; color: var(--teal); }
.mon-price span { font-size: 16px; font-weight: 600; color: var(--muted); }
.mon-label { font-size: 14.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); margin: 0 0 12px; }

/* Report warnings (heads-up) section */
.warn-list { list-style: none; margin: 0 0 28px; padding: 0; }
.warn-item {
  background: #fffdf5; border: 1px solid #f0dfae; border-left: 4px solid #d9a521;
  border-radius: 8px; padding: 12px 16px; margin-bottom: 10px;
  font-size: 14.5px; line-height: 1.55; color: var(--ink);
}
.warn-badge {
  display: inline-block; background: #fdf0dd; color: var(--amber);
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px;
  padding: 2px 8px; border-radius: 4px; margin-right: 8px;
}

/* Icon-only buttons (copy/download for file builders) */

/* PDF Background Queue (2026-10-11): muted note shown while PDF generates. */
.pdf-pending-note {
  display: inline-block;
  font-size: 13px;
  color: #6b7a81;
  font-style: italic;
  padding: 8px 12px;
  background: #f3f5f6;
  border-radius: 8px;
  margin-left: 8px;
  vertical-align: middle;
}

/* Report UI improvements (2026-10-11): executive summary, findings cards, radar chart. */
.exec-summary { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 24px; margin: 24px 0; }
.exec-kicker { font-size: 12px; text-transform: uppercase; letter-spacing: 1px; color: var(--muted); margin: 0 0 8px; }
.exec-summary h3 { font-size: 20px; margin: 0 0 8px; }
.exec-desc { color: var(--muted); font-size: 13px; margin: 0 0 16px; }
/* Monitoring-report elements (2026-10-14): next best action, what changed, streak. */
.next-action { margin: 0 0 24px; }
.na-head { display: flex; justify-content: space-between; align-items: center; }
.na-head h3 { margin: 0; }
.na-title { font-weight: 600; margin: 10px 0 4px; }
.na-why { color: var(--muted); font-size: 14.5px; margin: 0 0 12px; }
.chg-row { display: flex; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--border); }
.chg-row:last-of-type { border-bottom: 0; }
.chg-row .rep-bad-b, .chg-row .rep-good-b { flex: 0 0 62px; font-weight: 600; font-size: 13px; }
.chg-none { color: var(--muted); margin: 0; }
.chg-when { color: var(--muted); font-size: 13px; margin: 10px 0 0; }
.chg-more { color: var(--muted); font-size: 13px; margin: 4px 0 0; }
.streak-chip { display: inline-block; font-size: 12px; font-weight: 600; color: var(--teal); background: var(--bg-soft); border: 1px solid var(--border); border-radius: 999px; padding: 2px 10px; margin-left: 10px; vertical-align: middle; }
.exec-cards { display: flex; gap: 12px; flex-wrap: wrap; }
.exec-card { flex: 1; min-width: 120px; background: #f8f9fa; border-radius: 10px; padding: 16px; text-align: center; }
.exec-num { font-size: 30px; font-weight: 800; }
.exec-label { font-size: 12px; color: var(--muted); margin-top: 4px; }

.findings-summary { margin: 24px 0; }
.findings-summary h3 { font-size: 20px; margin: 0 0 4px; }
.fs-cards { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 12px; }
.fs-card { flex: 1; min-width: 100px; border-radius: 10px; padding: 16px; text-align: center; }
.fs-critical { background: var(--err-bg); border: 1px solid var(--err-line); }
.fs-warning { background: var(--warn-bg); border: 1px solid var(--warn-line); }
.fs-info { background: var(--green-bg); border: 1px solid #bfe3c9; }
.fs-num { font-size: 30px; font-weight: 800; }
.fs-critical .fs-num { color: var(--red); }
.fs-warning .fs-num { color: #e8930c; }
.fs-info .fs-num { color: var(--green); }
.fs-label { font-size: 12px; color: var(--muted); margin-top: 4px; text-transform: uppercase; letter-spacing: 0.5px; }


/* (Sticky footer now lives in components/shared.css, single-source for all properties.) */

/* Ensure footer is full-width */
.site-footer { width: 100%; }

/* ---- Tabbed report layout (2026-10-13, Kuang-approved design) ---- */
.rep-meta{font-size:13px;color:var(--muted);margin:4px 0 12px;}
.rep-stat-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:14px;margin-bottom:14px;}
@media (max-width: 640px) { .rep-stat-cards{grid-template-columns:1fr 1fr;} }
.rep-stat{background: var(--surface);border:1px solid var(--line,var(--line));border-radius:12px;padding:14px 15px;display:flex;flex-direction:column;}
.rep-stat-lab{font-size:11px;font-weight:700;letter-spacing:.7px;color:var(--muted);text-transform:uppercase;line-height:1.35;min-height:30px;display:flex;justify-content:space-between;align-items:flex-start;gap:8px;}
.rep-stat-big{font-size: 30px;font-weight:800;margin:5px 0 2px;}
.rep-stat-big small{font-size: 14.5px;color:var(--muted);font-weight:600;}
.rep-stat-sub{font-size:12.5px;color:var(--muted);line-height:1.45;}
.rep-chip{display:inline-block;background:#e7f0f3;color:var(--teal);font-size:11.5px;font-weight:700;padding:2px 8px;border-radius:20px;margin-top:6px;}
/* Stat-card explanations: info-icon tooltip (screen) / inline line (print).
   Cards stay clean — label + big number only (Kuang, 2026-10-14). */
#report-root .rep-stat-lab{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;}
.rep-tip{position:relative;display:inline-flex;flex:none;color:var(--muted);cursor:help;outline:none;}
.rep-tip::after{content:attr(data-tip);position:absolute;right:-4px;top:calc(100% + 8px);width:max-content;max-width:min(230px,calc(100vw - 32px));background:#1a2b33;color:#fff;font-size:12px;font-weight:500;line-height:1.45;letter-spacing:0;text-transform:none;text-align:left;white-space:normal;padding:8px 10px;border-radius:8px;opacity:0;pointer-events:none;transition:opacity .15s ease;z-index:40;box-shadow:0 8px 24px rgba(16,42,54,.25);}
.rep-tip:hover::after,.rep-tip:focus::after,.rep-tip:focus-visible::after{opacity:1;}
.rep-tip:hover,.rep-tip:focus-visible{color:var(--ink);}
.rep-tip:focus-visible{outline:2px solid var(--teal);outline-offset:2px;border-radius:50%;}
/* dark theme: the dark bubble vanished into the dark card (1.14:1) — invert it */
:root[data-theme="dark"] body:not(.pg-report) .rep-tip::after{background:#e9f1f3;color:#0b181e;box-shadow:0 8px 24px rgba(0,0,0,.5);}
.rep-parity{margin-top:auto;padding-top:9px;display:grid;gap:5px;}
.rep-parity-row{display:flex;align-items:center;gap:8px;font-size:11px;color:var(--muted);}
.rep-parity-row .pl{width:46px;flex:none;}
.rep-parity-row .pv{width:32px;flex:none;text-align:right;font-weight:700;color:var(--ink);}
.rep-parity-track{flex:1;height:6px;background:var(--bg-soft);border-radius:4px;overflow:hidden;}
.rep-parity-fill{height:100%;width:var(--w,0%);background:var(--teal);border-radius:4px;}
.rep-parity-fill.gray{background:#b9c6cc;}
.rep-tabs{display:flex;gap:2px;border-bottom:2px solid var(--line,var(--line));margin:10px 0 18px;flex-wrap:wrap;}
.rep-tab{background:none;border:0;font:inherit;font-size:14.5px;font-weight:600;color:var(--muted);padding:10px 16px;cursor:pointer;border-bottom:3px solid transparent;margin-bottom:-2px;}
.rep-tab.active{color:var(--teal);border-bottom-color:var(--orange,var(--orange));}
.rep-tab-cnt{background:#e7f0f3;border-radius:12px;padding:0 7px;font-size:12px;}
.rep-panel{display:none;}
.rep-panel.active{display:block;}
.rep-soon{border:1.5px dashed #b9cdd5;border-radius:12px;padding:26px;text-align:center;background:#fbfdfd;}
.rep-soon p{color:var(--muted);font-size: 14.5px;line-height:1.6;max-width:600px;margin:8px auto 0;}
.rep-ghost{opacity:.4;margin:18px auto 0;text-align:left;border-collapse:collapse;font-size: 13px;}
.rep-ghost th,.rep-ghost td{padding:7px 12px;border-bottom:1px solid var(--line,var(--line));}
.rep-statusbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;background: var(--surface);border:1px solid var(--line,var(--line));border-radius:10px;padding:9px 14px;font-size:13px;color:var(--muted);margin-bottom:14px;}
.rep-statusbar span + span{border-left:1px solid var(--line,var(--line));padding-left:10px;}
.rep-status-host{font-weight:800;color:var(--teal);font-size: 14.5px;}
.rep-status-mon{margin-left:auto;border-left:0 !important;font-style:italic;}

/* ---------- Admin standardization (2026-10-14: inline styles moved here) ---------- */
.page-h1 { font-size: 30px; margin-bottom: 6px; }
.u-none { display: none; }
.st-ok { color: var(--ok); }
.st-ok-b { color: var(--ok); font-weight: 700; }
.st-bad { color: var(--red); font-weight: 600; }
.st-bad-b { color: var(--red); font-weight: 700; }
.st-warn-b { color: var(--amber); font-weight: 700; }
.st-home-b { color: var(--teal-2); font-weight: 700; }
.u-minw-200 { min-width: 200px; }
.u-minw-220 { min-width: 220px; }
.u-minw-280 { min-width: 280px; }
.u-minw-700 { min-width: 700px; }
.u-minw-800 { min-width: 800px; }
.u-mr-6 { margin-right: 6px; }
.u-ml-8 { margin-left: 8px; }
.u-ml-10 { margin-left: 10px; }
.u-ml-12 { margin-left: 12px; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 16px; }
.u-note { font-size: 12px; color: var(--muted); }
.u-note-125 { font-size: 12.5px; color: var(--muted); margin: 0 0 10px; }
.u-sub-sm { font-weight: 400; font-size: 0.8em; color: var(--muted); }
.u-note-div { font-size: 11px; color: var(--muted); font-weight: 400; }
.u-w400 { max-width: 400px; }
.u-fw4 { font-weight: 400; }
.u-fs13 { font-size: 13px; }
.u-note-m { font-size: 12px; color: var(--muted); margin: 10px 0 0; }
.admin-denied { padding: 40px; max-width: 720px; margin: 0 auto; }
.u-cell-wrap { max-width: 280px; word-break: break-word; }
.row-actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; min-width: 230px; }


/* ================= Page styles moved from inline <style> blocks (2026-10-14) ================= */
/* ===== schema-wizard (moved from page, scoped body.pg-wizard) ===== */
body.pg-wizard .tool-grid {display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start;}
@media (max-width: 860px) {
body.pg-wizard .tool-grid {grid-template-columns: 1fr;}
}
body.pg-wizard .tool-form .field, body.pg-schemaval .tool-form .field, body.pg-robotsval .tool-form .field, body.pg-llmsgen .tool-form .field, body.pg-robotsgen .tool-form .field {margin-bottom: 18px;}
body.pg-wizard .tool-form label.flabel, body.pg-schemaval .tool-form label.flabel, body.pg-robotsval .tool-form label.flabel, body.pg-llmsgen .tool-form label.flabel, body.pg-robotsgen .tool-form label.flabel {display: block; font-weight: 600; font-size: 14.5px; margin-bottom: 6px;}
body.pg-wizard .tool-form .hint, body.pg-schemaval .tool-form .hint, body.pg-robotsval .tool-form .hint, body.pg-llmsgen .tool-form .hint, body.pg-robotsgen .tool-form .hint {font-size: 13px; color: var(--muted); margin-top: 5px; line-height: 1.5;}
body.pg-wizard .tool-form input[type="text"], body.pg-wizard .tool-form input[type="url"], body.pg-wizard .tool-form input[type="tel"], body.pg-wizard .tool-form textarea, body.pg-wizard .tool-form select {width: 100%;}
body.pg-wizard .tool-form textarea {min-height: 80px; resize: vertical;}
body.pg-wizard .type-tabs {display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px;}
body.pg-wizard .schema-fields {display: none;}
body.pg-wizard .schema-fields.active {display: block;}
body.pg-wizard .faq-item, body.pg-wizard .offer-item {border: 1px solid var(--border); border-radius: 10px; padding: 14px; margin-bottom: 10px; background: var(--surface); position: relative;}
body.pg-wizard .rm-item {position: absolute; right: 8px; top: 8px; width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--border); background: var(--surface); color: var(--muted); cursor: pointer; font-size: 16px; line-height: 1;}
body.pg-wizard .output-pane, body.pg-schemaval .output-pane, body.pg-robotsval .output-pane, body.pg-llmsgen .output-pane, body.pg-robotsgen .output-pane {position: sticky; top: 90px;}
body.pg-wizard .output-pane pre {background: var(--teal-ink); color: var(--teal-bg); border-radius: 14px; padding: 20px;
  font-size: 14.5px; line-height: 1.65; overflow-x: auto; min-height: 380px; max-height: 600px; overflow-y: auto;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre-wrap; word-break: break-all;}
body.pg-wizard .output-actions {display: flex; gap: 10px; margin: 12px 0 26px; flex-wrap: wrap;}
body.pg-wizard .out-label, body.pg-schemaval .out-label, body.pg-robotsval .out-label, body.pg-llmsgen .out-label, body.pg-robotsgen .out-label {display: block; font-weight: 600; font-size: 14.5px; margin-bottom: 6px;}
body.pg-wizard .steps-list, body.pg-schemaval .steps-list, body.pg-robotsval .steps-list, body.pg-llmsgen .steps-list, body.pg-robotsgen .steps-list {counter-reset: step; list-style: none; padding: 0; margin: 20px 0 0;}
body.pg-wizard .steps-list li, body.pg-schemaval .steps-list li, body.pg-robotsval .steps-list li, body.pg-llmsgen .steps-list li, body.pg-robotsgen .steps-list li {counter-increment: step; padding: 14px 0 14px 52px; position: relative; font-size: 13px; line-height: 1.6; border-bottom: 1px solid var(--border);}
body.pg-wizard .steps-list li::before, body.pg-schemaval .steps-list li::before, body.pg-robotsval .steps-list li::before, body.pg-llmsgen .steps-list li::before, body.pg-robotsgen .steps-list li::before {content: counter(step); position: absolute; left: 0; top: 14px; width: 34px; height: 34px; border-radius: 50%; background: var(--teal); color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center;}
body.pg-wizard .steps-list li:last-child, body.pg-schemaval .steps-list li:last-child, body.pg-robotsval .steps-list li:last-child, body.pg-llmsgen .steps-list li:last-child, body.pg-robotsgen .steps-list li:last-child {border-bottom: none;}
body.pg-wizard .webperson-box, body.pg-schemaval .webperson-box, body.pg-robotsval .webperson-box, body.pg-llmsgen .webperson-box, body.pg-robotsgen .webperson-box {background: var(--surface); border: 1.5px dashed var(--teal); border-radius: 12px; padding: 18px; font-size: 14.5px; line-height: 1.65; margin-top: 16px;}
body.pg-wizard code.inline {background: var(--bg-soft); padding: 2px 6px; border-radius: 4px; font-size: 13px;}

/* ===== schema-validator (moved from page, scoped body.pg-schemaval) ===== */
body.pg-schemaval .tool-form input[type="text"], body.pg-schemaval .tool-form textarea {width: 100%;}
body.pg-schemaval .tool-form textarea {min-height: 160px; resize: vertical; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;}
body.pg-wizard .field-tip, body.pg-schemaval .field-tip, body.pg-robotsval .field-tip, body.pg-llmsgen .field-tip, body.pg-robotsgen .field-tip {position: relative; display: flex; align-items: center;}
body.pg-wizard .field-tip input, body.pg-schemaval .field-tip input, body.pg-robotsval .field-tip input, body.pg-llmsgen .field-tip input, body.pg-robotsgen .field-tip input {flex: 1; padding-right: 36px;}
body.pg-wizard .tip-icon, body.pg-schemaval .tip-icon, body.pg-robotsval .tip-icon, body.pg-llmsgen .tip-icon, body.pg-robotsgen .tip-icon {position: absolute; right: 10px; width: 20px; height: 20px; border-radius: 50%; background: var(--bg-soft); color: var(--muted); font-size: 12px; font-weight: 700; display: flex; align-items: center; justify-content: center; cursor: help; flex-shrink: 0;}
body.pg-wizard .tip-icon:hover, body.pg-schemaval .tip-icon:hover, body.pg-robotsval .tip-icon:hover, body.pg-llmsgen .tip-icon:hover, body.pg-robotsgen .tip-icon:hover {background: var(--teal, var(--teal-2)); color: #fff;}
body.pg-schemaval .schema-block {border: 1px solid var(--border); border-radius: 14px; padding: 18px; margin-bottom: 16px; background: var(--surface);}
body.pg-schemaval .schema-block h3 {margin: 0 0 4px; font-size: 17px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap;}
body.pg-schemaval .schema-block .block-sub {font-size: 13px; color: var(--muted); margin-bottom: 10px;}
body.pg-schemaval .badge {display: inline-block; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 20px;}
body.pg-schemaval .badge-ok {background: var(--ok-bg); color: var(--ok);}
body.pg-schemaval .badge-warn {background: var(--warn-bg); color: #8a6d00;}
body.pg-schemaval .badge-err {background: var(--err-bg); color: var(--red);}
body.pg-schemaval .issue {display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; border-top: 1px solid var(--border); font-size: 14.5px; line-height: 1.55;}
body.pg-schemaval .issue:first-of-type {border-top: none;}
body.pg-schemaval .issue .dot {width: 10px; height: 10px; border-radius: 50%; margin-top: 6px; flex-shrink: 0;}
body.pg-schemaval .dot-err {background: var(--red);}
body.pg-schemaval .dot-warn {background: #e8930c;}
body.pg-schemaval .dot-info {background: #1976d2;}
body.pg-schemaval .issue .fix {display: block; color: var(--muted); font-size: 13px; margin-top: 3px;}
body.pg-schemaval .issue .fix code {background: var(--bg-soft); padding: 1px 6px; border-radius: 5px; font-size: 12.5px;}
body.pg-schemaval details.raw-json {margin-top: 10px;}
body.pg-schemaval details.raw-json summary {cursor: pointer; font-size: 13px; color: var(--teal); font-weight: 600;}
body.pg-schemaval details.raw-json pre {background: var(--teal-ink); color: var(--teal-bg); border-radius: 10px; padding: 14px; font-size: 12.5px; line-height: 1.6; overflow-x: auto; max-height: 300px; overflow-y: auto; white-space: pre-wrap; word-break: break-all; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;}
body.pg-schemaval .summary-counts {display: flex; gap: 12px; flex-wrap: wrap; margin: 16px 0;}
body.pg-schemaval .count-card {border: 1px solid var(--border); border-radius: 10px; padding: 12px 18px; background: var(--surface); text-align: center; min-width: 110px;}
body.pg-schemaval .count-card .num {font-size: 30px; font-weight: 800;}
body.pg-schemaval .count-card .lbl {font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.5px;}

/* ===== robots-validator (moved from page, scoped body.pg-robotsval) ===== */
body.pg-robotsval .tool-grid {display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start;}
@media (max-width: 860px) {
body.pg-robotsval .tool-grid {grid-template-columns: 1fr;}
}
body.pg-robotsval .tool-form input[type="text"], body.pg-robotsval .tool-form textarea {width: 100%;}
body.pg-robotsval .tool-form textarea {min-height: 180px; resize: vertical; font-family: ui-monospace, monospace;}
body.pg-robotsval .mode-toggle {display: flex; gap: 8px; margin-bottom: 16px;}
body.pg-robotsval .mode-toggle button {flex: 1; padding: 10px; border: 1.5px solid var(--border); border-radius: 10px; background: var(--surface); font-size: 14.5px; font-weight: 600; cursor: pointer; color: var(--ink);}
body.pg-robotsval .mode-toggle button.active {border-color: var(--teal); background: var(--bg-soft); color: var(--teal-ink);}
body.pg-robotsval .stat-row {display: flex; gap: 10px; margin-bottom: 16px; flex-wrap: wrap;}
body.pg-robotsval .stat-chip {flex: 1; min-width: 90px; border: 1px solid var(--border); border-radius: 10px; padding: 10px; text-align: center; background: var(--surface);}
body.pg-robotsval .stat-chip .num {font-size: 20px; font-weight: 800;}
body.pg-robotsval .stat-chip .lbl {font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.5px;}
body.pg-robotsval .line-table-wrap {overflow-x: auto; margin-bottom: 18px;}
body.pg-robotsval table.line-table {width: 100%; border-collapse: collapse; font-size: 14.5px; min-width: 560px;}
body.pg-robotsval table.line-table th {text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--muted); padding: 8px 10px; border-bottom: 2px solid var(--border);}
body.pg-robotsval table.line-table td {padding: 9px 10px; border-bottom: 1px solid var(--border); vertical-align: top;}
body.pg-robotsval table.line-table td.ln {font-family: ui-monospace, monospace; color: var(--muted); width: 40px;}
body.pg-robotsval table.line-table td.rule {font-family: ui-monospace, monospace; font-size: 13px; word-break: break-all;}
body.pg-robotsval .badge {display: inline-block; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; white-space: nowrap;}
body.pg-robotsval .badge-ok {background: var(--green-bg); color: var(--ok-dark);}
body.pg-robotsval .badge-warn {background: #fff3d6; color: #6b4a12;}
body.pg-robotsval .badge-err {background: var(--err-bg); color: #7a1f16;}
body.pg-robotsval .badge-info {background: #e3f2fd; color: #1a4f7a;}
body.pg-robotsval .line-explain {font-size: 13px; color: var(--muted); margin-top: 4px; line-height: 1.5;}
body.pg-robotsval .output-pane pre {background: var(--teal-ink); color: var(--teal-bg); border-radius: 14px; padding: 20px;
  font-size: 14.5px; line-height: 1.65; overflow-x: auto; min-height: 280px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre-wrap; word-break: break-all;}
body.pg-robotsval .output-actions {display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap;}
body.pg-robotsval .check-cards {display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; margin-top: 18px;}
body.pg-robotsval .check-card {border: 1px solid var(--border); border-radius: 12px; padding: 16px; background: var(--surface);}
body.pg-robotsval .check-card h3 {font-size: 17px; font-weight: 800; margin: 0 0 6px;}
body.pg-robotsval .check-card p {font-size: 13px; color: var(--muted); margin: 0; line-height: 1.55;}
body.pg-robotsval .form-msg {font-size: 14.5px;}

/* ===== llms-txt-generator (moved from page, scoped body.pg-llmsgen) ===== */
body.pg-llmsgen .tool-grid {display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start;}
@media (max-width: 860px) {
body.pg-llmsgen .tool-grid {grid-template-columns: 1fr;}
}
body.pg-llmsgen .tool-form input[type="text"], body.pg-llmsgen .tool-form textarea {width: 100%;}
body.pg-llmsgen .tool-form textarea {min-height: 96px; resize: vertical;}
body.pg-llmsgen .section-card {border: 1px solid var(--border); border-radius: 14px; padding: 16px; margin-bottom: 14px; background: var(--surface);}
body.pg-llmsgen .section-card h3 {font-size: 14.5px; margin: 0 0 10px; display: flex; justify-content: space-between; align-items: center;}
body.pg-llmsgen .link-row {display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px;}
body.pg-llmsgen .link-row input {width: 100%;}
body.pg-llmsgen .link-row .link-desc {width: 100%;}
body.pg-llmsgen .link-row-wrap {position: relative;}
body.pg-llmsgen .rm-link {position: absolute; right: -6px; top: -8px; width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--border); background: var(--surface); color: var(--muted); cursor: pointer; font-size: 14.5px; line-height: 1;}
body.pg-llmsgen .rm-link:hover {color: var(--red); border-color: var(--red);}
body.pg-llmsgen .check-row {display: flex; gap: 10px; align-items: flex-start; background: var(--bg-soft); border-radius: 10px; padding: 12px 14px; margin: 18px 0;}
body.pg-llmsgen .check-row input {margin-top: 3px; width: 18px; height: 18px; accent-color: var(--teal);}
body.pg-llmsgen .check-row .hint {margin-top: 2px;}
body.pg-llmsgen .output-pane pre {background: var(--teal-ink); color: var(--teal-bg); border-radius: 14px; padding: 20px;
  font-size: 14.5px; line-height: 1.65; overflow-x: auto; min-height: 320px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre-wrap; word-break: break-all;}
body.pg-llmsgen .output-actions {display: flex; gap: 10px; margin: 12px 0 26px; flex-wrap: wrap;}
body.pg-llmsgen .out-label .fname {font-family: ui-monospace, monospace; font-weight: 700; color: var(--teal);}

/* ===== robots-txt-generator (moved from page, scoped body.pg-robotsgen) ===== */
body.pg-robotsgen .tool-grid {display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start;}
@media (max-width: 860px) {
body.pg-robotsgen .tool-grid {grid-template-columns: 1fr;}
}
body.pg-robotsgen .tool-form label {display: block; font-weight: 600; font-size: 14.5px; margin-bottom: 6px;}
body.pg-robotsgen .tool-form input[type="text"], body.pg-robotsgen .tool-form input[type="number"], body.pg-robotsgen .tool-form textarea {width: 100%;}
body.pg-robotsgen .tool-form textarea {min-height: 90px; resize: vertical; font-family: ui-monospace, monospace;}
body.pg-robotsgen .bot-row {display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 10px; margin-bottom: 8px; background: var(--surface);}
body.pg-robotsgen .bot-row > div:first-child {flex: 1; min-width: 0;}
body.pg-robotsgen .bot-row .bot-name {font-weight: 600; font-size: 14.5px; font-family: ui-monospace, monospace;}
body.pg-robotsgen .bot-row .bot-who {font-size: 13px; color: var(--muted);}
body.pg-robotsgen .bot-row .bot-opts {flex-shrink: 0;}
body.pg-robotsgen .bot-opts {display: flex; gap: 4px;}
body.pg-robotsgen .bot-opts label {font-size: 13px; font-weight: 500; padding: 6px 10px; border-radius: 999px; cursor: pointer; border: 1px solid transparent; margin: 0;}
body.pg-robotsgen .bot-opts input {position: absolute; opacity: 0; pointer-events: none; width: auto; padding: 0; border: none;}
body.pg-robotsgen .bot-opts input:checked + span {font-weight: 700;}
body.pg-robotsgen .bot-opts .opt-allow input:checked + span {color: var(--green);}
body.pg-robotsgen .bot-opts .opt-block input:checked + span {color: var(--red);}
body.pg-robotsgen .bot-opts label:has(input:checked) {border-color: var(--border); background: var(--bg-soft);}
body.pg-robotsgen .output-pane pre {background: var(--teal-ink); color: var(--teal-bg); border-radius: 14px; padding: 20px;
  font-size: 14.5px; line-height: 1.65; overflow-x: auto; min-height: 320px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre-wrap; word-break: break-all;}
body.pg-robotsgen .output-actions {display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap;}
body.pg-robotsgen .warn-box {border-radius: 12px; padding: 14px 16px; font-size: 14.5px; line-height: 1.55; margin-top: 14px;}
body.pg-robotsgen .warn-red {background: var(--red-bg); border: 1.5px solid var(--red); color: #7a1f16;}
body.pg-robotsgen .warn-amber {background: var(--amber-bg); border: 1.5px solid var(--amber); color: #6b4a12;}
body.pg-robotsgen .warn-ok {background: var(--green-bg); border: 1.5px solid var(--green); color: var(--ok-dark);}

/* ===== parity-check (moved from page, scoped body.pg-parity) ===== */
body.pg-parity .parity-grid {display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 24px;}
@media (max-width: 860px) {
body.pg-parity .parity-grid {grid-template-columns: 1fr;}
}
body.pg-parity .parity-pane {border: 1px solid var(--border); border-radius: 14px; padding: 20px; background: var(--surface);}
body.pg-parity .parity-pane h3 {margin: 0 0 12px; font-size: 20px;}
body.pg-parity .parity-pane .word-count {font-size: 30px; font-weight: 800; margin: 8px 0;}
body.pg-parity .parity-pane .word-label {font-size: 13px; color: var(--muted);}
body.pg-parity .parity-text {background: var(--bg-soft); border-radius: 8px; padding: 16px; font-size: 14.5px; line-height: 1.6; max-height: 400px; overflow-y: auto; margin-top: 12px; white-space: pre-wrap;}

/* ===== settings (moved from page, scoped body.pg-settings) ===== */
body.pg-settings .chips-list {display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;}
body.pg-settings .chips-list:empty {display: none;}
body.pg-settings .chip {display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #E8F2EF;
  color: #173F3A;
  border-radius: 20px;
  padding: 8px 8px 8px 16px;
  font-size: 14.5px;
  font-weight: 600;
  max-width: 100%;}
body.pg-settings .chip span {overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 260px;}
body.pg-settings .chip button {background: none;
  border: none;
  color: #5b6b68;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 50%;
  display: flex;
  align-items: center;}
body.pg-settings .chip button:hover {background: rgba(23,63,58,.12);
  color: #173F3A;}

/* ===== papers (moved from page, scoped body.pg-papers) ===== */
body.pg-papers .side-sub-link.active {background: var(--teal); color: #fff; border-radius: 8px;}
body.pg-papers .masthead {display: flex; align-items: center; justify-content: space-between; gap: 24px; border-bottom: 3px solid var(--teal); padding-bottom: 22px;}
body.pg-papers .masthead .logo-slot img, body.pg-agencyrep .masthead .logo-slot img {max-height: 64px; max-width: 260px; object-fit: contain;}
body.pg-papers .masthead .logo-slot .placeholder-logo, body.pg-agencyrep .masthead .logo-slot .placeholder-logo {font-size: 14.5px; font-weight: 800; color: var(--teal); border: 2px dashed #b9cdd6; border-radius: 10px; padding: 14px 20px; display: inline-block;}
body.pg-papers .masthead .who, body.pg-agencyrep .masthead .who {text-align: right;}
body.pg-papers .masthead .aname {font-size: 20px; font-weight: 800; color: var(--teal);}
body.pg-papers .masthead .aaddr {font-size: 14.5px; color: var(--ink-2); margin-top: 3px; white-space: pre-line;}
body.pg-papers .doc-sheet {display: none; max-width: 820px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 40px rgba(30,95,123,.10); padding: 60px 68px 48px; margin: 28px 0 36px; color: var(--doc-ink);}
body.pg-papers .doc-sheet.active {display: block;}
body.pg-papers .doc-sheet .kicker, body.pg-agencyrep .doc-sheet .kicker {display: inline-block; font-size: 12.5px; font-weight: 800; letter-spacing: 1.6px; text-transform: uppercase; color: var(--orange); margin: 30px 0 10px;}
body.pg-papers .doc-sheet h2.doc-title, body.pg-agencyrep .doc-sheet h2.doc-title {font-size: 36px; line-height: 1.15; letter-spacing: -0.8px; color: var(--doc-ink); margin: 0 0 10px;}
body.pg-papers .doc-sheet .doc-sub {font-size: 16px; color: var(--ink-2); line-height: 1.55; margin: 0 0 26px;}
body.pg-papers .doc-sheet h3.sec-title {font-size: 20px; color: var(--teal); letter-spacing: -0.4px; margin: 28px 0 6px;}
body.pg-papers .doc-sheet .sec-sub {font-size: 14.5px; color: var(--ink-2); margin: 0 0 20px; line-height: 1.55;}
body.pg-papers .doc-sheet p.body {font-size: 14.5px; line-height: 1.65; color: var(--ink-3); margin: 0 0 14px;}
body.pg-papers .stat-grid {display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin: 6px 0 8px;}
body.pg-papers .stat-card, body.pg-agencyrep .stat-card {border: 1px solid var(--line-2); border-radius: 12px; padding: 22px 24px; background: var(--surface-2);}
body.pg-papers .stat-card .num, body.pg-agencyrep .stat-card .num {font-size: 44px; font-weight: 800; color: var(--teal); line-height: 1; letter-spacing: -1px;}
body.pg-papers .stat-card .num .unit, body.pg-agencyrep .stat-card .num .unit {font-size: 20px; color: var(--orange); font-weight: 800;}
body.pg-papers .stat-card .lbl, body.pg-agencyrep .stat-card .lbl {font-size: 14.5px; color: var(--ink-2); margin-top: 8px; line-height: 1.45;}
body.pg-papers .method {font-size: 12.5px; color: var(--muted-2); line-height: 1.55; margin-top: 26px; border-top: 1px solid var(--line-2); padding-top: 14px;}
body.pg-papers .cta-block {background: var(--teal); color: #fff; border-radius: 14px; padding: 26px 30px; margin-top: 30px; display: flex; gap: 20px; align-items: center;}
body.pg-papers .cta-block .cta-t {font-size: 16px; line-height: 1.55;}
body.pg-papers .cta-block .cta-t strong {color: #ffd9a8;}
body.pg-papers .chart-row {display: flex; gap: 28px; flex-wrap: wrap; align-items: center; margin: 10px 0 6px;}
body.pg-papers .donut-box {text-align: center;}
body.pg-papers .donut-box .d-lbl {font-size: 13px; color: var(--ink-2); margin-top: 6px; max-width: 170px; line-height: 1.4;}
body.pg-papers .donut-box .d-num {font-size: 30px; font-weight: 800; fill: var(--teal);}
body.pg-papers .gauge-row {display: flex; gap: 14px; flex-wrap: wrap; margin: 8px 0 4px;}
body.pg-papers .gauge {flex: 1 1 120px; text-align: center; border: 1px solid var(--line-2); border-radius: 12px; padding: 16px 8px 12px; background: var(--surface-2);}
body.pg-papers .gauge .g-name {font-size: 13px; font-weight: 700; color: var(--ink-3); margin-top: 4px;}
body.pg-papers .gauge .g-note {font-size: 12px; color: var(--muted-2); line-height: 1.4; margin-top: 3px;}
body.pg-papers .waffle {display: grid; grid-template-columns: repeat(10, 1fr); gap: 4px; width: 230px;}
body.pg-papers .waffle i {aspect-ratio: 1; border-radius: 3px; background: var(--line-2); display: block;}
body.pg-papers .waffle i.on {background: var(--orange);}
body.pg-papers .waffle i.on.teal {background: var(--teal);}
body.pg-papers .pictogram {display: flex; gap: 7px;}
body.pg-papers .pictogram svg {width: 30px; height: 30px;}
body.pg-papers .dotplot {margin: 10px 0 4px;}
body.pg-papers .dotplot .dp-row {display: grid; grid-template-columns: 150px 1fr 92px; align-items: center; gap: 12px; padding: 7px 0; border-bottom: 1px dashed var(--line-2);}
body.pg-papers .dotplot .dp-name {font-size: 14.5px; font-weight: 600; color: var(--ink-3);}
body.pg-papers .dotplot .dp-track {position: relative; height: 22px; background: #f2f6f8; border-radius: 6px;}
body.pg-papers .dotplot .dp-avg {position: absolute; top: -3px; bottom: -3px; width: 2px; background: #98a8b1;}
body.pg-papers .dotplot .dp-dot {position: absolute; top: 50%; width: 15px; height: 15px; border-radius: 50%; background: var(--orange); transform: translate(-50%, -50%); border: 2.5px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.25);}
body.pg-papers .dotplot .dp-val {font-size: 14.5px; color: var(--ink-2);}
body.pg-papers .dotplot .dp-val strong {color: var(--teal); font-size: 16px;}
body.pg-papers .lolli {margin: 8px 0 4px;}
body.pg-papers .lolli .l-row {display: grid; grid-template-columns: 1fr 130px; gap: 14px; align-items: center; padding: 9px 0; border-bottom: 1px dashed var(--line-2);}
body.pg-papers .lolli .l-name {font-size: 14.5px; color: var(--ink-3);}
body.pg-papers .lolli .l-name .l-fix {display: block; font-size: 13px; color: var(--muted-2); margin-top: 2px; line-height: 1.45;}
body.pg-papers .lolli .l-track {position: relative; height: 4px; background: var(--line-2); border-radius: 2px;}
body.pg-papers .lolli .l-line {position: absolute; left: 0; top: 0; height: 4px; background: var(--teal); border-radius: 2px;}
body.pg-papers .lolli .l-dot {position: absolute; top: 50%; width: 13px; height: 13px; border-radius: 50%; background: var(--orange); transform: translate(-50%, -50%); border: 2px solid #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25);}
body.pg-papers .lolli .l-val {position: absolute; right: -4px; top: -20px; font-size: 13px; font-weight: 800; color: var(--teal); transform: translateX(50%);}
body.pg-papers .steps {display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 10px 0 4px;}
body.pg-papers .step {border: 1px solid var(--line-2); border-radius: 12px; padding: 18px; background: var(--surface-2);}
body.pg-papers .step .s-num {font-size: 13px; font-weight: 800; color: var(--orange); letter-spacing: 1.2px;}
body.pg-papers .step .s-title {font-size: 16px; font-weight: 800; color: var(--teal); margin: 5px 0 6px;}
body.pg-papers .step .s-body {font-size: 13px; color: var(--ink-2); line-height: 1.55;}
body.pg-papers table.bots {width: 100%; border-collapse: collapse; font-size: 14.5px; margin: 8px 0 4px;}
body.pg-papers table.bots th {text-align: left; color: var(--teal); font-size: 13px; letter-spacing: .6px; text-transform: uppercase; padding: 8px 10px; border-bottom: 2px solid var(--teal);}
body.pg-papers table.bots td {padding: 9px 10px; border-bottom: 1px solid var(--line-2); color: var(--ink-3); vertical-align: top; line-height: 1.5;}
body.pg-papers table.bots td.bot {font-weight: 800; white-space: nowrap;}
body.pg-papers .checklist {margin: 8px 0 4px;}
body.pg-papers .checklist .c-row {display: flex; gap: 14px; padding: 11px 0; border-bottom: 1px dashed var(--line-2); align-items: flex-start;}
body.pg-papers .checklist .c-box {flex: none; width: 21px; height: 21px; border: 2.2px solid var(--teal); border-radius: 6px; margin-top: 2px;}
body.pg-papers .checklist .c-text {font-size: 14.5px; color: var(--ink-3); line-height: 1.55;}
body.pg-papers .checklist .c-text .c-why {display: block; font-size: 13px; color: var(--muted-2); margin-top: 2px;}
/* Print is ALWAYS the light document (the PDF doctrine: print/shared
   output is light even when the screen is in the dark theme). Without
   this, a dark-theme print carries near-white ink and dark border
   tokens onto white paper — the text washes out and the report's
   borders all but disappear. */
@media print {
:root[data-theme="dark"] {
  color-scheme: light;
  --teal: #1e5f7b; --teal-dark: #164a61; --teal-ink: #0f3c50;
  --orange: #ff7e00; --orange-dark: #e56f00;
  --ink: #1a2b33; --muted: #5a6f78;
  --bg: #ffffff; --bg-soft: #f4f7f8; --bg-sage: #eef3f1;
  --border: #dde5e8;
  --red: #c0392b; --red-bg: #fde8e8;
  --amber: #b7791f; --amber-bg: #fef3e2;
  --green: #1e7e34; --green-bg: #e6f4ea;
  --surface: #fff; --surface-2: #fbfdff;
  --ink-2: #3a4a52; --ink-3: #24333b; --doc-ink: #17211f;
  --muted-2: #71828c; --line: #dde6ea; --line-2: #e3ebee;
  --ok: #1a7a3a; --ok-dark: #14522a; --ok-bg: #e8f5e9;
  --err-bg: #fdecea; --err-line: #f5c6cb;
  --warn-bg: #fff8e1; --warn-line: #ffe082;
  --teal-bg: #eaf3f6; --teal-2: #1E6F67;
  --soft-2: #eef2f3; --soft-3: #e8eef0;
}
}
@media print {
body.pg-papers .doc-head, body.pg-papers .profile-nudge, body.pg-papers .side-nav, body.pg-papers header, body.pg-papers footer {display: none !important;}
/* the anchored left menu (.side, a 232px grid column) must not print:
   hide it and collapse the shell so the sheet takes the full width */
body.pg-papers .side, body.pg-papers .apphead {display: none !important;}
body.pg-papers .shell {display: block !important;}
/* print = all six papers, complete, each starting on a fresh page (the
   screen still shows only the .active one) */
body.pg-papers .doc-sheet {display: block !important; box-shadow: none !important; border: none !important; border-radius: 0 !important; max-width: none !important; margin: 0 !important; padding: 0 !important;}
body.pg-papers .doc-sheet.paper ~ .doc-sheet.paper {break-before: page;}
/* lollipop value labels hang half their width past the chart's right edge
   (fine on screen, cut off the % in print): center each on its dot, but
   never let it end past the track's right end */
body.pg-papers .lolli .l-val {left: auto; right: max(0px, calc(100% - var(--x) - 1em)); transform: none; white-space: nowrap;}
body.pg-papers .doc-sheet, body.pg-papers .stat-card, body.pg-papers .cta-block, body.pg-papers .gauge, body.pg-papers .step, body.pg-papers .placeholder-logo {-webkit-print-color-adjust: exact; print-color-adjust: exact;}
a {text-decoration: none !important; color: inherit !important;}
}

/* ===== agency-report (moved from page, scoped body.pg-agencyrep) ===== */
/* Page head, actions and profile nudge: portal chrome, see body.pg-pdoc below. */
body.pg-agencyrep .doc-sheet {max-width: 820px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 40px rgba(30,95,123,.10); padding: 60px 68px 48px; margin: 28px 0 36px; color: var(--doc-ink);}
body.pg-agencyrep .masthead {display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; padding-bottom: 26px; border-bottom: 3px solid var(--teal);}
body.pg-agencyrep .masthead .who .aname {font-size: 20px; font-weight: 800; color: var(--teal);}
body.pg-agencyrep .masthead .who .aaddr {font-size: 13px; color: #5b6b72; margin-top: 4px;}
body.pg-agencyrep .doc-sheet .doc-sub {font-size: 16px; color: var(--ink-2); line-height: 1.55; margin: 0 0 30px;}
body.pg-agencyrep .stat-grid {display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 30px;}
body.pg-agencyrep .method {font-size: 12.5px; color: #7a8b92; line-height: 1.6; border-top: 1px solid #eef2f4; padding-top: 18px;}
body.pg-agencyrep .powered {text-align: center; font-size: 12.5px; color: #9aa8ae; letter-spacing: 0.4px; margin-top: 30px;}
body.pg-agencyrep .doc-sheet h3.sec-title {font-size: 20px; color: var(--teal); letter-spacing: -0.4px; margin: 28px 0 6px;}
body.pg-agencyrep .doc-sheet .sec-sub {font-size: 14.5px; color: var(--ink-2); margin: 0 0 22px; line-height: 1.55;}
body.pg-agencyrep .finding {display: flex; gap: 16px; margin-bottom: 20px;}
body.pg-agencyrep .finding .ico {flex: none; width: 42px; height: 42px; border-radius: 12px; background: #e8f1f5; display: flex; align-items: center; justify-content: center;}
body.pg-agencyrep .finding .ico svg {width: 22px; height: 22px; color: var(--teal);}
body.pg-agencyrep .finding .f-title {font-size: 16px; font-weight: 800; color: var(--doc-ink);}
body.pg-agencyrep .finding .f-num {color: var(--orange);}
body.pg-agencyrep .finding .f-text {font-size: 14.5px; color: var(--ink-2); margin-top: 4px; line-height: 1.55;}
body.pg-agencyrep .chart-wrap {margin: 22px 0 6px;}
body.pg-agencyrep .chart-wrap .chart-cap {font-size: 14.5px; font-weight: 700; color: var(--doc-ink); margin-bottom: 10px;}
body.pg-agencyrep .chart-wrap svg {width: 100%; height: auto; display: block;}
body.pg-agencyrep .chart-note {font-size: 12.5px; color: #7a8b92; margin: 8px 0 0;}
body.pg-agencyrep .cta-block {background: var(--teal); color: #fff; border-radius: 14px; padding: 26px 30px; margin-top: 26px;}
body.pg-agencyrep .cta-block .cta-q {font-size: 20px; font-weight: 800; letter-spacing: -0.3px;}
body.pg-agencyrep .cta-block .cta-t {font-size: 14.5px; line-height: 1.6; margin-top: 8px;}
body.pg-agencyrep .cta-block .cta-t strong {color: #ffd9b3;}
@page { size: letter; margin: 0.5in 0.6in; }
@media print {
body.pg-agencyrep .app-header, body.pg-agencyrep .side-nav, body.pg-agencyrep .site-footer, body.pg-agencyrep .no-print {display: none !important;}
/* the anchored left menu (.side, a 232px grid column) must not print:
   hide it and collapse the shell so the sheet takes the full width */
body.pg-agencyrep .side, body.pg-agencyrep .apphead {display: none !important;}
body.pg-agencyrep .shell {display: block !important;}
body.pg-agencyrep .acct-layout {display: block !important; max-width: none !important; padding: 0 !important; margin: 0 !important;}
body.pg-agencyrep .acct-content {padding: 0 !important;}
body {background: #fff !important;}
body.pg-agencyrep .doc-sheet {box-shadow: none !important; border: none !important; border-radius: 0 !important; max-width: none !important; margin: 0 !important; padding: 0 !important;}
body.pg-agencyrep .doc-sheet.page-2 {break-before: page; page-break-after: avoid;}
body.pg-agencyrep .doc-sheet .masthead {break-inside: avoid;}
body.pg-agencyrep .doc-sheet h3.sec-title {margin-top: 14px !important;}
body.pg-agencyrep .doc-sheet .sec-sub {margin-bottom: 12px !important;}
body.pg-agencyrep .finding {margin-bottom: 13px !important;}
body.pg-agencyrep .chart-wrap {margin: 12px 0 4px !important;}
body.pg-agencyrep .chart-wrap svg {max-height: 150px;}
body.pg-agencyrep .cta-block {padding: 18px 24px !important; margin-top: 16px !important;}
body.pg-agencyrep .doc-sheet .doc-sub {margin-bottom: 20px !important;}
/* page 2 ran one line long: its closing "Powered by" line spilled onto a
   third page. Tighter tail spacing keeps the handout at exactly 2 pages. */
body.pg-agencyrep .doc-sheet.page-2 .finding {margin-bottom: 10px !important;}
body.pg-agencyrep .doc-sheet.page-2 .cta-block {margin-top: 12px !important;}
body.pg-agencyrep .doc-sheet.page-2 .powered {margin-top: 10px !important;}
/* real branding runs taller than the placeholder this was tuned on: a
   wide logo raises the masthead and the agency name + address wrap the
   CTA line to two lines, pushing the closing "Powered by" line onto a
   third page. Trim the tail so page 2 holds at exactly 2 pages with a
   real logo and address too. */
body.pg-agencyrep .doc-sheet.page-2 .cta-block {padding-top: 13px !important; padding-bottom: 13px !important;}
body.pg-agencyrep .doc-sheet.page-2 .powered {margin-top: 5px !important;}
body.pg-agencyrep .stat-grid {margin-bottom: 20px !important; gap: 12px !important;}
body.pg-agencyrep .doc-sheet, body.pg-agencyrep .stat-card, body.pg-agencyrep .cta-block, body.pg-agencyrep .finding .ico, body.pg-agencyrep .placeholder-logo {-webkit-print-color-adjust: exact; print-color-adjust: exact;}
}

/* ===== report (moved from page, scoped body.pg-report) ===== */
@media print {
body.pg-report .report-close, body.pg-report .report-actions, body.pg-report .dropdown-toggle, body.pg-report button.close, body.pg-report .no-print {display: none !important;}
body.pg-report .fix-toggle {display: none !important;}
body.pg-report .fix-collapsible {display: block !important;}
body.pg-report .score-category, body.pg-report .chart-container, body.pg-report .crawler-matrix, body.pg-report .report-section {page-break-inside: avoid;}
body.pg-report .fs-cats, body.pg-report .category-bars {page-break-inside: avoid;}
body.pg-report .rep-panel {display: block !important;}
body.pg-report .rep-tabs {display: none !important;}
body.pg-report .rep-tip {display: block; position: static; margin-top: 4px; cursor: default;}
body.pg-report .rep-tip svg {display: none !important;}
body.pg-report .rep-tip::after {content: attr(data-tip); position: static; opacity: 1; background: none; color: var(--muted); box-shadow: none; padding: 0; font-size: 11.5px; max-width: none; width: auto;}
}
body.pg-papers .dp-avg, body.pg-papers .dp-dot, body.pg-papers .l-dot, body.pg-papers .l-val { left: var(--x); }
body.pg-papers .l-line { width: var(--x); }
.svg-score { font-size: 20px; font-weight: 800; fill: #173f3a; }
body.pg-papers .dp-note { font-size: 13px; color: var(--ink-2); margin-top: 8px; max-width: 230px; }
body.pg-papers .dp-src { font-size: 13px; color: var(--muted-2); text-align: right; }
body.pg-settings .pf-amber { color: #b45309; }
body.pg-settings .notif-actions { display: flex; gap: 8px; }
body.pg-settings .agency-fields { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 14px; }
/* Branding card: one column — Role, Logo (report masthead preview), agency fields. */
body.pg-settings .brand-stack { flex: 1; min-width: 0; }
body.pg-settings .brand-logo { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 14px; }
body.pg-settings .brand-logo[hidden] { display: none; }
body.pg-settings .brand-logo .pf-label { display: block; }
body.pg-settings .brand-logo .file-pill { width: 100%; }
/* The preview is a slice of a report page: always light (that's what
   prints), so it pins the light palette even on the dark theme. Logo and
   type sizes match the study/papers masthead. */
body.pg-settings .brand-preview {
  --teal: #1e5f7b; --ink: #1a2b33; --ink-2: #3a4a52; --muted: #5a6f78;
  --surface: #fff; --border: #dde5e8; --red: #c0392b;
  margin: 0 0 14px; background: #fff; color: var(--ink); color-scheme: light;
  border: 1px solid #dde5e8; border-radius: 12px; padding: 18px 32px 28px;
  box-shadow: 0 1px 3px rgba(15, 60, 80, .08);
}
body.pg-settings .brand-preview-cap { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 18px; }
body.pg-settings .brand-preview-mast { display: flex; align-items: center; justify-content: space-between; gap: 24px; border-bottom: 3px solid var(--teal); padding-bottom: 22px; }
body.pg-settings .brand-preview .logo-slot { flex-shrink: 0; }
body.pg-settings .brand-preview .logo-wrap img { max-height: 64px; max-width: 260px; object-fit: contain; border: none; border-radius: 0; padding: 0; background: none; }
body.pg-settings .brand-preview .placeholder-logo { font-size: 14.5px; font-weight: 800; color: var(--teal); border: 2px dashed #b9cdd6; border-radius: 10px; padding: 14px 20px; display: inline-block; }
body.pg-settings .brand-preview .logo-wrap:not([hidden]) + .placeholder-logo { display: none; }
body.pg-settings .brand-preview .who { text-align: right; min-width: 0; }
body.pg-settings .brand-preview .aname { font-size: 20px; font-weight: 800; color: var(--teal); overflow-wrap: break-word; }
body.pg-settings .brand-preview .aaddr { font-size: 14.5px; color: var(--ink-2); margin-top: 3px; white-space: pre-line; overflow-wrap: break-word; }
@media (max-width: 640px) {
  body.pg-settings .brand-preview { padding: 14px 18px 20px; }
  body.pg-settings .brand-preview-mast { flex-wrap: wrap; }
}
body.pg-wizard .site-pick { margin-bottom: 16px; padding: 12px; background: #fff8f0; border: 1px solid #ffd8a8; border-radius: 8px; }
body.pg-wizard .combine-box { margin: 12px 0; padding: 10px; background: #f0f7ff; border-radius: 8px; }
body.pg-llmsgen .sec-title { flex: 1; margin-right: 8px; }
body.pg-papers .star-on { color: var(--orange); }
body.pg-papers .star-off { color: #c3d0d7; }
body.pg-robotsval .num, body.pg-schemaval .num { color: var(--c); }
.hist-score { color: var(--c); }

/* ---------- Report.js generated markup (2026-10-14: inline styles moved here) ---------- */
#report-root .rep-c { color: var(--c); }
#report-root .exec-num { color: var(--c); }
#report-root .cat-score { color: var(--c); }
#report-root .hbar-fill { width: var(--w, 0%); }
#report-root .rep-stat-big { color: var(--c); }
#report-root .rep-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
#report-root .rep-table tbody tr { border-top: 1px solid var(--border); }
#report-root .rep-td { padding: 10px 16px; }
#report-root .rep-td-b { padding: 10px 16px; font-weight: 600; }
#report-root .rep-th { padding: 12px 16px; font-size: 12px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); text-align: left; }
#report-root .rep-copy-label { font-size: 14.5px; font-weight: 700; margin: 0 0 8px; }
#report-root .rep-copy-actions { margin-top: 12px; display: flex; gap: 10px; }
#report-root .rep-flex-between { display: flex; justify-content: space-between; font-size: 13px; margin-bottom: 6px; }
#report-root .rep-b { font-weight: 700; }
#report-root .rep-note-p { font-size: 14.5px; margin-top: 4px; }
#report-root .rep-bench-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 0; }
#report-root .rep-mini-label { font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 4px; }
#report-root .rep-big-num { font-size: 36px; font-weight: 800; color: var(--c); }
#report-root .rep-bench-note { background: var(--bg-soft); border-radius: 8px; padding: 16px 20px; font-size: 14.5px; }
#report-root .rep-means { margin-top: 10px; font-size: 13px; color: var(--muted); }
#report-root .rep-bad-b { color: var(--red, var(--red)); font-weight: 700; }
#report-root .rep-good-b { color: var(--green, var(--green)); font-weight: 700; }
#report-root .rep-loading { color: var(--muted); font-size: 14.5px; }
#report-root .rep-hist-row { display: flex; align-items: center; gap: 10px; margin: 8px 0; font-size: 13px; }
#report-root .rep-hist-date { width: 86px; color: var(--muted); }
#report-root .rep-hist-track { flex: 1; background: var(--bg-soft); border-radius: 6px; height: 14px; }
#report-root .rep-hist-bar { height: 100%; border-radius: 6px; width: var(--w); background: var(--bg); }
/* Monitoring upsell (report page, non-subscribers) */
#report-root .mon-banner { background: #e8f4f0; border: 1px solid #bfe0d2; border-radius: 10px; padding: 12px 16px; font-size: 14.5px; margin: 18px 0 12px; color: var(--ink); }
#report-root .mon-panel { margin: 12px 0 26px; }
/* Columns sized by the CONTAINER (auto-fit/minmax), not the viewport: the
   report column is narrower than the window, and a viewport breakpoint
   squeezed the first panel into a sliver (Kuang's screenshot, 2026-10-15). */
#report-root .aeo-upsell-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(330px, 100%), 1fr)); gap: 16px; grid-auto-rows: 1fr; margin: 12px 0 26px; }
/* Uniform blocks (Kuang, 2026-10-15): every panel the same size, CTA pinned
   to the bottom so the grid reads as one tidy set, not a jumble. */
#report-root .aeo-upsell-grid .mon-panel { margin: 0; display: flex; flex-direction: column; }
/* Mockup shape: the Start button floats CENTERED over the blurred body —
   same spot on every panel regardless of content height. */
#report-root .mon-panel-body { position: relative; flex: 1; min-height: 92px; }
#report-root .aeo-upsell-grid .mon-cta { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; margin: 0; padding: 0; }
#report-root .mon-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
#report-root .mon-panel-head h3 { margin: 0; font-size: 17px; }
#report-root .mon-lock { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--muted); border: 1px solid var(--border); border-radius: 999px; padding: 4px 10px; white-space: nowrap; }
#report-root .mon-future { margin-top: 2px; }
#report-root .mon-future-row { opacity: .8; }
#report-root .mon-future-track { flex: 1; height: 14px; border-radius: 6px; border: 1.5px dashed var(--border); filter: blur(1px); }
#report-root .mon-future-lab { font-size: 12.5px; color: var(--muted); white-space: nowrap; }
#report-root .aeo-rate-row { display: flex; align-items: center; gap: 12px; margin: 7px 0; }
#report-root .aeo-rate-name { flex: 0 0 118px; font-size: 13px; font-weight: 600; color: var(--ink); }
#report-root .aeo-rate-track { flex: 1; height: 12px; background: var(--surface-2); border-radius: 6px; overflow: hidden; }
#report-root .aeo-blur-fill { height: 100%; width: 62%; background: var(--teal); border-radius: 6px; }
#report-root .aeo-rate-fill { height: 100%; background: var(--teal); border-radius: 6px; }
#report-root .aeo-rate-fill.alt { background: var(--amber); }
#report-root .aeo-rate-val { flex: 0 0 52px; font-size: 13px; color: var(--muted); text-align: right; }
#report-root .aeo-record { text-align: left; }
#report-root .aeo-record > h3 { font-size: 20px; margin: 2px 0 8px; }
#report-root .aeo-record .viz-card { margin-top: 14px; padding-left: 16px; padding-right: 16px; }
/* AEO record: the two top charts share one row (Kuang, 2026-10-15). */
#report-root .aeo-rec-two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: stretch; margin-bottom: 16px; }
#report-root .aeo-rec-two .viz-card { margin-top: 14px; height: 100%; }
@media (max-width: 900px) { #report-root .aeo-rec-two { grid-template-columns: 1fr; } }
#report-root .aeo-rec-h { font-size: 14.5px; margin: 0 0 10px; }
#report-root .aeo-matrix td.aeo-hit { color: var(--ink); font-weight: 700; }
#report-root .aeo-skel-bar { height: 13px; border-radius: 6px; background: var(--surface-2); margin: 9px 0; }
#report-root .aeo-change-head { font-size: 14.5px; margin: 4px 0 6px; }
#report-root .aeo-peek { display: flex; gap: 12px; margin: 8px 0 4px; }
#report-root .aeo-peek-fig { flex: 1; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; text-align: center; }
#report-root .aeo-peek-num { font-size: 20px; font-weight: 800; color: var(--teal-ink); line-height: 1.1; }
#report-root .aeo-peek-lab { font-size: 12px; color: var(--muted); margin-top: 2px; }
#report-root .aeo-blur { filter: blur(3px); opacity: .55; pointer-events: none; user-select: none; }
/* Static report: the real AEO record, shown locked behind the house blur. */
#report-root .aeo-locked { max-height: 560px; overflow: hidden; border-radius: 12px; margin-top: 14px; }
#report-root .aeo-blur .rep-ghost { opacity: 1; margin-top: 4px; }
/* Compact pass (2026-10-15 QA): teaser panels were 433px tall; Kuang's rule is
   fit more in one page view. Trim the vertical drivers inside the AEO grid. */
#report-root .aeo-upsell-grid .mon-panel { padding: 12px 16px; }
#report-root .aeo-upsell-grid .mon-panel-head { margin-bottom: 2px; }
#report-root .aeo-upsell-grid .aeo-rate-row { margin: 3px 0; }
#report-root .aeo-upsell-grid .aeo-skel-bar { height: 10px; margin: 5px 0; }
#report-root .aeo-upsell-grid .aeo-peek { margin: 5px 0 2px; gap: 8px; }
#report-root .aeo-upsell-grid .aeo-peek-fig { padding: 6px 10px; }
#report-root .aeo-upsell-grid .aeo-peek-num { font-size: 20px; }
#report-root .aeo-upsell-grid .mon-future-track { height: 11px; }
#report-root .aeo-upsell-grid .viz-card { margin-top: 8px; padding: 10px 12px; }
/* Round 2 (same QA pass): the measured drivers were the CTA block (104px),
   the head (51-77px) and one panel's blurred question table (213px). Cap the
   blurred peek so it hints instead of unfolding, tighten head + CTA. */
#report-root .aeo-upsell-grid .aeo-blur { max-height: 118px; overflow: hidden; }
#report-root .aeo-upsell-grid .mon-panel-head h3 { font-size: 14.5px; line-height: 1.25; }
#report-root .aeo-upsell-grid .mon-lock { padding: 2px 8px; font-size: 11.5px; }
#report-root .aeo-upsell-grid .mon-cta { gap: 8px; }
#report-root .aeo-upsell-grid .mon-note { font-size: 12px; line-height: 1.35; }
#report-root .mon-cta { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 14px; }
#report-root .mon-note { font-size: 13px; color: var(--muted); }
#report-root .mon-plans { display: flex; gap: 10px; flex-wrap: wrap; margin: 16px 0 10px; }
#report-root .mon-plan { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--border); border-radius: 10px; padding: 10px 14px; font-size: 14.5px; cursor: pointer; }
#report-root .mon-plan:has(input:checked) { border-color: var(--orange); background: #fff7ef; }
#report-root .mon-tos { display: flex; align-items: center; gap: 8px; font-size: 14.5px; margin: 8px 0 12px; }
#report-root .mon-go-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
#report-root .mon-err { color: #b3261e; font-size: 13px; }
.tools-pager { display: flex; align-items: center; gap: 14px; margin: 4px 0 24px; }
#report-root .rep-float-r { float: right; }
#report-root .location-table-wrap, #report-root .page-matrix-wrap { margin: 0 0 24px; overflow-x: auto; }
#report-root .rep-p15 { font-size: 14.5px; color: var(--muted); }
#report-root .rep-list { margin: 14px 0 6px 20px; font-size: 14.5px; line-height: 1.65; color: var(--muted); }
#report-root .rep-list2 { margin: 8px 0 2px 20px; font-size: 14.5px; line-height: 1.65; }
#report-root .rep-guide-link { color: var(--teal); font-weight: 400; }
#report-root .rep-pm-note { font-size: 13px; color: var(--muted); margin: 0 0 10px; }
#report-root .rep-ico { width: 18px; height: 18px; }
#report-root .rep-uplift-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
#report-root .rep-up-label { font-size: 12.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; }
#report-root .rep-up-num { font-size: 42px; font-weight: 800; color: var(--c); }
#report-root .rep-cmp-th { padding: 12px 16px; font-size: 12px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); }
#report-root .rep-cmp-td { padding: 12px 16px; }
#report-root .rep-cmp-td-b { padding: 12px 16px; font-weight: 700; }
#report-root .rep-cmp-score { padding: 12px 16px; font-weight: 800; color: var(--c); }
#report-root .rep-cmp-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
#report-root .rep-cmp-table tbody tr { border-top: 1px solid var(--border); }
#report-root .rep-cmp-table tr.you { background: #fef6ee; }
#report-root .rep-cmp-note { padding: 18px 24px; background: var(--bg-soft); font-size: 14.5px; border-top: 1px solid var(--border); }
#report-root .vbar { height: var(--h); }
.wl-logo { max-height: 64px; max-width: 240px; object-fit: contain; border-radius: 8px; }
.wl-name { font-size: 20px; font-weight: 800; }
.wl-addr { font-size: 13px; color: var(--muted); }
.wl-sub { font-size: 13px; color: var(--muted); }
.u-mt-24 { margin-top: 24px; }
#report-root .rep-p145 { font-size: 14.5px; }
/* Checkout test-handoff state (converted from inline styles, 2026-10-14) */
.co-state { text-align: center; padding: 40px 24px; }
.co-state-p { color: var(--muted); max-width: 420px; margin: 0 auto 8px; }
.co-state-p2 { color: var(--muted); max-width: 420px; margin: 0 auto 20px; }

/* ===== App work-page headings: ONE standard (Kuang 2026-10-14) =====
   28px two-tone brand-head, -0.6px tracking, 6px under the title; the
   header block keeps its 24px bottom spacing via the sub where one
   exists, or the title itself where it does not (settings). */
.acct-content h1.brand-head { font-size: 30px; letter-spacing: -0.6px; margin-bottom: 6px; }
body[data-section="scan"] .wizard h1 { font-size: 30px; letter-spacing: -0.6px; margin-bottom: 6px; }
body.pg-settings .acct-content h1.brand-head { margin-bottom: 24px; }

/* Tool hero kicker (Kuang, 2026-10-14): the orange "Free tool · No signup"
   line on the five portal tool heroes goes a little bigger than the global
   13px kicker — scoped to tool heroes inside the app shell only. */
.acct-content .hero .kicker { font-size: 14.5px; }

/* Legacy robots generator: local pieces (moved from inline styles 2026-10-14) */
.bot-toggle-row { display: flex; gap: 8px; margin-bottom: 12px; }
.notice-pre { margin: 8px 0 0; white-space: pre-wrap; font-size: 12.5px; max-height: 200px; overflow-y: auto; }
.notice-note { margin: 8px 0 0; font-size: 13px; }

/* --- Admin pages (moved from per-page <style> 2026-10-14) --- */
body[data-admin-gate] main.acct-layout{visibility:hidden}body[data-admin-gate].admin-verified main.acct-layout{visibility:visible}
.tool-result { margin-top: 12px; padding: 10px 12px; background: #f5f7f8; border: 1px solid #e2e8eb; border-radius: 6px; font-family: monospace; font-size: 12px; white-space: pre-wrap; word-break: break-word; max-height: 300px; overflow: auto; }
.tool-note { margin-top: 10px; font-size: 13px; color: var(--muted); }
.scan-list { margin-top: 12px; font-size: 13px; }
.scan-list table { width: 100%; border-collapse: collapse; }
.scan-list td, .scan-list th { padding: 5px 8px; border-bottom: 1px solid #e2e8eb; text-align: left; }
.scan-list .jid { font-family: monospace; font-size: 11.5px; }

/* ---------- Dark theme overrides for literal tint backgrounds ----------
   (shared.css carries the token-level dark palette; these are the app
   rules that hardcode light tints, remapped for data-theme="dark".) */
:root[data-theme="dark"] .mx-warn { background: var(--surface-2); }
:root[data-theme="dark"] .test-banner { background: var(--surface-2); border-color: #8a6d1f; color: #e8c98a; }
:root[data-theme="dark"] .warn-item { background: var(--surface-2); border-color: var(--border); border-left-color: #d9a521; }
:root[data-theme="dark"] .warn-badge { background: #3a2c10; }
:root[data-theme="dark"] .exec-card { background: var(--surface-2); }
:root[data-theme="dark"] .rep-chip { background: var(--teal-bg); }
:root[data-theme="dark"] .rep-tab-cnt { background: var(--teal-bg); }
:root[data-theme="dark"] .rep-soon { background: var(--surface); border-color: var(--border); }
:root[data-theme="dark"] body.pg-robotsval .badge-warn { background: var(--surface-2); color: var(--amber); }
:root[data-theme="dark"] body.pg-wizard .site-pick { background: var(--surface-2); border-color: #5c4d1c; }
:root[data-theme="dark"] #report-root .mon-plan:has(input:checked) { background: var(--surface-2); }
:root[data-theme="dark"] #report-root .mon-banner { background: var(--surface-2); border-color: var(--border); color: var(--ink); }
:root[data-theme="dark"] #report-root .rep-cmp-table tr.you { background: var(--surface-2); }
:root[data-theme="dark"] .scan-list td, :root[data-theme="dark"] .scan-list th { border-bottom-color: var(--line); }
:root[data-theme="dark"] body.pg-robotsval .mode-toggle button.active { color: var(--ink); }
:root[data-theme="dark"] .output-pane pre, :root[data-theme="dark"] body.pg-schemaval details.raw-json pre { color: #d9e8ee; }
:root[data-theme="dark"] body.pg-wizard .combine-box { background: var(--surface-2); }

/* Monitoring summary + detail pages (2026-10-15) — .mons- prefix. */
.mons-meta { color: var(--muted); font-size: 13px; }
.plan-card { padding: 6px 18px 14px; }
.plan-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.plan-table th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); padding: 10px 8px; border-bottom: 2px solid var(--border); }
.plan-table td { padding: 9px 8px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.plan-table tr:last-child td { border-bottom: none; }
.plan-n { font-weight: 700; width: 34px; }
.plan-jump { color: var(--ink); font-weight: 600; text-decoration: none; }
.plan-jump:hover { color: var(--teal); text-decoration: underline; }
.hist-tools { display: flex; align-items: center; gap: 14px; margin: 0 0 16px; flex-wrap: wrap; }
.hist-search { flex: 1 1 260px; max-width: 440px; }
.hist-count { color: var(--muted); font-size: 13px; }
.hist-pager { display: flex; align-items: center; gap: 16px; margin: 20px 0 8px; }
.hist-page-lab { color: var(--muted); font-size: 13px; }
.plan-box { background: var(--surface-2); border-radius: 10px; padding: 14px 16px; margin: 14px 0 6px; }
.plan-box-msg { font-size: 13px; line-height: 1.5; color: var(--ink-2); margin: 8px 0 10px; }
.mons-next { font-size: 14.5px; margin: 12px 0 2px; }
.mons-streak { color: var(--muted); font-size: 13px; margin: 2px 0 0; }
.mons-earlier { margin-top: 12px; border-top: 1px solid var(--border); padding-top: 8px; }
.mons-earlier-row { font-size: 13px; color: var(--muted); padding: 3px 0; }
/* Detail Overview: chart + right rail (Next best action, Streak). */
.monc-ov-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 16px; align-items: stretch; margin-bottom: 16px; }
.monc-ov-grid .viz-card { margin: 0; }
.monc-ov-grid > .viz-card { height: 100%; }
.monc-ov-rail { display: grid; gap: 16px; }
.monc-action-title { font-weight: 400; font-size: 13px; color: var(--muted); margin: 0 0 4px; }
@media (max-width: 900px) { .monc-ov-grid { grid-template-columns: 1fr; } }
/* Detail Overview KPIs: all four in one row (Kuang, 2026-10-15). */
.monc-kpis.monc-kpis-ov { grid-template-columns: repeat(4, minmax(0, 1fr)); }
/* Four-across holds until phone widths (Kuang, 2026-10-15 — at his
   window size the 900px breakpoint was collapsing the row to 2x2). */
@media (max-width: 640px) { .monc-kpis.monc-kpis-ov { grid-template-columns: 1fr 1fr; } }
/* AI mentions (2026-10-15): top two cards in a row. */
.monc-two-eq { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: stretch; margin-bottom: 16px; }
.monc-two-eq .viz-card { margin: 0; height: 100%; }
@media (max-width: 820px) { .monc-two-eq { grid-template-columns: 1fr; } }
/* Summary page (2026-10-15): 4 KPI boxes in a row + one compact sites table. */
.monc-kpis.mons-kpis4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 640px) { .monc-kpis.mons-kpis4 { grid-template-columns: 1fr 1fr; } }
.mons-table-card { padding: 10px 18px 14px; }
.mons-table td { vertical-align: middle; padding: 9px 6px; }
.mons-td-score { font-size: 20px; font-weight: 800; }
.mons-td-actions { white-space: nowrap; text-align: right; }
.mons-table-note { margin: 10px 0 2px; }
/* Reports tab (2026-10-15): one row of three equal-height cards + history below. */
.monc-reports-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: stretch; margin-bottom: 16px; }
.monc-deliv-card { margin-bottom: 16px; }
.monc-deliv-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.monc-deliv-grid .monc-rule { flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: 8px; border-bottom: none; padding: 0; }
@media (max-width: 900px) { .monc-deliv-grid { grid-template-columns: 1fr 1fr; } }
.monc-reports-grid .viz-card { margin: 0; height: 100%; }
@media (max-width: 1120px) { .monc-reports-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 720px) { .monc-reports-grid { grid-template-columns: 1fr; } }
.rule-line-tight { padding: 5px 0; }
.rule-line.monc-rule { display: flex; align-items: center; justify-content: space-between; gap: 10px; cursor: pointer; }
#monc-badge img { max-width: 100%; height: auto; }
#monc-badge .monc-badge-snip, #monc-badge code { display: block; max-width: 100%; white-space: normal; word-break: break-all; }
.monc-three .monc-alert-row { flex-wrap: wrap; }
.monc-three .monc-alert-main { flex: 1 1 100%; order: 3; }
/* Reports tab (2026-10-15): icon actions, delivery switches, badge, history table. */
.icobtn { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border: 1px solid var(--border); border-radius: 8px; background: none; color: var(--teal); cursor: pointer; vertical-align: middle; }
.icobtn:hover { background: var(--surface-2); }
.monc-rep-actions { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.rule-line { display: flex; gap: 10px; align-items: flex-start; padding: 7px 0; cursor: pointer; }
.rule-line input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--teal); }
.monc-table { width: 100%; border-collapse: collapse; }
.monc-table th { text-align: left; font-size: 12px; color: var(--muted); padding: 5px 6px; border-bottom: 1px solid var(--border); }
.monc-table td { padding: 7px 6px; border-bottom: 1px solid var(--border); vertical-align: top; }
.monc-rep-cell .mons-rep-view { margin-top: 8px; }
.monc-snippet + .mons-view { margin-top: 4px; }
.monc-snippet { display: block; max-width: 100%; white-space: normal; word-break: break-all; background: var(--surface-2); border-radius: 6px; padding: 5px 9px; font-size: 11.5px; margin-bottom: 8px; }
/* Card head with the info icon at the top-right (Kuang's example from
   the report stat boxes, 2026-10-15). */
.monc-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.mons-rep-view { padding: 10px 0 4px; font-size: 14.5px; line-height: 1.5; }
.mons-rep-view h4 { margin: 12px 0 4px; font-size: 14.5px; }
.mons-err { color: var(--red); font-size: 14.5px; margin-top: 10px; }
.mons-row { position: relative; }
.mons-row-main { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.mons-row-site { flex: 1 1 180px; display: flex; flex-direction: column; }
.mons-row-site strong { font-size: 17px; }
.mons-row-score { font-size: 30px; font-weight: 800; min-width: 52px; text-align: right; }
.mons-row-meta { margin-top: 10px; }
.mons-row-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.mons-chip { font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; white-space: nowrap; }
.mons-chip-up { background: #e5f4ea; color: #157347; }
.mons-chip-down { background: #fbeaea; color: #b3362b; }
.mons-chip-flat { background: var(--surface-2); color: var(--muted); }
.mons-spark { display: block; }
.mons-add { display: flex; gap: 10px; flex-wrap: wrap; }
.mons-plans { display: flex; gap: 10px; flex-wrap: wrap; margin: 6px 0 12px; }
.mons-plan { border: 1px solid var(--border); border-radius: 10px; padding: 10px 14px; cursor: pointer; font-size: 14.5px; }
.mons-plan-sel { border-color: var(--orange,#ff7e00); background: #fff7ec; }
.mons-tos { display: block; font-size: 14.5px; margin: 8px 0 12px; }
.mons-detail-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.mons-detail-h1 { font-size: 30px; margin: 0 0 4px; }
.mons-detail-score { display: flex; align-items: center; gap: 12px; font-size: 42px; font-weight: 800; }
.mons-chart { width: 100%; height: auto; display: block; }
/* Overview chart card: the drawing flexes to fill the card's full
   height (the card matches the rail beside it) — no white chunk. */
.monc-chart-card { display: flex; flex-direction: column; }
.monc-chart-card .mons-chart { flex: 1 1 auto; min-height: 230px; }
.mons-grid { stroke: var(--border); stroke-width: 1; }
.mons-axis { font-size: 11px; fill: var(--muted); }
.mons-cats { margin-top: 14px; border-top: 1px solid var(--border); }
.mons-cat-row { display: flex; align-items: center; gap: 14px; padding: 7px 0; border-bottom: 1px solid var(--border); font-size: 14.5px; }
.mons-cat-row span:first-child { flex: 1; }
.mons-delta-up { color: #157347; font-weight: 700; font-size: 13px; }
.mons-delta-down { color: #b3362b; font-weight: 700; font-size: 13px; }
.mons-list { list-style: none; margin: 0; padding: 0; }
.mons-list li { padding: 6px 0; border-bottom: 1px solid var(--border); font-size: 14.5px; }
.mons-list li:last-child { border-bottom: none; }
.mons-muted { color: var(--muted); }
.mons-fixed-h { font-weight: 700; margin: 14px 0 4px; }
.mons-new-h { font-weight: 700; margin: 14px 0 4px; color: #b3362b; }
.mons-flip { margin: 8px 0 0; font-size: 14.5px; }
.mons-sev { font-size: 11px; font-weight: 700; text-transform: capitalize; padding: 2px 8px; border-radius: 999px; background: var(--surface-2); color: var(--muted); }
.mons-sev-critical, .mons-sev-high { background: #fbeaea; color: #b3362b; }
.mons-sev-medium { background: #fdf3e0; color: #b7791f; }
.mons-cg { overflow-x: auto; }
.mons-cg-row { display: flex; align-items: center; gap: 4px; padding: 4px 0; min-width: 520px; }
.mons-cg-name { flex: 0 0 130px; font-size: 13px; font-weight: 400; color: var(--muted); }
.mons-cg-cell { flex: 1; text-align: center; font-size: 11px; }
.mons-cg-pct { flex: 0 0 44px; text-align: right; }
.mons-dot { display: inline-block; width: 11px; height: 11px; border-radius: 50%; }
.mons-dot-ok { background: #2e9e5b; }
.mons-dot-bad { background: #d64541; }
.mons-dot-unknown { background: #fff; border: 2px solid #b9c4c9; width: 7px; height: 7px; }
/* Compact upsell panels (Kuang, 2026-10-15): the blocks should read at the
   report module's scale — a whole set visible in one screen, no scrolling
   past stretched-empty cards. */
#report-root .aeo-upsell-grid { grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); }
#report-root .aeo-upsell-grid .mon-panel { padding: 16px 18px; }
#report-root .aeo-upsell-grid .mon-panel-head h3 { font-size: 16px; }
#report-root .aeo-upsell-grid .aeo-peek { gap: 8px; margin: 6px 0 2px; }
#report-root .aeo-upsell-grid .aeo-peek-fig { padding: 8px 10px; }
#report-root .aeo-upsell-grid .aeo-peek-num { font-size: 20px; }
#report-root .aeo-upsell-grid .rep-ghost th, #report-root .aeo-upsell-grid .rep-ghost td { padding: 5px 10px; font-size: 13px; }
#report-root .aeo-upsell-grid .aeo-rate-row { margin: 5px 0; }
#report-root .aeo-upsell-grid .aeo-skel-bar { margin: 7px 0; }
#report-root .aeo-upsell-grid .mon-cta { padding-top: 10px; }
#report-root .aeo-upsell-grid .aeo-qpeek { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 13px; margin: 8px 0 4px; }
#report-root .aeo-upsell-grid .mon-lock { font-size: 12px; padding: 3px 8px; }
#report-root .aeo-upsell-grid .aeo-peek-lab { font-size: 11.5px; }

/* Monitoring console tabs (2026-10-15, Kuang's mockup layout) */
.monc-tabs { margin-top: 16px; }
.monc-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 12px; margin-bottom: 14px; }
.monc-kpi { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.monc-kpi-lab { margin: 0; font-size: 12.5px; color: var(--muted); }
.monc-kpi-big { margin: 2px 0; font-size: 30px; font-weight: 700; line-height: 1.1; }
.monc-kpi-sub { margin: 0; font-size: 12.5px; color: var(--muted); }
.monc-change-row { display: flex; gap: 14px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.monc-change-row:last-child { border-bottom: none; }
.monc-change-date { flex: 0 0 108px; color: var(--muted); font-size: 13px; padding-top: 1px; }
.monc-change-bits { font-size: 13px; color: var(--muted); }
/* Score-change lines inside a change row match the row's 14px — the
   delta classes default to 13px for tighter contexts (Kuang, 2026-10-15). */
.monc-change-bits .mons-delta-up, .monc-change-bits .mons-delta-down { font-size: 13px; }
.monc-chip { display: inline-block; font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 999px; vertical-align: 1px; }
.monc-chip-fix { background: #e2f4e5; color: #1d7a35; }
.monc-chip-new { background: #fdf0d9; color: #9a6a12; }
.monc-chip-alert { background: #fbe3e3; color: #b02a2a; }
/* Changes & alerts one-screen layout (2026-10-15): three columns, each
   card body scrolls internally so the whole tab fits one viewport. */
.monc-three { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 16px; align-items: stretch; }
/* Columns end together (Kuang, 2026-10-15): the last card in each
   column flexes to the row's full height — no white space under the
   shorter side. The watch card spreads its rows to fill. */
.monc-three .monc-col > .viz-card:last-child { flex: 1; }
.monc-watch-card { display: flex; flex-direction: column; }
.monc-watch-card .monc-watch-row { flex: 1; align-items: center; }
@media (max-width: 1120px) { .monc-three { grid-template-columns: 1fr 1fr; } }
@media (max-width: 720px) { .monc-three { grid-template-columns: 1fr; } }
.monc-scroll { max-height: 46vh; overflow-y: auto; }
.monc-dchip { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 1px 8px; border-radius: 99px; background: var(--surface-2); color: var(--muted); }
.monc-dchip.up { background: #e2f3e5; color: #1d7a35; }
.monc-dchip.down { background: #fbe7e5; color: #b03030; }
.monc-change-compact { padding: 7px 0; }
.monc-change-compact { display: grid; grid-template-columns: 108px 132px minmax(0, 1fr); column-gap: 14px; align-items: start; }
.monc-change-compact .monc-change-date { flex: none; }
.monc-change-bits .monc-chip { display: inline-block; min-width: 62px; text-align: center; }
.monc-two { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.monc-col { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.monc-col .viz-card { margin: 0; }
@media (max-width: 880px) { .monc-two { grid-template-columns: 1fr; } }
.monc-watch-row { display: grid; grid-template-columns: max-content minmax(0, 1fr); column-gap: 14px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.monc-watch-row:last-child { border-bottom: none; }
.monc-watch-name { font-weight: 600; font-size: 13px; white-space: nowrap; }
.monc-rules-strip { margin-top: 16px; }
.monc-rules-lab { display: block; font-weight: 700; color: var(--ink); font-size: 14.5px; margin-bottom: 4px; }
.monc-rules-strip .mons-meta { display: block; margin-top: 10px; }
.monc-rule-inline { border-bottom: none; padding: 4px 0; gap: 10px; justify-content: flex-start; }
.monc-alert-row { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.monc-alert-row:last-child { border-bottom: none; }
.monc-alert-main { flex: 1; font-size: 13px; color: var(--muted); }
.monc-alert-state { font-size: 12.5px; color: var(--muted); }
.monc-rule { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); cursor: pointer; font-size: 14.5px; }
.monc-rule input { display: none; }
.monc-switch { flex: 0 0 auto; width: 42px; height: 24px; border-radius: 999px; background: var(--line); position: relative; transition: background .15s; }
.monc-switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: left .15s; }
.monc-rule input:checked + .monc-switch { background: var(--green); }
.monc-rule input:checked + .monc-switch::after { left: 21px; }
.monc-bar-row { display: flex; align-items: center; gap: 12px; padding: 5px 0; }
.monc-bar-lab { flex: 0 0 130px; font-size: 13px; color: var(--muted); }
.monc-bar-track { flex: 1; height: 10px; border-radius: 999px; background: var(--line); overflow: hidden; }
.monc-bar-fill { display: block; height: 100%; background: var(--teal); border-radius: 999px; width: var(--w, 0%); }
.monc-bar-alt { background: var(--orange); }
.monc-bar-val { flex: 0 0 44px; text-align: right; font-weight: 400; font-size: 13px; color: var(--muted); }
.monc-matrix-wrap { overflow-x: auto; }
.monc-matrix { border-collapse: collapse; width: 100%; font-size: 13px; }
.monc-matrix th, .monc-matrix td { padding: 7px 10px; border-bottom: 1px solid var(--line); text-align: left; }
.monc-cell { font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.monc-cell-yes { background: #e2f4e5; color: #1d7a35; }
.monc-cell-absent { background: var(--line); color: var(--muted); }
.monc-cell-comp { background: #fdf0d9; color: #9a6a12; max-width: 132px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: inline-block; vertical-align: middle; }
.monc-cell-none { color: var(--muted); font-size: 14.5px; }

/* Reports tab: one reading font (Kuang, 2026-10-15 — "dont need that
   many font for a simple display"). All body text is the silver 13px
   meta style; only card titles, sub-heads and numbers stay dark. */
[data-mpanel="reports"] #monc-rep-preview p { font-size: 13px; color: var(--muted); }
[data-mpanel="reports"] #monc-rep-preview strong { color: var(--ink); }
[data-mpanel="reports"] #monc-rep-preview h4 { font-size: 13px; color: var(--ink); margin: 14px 0 2px; }
[data-mpanel="reports"] .mons-list li { font-size: 13px; color: var(--muted); }
[data-mpanel="reports"] .monc-rule { font-size: 13px; }
[data-mpanel="reports"] .monc-table td { font-size: 13px; }
.monc-rep-actions { font-size: 13px; color: var(--muted); }

/* Change-log lines: chip and its text are one flex line, so the text
   always starts beside the chip on the same top line and wraps under
   itself — never drops below the chip (Kuang, 2026-10-15). */
.monc-change-line { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 3px; }
.monc-change-line:last-child { margin-bottom: 0; }
.monc-change-line .monc-chip { flex: none; margin-top: 0; }

/* Changes & alerts consistency pass (Kuang's batch, 2026-10-15):
   score chips and change chips share one height and top edge, so a
   "New" pill never sits higher than the score chip beside it; the
   Alert rules rows take the Change log's row size (14px, 8px). */
.monc-chip, .monc-dchip { display: inline-flex; align-items: center; justify-content: center; height: 20px; line-height: 1; }
.monc-rules-strip .monc-rule { font-size: 14.5px; padding: 8px 0; }

.switch { font-size: 13px; }


/* Public share page (moved out of share.html 2026-10-16 — every page on the stylesheet) */
.share-pg { font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; color: var(--ink); margin: 0; background: #F7F4EC; font-size: 13px; }
.share-pg .wrap { max-width: 760px; margin: 0 auto; padding: 28px 20px 60px; }
.share-pg .brandbar { display: flex; justify-content: space-between; align-items: center; border-bottom: 3px solid var(--teal); padding-bottom: 12px; }
.share-pg .brandname { font-size: 21px; font-weight: 800; color: var(--teal); }
.share-pg .brandname span { color: var(--orange); }
.share-pg .brandbar img { max-height: 40px; max-width: 180px; }
.share-pg h1 { font-size: 23px; margin: 20px 0 2px; }
.share-pg .sub { color: var(--muted); margin: 0 0 16px; }
.share-pg .card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px; margin: 14px 0; }
.share-pg .scoreband { display: flex; gap: 20px; align-items: center; }
.share-pg .scorebig { font-size: 50px; font-weight: 800; color: var(--teal); line-height: 1; }
.share-pg .gradechip { display: inline-block; color: #fff; font-weight: 800; border-radius: 8px; padding: 3px 12px; font-size: 16px; background: var(--teal); }
.share-pg .up { color: var(--green); font-weight: 700; }
.share-pg .down { color: var(--red); font-weight: 700; }
.share-pg h2 { font-size: 14px; color: var(--teal); text-transform: uppercase; letter-spacing: .05em; margin: 0 0 8px; }
.share-pg ul { margin: 0; padding-left: 18px; }
.share-pg li { margin: 3px 0; }
.share-pg .muted { color: var(--muted); }
.share-pg .foot { color: var(--muted); font-size: 12.5px; text-align: center; margin-top: 26px; }

.score-c { color: var(--c); }
.u-red { color: var(--red); }

.mons-sev { display: inline-flex; align-items: center; height: 24px; padding: 0 10px; font-size: 12px; }

/* Claude portal build (2026-10-16): x- layout helpers used by the generated screens.
   Presentation only — no behavior. Component styles stay in shared.css. */
.x-field { display: flex; flex-direction: column; gap: 4px; }
.x-field input { width: 100%; }
.x-full { width: 100%; justify-content: center; }
.x-row .show-pw { white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }

/* Claude portal build: home layout (from the generated screens). */
.x-pagehead { margin-bottom: 24px; }
.x-pagehead h1 { margin: 0; }
.x-grid12 { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px; }
.x-span12 { grid-column: span 12; }
.x-status { grid-column: span 12; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); grid-auto-rows: 1fr; gap: 16px; }
.x-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 16px; }
.x-card-head h2 { font-size: 17px; font-weight: 800; margin: 0; }
.x-link { display: inline-flex; align-items: center; gap: 4px; color: var(--teal); font-weight: 600; font-size: 13px; text-decoration: none; }
.x-value { font-size: 17px; font-weight: 800; margin: 0 0 4px; }
.x-label { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; color: var(--muted); margin: 0 0 8px; }
.x-mini { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.x-mini li { display: flex; justify-content: space-between; gap: 8px; }
.x-table { width: 100%; border-collapse: collapse; }
.x-table th { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; color: var(--muted); text-align: left; padding: 8px 16px; border-bottom: 1px solid var(--line, var(--border)); }
.x-table td { height: 48px; padding: 0 16px; border-bottom: 1px solid var(--line, var(--border)); }
.x-table tbody tr { cursor: pointer; }
.x-table tbody tr:hover { background: var(--bg-soft); }
.x-num { text-align: right; font-variant-numeric: tabular-nums; }
.x-score { font-weight: 800; }
.x-chev { width: 32px; color: var(--muted); }
.x-scanhint { margin: 8px 0 0; }
.x-hero-notes { list-style: none; padding: 0; margin: 24px 0 0; display: flex; flex-direction: column; gap: 8px; }
.x-hero-notes li { display: flex; gap: 8px; align-items: flex-start; }
.x-hero-notes[hidden] { display: none; }
.x-grid12 .wizard { max-width: none; margin: 0; }

/* Claude portal build: sites page + shared bits. */
.muted { color: var(--muted); }
.x-score { color: var(--c, inherit); }
.x-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-bottom: 16px; }
.x-search { position: relative; flex: 1 1 280px; max-width: 420px; display: block; }
.x-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.x-search input { width: 100%; }
.x-pager { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 24px; }
.x-pager[hidden] { display: none; }
.x-table-card { padding: 16px; }
.icobtn[disabled] { opacity: .4; cursor: default; }
.x-site-latest { display: flex; align-items: center; gap: 16px; }
.x-big-score { font-size: 36px; font-weight: 800; line-height: 1; color: var(--c, inherit); }
.x-site-latest-meta { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.pill.good { background: var(--green-bg); color: var(--ok); }
.pill.warn { background: var(--amber-bg); color: var(--orange-dark); }
.pill.bad { background: var(--red-bg); color: var(--red); }

/* Claude portal build: report recomposition. */
.x-mast { display: grid; grid-template-columns: 1fr auto 1.2fr; gap: 32px; align-items: center; position: relative; padding-top: 48px; }
.x-mast-actions { position: absolute; top: 16px; right: 16px; }
.x-mast-actions .report-actions { display: flex; gap: 8px; align-items: center; }
.x-mast .x-score { font-size: 54px; line-height: 1; }
.x-mast .x-score small { font-size: 17px; font-weight: 600; color: var(--muted); }
.x-head17 { font-size: 17px; font-weight: 800; margin: 0; }
.x-cats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; margin-top: 16px; }
.x-tile { display: flex; flex-direction: column; gap: 4px; padding: 16px; text-align: left; cursor: pointer; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.x-tile-num { font-size: 20px; font-weight: 800; color: var(--c, inherit); }
.x-section { margin-top: 32px; }
.x-stack { display: flex; flex-direction: column; gap: 16px; }
.x-grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); grid-auto-rows: 1fr; gap: 16px; }
.x-teaser { display: flex; align-items: center; gap: 16px; padding: 16px 24px; text-decoration: none; color: inherit; }
.x-fix-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.x-fix-head h3 { flex: 1; font-size: 17px; font-weight: 800; margin: 0; }
body.pg-report .rank-card { display: block; }
body.pg-report .mode-toggle { display: inline-flex; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
body.pg-report .mode-toggle button { padding: 0 16px; height: 32px; background: transparent; border: 0; font-weight: 600; font-size: 13px; cursor: pointer; color: var(--muted); }
body.pg-report .mode-toggle button.active { color: var(--teal); background: var(--bg-soft); }
.chips-list { display: flex; flex-wrap: wrap; gap: 8px; }
#x-mon-print { display: none; }
@media (max-width: 900px) { .x-cats { grid-template-columns: repeat(3, 1fr); } .x-mast { grid-template-columns: 1fr; } }
@media print {
  .x-mast-actions, .x-teaser { display: none !important; }
  .rep-panel { display: block !important; }
  .fix-collapsible[hidden] { display: block !important; }
  #x-mon-print { display: block; }
  #aeo-body { display: none; }
}

/* Report panels: only the active tab shows (the x-stack flex must not win). */
body.pg-report .rep-panel { display: none; }
body.pg-report .rep-panel.active { display: block; }
body.pg-report .rep-panel.x-stack.active { display: flex; }
body.pg-report .x-mast { padding-top: 64px; }
body.pg-report .plan-table td:nth-child(4) { white-space: nowrap; }
body.pg-report .pro-group-header { background: transparent; border: 0; padding: 0; }
body.pg-report .plan-box-msg { white-space: pre-wrap; }
.x-teaser { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
@media print { body.pg-report .rep-panel { display: block !important; } }
body.pg-report .x-mast { align-items: start; }
/* Masthead actions: their own right-aligned row above the grid cells —
   absolute positioning clipped the verdict at app content widths. */
body.pg-report .x-mast { padding-top: 24px; }
body.pg-report .x-mast-actions { position: static; grid-column: 1 / -1; justify-self: end; }

/* Portal design — monitoring (summary + detail + sales) */
.x-sub { margin: 4px 0 0; color: var(--muted); }
.x-allclear { display: flex; align-items: center; gap: 4px; color: var(--green); font-weight: 700; }
.x-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); grid-auto-rows: 1fr; gap: 16px; margin-bottom: 24px; }
.x-kpis-tight { margin-bottom: 0; }
.x-kpi { display: flex; flex-direction: column; gap: 4px; padding: 16px 24px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.x-kpi-lab { margin: 0; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.x-kpi-val { margin: 0; font-size: 20px; font-weight: 800; }
.x-kpi-sub { margin: 0; color: var(--muted); }
.x-card-head h3 { font-size: 17px; font-weight: 800; margin: 0; }
.x-table { width: 100%; border-collapse: collapse; }
.x-table th { padding: 0 8px 8px; text-align: left; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border-bottom: 1px solid var(--line); }
.x-table td { height: 48px; padding: 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.x-table tbody tr { position: relative; }
.x-table tbody tr:hover { background: var(--bg-soft); }
.x-table tfoot td { height: auto; border-bottom: 0; }
.x-table .x-num { text-align: right; }
.x-rowlink { color: inherit; font-weight: 700; text-decoration: none; }
.x-rowlink::after { content: ""; position: absolute; inset: 0; }
.x-above { position: relative; z-index: 1; width: 40px; }
.x-meta-line { display: block; color: var(--muted); }
.x-chev { width: 32px; color: var(--muted); }
.x-add { display: flex; align-items: center; gap: 8px; }
.x-add input { flex: 1; max-width: 320px; }
.x-offer { display: flex; flex-direction: column; gap: 16px; padding: 24px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.x-offer h2 { margin: 0 0 4px; font-size: 17px; font-weight: 800; }
.x-offer-row { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.x-plans { display: inline-flex; gap: 4px; }
.x-plans .mons-plan { border: 1.5px solid var(--border); border-radius: 999px; padding: 7px 14px; margin: 0; font-size: 13px; font-weight: 700; background: var(--surface); }
.x-plans .mons-plan-sel { border-color: var(--teal); color: var(--teal-ink); background: var(--bg-soft); }
.x-plans .mons-plan input { position: absolute; opacity: 0; pointer-events: none; }
.x-offer-act { display: flex; flex-direction: column; gap: 8px; align-items: flex-end; }
.x-offer-act .mons-tos { margin: 0; }
@media (max-width: 640px) { .x-offer-act { align-items: flex-start; } }
.x-back { display: inline-flex; align-items: center; gap: 4px; margin-bottom: 16px; }
.x-dhead { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 32px; margin-bottom: 24px; }
.x-dhead h1 { margin: 0; font-size: 30px; }
.x-bigscore { display: flex; align-items: center; gap: 8px; }
.x-score-num { font-size: 54px; line-height: 1; font-weight: 800; color: var(--c, inherit); }
@media (max-width: 900px) { .x-dhead { grid-template-columns: 1fr; } }
.x-split { display: grid; gap: 16px; grid-auto-rows: 1fr; }
.x-8-4 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.x-7-5 { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); grid-auto-rows: auto; }
.x-6-6 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 900px) { .x-8-4, .x-7-5, .x-6-6 { grid-template-columns: minmax(0, 1fr); } }
.x-row:has(> .x-row-lines) { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 16px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.x-row:has(> .x-row-lines):last-child { border-bottom: 0; }
.x-row-lines { display: flex; flex-direction: column; gap: 4px; }
.x-line { display: flex; align-items: center; gap: 8px; }
.x-up { color: var(--green); font-weight: 700; }
.x-down { color: var(--red); font-weight: 700; }
.x-deliv { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 16px; }
.monc-panel[hidden] { display: none; }

/* Portal design — tool pages */
.x-page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 8px; }
.x-page-head h1 { margin: 0; }
.x-head-sub { margin: 4px 0 0; color: var(--muted); }

/* Portal design — tokens & settings */
.x-row2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); grid-auto-rows: 1fr; gap: 16px; margin-bottom: 32px; }
.x-row3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); grid-auto-rows: 1fr; gap: 16px; margin-bottom: 32px; }
.x-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: 8px; }
.x-card-title { font-size: 17px; font-weight: 800; margin: 0 0 4px; }
.x-link { display: inline-flex; align-items: center; gap: 8px; }
.x-price { font-size: 20px; font-weight: 800; margin: 8px 0 4px; }
.x-pack .btn { margin-top: 16px; width: 100%; }
.x-sec-h { font-size: 17px; font-weight: 800; margin: 0 0 16px; }
.x-layout { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 32px; align-items: start; }
@media (max-width: 860px) { .x-layout { grid-template-columns: 1fr; } }
.x-subnav { display: flex; flex-direction: column; gap: 4px; position: sticky; top: 88px; }
.x-subnav a { display: flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 8px; font-weight: 700; color: inherit; text-decoration: none; }
.x-subnav a:hover { background: var(--bg-soft); }
.x-panel { margin-bottom: 32px; }
.x-panel-h { font-size: 17px; font-weight: 800; margin: 0 0 16px; }

/* Settings switch rows (from the design batch's settings page). */
.x-sw-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line, var(--border)); }
.x-sw-row:last-child { border-bottom: 0; }
.x-sw-row p { margin: 4px 0 0; color: var(--muted); }
/* Settings switch: visually-hidden native checkbox drives the track + knob. */
.x-switch { position: relative; display: inline-flex; flex: 0 0 auto; cursor: pointer; }
.x-switch-input { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; opacity: 0; appearance: none; -webkit-appearance: none; }
.x-switch-track { position: relative; display: block; width: 42px; height: 24px; border-radius: 999px; background: var(--line, var(--border)); transition: background .15s; }
.x-switch-track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: left .15s; }
.x-switch-input:checked + .x-switch-track { background: var(--green); }
.x-switch-input:checked + .x-switch-track::after { left: 21px; }
.x-switch-input:focus-visible + .x-switch-track { outline: 2px solid var(--teal); outline-offset: 2px; }
.x-switch-input:disabled + .x-switch-track { opacity: .5; }
.x-switch:has(.x-switch-input:disabled) { cursor: default; }
/* ===== Robots tool — Claude layout (Build | Check) ===== */
.x-ico{width:16px;height:16px;flex:none}
.x-picker{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.x-picker-sel{display:flex;align-items:center;gap:8px}
.x-tool-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(420px,100%),1fr));gap:32px;align-items:start}
.x-sticky{position:sticky;top:88px}
.x-field{margin-bottom:16px}
.x-from{font-size:12px;color:var(--muted);font-weight:600;margin-left:8px}
.x-rep-row{display:flex;gap:8px;align-items:center;margin-bottom:8px}
.x-rep-row .field-input{flex:1;margin:0}
.x-counts{display:flex;gap:8px;flex-wrap:wrap;margin:16px 0}
.x-icons{display:flex;gap:8px}
.x-full{margin-top:32px}
.x-mode{margin-bottom:24px}
.x-copied{color:var(--green)!important;border-color:var(--green)!important}
.bots{display:flex;flex-direction:column}
.bot-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:9px 0;border-bottom:1px solid var(--border)}
.bot-row:last-child{border-bottom:none}
.bot-name{font-weight:700}
.bot-opts{display:flex;gap:14px;flex:none}
.bot-opts .opt{display:inline-flex;align-items:center;gap:6px;cursor:pointer}
.bot-row-master{border-bottom:2px solid var(--border)}
.bot-row-master .bot-name{color:var(--muted);font-size:13px;text-transform:uppercase;letter-spacing:.5px}
.bot-row-master .opt{font-weight:600}
/* Master radios sit in the per-crawler radio columns: each label copies a bot
   label's geometry (radio + hidden "Allow"/"Block" at the same weight), and the
   "Allow all"/"Block all" text floats above, centered on its radio. */
body.pg-robots .bot-row-master{padding-top:28px}
body.pg-robots .bot-row-master .opt{font-weight:inherit}
body.pg-robots .bot-row-master .opt-dot{position:relative;display:inline-flex}
body.pg-robots .bot-row-master .opt-text{position:absolute;bottom:100%;left:50%;transform:translateX(-50%);margin-bottom:3px;white-space:nowrap;font-size:13px;font-weight:600;line-height:1.2}
body.pg-robots .bot-row-master .opt input{margin:0}
body.pg-robots .bot-row-master .opt-ghost{visibility:hidden}
.add-row-btn{margin-top:4px}
.type-tabs{display:flex;gap:8px;flex-wrap:wrap}
.type-tab{padding:8px 16px;border:1.5px solid var(--border);border-radius:999px;background:var(--surface);font:inherit;font-size:13px;font-weight:600;cursor:pointer;color:var(--muted)}
.type-tab.active{background:var(--teal);border-color:var(--teal);color:#fff}
.type-tab:hover:not(.active){border-color:var(--teal)}
body.pg-robotsval .line-table td.num{color:var(--muted);white-space:nowrap}
body.pg-robotsval .line-table td code{font-family:ui-monospace,"SF Mono",Menlo,Consolas,monospace;font-size:12.5px}

table.sites th .th-sort { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; letter-spacing: inherit; text-transform: inherit; }
table.sites th .th-sort:hover { color: var(--teal-6, var(--teal)); }
/* Home "Your sites": fixed layout so sorting/paging never moves the columns. */
table.sites { table-layout: fixed; }
table.sites th:nth-child(1) { width: 46%; }
table.sites th:nth-child(2) { width: 14%; }
table.sites th:nth-child(3) { width: 18%; }
table.sites th:nth-child(4) { width: 16%; }
table.sites th:nth-child(5) { width: 6%; }
table.sites td:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.brandrow img { height: 30px; width: auto; display: block; }

/* Portal Tools hub (portal/tools.html): each card is one link. */
body.pg-tools .x-tool-grid { margin-top: 24px; gap: 16px; align-items: stretch; }
body.pg-tools .x-tool-link { text-decoration: none; color: inherit; }
body.pg-tools .x-tool-link:hover { border-color: var(--teal); }
body.pg-tools .x-tool-link .x-card-head { margin-bottom: 8px; }
body.pg-tools .x-tool-link .x-ico { color: var(--muted); }
body.pg-tools .x-tool-link p { margin: 0; }

/* Portal tool pages ported from the old app (tool-llms, tool-schema-wizard,
   tool-schema-validator, tool-parity). The old pages' scoped rules
   (pg-llmsgen / pg-wizard / pg-schemaval / pg-parity) still style the
   tool bodies; these only fit them into the portal cards. */
body.pg-llms .section-card .sec-title { width: auto; max-width: 240px; }
body.pg-llms .output-pane pre, body.pg-schemawiz .output-pane pre { margin-top: 0; }
body.pg-schemawiz .type-tabs { margin-bottom: 16px; }
body.pg-schemavalidator .x-counts { margin-top: 0; }
body.pg-paritytool .parity-pane.x-card { border-radius: var(--radius); padding: 24px; }
body.pg-paritytool .parity-pane .x-card-head { margin-bottom: 8px; }
body.pg-paritytool .parity-pane .x-card-head .x-ico { color: var(--muted); }

/* Portal rail: "Client reports" is a menu, not a page (Kuang). A native
   <details> — the header opens/closes the sub-list, nothing navigates;
   the sub-links go out to the client handouts. Collapsed by default. */
.navgroup > summary { list-style: none; cursor: pointer; user-select: none; }
.navgroup > summary::-webkit-details-marker { display: none; }
.navgroup > summary::marker { content: ""; }
.navgroup > summary:hover { color: var(--ink); }
.navgroup[open] > summary { color: var(--ink); }
.navgroup .navchev { width: 14px; height: 14px; flex: none; margin-left: auto; transition: transform .15s ease; }
.navgroup[open] .navchev { transform: rotate(180deg); }
.navsub { display: flex; flex-direction: column; gap: 1px; margin: 2px 0 6px 18px; padding-left: 12px; border-left: 2px solid var(--border); }
.navgroup:not([open]) .navsub { display: none; }
.navsub-link { display: block; padding: 7px 10px; border-radius: 8px; font-size: 12.5px; font-weight: 500; line-height: 1.35; color: var(--muted); text-decoration: none; }
.navsub-link:hover { background: var(--bg-soft); color: var(--ink); }

/* Tool verdicts: ONE result banner for every tool (robots, llms.txt,
   schema validator, parity) — Kuang, 2026-10-16. Pill spec (rounded,
   pill tints, no border) + the small circular icon (20px solid dot,
   white glyph, mx-dot colors): is-pass ✓, is-fail ✕, is-warn !.
   No filled bars, no emoji. Block + absolute icon (not flex) so an
   inline <strong> lead stays in the same text run. */
.tool-verdict { position: relative; display: block; width: fit-content; max-width: 100%; box-sizing: border-box; margin-bottom: 16px; padding: 6px 16px 6px 38px; border-radius: 16px; font-size: 14.5px; font-weight: 600; line-height: 20px; color: var(--ink); background: var(--soft-2); }
.tool-verdict:empty { display: none; }
.tool-verdict::before { position: absolute; left: 8px; top: 6px; width: 20px; height: 20px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; line-height: 1; color: #fff; }
.tool-verdict strong { font-weight: 700; }
.tool-verdict.is-pass { background: var(--green-bg); }
.tool-verdict.is-pass::before { content: "\2713"; background: #1e7e34; }
.tool-verdict.is-fail { background: var(--red-bg); }
.tool-verdict.is-fail::before { content: "\2715"; background: #b3362b; }
.tool-verdict.is-warn { background: var(--amber-bg); }
.tool-verdict.is-warn::before { content: "!"; background: #d97706; }

/* Tool action buttons with a leading icon: icon + label on one line,
   and the footer note shrinks instead of the button (the schema
   validator's "Validate schema" wrapped its icon above the word). */

/* Portal top bar (Kuang, 2026-10-16): the app bar on every portal page —
   tokens pill + Buy, Monitoring pill, New scan, theme toggle, profile. */
.apphead a.profile-btn { text-decoration: none; }
.apphead .token-pill svg { flex: none; }

/* Scan wizard modal: lives here (not Home's page styles) because the top
   bar's New scan opens it on every portal page. */
.scan-modal-backdrop { position: fixed; inset: 0; background: rgba(13, 33, 44, .48); display: flex; align-items: flex-start; justify-content: center; padding: 6vh 16px 16px; z-index: 60; overflow-y: auto; }
.scan-modal-backdrop[hidden] { display: none; }
.scan-modal-card { position: relative; width: min(680px, 100%); background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 38px 24px 24px; box-shadow: 0 24px 60px rgba(13, 33, 44, .25); }
.scan-modal-card .card { padding: 0; box-shadow: none; }
.scan-modal-card .wizstep { margin-top: 16px; }
.scan-modal-card .x-card-head h2 { font-size: 17px; font-weight: 800; margin: 0; }
.scan-modal-card .scanbar { display: flex; gap: 10px; }
.scan-modal-card .scanbar input { flex: 1; }
.scan-modal-x { position: absolute; top: 6px; right: 8px; z-index: 2; width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center; border-radius: 8px; color: var(--muted); background: transparent; border: 0; cursor: pointer; }
.scan-modal-x svg { width: 16px; height: 16px; }

/* Portal report (portal/report.html): score + band on one row, the
   web-person hand-off, What AI sees, and the Local tab. Bar lengths come
   in as --w / --h set from the report data. */
.p-rep-scorerow { display: flex; align-items: center; justify-content: center; gap: 12px; }
.p-rep-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); gap: 16px; }
.p-rep-gap { margin-top: 16px; }
.p-rep-cardhead { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.p-rep-cardhead h3 { font-size: 17px; font-weight: 800; margin: 0; }
.p-rep-flush { margin: 0 0 10px; }
.p-rep-subhead { margin: 16px 0 8px; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); }
.p-rep-guide { margin: 10px 0 0; font-size: 13px; }
.p-rep-guide a { color: var(--teal); font-weight: 600; text-decoration: none; }
.p-rep-guide a:hover { text-decoration: underline; }
.p-rep-err { margin: 0 0 10px; color: var(--red); font-size: 13px; }
.p-rep-offscreen { position: fixed; top: 0; left: 0; opacity: 0; pointer-events: none; }

/* Fixes: who filter + group headings */
.p-rep-who { display: inline-flex; margin-left: auto; border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.p-rep-who[hidden] { display: none; }
.p-rep-who span { padding: 6px 14px; font-size: 12.5px; font-weight: 600; color: var(--muted); cursor: pointer; }
.p-rep-who span.on { background: var(--teal); color: #fff; }
.p-rep-grouphead { margin: 24px 0 0; font-size: 13px; color: var(--muted); }
.p-rep-grouphead strong { color: var(--ink); }
#p-rep-findings > [data-who][hidden], #p-rep-plan-body tr[hidden] { display: none; }

/* Web-person hand-off */
.p-rep-wp { margin-top: 16px; }
.p-rep-msg { margin: 0; max-height: 280px; overflow: auto; white-space: pre-wrap; word-break: break-word; font-family: inherit; font-size: 13px; line-height: 1.5; color: var(--ink); background: var(--bg-soft); border-radius: 10px; padding: 14px 16px; }
.p-rep-matrix { margin-top: 16px; overflow-x: auto; }

/* What AI sees */
.p-rep-wbar { margin-bottom: 14px; }
.p-rep-wbar-top { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 6px; font-size: 13px; }
.p-rep-wbar-track { flex: none; height: 14px; }

/* Local */
.p-rep-compadd { margin-bottom: 4px; }
#p-comp-list[hidden] { display: none; }
#p-comp-list li { grid-template-columns: 1fr auto; }
.p-rep-vbar { height: var(--h, 0%); }
.p-rep-ranknote { margin: 12px 0 0; font-size: 13.5px; }
.p-rep-checklist { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; }
.p-rep-nap { display: grid; grid-template-columns: 80px 1fr; gap: 6px 12px; margin: 0; font-size: 13.5px; }
.p-rep-nap dt { color: var(--muted); }
.p-rep-nap dd { margin: 0; font-weight: 600; }

/* Portal settings (portal/settings.html, approved mock 2026-10-16): the
   rail swaps to Settings mode (back link + SETTINGS label + four
   sections) and one section shows at a time. Scoped to body.pg-settings
   so the other portal pages keep their own rail styles untouched. */
body.pg-settings { margin: 0; }
body.pg-settings .shell { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; }
body.pg-settings .side { background: var(--surface); border-right: 1px solid var(--border); padding: 20px 14px; display: flex; flex-direction: column; gap: 2px; }
body.pg-settings .side .brandrow { display: flex; align-items: center; gap: 10px; padding: 2px 10px 18px; }
body.pg-settings .navitem { display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-radius: 10px; font-size: 13px; font-weight: 600; color: var(--muted); text-decoration: none; }
body.pg-settings .navitem:hover { color: var(--ink); }
body.pg-settings .navitem.on { background: var(--bg-soft); color: var(--ink); }
body.pg-settings .navitem svg { width: 17px; height: 17px; flex: none; }
body.pg-settings .rail-back { margin-bottom: 10px; }
body.pg-settings .rail-back svg { width: 16px; height: 16px; }
body.pg-settings .rail-back:hover { background: var(--bg-soft); color: var(--ink); }
body.pg-settings .rail-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 6px 10px; }
body.pg-settings .apphead { height: 64px; display: flex; align-items: center; justify-content: flex-end; gap: 14px; padding: 0 28px; border-bottom: 1px solid var(--border); background: var(--surface); }
body.pg-settings .content { padding: 28px 32px 40px; max-width: 1200px; }
.p-set-col { max-width: 720px; }
.p-set-panel[hidden] { display: none; }
.p-set-h1 { font-size: 30px; margin: 0 0 4px; }
.p-set-sub { color: var(--muted); margin: 0 0 24px; }
.p-set-cardsub { color: var(--muted); margin: 4px 0 12px; }
.p-set-note { color: var(--muted); margin: 12px 0 0; }

/* ===== Portal client reports: study.html + papers.html (body.pg-pdoc) =====
   The old app's study handout and GEO papers in the portal shell. The
   document styles are the existing body.pg-agencyrep / body.pg-papers
   rules above (the pages carry those classes too); this block adds the
   shell (same as Settings — no private <style> block), the chart colours
   that were SVG attributes, and print rules that drop the shell. */
body.pg-pdoc { margin: 0; }
body.pg-pdoc .shell { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; }
body.pg-pdoc .side { background: var(--surface); border-right: 1px solid var(--border); padding: 20px 14px; display: flex; flex-direction: column; gap: 2px; }
body.pg-pdoc .side .brandrow { display: flex; align-items: center; gap: 10px; padding: 2px 10px 18px; }
body.pg-pdoc .navitem { display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-radius: 10px; font-size: 13px; font-weight: 600; color: var(--muted); text-decoration: none; }
body.pg-pdoc .navitem.on { background: var(--bg-soft); color: var(--ink); }
body.pg-pdoc .navitem svg { width: 17px; height: 17px; flex: none; }
body.pg-pdoc .side .sp { flex: 1; }
body.pg-pdoc .apphead { height: 64px; display: flex; align-items: center; justify-content: flex-end; gap: 14px; padding: 0 28px; border-bottom: 1px solid var(--border); background: var(--surface); }
body.pg-pdoc .content { padding: 28px 32px 40px; max-width: 1200px; }
/* the paper on screen is marked in the rail */
body.pg-pdoc .navsub-link.on { background: var(--bg-soft); color: var(--ink); font-weight: 600; }
/* page chrome = tool-page standard: .x-page-head with .page-h1 + .x-head-sub,
   Download PDF as an .icobtn on the right (same as the tools' Download) */
/* papers: the Download icon sits right beside the heading block, not at the far edge */
body.pg-papers .doc-head .x-page-head { justify-content: flex-start; align-items: center; }
/* study: same placement — the Download button sits beside the heading
   block, not at the far right edge (Kuang, 2026-10-17) */
body.pg-agencyrep .doc-head .x-page-head { justify-content: flex-start; align-items: center; }
body.pg-pdoc .profile-nudge { display: none; margin-top: 16px; padding: 12px 16px; background: var(--bg-soft); border: 1px solid var(--border); border-radius: var(--radius); color: var(--ink-2); font-size: 13px; line-height: 1.55; }
body.pg-pdoc .profile-nudge a { color: var(--teal); font-weight: 700; }
body.pg-pdoc .profile-nudge.show { display: block; }
/* study bar chart */
body.pg-pdoc .ch-g { font-family: inherit; font-size: 13px; }
body.pg-pdoc .ch-lbl { fill: var(--ink-2); }
body.pg-pdoc .ch-val { fill: var(--doc-ink); font-weight: 700; }
body.pg-pdoc .ch-track { fill: #eef3f5; }
body.pg-pdoc .ch-bar { fill: #1e5f7b; }
body.pg-pdoc .ch-bar.ch-bar-hot { fill: #ff7e00; }
/* papers: donut, gauges, pictogram glyphs */
body.pg-pdoc .donut-box svg { width: 150px; height: 150px; }
body.pg-pdoc .donut-track, body.pg-pdoc .donut-arc { fill: none; stroke-width: 10; }
body.pg-pdoc .donut-track { stroke: var(--line-2); }
body.pg-pdoc .donut-arc { stroke: #ff7e00; stroke-linecap: round; }
body.pg-pdoc .gauge svg { width: 86px; height: 86px; }
body.pg-pdoc .gauge-track, body.pg-pdoc .gauge-arc { fill: none; stroke-width: 9; }
body.pg-pdoc .gauge-track { stroke: var(--line-2); }
body.pg-pdoc .gauge-arc { stroke-linecap: round; }
body.pg-pdoc .gauge-teal { stroke: #1e6f67; }
body.pg-pdoc .gauge-orange { stroke: #ff7e00; }
body.pg-pdoc .gauge-amber { stroke: #f5a623; }
body.pg-pdoc .pictogram svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
/* Print: only the document prints, sized to the paper (the global @page
   letter box). Every ancestor of the sheet drops to a plain block at auto
   width — no flex body, no grid shell, no screen max-widths/padding — so
   the sheet lays out at the printable width instead of the screen width;
   nothing inside may be wider than the sheet. */
@media print {
  body.pg-pdoc .side, body.pg-pdoc .apphead, body.pg-pdoc .no-print { display: none !important; }
  html:has(body.pg-pdoc), body.pg-pdoc { display: block !important; width: auto !important; min-width: 0 !important; height: auto !important; min-height: 0 !important; margin: 0 !important; padding: 0 !important; overflow: visible !important; background: #fff !important; }
  body.pg-pdoc .shell, body.pg-pdoc .shell > div, body.pg-pdoc .content, body.pg-pdoc #shareable-doc { display: block !important; width: auto !important; min-width: 0 !important; max-width: none !important; min-height: 0 !important; margin: 0 !important; padding: 0 !important; overflow: visible !important; }
  body.pg-pdoc .doc-sheet { box-sizing: border-box !important; width: 100% !important; max-width: 100% !important; margin: 0 !important; padding: 0 0.12in !important; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; overflow: visible !important; overflow-wrap: break-word; }
  body.pg-pdoc .doc-sheet * { max-width: 100%; min-width: 0; }
  /* papers text column keeps its 240px floor so it wraps under the chart
     instead of collapsing to a few px (one word per line) */
  body.pg-pdoc .doc-sheet .u-flex240 { min-width: 240px; }
  /* masthead right block shrinks and wraps instead of running off the edge */
  body.pg-pdoc .masthead .who { min-width: 0; max-width: 100%; }
  body.pg-pdoc .masthead .who .aname, body.pg-pdoc .masthead .who .aaddr { overflow-wrap: break-word; max-width: 100%; }
  body.pg-pdoc .doc-sheet img, body.pg-pdoc .doc-sheet svg { max-width: 100% !important; }
  /* page breaks: blocks never split, headings stay with what follows */
  body.pg-pdoc .masthead, body.pg-pdoc .stat-card, body.pg-pdoc .finding, body.pg-pdoc .chart-wrap, body.pg-pdoc .cta-block,
  body.pg-pdoc .chart-row, body.pg-pdoc .gauge, body.pg-pdoc .step, body.pg-pdoc .dp-row, body.pg-pdoc .l-row,
  body.pg-pdoc .c-row, body.pg-pdoc table.bots tr { break-inside: avoid; }
  body.pg-pdoc .doc-title, body.pg-pdoc .sec-title, body.pg-pdoc .sec-sub, body.pg-pdoc .kicker { break-after: avoid; }
  body.pg-pdoc .ch-track, body.pg-pdoc .ch-bar, body.pg-pdoc .donut-arc, body.pg-pdoc .gauge-arc { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* ---------- Customer invoice (tokens.html?invoice=CR-…) ----------
   Header = the SERAVERRA logo (same artwork as the rail) + division line.
   Dark theme swaps to the dark logo on screen, same trick as the rail. */
.inv-logo { height: 34px; width: auto; display: block; }
.inv-division { font-size: 13px; color: var(--ink-2); margin: 8px 0 0; }
:root[data-theme="dark"] .inv-logo { object-position: -99999px 0; background: url("seraverra-logo-dark.png") center / contain no-repeat; }
/* Print = the invoice only, same discipline as the report sheets: the shell
   (rail, top bar), the billing page behind it and the Back/Download
   controls are dropped; every ancestor of the card becomes a plain block at
   auto width so the card lays out at the printable width of the @page
   letter box, nothing clipped. Only applies while the invoice view is open. */
@media print {
  body:has(#invoice-view:not([hidden])) :is(.side, .apphead, #tokens-main),
  #invoice-view > :not(.invoice-card) { display: none !important; }
  html:has(#invoice-view:not([hidden])), body:has(#invoice-view:not([hidden])) { display: block !important; width: auto !important; min-width: 0 !important; height: auto !important; min-height: 0 !important; margin: 0 !important; padding: 0 !important; overflow: visible !important; background: #fff !important; }
  body:has(#invoice-view:not([hidden])) :is(.shell, .shell > div, .content, #invoice-view) { display: block !important; width: auto !important; min-width: 0 !important; max-width: none !important; min-height: 0 !important; margin: 0 !important; padding: 0 !important; overflow: visible !important; }
  #invoice-view .invoice-card { box-sizing: border-box !important; width: 100% !important; max-width: 100% !important; margin: 0 !important; padding: 0 0.12in !important; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; background: #fff !important; overflow: visible !important; overflow-wrap: break-word; break-inside: avoid; }
  #invoice-view .invoice-card * { max-width: 100%; min-width: 0; }
  :root[data-theme="dark"] .inv-logo { object-position: 50% 50%; background: none; }
}

/* ---------- Text inputs: ONE spec (Kuang 2026-10-16) ----------
   Every text field, search box, textarea and select in the portal. Older
   per-page/per-tool input rules were deleted or cut down to layout only
   (width/flex); nothing else may set an input's border, radius, padding,
   font or focus. :root raises this above the page <style> blocks.
   Focus = teal border + a soft ring drawn with box-shadow, so focusing a
   field can never change its size or move the layout around it (border
   width and padding are identical in every state). 40px tall, same as a
   button. */
:root :is(input:not([type="checkbox"], [type="radio"], [type="file"], [type="range"], [type="hidden"], [type="submit"], [type="button"], [type="reset"], [type="image"], [type="color"]), textarea, select) {
  box-sizing: border-box; margin: 0;
  padding: 9px 14px; border: 1px solid var(--border); border-radius: 10px;
  background: var(--surface); color: var(--ink);
  font: inherit; font-size: 14.5px; font-weight: 400; line-height: 20px;
  outline: none; box-shadow: none; transition: border-color .15s, box-shadow .15s;
}
:root :is(input:not([type="checkbox"], [type="radio"], [type="file"], [type="range"], [type="hidden"], [type="submit"], [type="button"], [type="reset"], [type="image"], [type="color"]), textarea, select):focus {
  border-color: var(--teal); box-shadow: 0 0 0 3px color-mix(in srgb, var(--teal) 22%, transparent); outline: none;
}
:root :is(input, textarea)::placeholder { color: var(--muted); opacity: 1; }
:root :is(input, textarea, select):disabled { opacity: .6; cursor: not-allowed; }
/* phones: 16px text stops iOS zooming the page when a field is tapped */
@media (pointer: coarse) { :root :is(input:not([type="checkbox"], [type="radio"], [type="file"], [type="range"], [type="hidden"]), textarea, select) { font-size: 16px; } }
/* layout exception: the search box leaves room for its magnifier icon */
:root .x-search input { padding-left: 36px; }

/* ---------- Cards: ONE spec (Kuang 2026-10-16) ----------
   Every portal card (.card, alone or with .x-card; the settings .pf-card
   list card) is the same box: surface, 1px border, 12px radius, 24px
   inset. .pf-card's rows carry 18px of their own, so its block padding is
   the remainder — same visual inset. Head / body / foot stack in a
   column with the foot pinned to the bottom. A foot that hosts an inline
   form (Tokens: Redeem a code) reserves one control row (40px) so opening
   the form never grows the card.
   Cards placed in a row always end level: every card row stretches its
   cards to the tallest one. Exception: sticky output panes (tool pages)
   keep their own height so they can follow the scroll. */
.card, .pf-card { box-sizing: border-box; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: none; }
.pf-card { padding-block: 6px; margin-bottom: 20px; }
.x-card { display: flex; flex-direction: column; }
.x-card-body { flex: 1; }
.x-card-foot { margin-top: auto; padding-top: 16px; display: flex; align-items: center; gap: 8px; }
.x-card-foot:has(form) { min-height: 56px; }
.x-card-foot > form { margin-top: 0 !important; } /* the page's inline 8px top gap would make the row 48px */
:is(.x-row, .statrow, .p-rep-grid, .x-kpis, .x-split, .x-grid22, .x-tool-grid, .x-row2, .x-row3, .x-grid2, .x-status, .x-deliv, .monc-reports-grid, .monc-two-eq, .aeo-rec-two) { align-items: stretch; }
:is(.x-row, .statrow, .p-rep-grid, .x-kpis, .x-split, .x-grid22, .x-tool-grid, .x-row2, .x-row3, .x-grid2, .x-status, .x-deliv) > :is(.card, .x-card, .x-kpi) { height: auto; margin: 0; align-self: stretch; }
.x-tool-grid > .x-sticky { align-self: start; }

/* ---------- Rail logo follows the theme ----------
   Light: seraverra-logo.png (the <img> in every page's .brandrow).
   Dark: the same <img> box paints seraverra-logo-dark.png instead — the
   light file is pushed out of its box with object-position and the dark
   file is drawn as the box background (same 1380x290 artwork, so the box
   size never changes). Driven by the existing data-theme="dark" switch;
   no page markup involved. */
:root[data-theme="dark"] .brandrow img { object-position: -99999px 0; background: url("seraverra-logo-dark.png") center / contain no-repeat; }
@media print { :root[data-theme="dark"] .brandrow img { object-position: 50% 50%; background: none; } }

/* ---------- Rendered-PDF download buttons (portal-download.js) ----------
   Working state while the server prepares the file (study, papers, invoice). */
.is-busy { cursor: progress; opacity: .65; }
.icobtn.is-busy svg { animation: pdl-pulse 1s ease-in-out infinite; }
@keyframes pdl-pulse { 50% { opacity: .3; } }
/* Top-bar Log out (Kuang, 2026-10-17): visible, not buried in settings.
   Same 40px height and muted -> teal hover as the theme toggle. */
.logout-btn {
  display: inline-flex; align-items: center; gap: 7px; height: 40px; padding: 0 12px; flex: none;
  border-radius: 10px; border: 1px solid transparent; background: none; cursor: pointer;
  color: var(--muted); font: inherit; font-size: 14px; font-weight: 600;
}
.logout-btn:hover { color: var(--teal); background: var(--bg-soft); }
.logout-btn svg { width: 19px; height: 19px; flex: none; }
