/* ==========================================================================
   Senior Benefits Central
   Editorial palette: warm paper, forest ink, ochre accent.
   Serif display / sans body. No external font or asset dependencies.
   ========================================================================== */

:root {
  /* surfaces */
  --paper:      #fbf9f6;
  --paper-warm: #f4efe6;
  --paper-card: #ffffff;

  /* ink */
  --ink:        #1c1b18;
  --ink-mid:    #4f4c45;
  --ink-soft:   #6d6960;

  /* accents */
  --forest:      #275446;
  --forest-deep: #1b3c31;
  --forest-lift: #326a58;
  --ochre:       #a9741f;
  --ochre-soft:  #f0e4cd;

  /* lines */
  --rule:      #e4ddd0;
  --rule-firm: #d3c9b7;

  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --measure: 68ch;
  --shell: 1180px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 18.5px;
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: var(--shell); margin: 0 auto; padding: 0 26px; }

a { color: var(--forest); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--ochre); }
img { max-width: 100%; height: auto; }

::selection { background: var(--ochre-soft); }

/* --------------------------------------------------------------------------
   Top disclosure — warm band, small-caps label, hairline rules
   -------------------------------------------------------------------------- */
.top-disclosure {
  background: var(--paper-warm);
  border-bottom: 1px solid var(--rule-firm);
  font-size: 14.5px;
  line-height: 1.62;
  color: var(--ink-mid);
}
.top-disclosure .wrap { padding-top: 14px; padding-bottom: 14px; }
.top-disclosure p { margin: 6px 0 0; max-width: 104ch; }
.top-disclosure strong {
  display: block;
  font-family: var(--sans);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--ochre);
}
.top-disclosure a { color: var(--forest); font-weight: 600; }

/* --------------------------------------------------------------------------
   Masthead
   -------------------------------------------------------------------------- */
.site-header { background: var(--paper); border-bottom: 2px solid var(--ink); }

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  padding-top: 26px;
  padding-bottom: 18px;
}

.brand {
  display: block;
  text-decoration: none;
  color: var(--ink);
  line-height: 1.1;
}
.brand b {
  display: block;
  font-family: var(--serif);
  font-size: 30px;
  font-weight: 600;
  letter-spacing: -0.015em;
}
.brand b span { color: var(--forest); font-style: italic; }
.brand small {
  display: block;
  margin-top: 7px;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 22px;
  list-style: none;
  margin: 0;
  padding: 0;
}
nav a {
  display: inline-block;
  padding: 3px 0;
  text-decoration: none;
  color: var(--ink-mid);
  font-size: 15.5px;
  font-weight: 500;
  border-bottom: 2px solid transparent;
}
nav a:hover { color: var(--forest); border-bottom-color: var(--rule-firm); }
nav a[aria-current="page"] { color: var(--ink); font-weight: 700; border-bottom-color: var(--ochre); }

/* --------------------------------------------------------------------------
   Hero — deep forest block
   -------------------------------------------------------------------------- */
.hero {
  background: var(--forest-deep);
  color: var(--paper);
  padding: 64px 0 60px;
  position: relative;
}
.hero::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 5px;
  background: linear-gradient(90deg, var(--ochre) 0 22%, transparent 22%);
}
.hero .eyebrow {
  margin: 0 0 16px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: #cfa456;
}
.hero h1 {
  margin: 0 0 20px;
  max-width: 19ch;
  font-family: var(--serif);
  font-size: clamp(34px, 5.2vw, 55px);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.022em;
}
.hero p {
  margin: 0;
  max-width: 58ch;
  font-size: 19.5px;
  line-height: 1.62;
  color: #ded7c9;
}

/* --------------------------------------------------------------------------
   Article shell — sticky contents rail + prose column
   -------------------------------------------------------------------------- */
main { padding: 0 0 10px; }

.shell {
  display: grid;
  grid-template-columns: 218px minmax(0, 1fr);
  gap: 56px;
  align-items: start;
  padding-top: 48px;
}
.shell.no-rail { grid-template-columns: minmax(0, 1fr); }

.rail { position: sticky; top: 28px; font-size: 14.5px; line-height: 1.45; }
.rail h4 {
  margin: 0 0 12px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--rule-firm);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ochre);
}
.rail ol { list-style: none; margin: 0; padding: 0; counter-reset: rail; }
.rail li { counter-increment: rail; margin-bottom: 11px; }
.rail a {
  display: grid;
  grid-template-columns: 26px 1fr;
  gap: 4px;
  text-decoration: none;
  color: var(--ink-mid);
}
.rail a::before {
  content: counter(rail, decimal-leading-zero);
  font-family: var(--serif);
  font-size: 12.5px;
  color: var(--rule-firm);
  padding-top: 2px;
}
.rail a:hover { color: var(--forest); }
.rail a:hover::before { color: var(--ochre); }

/* Everything after the rail lives in one grid item, so multiple body blocks
   (prose, cards, prose) stack instead of flowing back into the rail column. */
.content { min-width: 0; }

/* Reading column is capped for line length; cards and tables may use the
   full content width. */
.prose { max-width: var(--measure); }

/* --------------------------------------------------------------------------
   Prose typography
   -------------------------------------------------------------------------- */
.prose > p:first-child, .lead {
  font-family: var(--serif);
  font-size: 22px;
  line-height: 1.52;
  color: var(--ink);
  margin-bottom: 26px;
}

h2 {
  margin: 52px 0 16px;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
  font-family: var(--serif);
  font-size: 30px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.017em;
  scroll-margin-top: 24px;
}
h2:first-child { margin-top: 0; border-top: 0; padding-top: 0; }

h3 {
  margin: 32px 0 9px;
  font-family: var(--sans);
  font-size: 17.5px;
  font-weight: 700;
  letter-spacing: 0.005em;
  color: var(--forest-deep);
}

p { margin: 0 0 18px; }

/* List styling is deliberately scoped to .prose so it cannot leak into the
   nav, the contents rail, or the footer columns -- all of which are also ul/ol. */
.prose ul, .prose ol { margin: 0 0 18px; padding-left: 0; list-style: none; }
.prose li { margin-bottom: 11px; padding-left: 26px; position: relative; }
.prose ul > li::before {
  content: "";
  position: absolute;
  left: 6px; top: 0.72em;
  width: 6px; height: 6px;
  background: var(--ochre);
  border-radius: 50%;
}
.prose ol { counter-reset: ol; }
.prose ol > li { counter-increment: ol; }
.prose ol > li::before {
  content: counter(ol) ".";
  position: absolute;
  left: 0; top: 0;
  font-family: var(--serif);
  font-weight: 600;
  color: var(--ochre);
}
.prose li > ul { margin-top: 11px; margin-bottom: 0; }

strong { font-weight: 700; }
em { font-style: italic; }

/* --------------------------------------------------------------------------
   Index cards
   -------------------------------------------------------------------------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(258px, 1fr));
  gap: 1px;
  margin: 38px 0 12px;
  background: var(--rule);
  border: 1px solid var(--rule);
}
.card {
  background: var(--paper-card);
  padding: 26px 24px 24px;
  counter-increment: card;
  transition: background 0.15s ease;
}
.cards { counter-reset: card; }
.card::before {
  content: counter(card, decimal-leading-zero);
  display: block;
  margin-bottom: 12px;
  font-family: var(--serif);
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--ochre);
}
.card h3 { margin: 0 0 9px; font-family: var(--serif); font-size: 20px; font-weight: 600; color: var(--ink); }
.card p { margin-bottom: 14px; font-size: 16px; line-height: 1.6; color: var(--ink-mid); }
.card a { font-size: 14.5px; font-weight: 700; text-decoration: none; }
.card a:hover { text-decoration: underline; }
.card:hover { background: #fffdf9; }

/* --------------------------------------------------------------------------
   Callout
   -------------------------------------------------------------------------- */
.callout {
  margin: 34px 0;
  padding: 24px 26px 20px;
  background: var(--paper-warm);
  border-top: 3px solid var(--ochre);
  font-size: 16.5px;
  line-height: 1.65;
}
.callout > p:first-child > strong:only-child,
.callout strong:first-child {
  display: block;
  margin-bottom: 6px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ochre);
}
.callout p { margin-bottom: 12px; }
.callout p:last-child, .callout ul:last-child { margin-bottom: 0; }
.prose .callout ul > li::before { background: var(--rule-firm); }
.prose .callout li { margin-bottom: 8px; }

/* --------------------------------------------------------------------------
   Tables
   -------------------------------------------------------------------------- */
.table-scroll { margin: 30px 0; overflow-x: auto; }
table { border-collapse: collapse; width: 100%; min-width: 520px; font-size: 16px; line-height: 1.55; }
thead th {
  border-bottom: 2px solid var(--ink);
  padding: 0 16px 10px 0;
  text-align: left;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  vertical-align: bottom;
}
tbody td {
  padding: 14px 16px 14px 0;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
  color: var(--ink-mid);
}
tbody td:first-child { color: var(--ink); padding-right: 24px; }
tbody tr:last-child td { border-bottom: 1px solid var(--rule-firm); }

/* --------------------------------------------------------------------------
   Next link
   -------------------------------------------------------------------------- */
.next {
  margin-top: 46px;
  padding-top: 22px;
  border-top: 2px solid var(--ink);
}
.next a {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 600;
  text-decoration: none;
}
.next a:hover { text-decoration: underline; }
.next span {
  display: block;
  margin-bottom: 4px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-family: var(--sans);
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
.site-footer {
  margin-top: 70px;
  background: var(--forest-deep);
  color: #c9c2b4;
  padding: 52px 0 40px;
  font-size: 14.5px;
  line-height: 1.68;
}
.site-footer a { color: #e6ddcb; text-decoration: none; }
.site-footer a:hover { color: #d8a960; text-decoration: underline; }

.footer-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 32px;
  padding-bottom: 34px;
  border-bottom: 1px solid rgba(255,255,255,0.14);
}
.footer-cols h4 {
  margin: 0 0 13px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #cfa456;
}
.footer-cols ul { list-style: none; margin: 0; padding: 0; }
.footer-cols li { margin-bottom: 7px; padding-left: 0; }
.footer-cols li::before { display: none; }

.disclosures { padding-top: 32px; }
.disclosures h4 {
  margin: 0 0 16px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #cfa456;
}
.disclosures p {
  margin: 0 0 14px;
  font-size: 13.5px;
  line-height: 1.62;
  color: #a9a294;
  max-width: 92ch;
}
.disclosures p strong { color: #ddd5c5; }

.copyright {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid rgba(255,255,255,0.14);
  font-size: 13px;
  color: #9b9486;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1000px) {
  .shell { grid-template-columns: minmax(0, 1fr); gap: 0; padding-top: 36px; }
  .rail {
    position: static;
    margin-bottom: 40px;
    padding: 20px 22px;
    background: var(--paper-warm);
    border-top: 3px solid var(--ochre);
  }
  .rail ol { columns: 2; column-gap: 30px; }
  .rail li { break-inside: avoid; }
  .prose { max-width: none; }
}

@media (max-width: 720px) {
  body { font-size: 18px; }
  .wrap { padding: 0 20px; }
  .hero { padding: 44px 0 42px; }
  .hero p { font-size: 18px; }
  .header-inner { align-items: flex-start; padding-top: 20px; }
  .brand b { font-size: 25px; }
  nav ul { gap: 2px 18px; }
  .prose > p:first-child, .lead { font-size: 20px; }
  h2 { font-size: 25px; margin-top: 44px; }
  /* The disclosure must stay prominent, but at 18px it filled a whole phone
     screen before the masthead. Smaller, still above the fold, still first. */
  .top-disclosure { font-size: 13.5px; line-height: 1.55; }
  .top-disclosure strong { font-size: 10.5px; letter-spacing: 0.11em; }
  .rail ol { columns: 1; }
  .callout { padding: 20px 20px 16px; }
  .site-footer { margin-top: 52px; padding: 42px 0 36px; }
}
