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

:root {
  --bg: #0a0a0a;
  --bg-alt: #111111;
  --text: #e8e8e8;
  --text-muted: #888;
  --accent: #ff3333;
  --accent2: #ff8800;
  --border: #222;
  --card-bg: #161616;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

/* HERO */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 2rem;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(255,51,51,0.12) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(255,136,0,0.08) 0%, transparent 50%),
    var(--bg);
  position: relative;
}

.hero h1 {
  font-size: clamp(3rem, 10vw, 8rem);
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1;
  background: linear-gradient(135deg, #ffffff 30%, #ff3333 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1.5rem;
}

.tagline {
  font-size: clamp(1rem, 2.5vw, 1.4rem);
  color: var(--text-muted);
  max-width: 600px;
  margin-bottom: 2.5rem;
}

.nav-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: center;
}

.nav-pills a {
  color: var(--text-muted);
  text-decoration: none;
  border: 1px solid var(--border);
  padding: 0.4rem 1rem;
  border-radius: 999px;
  font-size: 0.85rem;
  transition: all 0.2s;
}

.nav-pills a:hover {
  color: #fff;
  border-color: var(--accent);
  background: rgba(255,51,51,0.1);
}

.scroll-hint {
  position: absolute;
  bottom: 2rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}

/* SECTIONS */
.section { padding: 5rem 1.5rem; }
.section.alt { background: var(--bg-alt); }

.container {
  max-width: 960px;
  margin: 0 auto;
}

.section-header {
  margin-bottom: 3rem;
}

.tag {
  display: inline-block;
  background: rgba(255,51,51,0.15);
  color: var(--accent);
  border: 1px solid rgba(255,51,51,0.3);
  padding: 0.2rem 0.8rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.section-header h2 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 1rem;
}

.section-intro {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 640px;
}

/* CARDS */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  margin-bottom: 3rem;
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.75rem 1.5rem;
  border-top-width: 3px;
}

.card-red   { border-top-color: #ff3333; }
.card-orange { border-top-color: #ff8800; }
.card-gray  { border-top-color: #666; }
.card-purple { border-top-color: #9933ff; }

.stat {
  font-size: 2.2rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  margin-bottom: 0.6rem;
  line-height: 1.1;
}
.card-red .stat    { color: #ff5555; }
.card-orange .stat { color: #ff9922; }
.card-gray .stat   { color: #aaa; }
.card-purple .stat { color: #bb66ff; font-size: 1.4rem; }

.stat-label {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* CHARTS */
.chart-wrap {
  margin-bottom: 2rem;
}

.chart-title {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 1rem;
}

.chart {
  width: 100%;
  height: auto;
  display: block;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem 0.5rem;
}

.chart-note {
  font-size: 0.75rem;
  color: #555;
  margin-top: 0.5rem;
}

/* BAR CHART */
.bar-section { margin-bottom: 2rem; }

.bar-group { display: flex; flex-direction: column; gap: 0.75rem; margin: 1.25rem 0; }

.bar-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  align-items: center;
  gap: 1rem;
}

.bar-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: right;
}

.bar-track {
  background: #1a1a1a;
  border-radius: 4px;
  height: 32px;
  overflow: visible;
  position: relative;
}

.bar {
  height: 32px;
  border-radius: 4px;
  background: linear-gradient(90deg, #2266cc, #44aaff);
  max-width: 100%;
  position: relative;
  transition: width 1.2s cubic-bezier(0.4,0,0.2,1);
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.bar.bar-bad {
  background: linear-gradient(90deg, #cc3300, #ff5533);
  max-width: 100%;
}

.bar::after {
  content: attr(data-val);
  position: absolute;
  right: -3.5rem;
  font-size: 0.8rem;
  font-weight: 700;
  white-space: nowrap;
  color: var(--text);
}

/* CALLOUT */
.callout {
  background: rgba(255,51,51,0.07);
  border-left: 3px solid var(--accent);
  padding: 1.25rem 1.5rem;
  border-radius: 0 8px 8px 0;
  font-size: 1rem;
  color: var(--text-muted);
  margin-top: 2rem;
}

.callout strong { color: var(--text); }

/* COMPARE GRID */
.compare-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.compare-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
}

.country {
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.compare-list { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; }

.compare-list li {
  padding: 0.4rem 0.5rem 0.4rem 1.75rem;
  border-radius: 4px;
  font-size: 0.9rem;
  position: relative;
}

.compare-list li::before {
  position: absolute;
  left: 0.4rem;
  font-size: 0.9rem;
}

.compare-list li.bad { background: rgba(255,50,50,0.06); color: #ff7777; }
.compare-list li.bad::before { content: '✗'; color: #ff4444; }
.compare-list li.good { background: rgba(50,200,100,0.06); color: #66cc88; }
.compare-list li.good::before { content: '✓'; color: #44bb66; }

/* TIMELINE */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 2rem;
  position: relative;
  padding-left: 80px;
  border-left: 2px solid var(--border);
  margin-left: 40px;
}

.timeline-item {
  padding: 1.25rem 0 1.25rem 1.5rem;
  position: relative;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -7px;
  top: 1.6rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
}

.tl-year {
  position: absolute;
  left: -90px;
  top: 1.25rem;
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--accent);
  width: 60px;
  text-align: right;
}

.tl-text {
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* EXAMPLES */
.examples { margin-top: 2rem; }
.examples h3 { font-size: 1.1rem; margin-bottom: 1.25rem; color: var(--text-muted); font-weight: 600; }

.example-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.example-item {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.25rem;
}

.ex-icon { font-size: 1.8rem; margin-bottom: 0.75rem; }
.ex-text { font-size: 0.88rem; color: var(--text-muted); line-height: 1.5; }
.ex-text strong { color: var(--text); }

/* POLICY LIST */
.policy-list { display: flex; flex-direction: column; gap: 0; }

.policy-item {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--border);
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 1.5rem;
  align-items: start;
}

.policy-item:first-child { border-top: 1px solid var(--border); }

.policy-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--accent2);
}

.policy-desc {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* SOURCE LINKS */
.src-link {
  color: #888;
  font-size: 0.78rem;
  text-decoration: none;
  border-bottom: 1px dotted #444;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s;
}
.src-link:hover { color: var(--accent); border-color: var(--accent); }

/* WEALTH TABLE */
.wealth-table-wrap {
  overflow-x: auto;
  margin-bottom: 2rem;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.wealth-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.wealth-table thead tr {
  background: #161616;
  border-bottom: 2px solid var(--border);
}

.wealth-table th {
  padding: 0.85rem 1rem;
  text-align: left;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  font-weight: 600;
  white-space: nowrap;
}

.wealth-table tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}

.wealth-table tbody tr:last-child { border-bottom: none; }
.wealth-table tbody tr:hover { background: rgba(255,255,255,0.03); }

.wealth-table td {
  padding: 1rem;
  vertical-align: top;
}

.rank {
  color: var(--text-muted);
  font-weight: 700;
  font-size: 1rem;
  width: 36px;
}

.member-name {
  font-weight: 700;
  white-space: nowrap;
}

.party {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
  margin-right: 0.4rem;
}

.party.rep { background: rgba(255,60,60,0.2); color: #ff6666; }
.party.dem { background: rgba(60,100,255,0.2); color: #6699ff; }

.networth {
  font-weight: 800;
  color: #ffcc44;
  white-space: nowrap;
  font-size: 1rem;
}

.source {
  color: var(--text-muted);
  font-size: 0.85rem;
  line-height: 1.5;
  max-width: 380px;
}

/* FOOTER */
.footer {
  background: #000;
  padding: 5rem 1.5rem;
  text-align: center;
  border-top: 1px solid var(--border);
}

.footer h2 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 900;
  margin-bottom: 0.75rem;
  color: var(--accent);
}

.footer > .container > p {
  color: var(--text-muted);
  margin-bottom: 2.5rem;
  font-size: 1.05rem;
}

.cta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.25rem;
  text-align: left;
  margin-bottom: 3rem;
}

.cta-item {
  background: #0d0d0d;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
}

.cta-item strong {
  display: block;
  font-size: 1rem;
  margin-bottom: 0.6rem;
  color: #fff;
}

.cta-item p { font-size: 0.88rem; color: var(--text-muted); line-height: 1.5; }

.footer-note {
  font-size: 0.8rem;
  color: #333;
  margin-bottom: 0 !important;
}

/* RESPONSIVE */
@media (max-width: 640px) {
  .policy-item { grid-template-columns: 1fr; gap: 0.5rem; }
  .bar-row { grid-template-columns: 100px 1fr; }
  .timeline { padding-left: 60px; margin-left: 20px; }
  .tl-year { left: -70px; width: 50px; font-size: 0.8rem; }
  .bar::after { right: -3rem; font-size: 0.72rem; }
}
