:root {
    color-scheme: light;
    --ink: #1f2933;
    --muted: #667085;
    --line: #e4e7ec;
    --surface: #ffffff;
    --canvas: #f6f7f9;
    --brand: #008060;
    --brand-dark: #006e52;
    --danger: #b42318;
    --warning: #b54708;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--canvas); color: var(--ink); }
button, input, select { font: inherit; }
button { cursor: pointer; }
.shell { max-width: 1180px; margin: 0 auto; padding: 34px 22px 70px; }
.topbar { display: flex; justify-content: space-between; gap: 24px; align-items: flex-start; margin-bottom: 28px; }
.eyebrow { color: var(--brand); text-transform: uppercase; letter-spacing: .08em; font-size: 11px; font-weight: 800; margin: 0 0 8px; }
h1, h2 { margin: 0 0 8px; letter-spacing: -.02em; }
h1 { font-size: clamp(26px, 4vw, 38px); }
h2 { font-size: 20px; }
p { line-height: 1.6; }
.muted, .help, small { color: var(--muted); }
.badge { border: 1px solid #b7e3d5; background: #e9f8f3; color: #006e52; padding: 9px 13px; border-radius: 999px; font-size: 13px; font-weight: 700; white-space: nowrap; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 24px; overflow-x: auto; }
.tab { border: 0; border-bottom: 3px solid transparent; background: transparent; padding: 13px 16px; color: var(--muted); font-weight: 700; white-space: nowrap; }
.tab.active { color: var(--brand-dark); border-bottom-color: var(--brand); }
.grid { display: grid; gap: 18px; }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.spaced { margin-top: 18px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px; box-shadow: 0 2px 6px rgba(16,24,40,.03); }
.metric { min-height: 128px; display: flex; flex-direction: column; gap: 6px; }
.metric span, .metric small { color: var(--muted); font-size: 13px; }
.metric strong { font-size: 26px; margin-top: auto; }
.section { display: none; }
.section.active { display: block; }
.section-heading { display: flex; justify-content: space-between; margin: 10px 0 18px; }
.section-heading.compact { align-items: flex-start; }
.health-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.health-item { display: flex; gap: 11px; align-items: flex-start; padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: #fbfcfd; }
.health-item.ok { border-color: #b7e3d5; background: #f4fcf9; }
.health-item.warning { border-color: #f4c7a1; background: #fffaf5; }
.health-item.error { border-color: #f3b5b0; background: #fff7f6; }
.health-icon { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: #eef2f6; color: var(--muted); font-weight: 900; flex: 0 0 auto; }
.health-item.ok .health-icon { background: #d9f5ea; color: var(--brand-dark); }
.health-item.warning .health-icon { background: #ffe8c7; color: var(--warning); }
.health-item.error .health-icon { background: #fddbd8; color: var(--danger); }
.health-item strong { display: block; margin-bottom: 4px; }
.health-item p { margin: 0 0 3px; line-height: 1.45; font-size: 14px; }
.health-item small { display: block; line-height: 1.45; }
.health-action { display: inline-block; margin-top: 8px; color: var(--brand-dark); font-size: 12px; font-weight: 800; }
.diagnostic-form { max-width: 520px; }
.diagnostics-summary { display: grid; gap: 18px; }
.summary-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.summary-grid div { padding: 12px; background: #f6f7f9; border-radius: 8px; }
.summary-grid span { display: block; color: var(--muted); font-size: 12px; }
.summary-grid strong { display: block; margin-top: 4px; font-size: 18px; }
.cron-summary { border-top: 1px solid var(--line); padding-top: 14px; }
.cron-summary > strong { font-size: 14px; }
.diagnostics-errors { border-top: 1px solid var(--line); margin-top: 18px; padding-top: 14px; }
.diagnostics-overview { display: block; }
.overview-card { display: flex; justify-content: space-between; align-items: center; gap: 18px; padding: 20px 22px; border: 1px solid var(--line); border-radius: 12px; background: #fff; box-shadow: 0 4px 18px rgba(16,24,40,.05); }
.overview-card.ok { border-left: 5px solid #16803c; }
.overview-card.warning { border-left: 5px solid #b26a00; }
.overview-card.error { border-left: 5px solid #c62828; }
.overview-card h2 { margin: 4px 0; font-size: 21px; }
.overview-card p { margin: 0; color: var(--muted); font-size: 13px; }
.overview-badge { white-space: nowrap; border-radius: 999px; padding: 7px 10px; font-size: 12px; font-weight: 800; background: #eef2f5; }
.overview-card.ok .overview-badge { color: #126b36; background: #eaf7ef; }
.overview-card.warning .overview-badge { color: #8a5200; background: #fff5df; }
.overview-card.error .overview-badge { color: #a51f1f; background: #fff0f0; }
.diagnostics-detail { border-top: 1px solid var(--line); margin-top: 15px; padding-top: 12px; }
.diagnostics-detail summary { cursor: pointer; font-size: 13px; font-weight: 800; color: var(--ink); }
.diagnostics-table, .diagnostic-flow-list { margin-top: 10px; }
.diagnostic-message-row, .flow-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.diagnostic-message-row small, .flow-row span { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
.diagnostic-message-status { text-align: right; white-space: nowrap; }
.diagnostic-message-status small { color: var(--muted); }
.message-detail { flex-basis: 100%; margin-top: 5px; font-size: 11px; }
.message-detail summary { cursor: pointer; color: var(--brand-dark); font-weight: 800; }
.message-detail > div { display: grid; gap: 3px; margin-top: 6px; padding: 8px; background: #f6f7f9; border-radius: 6px; color: var(--muted); }
.message-detail b { color: var(--ink); }
.inline-error { flex-basis: 100%; margin: 4px 0 0; color: var(--danger); font-size: 12px; }
.flow-row em { color: #16803c; font-style: normal; }
.diagnostics-errors-title { font-size: 14px; font-weight: 800; margin-bottom: 8px; }
.error-row { padding: 11px 0; border-bottom: 1px solid var(--line); }
.error-row > div { display: flex; justify-content: space-between; gap: 12px; }
.error-row small { display: block; margin-top: 3px; }
.error-row p { margin: 6px 0 0; color: var(--danger); font-size: 13px; line-height: 1.45; }
.error-help { margin-top: 8px; padding: 9px 10px; border-radius: 7px; background: #fff8eb; color: #7a2e0b; font-size: 12px; line-height: 1.45; }
.error-help strong { color: #5f2308; }
.recovery-summary { border-top: 1px solid var(--line); margin-top: 14px; padding-top: 14px; }
.recovery-summary > strong { display: block; font-size: 14px; margin-bottom: 8px; }
.recovery-summary small { display: block; margin-top: 3px; color: var(--muted); }
.inline-form { display: flex; align-items: end; gap: 12px; flex-wrap: wrap; }
.inline-form label { margin: 0; min-width: 190px; flex: 1; }
.inline-form input { width: 100%; }
.timeline-result { margin-top: 18px; }
.timeline-order { display: flex; justify-content: space-between; gap: 12px; padding: 14px; background: #f6f7f9; border-radius: 8px; }
.timeline-order strong, .timeline-order span { display: block; }
.timeline-order span, .timeline-order small { color: var(--muted); margin-top: 4px; }
.timeline-list { margin-top: 14px; border-left: 2px solid #dfe4e8; padding-left: 18px; }
.timeline-event { position: relative; padding: 0 0 16px; }
.timeline-event:last-child { padding-bottom: 0; }
.timeline-dot { position: absolute; left: -25px; top: 3px; width: 10px; height: 10px; border-radius: 50%; background: #9aa4ad; border: 2px solid #fff; box-shadow: 0 0 0 1px #dfe4e8; }
.timeline-dot.message { background: var(--brand); }
.timeline-dot.recovery { background: #16803c; }
.timeline-event p { margin: 4px 0; color: var(--muted); font-size: 13px; }
.timeline-event small { color: var(--muted); }
.form-card { max-width: 760px; }
label { display: block; font-weight: 700; font-size: 14px; margin: 18px 0 7px; }
input[type="text"], input[type="password"], input[type="tel"], select { width: 100%; border: 1px solid #cfd5dc; border-radius: 8px; padding: 11px 12px; background: #fff; color: var(--ink); }
input:focus { outline: 3px solid rgba(0,128,96,.16); border-color: var(--brand); }
.check { display: flex; align-items: center; gap: 9px; font-weight: 500; }
.check input { width: 17px; height: 17px; accent-color: var(--brand); }
.form-actions { display: flex; align-items: center; gap: 14px; margin-top: 22px; }
.primary, .secondary { border-radius: 8px; padding: 11px 17px; font-weight: 800; border: 1px solid transparent; }
.button-link { display: inline-block; text-decoration: none; }
.support-card { border-color: #b7e3d5; }
.offer-card { border-color: #f4c7a1; background: #fffaf5; }
.offer-card small { display: block; margin: 12px 0 16px; line-height: 1.5; }
.template-summary { display: grid; gap: 8px; padding: 14px; margin: 14px 0; background: #f6f7f9; border-radius: 8px; }
.guide pre { overflow-x: auto; margin: 14px 0; padding: 16px; border-radius: 8px; background: #1f2933; color: #f8fafc; line-height: 1.6; white-space: pre-wrap; }
.guide-table { width: 100%; border-collapse: collapse; margin-top: 14px; font-size: 14px; }
.guide-table th, .guide-table td { padding: 9px 10px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
.guide-table th { background: #f6f7f9; }
.offer-guide { border-color: #f4c7a1; }
.primary { background: var(--brand); color: white; }
.primary:hover { background: var(--brand-dark); }
.secondary { color: var(--brand-dark); background: #edf8f5; border-color: #b7e3d5; }
.inline-message { font-size: 14px; color: var(--brand-dark); }
.alert { padding: 13px 16px; margin-bottom: 18px; border-radius: 8px; background: #fff4ed; border: 1px solid #f4c7a1; color: var(--warning); }
.warning { background: #fff8eb; border-left: 4px solid #f79009; padding: 12px 14px; color: #7a2e0b; }
.loading { padding: 24px; text-align: center; color: var(--muted); }
.hidden { display: none !important; }
.empty { color: var(--muted); padding: 18px 0; }
.guides { display: grid; gap: 16px; }
.guide { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 20px; }
.guide ol { margin: 12px 0 0; padding-left: 22px; line-height: 1.8; }
.billing-card { display: flex; justify-content: space-between; gap: 20px; align-items: center; max-width: 760px; }
.list { display: grid; gap: 10px; }
.list-row { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.status { border-radius: 999px; padding: 4px 9px; font-size: 12px; font-weight: 800; background: #eef2f6; }
.status.ok { color: #006e52; background: #e9f8f3; }
.status.error { color: var(--danger); background: #fef3f2; }
@media (max-width: 720px) {
    .shell { padding: 22px 14px 48px; }
    .topbar, .billing-card { flex-direction: column; }
    .grid.three, .grid.two, .health-grid { grid-template-columns: 1fr; }
    .summary-grid { grid-template-columns: 1fr 1fr; }
    .badge { align-self: flex-start; }
    .overview-card, .diagnostic-message-row, .flow-row { align-items: flex-start; flex-direction: column; }
    .overview-badge, .diagnostic-message-status { align-self: flex-start; text-align: left; }
    .diagnostic-message-row { display: flex; }
    .inline-form { display: block; }
    .inline-form button { margin-top: 12px; width: 100%; }
    .timeline-order { flex-direction: column; }
}
