/* ═══════════════════════════════════════════════════════════════════
   calculator.css — the panels, fields, results and charts shared by the
   four calculator pages. Loads after site.css and uses its tokens, so
   the light theme needs no overrides of its own.

   Every component from the four pages' old inline blocks is here,
   including the ones only one page uses (the divider's error budget,
   the trace-width checker). Unused selectors cost nothing, and one file
   means the pages cannot drift apart again.

   The scripts on those pages toggle these classes and must keep working:
   .acc-section.open, .toggle-btn.active, .cond-hide, .busy, .toast.show,
   .result-card.{highlight,success,warn,fail}, .verdict.{pass,fail},
   .cf-row.{win,neutral,info}, .check-status-badge.{pass,fail}.
   ═══════════════════════════════════════════════════════════════════ */

:root {
    /* Colours the resistor divider's inline SVG schematic reads. */
    --sv-vin: #4F8EF7;
    --sv-wire: #94A3B8;
    --sv-comp: #FFB77B;
    --sv-mid: #BAC8DA;
    --sv-load: #38BDF8;
    --sv-gnd: #64748B;
    --sv-dim: #64748B;
}

[data-theme="light"] {
    --sv-wire: #64748B;
    --sv-comp: #2563EB;
    --sv-mid: #475569;
}

/* ─── Layout ─── */
/* The two-column layout wants more room than the 1120px prose measure the
   rest of the site uses, so the calculator sections widen the wrap. */
.calc-wide {
    max-width: 1280px;
}

.calc-layout {
    display: grid;
    grid-template-columns: 380px minmax(0, 1fr);
    gap: 28px;
    align-items: start;
    padding-bottom: clamp(48px, 6vw, 80px);
}

@media (max-width: 960px) {
    .calc-layout {
        grid-template-columns: 1fr;
    }
}

/* ─── Panels ─── */
.panel,
.chart-panel,
.circuit-panel,
.eva-panel,
.mc-panel,
.design-card,
.budget-panel,
.cf-panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.panel-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--line);
}

.panel-header .ms {
    font-size: 20px;
    color: var(--accent);
}

.panel-header h2 {
    font-size: 16px;
    font-weight: 700;
}

.input-sidebar {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* ─── Accordion ─── */
.acc-section {
    border-bottom: 1px solid var(--line);
}

.acc-section:last-child {
    border-bottom: none;
}

.acc-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 0;
    cursor: pointer;
    user-select: none;
}

.acc-header:hover .acc-title {
    color: var(--text);
}

.acc-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-2);
}

.acc-title .ms {
    font-size: 17px;
    color: var(--accent);
}

.acc-header .chevron {
    font-size: 18px;
    color: var(--text-3);
    transition: transform 0.2s ease;
}

.acc-section.open .acc-header .chevron {
    transform: rotate(180deg);
    color: var(--text);
}

.acc-body {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.2s ease;
}

.acc-section.open .acc-body {
    max-height: 1200px;
    opacity: 1;
    padding-bottom: 8px;
}

/* ─── Fields ─── */
.field-group {
    margin-bottom: 16px;
}

.field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.field-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-2);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.field-unit {
    font-size: 10px;
    color: var(--text-3);
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0;
}

.input-row {
    display: flex;
    gap: 8px;
    align-items: center;
}

.field-input,
.select-input {
    width: 100%;
    padding: 9px 12px;
    border-radius: var(--radius);
    background: var(--field-bg);
    border: 1px solid var(--line-strong);
    color: var(--text);
    font-size: 14px;
    font-weight: 500;
    outline: none;
    transition: border-color 0.15s ease;
}

.field-input {
    font-family: var(--font-mono);
}

.field-input:focus,
.select-input:focus {
    border-color: var(--accent);
}

.field-input:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.field-hint {
    font-size: 11px;
    color: var(--text-3);
    margin-top: 4px;
    line-height: 1.5;
}

.select-input {
    font-family: var(--font);
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
    padding-right: 36px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23858892'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 16px;
}

.select-input option {
    background: var(--surface);
    color: var(--text);
}

.section-divider {
    border: none;
    border-top: 1px solid var(--line);
    margin: 20px 0 16px;
}

.section-sub {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-3);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.section-sub .ms {
    font-size: 15px;
    color: var(--accent);
}

/* ─── Sliders ─── */
.slider-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.mc-slider-wrap {
    margin-bottom: 16px;
}

.mc-slider-wrap .field-label {
    margin-bottom: 10px;
}

.slider {
    flex: 1;
    width: 100%;
    -webkit-appearance: none;
    appearance: none;
    height: 4px;
    border-radius: 2px;
    background: var(--line-strong);
    outline: none;
    cursor: pointer;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent);
    border: 2px solid var(--surface);
    cursor: pointer;
}

.slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent);
    border: 2px solid var(--surface);
    cursor: pointer;
}

.slider-val {
    font-size: 12px;
    font-family: var(--font-mono);
    color: var(--accent);
    font-weight: 500;
    min-width: 52px;
    text-align: right;
}

/* ─── Toggle group ─── */
.toggle-group {
    display: flex;
    border-radius: var(--radius);
    border: 1px solid var(--line-strong);
    overflow: hidden;
    margin-bottom: 12px;
}

.toggle-btn {
    flex: 1;
    padding: 8px 10px;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    color: var(--text-2);
    background: transparent;
    border: none;
    font-family: var(--font);
    transition: background-color 0.15s ease, color 0.15s ease;
}

.toggle-btn.active {
    background: var(--accent);
    color: var(--accent-ink);
}

.toggle-btn:hover:not(.active) {
    background: var(--bg-2);
    color: var(--text);
}

/* ─── Error banner (surfaced, never swallowed) ─── */
.err-banner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: var(--radius);
    background: var(--bad-soft);
    border: 1px solid var(--bad);
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
}

.err-banner .ms {
    font-size: 18px;
    color: var(--bad);
}

/* ─── Results ─── */
.results-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-width: 0;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}

.result-card {
    padding: 16px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    min-width: 0;
}

.result-card.highlight,
.result-card.cyan-hl {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.result-card.success {
    border-color: var(--ok);
    background: var(--ok-soft);
}

.result-card.warn,
.result-card.warn-card {
    border-color: var(--warn);
    background: var(--warn-soft);
}

.result-card.fail {
    border-color: var(--bad);
    background: var(--bad-soft);
}

.result-label {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-3);
    margin-bottom: 6px;
}

.result-value {
    font-size: clamp(18px, 2.5vw, 26px);
    font-weight: 700;
    color: var(--text);
    font-family: var(--font-mono);
    letter-spacing: -0.02em;
    line-height: 1.1;
    overflow-wrap: anywhere;
}

.result-value .unit {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-3);
    margin-left: 2px;
}

.result-sub {
    font-size: 11px;
    color: var(--text-3);
    margin-top: 5px;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 7px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
}

.status-badge.pass { background: var(--ok-soft); color: var(--ok); }
.status-badge.marginal { background: var(--warn-soft); color: var(--warn); }
.status-badge.fail-st { background: var(--bad-soft); color: var(--bad); }

/* ─── Charts ─── */
.chart-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}

.chart-header .ms {
    font-size: 18px;
    color: var(--accent);
}

.chart-header h3 {
    font-size: 14px;
    font-weight: 700;
}

.chart-header p {
    font-size: 11px;
    color: var(--text-3);
    margin-top: 2px;
}

.chart-wrap {
    position: relative;
    height: 300px;
}

.chart-wrap.short {
    height: 120px;
}

.eia-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: var(--ok-soft);
    color: var(--ok);
    margin-left: 8px;
}

/* ─── Formula panel ─── */
.formula-panel {
    background: var(--bg-2);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 18px;
    overflow-x: auto;
}

.formula-panel h4 {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-2);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.formula-panel h4 .ms {
    font-size: 16px;
    color: var(--accent);
}

.formula {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-2);
    line-height: 2;
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 0 12px;
}

.formula .lhs {
    color: var(--accent);
    font-weight: 500;
    white-space: nowrap;
}

.info-callout {
    background: var(--bg-2);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 14px 16px;
    font-size: 13px;
    color: var(--text-2);
    line-height: 1.7;
}

.info-callout strong {
    color: var(--text);
}

.freq-range-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 8px;
    align-items: end;
}

.freq-range-row .sep {
    font-size: 14px;
    color: var(--text-3);
    padding-bottom: 10px;
    font-weight: 700;
}

/* ─── Conditional visibility and busy state ─── */
.cond-hide {
    display: none !important;
}

.busy {
    opacity: 0.55;
    transition: opacity 0.15s;
}

/* ─── Apply button and toast (resistor divider) ─── */
.btn-apply {
    width: 100%;
    padding: 10px;
    border-radius: var(--radius);
    background: var(--accent-soft);
    border: 1px solid var(--accent);
    color: var(--text);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    font-family: var(--font);
}

.btn-apply:hover {
    background: var(--accent);
    color: var(--accent-ink);
}

.btn-apply:disabled {
    opacity: 0.4;
    cursor: default;
    pointer-events: none;
}

.toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--ok);
    color: #FFFFFF;
    padding: 12px 28px;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 700;
    z-index: 9999;
    transition: transform 0.3s ease;
    pointer-events: none;
    white-space: nowrap;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
}

/* ─── Tooltips ───
   A flat box on the surface colour. The results grid puts them below the
   card so the top row does not push them off the page. */
[data-tip] {
    position: relative;
    cursor: help;
}

[data-tip]::after {
    content: attr(data-tip);
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 999;
    background: var(--surface);
    color: var(--text-2);
    font-size: 11px;
    font-weight: 400;
    line-height: 1.5;
    padding: 8px 12px;
    border-radius: var(--radius);
    border: 1px solid var(--line-strong);
    white-space: normal;
    width: max-content;
    max-width: 260px;
    text-transform: none;
    letter-spacing: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
    font-family: var(--font);
}

[data-tip]:hover::after {
    opacity: 1;
}

.results-grid [data-tip]::after {
    bottom: auto;
    top: calc(100% + 8px);
}

/* ─── Closing call to action ─── */
.app-cta {
    padding-bottom: clamp(32px, 4vw, 48px);
}

.cta-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--surface);
    padding: 28px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.cta-text h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 6px;
}

.cta-text p {
    font-size: 14px;
    color: var(--text-2);
    max-width: 560px;
}

/* ─── Resistor divider: schematic, worst case, Monte Carlo ─── */
.circuit-panel h3,
.eva-panel h3,
.mc-panel h3,
.budget-panel h3,
.cf-panel h3 {
    font-size: 15px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
}

.circuit-panel h3 .ms,
.eva-panel h3 .ms,
.mc-panel h3 .ms,
.budget-panel h3 .ms,
.cf-panel h3 .ms {
    font-size: 18px;
    color: var(--accent);
}

.circuit-svg-wrap {
    display: flex;
    justify-content: center;
}

#divider-svg {
    width: 100%;
    max-width: 380px;
    height: auto;
}

.eva-results,
.eva-spread-row,
.mc-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.eva-results {
    margin-bottom: 16px;
}

.eva-spread-row {
    margin-top: 12px;
}

@media (max-width: 600px) {
    .eva-results,
    .eva-spread-row {
        grid-template-columns: 1fr;
    }

    .mc-stats {
        grid-template-columns: 1fr 1fr;
    }
}

.eva-stat,
.eva-spread-card,
.mc-stat {
    background: var(--bg-2);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 12px;
    text-align: center;
    min-width: 0;
}

.eva-stat-label,
.eva-spread-label,
.mc-stat-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-3);
    margin-bottom: 4px;
}

.eva-stat-val,
.eva-spread-val,
.mc-stat-val {
    font-size: 16px;
    font-weight: 700;
    color: var(--text);
    font-family: var(--font-mono);
    overflow-wrap: anywhere;
}

.eva-stat-sub,
.mc-stat-sub {
    font-size: 11px;
    color: var(--text-3);
    margin-top: 3px;
}

.eva-stat.low .eva-stat-val { color: var(--sv-vin); }
.eva-stat.nom .eva-stat-val { color: var(--ok); }
.eva-stat.high .eva-stat-val { color: var(--bad); }
.eva-spread-val { color: var(--warn); }
.mc-stat.yield .mc-stat-val { color: var(--ok); }

.eva-range-wrap {
    position: relative;
    height: 40px;
    margin: 12px 0 8px;
}

.eva-range-track {
    position: absolute;
    top: 14px;
    left: 0;
    right: 0;
    height: 12px;
    border-radius: 6px;
    background: var(--line);
}

.eva-range-fill {
    position: absolute;
    top: 14px;
    height: 12px;
    border-radius: 6px;
    background: linear-gradient(90deg, var(--sv-vin), var(--ok), var(--bad));
    opacity: 0.8;
}

.eva-nom-marker {
    position: absolute;
    top: 6px;
    width: 2px;
    height: 28px;
    background: var(--ok);
    border-radius: 1px;
    transform: translateX(-50%);
}

.eva-nom-marker::after {
    content: '';
    position: absolute;
    top: -4px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid var(--ok);
}

.eva-label-row {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    font-family: var(--font-mono);
    font-weight: 500;
}

.eva-label-min { color: var(--sv-vin); }
.eva-label-max { color: var(--bad); }

.eva-assumptions,
.mc-note,
.design-note {
    font-size: 11px;
    color: var(--text-3);
    margin-top: 10px;
    line-height: 1.6;
}

.eva-assumptions {
    padding: 8px 12px;
    background: var(--bg-2);
    border-radius: var(--radius);
    border: 1px solid var(--line);
}

#mc-canvas {
    width: 100%;
    height: 180px;
    border-radius: var(--radius);
    background: var(--bg-2);
    border: 1px solid var(--line);
    margin-bottom: 16px;
}

.corner-tag {
    font-size: 10px;
    font-weight: 700;
    padding: 3px 9px;
    border-radius: 4px;
    letter-spacing: 0.04em;
    background: var(--bg-2);
    border: 1px solid var(--line);
    color: var(--text-2);
    font-family: var(--font-mono);
}

/* Design card: the chosen pair and its verdict. */
.design-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.design-label,
.stack-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-3);
    margin-bottom: 8px;
}

.design-values {
    font-size: clamp(20px, 3vw, 30px);
    font-weight: 700;
    color: var(--text);
    font-family: var(--font-mono);
    letter-spacing: -0.02em;
    line-height: 1.15;
    overflow-wrap: anywhere;
}

.design-sub {
    font-size: 13px;
    color: var(--text-2);
    margin-top: 6px;
}

.verdict {
    padding: 8px 18px;
    border-radius: var(--radius);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    white-space: nowrap;
}

.verdict.pass {
    background: var(--ok-soft);
    color: var(--ok);
    border: 1px solid var(--ok);
}

.verdict.fail {
    background: var(--bad-soft);
    color: var(--bad);
    border: 1px solid var(--bad);
}

.design-note {
    margin-top: 16px;
    padding: 11px 14px;
    border-radius: var(--radius);
    background: var(--warn-soft);
    border: 1px solid var(--warn);
    font-size: 12px;
    color: var(--text-2);
}

.design-note .ms {
    font-size: 14px;
    color: var(--warn);
    vertical-align: -2px;
    margin-right: 5px;
}

/* Worst case beside statistical. */
.stack-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

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

.stack-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 18px;
    min-width: 0;
}

.stack-card.gate {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.stack-label {
    display: flex;
    align-items: center;
    gap: 7px;
}

.stack-tag {
    font-size: 9px;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 4px;
    letter-spacing: 0.05em;
    background: var(--accent);
    color: var(--accent-ink);
}

.stack-val {
    font-size: 24px;
    font-weight: 700;
    color: var(--text);
    font-family: var(--font-mono);
    overflow-wrap: anywhere;
}

.stack-sub {
    font-size: 11px;
    color: var(--text-3);
    margin-top: 5px;
}

/* Error budget bar and list. */
.budget-bar {
    display: flex;
    height: 24px;
    border-radius: 6px;
    overflow: hidden;
    background: var(--bg-2);
    border: 1px solid var(--line);
    margin-bottom: 16px;
}

.budget-seg {
    height: 100%;
    transition: width 0.3s ease;
}

.budget-list {
    display: grid;
    gap: 8px;
}

.budget-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12.5px;
}

.budget-dot {
    width: 11px;
    height: 11px;
    border-radius: 3px;
    flex-shrink: 0;
}

.budget-name {
    color: var(--text-2);
    flex: 1;
}

.budget-name em {
    color: var(--text-3);
    font-style: normal;
    font-size: 11px;
}

.budget-pct {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--text);
    font-size: 12.5px;
}

.budget-foot {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--line);
    font-size: 11px;
    color: var(--text-3);
    line-height: 1.6;
}

/* Counterfactuals: what one change would buy. */
.cf-row {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    padding: 10px 13px;
    border-radius: var(--radius);
    background: var(--bg-2);
    border: 1px solid var(--line);
    margin-bottom: 8px;
    font-size: 12.5px;
}

.cf-row .ms {
    font-size: 16px;
    flex-shrink: 0;
    margin-top: 1px;
    color: var(--text-3);
}

.cf-change {
    color: var(--text-2);
    flex: 1;
    line-height: 1.5;
}

.cf-out {
    font-weight: 700;
    white-space: nowrap;
    font-size: 11.5px;
    color: var(--text-3);
}

.cf-row.win {
    border-color: var(--ok);
    background: var(--ok-soft);
}

.cf-row.win .ms,
.cf-row.win .cf-out {
    color: var(--ok);
}

.cf-row.info {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.cf-row.info .ms,
.cf-row.info .cf-out {
    color: var(--accent);
}

/* ─── PCB trace width: the checker under the inputs ─── */
.check-results-container {
    margin-top: 20px;
    border-top: 1px solid var(--line);
    padding-top: 20px;
}

.check-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 16px 8px;
}

.check-active-state {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.check-status-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: var(--radius);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.check-status-badge.pass {
    background: var(--ok-soft);
    border: 1px solid var(--ok);
    color: var(--ok);
}

.check-status-badge.fail {
    background: var(--bad-soft);
    border: 1px solid var(--bad);
    color: var(--bad);
}

.check-status-badge .ms {
    font-size: 18px;
}

.check-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.check-stat-item {
    background: var(--bg-2);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 12px 14px;
    text-align: left;
    min-width: 0;
}

.check-stat-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-3);
    margin-bottom: 6px;
}

.check-stat-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--text);
    font-family: var(--font-mono);
    overflow-wrap: anywhere;
}

.check-stat-value .unit {
    font-size: 12px;
    color: var(--text-3);
    margin-left: 2px;
}

.check-stat-hint {
    font-size: 12px;
    color: var(--text-2);
    line-height: 1.6;
    border-left: 2px solid var(--line-strong);
    padding: 8px 14px;
}

.check-stat-hint strong {
    color: var(--text);
}
