/* ============================================================
   TOM SELLECK — Brazoria County Criminal District Attorney
   Brand: navy / campaign red / cream  (from Selleck logo)
   ============================================================ */

:root {
  --navy: #142f55;
  --navy-deep: #0b1e3a;
  --navy-mid: #1d4173;
  --red: #bf3a3f;
  --red-deep: #a52f34;
  --cream: #faf7f1;
  --paper: #ffffff;
  --ink: #1c2534;
  --ink-soft: #5a6575;
  --rule: #e7e1d6;
  --gold: #c9a86a;
  --serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --sans: "Inter", "Helvetica Neue", Arial, sans-serif;
  --shadow-lg: 0 30px 80px rgba(11, 30, 58, 0.18);
  --shadow-md: 0 16px 44px rgba(11, 30, 58, 0.12);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html { scroll-behavior: smooth; }

html {
  overflow-x: hidden;
}

body {
  font-family: var(--sans);
  font-size: 16.5px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

::selection { background: var(--navy); color: var(--cream); }

.container { width: min(1140px, 91%); margin: 0 auto; }

/* ---------- Reveal-on-scroll animations ---------- */

.reveal {
  opacity: 0;
  transform: translateY(34px);
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
  transition-delay: var(--d, 0s);
  will-change: opacity, transform;
}

.reveal.in { opacity: 1; transform: none; }

.reveal-left { transform: translateX(-40px); }
.reveal-right { transform: translateX(40px); }
.reveal-left.in, .reveal-right.in { transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal-left, .reveal-right {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  html { scroll-behavior: auto; }
}

/* ---------- Header / Navigation ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(250, 247, 241, 0.86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(20, 47, 85, 0.08);
  transition: box-shadow 0.3s ease, background 0.3s ease;
}

.site-header.scrolled {
  background: rgba(250, 247, 241, 0.97);
  box-shadow: 0 10px 34px rgba(11, 30, 58, 0.1);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 10px 0;
}

.logo { display: flex; align-items: center; text-decoration: none; }

.logo img { height: 62px; width: auto; }

.main-nav ul { list-style: none; display: flex; align-items: center; gap: 4px; }

.main-nav a {
  position: relative;
  color: var(--navy);
  text-decoration: none;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 10px 14px;
  white-space: nowrap;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 4px;
  height: 2px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease-out);
}

.main-nav a:hover::after, .main-nav a.active::after { transform: scaleX(1); }

.main-nav a.nav-support {
  background: var(--red);
  color: #fff;
  border-radius: 3px;
  margin-left: 12px;
  padding: 11px 20px;
  transition: background 0.25s ease, transform 0.25s ease;
}

.main-nav a.nav-support::after { display: none; }

.main-nav a.nav-support:hover { background: var(--red-deep); transform: translateY(-1px); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid rgba(20, 47, 85, 0.3);
  border-radius: 4px;
  color: var(--navy);
  font-size: 1.25rem;
  line-height: 1;
  padding: 7px 13px;
  cursor: pointer;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  padding: 15px 32px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border-radius: 3px;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease,
    transform 0.25s ease, box-shadow 0.25s ease;
}

.btn:hover { transform: translateY(-2px); }

.btn-red {
  background: var(--red);
  color: #fff;
  border: 2px solid var(--red);
}

.btn-red:hover { background: var(--red-deep); border-color: var(--red-deep); box-shadow: 0 12px 28px rgba(191, 58, 63, 0.35); }

.btn-outline-light {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.55);
}

.btn-outline-light:hover { border-color: #fff; }

.btn-navy {
  background: var(--navy);
  color: #fff;
  border: 2px solid var(--navy);
}

.btn-navy:hover { background: var(--navy-mid); border-color: var(--navy-mid); box-shadow: 0 12px 28px rgba(20, 47, 85, 0.3); }

.btn-outline-navy {
  background: transparent;
  color: var(--navy);
  border: 2px solid var(--navy);
}

.btn-outline-navy:hover { background: var(--navy); color: #fff; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: min(88vh, 860px);
  display: flex;
  align-items: center;
  background: linear-gradient(158deg, var(--navy-deep) 0%, var(--navy) 62%, #17376a 100%);
  color: #fff;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(900px 600px at 35% 30%, #000 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(900px 600px at 35% 30%, #000 0%, transparent 75%);
  pointer-events: none;
}

/* drifting aurora glow */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
}

.aurora {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  will-change: transform;
  animation: auroraDrift 22s ease-in-out infinite alternate;
}

.aurora-1 {
  width: 700px; height: 700px;
  left: -12%; top: -30%;
  background: radial-gradient(circle, rgba(29, 65, 115, 0.9) 0%, transparent 65%);
}

.aurora-2 {
  width: 560px; height: 560px;
  left: 30%; bottom: -38%;
  background: radial-gradient(circle, rgba(191, 58, 63, 0.35) 0%, transparent 65%);
  animation-delay: -7s;
  animation-duration: 26s;
}

.aurora-3 {
  width: 480px; height: 480px;
  right: 6%; top: -22%;
  background: radial-gradient(circle, rgba(201, 168, 106, 0.22) 0%, transparent 65%);
  animation-delay: -14s;
  animation-duration: 30s;
}

@keyframes auroraDrift {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  50%  { transform: translate3d(60px, 40px, 0) scale(1.12); }
  100% { transform: translate3d(-40px, 70px, 0) scale(0.96); }
}

/* full-bleed portrait panel, blended into the navy */
.hero-photo-panel {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 46%;
  z-index: 3;
  opacity: 0;
  animation: heroPhotoIn 1.6s var(--ease-out) 0.25s forwards;
}

.hero-photo-panel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  mask-image: linear-gradient(to right, transparent 0%, #000 34%),
              linear-gradient(to top, transparent 0%, #000 26%);
  mask-composite: intersect;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 34%),
                      linear-gradient(to top, transparent 0%, #000 26%);
  -webkit-mask-composite: source-in;
  will-change: transform;
}

.hero-photo-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to right, var(--navy) 0%, rgba(20, 47, 85, 0.25) 45%, transparent 70%),
    linear-gradient(to top, rgba(11, 30, 58, 0.85) 0%, transparent 38%);
  pointer-events: none;
}

@keyframes heroPhotoIn {
  from { opacity: 0; transform: translateX(36px); }
  to   { opacity: 1; transform: none; }
}

.hero-content {
  position: relative;
  z-index: 4;
  padding: 110px 0 130px;
  max-width: none;
}

.hero-content > * { max-width: 58ch; }

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: #e8d9b0;
  margin-bottom: 26px;
}

.hero-kicker::before {
  content: "";
  width: 34px;
  height: 1px;
  background: var(--red);
}

.hero h1 {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(3.2rem, 7vw, 5.6rem);
  line-height: 1.0;
  letter-spacing: 0.01em;
  margin-bottom: 24px;
}

.hero h1 .accent {
  font-style: italic;
  font-weight: 500;
  color: #e79396;
  display: block;
  font-size: 0.4em;
  letter-spacing: 0.06em;
  margin-bottom: 10px;
}

.hero h1 .title-rule {
  display: block;
  width: 120px;
  height: 3px;
  margin-top: 26px;
  background: linear-gradient(90deg, var(--red), var(--gold));
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left;
  animation: ruleGrow 1s var(--ease-out) 0.9s forwards;
}

@keyframes ruleGrow { to { transform: scaleX(1); } }

@media (prefers-reduced-motion: reduce) {
  .hero h1 .title-rule { transform: none; animation: none; }
  .aurora { animation: none; }
  .hero-photo-panel { animation: none; opacity: 1; }
}

.hero-roles {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 0;
  align-items: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.22rem;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 24px;
}

.hero-roles span { white-space: nowrap; }

.hero-roles .dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--red);
  margin: 0 16px;
}

.hero p.hero-intro {
  font-size: 1.02rem;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.78);
  margin-bottom: 38px;
  max-width: 56ch;
}

.hero-buttons { display: flex; gap: 16px; flex-wrap: wrap; }

/* hero load-in stagger */
.hero .stagger {
  opacity: 0;
  transform: translateY(26px);
  animation: heroUp 1s var(--ease-out) forwards;
}

.hero .stagger:nth-child(1) { animation-delay: 0.1s; }
.hero .stagger:nth-child(2) { animation-delay: 0.22s; }
.hero .stagger:nth-child(3) { animation-delay: 0.34s; }
.hero .stagger:nth-child(4) { animation-delay: 0.46s; }
.hero .stagger:nth-child(5) { animation-delay: 0.58s; }

@keyframes heroUp {
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .hero .stagger { animation: none; opacity: 1; transform: none; }
}

.hero-badge {
  position: absolute;
  right: 5%;
  bottom: 9%;
  z-index: 5;
  background: rgba(250, 247, 241, 0.94);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--navy);
  border-left: 4px solid var(--red);
  border-radius: 4px;
  box-shadow: var(--shadow-md);
  padding: 16px 22px;
  max-width: 280px;
  opacity: 0;
  animation: badgeIn 1s var(--ease-out) 1.1s forwards,
             badgeFloat 6s ease-in-out 2.2s infinite;
}

@keyframes badgeIn {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: none; }
}

@keyframes badgeFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-badge { animation: none; opacity: 1; }
}

/* scroll cue */
.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  z-index: 5;
  width: 26px;
  height: 44px;
  border: 1.5px solid rgba(255, 255, 255, 0.45);
  border-radius: 14px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
  opacity: 0;
  animation: heroUp 1s var(--ease-out) 1.4s forwards;
  transition: border-color 0.25s ease;
}

.scroll-cue:hover { border-color: rgba(255, 255, 255, 0.85); }

.scroll-cue-line {
  width: 2px;
  height: 10px;
  border-radius: 2px;
  background: #e79396;
  animation: cueDrop 1.8s ease-in-out 2s infinite;
}

@keyframes cueDrop {
  0%   { transform: translateY(0); opacity: 1; }
  70%  { transform: translateY(14px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .scroll-cue { animation: none; opacity: 1; }
  .scroll-cue-line { animation: none; }
}

.hero-badge .badge-top {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 4px;
}

.hero-badge .badge-main {
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
}

/* ---------- Stats band ---------- */

.stats-band {
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 44px 0;
}

.stat {
  text-align: center;
  padding: 10px 20px;
  border-right: 1px solid var(--rule);
}

.stat:last-child { border-right: none; }

.stat .stat-num {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(2.2rem, 4vw, 3rem);
  color: var(--navy);
  line-height: 1.1;
}

.stat .stat-num .unit { color: var(--red); font-size: 0.55em; font-style: italic; }

.stat .stat-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 6px;
}

/* ---------- Section basics ---------- */

.section { padding: 96px 0; }

.section-alt { background: var(--paper); }

.section-navy {
  background:
    radial-gradient(900px 500px at 90% 0%, rgba(29, 65, 115, 0.8) 0%, transparent 60%),
    linear-gradient(160deg, var(--navy-deep) 0%, var(--navy) 80%);
  color: #fff;
}

.section-head { max-width: 760px; margin-bottom: 24px; }

.section-head.center { margin-inline: auto; text-align: center; }

.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 14px;
}

.section-kicker::before { content: ""; width: 30px; height: 1px; background: var(--red); }

.section-head.center .section-kicker::after { content: ""; width: 30px; height: 1px; background: var(--red); }

.section-navy .section-kicker { color: #e79396; }

.section-title {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(2rem, 3.8vw, 2.9rem);
  color: var(--navy);
  line-height: 1.12;
  margin-bottom: 18px;
}

.section-navy .section-title { color: #fff; }

.section-lead { color: var(--ink-soft); }

.section-navy .section-lead { color: rgba(255, 255, 255, 0.78); }

/* ---------- Timeline ---------- */

.timeline {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin-top: 64px;
  position: relative;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 2%;
  right: 2%;
  height: 2px;
  background: linear-gradient(90deg, var(--red) 0%, var(--navy) 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 1.4s var(--ease-out) 0.2s;
}

.timeline.in::before { transform: scaleX(1); }

@media (prefers-reduced-motion: reduce) {
  .timeline::before { transform: none; transition: none; }
}

.timeline-item {
  position: relative;
  padding: 40px 18px 0;
  text-align: center;
}

.timeline-item::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--cream);
  border: 3px solid var(--red);
  box-shadow: 0 0 0 5px var(--cream);
}

.timeline-year {
  font-family: var(--serif);
  font-weight: 800;
  font-size: 1.3rem;
  color: var(--navy);
  margin-bottom: 8px;
}

.timeline-item p { font-size: 0.9rem; color: var(--ink-soft); }

/* ---------- Office tiles ---------- */

.tiles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-top: 56px;
}

.tile {
  position: relative;
  background: linear-gradient(168deg, var(--navy-mid) 0%, var(--navy-deep) 90%);
  color: #fff;
  min-height: 250px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 28px 24px;
  border-radius: 6px;
  overflow: hidden;
  text-decoration: none;
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}

.tile::before {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 4px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease-out);
}

.tile:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }

.tile:hover::before { transform: scaleX(1); }

.tile .tile-num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.95rem;
  color: var(--gold);
  margin-bottom: auto;
}

.tile h3 {
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.3rem;
  line-height: 1.25;
}

.tile p { font-size: 0.86rem; color: rgba(255, 255, 255, 0.72); margin-top: 10px; }

.tiles-note { margin-top: 34px; max-width: 76ch; color: var(--ink-soft); font-size: 0.95rem; }

/* ---------- Operations cards ---------- */

.ops-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-top: 54px;
}

.ops-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 6px;
  padding: 30px 24px;
  transition: transform 0.35s var(--ease-out), background 0.35s ease, border-color 0.35s ease;
}

.ops-card:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(231, 147, 150, 0.5);
}

.ops-card .ops-icon {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(231, 147, 150, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  color: #e79396;
}

.ops-card .ops-icon svg { width: 20px; height: 20px; }

.ops-card h3 {
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 10px;
  color: #fff;
}

.ops-card p { font-size: 0.88rem; color: rgba(255, 255, 255, 0.72); }

.ops-footnote {
  margin-top: 30px;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.55);
  font-style: italic;
}

/* Light variant */
.ops-card.light {
  background: var(--paper);
  border: 1px solid var(--rule);
}

.ops-card.light:hover { border-color: rgba(191, 58, 63, 0.45); }

.ops-card.light .ops-icon { border-color: rgba(191, 58, 63, 0.5); color: var(--red); }

.ops-card.light h3 { color: var(--navy); }

.ops-card.light p { color: var(--ink-soft); }

.ops-footnote.light { color: var(--ink-soft); }

/* ---------- Split / community ---------- */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
  align-items: center;
}

.photo-frame {
  position: relative;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.photo-frame img { width: 100%; height: auto; }

.photo-frame-offset { position: relative; }

.photo-frame-offset::before {
  content: "";
  position: absolute;
  inset: 24px -24px -24px 24px;
  border: 1px solid rgba(191, 58, 63, 0.35);
  border-radius: 6px;
  pointer-events: none;
}

.community-list { list-style: none; margin-top: 26px; }

.community-list li {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--rule);
}

.community-list li::before {
  content: "★";
  color: var(--red);
  font-size: 0.8rem;
  flex-shrink: 0;
}

.community-list li strong { color: var(--navy); }

/* ---------- Page banner (interior) ---------- */

.page-banner {
  position: relative;
  background:
    radial-gradient(900px 420px at 85% -20%, rgba(29, 65, 115, 0.8) 0%, transparent 60%),
    linear-gradient(158deg, var(--navy-deep) 0%, var(--navy) 85%);
  color: #fff;
  padding: 84px 0 72px;
  overflow: hidden;
}

.page-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(800px 400px at 75% 20%, #000 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(800px 400px at 75% 20%, #000 0%, transparent 75%);
}

.page-banner .container { position: relative; }

.page-banner .section-kicker { color: #e79396; }

.page-banner h1 {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(2.4rem, 4.6vw, 3.6rem);
  line-height: 1.08;
  max-width: 20ch;
}

.page-banner p.banner-sub {
  margin-top: 18px;
  max-width: 62ch;
  color: rgba(255, 255, 255, 0.78);
  font-weight: 300;
}

/* ---------- Prose / bio ---------- */

.prose { max-width: 72ch; }

.prose h2 {
  font-family: var(--serif);
  font-weight: 800;
  font-size: 1.75rem;
  color: var(--navy);
  margin: 54px 0 18px;
  line-height: 1.2;
}

.prose h2:first-child { margin-top: 0; }

.prose h2 .num {
  font-style: italic;
  font-weight: 500;
  color: var(--red);
  font-size: 0.75em;
  margin-right: 10px;
}

.prose p { margin-bottom: 18px; }

.prose .fact-note {
  font-size: 0.92rem;
  color: var(--ink-soft);
  border-left: 3px solid var(--red);
  padding: 14px 20px;
  background: var(--paper);
  border-radius: 0 4px 4px 0;
  margin: 26px 0;
}

.bio-layout {
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: 70px;
  align-items: start;
}

.bio-side { position: sticky; top: 110px; }

.bio-side .photo-frame { margin-bottom: 22px; }

.side-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--red);
  border-radius: 6px;
  padding: 26px;
}

.side-card h3 {
  font-family: var(--serif);
  font-weight: 700;
  color: var(--navy);
  font-size: 1.1rem;
  margin-bottom: 12px;
}

.side-card ul { list-style: none; }

.side-card li {
  font-size: 0.9rem;
  padding: 10px 0;
  border-bottom: 1px solid var(--rule);
  color: var(--ink-soft);
}

.side-card li:last-child { border-bottom: none; }

.side-card li strong { color: var(--navy); display: block; font-size: 0.95rem; }

/* ---------- Record page cases ---------- */

.case-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 50px;
}

.case-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 6px;
  padding: 28px 24px;
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}

.case-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }

.case-card .case-tag {
  display: inline-block;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--red);
  border: 1px solid rgba(191, 58, 63, 0.4);
  border-radius: 100px;
  padding: 4px 12px;
  margin-bottom: 16px;
}

.case-card h3 {
  font-family: var(--serif);
  font-weight: 700;
  color: var(--navy);
  font-size: 1.15rem;
  margin-bottom: 8px;
}

.case-card p { font-size: 0.9rem; color: var(--ink-soft); }

/* ---------- Letter page ---------- */

.letter-wrap { max-width: 780px; margin: 0 auto; }

.letter-photo {
  border-radius: 6px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  margin: 0 auto 46px;
  max-width: 420px;
}

.letter-paper {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 4px;
  box-shadow: var(--shadow-md);
  padding: clamp(34px, 6vw, 76px);
}

.letter-paper::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--red), var(--navy));
  border-radius: 4px 4px 0 0;
}

.letter-paper .salutation {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 26px;
}

.letter-paper p { margin-bottom: 20px; }

.letter-placeholder {
  border: 2px dashed rgba(191, 58, 63, 0.5);
  background: var(--cream);
  border-radius: 4px;
  padding: 38px 30px;
  text-align: center;
  color: var(--ink-soft);
  font-size: 0.94rem;
  margin: 12px 0 28px;
}

.signature-block { margin-top: 48px; }

.signature-image {
  width: 280px;
  max-width: 70%;
  height: auto;
  margin-bottom: 14px;
}

.signature-block .sig-name {
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--navy);
}

.signature-block .sig-title {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 4px;
}

.letter-nav {
  display: flex;
  gap: 16px;
  justify-content: center;
  margin-top: 52px;
  flex-wrap: wrap;
}

/* ---------- Support page ---------- */

.support-layout {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 70px;
  align-items: start;
}

.donate-card {
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 6px;
  box-shadow: var(--shadow-md);
  padding: 44px;
  position: relative;
  overflow: hidden;
}

.donate-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--red), var(--navy));
}

.donate-card h2 {
  font-family: var(--serif);
  font-weight: 800;
  color: var(--navy);
  font-size: 1.7rem;
  margin-bottom: 12px;
}

.embed-placeholder {
  border: 2px dashed rgba(191, 58, 63, 0.5);
  background: var(--cream);
  border-radius: 4px;
  padding: 50px 30px;
  text-align: center;
  color: var(--ink-soft);
  font-size: 0.94rem;
  margin: 28px 0;
}

.disclosure {
  font-size: 0.76rem;
  color: var(--ink-soft);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 16px;
  text-align: center;
  margin-top: 28px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ---------- CTA band ---------- */

.cta-band {
  position: relative;
  background: linear-gradient(120deg, var(--red-deep) 0%, var(--red) 100%);
  color: #fff;
  padding: 72px 0;
  overflow: hidden;
}

.cta-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
}

.cta-band .container {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  flex-wrap: wrap;
}

.cta-band h2 {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(1.6rem, 3.2vw, 2.3rem);
  line-height: 1.2;
}

.cta-band p { color: rgba(255, 255, 255, 0.85); margin-top: 6px; }

.cta-band .btn {
  background: #fff;
  color: var(--red-deep);
  border: 2px solid #fff;
}

.cta-band .btn:hover { background: var(--cream); box-shadow: 0 12px 28px rgba(0, 0, 0, 0.2); }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--navy-deep);
  color: rgba(255, 255, 255, 0.7);
  padding: 60px 0 36px;
  font-size: 0.9rem;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.footer-logo .logo-name {
  font-family: var(--serif);
  font-weight: 800;
  font-size: 1.5rem;
  color: #fff;
  display: block;
  line-height: 1.2;
}

.footer-logo .logo-name .tom { font-style: italic; font-weight: 500; color: #e79396; font-size: 0.7em; margin-right: 6px; }

.footer-logo .logo-title {
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.footer-nav ul { list-style: none; display: flex; gap: 26px; flex-wrap: wrap; }

.footer-nav a {
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transition: color 0.25s ease;
}

.footer-nav a:hover { color: #e79396; }

.footer-legal {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 24px;
  text-align: center;
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.45);
}

/* ---------- Responsive ---------- */

@media (max-width: 980px) {
  /* side-entrance reveals become vertical so nothing overhangs the viewport */
  .reveal-left, .reveal-right { transform: translateY(34px); }
  .reveal-left.in, .reveal-right.in { transform: none; }

  .split, .bio-layout, .support-layout {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .hero {
    display: flex;
    flex-direction: column;
    min-height: 0;
  }

  .hero-content { order: 1; padding: 72px 0 44px; }

  .hero-photo-panel {
    position: relative;
    order: 2;
    width: 100%;
    height: min(72vw, 620px);
    animation-name: heroUp;
  }

  .hero-photo-panel img {
    mask-image: linear-gradient(to bottom, transparent 0%, #000 22%);
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 22%);
    object-position: center 22%;
    transform: none !important;
  }

  .hero-photo-panel::after {
    background: linear-gradient(to top, rgba(11, 30, 58, 0.7) 0%, transparent 40%);
  }

  .hero-badge { right: auto; left: 4.5%; bottom: 5%; }

  .scroll-cue { display: none; }

  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 20px 0; }

  .stat:nth-child(2) { border-right: none; }

  .timeline { grid-template-columns: 1fr; margin-top: 44px; }

  .timeline::before {
    top: 1%;
    bottom: 4%;
    left: 7px;
    right: auto;
    width: 2px;
    height: auto;
    background: linear-gradient(180deg, var(--red) 0%, var(--navy) 100%);
    transform: scaleY(0);
    transform-origin: top;
  }

  .timeline.in::before { transform: scaleY(1); }

  .timeline-item { text-align: left; padding: 0 0 38px 42px; }

  .timeline-item::before { left: 0; top: 5px; transform: none; }

  .tiles, .ops-grid { grid-template-columns: repeat(2, 1fr); }

  .case-grid { grid-template-columns: repeat(2, 1fr); }

  .bio-side { position: static; }
}

@media (max-width: 960px) {
  .nav-toggle { display: block; }

  .main-nav { display: none; width: 100%; }

  .main-nav.open { display: block; }

  .main-nav ul { flex-direction: column; align-items: stretch; gap: 0; padding-bottom: 16px; }

  .main-nav a { display: block; padding: 13px 4px; }

  .main-nav a::after { display: none; }

  .main-nav a.nav-support { margin-left: 0; text-align: center; margin-top: 8px; }

  .header-inner { flex-wrap: wrap; }
}

@media (max-width: 700px) {
  .logo img { height: 52px; }

  .section { padding: 72px 0; }

  /* the offset accent frame pokes past the viewport on small screens */
  .photo-frame-offset::before { display: none; }

  .tiles, .ops-grid, .case-grid { grid-template-columns: 1fr; }

  .tile { min-height: 180px; }

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

  .stat { border-right: none; }

  .hero-photo-panel { height: 400px; }
}
