/* Kingdom Protection — "Your Medicare Roadmap" signature feature.
   Scoped entirely under .medicare-page. Shape language (rounded corners,
   shadows, cards) is its own premium treatment, but colors are pulled from
   the site's own tokens (assets/styles.css + assets/site.css) — royal blue
   and red accent — not a separate invented palette. */

.medicare-page {
  --mr-navy: var(--color-text);        /* royal blue — dark-section bg, headings */
  --mr-navy-soft: #1c2470;             /* deeper blue for gradient depth only */
  --mr-accent: var(--color-accent);    /* red — buttons, active states */
  --mr-accent-ink: var(--color-accent-700);   /* dark red — kicker text on white */
  --mr-accent-on-dark: var(--color-accent-400); /* red tint safe on blue bg (4.95:1) */
  --mr-accent-soft: var(--color-accent-100);  /* icon chip backgrounds */
  --mr-ink: var(--color-text);
  --mr-muted: var(--color-neutral-700);
  --mr-line: var(--color-neutral-300);
  --mr-surface: #ffffff;
  --mr-bg: var(--color-bg);
  --mr-shadow-sm: 0 1px 3px rgba(45, 43, 43, 0.07), 0 1px 2px rgba(45, 43, 43, 0.08);
  --mr-shadow-md: 0 12px 28px rgba(45, 43, 43, 0.10);
  --mr-shadow-lg: 0 24px 56px rgba(45, 43, 43, 0.16);
  --mr-radius: 20px;
  --mr-radius-sm: 14px;
  color: var(--mr-ink);
  background: var(--mr-bg);
}

.medicare-page * { box-sizing: border-box; }

.mr-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding-inline: 24px;
}

.mr-section { padding-block: 88px; }
.mr-section--tight { padding-block: 64px; }

.mr-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  /* Dark red by default (this text sits on light backgrounds in the hero
     and Medicare Explained — 7.17:1). Sections on the blue background
     override to --mr-accent-on-dark below, which clears WCAG AA there
     (plain --mr-accent only hits 2.47:1 on blue, so it can't be reused). */
  color: var(--mr-accent-ink);
  margin-bottom: 16px;
}
.mr-eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
}

.mr-title {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  color: var(--mr-navy);
  font-size: clamp(32px, 4.4vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin: 0 0 20px;
}
.mr-subtitle {
  font-size: 19px;
  line-height: 1.65;
  color: var(--mr-muted);
  max-width: 640px;
  margin: 0;
}

/* — hero — */
.mr-hero {
  padding-block: 88px 72px;
  background: linear-gradient(180deg, #fff 0%, var(--mr-bg) 100%);
  border-bottom: 1px solid var(--mr-line);
}
.mr-hero-inner { max-width: 780px; }
.mr-hero p.mr-lead {
  font-size: 20px;
  line-height: 1.65;
  color: var(--mr-muted);
  margin: 0 0 36px;
  max-width: 620px;
}
.mr-actions { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; }

.mr-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 15px;
  padding: 14px 28px;
  border-radius: 999px;
  text-decoration: none;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}
.mr-btn:hover { transform: translateY(-1px); }
.mr-btn-primary {
  background: var(--mr-accent);
  color: #fff;
  box-shadow: var(--mr-shadow-md);
}
.mr-btn-primary:hover { background: var(--color-accent-600); box-shadow: var(--mr-shadow-lg); }
.mr-btn-outline {
  background: transparent;
  color: var(--mr-navy);
  border-color: var(--mr-line);
}
.mr-btn-outline:hover { border-color: var(--mr-navy); }

/* — roadmap section — */
.mr-roadmap {
  background: var(--mr-navy);
  background-image: radial-gradient(1200px 500px at 15% -10%, var(--mr-navy-soft) 0%, transparent 60%);
  border-bottom: 1px solid var(--mr-line);
}
.mr-roadmap .mr-eyebrow { color: var(--mr-accent-on-dark); }
.mr-roadmap .mr-title,
.mr-roadmap .mr-subtitle { color: #fff; }
.mr-roadmap .mr-subtitle { color: rgba(255, 255, 255, 0.72); }
.mr-roadmap-head { margin-bottom: 56px; }

/* Track: 6 clickable step nodes connected by a line. Desktop = horizontal
   row; mobile = vertical column (see media query). One shared detail panel
   below does the "reveal more without cluttering" work, so clicking a node
   never reflows the track itself. */
.mr-track {
  display: flex;
  align-items: flex-start;
  gap: 0;
  position: relative;
  margin-bottom: 40px;
}
.mr-track::before {
  content: "";
  position: absolute;
  top: 29px;
  left: 6%;
  right: 6%;
  height: 2px;
  background: linear-gradient(90deg, rgba(236, 48, 19, 0.15), rgba(236, 48, 19, 0.55), rgba(236, 48, 19, 0.15));
}
.mr-node {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  background: none;
  border: none;
  padding: 4px 6px 0;
  cursor: pointer;
  position: relative;
  z-index: 1;
  font-family: inherit;
  color: inherit;
}
.mr-node-circle {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--mr-navy);
  border: 2px solid rgba(236, 48, 19, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.75);
  transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.mr-node-circle svg { width: 24px; height: 24px; }
.mr-node-num {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--mr-accent-on-dark);
}
.mr-node-label {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  text-align: center;
  color: rgba(255, 255, 255, 0.85);
  max-width: 140px;
}
.mr-node:hover .mr-node-circle {
  border-color: var(--mr-accent-on-dark);
  transform: translateY(-2px);
}
.mr-node:focus-visible {
  outline: 2px solid var(--mr-accent-on-dark);
  outline-offset: 4px;
  border-radius: 12px;
}
.mr-node[aria-selected="true"] .mr-node-circle {
  background: var(--mr-accent);
  border-color: var(--mr-accent);
  color: #fff;
  box-shadow: 0 0 0 6px rgba(236, 48, 19, 0.18);
  transform: translateY(-2px);
}
.mr-node[aria-selected="true"] .mr-node-label { color: #fff; }

/* Shared detail panel */
.mr-panel {
  background: #fff;
  border-radius: var(--mr-radius);
  box-shadow: var(--mr-shadow-lg);
  padding: 40px;
  display: flex;
  gap: 28px;
  align-items: flex-start;
}
.mr-panel-icon {
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--mr-accent-soft);
  color: var(--mr-navy);
  display: flex;
  align-items: center;
  justify-content: center;
}
.mr-panel-icon svg { width: 28px; height: 28px; }
.mr-panel-kicker {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mr-accent-ink);
  margin-bottom: 8px;
}
.mr-panel-title {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  color: var(--mr-navy);
  font-size: 24px;
  margin: 0 0 12px;
}
.mr-panel-body {
  font-size: 17px;
  line-height: 1.7;
  color: var(--mr-muted);
  max-width: 68ch;
}
.mr-panel-body p { margin: 0 0 16px; }
.mr-panel-body p:last-child { margin-bottom: 0; }
.mr-panel-body strong { color: var(--mr-navy); font-weight: 700; }
.mr-panel-body .mr-panel-subhead {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  font-size: 15px;
  color: var(--mr-accent-ink);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 24px 0 10px;
  padding-top: 16px;
  border-top: 1px solid var(--mr-line);
}
.mr-panel-body p:first-child.mr-panel-subhead { margin-top: 0; padding-top: 0; border-top: none; }
.mr-panel.is-fading { opacity: 0; transform: translateY(4px); }
.mr-panel { transition: opacity 0.16s ease, transform 0.16s ease; }

.mr-closing {
  margin-top: 64px;
  padding-top: 48px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  text-align: center;
}
.mr-closing .mr-eyebrow { justify-content: center; color: var(--mr-accent-on-dark); }
.mr-closing .mr-eyebrow::before { display: none; }
.mr-closing h3 {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  color: #fff;
  font-size: clamp(24px, 3vw, 34px);
  margin: 0 0 28px;
}

/* — Medicare Explained — */
.mr-explained { background: var(--mr-surface); }
.mr-explained-head { margin-bottom: 48px; }

.mr-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 64px;
}
.mr-card {
  background: #fff;
  border: 1px solid var(--mr-line);
  border-radius: var(--mr-radius);
  padding: 28px 24px;
  box-shadow: var(--mr-shadow-sm);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.mr-card:hover { box-shadow: var(--mr-shadow-md); transform: translateY(-3px); }
.mr-card-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--mr-accent-soft);
  color: var(--mr-navy);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}
.mr-card-icon svg { width: 24px; height: 24px; }
.mr-card-kicker {
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mr-accent-ink);
  margin-bottom: 8px;
}
.mr-card-title {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  color: var(--mr-navy);
  font-size: 18px;
  margin: 0 0 10px;
}
.mr-card-body {
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--mr-muted);
  margin: 0;
}

.mr-compare {
  background: var(--mr-bg);
  border-radius: var(--mr-radius);
  padding: 8px;
  box-shadow: var(--mr-shadow-sm);
}
.mr-compare-inner { overflow-x: auto; }
.mr-table {
  width: 100%;
  min-width: 560px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 15px;
}
.mr-table th {
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  background: var(--mr-navy);
  padding: 16px 20px;
}
.mr-table th:first-child { border-radius: 14px 0 0 0; }
.mr-table th:last-child { border-radius: 0 14px 0 0; }
.mr-table td {
  padding: 16px 20px;
  border-bottom: 1px solid var(--mr-line);
  color: var(--mr-ink);
  background: #fff;
}
.mr-table tr:last-child td:first-child { border-radius: 0 0 0 14px; }
.mr-table tr:last-child td:last-child { border-radius: 0 0 14px 0; }
.mr-table tr:last-child td { border-bottom: none; }
.mr-table td:first-child { font-weight: 600; color: var(--mr-navy); }
.mr-note {
  font-size: 13px;
  color: var(--mr-muted);
  margin-top: 20px;
}

/* — final CTA — */
.mr-final {
  background: linear-gradient(135deg, var(--mr-navy-soft) 0%, var(--mr-navy) 100%);
  text-align: center;
}
.mr-final .mr-eyebrow { justify-content: center; color: var(--mr-accent-on-dark); }
.mr-final .mr-eyebrow::before { display: none; }
.mr-final h2 { color: #fff; }
.mr-final p { color: rgba(255, 255, 255, 0.78); max-width: 560px; margin: 0 auto 32px; }
.mr-final-wrap { max-width: 640px; margin: 0 auto; }
.mr-final .mr-actions { justify-content: center; }

@media (prefers-reduced-motion: reduce) {
  .mr-btn:hover, .mr-card:hover, .mr-node:hover .mr-node-circle { transform: none; }
  .mr-panel { transition: none; }
}

/* — responsive — */
@media (max-width: 980px) {
  .mr-cards { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .mr-track {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }
  .mr-track::before {
    top: 6px;
    bottom: 6px;
    left: 29px;
    right: auto;
    width: 2px;
    height: auto;
  }
  .mr-node {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    gap: 16px;
    padding: 10px 6px;
  }
  .mr-node-circle { width: 44px; height: 44px; flex: none; }
  .mr-node-circle svg { width: 20px; height: 20px; }
  .mr-node-label { max-width: none; text-align: left; font-size: 15px; }
  .mr-node[aria-selected="true"] .mr-node-circle { box-shadow: 0 0 0 5px rgba(236, 48, 19, 0.18); }
  .mr-panel { padding: 28px 20px; flex-direction: column; gap: 16px; }
  .mr-panel-icon { width: 48px; height: 48px; }
}

@media (max-width: 640px) {
  .mr-section { padding-block: 56px; }
  .mr-hero { padding-block: 56px 40px; }
  .mr-cards { grid-template-columns: 1fr; }
  .mr-actions { flex-direction: column; align-items: stretch; }
  .mr-btn { width: 100%; }
}
