:root {
  color-scheme: light;
  --ink: #17211b;
  --muted: #66726b;
  --surface: #ffffff;
  --canvas: #f3f6f2;
  --line: #dfe6df;
  --brand: #176b45;
  --brand-dark: #0d5032;
  --brand-soft: #e4f3e9;
  --success: #137a45;
  --warning: #a96c00;
  --critical: #b42318;
  --info: #175cd3;
  --shadow: 0 1px 2px rgba(20, 36, 27, 0.06), 0 8px 28px rgba(20, 36, 27, 0.04);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 90% -10%, rgba(91, 175, 118, 0.12), transparent 30rem),
    var(--canvas);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.5;
}

button, input, select { font: inherit; }
a { color: inherit; }

.app-shell {
  width: min(1220px, calc(100% - 40px));
  margin: 0 auto;
  padding: 22px 0 64px;
}

.app-shell-narrow { width: min(900px, calc(100% - 40px)); }
.page-stack { display: grid; min-width: 0; gap: 24px; }
.page-stack > * { min-width: 0; }

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 2px 22px;
}

.brand-lockup { display: flex; align-items: center; gap: 11px; }
.brand-lockup > div { display: grid; line-height: 1.25; }
.brand-lockup strong { font-size: 15px; letter-spacing: -0.01em; }
.brand-lockup span:not(.brand-mark) { color: var(--muted); font-size: 12px; }

.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(145deg, #217b52, #0c4b2f);
  color: #fff;
  font-weight: 800;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.topnav { display: flex; align-items: center; gap: 5px; }
.topnav a { padding: 8px 12px; border-radius: 8px; color: var(--muted); font-weight: 650; text-decoration: none; }
.topnav a:hover, .topnav a.active { background: rgba(255, 255, 255, 0.75); color: var(--ink); }

.hero-row { display: flex; align-items: end; justify-content: space-between; gap: 28px; padding: 30px 0 8px; }
.hero-row.compact { padding-top: 18px; }
.hero-row h1 { max-width: 720px; margin: 4px 0 7px; font-size: clamp(28px, 4vw, 44px); line-height: 1.08; letter-spacing: -0.04em; }
.hero-row.compact h1 { font-size: 34px; }
.lede { max-width: 690px; margin: 0; color: var(--muted); font-size: 16px; }
.eyebrow { margin: 0 0 5px; color: var(--brand); font-size: 11px; font-weight: 800; letter-spacing: 0.11em; text-transform: uppercase; }
.subdued { color: var(--muted); }

.button {
  display: inline-flex;
  min-height: 39px;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 8px 14px;
  font-weight: 720;
  text-decoration: none;
  cursor: pointer;
}

.button-primary { background: var(--brand); color: #fff; box-shadow: 0 1px 1px rgba(0, 0, 0, 0.08); }
.button-primary:hover { background: var(--brand-dark); }
.button-primary:disabled { opacity: 0.55; cursor: wait; }
.button-secondary { border-color: var(--line); background: #fff; color: var(--ink); }

.card { border: 1px solid rgba(205, 217, 207, 0.9); border-radius: 16px; background: var(--surface); box-shadow: var(--shadow); }
.card-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 22px; border-bottom: 1px solid var(--line); }
.card-header h2, .section-heading h2, .scan-summary h2 { margin: 0; font-size: 18px; letter-spacing: -0.02em; }

.banner { display: flex; align-items: center; justify-content: space-between; gap: 18px; border: 1px solid; border-radius: 12px; padding: 12px 14px; }
.banner > div { display: grid; }
.banner span { color: var(--muted); }
.banner-success { border-color: #a9d7b8; background: #ecf8f0; }
.banner-critical { border-color: #f0b5af; background: #fff0ee; color: #7a271a; }
.banner-info { border-color: #b8cdf5; background: #f1f6ff; }
.usage-pill { display: inline-flex; align-items: center; gap: 4px; border-radius: 99px; padding: 7px 11px; background: #fff; color: var(--brand); font-size: 12px; font-weight: 750; text-decoration: none; white-space: nowrap; }

.plan-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; align-items: stretch; }
.plan-card { display: flex; min-width: 0; flex-direction: column; padding: 22px; position: relative; }
.plan-card-featured { border-color: #69ae82; box-shadow: 0 0 0 2px rgba(23, 107, 69, 0.09), var(--shadow); }
.popular-badge { position: absolute; top: 14px; right: 14px; border-radius: 99px; padding: 4px 7px; background: var(--brand-soft); color: var(--brand); font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.plan-card h2 { margin: 5px 0 8px; color: var(--muted); font-size: 14px; font-weight: 650; }
.plan-card h2 span { color: var(--ink); font-size: 30px; letter-spacing: -.04em; }
.plan-description { min-height: 66px; margin: 0; color: var(--muted); }
.plan-card ul { display: grid; gap: 9px; margin: 18px 0 24px; padding: 0; list-style: none; }
.plan-card li { padding-left: 20px; position: relative; }
.plan-card li::before { content: "✓"; position: absolute; left: 0; color: var(--success); font-weight: 850; }
.plan-card form, .plan-card form .button, .plan-card > .button { width: 100%; margin-top: auto; }
.button-disabled, .button:disabled { opacity: .58; cursor: not-allowed; }
.billing-footnote { margin: 0; color: var(--muted); font-size: 12px; text-align: center; }

.score-grid { display: grid; grid-template-columns: 1.25fr repeat(3, 1fr); gap: 14px; }
.score-card, .metric-card { min-height: 162px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: var(--shadow); padding: 21px; }
.score-card-primary { display: flex; align-items: center; justify-content: space-between; gap: 14px; background: linear-gradient(145deg, #163f2c, #0b2d1e); color: #fff; border: none; }
.metric-label { margin: 0; color: var(--muted); font-size: 12px; font-weight: 730; letter-spacing: 0.02em; }
.score-card-primary .metric-label { color: #b9d9c5; }
.score-number { margin: 8px 0 0; font-size: 46px; line-height: 1; font-weight: 780; letter-spacing: -0.05em; }
.score-number span, .metric-number span { margin-left: 4px; color: #b9d9c5; font-size: 14px; font-weight: 600; letter-spacing: 0; }
.metric-number { margin: 18px 0 6px; font-size: 29px; line-height: 1.05; font-weight: 760; letter-spacing: -0.04em; }
.metric-number span { color: var(--muted); }
.metric-note { margin: 0; color: var(--muted); font-size: 12px; }

.score-ring {
  --ring-color: #5ad18a;
  display: grid;
  width: 88px;
  height: 88px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--ring-color) calc(var(--score) * 1%), rgba(255, 255, 255, 0.15) 0);
  position: relative;
}
.score-ring::after { content: ""; position: absolute; inset: 8px; border-radius: 50%; background: #123824; }
.score-ring span { z-index: 1; font-size: 22px; font-weight: 800; }

.content-grid { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(270px, 0.7fr); gap: 16px; }
.category-list { display: grid; gap: 16px; padding: 22px; }
.category-row { display: grid; grid-template-columns: 140px minmax(100px, 1fr) 34px; align-items: center; gap: 14px; }
.category-row > span { font-weight: 650; }
.category-row > strong { text-align: right; font-variant-numeric: tabular-nums; }
.progress { height: 8px; overflow: hidden; border-radius: 99px; background: #edf0ed; }
.progress span { display: block; height: 100%; border-radius: inherit; background: var(--success); }
.progress .tone-warning { background: #d69e2e; }
.progress .tone-critical { background: #d14b3d; }

.scan-summary { padding: 22px; }
.scan-summary dl { display: grid; gap: 0; margin: 18px 0; }
.scan-summary dl div, .evidence-list div { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.scan-summary dt, .evidence-list dt { color: var(--muted); }
.scan-summary dd, .evidence-list dd { margin: 0; font-weight: 720; text-align: right; }

.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin: 8px 0 14px; }
.section-actions { display: flex; align-items: center; gap: 9px; }
.ai-badge, .badge { display: inline-flex; align-items: center; border-radius: 99px; font-size: 11px; font-weight: 800; }
.ai-badge { padding: 6px 9px; background: #eee9ff; color: #5634a5; }
.finding-list { display: grid; gap: 12px; }
.finding { display: grid; grid-template-columns: 46px minmax(0, 1fr) 170px; overflow: hidden; }
.finding-rank { display: grid; place-items: start center; padding-top: 22px; background: #f8faf8; border-right: 1px solid var(--line); color: var(--muted); font-size: 15px; font-weight: 800; }
.finding-body { min-width: 0; padding: 19px 21px; }
.finding-body h3 { margin: 7px 0 5px; font-size: 17px; line-height: 1.3; letter-spacing: -0.015em; }
.finding-body > p { margin: 0; color: var(--muted); }
.finding-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; }
.badge { padding: 3px 7px; text-transform: uppercase; letter-spacing: 0.05em; }
.badge-critical { background: #fee4e2; color: #912018; }
.badge-high { background: #ffead5; color: #93370d; }
.badge-medium { background: #fef0c7; color: #854a0e; }
.badge-low { background: #e8eef9; color: #344b73; }
.recommendation { display: grid; gap: 2px; margin-top: 13px; padding: 11px 13px; border-left: 3px solid #54a975; border-radius: 0 8px 8px 0; background: #f3f9f5; }
.recommendation strong { font-size: 11px; color: var(--brand); text-transform: uppercase; letter-spacing: 0.06em; }
.recommendation span { color: #34423a; }
.finding-impact { display: flex; flex-direction: column; align-items: flex-end; padding: 20px; border-left: 1px solid var(--line); background: #fcfdfc; text-align: right; }
.finding-impact > span { color: var(--muted); font-size: 11px; }
.finding-impact > strong { margin-top: 4px; font-size: 18px; }
.finding-impact > small { color: var(--muted); }
.finding-impact form { width: 100%; margin-top: auto; padding-top: 18px; }
.status-select { width: 100%; border: 1px solid var(--line); border-radius: 8px; background: #fff; padding: 7px 9px; color: var(--ink); }
.finding-impact .issue-status { margin-top: auto; }
.finding-impact .finding-fix-link { width: 100%; margin-top: 8px; font-size: 12px; }

.fix-panel { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 10px; }
.fix-panel summary { width: fit-content; color: var(--brand); font-weight: 750; cursor: pointer; }
.fix-panel > p { color: var(--muted); }
.fix-panel ol { margin: 10px 0; padding-left: 20px; }
.copy-block { margin: 12px 0; border: 1px solid #d8d0f0; border-radius: 10px; padding: 12px; background: #faf8ff; }
.copy-block > span { display: block; margin-bottom: 5px; color: #6840b6; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; }
.copy-block p { margin: 0; }
.caution { padding: 9px 11px; border-radius: 8px; background: #fff8e8; color: #725316 !important; }
.evidence-list { display: grid; max-width: 580px; margin: 12px 0 0; font-size: 12px; }
.evidence-list div { padding: 6px 0; }

.catalog-group-count { border-radius: 99px; padding: 6px 10px; background: var(--brand-soft); color: var(--brand); font-size: 12px; font-weight: 760; white-space: nowrap; }
.catalog-issue-list { display: grid; gap: 12px; }
.catalog-issue { padding: 20px 22px; }
.catalog-issue > p { margin: 8px 0 0; color: var(--muted); }
.catalog-issue-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.catalog-issue-header > strong { font-variant-numeric: tabular-nums; white-space: nowrap; }
.catalog-issue-header > strong span { color: var(--muted); font-weight: 620; }
.catalog-issue-title { display: flex; min-width: 0; align-items: center; gap: 9px; }
.catalog-issue-title h3 { margin: 0; font-size: 17px; line-height: 1.3; letter-spacing: -0.015em; }
.catalog-details { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 12px; }
.catalog-details summary { width: fit-content; color: var(--brand); font-weight: 750; cursor: pointer; }
.catalog-resource-list { display: grid; margin: 12px 0 0; padding: 0; list-style: none; }
.catalog-resource-list li { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.catalog-resource-list li > div { display: grid; min-width: 0; }
.catalog-resource-list li strong { overflow-wrap: anywhere; }
.catalog-resource-list li span { color: var(--muted); font-size: 12px; }
.catalog-admin-link { flex: 0 0 auto; color: var(--brand); font-size: 12px; font-weight: 760; text-decoration: none; }
.catalog-admin-link:hover { text-decoration: underline; }
.catalog-more { margin: 12px 0 0; color: var(--muted); font-size: 12px; }
.catalog-clear { display: flex; align-items: center; gap: 14px; padding: 22px; }
.catalog-clear > span { display: grid; width: 38px; height: 38px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: var(--brand-soft); color: var(--success); font-size: 20px; font-weight: 850; }
.catalog-clear h3 { margin: 0; font-size: 17px; }
.catalog-clear p { margin: 2px 0 0; color: var(--muted); }
.catalog-pending > span { background: #eef3ef; color: var(--muted); }

.performance-health-section { display: grid; }
.performance-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.performance-metric { display: grid; min-height: 150px; align-content: start; padding: 20px; }
.performance-metric > span { color: var(--muted); font-size: 12px; font-weight: 720; }
.performance-metric > strong { margin-top: 12px; font-size: 31px; line-height: 1; letter-spacing: -.04em; }
.performance-metric > strong small { margin-left: 3px; color: var(--muted); font-size: 13px; letter-spacing: 0; }
.performance-metric > p { margin: auto 0 0; padding-top: 14px; color: var(--muted); font-size: 12px; }
.performance-metric .performance-unavailable { color: var(--muted); font-size: 20px; letter-spacing: -.02em; }
.tone-text-critical { color: var(--critical); }
.tone-text-warning { color: var(--warning); }
.tone-text-success { color: var(--success); }

.monitoring-section { display: grid; }
.change-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.change-card { display: grid; min-height: 132px; align-content: center; padding: 18px 20px; position: relative; overflow: hidden; }
.change-card::before { content: ""; width: 4px; position: absolute; inset: 0 auto 0 0; background: var(--line); }
.change-card > span { color: var(--muted); font-size: 12px; font-weight: 720; }
.change-card > strong { margin: 3px 0 0; font-size: 32px; line-height: 1; letter-spacing: -.04em; }
.change-card > small { margin-top: 6px; color: var(--muted); }
.change-new::before { background: var(--critical); }
.change-new > strong { color: var(--critical); }
.change-open::before { background: var(--warning); }
.change-open > strong { color: var(--warning); }
.change-resolved::before { background: var(--success); }
.change-resolved > strong { color: var(--success); }
.change-score::before { background: var(--info); }
.change-detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.change-detail { padding: 20px 22px; }
.change-detail h3 { margin: 0 0 10px; font-size: 16px; }
.change-detail > p { margin: 0; color: var(--muted); }
.change-detail ul { display: grid; margin: 0; padding: 0; list-style: none; }
.change-detail li { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); }
.change-detail li:first-child { border-top: 0; }
.change-detail li > div { display: grid; min-width: 0; }
.change-detail li strong { line-height: 1.35; }
.change-detail li small { color: var(--muted); }
.resolved-check { display: grid; width: 24px; height: 24px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: var(--brand-soft); color: var(--success); font-weight: 850; }
.change-steady { display: flex; align-items: center; gap: 14px; padding: 22px; }
.change-steady > span { display: grid; width: 38px; height: 38px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: var(--brand-soft); color: var(--success); font-size: 20px; font-weight: 850; }
.change-steady h3, .monitoring-baseline h3 { margin: 0; font-size: 17px; }
.change-steady p, .monitoring-baseline p { margin: 2px 0 0; color: var(--muted); }
.monitoring-baseline { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 16px; padding: 22px; }
.monitoring-baseline > div > span { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 12px; background: var(--brand-soft); color: var(--brand); font-size: 20px; font-weight: 850; }
.monitoring-baseline > aside { display: grid; min-width: 200px; border-left: 1px solid var(--line); padding-left: 20px; }
.monitoring-baseline > aside span { color: var(--brand); font-size: 11px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.monitoring-baseline > aside strong { margin-top: 2px; }
.monitoring-baseline > aside small { color: var(--muted); }

.monitoring-status-card { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 22px; }
.monitoring-status-card h2 { margin: 0; font-size: 20px; }
.monitoring-status-card p:not(.eyebrow) { margin: 4px 0 0; color: var(--muted); }
.monitoring-status-card aside { display: grid; min-width: 220px; border-left: 1px solid var(--line); padding-left: 22px; }
.monitoring-status-card aside span { color: var(--muted); font-size: 11px; font-weight: 720; text-transform: uppercase; letter-spacing: .06em; }

.fix-center-hero h1 { max-width: 800px; }
.verification-banner { position: relative; overflow: hidden; }
.verification-pulse { width: 12px; height: 12px; flex: 0 0 auto; border: 3px solid rgba(23, 92, 211, .2); border-top-color: var(--info); border-radius: 50%; animation: verify-spin .8s linear infinite; }
@keyframes verify-spin { to { transform: rotate(360deg); } }

.fix-summary-grid { display: grid; grid-template-columns: 1.45fr repeat(3, 1fr); gap: 12px; }
.fix-progress-card, .fix-metric { min-height: 132px; padding: 19px 20px; }
.fix-progress-card { display: flex; align-items: center; gap: 16px; background: linear-gradient(145deg, #163f2c, #0b2d1e); color: #fff; border: 0; }
.fix-progress-card > div:last-child { display: grid; }
.fix-progress-card span, .fix-progress-card small { color: #b9d9c5; }
.fix-progress-card strong { font-size: 17px; }
.fix-progress-ring { --progress: 0; display: grid; width: 76px; height: 76px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: conic-gradient(#5ad18a calc(var(--progress) * 1%), rgba(255, 255, 255, .15) 0); position: relative; }
.fix-progress-ring::after { content: ""; position: absolute; inset: 7px; border-radius: 50%; background: #123824; }
.fix-progress-ring strong { z-index: 1; font-size: 16px; }
.fix-metric { display: grid; align-content: center; }
.fix-metric > span { color: var(--muted); font-size: 12px; font-weight: 720; }
.fix-metric > strong { margin: 2px 0; font-size: 30px; letter-spacing: -.04em; }
.fix-metric > small { color: var(--muted); }

.fix-center-heading { align-items: end; }
.fix-center-heading > p { max-width: 410px; margin: 0; color: var(--muted); font-size: 12px; text-align: right; }
.issue-filters { display: flex; max-width: 100%; gap: 7px; margin-bottom: 12px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: thin; }
.issue-filter { display: inline-flex; align-items: center; gap: 7px; flex: 0 0 auto; border: 1px solid var(--line); border-radius: 99px; padding: 7px 10px; background: #fff; color: var(--muted); font-size: 12px; font-weight: 700; text-decoration: none; }
.issue-filter strong { display: grid; min-width: 21px; height: 21px; place-items: center; border-radius: 99px; padding: 0 5px; background: #eef2ee; color: var(--ink); font-size: 11px; }
.issue-filter:hover, .issue-filter.active { border-color: #86b899; background: var(--brand-soft); color: var(--brand-dark); }
.issue-filter.active strong { background: var(--brand); color: #fff; }

.store-issue-list { display: grid; gap: 12px; }
.store-issue { display: grid; grid-template-columns: 5px minmax(0, 1fr) 220px; overflow: hidden; }
.store-issue-accent { background: var(--warning); }
.store-issue-severity-critical .store-issue-accent, .store-issue-returned .store-issue-accent { background: var(--critical); }
.store-issue-resolved .store-issue-accent { background: var(--success); }
.store-issue-ignored .store-issue-accent { background: #98a2b3; }
.store-issue-main { min-width: 0; padding: 20px 22px; }
.store-issue-main h3 { margin: 7px 0 5px; font-size: 18px; line-height: 1.3; letter-spacing: -.015em; }
.store-issue-main > p { margin: 0; color: var(--muted); }
.store-issue-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.issue-last-seen { flex: 0 0 auto; color: var(--muted); font-size: 11px; }
.issue-status { display: inline-flex; align-items: center; border-radius: 99px; padding: 3px 7px; background: #edf0ed; color: #475467; font-size: 10px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.issue-status-open { background: #fff3e0; color: #8a4b08; }
.issue-status-in_progress { background: #edf4ff; color: #175cd3; }
.issue-status-awaiting_verification { background: #eee9ff; color: #5634a5; }
.issue-status-returned { background: #fee4e2; color: #912018; }
.issue-status-resolved { background: #e5f6eb; color: #137a45; }
.issue-status-ignored { background: #f0f1f1; color: #667085; }
.issue-message { margin-top: 12px; border-radius: 9px; padding: 10px 12px; background: #f4f6f4; color: var(--muted); font-size: 12px; }
.issue-message-returned { background: #fff0ee; color: #7a271a; }
.issue-message-warning { background: #fff8e8; color: #725316; }
.issue-message-success { background: #ecf8f0; color: #176b45; }
.issue-guidance { margin-top: 12px; border: 1px solid #d8d0f0; border-radius: 10px; padding: 10px 12px; background: #faf8ff; }
.issue-guidance summary { width: fit-content; color: #5634a5; font-size: 12px; font-weight: 800; cursor: pointer; }
.issue-guidance > p { color: var(--muted); }
.issue-guidance ol { margin: 10px 0; padding-left: 20px; }
.issue-evidence { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 10px; }
.issue-evidence summary { width: fit-content; color: var(--brand); font-size: 12px; font-weight: 750; cursor: pointer; }
.store-issue-actions { display: flex; flex-direction: column; gap: 8px; border-left: 1px solid var(--line); padding: 20px; background: #fcfdfc; }
.store-issue-actions > .button, .store-issue-actions > form, .store-issue-actions > form .button { width: 100%; }
.issue-impact { display: grid; margin-bottom: 8px; text-align: right; }
.issue-impact span, .issue-impact small { color: var(--muted); font-size: 11px; }
.issue-impact strong { font-size: 19px; }
.button-verify { border-color: #bcb0df; background: #f5f2ff; color: #5634a5; }
.button-verify:hover { background: #ece6ff; }
.button-verify:disabled { opacity: .5; cursor: not-allowed; }
.ignore-panel { margin-top: 4px; border-top: 1px solid var(--line); padding-top: 10px; }
.ignore-panel summary { color: var(--muted); font-size: 12px; font-weight: 700; text-align: center; cursor: pointer; }
.ignore-panel form { display: grid; gap: 6px; margin-top: 10px; }
.ignore-panel label { color: var(--muted); font-size: 11px; font-weight: 700; }
.ignore-panel select, .ignore-panel textarea { width: 100%; border: 1px solid #b9c3bb; border-radius: 8px; background: #fff; padding: 8px; color: var(--ink); font: inherit; }
.ignore-panel textarea { resize: vertical; }
.resolved-stamp { display: inline-flex; min-height: 39px; align-items: center; justify-content: center; border-radius: 9px; background: var(--brand-soft); color: var(--success); font-weight: 800; }
.fix-center-empty { display: flex; align-items: center; gap: 16px; padding: 24px; }
.fix-center-empty > span { display: grid; width: 42px; height: 42px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: var(--brand-soft); color: var(--success); font-size: 20px; font-weight: 850; }
.fix-center-empty > div { flex: 1; }
.fix-center-empty h3 { margin: 0; font-size: 17px; }
.fix-center-empty p { margin: 2px 0 0; color: var(--muted); }
.history-chart-card { overflow: hidden; }
.history-chart { display: flex; min-height: 260px; align-items: end; gap: 10px; padding: 28px 24px 22px; }
.history-bar { display: grid; min-width: 38px; height: 190px; flex: 1 1 0; grid-template-rows: 20px 1fr 22px; gap: 5px; align-items: end; color: var(--muted); text-align: center; text-decoration: none; }
.history-bar-value { align-self: start; color: var(--ink); font-size: 11px; font-weight: 780; }
.history-bar i { display: block; width: min(100%, 46px); min-height: 3px; justify-self: center; border-radius: 6px 6px 2px 2px; background: var(--brand); transition: transform .15s ease; }
.history-bar:hover i { transform: translateY(-3px); }
.history-bar i.tone-critical { background: var(--critical); }
.history-bar i.tone-warning { background: var(--warning); }
.history-bar i.tone-success { background: var(--success); }
.history-bar small { align-self: end; white-space: nowrap; font-size: 10px; }
.history-list { display: grid; gap: 10px; }
.history-row { display: grid; grid-template-columns: 74px minmax(220px, 1fr) 90px 90px 110px 24px; align-items: center; gap: 14px; padding: 15px 18px; text-decoration: none; }
.history-row:hover { border-color: #9fc4ac; box-shadow: 0 0 0 2px rgba(23, 107, 69, .07), var(--shadow); }
.history-score { display: flex; align-items: baseline; gap: 2px; color: var(--success); }
.history-score.tone-critical { color: var(--critical); }
.history-score.tone-warning { color: var(--warning); }
.history-score strong { font-size: 25px; letter-spacing: -.04em; }
.history-score span { color: var(--muted); font-size: 10px; }
.history-main { display: grid; }
.history-main span, .history-stat span, .history-delta span { color: var(--muted); font-size: 11px; }
.history-stat, .history-delta { display: grid; }
.history-stat strong, .history-delta strong { font-size: 16px; }
.history-delta.positive strong { color: var(--success); }
.history-delta.negative strong { color: var(--critical); }
.history-arrow { color: var(--brand); font-size: 20px; font-weight: 800; }

.empty-state { display: grid; max-width: 760px; justify-items: center; margin: 34px auto; padding: 50px 40px; text-align: center; }
.empty-state h2 { max-width: 520px; margin: 2px 0 8px; font-size: 28px; letter-spacing: -0.035em; }
.empty-state > p:not(.eyebrow) { max-width: 570px; margin: 0 0 22px; color: var(--muted); }
.empty-illustration { display: flex; align-items: end; gap: 7px; width: 100px; height: 76px; margin-bottom: 20px; padding: 14px; border-radius: 22px; background: var(--brand-soft); }
.empty-illustration span { flex: 1; border-radius: 5px 5px 2px 2px; background: var(--brand); }
.empty-illustration span:nth-child(1) { height: 35%; opacity: .5; }
.empty-illustration span:nth-child(2) { height: 62%; opacity: .72; }
.empty-illustration span:nth-child(3) { height: 100%; }

.scan-state { display: flex; align-items: center; gap: 26px; max-width: 780px; margin: 40px auto; padding: 34px; }
.scan-state h2 { margin: 2px 0 7px; font-size: 25px; }
.scan-state p:last-child { margin: 0; color: var(--muted); }
.scanner { display: grid; width: 78px; height: 78px; flex: 0 0 auto; place-items: center; border-radius: 20px; background: var(--brand-soft); overflow: hidden; position: relative; }
.scanner::before { content: ""; width: 35px; height: 45px; border: 3px solid var(--brand); border-radius: 4px; }
.scanner span { position: absolute; width: 58px; height: 2px; background: #49b974; box-shadow: 0 0 12px #49b974; animation: scan 1.8s ease-in-out infinite; }
@keyframes scan { 0%, 100% { transform: translateY(-24px); } 50% { transform: translateY(24px); } }

.settings-card { padding: 24px; }
.field { display: grid; gap: 8px; }
.field > label { font-weight: 750; }
.field > p { margin: 0; color: var(--muted); font-size: 12px; }
.money-input { display: flex; max-width: 420px; overflow: hidden; border: 1px solid #b9c3bb; border-radius: 9px; background: #fff; }
.money-input span { display: grid; place-items: center; padding: 0 12px; border-right: 1px solid var(--line); background: #f5f7f5; color: var(--muted); font-weight: 700; }
.money-input input { width: 100%; border: 0; padding: 11px 12px; outline: 0; }
.money-input:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(23, 107, 69, 0.12); }
.form-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); }
.legal-shell { width: min(820px, calc(100% - 40px)); margin: 0 auto; padding: 54px 0 80px; }
.legal-shell h1 { margin: 5px 0 10px; font-size: 38px; letter-spacing: -0.04em; }
.legal-shell h2 { margin-top: 30px; font-size: 19px; }
.legal-shell p, .legal-shell li { color: var(--muted); line-height: 1.7; }
.legal-nav { display: flex; gap: 16px; margin: 24px 0; padding: 14px 0; border-block: 1px solid var(--line); }
.legal-nav a { color: var(--brand); font-weight: 700; }

@media (max-width: 900px) {
  .plan-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .score-grid { grid-template-columns: repeat(2, 1fr); }
  .performance-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .content-grid { grid-template-columns: 1fr; }
  .fix-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .store-issue { grid-template-columns: 5px minmax(0, 1fr); }
  .store-issue-actions { grid-column: 2; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 0; }
  .issue-impact { grid-column: 1 / -1; text-align: left; }
  .ignore-panel { grid-column: 1 / -1; }
  .change-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .history-row { grid-template-columns: 68px minmax(180px, 1fr) 72px 90px 24px; }
  .history-row .history-stat + .history-stat { display: none; }
  .finding { grid-template-columns: 40px minmax(0, 1fr); }
  .finding-impact { grid-column: 2; flex-direction: row; align-items: center; gap: 8px; border-top: 1px solid var(--line); border-left: 0; text-align: left; }
  .finding-impact form { width: auto; min-width: 140px; margin-left: auto; padding-top: 0; }
}

@media (max-width: 640px) {
  .app-shell, .app-shell-narrow { width: min(100% - 24px, 1220px); padding-top: 14px; }
  .topbar { align-items: flex-start; flex-direction: column; gap: 12px; padding-bottom: 12px; }
  .topnav { width: 100%; }
  .topnav a { flex: 1; padding-inline: 7px; font-size: 12px; text-align: center; }
  .hero-row { align-items: stretch; flex-direction: column; padding-top: 20px; }
  .hero-row form, .hero-row .button { width: 100%; }
  .score-grid { grid-template-columns: 1fr; }
  .performance-grid { grid-template-columns: 1fr; }
  .change-grid, .change-detail-grid { grid-template-columns: 1fr; }
  .change-card { min-height: 104px; }
  .monitoring-baseline { grid-template-columns: auto minmax(0, 1fr); align-items: start; }
  .monitoring-baseline > aside { grid-column: 1 / -1; min-width: 0; border-top: 1px solid var(--line); border-left: 0; padding: 14px 0 0; }
  .monitoring-status-card { align-items: flex-start; flex-direction: column; }
  .monitoring-status-card aside { width: 100%; min-width: 0; border-top: 1px solid var(--line); border-left: 0; padding: 14px 0 0; }
  .history-chart { min-width: 560px; }
  .history-chart-card { overflow-x: auto; }
  .history-row { grid-template-columns: 58px minmax(0, 1fr) 72px 18px; gap: 10px; padding: 13px 12px; }
  .history-row .history-stat, .history-row .history-delta { display: none; }
  .plan-grid { grid-template-columns: 1fr; }
  .plan-description { min-height: 0; }
  .score-card, .metric-card { min-height: 132px; }
  .score-card-primary { min-height: 150px; }
  .category-row { grid-template-columns: 105px minmax(70px, 1fr) 30px; gap: 9px; }
  .card-header, .section-heading { align-items: flex-start; flex-direction: column; }
  .section-actions { width: 100%; align-items: stretch; flex-direction: column; }
  .fix-summary-grid { grid-template-columns: 1fr; }
  .fix-progress-card, .fix-metric { min-height: 112px; }
  .fix-center-heading > p { text-align: left; }
  .store-issue { grid-template-columns: 4px minmax(0, 1fr); }
  .store-issue-main { padding: 17px 14px; }
  .store-issue-header { flex-direction: column; }
  .issue-last-seen { flex: initial; }
  .store-issue-actions { grid-template-columns: 1fr; padding: 14px; }
  .issue-impact, .ignore-panel { grid-column: auto; }
  .fix-center-empty { align-items: flex-start; flex-wrap: wrap; }
  .fix-center-empty .button { width: 100%; }
  .finding { grid-template-columns: 32px minmax(0, 1fr); }
  .finding-rank { padding-top: 19px; }
  .finding-body { padding: 16px 14px; }
  .finding-impact { grid-column: 1 / -1; flex-wrap: wrap; padding: 13px 14px; }
  .finding-impact form { width: 100%; margin: 6px 0 0; }
  .catalog-issue { padding: 17px 15px; }
  .catalog-issue-header, .catalog-issue-title { align-items: flex-start; flex-direction: column; }
  .catalog-resource-list li { align-items: flex-start; flex-direction: column; }
  .scan-state { align-items: flex-start; flex-direction: column; }
  .banner { align-items: flex-start; flex-direction: column; }
  .banner .button { width: 100%; }
}
