:root {
  --ink: #151922;
  --muted: #697386;
  --line: #e3e7ed;
  --paper: #f5f7fa;
  --white: #fff;
  --green: #079455;
  --green-dark: #067647;
  --green-soft: #eafaf2;
  --lime: #b9f36a;
  --amber: #b54708;
  --amber-soft: #fff5e8;
  --red: #d92d20;
  --red-soft: #fff0ee;
  --blue: #1769e0;
  --blue-dark: #0f50b5;
  --blue-soft: #eaf2ff;
  --violet-soft: #f1edff;
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 12px 32px rgba(16, 24, 40, .06);
  --shadow-hover: 0 2px 4px rgba(16, 24, 40, .05), 0 18px 42px rgba(16, 24, 40, .09);
  --radius: 20px;
}

* { box-sizing: border-box; }
html { background: var(--paper); color: var(--ink); font-family: "Segoe UI", Arial, sans-serif; }
body { margin: 0; min-width: 320px; }
a { color: inherit; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }

.topbar {
  align-items: center;
  background: rgba(245, 246, 242, .94);
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  min-height: 76px;
  padding: 0 clamp(20px, 4vw, 64px);
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(14px);
}
.brand { align-items: center; display: inline-flex; gap: 12px; text-decoration: none; width: fit-content; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 15px; letter-spacing: -.02em; }
.brand small { color: var(--muted); font-size: 10px; letter-spacing: .08em; margin-top: 2px; text-transform: uppercase; }
.brand-mark { align-items: center; background: var(--ink); border-radius: 11px; color: var(--lime); display: inline-flex; font-size: 17px; font-weight: 800; height: 38px; justify-content: center; width: 38px; }
.brand-mark.large { border-radius: 15px; font-size: 24px; height: 54px; width: 54px; }
.main-nav { align-items: center; display: flex; gap: 6px; }
.main-nav a { border-radius: 10px; color: var(--muted); font-size: 14px; font-weight: 700; padding: 10px 16px; text-decoration: none; }
.main-nav a:hover, .main-nav a[aria-current="page"] { background: var(--white); box-shadow: 0 2px 10px rgba(23, 34, 29, .05); color: var(--ink); }
.user-menu { align-items: center; display: flex; gap: 14px; justify-self: end; }
.user-menu > .user-name { color: var(--muted); font-size: 13px; }
.user-menu form { margin: 0; }
.service-balances { align-items: center; display: flex; gap: 7px; }
.balance-chip { align-items: center; background: var(--white); border: 1px solid var(--line); border-radius: 11px; display: flex; gap: 7px; min-height: 43px; padding: 6px 10px; white-space: nowrap; }
.balance-chip > span:last-child { display: block; }
.balance-chip small, .balance-chip strong { display: block; line-height: 1.15; }
.balance-chip small { color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.balance-chip strong { color: var(--ink); font-size: 12px; margin-top: 3px; }
.balance-dot { background: var(--green); border-radius: 50%; box-shadow: 0 0 0 4px var(--green-soft); height: 7px; width: 7px; }
.balance-chip.is-stale .balance-dot { background: var(--amber); box-shadow: 0 0 0 4px var(--amber-soft); }
.utility-link { color: var(--muted); font-size: 11px; font-weight: 700; text-decoration: none; }
.utility-link:hover { color: var(--green); }
.mailing-title-link { color: var(--ink); text-decoration: none; }
.mailing-title-link:hover { color: var(--green); }

.page-shell { margin: 0 auto; max-width: 1540px; padding: 48px clamp(20px, 4vw, 64px) 80px; }
.page-heading { align-items: end; display: flex; justify-content: space-between; margin-bottom: 28px; }
.page-heading.compact { align-items: center; }
.page-heading h1 { font-size: clamp(34px, 4.2vw, 58px); letter-spacing: -.055em; line-height: .98; margin: 7px 0 10px; }
.page-heading p { color: var(--muted); font-size: 15px; margin: 0; }
.eyebrow { color: var(--green); font-size: 11px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.back-link { color: var(--muted); display: block; font-size: 13px; font-weight: 700; margin-bottom: 12px; text-decoration: none; }
.back-link:hover { color: var(--green); }
.muted { color: var(--muted); }

.button {
  align-items: center;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 11px;
  color: var(--ink);
  cursor: pointer;
  display: inline-flex;
  font-size: 13px;
  font-weight: 750;
  justify-content: center;
  min-height: 42px;
  padding: 0 17px;
  text-decoration: none;
  transition: border-color .15s, transform .15s, background .15s;
}
.button:hover { border-color: #aeb9b1; transform: translateY(-1px); }
.button.primary { background: var(--green); border-color: var(--green); color: var(--white); box-shadow: 0 9px 24px rgba(31, 112, 77, .18); }
.button.primary:hover { background: var(--green-dark); }
.button:disabled { cursor: not-allowed; opacity: .45; transform: none; }
.button.danger { color: var(--red); }
.button.warning { background: var(--amber-soft); border-color: #e6c28d; color: var(--amber); }
.button.small { min-height: 34px; padding: 0 12px; }
.button.full { width: 100%; }
.link-button { background: none; border: 0; color: var(--green); cursor: pointer; font-size: 12px; font-weight: 750; padding: 4px; }
.link-button.danger { color: var(--red); margin-top: 14px; width: 100%; }

.panel, .table-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.table-card { overflow: hidden; }
.table-scroll { overflow-x: auto; }
table { border-collapse: collapse; font-size: 13px; width: 100%; }
th { background: #fafbf9; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .08em; padding: 14px 18px; text-align: left; text-transform: uppercase; white-space: nowrap; }
td { border-top: 1px solid #e9edea; padding: 17px 18px; vertical-align: middle; }
td strong, td small { display: block; }
td strong { font-weight: 750; }
td small { color: var(--muted); font-size: 11px; margin-top: 4px; }
tbody tr:hover { background: #fbfcfa; }
.actions-cell { text-align: right; }
.result-number { font-size: 12px; font-weight: 800; }
.result-number.success { color: var(--green); }
.empty-state { align-items: center; display: flex; flex-direction: column; gap: 7px; justify-content: center; min-height: 180px; text-align: center; }
.empty-state strong { font-size: 17px; }
.empty-state span { color: var(--muted); }

.status { background: #eef1ef; border-radius: 999px; color: #58615c; display: inline-flex; font-size: 10px; font-weight: 800; letter-spacing: .04em; padding: 6px 9px; text-transform: uppercase; white-space: nowrap; }
.status.large { font-size: 11px; padding: 8px 12px; }
.status-success, .status-sent, .status-valid, .status-completed { background: var(--green-soft); color: var(--green); }
.status-warning, .status-waiting_daily_limit, .status-waiting_schedule, .status-waiting_validation { background: var(--amber-soft); color: var(--amber); }
.status-running, .status-sending { background: var(--blue-soft); color: var(--blue); }
.status-error, .status-send_error, .status-invalid { background: var(--red-soft); color: var(--red); }
.status-draft, .status-paused, .status-pending, .status-neutral { background: #eef1ef; color: #606a64; }
.status-ready { background: #eaf3d0; color: #547114; }
.status-cancelled, .status-skipped_invalid, .status-unknown { background: #f1ece7; color: #786657; }

.messages { display: grid; gap: 8px; margin-bottom: 18px; }
.message { background: var(--blue-soft); border: 1px solid #c7d9eb; border-radius: 12px; color: var(--blue); font-size: 13px; padding: 13px 16px; }
.message-success { background: var(--green-soft); border-color: #c5dfcf; color: var(--green); }
.message-error { background: var(--red-soft); border-color: #eccdc7; color: var(--red); }

.form-layout { align-items: start; display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr) 290px; }
.form-panel { padding: clamp(22px, 3.2vw, 42px); }
.form-panel.narrow { margin: 0 auto; max-width: 880px; }
.side-panel { padding: 24px; position: sticky; top: 98px; }
.side-panel h3 { font-size: 15px; margin: 0 0 16px; }
.section-heading { align-items: flex-start; display: flex; gap: 14px; margin: 32px 0 18px; }
.section-heading:first-child { margin-top: 0; }
.section-heading > span { align-items: center; background: var(--ink); border-radius: 8px; color: var(--lime); display: flex; flex: 0 0 32px; font-family: Consolas, monospace; font-size: 10px; height: 32px; justify-content: center; }
.section-heading h2 { font-size: 17px; letter-spacing: -.025em; margin: 1px 0 4px; }
.section-heading p { color: var(--muted); font-size: 12px; margin: 0; }
.form-grid { display: grid; gap: 17px; grid-template-columns: 1fr 1fr; }
.field { min-width: 0; }
.field.span-2 { grid-column: span 2; }
.field > label { display: block; font-size: 11px; font-weight: 800; margin: 0 0 7px; }
.field > small { color: var(--muted); display: block; font-size: 10px; line-height: 1.45; margin-top: 6px; }
input[type="text"], input[type="email"], input[type="password"], input[type="number"], input[type="search"], select, textarea {
  background: #fbfcfa;
  border: 1px solid #ccd4ce;
  border-radius: 10px;
  color: var(--ink);
  min-height: 44px;
  outline: none;
  padding: 10px 12px;
  transition: border .15s, box-shadow .15s, background .15s;
  width: 100%;
}
textarea { line-height: 1.6; resize: vertical; }
input:focus, select:focus, textarea:focus { background: var(--white); border-color: var(--green); box-shadow: 0 0 0 3px rgba(31, 112, 77, .1); }
.checkbox-field { align-items: center; display: flex; gap: 9px; padding-top: 26px; }
.checkbox-field input { accent-color: var(--green); height: 18px; width: 18px; }
.checkbox-field label { margin: 0; }
.errorlist { color: var(--red); font-size: 11px; list-style: none; margin: 5px 0 0; padding: 0; }
.form-error { background: var(--red-soft); border-radius: 10px; color: var(--red); font-size: 12px; margin-bottom: 18px; padding: 12px 14px; }
.form-error ul { margin: 0; padding-left: 18px; }
.form-actions { align-items: center; border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; margin-top: 32px; padding-top: 22px; }
.check-result { background: var(--paper); border-radius: 12px; margin-bottom: 14px; padding: 15px; }
.check-result strong, .check-result span { display: block; }
.check-result strong { font-size: 12px; }
.check-result span { color: var(--muted); font-size: 10px; margin-top: 4px; }
.check-result.success { background: var(--green-soft); color: var(--green); }
.check-result.progress { background: var(--amber-soft); color: var(--amber); }
.subject-variants-label { align-items: center; display: flex; justify-content: space-between; margin-bottom: 8px; }
.subject-variants-label strong { font-size: 11px; }
.subject-variants-label span { color: var(--muted); font-size: 9px; }
.subject-lines-input { line-height: 1.55; min-height: 170px; resize: vertical; white-space: pre-wrap; }
.subject-variants { display: grid; gap: 9px; }
.subject-variant { align-items: end; background: #f5f7f4; border: 1px solid var(--line); border-radius: 11px; display: grid; gap: 8px; grid-template-columns: 1fr auto; padding: 10px; }
.subject-variant label { color: var(--muted); font-size: 9px; font-weight: 700; }
.subject-variant input { background: var(--white); margin-top: 5px; width: 100%; }
.remove-subject { background: transparent; border: 0; color: var(--red); cursor: pointer; font-size: 9px; font-weight: 800; padding: 12px 8px; }
.add-subject { margin-top: 9px; }
.review-subjects { display: grid; gap: 4px; margin: 0; padding-left: 18px; }
.rich-body-field { margin-top: 18px; }
.rich-editor { background: #fff; border: 1px solid #ccd4ce; border-radius: 12px; overflow: hidden; transition: border .15s, box-shadow .15s; }
.rich-editor:focus-within { border-color: var(--green); box-shadow: 0 0 0 3px rgba(31, 112, 77, .1); }
.rich-editor-toolbar { align-items: center; background: #f5f7f4; border-bottom: 1px solid var(--line); display: flex; gap: 6px; padding: 8px; }
.rich-editor-toolbar button { align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); cursor: pointer; display: inline-flex; font-size: 10px; font-weight: 750; gap: 6px; min-height: 34px; padding: 0 10px; }
.rich-editor-toolbar button:hover { background: var(--green-soft); border-color: #bcd8c6; }
.rich-editor-toolbar button > strong, .rich-editor-toolbar button > u { font-size: 14px; }
.rich-editor-surface { color: var(--ink); font-size: 13px; line-height: 1.65; min-height: 250px; outline: 0; overflow-wrap: anywhere; padding: 14px; white-space: normal; }
.rich-editor-surface p, .mail-preview-body p { margin: 0 0 1em; }
.rich-editor-surface p:last-child, .mail-preview-body p:last-child { margin-bottom: 0; }
.rich-editor-surface:empty::before { color: #98a19b; content: "Введите текст письма…"; pointer-events: none; }
.rich-editor-source { display: none; }
.file-field input { border: 1px dashed #9dab9f; cursor: pointer; padding: 24px; }
.notice { align-items: flex-start; background: #f0f4ed; border-radius: 12px; display: flex; flex-direction: column; gap: 4px; margin-top: 24px; padding: 16px; }
.notice strong { font-size: 12px; }
.notice span { color: var(--muted); font-size: 11px; }

.composer { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr) 330px; }
.compose-fields, .variables-panel, .preview-panel { padding: 26px; }
.variables-panel { align-self: stretch; }
.sticky-panel { position: sticky; top: 100px; }
.variables-panel h3 { align-items: center; display: flex; font-size: 15px; justify-content: space-between; margin: 0 0 13px; }
.variables-panel h3 span { background: var(--green-soft); border-radius: 999px; color: var(--green); font-size: 10px; padding: 4px 8px; }
.variable-list { display: grid; gap: 6px; margin-top: 12px; max-height: 480px; overflow-y: auto; padding-right: 3px; }
.variable-chip { align-items: center; background: #f7f9f6; border: 1px solid var(--line); border-radius: 9px; cursor: pointer; display: flex; gap: 8px; justify-content: space-between; min-height: 36px; padding: 7px 9px; text-align: left; }
.variable-chip:hover { background: var(--green-soft); border-color: #bcd8c6; }
.variable-chip code { font-family: Consolas, monospace; font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.variable-chip span { color: var(--green); font-size: 17px; }
.preview-panel { grid-column: 1 / -1; }
.preview-list { display: grid; gap: 12px; grid-template-columns: repeat(3, 1fr); margin-top: 14px; }
.mail-preview { background: #f8faf7; border: 1px solid var(--line); border-radius: 12px; min-width: 0; padding: 16px; }
.mail-preview > span { color: var(--muted); display: block; font-size: 9px; font-weight: 800; letter-spacing: .08em; margin-bottom: 10px; text-transform: uppercase; }
.mail-preview > strong { display: block; font-size: 12px; margin-bottom: 12px; overflow-wrap: anywhere; }
.mail-preview pre { color: #3f4b44; font-family: "Segoe UI", Arial, sans-serif; font-size: 10px; line-height: 1.55; margin: 0; max-height: 180px; overflow: auto; white-space: pre-wrap; }
.mail-preview-body { color: #3f4b44; font-size: 10px; line-height: 1.55; max-height: 220px; overflow: auto; overflow-wrap: anywhere; white-space: normal; }
.mail-preview-body strong { display: inline; font-size: inherit; margin: 0; }
.mailing-body-preview { background: #f5f7f4; border-radius: 10px; font-size: 12px; margin-top: 16px; padding: 15px; }
.composer-actions { align-items: center; display: flex; gap: 10px; grid-column: 1 / -1; justify-content: flex-end; }
.wide { grid-column: 1 / -1; }

.action-bar { align-items: center; display: flex; justify-content: space-between; margin-bottom: 18px; }
.mailing-message-summary { margin-bottom: 18px; padding: 22px 24px; }
.mailing-message-heading { align-items: flex-start; display: flex; gap: 20px; justify-content: space-between; }
.mailing-message-heading h2 { font-size: 18px; margin: 5px 0 0; }
.mailing-message-heading a { color: var(--green); font-size: 11px; font-weight: 800; text-decoration: none; white-space: nowrap; }
.mailing-message-summary pre { background: #f5f7f4; border-radius: 10px; color: var(--ink); font-family: inherit; font-size: 12px; line-height: 1.65; margin: 16px 0 0; max-height: 220px; overflow: auto; padding: 15px; white-space: pre-wrap; }
.mailing-message-summary > p { color: var(--muted); font-size: 10px; margin: 10px 0 0; }
.mailing-ab-summary { display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 16px; }
.mailing-ab-summary > article { background: #f8fafc; border: 1px solid #edf0f4; border-radius: 14px; padding: 13px; }
.mailing-ab-summary > article > span { color: var(--blue); font-size: 9px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.mailing-ab-summary .mailing-body-preview { margin-top: 9px; }
.action-group { display: flex; gap: 8px; }
.action-group form { margin: 0; }
.stats-grid { display: grid; gap: 12px; grid-template-columns: 1.2fr repeat(3, 1fr); margin-bottom: 22px; }
.stat-card { background: var(--white); border: 1px solid var(--line); border-radius: 15px; min-height: 132px; padding: 18px; }
.stat-card > span { color: var(--muted); display: block; font-size: 10px; font-weight: 800; letter-spacing: .07em; margin-bottom: 12px; text-transform: uppercase; }
.stat-card > strong { display: block; font-size: 30px; letter-spacing: -.05em; line-height: 1; }
.stat-card > small { color: var(--muted); display: block; font-size: 10px; margin-top: 9px; }
.hero-stat { background: var(--ink); color: var(--white); grid-row: span 2; min-height: 276px; padding: 26px; }
.hero-stat > span, .hero-stat > small { color: #aebbb4; }
.hero-stat > strong { font-size: 70px; margin-top: 38px; }
.progress { background: #34433b; border-radius: 99px; height: 6px; margin-top: 24px; overflow: hidden; }
.progress i { background: var(--lime); display: block; height: 100%; }
.limit-card, .time-card { grid-column: span 1; }
.time-card { grid-column: span 2; }
.time-card > strong { font-size: 20px; letter-spacing: -.02em; }
.recipients-section { margin-top: 20px; }
.table-toolbar { align-items: center; display: flex; justify-content: space-between; padding: 20px; }
.table-toolbar h2 { font-size: 17px; margin: 0 0 4px; }
.table-toolbar p { color: var(--muted); font-size: 11px; margin: 0; }
.filters { display: flex; gap: 7px; }
.filters select { font-size: 11px; min-height: 34px; padding: 6px 9px; width: auto; }
.recipients-table { font-size: 11px; }
.recipients-table td, .recipients-table th { padding-left: 12px; padding-right: 12px; }
.reason-cell { max-width: 230px; overflow-wrap: anywhere; }
.pagination { align-items: center; border-top: 1px solid var(--line); display: flex; font-size: 11px; justify-content: space-between; padding: 14px 18px; }
.pagination div { display: flex; gap: 7px; }
.results-summary { display: grid; gap: 12px; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 22px; }
.results-summary article { background: var(--white); border: 1px solid var(--line); border-radius: 16px; min-height: 142px; padding: 20px; }
.results-summary span { color: var(--muted); display: block; font-size: 9px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.results-summary strong { display: block; font-size: 36px; letter-spacing: -.05em; line-height: 1; margin-top: 18px; }
.results-summary small { color: var(--muted); display: block; font-size: 10px; margin-top: 9px; }
.results-summary .result-last-time { font-size: 22px; letter-spacing: -.03em; }
.results-filters { flex-wrap: wrap; justify-content: flex-end; }
.results-filters input { font-size: 11px; min-height: 34px; min-width: 210px; padding: 6px 10px; width: auto; }
.delivery-results-table td, .delivery-results-table th { padding-left: 16px; padding-right: 16px; }
.delivery-results-table td { vertical-align: middle; }
.delivery-results-table td > small { color: var(--muted); display: block; font-size: 9px; margin-top: 5px; }
.delivery-results-table .smtp-result { max-width: 260px; overflow-wrap: anywhere; }
.sent-content-cell { min-width: 165px; vertical-align: top; }
.sent-message-details { width: min(440px, 70vw); }
.sent-message-details:not([open]) { width: auto; }
.sent-message-details summary { color: var(--blue); cursor: pointer; font-size: 10px; font-weight: 800; list-style: none; white-space: nowrap; }
.sent-message-details summary::-webkit-details-marker { display: none; }
.sent-message-details summary::after { content: " →"; }
.sent-message-details[open] summary::after { content: " ↑"; }
.sent-message-card { background: #f8fafc; border: 1px solid var(--line); border-radius: 13px; display: grid; gap: 7px; margin-top: 12px; padding: 15px; }
.sent-message-card > span { color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .08em; margin-top: 5px; text-transform: uppercase; }
.sent-message-card > strong { color: var(--ink); font-size: 12px; overflow-wrap: anywhere; }
.sent-message-card > small { color: var(--muted); font-size: 9px; margin-top: 7px; }
.sent-message-body { background: var(--white); border: 1px solid #edf0f4; border-radius: 10px; color: #3f4b44; font-size: 11px; line-height: 1.6; max-height: 280px; overflow: auto; overflow-wrap: anywhere; padding: 13px; }
.sent-message-body p { margin: 0 0 12px; }
.sent-message-body p:last-child { margin-bottom: 0; }
.content-retention-state { color: var(--muted); display: inline-block; font-size: 9px; line-height: 1.45; max-width: 150px; }
.content-retention-state.is-expired { color: var(--amber); }
.sales-results-card { margin-bottom: 22px; }
.sales-results-toolbar { gap: 20px; }
.sales-results-toolbar .eyebrow { display: block; margin-bottom: 6px; }
.sales-results-actions { align-items: center; display: flex; flex: 0 0 auto; gap: 10px; }
.sales-results-total { background: var(--blue-soft); border-radius: 999px; color: var(--blue); font-size: 10px; font-weight: 800; padding: 8px 11px; text-transform: uppercase; white-space: nowrap; }
.sales-results-table { min-width: 1120px; }
.sales-results-limit { border-top: 1px solid var(--line); color: var(--muted); font-size: 10px; padding: 13px 20px; }
.sales-status-sent { background: var(--green-soft); color: var(--green-dark); }
.sales-status-invalid, .sales-status-error { background: var(--red-soft); color: var(--red); }
.sales-status-suppressed { background: var(--amber-soft); color: var(--amber); }
.sales-status-validating { background: var(--blue-soft); color: var(--blue); }

/* Fast follow-up after a sales call */
.sales-email-shell { max-width: 1500px; }
.sales-email-heading > div { max-width: 880px; }
.sales-email-grid { align-items: stretch; display: grid; gap: 20px; grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr); margin-bottom: 22px; }
.sales-email-form, .sales-email-process { padding: clamp(24px, 3.2vw, 38px); }
.sales-email-form-head { align-items: center; display: flex; gap: 14px; margin-bottom: 28px; }
.sales-email-form-head h2 { font-size: 22px; letter-spacing: -.035em; margin: 0 0 4px; }
.sales-email-form-head p { color: var(--muted); font-size: 11px; margin: 0; }
.sales-email-step { align-items: center; background: var(--blue); border-radius: 12px; color: var(--white); display: inline-flex; flex: 0 0 42px; font-size: 14px; font-weight: 850; height: 42px; justify-content: center; }
.sales-email-form .field + .field { margin-top: 19px; }
.sales-email-form input[type="email"] { font-size: 18px; min-height: 58px; padding: 14px 16px; }
.sales-email-form select { min-height: 54px; }
.sales-email-submit { margin-top: 26px; min-height: 52px; width: 100%; }
.sales-email-submit-note { color: var(--muted); font-size: 10px; line-height: 1.5; margin: 10px 0 0; text-align: center; }
.sales-email-empty-template { background: var(--amber-soft); border: 1px solid #f3d6a8; border-radius: 14px; display: grid; gap: 6px; margin-top: 24px; padding: 16px; }
.sales-email-empty-template strong { color: var(--amber); font-size: 13px; }
.sales-email-empty-template span { color: var(--muted); font-size: 11px; line-height: 1.5; }
.sales-email-empty-template a { color: var(--blue); font-size: 11px; font-weight: 800; margin-top: 3px; text-decoration: none; }
.sales-email-process { background: linear-gradient(145deg, #172033, #102848); border: 0; color: var(--white); }
.sales-email-process .eyebrow { color: #8bbaff; }
.sales-email-process ol { display: grid; gap: 0; list-style: none; margin: 22px 0 0; padding: 0; }
.sales-email-process li { align-items: flex-start; border-top: 1px solid rgba(255, 255, 255, .1); display: flex; gap: 13px; padding: 17px 0; }
.sales-email-process li > span { align-items: center; background: rgba(98, 166, 255, .15); border-radius: 9px; color: #9cc6ff; display: inline-flex; flex: 0 0 30px; font-size: 11px; font-weight: 850; height: 30px; justify-content: center; }
.sales-email-process li strong, .sales-email-process li small { display: block; }
.sales-email-process li strong { font-size: 13px; }
.sales-email-process li small { color: #9fb0c6; font-size: 10px; line-height: 1.45; margin-top: 4px; }
.sales-email-result { align-items: flex-start; border-left: 4px solid var(--blue); display: flex; gap: 18px; margin-bottom: 22px; padding: 25px; }
.sales-email-result.status-sent { border-left-color: var(--green); }
.sales-email-result.status-invalid, .sales-email-result.status-error { border-left-color: var(--red); }
.sales-email-result.status-suppressed { border-left-color: var(--amber); }
.sales-email-result-mark { align-items: center; background: var(--blue-soft); border-radius: 14px; color: var(--blue); display: inline-flex; flex: 0 0 48px; font-size: 22px; font-weight: 900; height: 48px; justify-content: center; }
.sales-email-result.status-sent .sales-email-result-mark { background: var(--green-soft); color: var(--green); }
.sales-email-result.status-invalid .sales-email-result-mark, .sales-email-result.status-error .sales-email-result-mark { background: var(--red-soft); color: var(--red); }
.sales-email-result.status-suppressed .sales-email-result-mark { background: var(--amber-soft); color: var(--amber); }
.sales-email-result-copy { min-width: 0; width: 100%; }
.sales-email-result-copy h2 { font-size: 26px; letter-spacing: -.04em; margin: 5px 0 7px; }
.sales-email-result-copy > p { color: var(--muted); font-size: 12px; margin: 0; }
.sales-email-result-error { background: var(--red-soft); border-radius: 11px; color: var(--red); font-size: 12px; margin-top: 16px; padding: 12px 14px; }
.sales-email-result-copy dl { display: grid; gap: 9px; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 20px 0 0; }
.sales-email-result-copy dl > div { background: #f8fafc; border: 1px solid #edf0f4; border-radius: 12px; min-width: 0; padding: 13px; }
.sales-email-result-copy dt { color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.sales-email-result-copy dd { font-size: 11px; font-weight: 750; margin: 7px 0 0; overflow-wrap: anywhere; }
.sales-email-preview { margin-top: 18px; width: min(720px, 100%); }
.sales-email-history { margin-top: 0; }
.sales-email-history .table-toolbar .eyebrow { display: block; margin-bottom: 5px; }
.section-link { color: var(--blue); font-size: 11px; font-weight: 800; text-decoration: none; }
.sales-module-nav { align-items: center; background: rgba(255, 255, 255, .86); border: 1px solid var(--line); border-radius: 16px; display: flex; gap: 5px; margin: 0 0 28px; overflow-x: auto; padding: 5px; width: fit-content; }
.sales-module-nav a { border-radius: 11px; color: var(--muted); font-size: 11px; font-weight: 800; padding: 11px 18px; text-decoration: none; white-space: nowrap; }
.sales-module-nav a:hover { background: #f4f7fb; color: var(--ink); }
.sales-module-nav a[aria-current="page"] { background: var(--ink); color: var(--white); box-shadow: 0 7px 18px rgba(17, 24, 39, .14); }
.page-heading-actions { align-items: center; display: flex; flex-wrap: wrap; gap: 9px; }
.page-heading-actions form { margin: 0; }
.sales-template-editor .compose-fields { min-width: 0; }
.sales-template-active { align-items: center; background: #f7f9fc; border: 1px solid var(--line); border-radius: 14px; cursor: pointer; display: flex; gap: 12px; margin-top: 22px; padding: 14px; }
.sales-template-active input { accent-color: var(--blue); height: 19px; margin: 0; width: 19px; }
.sales-template-active span, .sales-template-active strong, .sales-template-active small { display: block; }
.sales-template-active strong { font-size: 12px; }
.sales-template-active small { color: var(--muted); font-size: 10px; line-height: 1.45; margin-top: 3px; }
.sales-variable-base-link { margin-top: 14px; }
.sales-database-upload input[type="file"] { background: #f8fafc; border: 1px dashed #b8c4d5; border-radius: 14px; min-height: 84px; padding: 26px 18px; }
.sales-columns-preview, .sales-database-fields { background: #f7f9fc; border: 1px solid var(--line); border-radius: 14px; margin-top: 20px; padding: 15px; }
.sales-columns-preview > span, .sales-database-fields > span { color: var(--muted); display: block; font-size: 9px; font-weight: 800; letter-spacing: .07em; margin-bottom: 10px; text-transform: uppercase; }
.sales-columns-preview > div, .sales-database-fields > div { display: flex; flex-wrap: wrap; gap: 7px; }
.sales-columns-preview code, .sales-database-fields code { background: var(--white); border: 1px solid #dbe2eb; border-radius: 8px; color: var(--blue); font-size: 10px; padding: 6px 8px; }
.sales-database-summary article:nth-child(3) strong { color: var(--amber); }
.sales-database-summary article:nth-child(4) strong { color: var(--red); }
.sales-email-report-summary article:nth-child(2) strong { color: var(--green); }
.sales-email-report-summary article:nth-child(3) strong, .sales-email-report-summary article:nth-child(4) strong { color: var(--red); }
.sales-database-toolbar { gap: 18px; }
.sales-database-fields { border-left: 0; border-right: 0; border-radius: 0; margin: 0; padding: 14px 20px; }
.sales-contact-values { display: flex; flex-wrap: wrap; gap: 5px 11px; max-width: 680px; }
.sales-contact-values span { color: var(--muted); font-size: 9px; line-height: 1.45; }
.sales-contact-values b { color: var(--ink); }

.login-shell { align-items: center; display: flex; justify-content: center; min-height: 100vh; max-width: none; padding: 30px; }
.login-card { background: var(--white); border: 1px solid var(--line); border-radius: 26px; box-shadow: 0 30px 90px rgba(24, 41, 32, .13); display: grid; grid-template-columns: 1.1fr .9fr; max-width: 950px; min-height: 560px; overflow: hidden; width: 100%; }
.login-aside { background: var(--ink); color: var(--white); display: flex; flex-direction: column; justify-content: center; padding: clamp(38px, 7vw, 76px); position: relative; }
.login-aside h1 { font-size: clamp(39px, 5vw, 66px); letter-spacing: -.06em; line-height: .98; margin: 15px 0 24px; max-width: 530px; }
.login-aside p { color: #b8c2bc; font-size: 14px; line-height: 1.7; max-width: 470px; }
.signal-row { bottom: 38px; display: flex; gap: 6px; left: 76px; position: absolute; }
.signal-row span { background: var(--lime); border-radius: 99px; height: 7px; width: 7px; }
.signal-row span:nth-child(2) { opacity: .7; width: 24px; }.signal-row span:nth-child(3) { opacity: .4; width: 50px; }.signal-row span:nth-child(4) { opacity: .2; width: 90px; }
.login-form { align-self: center; padding: clamp(34px, 6vw, 68px); }
.login-form h2 { font-size: 27px; letter-spacing: -.04em; margin: 24px 0 7px; }
.login-form > p { font-size: 12px; margin: 0 0 30px; }
.login-form label { display: block; font-size: 11px; font-weight: 800; margin: 15px 0 7px; }
.login-form .button { margin-top: 22px; }

.dashboard-hero { background: var(--ink); border-radius: 28px; color: var(--white); display: grid; gap: clamp(30px, 6vw, 90px); grid-template-columns: minmax(0, 1.45fr) minmax(280px, .55fr); overflow: hidden; padding: clamp(34px, 6vw, 78px); position: relative; }
.dashboard-hero::after { background: var(--lime); border-radius: 50%; content: ""; filter: blur(1px); height: 210px; opacity: .1; position: absolute; right: -70px; top: -90px; width: 210px; }
.dashboard-hero h1 { font-size: clamp(42px, 6vw, 78px); letter-spacing: -.065em; line-height: .94; margin: 14px 0 22px; max-width: 920px; }
.dashboard-hero p { color: #b9c5be; font-size: 15px; line-height: 1.75; margin: 0; max-width: 740px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.dashboard-hero .button:not(.primary) { background: transparent; border-color: #4b5a52; color: var(--white); }
.readiness-card { align-self: center; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .12); border-radius: 20px; padding: 24px; position: relative; z-index: 1; }
.readiness-row { align-items: center; border-top: 1px solid rgba(255, 255, 255, .1); display: flex; justify-content: space-between; padding: 15px 0; }
.readiness-card .eyebrow + .readiness-row { margin-top: 12px; }
.readiness-row span { color: #b9c5be; font-size: 11px; }
.readiness-row strong { color: var(--lime); font-size: 20px; }
.dashboard-section { margin-top: 44px; }
.section-title { align-items: end; display: flex; justify-content: space-between; margin-bottom: 20px; }
.section-title h2, .panel-heading h2, .dashboard-panel h2, .wizard-tip h2 { font-size: 24px; letter-spacing: -.04em; margin: 5px 0 0; }
.section-title > p { color: var(--muted); font-size: 12px; margin: 0; max-width: 420px; text-align: right; }
.launch-steps { display: grid; gap: 10px; grid-template-columns: repeat(7, 1fr); }
.launch-step { background: var(--white); border: 1px solid var(--line); border-radius: 16px; display: flex; flex-direction: column; min-height: 205px; padding: 18px; text-decoration: none; transition: border-color .15s, transform .15s; }
.launch-step:hover { border-color: #aeb9b1; transform: translateY(-2px); }
.launch-step > span { align-items: center; background: var(--ink); border-radius: 9px; color: var(--lime); display: flex; font-size: 12px; font-weight: 800; height: 34px; justify-content: center; margin-bottom: 22px; width: 34px; }
.launch-step strong { font-size: 14px; }
.launch-step small { color: var(--muted); font-size: 10px; line-height: 1.5; margin-top: 7px; }
.launch-step em { color: var(--green); font-size: 9px; font-style: normal; font-weight: 800; letter-spacing: .06em; margin-top: auto; padding-top: 18px; text-transform: uppercase; }
.launch-step.is-ready { background: #f7fbf7; border-color: #c8dfd0; }
.dashboard-grid { display: grid; gap: 18px; grid-template-columns: minmax(0, 1.5fr) minmax(290px, .5fr); margin-top: 44px; }
.dashboard-panel { padding: 26px; }
.panel-heading { align-items: center; display: flex; justify-content: space-between; }
.panel-heading a, .wizard-tip > a { color: var(--green); font-size: 11px; font-weight: 750; text-decoration: none; }
.recent-list { display: grid; margin-top: 18px; }
.recent-item { align-items: center; border-top: 1px solid var(--line); display: flex; justify-content: space-between; padding: 15px 0; text-decoration: none; }
.recent-item > div:last-child { align-items: flex-end; display: flex; flex-direction: column; }
.recent-item strong, .recent-item small { display: block; }
.recent-item strong { font-size: 13px; }
.recent-item small { color: var(--muted); font-size: 9px; margin-top: 5px; }
.friendly-empty { align-items: center; display: flex; flex-direction: column; gap: 6px; justify-content: center; min-height: 150px; text-align: center; }
.friendly-empty span { color: var(--muted); font-size: 11px; }
.glossary { display: grid; gap: 0; margin: 18px 0 0; }
.glossary > div { border-top: 1px solid var(--line); padding: 13px 0; }
.glossary dt { font-size: 11px; font-weight: 800; }
.glossary dd { color: var(--muted); font-size: 10px; line-height: 1.5; margin: 4px 0 0; }
.glossary code, .wizard-tip code { background: var(--green-soft); border-radius: 4px; color: var(--green); font-size: 9px; padding: 2px 4px; }

.wizard-progress { background: var(--white); border: 1px solid var(--line); border-radius: 16px; display: grid; grid-template-columns: repeat(5, 1fr); margin-bottom: 34px; overflow: hidden; }
.wizard-progress.seven-steps { grid-template-columns: repeat(7, 1fr); }
.wizard-progress a { align-items: center; border-left: 1px solid var(--line); display: grid; gap: 1px 10px; grid-template-columns: 34px 1fr; min-height: 74px; padding: 12px 15px; text-decoration: none; }
.wizard-progress a:first-child { border-left: 0; }
.wizard-progress a > span { align-items: center; background: #edf0ee; border-radius: 50%; color: var(--muted); display: flex; font-size: 11px; font-weight: 800; grid-row: span 2; height: 32px; justify-content: center; width: 32px; }
.wizard-progress strong { font-size: 11px; }
.wizard-progress small { color: var(--muted); font-size: 8px; }
.wizard-progress .is-current { background: var(--ink); color: var(--white); }
.wizard-progress .is-current > span, .wizard-progress .is-complete > span { background: var(--lime); color: var(--ink); }
.wizard-progress .is-current small { color: #afbab4; }
.wizard-progress .is-complete { background: #f5faf6; }
.wizard-heading { align-items: end; display: flex; justify-content: space-between; margin-bottom: 26px; }
.wizard-heading h1 { font-size: clamp(35px, 4.5vw, 60px); letter-spacing: -.055em; line-height: .98; margin: 7px 0 11px; }
.wizard-heading p { color: var(--muted); font-size: 13px; line-height: 1.6; margin: 0; max-width: 790px; }
.wizard-section { margin-bottom: 28px; }
.compact-title { align-items: center; }
.compact-title p { color: var(--muted); font-size: 11px; margin: 5px 0 0; }
.sender-choice-grid { display: grid; gap: 12px; grid-template-columns: repeat(3, 1fr); }
.sender-choice { display: flex; flex-direction: column; min-height: 190px; padding: 20px; }
.sender-choice strong, .sender-choice small { display: block; }
.sender-choice strong { font-size: 14px; }
.sender-choice small { color: var(--muted); font-size: 10px; margin-top: 5px; }
.sender-choice-meta { align-items: flex-start; display: flex; flex-direction: column; gap: 8px; margin: 18px 0; }
.sender-choice-meta > span:first-child { color: var(--muted); font-family: Consolas, monospace; font-size: 9px; }
.sender-choice .button { margin-top: auto; }
.or-divider { align-items: center; color: var(--muted); display: flex; font-size: 9px; font-weight: 800; gap: 15px; letter-spacing: .08em; margin: 30px 0; text-transform: uppercase; }
.or-divider::before, .or-divider::after { background: var(--line); content: ""; height: 1px; width: 100%; }
.wizard-form { margin: 0 auto; max-width: 980px; }
.wizard-focus-grid, .review-grid { align-items: start; display: grid; gap: 20px; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); }
.wizard-main-card { padding: clamp(24px, 4vw, 42px); }
.connection-identity { align-items: center; display: flex; gap: 14px; }
.connection-icon { align-items: center; background: var(--ink); border-radius: 13px; color: var(--lime); display: flex; font-size: 20px; font-weight: 800; height: 48px; justify-content: center; width: 48px; }
.connection-identity strong, .connection-identity small { display: block; }
.connection-identity strong { font-size: 18px; }
.connection-identity small { color: var(--muted); font-size: 11px; margin-top: 4px; }
.connection-details, .review-details { border-bottom: 1px solid var(--line); border-top: 1px solid var(--line); display: grid; grid-template-columns: 1fr 1fr; margin: 26px 0; }
.connection-details > div, .review-details > div { padding: 15px 0; }
.connection-details dt, .review-details dt { color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.connection-details dd, .review-details dd { font-size: 11px; font-weight: 700; margin: 5px 0 0; overflow-wrap: anywhere; }
.wizard-actions { align-items: center; display: flex; flex-wrap: wrap; gap: 9px; justify-content: flex-end; margin-top: 22px; }
.wizard-tip { padding: 26px; }
.wizard-tip ol { color: var(--muted); font-size: 11px; line-height: 1.6; margin: 18px 0 22px; padding-left: 20px; }
.wizard-tip li { margin-bottom: 9px; padding-left: 4px; }
.wizard-tip > p { color: var(--muted); font-size: 10px; line-height: 1.6; }
.file-example { background: #f7f9f6; border: 1px solid var(--line); border-radius: 11px; display: grid; font-size: 8px; grid-template-columns: repeat(3, 1fr); margin: 18px 0; overflow: hidden; }
.file-example > * { border-bottom: 1px solid var(--line); border-left: 1px solid var(--line); overflow: hidden; padding: 8px 6px; text-overflow: ellipsis; }
.file-example code { background: var(--ink); border-radius: 0; color: var(--lime); font-weight: 800; }
.panel-help { color: var(--muted); font-size: 10px; line-height: 1.5; margin: -4px 0 14px; }
.review-summary, .launch-checklist, .final-preview { padding: 28px; }
.review-title { align-items: center; display: flex; justify-content: space-between; }
.review-title h2 { font-size: 27px; letter-spacing: -.04em; margin: 5px 0 0; }
.review-stats { display: grid; gap: 8px; grid-template-columns: repeat(4, 1fr); margin: 24px 0; }
.review-stats > div { background: #f7f9f6; border-radius: 12px; min-height: 110px; padding: 14px; }
.review-stats span { color: var(--muted); display: block; font-size: 9px; line-height: 1.35; min-height: 38px; }
.review-stats strong { display: block; font-size: 25px; letter-spacing: -.04em; margin-top: 10px; }
.review-details { border-bottom: 0; grid-template-columns: 1fr 1fr; margin-bottom: 0; }
.launch-checklist h2 { font-size: 25px; letter-spacing: -.04em; margin: 6px 0 18px; }
.launch-checklist ul { display: grid; gap: 12px; list-style: none; margin: 0; padding: 0; }
.launch-checklist li { color: var(--muted); display: flex; font-size: 10px; line-height: 1.45; }
.launch-checklist li span { color: var(--green); font-weight: 900; margin-right: 8px; }
.launch-warning { background: var(--amber-soft); border-radius: 11px; color: var(--amber); margin-top: 22px; padding: 14px; }
.launch-warning strong, .launch-warning span { display: block; }
.launch-warning strong { font-size: 10px; text-transform: uppercase; }
.launch-warning span { font-size: 9px; line-height: 1.5; margin-top: 5px; }
.final-preview { margin-top: 20px; }
.review-preview-list { margin-top: 20px; }
.test-email-card { align-items: center; display: grid; gap: 24px; grid-template-columns: minmax(0, 1fr) minmax(360px, .7fr); margin-top: 20px; padding: 24px 28px; }
.test-email-card h2 { font-size: 20px; letter-spacing: -.035em; margin: 5px 0 6px; }
.test-email-card p { color: var(--muted); font-size: 10px; line-height: 1.5; margin: 0; max-width: 650px; }
.test-email-card form { display: grid; gap: 7px; }
.test-email-card form > label { font-size: 10px; font-weight: 800; }
.test-email-card form > div { display: flex; gap: 8px; }
.test-email-card input { min-width: 0; }
.test-email-card button { white-space: nowrap; }
.final-launch-bar { align-items: center; background: var(--ink); border-radius: 18px; color: var(--white); display: flex; justify-content: space-between; margin-top: 20px; padding: 22px 26px; }
.final-launch-bar > div:last-child { display: flex; gap: 9px; }
.final-launch-bar strong, .final-launch-bar span { display: block; }
.final-launch-bar strong { font-size: 14px; }
.final-launch-bar span { color: #b7c2bc; font-size: 9px; margin-top: 5px; }
.final-launch-bar .button:not(.primary) { background: transparent; border-color: #4b5a52; color: var(--white); }
.launch-button { min-width: 190px; }

.validation-balance-grid { display: grid; gap: 12px; grid-template-columns: repeat(4, 1fr); margin-bottom: 20px; }
.validation-number { min-height: 145px; padding: 20px; }
.validation-number > span { color: var(--muted); display: block; font-size: 9px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.validation-number > strong { display: block; font-size: 38px; letter-spacing: -.05em; margin-top: 18px; }
.validation-number > small { color: var(--muted); display: block; font-size: 9px; line-height: 1.4; margin-top: 8px; }
.validation-number.status-number { background: var(--ink); color: var(--white); }
.validation-number.status-number > strong { color: var(--lime); font-size: 19px; letter-spacing: -.02em; margin-top: 24px; }
.validation-number.status-number > span, .validation-number.status-number > small { color: #b4c0b9; }
.validation-alert { align-items: center; border-radius: 14px; display: grid; gap: 5px 20px; grid-template-columns: 1fr auto; margin-bottom: 20px; padding: 18px 20px; }
.validation-alert strong { font-size: 14px; }
.validation-alert span { font-size: 10px; grid-column: 1; line-height: 1.5; }
.validation-alert a { font-size: 11px; font-weight: 800; grid-column: 2; grid-row: 1 / span 2; text-decoration: none; }
.validation-alert form { grid-column: 2; grid-row: 1 / span 2; margin: 0; }
.validation-alert.balance { background: var(--amber-soft); color: var(--amber); }
.validation-alert.error { background: var(--red-soft); color: var(--red); }
.validation-start-grid { margin-top: 20px; }
.validation-running-card { padding: clamp(24px, 4vw, 42px); }
.validation-running-head { align-items: center; display: flex; justify-content: space-between; }
.validation-running-head h2 { font-size: 25px; letter-spacing: -.04em; margin: 6px 0 0; }
.validation-running-head > strong { color: var(--green); font-size: 36px; letter-spacing: -.05em; }
.validation-progress { background: #e7ece8; border-radius: 999px; height: 10px; margin: 24px 0 18px; overflow: hidden; }
.validation-progress i { background: var(--green); border-radius: inherit; display: block; height: 100%; transition: width .25s ease; }
.validation-live-stats { display: flex; flex-wrap: wrap; gap: 10px 24px; }
.validation-live-stats span { color: var(--muted); font-size: 10px; }
.validation-live-stats strong { color: var(--ink); }
.validation-running-card > p { color: var(--muted); font-size: 10px; margin: 18px 0 0; }
.validation-complete-card { align-items: center; display: flex; justify-content: space-between; padding: 25px 28px; }
.validation-complete-card > div { align-items: center; display: flex; gap: 17px; }
.validation-check { align-items: center; background: var(--green-soft); border-radius: 50%; color: var(--green); display: flex; font-size: 23px; font-weight: 900; height: 52px; justify-content: center; width: 52px; }
.validation-complete-card h2 { font-size: 22px; letter-spacing: -.035em; margin: 5px 0; }
.validation-complete-card p { color: var(--muted); font-size: 10px; margin: 0; }
.validation-results { margin-top: 38px; }
.validation-results td small { margin: 0; max-width: 250px; }
.validation-analytics-grid { display: grid; gap: 12px; grid-template-columns: repeat(7, 1fr); margin: 20px 0 28px; }
.validation-analytics-card { min-height: 132px; padding: 18px; }
.validation-analytics-card > span { color: var(--muted); display: block; font-size: 8px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.validation-analytics-card > strong { display: block; font-size: 32px; letter-spacing: -.05em; margin-top: 15px; }
.validation-analytics-card > small { color: var(--muted); display: block; font-size: 8px; line-height: 1.45; margin-top: 7px; }
.validation-analytics-card.duplicate > strong, .validation-analytics-card.pending > strong { color: var(--amber); }
.validation-analytics-card.checked > strong { color: var(--green); }
.validation-analytics-card.invalid > strong { color: var(--red); }
.validation-analytics-card.failed > strong { color: var(--blue); }
.validation-table-heading { align-items: flex-end; display: flex; justify-content: space-between; margin: 0 0 12px; }
.validation-table-heading h3 { font-size: 19px; margin: 4px 0 0; }
.validation-table-heading p { color: var(--muted); font-size: 9px; margin: 0; }
.enrichment-stats .validation-number > strong { color: var(--green); }
.enrichment-stats .status-number > strong { color: var(--lime); }
.status-found, .status-existing { background: var(--green-soft); color: var(--green); }
.status-not_found, .status-invalid_inn, .status-duplicate { background: var(--amber-soft); color: var(--amber); }
.compact-section { margin-top: 24px; }
.enrichment-checklist { display: grid; gap: 10px; grid-template-columns: repeat(2, minmax(0, 1fr)); margin: 14px 0; }
.enrichment-check-item { align-items: flex-start; background: #fff; border: 1px solid var(--line); border-radius: 14px; cursor: pointer; display: flex; gap: 11px; padding: 14px; }
.enrichment-check-item:has(input:checked) { background: #f3faf6; border-color: var(--green); box-shadow: inset 0 0 0 1px var(--green); }
.enrichment-check-item input { accent-color: var(--green); height: 18px; margin-top: 2px; width: 18px; }
.enrichment-check-item span { display: grid; gap: 4px; }
.enrichment-check-item small { color: var(--muted); line-height: 1.35; }
.enrichment-variable-summary { align-items: center; display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.enrichment-variable-summary code { background: var(--green-soft); border-radius: 8px; color: var(--green); padding: 5px 7px; }
.collected-data { display: grid; gap: 8px; min-width: 260px; }
.collected-data span { display: grid; gap: 2px; }
.collected-data small { color: var(--muted); }
.draft-save-status { color: var(--muted); font-size: 10px; margin-left: auto; }

@media (max-width: 1050px) {
  .stats-grid { grid-template-columns: 1fr 1fr 1fr; }
  .hero-stat { grid-row: span 2; }
  .time-card { grid-column: span 2; }
  .preview-list { grid-template-columns: 1fr; }
  .launch-steps { grid-template-columns: repeat(3, 1fr); }
  .dashboard-hero { grid-template-columns: 1fr; }
  .sender-choice-grid { grid-template-columns: 1fr 1fr; }
  .review-stats { grid-template-columns: 1fr 1fr; }
  .validation-balance-grid { grid-template-columns: 1fr 1fr; }
  .validation-analytics-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 820px) {
  .topbar { grid-template-columns: 1fr auto; padding: 0 18px; }
  .main-nav { bottom: 0; left: 50%; max-width: calc(100vw - 20px); overflow-x: auto; position: fixed; transform: translateX(-50%); z-index: 40; background: var(--ink); border-radius: 14px 14px 0 0; padding: 7px; }
  .main-nav a { white-space: nowrap; }
  .main-nav a, .main-nav a:hover, .main-nav a[aria-current="page"] { color: #d9e1dc; background: transparent; box-shadow: none; }
  .main-nav a[aria-current="page"] { color: var(--lime); }
  .user-menu > .user-name { display: none; }
  .page-shell { padding-bottom: 105px; padding-top: 32px; }
  .form-layout, .composer { grid-template-columns: 1fr; }
  .side-panel, .sticky-panel { position: static; }
  .variables-panel { grid-row: 2; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .hero-stat { grid-column: span 2; grid-row: auto; min-height: 210px; }
  .hero-stat > strong { margin-top: 24px; }
  .login-card { grid-template-columns: 1fr; }
  .login-aside { display: none; }
  .table-toolbar { align-items: stretch; flex-direction: column; gap: 14px; }
  .dashboard-grid, .wizard-focus-grid, .review-grid { grid-template-columns: 1fr; }
  .wizard-progress { overflow-x: auto; }
  .wizard-progress a { min-width: 150px; }
  .final-launch-bar { align-items: stretch; flex-direction: column; gap: 18px; }
  .final-launch-bar > div:last-child { justify-content: flex-end; }
  .test-email-card { grid-template-columns: 1fr; }
  .validation-complete-card { align-items: stretch; flex-direction: column; gap: 20px; }
  .enrichment-checklist { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .brand > span:last-child { display: none; }
  .user-menu { gap: 8px; }
  .service-balances { gap: 5px; }
  .balance-chip { min-height: 39px; padding: 5px 7px; }
  .balance-chip strong { font-size: 11px; }
  .brand small { display: none; }
  .page-heading { align-items: flex-start; flex-direction: column; gap: 18px; }
  .page-heading h1 { font-size: 40px; }
  .form-grid { grid-template-columns: 1fr; }
  .field.span-2 { grid-column: auto; }
  .stats-grid { grid-template-columns: 1fr; }
  .hero-stat, .time-card { grid-column: auto; }
  .action-bar { align-items: stretch; flex-direction: column; gap: 10px; }
  .action-group { flex-wrap: wrap; }
  .filters { align-items: stretch; flex-direction: column; }
  .filters select { width: 100%; }
  .composer-actions { align-items: stretch; flex-direction: column; }
  .composer-actions .button { width: 100%; }
  .draft-save-status { margin-left: 0; text-align: center; }
  .main-nav { max-width: calc(100vw - 20px); overflow-x: auto; }
  .main-nav a { padding: 10px 12px; white-space: nowrap; }
  .utility-link { display: none; }
  .dashboard-hero { border-radius: 20px; margin: 0 -8px; padding: 30px 22px; }
  .dashboard-hero h1 { font-size: 43px; }
  .hero-actions, .hero-actions .button { align-items: stretch; flex-direction: column; width: 100%; }
  .section-title, .wizard-heading { align-items: flex-start; flex-direction: column; gap: 13px; }
  .section-title > p { text-align: left; }
  .launch-steps, .sender-choice-grid { grid-template-columns: 1fr; }
  .launch-step { min-height: 170px; }
  .connection-details, .review-details { grid-template-columns: 1fr; }
  .review-stats { grid-template-columns: 1fr 1fr; }
  .wizard-actions, .wizard-actions .button { align-items: stretch; flex-direction: column; width: 100%; }
  .final-launch-bar > div:last-child { flex-direction: column; }
  .final-launch-bar .button { width: 100%; }
  .test-email-card form > div { flex-direction: column; }
  .test-email-card .button { width: 100%; }
  .validation-balance-grid { grid-template-columns: 1fr; }
  .validation-analytics-grid { grid-template-columns: 1fr 1fr; }
  .validation-table-heading { align-items: flex-start; flex-direction: column; gap: 6px; }
  .validation-alert { grid-template-columns: 1fr; }
  .validation-alert a { grid-column: 1; grid-row: auto; margin-top: 5px; }
  .validation-running-head { align-items: flex-start; flex-direction: column; gap: 12px; }
  .validation-complete-card > div { align-items: flex-start; }
}

/* 2026 light admin refresh: visual layer only. */
html { background: var(--paper); color-scheme: light; font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
body { background: radial-gradient(circle at 88% 5%, rgba(23, 105, 224, .055), transparent 28rem), var(--paper); color: var(--ink); min-height: 100vh; }
::selection { background: #cfe1ff; color: #0d3268; }

a, button, input, select, textarea { transition-duration: .18s; transition-timing-function: ease; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, [contenteditable="true"]:focus-visible {
  outline: 3px solid rgba(23, 105, 224, .3);
  outline-offset: 2px;
}

.page-shell { max-width: none; padding: 42px clamp(24px, 3vw, 52px) 80px; }
.page-heading { margin-bottom: 24px; }
.page-heading h1, .wizard-heading h1 { font-size: clamp(36px, 4vw, 54px); letter-spacing: -.052em; line-height: 1; }
.page-heading p, .wizard-heading p { color: var(--muted); font-size: 14px; }
.eyebrow { color: var(--blue); font-size: 10px; letter-spacing: .12em; }
.back-link, .panel-heading a, .wizard-tip > a, .mailing-message-heading a { color: var(--blue); }

.button {
  border-color: #dfe3e9;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
  font-size: 13px;
  min-height: 46px;
  padding: 0 18px;
}
.button:hover { background: #f9fafb; border-color: #c8cfd9; box-shadow: 0 6px 18px rgba(16, 24, 40, .07); transform: translateY(-1px); }
.button.primary { background: var(--blue); border-color: var(--blue); box-shadow: 0 8px 20px rgba(23, 105, 224, .22); }
.button.primary:hover { background: var(--blue-dark); border-color: var(--blue-dark); box-shadow: 0 10px 24px rgba(23, 105, 224, .28); }
.button.small { min-height: 38px; }
.link-button { color: var(--blue); min-height: 42px; }

.panel, .table-card {
  border-color: var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.panel { overflow: clip; }
.table-card { box-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 8px 24px rgba(16, 24, 40, .045); }
th { background: #f8fafc; color: #667085; font-size: 10px; letter-spacing: .065em; padding: 15px 18px; }
td { border-color: #edf0f4; font-size: 13px; padding: 18px; }
tbody tr:hover { background: #f8fbff; }

.status { border: 1px solid transparent; font-size: 9px; letter-spacing: .055em; padding: 6px 9px; }
.status-success, .status-sent, .status-valid, .status-completed, .status-found, .status-existing { border-color: #ccebdc; }
.status-running, .status-sending { border-color: #cfe0fa; }
.status-error, .status-send_error, .status-invalid { border-color: #f4d0cc; }
.status-warning, .status-waiting_daily_limit, .status-waiting_schedule, .status-waiting_validation, .status-not_found, .status-invalid_inn, .status-duplicate { border-color: #f2ddbd; }

.messages { margin-bottom: 20px; }
.message { border-radius: 14px; box-shadow: 0 3px 12px rgba(16, 24, 40, .04); font-size: 13px; padding: 14px 17px; }

input[type="text"], input[type="email"], input[type="password"], input[type="number"], input[type="search"], select, textarea {
  background: #fbfcfe;
  border-color: #d8dee7;
  border-radius: 12px;
  min-height: 46px;
  padding: 11px 13px;
}
input:hover, select:hover, textarea:hover { border-color: #b9c2cf; }
input:focus, select:focus, textarea:focus { background: var(--white); border-color: var(--blue); box-shadow: 0 0 0 4px rgba(23, 105, 224, .1); }
.field > label, .test-email-card form > label { font-size: 12px; }
.field > small, .panel-help { font-size: 11px; }
.form-panel { padding: clamp(26px, 3.2vw, 42px); }
.side-panel { top: 28px; }
.section-heading > span { background: var(--blue-soft); border-radius: 10px; color: var(--blue); }
.section-heading h2 { font-size: 18px; }
.section-heading p { font-size: 12px; }
.file-field input { background: #f8fbff; border-color: #9ebce5; border-radius: 14px; }
.notice, .check-result { background: #f7f9fc; border: 1px solid var(--line); border-radius: 14px; }

.rich-editor { border-color: #d8dee7; border-radius: 14px; }
.rich-editor:focus-within { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(23, 105, 224, .1); }
.rich-editor-toolbar { background: #f7f9fc; }
.rich-editor-toolbar button { border-radius: 10px; min-height: 38px; }
.rich-editor-toolbar button:hover { background: var(--blue-soft); border-color: #bfd5f7; }
.rich-editor-surface { font-size: 14px; min-height: 270px; padding: 18px; }
.ab-body-editors { display: grid; gap: 18px; margin-top: 20px; }
.ab-body-variant { background: #fbfcfe; border: 1px solid #e5eaf1; border-radius: 18px; margin-top: 0; padding: 16px; }
.ab-body-variant[data-body-variant="B"] { background: #f8fbff; border-color: #dce8f8; }
.ab-variant-heading { align-items: center; display: flex; justify-content: space-between; margin-bottom: 10px; }
.ab-variant-heading label { color: var(--ink); font-size: 14px; font-weight: 850; }
.ab-variant-heading span { background: var(--blue-soft); border-radius: 999px; color: var(--blue); font-size: 9px; font-weight: 800; padding: 6px 9px; }
.ab-body-variant[data-body-variant="A"] .ab-variant-heading span { background: var(--green-soft); color: var(--green); }
.ab-body-variant > small { color: var(--muted); display: block; font-size: 9px; line-height: 1.5; margin-top: 9px; }
.ab-body-variant[data-body-variant="B"] .rich-editor-surface:empty::before { content: "Введите альтернативный текст или оставьте пустым…"; }
.subject-variant { background: #f8fafc; border-radius: 14px; padding: 12px; }
.subject-lines-input { background: #f8fafc; border-radius: 14px; font-size: 14px; padding: 15px; }
.variable-chip { background: #f8fafc; border-radius: 11px; min-height: 42px; }
.variable-chip:hover { background: var(--blue-soft); border-color: #bfd5f7; }
.variable-chip span { color: var(--blue); }
.mail-preview, .mailing-body-preview, .mailing-message-summary pre { background: #f8fafc; border-radius: 14px; }

.stats-grid { gap: 14px; }
.stat-card { border-color: var(--line); border-radius: 18px; box-shadow: 0 1px 2px rgba(16, 24, 40, .035); min-height: 140px; padding: 20px; }
.stat-card > span { font-size: 10px; }
.stat-card > strong { font-size: 34px; }
.stat-card > small { font-size: 11px; }
.hero-stat { background: linear-gradient(145deg, #172033, #111722); box-shadow: 0 18px 40px rgba(17, 24, 39, .18); }
.hero-stat > span, .hero-stat > small { color: #b7c0cf; }
.hero-stat > strong { font-size: 68px; }
.progress { background: rgba(255, 255, 255, .13); height: 8px; }
.progress i { background: linear-gradient(90deg, #57d5a0, #b9f36a); border-radius: inherit; }
.table-toolbar { padding: 22px; }
.table-toolbar h2 { font-size: 19px; }
.table-toolbar p, .pagination { font-size: 11px; }

.dashboard-hero {
  background: transparent;
  border-radius: 0;
  color: var(--ink);
  gap: 18px;
  grid-template-columns: minmax(0, 1.45fr) minmax(310px, .55fr);
  overflow: visible;
  padding: 0;
}
.dashboard-hero::after { display: none; }
.dashboard-hero > div:first-child {
  background: linear-gradient(135deg, #eef5ff 0%, #f9fbff 58%, #f1edff 100%);
  border: 1px solid #dce7f7;
  border-radius: 24px;
  box-shadow: var(--shadow);
  min-height: 400px;
  overflow: hidden;
  padding: clamp(34px, 4.5vw, 64px);
  position: relative;
}
.dashboard-hero > div:first-child::after {
  background: radial-gradient(circle, rgba(23, 105, 224, .17), rgba(23, 105, 224, 0) 70%);
  content: "";
  height: 420px;
  pointer-events: none;
  position: absolute;
  right: -150px;
  top: -190px;
  width: 420px;
}
.dashboard-hero h1 { color: var(--ink); font-size: clamp(44px, 5vw, 66px); line-height: .98; margin: 14px 0 20px; max-width: 790px; position: relative; z-index: 1; }
.dashboard-hero p { color: #5d687b; font-size: 15px; line-height: 1.7; position: relative; z-index: 1; }
.hero-actions { position: relative; z-index: 1; }
.dashboard-hero .button:not(.primary) { background: rgba(255, 255, 255, .8); border-color: #d7e0ec; color: var(--ink); }
.readiness-card { align-self: stretch; background: var(--white); border-color: var(--line); border-radius: 24px; box-shadow: var(--shadow); padding: 28px; }
.readiness-card .eyebrow + .readiness-row { margin-top: 16px; }
.readiness-row { border-color: #edf0f4; padding: 18px 0; }
.readiness-row span { color: var(--muted); font-size: 12px; }
.readiness-row strong { color: var(--ink); font-size: 25px; letter-spacing: -.04em; }

.deliverability-header-chip { text-decoration: none; }
.deliverability-header-chip.health-healthy .balance-dot { background: var(--green); box-shadow: 0 0 0 4px var(--green-soft); }
.deliverability-header-chip.health-warning .balance-dot { background: #f79009; box-shadow: 0 0 0 4px #fff4e5; }
.deliverability-header-chip.health-critical .balance-dot { background: var(--red); box-shadow: 0 0 0 4px var(--red-soft); }
.dashboard-deliverability-section .section-title { align-items: center; }
.section-link { color: var(--blue); font-size: 11px; font-weight: 800; text-decoration: none; }
.section-link:hover { color: var(--blue-dark); }
.dashboard-deliverability {
  display: grid;
  gap: 0;
  grid-template-columns: minmax(210px, .45fr) minmax(0, 1.8fr);
  overflow: hidden;
}
.dashboard-deliverability-score {
  background: linear-gradient(150deg, #172033, #102b4d);
  color: var(--white);
  min-height: 245px;
  padding: 30px;
  position: relative;
}
.dashboard-deliverability-score::after { background: #62a6ff; border-radius: 50%; content: ""; height: 130px; opacity: .14; position: absolute; right: -45px; top: -45px; width: 130px; }
.dashboard-deliverability.health-healthy .dashboard-deliverability-score { background: linear-gradient(150deg, #123f30, #102b28); }
.dashboard-deliverability.health-warning .dashboard-deliverability-score { background: linear-gradient(150deg, #69410d, #32240f); }
.dashboard-deliverability.health-critical .dashboard-deliverability-score { background: linear-gradient(150deg, #6e211c, #351613); }
.dashboard-deliverability-score .eyebrow { color: #9cc9ff; }
.dashboard-deliverability.health-healthy .dashboard-deliverability-score .eyebrow { color: #8ce3ba; }
.dashboard-deliverability-score > strong { display: block; font-size: 56px; letter-spacing: -.06em; line-height: 1; margin-top: 34px; }
.dashboard-deliverability-score > strong small { color: #9fb0c6; font-size: 19px; letter-spacing: -.02em; }
.dashboard-deliverability-score h3 { font-size: 17px; margin: 12px 0 0; }
.dashboard-deliverability-score p { bottom: 28px; color: #9fb0c6; font-size: 9px; left: 30px; margin: 0; position: absolute; }
.dashboard-deliverability-content { display: flex; flex-direction: column; min-width: 0; padding: 25px; }
.dashboard-deliverability-metrics { display: grid; flex: 1; gap: 9px; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.dashboard-deliverability-metrics > div { background: #f8fafc; border: 1px solid #e9eef5; border-radius: 14px; min-width: 0; padding: 16px; }
.dashboard-deliverability-metrics span, .dashboard-deliverability-metrics strong, .dashboard-deliverability-metrics small { display: block; }
.dashboard-deliverability-metrics span { color: var(--muted); font-size: 8px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.dashboard-deliverability-metrics strong { font-size: clamp(22px, 2.6vw, 34px); letter-spacing: -.045em; margin-top: 18px; }
.dashboard-deliverability-metrics small { color: var(--muted); font-size: 9px; line-height: 1.35; margin-top: 7px; }
.dashboard-deliverability-checks { align-items: center; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 7px; margin-top: 17px; padding-top: 16px; }
.dashboard-deliverability-checks > span { align-items: center; background: #f3f5f8; border-radius: 999px; color: var(--muted); display: inline-flex; font-size: 9px; font-weight: 800; gap: 5px; padding: 6px 9px; }
.dashboard-deliverability-checks > span i { align-items: center; background: #e8edf3; border-radius: 50%; display: inline-flex; font-size: 8px; font-style: normal; height: 16px; justify-content: center; width: 16px; }
.dashboard-deliverability-checks > span.check-pass { background: var(--green-soft); color: var(--green-dark); }
.dashboard-deliverability-checks > span.check-pass i { background: #d4f4e3; }
.dashboard-deliverability-checks > span.check-fail { background: var(--red-soft); color: var(--red); }
.dashboard-deliverability-checks > a { color: var(--blue); font-size: 9px; font-weight: 800; margin-left: auto; text-decoration: none; }
.dashboard-deliverability-alert { align-items: center; border-radius: 14px; display: flex; gap: 12px; margin-bottom: 10px; padding: 13px 17px; }
.dashboard-deliverability-alert strong { font-size: 12px; }
.dashboard-deliverability-alert span { font-size: 11px; }
.dashboard-deliverability-alert.is-critical { background: var(--red-soft); color: var(--red); }
.dashboard-deliverability-alert.is-warning { background: var(--amber-soft); color: var(--amber); }
.dashboard-deliverability-empty { align-items: center; display: flex; justify-content: space-between; padding: 24px; text-decoration: none; }
.dashboard-deliverability-empty span { color: var(--muted); font-size: 12px; }
.dashboard-deliverability-empty strong { color: var(--blue); font-size: 12px; }

.dashboard-section, .dashboard-grid { margin-top: 34px; }
.section-title { margin-bottom: 18px; }
.section-title h2, .panel-heading h2, .dashboard-panel h2, .wizard-tip h2 { font-size: 25px; }
.section-title > p { font-size: 12px; }
.launch-steps { gap: 12px; grid-template-columns: repeat(4, 1fr); }
.launch-step { border-radius: 18px; box-shadow: 0 1px 2px rgba(16, 24, 40, .03); min-height: 190px; padding: 20px; }
.launch-step:nth-child(1), .launch-step:nth-child(5) { grid-column: span 2; }
.launch-step:hover { border-color: #bdd1ee; box-shadow: var(--shadow-hover); transform: translateY(-3px); }
.launch-step > span { background: var(--blue-soft); border-radius: 11px; color: var(--blue); height: 38px; margin-bottom: 25px; width: 38px; }
.launch-step strong { font-size: 15px; }
.launch-step small { font-size: 11px; }
.launch-step em { color: var(--blue); font-size: 9px; }
.launch-step.is-ready { background: linear-gradient(145deg, #f5fff9, #fff); border-color: #cce9db; }
.launch-step.is-ready > span { background: var(--green-soft); color: var(--green); }
.dashboard-grid { gap: 18px; grid-template-columns: minmax(0, 1.65fr) minmax(310px, .55fr); }
.dashboard-panel { padding: 28px; }
.recent-item { border-color: #edf0f4; border-radius: 12px; margin: 0 -10px; padding: 16px 10px; }
.recent-item:hover { background: #f8fbff; }
.recent-item strong { font-size: 14px; }
.recent-item small, .glossary dd { font-size: 11px; }

.wizard-progress { background: transparent; border: 0; border-radius: 0; gap: 8px; overflow: visible; }
.wizard-progress a { background: rgba(255, 255, 255, .88); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 1px 2px rgba(16, 24, 40, .03); min-height: 78px; padding: 12px; }
.wizard-progress a:first-child { border-left: 1px solid var(--line); }
.wizard-progress a > span { background: #f0f2f5; color: #6b7280; height: 34px; width: 34px; }
.wizard-progress strong { font-size: 11px; }
.wizard-progress small { font-size: 9px; }
.wizard-progress .is-current { background: #172033; border-color: #172033; box-shadow: 0 10px 24px rgba(17, 24, 39, .15); color: var(--white); }
.wizard-progress .is-current > span { background: #deebff; color: var(--blue); }
.wizard-progress .is-current small { color: #bdc6d5; }
.wizard-progress .is-complete { background: #f4fcf7; border-color: #d3eadc; }
.wizard-progress .is-complete > span { background: var(--green-soft); color: var(--green); }
.wizard-heading { margin-bottom: 24px; }
.sender-choice { min-height: 210px; padding: 22px; }
.connection-icon { background: var(--blue-soft); border-radius: 14px; color: var(--blue); }
.wizard-tip { background: linear-gradient(145deg, #fff, #f8faff); }
.file-example code { background: #172033; color: #c9ddff; }

.review-stats { gap: 10px; }
.review-stats > div { background: #f8fafc; border: 1px solid #edf0f4; border-radius: 14px; }
.launch-warning { border: 1px solid #f1ddbe; border-radius: 14px; }
.final-launch-bar { background: linear-gradient(135deg, #172033, #111722); border-radius: 18px; box-shadow: 0 14px 32px rgba(17, 24, 39, .17); }
.final-launch-bar .button:not(.primary) { border-color: rgba(255, 255, 255, .2); }
.test-email-card { background: linear-gradient(145deg, #fff, #f8fbff); }
.schedule-card { margin-top: 22px; }
.schedule-card .panel-heading { align-items: end; }
.schedule-card .panel-heading > p { color: var(--muted); font-size: 12px; margin: 0; }
.schedule-form { display: grid; gap: 22px; margin-top: 24px; }
.field-label, .schedule-grid label { color: var(--ink); display: grid; font-size: 11px; font-weight: 750; gap: 8px; }
.weekday-picker { display: grid; gap: 8px; grid-template-columns: repeat(7, minmax(48px, 1fr)); margin-top: 9px; }
.weekday-picker label { cursor: pointer; position: relative; }
.weekday-picker input { height: 1px; opacity: 0; position: absolute; width: 1px; }
.weekday-picker span { align-items: center; background: #f8fafc; border: 1px solid var(--line); border-radius: 12px; color: #526071; display: flex; font-size: 12px; font-weight: 800; justify-content: center; min-height: 46px; transition: .18s ease; }
.weekday-picker input:checked + span { background: var(--blue-soft); border-color: #a9c8f4; box-shadow: inset 0 0 0 1px #a9c8f4; color: var(--blue); }
.weekday-picker input:focus-visible + span { outline: 3px solid rgba(23, 105, 224, .18); }
.schedule-grid { display: grid; gap: 14px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.schedule-options { display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.schedule-options > label { align-items: start; background: #f8fafc; border: 1px solid var(--line); border-radius: 15px; cursor: pointer; display: flex; gap: 12px; padding: 16px; }
.schedule-options input { accent-color: var(--blue); height: 18px; margin-top: 2px; width: 18px; }
.schedule-options span { display: grid; gap: 4px; }
.schedule-options strong { color: var(--ink); font-size: 12px; }
.schedule-options small { color: var(--muted); font-size: 10px; line-height: 1.5; }
.schedule-actions { display: flex; justify-content: flex-end; }
.schedule-form .errorlist { color: var(--red); font-size: 10px; margin: 5px 0 0; padding: 0; }

.validation-number { min-height: 150px; padding: 22px; }
.validation-number > span, .validation-analytics-card > span { font-size: 9px; }
.validation-number > strong { font-size: 40px; }
.validation-number > small, .validation-analytics-card > small { font-size: 9px; }
.validation-number.status-number { background: linear-gradient(145deg, #172033, #111722); box-shadow: 0 12px 28px rgba(17, 24, 39, .15); }
.validation-number.status-number > strong, .enrichment-stats .status-number > strong { color: #a8e6cb; }
.validation-progress { background: #e8edf3; height: 11px; }
.validation-progress i { background: linear-gradient(90deg, var(--blue), #5f98ed); }
.validation-check { border-radius: 15px; }
.validation-analytics-card { min-height: 140px; padding: 20px; }
.validation-analytics-card > strong { font-size: 34px; }
.enrichment-check-item { background: #fbfcfe; border-radius: 15px; padding: 15px; }
.enrichment-check-item:has(input:checked) { background: #f2f7ff; border-color: var(--blue); box-shadow: inset 0 0 0 1px var(--blue); }
.enrichment-check-item input { accent-color: var(--blue); }
.enrichment-variable-summary code { background: var(--blue-soft); color: var(--blue); }

.login-shell { background: radial-gradient(circle at 15% 15%, rgba(23, 105, 224, .11), transparent 28rem), #f5f7fa; }
.login-card { border-color: #dfe4eb; border-radius: 28px; box-shadow: 0 28px 80px rgba(16, 24, 40, .13); }
.login-aside { background: linear-gradient(145deg, #1769e0, #0c397d); }
.login-aside p { color: #d7e5fb; }
.signal-row span { background: #bfe0ff; }

@media (min-width: 1101px) {
  .topbar {
    align-items: start;
    background: rgba(255, 255, 255, .97);
    border-bottom: 0;
    border-right: 1px solid var(--line);
    bottom: 0;
    display: grid;
    gap: 0;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto 1fr;
    left: 0;
    min-height: 100vh;
    overflow-y: auto;
    padding: 24px 18px 20px;
    position: fixed;
    top: 0;
    width: 272px;
  }
  .brand { gap: 13px; padding: 0 8px; }
  .brand strong { font-size: 16px; }
  .brand small { font-size: 9px; }
  .brand-mark { background: linear-gradient(145deg, #2580ff, #0d59c4); border-radius: 14px; box-shadow: 0 8px 18px rgba(23, 105, 224, .24); color: var(--white); height: 44px; width: 44px; }
  .main-nav { align-items: stretch; display: grid; gap: 6px; margin-top: 42px; width: 100%; }
  .main-nav::before { color: #98a2b3; content: "Управление"; font-size: 9px; font-weight: 800; letter-spacing: .11em; margin: 0 12px 8px; text-transform: uppercase; }
  .main-nav a { align-items: center; border-radius: 12px; color: #505b6d; display: flex; font-size: 13px; min-height: 46px; padding: 0 14px; }
  .main-nav a::before { align-items: center; color: currentColor; display: inline-flex; font-size: 17px; font-weight: 500; justify-content: center; margin-right: 11px; width: 20px; }
  .main-nav a:nth-child(1)::before { content: "⌂"; }
  .main-nav a:nth-child(2)::before { content: "↗"; }
  .main-nav a:nth-child(3)::before { content: "✉"; }
  .main-nav a:nth-child(4)::before { content: "▤"; }
  .main-nav a:nth-child(5)::before { content: "✓"; }
  .main-nav a:nth-child(6)::before { content: "◎"; }
  .main-nav a:nth-child(7)::before { content: "@"; }
  .main-nav a:hover { background: #f3f6fa; box-shadow: none; color: var(--ink); }
  .main-nav a[aria-current="page"] { background: #172033; box-shadow: 0 8px 18px rgba(17, 24, 39, .14); color: var(--white); }
  .user-menu { align-content: end; align-self: stretch; display: grid; gap: 9px; justify-self: stretch; padding: 24px 0 0; }
  .user-menu::before { color: #98a2b3; content: "Состояние сервисов"; font-size: 9px; font-weight: 800; letter-spacing: .11em; margin: 0 10px 1px; text-transform: uppercase; }
  .service-balances { display: grid; gap: 7px; }
  .balance-chip { background: #f8fafc; border-radius: 13px; min-height: 52px; padding: 8px 12px; width: 100%; }
  .balance-chip small { font-size: 9px; }
  .balance-chip strong { font-size: 12px; }
  .user-menu > .user-name { border-top: 1px solid var(--line); color: var(--ink); font-size: 12px; font-weight: 750; margin-top: 7px; padding: 17px 10px 0; }
  .utility-link { font-size: 11px; padding: 5px 10px; }
  .user-menu form { padding: 0 6px; }
  .user-menu .link-button { justify-content: flex-start; padding: 0 4px; text-align: left; }
  .page-shell { margin-left: 272px; }
}

@media (max-width: 1100px) {
  .topbar { background: rgba(255, 255, 255, .94); border-bottom: 1px solid var(--line); grid-template-columns: auto 1fr auto; }
  .brand-mark { background: var(--blue); color: var(--white); }
  .main-nav { justify-self: center; }
  .main-nav a[aria-current="page"] { background: #f1f5fb; box-shadow: none; color: var(--blue); }
  .user-menu > .user-name, .utility-link { display: none; }
  .page-shell { margin-left: 0; }
  .dashboard-hero { grid-template-columns: 1fr; }
  .dashboard-hero > div:first-child { min-height: 360px; }
  .launch-steps { grid-template-columns: repeat(2, 1fr); }
  .launch-step:nth-child(1), .launch-step:nth-child(5) { grid-column: auto; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .deliverability-header-chip { display: none; }
  .dashboard-deliverability { grid-template-columns: 1fr; }
  .dashboard-deliverability-score { min-height: 210px; }
  .dashboard-deliverability-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 820px) {
  .topbar { min-height: 70px; }
  .main-nav { background: rgba(17, 24, 39, .96); border: 1px solid rgba(255, 255, 255, .1); box-shadow: 0 -10px 30px rgba(16, 24, 40, .16); }
  .main-nav a[aria-current="page"], .main-nav a[aria-current="page"]:hover { background: rgba(255, 255, 255, .1); color: #b9d5ff; }
  .wizard-progress { gap: 7px; overflow-x: auto; padding-bottom: 6px; }
  .wizard-progress a { min-width: 155px; }
  .side-panel { top: auto; }
  .schedule-grid, .schedule-options { grid-template-columns: 1fr 1fr; }
  .results-summary { grid-template-columns: 1fr 1fr; }
  .results-toolbar { align-items: stretch; gap: 16px; }
  .results-filters { flex-wrap: wrap; }
  .sales-email-grid { grid-template-columns: 1fr; }
  .sales-email-result-copy dl { grid-template-columns: 1fr 1fr; }
  .sales-template-editor { grid-template-columns: 1fr; }
  .sales-template-editor .variables-panel { grid-row: auto; }
}

@media (max-width: 560px) {
  .page-shell { padding-left: 16px; padding-right: 16px; }
  .dashboard-hero { margin: 0; padding: 0; }
  .dashboard-hero > div:first-child { border-radius: 20px; margin: 0; min-height: 0; padding: 30px 22px; }
  .dashboard-hero h1 { font-size: 40px; }
  .readiness-card { border-radius: 20px; padding: 22px; }
  .launch-steps { grid-template-columns: 1fr; }
  .launch-step { min-height: 168px; }
  .dashboard-panel { padding: 22px; }
  .dashboard-deliverability-score { min-height: 205px; padding: 24px; }
  .dashboard-deliverability-score p { bottom: 23px; left: 24px; }
  .dashboard-deliverability-content { padding: 17px; }
  .dashboard-deliverability-metrics { grid-template-columns: 1fr 1fr; }
  .dashboard-deliverability-checks > a { margin-left: 0; width: 100%; }
  .dashboard-deliverability-empty { align-items: flex-start; flex-direction: column; gap: 9px; }
  .review-stats { grid-template-columns: 1fr; }
  .validation-analytics-grid { grid-template-columns: 1fr 1fr; }
  .weekday-picker { grid-template-columns: repeat(4, 1fr); }
  .schedule-grid, .schedule-options { grid-template-columns: 1fr; }
  .results-summary { grid-template-columns: 1fr; }
  .mailing-ab-summary { grid-template-columns: 1fr; }
  .results-toolbar { align-items: stretch; flex-direction: column; }
  .results-filters { display: grid; grid-template-columns: 1fr; }
  .results-filters input, .results-filters select { width: 100%; }
  .sales-results-toolbar, .sales-results-actions { align-items: stretch; flex-direction: column; }
  .sales-email-result { padding: 20px; }
  .sales-email-result-mark { display: none; }
  .sales-email-result-copy dl { grid-template-columns: 1fr; }
  .sales-module-nav { border-radius: 14px; margin-bottom: 22px; max-width: 100%; width: 100%; }
  .sales-module-nav a { flex: 1 0 auto; padding: 10px 14px; text-align: center; }
  .page-heading-actions { align-items: stretch; flex-direction: column; width: 100%; }
  .page-heading-actions .button { width: 100%; }
  .sales-template-editor .composer-actions { align-items: stretch; flex-direction: column-reverse; }
  .sales-template-editor .composer-actions .button { width: 100%; }
  .login-card { border-radius: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}

/* Deliverability center */
.deliverability-shell { max-width: 1660px; }
.deliverability-hero {
  align-items: end;
  background:
    radial-gradient(circle at 92% 8%, rgba(37, 128, 255, .18), transparent 22rem),
    linear-gradient(145deg, #ffffff, #f7faff);
  border: 1px solid #dfe6ef;
  border-radius: 26px;
  box-shadow: var(--shadow);
  display: flex;
  gap: 28px;
  justify-content: space-between;
  margin-bottom: 22px;
  overflow: hidden;
  padding: clamp(26px, 4vw, 48px);
  position: relative;
}
.deliverability-hero::after {
  background: linear-gradient(90deg, var(--blue), #62a6ff);
  bottom: 0;
  content: "";
  height: 4px;
  left: 0;
  position: absolute;
  width: 36%;
}
.deliverability-hero h1 { font-size: clamp(36px, 4.4vw, 66px); letter-spacing: -.06em; line-height: .96; margin: 8px 0 14px; }
.deliverability-hero p { color: var(--muted); font-size: 15px; line-height: 1.6; margin: 0; max-width: 720px; }
.deliverability-hero form { flex: 0 0 auto; }
.deliverability-stop {
  align-items: center;
  background: linear-gradient(135deg, #fff7f5, #fff);
  border: 1px solid #ffd7d2;
  border-radius: 18px;
  display: flex;
  gap: 18px;
  justify-content: space-between;
  margin-bottom: 22px;
  padding: 18px 22px;
}
.deliverability-stop strong, .deliverability-stop small { display: block; }
.deliverability-stop strong { color: var(--red); font-size: 14px; }
.deliverability-stop small { color: var(--muted); font-size: 12px; margin-top: 4px; }
.deliverability-overview { display: grid; gap: 14px; grid-template-columns: repeat(5, minmax(0, 1fr)); margin-bottom: 22px; }
.health-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
  min-height: 136px;
  padding: 20px;
  position: relative;
}
.health-card::before { background: #d0d5dd; border-radius: 10px; content: ""; height: 8px; position: absolute; right: 18px; top: 18px; width: 8px; }
.health-card > span { color: var(--muted); display: block; font-size: 9px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.health-card > strong { display: block; font-size: clamp(28px, 3vw, 42px); letter-spacing: -.045em; line-height: 1; margin-top: 24px; }
.health-card > small { color: var(--muted); display: block; font-size: 10px; margin-top: 8px; }
.health-card.health-healthy::before { background: var(--green); box-shadow: 0 0 0 5px var(--green-soft); }
.health-card.health-warning::before { background: #f79009; box-shadow: 0 0 0 5px #fff4e5; }
.health-card.health-critical::before { background: var(--red); box-shadow: 0 0 0 5px var(--red-soft); }
.deliverability-grid { display: grid; gap: 22px; grid-template-columns: minmax(0, 2fr) minmax(300px, .8fr); margin-bottom: 22px; }
.sender-health-panel, .deliverability-guide, .deliverability-section { padding: 24px; }
.sender-health-panel + .sender-health-panel { margin-top: 14px; }
.sender-health-panel header { align-items: flex-start; display: flex; gap: 18px; justify-content: space-between; margin-bottom: 20px; }
.sender-health-panel header h2 { font-size: 22px; letter-spacing: -.025em; margin: 5px 0 6px; }
.sender-health-panel header p { color: var(--muted); font-size: 11px; margin: 0; }
.sender-health-panel footer { border-top: 1px solid var(--line); color: var(--muted); display: flex; font-size: 10px; gap: 14px; justify-content: space-between; margin-top: 18px; padding-top: 14px; }
.sender-health-panel footer strong { color: var(--red); }
.section-heading-row { align-items: flex-start; display: flex; gap: 18px; justify-content: space-between; margin-bottom: 20px; }
.section-heading-row h2 { font-size: 22px; letter-spacing: -.025em; margin: 0; }
.section-heading-row p { color: var(--muted); font-size: 12px; line-height: 1.5; margin: 6px 0 0; }
.health-pill { border-radius: 999px; display: inline-flex; font-size: 10px; font-weight: 850; letter-spacing: .06em; padding: 7px 10px; text-transform: uppercase; white-space: nowrap; }
.health-pill.health-healthy { background: var(--green-soft); color: var(--green-dark); }
.health-pill.health-warning { background: #fff4e5; color: #b54708; }
.health-pill.health-critical { background: var(--red-soft); color: var(--red); }
.health-pill.health-unknown { background: #f2f4f7; color: var(--muted); }
.domain-checks { display: grid; gap: 10px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.domain-check { align-items: flex-start; background: #f8fafc; border: 1px solid #e8edf3; border-radius: 14px; display: flex; gap: 10px; min-height: 82px; padding: 14px; }
.domain-check strong, .domain-check small { display: block; }
.domain-check strong { font-size: 12px; }
.domain-check small { color: var(--muted); font-size: 10px; line-height: 1.35; margin-top: 5px; word-break: break-word; }
.check-icon { align-items: center; background: #eef1f5; border-radius: 50%; color: var(--muted); display: inline-flex; flex: 0 0 24px; font-size: 11px; font-weight: 900; height: 24px; justify-content: center; }
.domain-check.check-pass .check-icon { background: var(--green-soft); color: var(--green-dark); }
.domain-check.check-fail .check-icon { background: var(--red-soft); color: var(--red); }
.domain-check.check-warning .check-icon { background: #fff4e5; color: var(--amber); }
.deliverability-guide { background: linear-gradient(150deg, #172033, #0d2746); border: 0; color: var(--white); }
.deliverability-guide h2 { font-size: 21px; margin: 0 0 18px; }
.deliverability-guide ul { display: grid; gap: 17px; list-style: none; margin: 20px 0 0; padding: 0; }
.deliverability-guide li { color: #dce7f6; font-size: 12px; line-height: 1.5; padding-left: 20px; position: relative; }
.deliverability-guide li::before { background: #62a6ff; border-radius: 50%; content: ""; height: 7px; left: 0; position: absolute; top: 6px; width: 7px; }
.deliverability-guide li strong, .deliverability-guide li span { display: block; }
.deliverability-guide li span { color: #9fb0c6; margin-top: 3px; }
.deliverability-section { margin-bottom: 22px; }
.event-pill { border-radius: 999px; display: inline-flex; font-size: 9px; font-weight: 850; padding: 6px 9px; text-transform: uppercase; }
.event-accepted, .event-delivered, .event-opened { background: var(--green-soft); color: var(--green-dark); }
.event-deferred, .event-soft_bounce { background: #fff4e5; color: var(--amber); }
.event-hard_bounce, .event-blocked, .event-complaint { background: var(--red-soft); color: var(--red); }
.event-unsubscribed { background: var(--violet-soft); color: #6938ad; }
.suppression-filters { align-items: center; display: flex; flex-wrap: wrap; gap: 8px; }
.suppression-filters a { background: #f4f6f8; border-radius: 999px; color: var(--muted); font-size: 10px; font-weight: 800; padding: 7px 10px; text-decoration: none; }
.suppression-filters a:hover, .suppression-filters a.is-active { background: #172033; color: var(--white); }
.unsubscribe-shell { align-items: center; display: flex; justify-content: center; min-height: calc(100vh - 76px); padding: 30px; }
.unsubscribe-card { background: var(--white); border: 1px solid var(--line); border-radius: 26px; box-shadow: 0 24px 70px rgba(16, 24, 40, .12); max-width: 560px; padding: clamp(28px, 6vw, 54px); text-align: center; width: 100%; }
.unsubscribe-card h1 { font-size: clamp(29px, 5vw, 44px); letter-spacing: -.045em; margin: 18px 0 12px; }
.unsubscribe-card p { color: var(--muted); line-height: 1.6; }
.unsubscribe-card form { margin-top: 26px; }
.unsubscribe-mark { align-items: center; background: var(--blue-soft); border-radius: 18px; color: var(--blue); display: inline-flex; font-size: 28px; font-weight: 900; height: 64px; justify-content: center; width: 64px; }

@media (max-width: 1320px) {
  .deliverability-overview { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .domain-checks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .deliverability-hero, .deliverability-stop { align-items: stretch; flex-direction: column; }
  .deliverability-grid { grid-template-columns: 1fr; }
  .deliverability-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  .deliverability-hero { border-radius: 20px; padding: 28px 22px; }
  .deliverability-hero form .button { width: 100%; }
  .deliverability-overview, .domain-checks { grid-template-columns: 1fr; }
  .health-card { min-height: 118px; }
  .sender-health-panel, .deliverability-guide, .deliverability-section { padding: 19px; }
  .section-heading-row { align-items: stretch; flex-direction: column; }
  .unsubscribe-shell { padding: 16px; }
}
