/* ── Legally Brief: Texas — Landmark Week Edition ── */
:root {
  --bg-primary: #0a1628;
  --bg-secondary: #0f1d33;
  --bg-surface: rgba(212, 168, 83, 0.04);
  --bg-surface-alt: rgba(245, 230, 200, 0.03);
  --text-primary: #f5e6c8;
  --text-secondary: #c4b08a;
  --text-muted: #7a6d55;
  --accent-gold: #d4a853;
  --accent-crimson: #8b2020;
  --accent-cream: #f5e6c8;
  --accent-blue: #4a7fb5;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', 'Fira Code', monospace;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --ticker-h: 36px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.65;
  padding-top: var(--ticker-h);
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 10000;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

/* ── Ticker Strip ── */
.ticker {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--ticker-h);
  background: #060e1a;
  border-bottom: 1px solid rgba(212, 168, 83, 0.15);
  z-index: 9999;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.ticker__track {
  display: flex;
  align-items: center;
  white-space: nowrap;
  animation: ticker-scroll 45s linear infinite;
  will-change: transform;
}

.ticker__item {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-gold);
  padding: 0 1.5rem;
}

.ticker__sep {
  color: var(--accent-crimson);
  font-size: 0.5rem;
  opacity: 0.6;
}

@keyframes ticker-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ── Hero ── */
.hero {
  position: relative;
  min-height: 100dvh;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem 2rem;
  text-align: center;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 40%, rgba(212, 168, 83, 0.06) 0%, transparent 70%),
    radial-gradient(ellipse 60% 50% at 20% 80%, rgba(139, 32, 32, 0.04) 0%, transparent 60%),
    linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
  z-index: 0;
}

.hero__content {
  position: relative;
  z-index: 1;
  max-width: 800px;
}

.hero__kicker {
  font-family: var(--font-mono);
  font-size: clamp(0.6rem, 1.2vw, 0.75rem);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin-bottom: 1.5rem;
  opacity: 0;
}

.hero__title {
  font-family: var(--font-serif);
  font-size: clamp(3rem, 10vw, 7rem);
  font-weight: 900;
  line-height: 0.95;
  letter-spacing: -0.02em;
  color: var(--accent-cream);
  margin-bottom: 1.5rem;
  opacity: 0;
}

.hero__subtitle {
  font-size: clamp(1rem, 2.2vw, 1.4rem);
  color: var(--text-secondary);
  font-weight: 400;
  max-width: 500px;
  margin: 0 auto 3rem;
  opacity: 0;
}

.hero__stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  opacity: 0;
}

.hero__stat-number {
  font-family: var(--font-serif);
  font-size: clamp(4rem, 12vw, 8rem);
  font-weight: 900;
  color: var(--accent-gold);
  line-height: 1;
}

.hero__stat-label {
  font-family: var(--font-mono);
  font-size: clamp(0.55rem, 1vw, 0.7rem);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  line-height: 1.5;
}

.hero__scroll-cue {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  opacity: 0;
}

.hero__scroll-cue span {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.hero__scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--accent-gold), transparent);
  animation: scroll-pulse 2s ease-in-out infinite;
}

@keyframes scroll-pulse {
  0%, 100% { opacity: 0.3; transform: scaleY(1); }
  50% { opacity: 1; transform: scaleY(1.2); }
}

/* ── Sections — Shared ── */
.section {
  padding: clamp(4rem, 8vw, 7rem) clamp(1.5rem, 4vw, 3rem);
  border-top: 1px solid rgba(212, 168, 83, 0.08);
}

.section__inner {
  max-width: 800px;
  margin: 0 auto;
}

.section__label {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: clamp(0.55rem, 1vw, 0.65rem);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin-bottom: 1rem;
  padding: 0.3rem 0.8rem;
  border: 1px solid rgba(212, 168, 83, 0.2);
  border-radius: 2px;
}

.section__headline {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 4.5vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  color: var(--accent-cream);
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
}

.section__body {
  font-size: clamp(0.95rem, 1.8vw, 1.05rem);
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 1.25rem;
}

.section__body strong {
  color: var(--accent-gold);
  font-weight: 600;
}

/* ── Source Link ── */
.source {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: clamp(0.55rem, 0.9vw, 0.65rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  margin-top: 0.75rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(212, 168, 83, 0.12);
  transition: color 0.3s ease, border-color 0.3s ease;
}

.source:hover {
  color: var(--accent-gold);
  border-color: var(--accent-gold);
}

.source::before {
  content: '→';
  font-size: 0.75rem;
}

/* ── Data Strip ── */
.data-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(212, 168, 83, 0.1);
  border: 1px solid rgba(212, 168, 83, 0.12);
  border-radius: 4px;
  margin: 2rem 0;
  overflow: hidden;
}

.data-strip__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 1rem;
  background: var(--bg-primary);
  gap: 0.5rem;
}

.data-strip__number {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  color: var(--accent-gold);
  line-height: 1;
}

.data-strip__label {
  font-family: var(--font-mono);
  font-size: clamp(0.5rem, 0.8vw, 0.6rem);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-align: center;
}

.data-strip--dark .data-strip__item {
  background: var(--bg-secondary);
}

/* ── Pull Quote / Blockquote ── */
.section--blockquote {
  background: linear-gradient(135deg, rgba(139, 32, 32, 0.06) 0%, var(--bg-primary) 60%);
}

.pull-quote {
  border-left: 3px solid var(--accent-crimson);
  padding: 1.5rem 0 1.5rem 2rem;
  margin: 2rem 0;
}

.pull-quote p {
  font-family: var(--font-serif);
  font-size: clamp(1.3rem, 3vw, 1.8rem);
  font-style: italic;
  color: var(--accent-cream);
  line-height: 1.4;
  margin-bottom: 0.75rem;
}

.pull-quote cite {
  font-family: var(--font-mono);
  font-size: clamp(0.55rem, 0.9vw, 0.65rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-style: normal;
}

.pull-quote--small p {
  font-size: clamp(1.1rem, 2.2vw, 1.4rem);
}

/* ── Big Number Layout ── */
.big-number-layout {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3rem;
  align-items: start;
}

.big-number-layout__figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 2rem;
  background: var(--bg-surface);
  border: 1px solid rgba(212, 168, 83, 0.1);
  border-radius: 4px;
  position: sticky;
  top: calc(var(--ticker-h) + 2rem);
}

.big-number__value {
  font-family: var(--font-serif);
  font-size: clamp(3.5rem, 8vw, 5rem);
  font-weight: 900;
  color: var(--accent-gold);
  line-height: 1;
}

.big-number__unit {
  font-family: var(--font-mono);
  font-size: clamp(0.55rem, 0.9vw, 0.7rem);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-top: 0.5rem;
}

.big-number__context {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* ── Opinion Card ── */
.opinion-card {
  border: 1px solid rgba(212, 168, 83, 0.15);
  border-radius: 4px;
  overflow: hidden;
}

.opinion-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  background: rgba(212, 168, 83, 0.06);
  border-bottom: 1px solid rgba(212, 168, 83, 0.1);
}

.opinion-card__court {
  font-family: var(--font-serif);
  font-size: clamp(0.85rem, 1.5vw, 1rem);
  font-weight: 700;
  color: var(--accent-cream);
}

.opinion-card__type {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-gold);
  padding: 0.25rem 0.6rem;
  border: 1px solid rgba(212, 168, 83, 0.25);
  border-radius: 2px;
}

.opinion-card__body {
  padding: 2rem 1.5rem;
}

/* ── Comparison / Side-by-Side ── */
.comparison {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: rgba(212, 168, 83, 0.1);
  border-radius: 4px;
  overflow: hidden;
  margin: 2rem 0;
}

.comparison__col {
  padding: 1.5rem;
  background: var(--bg-primary);
}

.comparison__col--after {
  background: rgba(212, 168, 83, 0.03);
}

.comparison__heading {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(212, 168, 83, 0.15);
}

.comparison__list {
  list-style: none;
}

.comparison__list li {
  font-size: clamp(0.8rem, 1.4vw, 0.9rem);
  color: var(--text-secondary);
  padding: 0.5rem 0;
  padding-left: 1rem;
  position: relative;
  line-height: 1.5;
}

.comparison__list li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--text-muted);
}

.comparison__col--after .comparison__list li::before {
  content: '+';
  color: var(--accent-gold);
}

/* ── Timeline ── */
.timeline {
  position: relative;
  padding-left: 2rem;
  margin: 2rem 0;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent-gold), rgba(212, 168, 83, 0.1));
}

.timeline__event {
  position: relative;
  padding: 0 0 2.5rem 1.5rem;
}

.timeline__event::before {
  content: '';
  position: absolute;
  left: -2rem;
  top: 0.15rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent-gold);
  border: 2px solid var(--bg-primary);
  box-shadow: 0 0 0 2px var(--accent-gold);
}

.timeline__date {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-gold);
  display: block;
  margin-bottom: 0.5rem;
}

.timeline__content h4 {
  font-family: var(--font-serif);
  font-size: clamp(1rem, 1.8vw, 1.15rem);
  color: var(--accent-cream);
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.timeline__content h4 em {
  font-style: italic;
  color: var(--text-secondary);
}

.timeline__content p {
  font-size: clamp(0.85rem, 1.4vw, 0.95rem);
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── Regulatory Card ── */
.reg-card {
  border: 1px solid rgba(212, 168, 83, 0.12);
  border-radius: 4px;
  padding: 2rem;
  margin: 2rem 0;
  background: var(--bg-surface);
  position: relative;
}

.reg-card__badge {
  position: absolute;
  top: -0.6rem;
  left: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--bg-primary);
  background: var(--accent-gold);
  padding: 0.2rem 0.6rem;
  border-radius: 2px;
  font-weight: 600;
}

.reg-card__title {
  font-family: var(--font-serif);
  font-size: clamp(1.2rem, 2.5vw, 1.5rem);
  color: var(--accent-cream);
  margin-bottom: 1rem;
  font-weight: 700;
}

.reg-card__desc {
  font-size: clamp(0.9rem, 1.5vw, 1rem);
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 1rem;
}

.reg-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  padding-top: 1rem;
  border-top: 1px solid rgba(212, 168, 83, 0.08);
}

/* ── Stacked Cards ── */
.stacked-cards {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin: 2rem 0;
}

.stacked-card {
  padding: 2rem;
  border: 1px solid rgba(212, 168, 83, 0.1);
  border-radius: 4px;
  background: var(--bg-surface);
  position: relative;
  transition: border-color 0.3s ease;
}

.stacked-card:hover {
  border-color: rgba(212, 168, 83, 0.25);
}

.stacked-card__num {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4vw, 2.5rem);
  font-weight: 900;
  color: rgba(212, 168, 83, 0.12);
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  line-height: 1;
}

.stacked-card__title {
  font-family: var(--font-serif);
  font-size: clamp(1.1rem, 2vw, 1.3rem);
  font-weight: 700;
  color: var(--accent-cream);
  margin-bottom: 0.75rem;
}

.stacked-card__body {
  font-size: clamp(0.85rem, 1.4vw, 0.95rem);
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ── Highlight Box ── */
.highlight-box {
  padding: 1.5rem 2rem;
  margin: 2rem 0;
  border-left: 3px solid var(--accent-gold);
  background: rgba(212, 168, 83, 0.04);
  border-radius: 0 4px 4px 0;
}

.highlight-box--crimson {
  border-left-color: var(--accent-crimson);
  background: rgba(139, 32, 32, 0.06);
}

.highlight-box__title {
  font-family: var(--font-mono);
  font-size: clamp(0.6rem, 1vw, 0.7rem);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin-bottom: 0.75rem;
}

.highlight-box--crimson .highlight-box__title {
  color: #c94040;
}

.highlight-box__body {
  font-size: clamp(0.85rem, 1.5vw, 0.95rem);
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ── Section Variants ── */
.section--data-strip {
  background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
}

.section--big-number {
  background: var(--bg-primary);
}

.section--opinion-card {
  background: var(--bg-secondary);
}

.section--comparison {
  background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
}

.section--timeline {
  background: var(--bg-primary);
}

.section--reg-card {
  background: var(--bg-secondary);
}

.section--crim-justice {
  background: linear-gradient(180deg, var(--bg-primary) 0%, rgba(139, 32, 32, 0.03) 100%);
}

.section--stacked {
  background: var(--bg-secondary);
}

.section--real-estate {
  background: var(--bg-primary);
}

.section--healthcare {
  background: var(--bg-secondary);
}

.section--immigration {
  background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
}

/* ── Footer ── */
.site-footer {
  padding: 3rem 1.5rem;
  text-align: center;
  border-top: 1px solid rgba(212, 168, 83, 0.1);
}

.site-footer__brand {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.site-footer__pulse {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-gold);
  box-shadow: 0 0 8px var(--accent-gold);
  margin-right: 0.5rem;
  animation: pulse 2.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.site-footer__regen,
.site-footer__session,
.site-footer__timestamp {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .data-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  .big-number-layout {
    grid-template-columns: 1fr;
  }

  .big-number-layout__figure {
    position: static;
    flex-direction: row;
    gap: 1rem;
    align-items: baseline;
  }

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

  .hero {
    padding: 3rem 1.5rem 2rem;
  }

  .section {
    padding: clamp(3rem, 6vw, 5rem) 1.25rem;
  }

  .pull-quote {
    padding-left: 1.25rem;
  }

  .timeline {
    padding-left: 1.5rem;
  }

  .timeline__event::before {
    left: -1.5rem;
  }

  .timeline::before {
    left: 0;
  }
}

@media (max-width: 480px) {
  :root {
    --ticker-h: 30px;
  }

  .data-strip {
    grid-template-columns: 1fr 1fr;
  }

  .data-strip__item {
    padding: 1rem 0.5rem;
  }

  .ticker__item {
    font-size: 0.55rem;
    padding: 0 1rem;
  }

  .hero__title {
    font-size: clamp(2.5rem, 12vw, 4rem);
  }

  .stacked-card {
    padding: 1.5rem;
  }

  .stacked-card__num {
    font-size: 1.8rem;
  }

  .reg-card {
    padding: 1.5rem;
  }

  .opinion-card__header {
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-start;
  }

  .highlight-box {
    padding: 1.25rem 1.5rem;
  }
}
