:root {
  --bg: #090d12;
  --surface: #11161f;
  --surface-2: #171e2b;
  --surface-3: #1f2939;
  --border: rgba(226, 236, 248, 0.09);
  --border-strong: rgba(226, 236, 248, 0.17);
  --text: #edf2f7;
  --muted: #8e9caf;
  --accent: #38bdf8;
  --accent-hover: #0ea5e9;
  --accent-ink: #04131c;
  --accent-soft: rgba(56, 189, 248, 0.12);
  --ok: #10b981;
  --ok-hover: #059669;
  --ok-ink: #031a12;
  --ok-soft: rgba(16, 185, 129, 0.13);
  --warn: #f59e0b;
  --warn-soft: rgba(245, 158, 11, 0.12);
  --danger: #f87171;
  --danger-soft: rgba(248, 113, 113, 0.12);
  --shadow-featured: 0 22px 46px -22px rgba(14, 165, 233, 0.28);
  --shadow-modal: 0 28px 64px -18px rgba(0, 0, 0, 0.72);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --font-sans: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

[data-theme="light"] {
  --bg: #f6f8fb;
  --surface: #ffffff;
  --surface-2: #eef2f7;
  --surface-3: #e2e8f0;
  --border: rgba(15, 23, 42, 0.09);
  --border-strong: rgba(15, 23, 42, 0.18);
  --text: #0f172a;
  --muted: #526071;
  --accent: #0284c7;
  --accent-hover: #0369a1;
  --accent-ink: #ffffff;
  --accent-soft: rgba(2, 132, 199, 0.1);
  --ok: #059669;
  --ok-hover: #047857;
  --ok-ink: #ffffff;
  --ok-soft: rgba(5, 150, 105, 0.11);
  --warn: #b45309;
  --warn-soft: rgba(217, 119, 6, 0.11);
  --danger: #dc2626;
  --danger-soft: rgba(220, 38, 38, 0.09);
  --shadow-featured: 0 20px 44px -22px rgba(2, 132, 199, 0.22);
  --shadow-modal: 0 24px 56px -16px rgba(15, 23, 42, 0.24);
}

[hidden] {
  display: none !important;
}

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
  pointer-events: none;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

[data-theme="light"] {
  color-scheme: light;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

::selection {
  background: color-mix(in srgb, var(--accent) 28%, transparent);
  color: var(--text);
}

::-webkit-scrollbar {
  width: 9px;
  height: 9px;
}

::-webkit-scrollbar-track {
  background: var(--bg);
}

::-webkit-scrollbar-thumb {
  background: var(--surface-3);
  border-radius: 999px;
  border: 2px solid var(--bg);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--muted);
}

a {
  color: inherit;
  text-decoration: none;
}

.inline-link {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

.inline-link:hover {
  color: var(--accent-hover);
}

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

code,
.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

code {
  font-size: 0.88em;
  padding: 2px 6px;
  border-radius: 5px;
  background: var(--surface-2);
  border: 1px solid var(--border);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.container {
  width: 100%;
  max-width: 1020px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ── Topbar ──────────────────────────────────────────────────────────────── */

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 62px;
}

.brand-group {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: -0.02em;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--accent-soft);
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 26%, transparent);
  flex-shrink: 0;
}

.brand-mark-sm {
  width: 28px;
  height: 28px;
  border-radius: 7px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
  white-space: nowrap;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 3px var(--ok-soft);
}

.nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
}

.nav a {
  padding: 6px 2px;
  transition: color 0.15s ease;
}

.nav a:hover {
  color: var(--text);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ── Buttons & Inputs ────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.1s ease;
  white-space: nowrap;
}

.btn:active:not(:disabled) {
  transform: translateY(1px);
}

.btn:disabled {
  opacity: 0.52;
  cursor: not-allowed;
}

.btn-sm {
  min-height: 38px;
  padding: 8px 13px;
  font-size: 13px;
}

.btn-block {
  width: 100%;
  min-height: 46px;
}

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

.btn-primary:hover:not(:disabled) {
  background: var(--accent-hover);
}

.btn-ok {
  background: var(--ok);
  color: var(--ok-ink);
}

.btn-ok:hover:not(:disabled) {
  background: var(--ok-hover);
}

.btn-secondary {
  background: var(--surface-2);
  border-color: var(--border);
  color: var(--text);
}

.btn-secondary:hover:not(:disabled) {
  background: var(--surface-3);
  border-color: var(--border-strong);
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.icon-btn:hover {
  background: var(--surface-2);
  border-color: var(--border-strong);
  color: var(--text);
}

.field-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.input-action-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: stretch;
}

.input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  min-width: 0;
}

.input {
  width: 100%;
  min-height: 46px;
  padding: 11px 104px 11px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--bg);
  color: var(--text);
  caret-color: var(--accent);
  font-size: 16px;
  min-width: 0;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.input::placeholder {
  color: var(--muted);
}

.input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  outline: none;
}

.input.is-invalid {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px var(--danger-soft);
}

.paste-btn {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 34px;
  padding: 0 10px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.paste-btn:hover {
  background: var(--surface-3);
  border-color: var(--border-strong);
  color: var(--text);
}

.lookup-submit {
  min-height: 46px;
  padding: 0 20px;
}

/* ── Hero, Radar Motif & Stepper ─────────────────────────────────────────── */

.intro-section {
  position: relative;
  padding: 36px 0 32px;
  overflow: hidden;
}

.radar-bg {
  position: absolute;
  top: -24px;
  right: max(-60px, calc(50% - 620px));
  width: 540px;
  height: 405px;
  color: var(--accent);
  pointer-events: none;
  user-select: none;
  z-index: 0;
}

.radar-sweep {
  transform-origin: 430px 110px;
  animation: radar-sweep-once 1.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes radar-sweep-once {
  from {
    opacity: 0;
    transform: rotate(-38deg);
  }
  to {
    opacity: 1;
    transform: rotate(0deg);
  }
}

.intro-inner {
  position: relative;
  z-index: 1;
}

.page-header {
  margin-bottom: 22px;
}

.page-header h1 {
  margin: 0 0 8px;
  font-size: clamp(28px, 3.8vw, 40px);
  line-height: 1.12;
  letter-spacing: -0.025em;
  font-weight: 800;
  text-wrap: balance;
}

.page-lead {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  max-width: 60ch;
}

/* ── 3-Step Checkout Rail ────────────────────────────────────────────────── */

.stepper {
  list-style: none;
  margin: 0 0 18px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.step-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  transition: color 0.18s ease;
}

.step-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.step-item.is-active {
  color: var(--text);
}

.step-item.is-active .step-index {
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 60%, transparent);
  color: var(--accent);
}

.step-item.is-done {
  color: var(--text);
}

.step-item.is-done .step-index {
  background: var(--ok);
  border-color: var(--ok);
  color: var(--ok-ink);
}

.step-connector {
  width: 24px;
  height: 1px;
  background: var(--border-strong);
}

/* ── Account Lookup Surface ──────────────────────────────────────────────── */

.account-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.account-panel.is-attention {
  border-color: var(--warn);
  box-shadow: 0 0 0 3px var(--warn-soft);
}

.lookup-field-group {
  display: flex;
  flex-direction: column;
}

.lookup-hint {
  margin: 8px 0 0;
  font-size: 13px;
  color: var(--muted);
}

.lookup-error {
  margin: 10px 0 0;
  padding: 10px 13px;
  border-radius: var(--radius-sm);
  background: var(--danger-soft);
  border: 1px solid color-mix(in srgb, var(--danger) 35%, transparent);
  color: var(--danger);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.lookup-error svg {
  flex-shrink: 0;
  margin-top: 1px;
}

.presets-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 2px;
}

.presets-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}

.presets-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.preset-chip {
  min-height: 32px;
  padding: 4px 11px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.preset-chip:hover {
  color: var(--text);
  border-color: var(--border-strong);
}

.preset-chip.is-active {
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 45%, transparent);
  color: var(--accent);
}

.account-status {
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.account-empty {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.account-empty-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: var(--surface-2);
  color: var(--muted);
  flex-shrink: 0;
}

.account-banner {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 16px;
  align-items: center;
}

.account-confirm-box {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 15px 16px;
  border-radius: var(--radius-md);
  background: var(--warn-soft);
  border: 1px solid color-mix(in srgb, var(--warn) 42%, transparent);
  animation: surface-reveal 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes surface-reveal {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.account-confirm-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}

.account-confirm-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.account-identity {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.acc-code {
  font-size: 12px;
  color: var(--muted);
  padding: 2px 7px;
  border-radius: 5px;
  background: var(--surface-2);
  border: 1px solid var(--border);
}

.confirmed-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--ok-soft);
  color: var(--ok);
}

.account-meta {
  font-size: 13px;
  color: var(--muted);
  margin-top: 3px;
}

.account-metrics {
  display: flex;
  gap: 18px;
  padding-left: 16px;
  border-left: 1px solid var(--border);
}

.metric-box {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.metric-label {
  font-size: 12px;
  color: var(--muted);
}

.metric-val {
  font-size: 14px;
  font-weight: 700;
}

/* ── Sections ────────────────────────────────────────────────────────────── */

.section {
  padding: 40px 0 48px;
  border-top: 1px solid var(--border);
}

.section-muted {
  background: color-mix(in srgb, var(--surface) 45%, var(--bg));
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

.section-head h2 {
  margin: 0 0 6px;
  font-size: clamp(22px, 2.6vw, 28px);
  line-height: 1.18;
  letter-spacing: -0.02em;
  font-weight: 800;
  text-wrap: balance;
}

.section-sub {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  max-width: 64ch;
}

/* ── Tariffs Grid ────────────────────────────────────────────────────────── */

.recalc-notice {
  margin-bottom: 18px;
  padding: 13px 16px;
  border-radius: var(--radius-md);
  background: var(--warn-soft);
  border: 1px solid color-mix(in srgb, var(--warn) 36%, transparent);
  font-size: 14px;
  line-height: 1.55;
}

.tariffs-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  align-items: stretch;
  margin-bottom: 20px;
}

.tariff-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: border-color 0.18s ease, transform 0.18s ease;
}

.tariff-card:hover {
  border-color: var(--border-strong);
}

.tariff-card.is-featured {
  background: color-mix(in srgb, var(--accent) 4%, var(--surface));
  border-color: color-mix(in srgb, var(--accent) 52%, transparent);
  box-shadow: var(--shadow-featured);
}

.tariff-card.is-featured::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 16px;
  right: 16px;
  height: 2px;
  border-radius: 999px;
  background: var(--accent);
}

.tariff-card.is-current {
  border-color: color-mix(in srgb, var(--ok) 50%, transparent);
}

.tariff-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.tariff-name-wrap {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.tariff-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--surface-2);
  color: var(--accent);
  flex-shrink: 0;
}

.tariff-card.is-featured .tariff-icon {
  background: var(--accent-soft);
}

.tariff-title {
  margin: 0;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.015em;
}

.tariff-badge {
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  white-space: nowrap;
}

.tariff-badge.is-current {
  background: var(--ok-soft);
  color: var(--ok);
}

.tariff-price-block {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.tariff-price-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.tariff-price {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.tariff-period {
  font-size: 14px;
  color: var(--muted);
}

.tariff-per-day {
  font-size: 13px;
  color: var(--muted);
}

/* Honest radar scan-cadence telemetry bar */
.speed-meter {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
}

.speed-meter-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
}

.speed-label {
  color: var(--muted);
}

.speed-val {
  font-weight: 700;
  color: var(--text);
}

.speed-val.is-fastest {
  color: var(--accent);
}

.speed-track {
  height: 5px;
  border-radius: 999px;
  background: var(--surface-3);
  overflow: hidden;
}

.speed-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--muted);
}

.speed-fill-lite {
  width: 50%;
  background: color-mix(in srgb, var(--accent) 55%, var(--muted));
}

.speed-fill-standart {
  width: 72%;
  background: color-mix(in srgb, var(--accent) 78%, var(--muted));
}

.speed-fill-pro {
  width: 100%;
  background: var(--accent);
}

.tariff-recalc {
  font-size: 13px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--muted);
}

.tariff-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  font-size: 14px;
}

.tariff-list li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
}

.tariff-list svg {
  color: var(--ok);
  flex-shrink: 0;
  margin-top: 2px;
}

.tariff-perk {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
  margin-top: auto;
  padding-top: 4px;
}

.tariff-footer {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

/* ── Trust Strip & Shared Bar ────────────────────────────────────────────── */

.trust-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 24px;
  padding: 14px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin-bottom: 14px;
}

.trust-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.trust-item svg {
  color: var(--accent);
  flex-shrink: 0;
}

.shared-features-bar {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

/* ── Legal Documents ─────────────────────────────────────────────────────── */

.docs-shell {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.docs-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}

.doc-tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 40px;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.doc-tab:hover {
  color: var(--text);
  border-color: var(--border-strong);
}

.doc-tab.is-active {
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 45%, transparent);
  color: var(--accent);
}

.doc-body {
  padding: 22px;
  font-size: 14px;
  line-height: 1.65;
  color: var(--muted);
  max-width: 76ch;
}

.doc-body h3,
.doc-body strong {
  color: var(--text);
}

.doc-body p {
  margin: 0 0 11px;
}

.doc-body ul {
  margin: 0 0 14px;
  padding-left: 20px;
}

.doc-body li {
  margin-bottom: 6px;
}

.doc-page-divider {
  margin: 18px 0;
  border: 0;
  border-top: 1px dashed var(--border-strong);
}

/* ── Footer ──────────────────────────────────────────────────────────────── */

.footer {
  border-top: 1px solid var(--border);
  padding: 24px 0;
  font-size: 13px;
  color: var(--muted);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-weight: 600;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.footer-links a {
  padding: 4px 0;
  transition: color 0.15s ease;
}

.footer-links a:hover {
  color: var(--text);
}

/* ── Checkout Modal ──────────────────────────────────────────────────────── */

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(4, 7, 12, 0.74);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: fade-in 0.16s ease;
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-card {
  width: 100%;
  max-width: 488px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-modal);
  overflow: hidden;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  animation: modal-pop 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modal-pop {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
}

.modal-context {
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 3px;
}

.modal-head h3 {
  margin: 0;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.015em;
}

.modal-body {
  padding: 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.invoice-box {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: grid;
  gap: 9px;
  font-size: 14px;
}

.invoice-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}

.invoice-row span:first-child {
  color: var(--muted);
}

.invoice-total {
  padding-top: 9px;
  border-top: 1px solid var(--border);
  font-weight: 800;
  font-size: 17px;
}

.modal-fieldset {
  border: 0;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.modal-fieldset legend {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
  padding: 0;
}

.modal-methods {
  display: grid;
  gap: 8px;
}

.modal-method-card {
  width: 100%;
  min-height: 54px;
  text-align: left;
  padding: 11px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface-2);
  cursor: pointer;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.modal-method-card:hover {
  border-color: var(--border-strong);
}

.modal-method-card.is-active {
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 60%, transparent);
}

.method-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: var(--surface);
  color: var(--accent);
  flex-shrink: 0;
}

.method-title {
  font-weight: 700;
  font-size: 14px;
}

.method-sub {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.method-radio {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 2px solid var(--border-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.modal-method-card.is-active .method-radio {
  border-color: var(--accent);
}

.modal-method-card.is-active .method-radio::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
}

.consent-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
}

.consent-row input {
  width: 18px;
  height: 18px;
  margin-top: 1px;
  accent-color: var(--accent);
  flex-shrink: 0;
  cursor: pointer;
}

.modal-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.modal-status-box {
  padding: 13px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface-2);
  font-size: 14px;
  line-height: 1.5;
}

.modal-status-box.is-paid {
  background: var(--ok-soft);
  border-color: color-mix(in srgb, var(--ok) 45%, transparent);
}

.modal-status-box.is-error {
  background: var(--danger-soft);
  border-color: color-mix(in srgb, var(--danger) 40%, transparent);
  color: var(--danger);
}

.support-order-box {
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: var(--surface-2);
  border: 1px dashed var(--border-strong);
  font-size: 13px;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.support-order-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

/* ── Active Order Resume Bar (sessionStorage) ────────────────────────────── */

.active-order-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--accent) 9%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--accent) 42%, transparent);
  animation: surface-reveal 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.active-order-bar.is-paid {
  background: color-mix(in srgb, var(--ok) 9%, var(--surface));
  border-color: color-mix(in srgb, var(--ok) 45%, transparent);
}

.active-order-info {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-size: 14px;
}

.active-order-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  flex-shrink: 0;
}

.active-order-bar.is-paid .active-order-dot {
  background: var(--ok);
  box-shadow: 0 0 0 3px var(--ok-soft);
}

.active-order-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

/* ── Order Mode Switcher (Для себя / Подарочный код) ─────────────────────── */

.order-mode-switch {
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  border-radius: var(--radius-sm);
  background: var(--bg);
  border: 1px solid var(--border);
  align-self: flex-start;
  max-width: 100%;
}

.mode-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 7px 14px;
  border-radius: 6px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.mode-tab:hover {
  color: var(--text);
}

.mode-tab.is-active {
  background: var(--surface-2);
  border-color: var(--border-strong);
  color: var(--text);
}

.gift-mode-panel {
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--accent) 6%, var(--surface-2));
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
}

.gift-mode-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.gift-mode-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent);
  flex-shrink: 0;
}

/* ── @username Safeguard & OTP Controls ──────────────────────────────────── */

.username-mode-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.u-mode-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.u-mode-btn:hover {
  color: var(--text);
}

.u-mode-btn.is-active {
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
  color: var(--accent);
}

.username-warn-note {
  font-size: 13px;
  color: var(--text);
  line-height: 1.5;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--surface) 75%, transparent);
  border: 1px solid var(--border);
}

.otp-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

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

.otp-input {
  width: 132px;
  min-height: 44px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.25em;
  text-align: center;
}

.otp-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  outline: none;
}

.otp-status {
  font-size: 12px;
  color: var(--ok);
  font-weight: 600;
}

.ack-row {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 13px;
  color: var(--text);
  cursor: pointer;
}

.ack-row input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--accent);
  flex-shrink: 0;
  cursor: pointer;
}

/* ── Promo Code & Gift Voucher Receipt in Modal ──────────────────────────── */

.promo-box {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.promo-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}

.promo-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.promo-input {
  width: 100%;
  min-height: 44px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 16px;
  text-transform: uppercase;
}

.promo-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  outline: none;
}

.promo-applied {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  background: var(--ok-soft);
  border: 1px solid color-mix(in srgb, var(--ok) 40%, transparent);
  color: var(--ok);
  font-size: 13px;
  font-weight: 700;
}

.promo-error {
  font-size: 12px;
  font-weight: 600;
  color: var(--danger);
}

.price-strike {
  color: var(--muted);
  text-decoration: line-through;
  font-weight: 500;
  font-size: 14px;
  margin-right: 6px;
}

.promo-bonus-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  color: var(--ok);
}

.gift-voucher-box {
  padding: 16px;
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--ok) 11%, var(--surface-2));
  border: 1px solid color-mix(in srgb, var(--ok) 48%, transparent);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.gift-voucher-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  color: var(--ok);
}

.gift-voucher-code-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg);
  border: 1px solid var(--border-strong);
}

.gift-voucher-code {
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text);
}

.gift-voucher-hint {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */

@media (max-width: 860px) {
  .nav {
    display: none;
  }

  .tariffs-grid {
    grid-template-columns: 1fr;
  }

  .account-metrics {
    padding-left: 0;
    border-left: 0;
  }

  .radar-bg {
    width: 380px;
    height: 290px;
    opacity: 0.7;
  }
}

@media (max-width: 640px) {
  .intro-section {
    padding: 24px 0 24px;
  }

  .status-pill {
    display: none;
  }

  .account-panel {
    padding: 16px;
  }

  .order-mode-switch {
    width: 100%;
  }

  .active-order-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .active-order-actions {
    justify-content: space-between;
  }

  .input-action-row {
    grid-template-columns: 1fr;
  }

  .account-banner {
    grid-template-columns: 1fr;
  }

  .trust-strip {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .btn,
  .radar-sweep,
  .modal-backdrop,
  .modal-card,
  .account-confirm-box {
    animation: none;
    transition: none;
  }
}
