/* For Lawmakers pages. Visual tokens match Live Free Index (rankings.css)
   without loading chart rules. Scoped to these pages. */

.lawmakers {
  --navy: #0b1f3a;
  --navy2: #13294b;
  --ink: #13233d;
  --mut: #5d6b80;
  --line: #e3e8ef;
  --acc: #e8a33d;
  --bg: #f7f8fb;
  --gold-ink: #7a4e12;
  --link: #1a3f73;
  background: var(--bg);
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
}

html:has(body.page-lawmakers) {
  background-image: none;
  background-color: #f7f8fb;
}
body.page-lawmakers {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  background: #f7f8fb;
  color: var(--ink);
}
body.page-lawmakers::before {
  content: none !important;
  display: none !important;
}
body.page-lawmakers > .lawmakers {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
}
body.page-lawmakers > .lawmakers > * {
  min-width: 0;
}

.lawmakers .kicker {
  font: 700 12px/1 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--acc);
}
.lawmakers-banner {
  background: var(--navy);
  color: #fff;
  padding: 28px 20px 46px;
}
.lawmakers .wrap {
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 20px;
}
.lawmakers-banner h1 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(28px, 4.4vw, 48px);
  line-height: 1.08;
  margin: 10px 0;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #fff;
  text-wrap: balance;
}
.lawmakers .dek {
  font-size: clamp(16px, 1.6vw, 19px);
  line-height: 1.45;
  color: #c9d3e3;
  max-width: 800px;
  margin: 0;
}
.lawmakers .dek a {
  color: #fff;
  text-underline-offset: 2px;
}

.lawmakers .lm-panel {
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(11, 31, 58, 0.04), 0 8px 24px rgba(11, 31, 58, 0.05);
}
.lawmakers .lm-notice {
  position: relative;
  margin-top: -22px;
  padding: 16px 18px;
  border-left: 4px solid var(--acc);
}
.lawmakers .lm-notice p {
  margin: 0;
  font: 15px/1.5 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink);
}
.lawmakers .lm-notice p + p {
  margin-top: 8px;
}
.lawmakers .lm-notice strong {
  color: var(--gold-ink);
  font-weight: 700;
}

.lawmakers .lm-sec {
  margin: 28px 0 12px;
  font: 700 13px/1 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mut);
}
.lawmakers .lm-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.lawmakers .lm-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  height: 100%;
  padding: 18px 18px 16px;
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(11, 31, 58, 0.04), 0 8px 24px rgba(11, 31, 58, 0.05);
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.lawmakers .lm-card:hover {
  transform: translateY(-1px);
  border-color: var(--navy);
  box-shadow: 0 6px 18px rgba(11, 31, 58, 0.08);
}
.lawmakers .lm-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
}
.lawmakers .lm-tag {
  font: 700 10px/1.3 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-ink);
}
.lawmakers .lm-ver {
  flex: none;
  padding: 4px 8px;
  border-radius: 999px;
  background: #f3f6fb;
  border: 1px solid var(--line);
  font: 600 12px/1 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--mut);
}
.lawmakers .lm-card h3 {
  margin: 4px 0 0;
  font: 700 18px/1.25 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--navy);
  letter-spacing: -0.01em;
}
.lawmakers .lm-card:hover h3 {
  text-decoration: underline;
  text-decoration-color: var(--acc);
  text-underline-offset: 3px;
}
.lawmakers .lm-card p {
  margin: 0;
  font: 14.5px/1.45 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--mut);
}

.lawmakers .lm-doc,
.lawmakers .lm-bill {
  margin-top: 16px;
  padding: 22px 26px 24px;
}
.lawmakers .lm-doc h2,
.lawmakers .lm-bill h2 {
  margin: 1.35em 0 0.45em;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(20px, 2.2vw, 26px);
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--navy);
}
.lawmakers .lm-doc h2:first-child,
.lawmakers .lm-bill h2:first-child {
  margin-top: 0;
}
.lawmakers .lm-doc p,
.lawmakers .lm-doc li,
.lawmakers .lm-bill .lm-lead,
.lawmakers .lm-download {
  font-family: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--ink);
}
.lawmakers .lm-doc p,
.lawmakers .lm-bill .lm-lead {
  margin: 0.65em 0 0;
}
.lawmakers .lm-doc ul,
.lawmakers .lm-doc ol {
  margin: 0.55em 0 0;
  padding-left: 1.25em;
}
.lawmakers .lm-doc ul { list-style: disc; }
.lawmakers .lm-doc ol { list-style: decimal; }
.lawmakers .lm-doc li { margin: 0 0 0.4em; }
.lawmakers .lm-doc li:last-child { margin-bottom: 0; }
.lawmakers .lm-doc a,
.lawmakers .lm-bill a,
.lawmakers .lm-back a,
.lawmakers .lm-source a {
  color: var(--link);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  overflow-wrap: anywhere;
}
.lawmakers .lm-doc a:hover,
.lawmakers .lm-bill a:hover,
.lawmakers .lm-back a:hover,
.lawmakers .lm-source a:hover {
  color: var(--navy);
}

.lawmakers pre.bill-text {
  margin: 14px 0 0;
  padding: 16px 18px;
  max-width: none;
  overflow-x: auto;
  white-space: pre-wrap;
  font-family: ui-monospace, "IBM Plex Mono", SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12.5px;
  line-height: 1.55;
  color: #102038;
  background: #f4f7fb;
  border: 1px solid var(--line);
  border-radius: 10px;
}
.lawmakers .lm-download {
  margin: 14px 0 0;
  font-weight: 600;
  font-size: 14.5px;
}

.lawmakers-banner .lm-kicker-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.lawmakers-banner .lm-ver {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.35);
  color: #f4f7fb;
}

.lawmakers .lm-doc h3 {
  margin: 1.15em 0 0.4em;
  font: 700 13px/1.3 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--navy2);
}

.lawmakers p.lm-draft-flag,
.lawmakers .lm-doc p.lm-draft-flag {
  margin: 0.85em 0 0;
  padding: 10px 12px;
  border-left: 4px solid var(--acc);
  background: #fbf8f2;
  font: 600 14.5px/1.45 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--gold-ink);
}
.lawmakers > .wrap > p.lm-draft-flag {
  margin-top: 16px;
}

.lawmakers .lm-table-wrap {
  margin-top: 0.75em;
  overflow-x: auto;
}
.lawmakers table.lm-table {
  width: 100%;
  border-collapse: collapse;
  font-family: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 14.5px;
  line-height: 1.45;
  color: var(--ink);
}
.lawmakers table.lm-table th,
.lawmakers table.lm-table td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
}
.lawmakers table.lm-table th {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mut);
  font-weight: 700;
}
.lawmakers table.lm-table td:first-child {
  font-weight: 600;
  white-space: nowrap;
}
.lawmakers table.lm-table tr:last-child td {
  border-bottom: 0;
}

.lawmakers .lm-source {
  margin: 18px 0 0;
  font: 13px/1.45 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--mut);
}
.lawmakers .lm-back {
  margin: 18px 0 4px;
  font: 600 14px/1.4 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}

.lawmakers-foot {
  margin-top: auto;
  background: var(--navy);
  color: #9fb0c8;
  font: 13px/1.5 "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  padding: 20px 20px max(20px, env(safe-area-inset-bottom, 0px));
}
.lawmakers-foot a { color: #fff; }

.lawmakers a:focus-visible,
.lawmakers :focus-visible {
  outline: 2px solid #e0b84e;
  outline-offset: 3px;
}

@media (min-width: 700px) {
  .lawmakers .lm-cards {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .lawmakers-banner { padding: 22px 0 40px; }
  .lawmakers .wrap {
    padding-left: max(16px, env(safe-area-inset-left, 0px));
    padding-right: max(16px, env(safe-area-inset-right, 0px));
  }
  .lawmakers .lm-notice { padding: 14px 14px 14px 14px; }
  .lawmakers .lm-doc,
  .lawmakers .lm-bill { padding: 16px 14px 18px; }
  .lawmakers .lm-card { padding: 16px 14px 14px; }
  .lawmakers .lm-card h3 { font-size: 17px; }
  .lawmakers pre.bill-text {
    font-size: 12px;
    padding: 12px;
  }
}

@media print {
  html:has(body.page-lawmakers),
  body.page-lawmakers,
  .lawmakers,
  .lawmakers-banner,
  .lawmakers-foot {
    background: #fff !important;
    color: #111 !important;
  }
  .lawmakers-banner h1,
  .lawmakers .dek,
  .lawmakers .kicker,
  .lawmakers-foot {
    color: #111 !important;
  }
  .lawmakers .lm-panel,
  .lawmakers .lm-card,
  .lawmakers pre.bill-text {
    box-shadow: none;
  }
}
