/* ============================================================
   Glen T. Douglas for Lincoln County Mayor
   Classic patriotic theme — navy, cream, red
   Now with mobile menu, responsive layout, and scroll animations
   ============================================================ */

:root {
  --navy: #0a2342;
  --navy-light: #173a6b;
  --navy-dark: #061732;
  --red: #b1252e;
  --red-dark: #8a1c23;
  --cream: #faf6ef;
  --paper: #ffffff;
  --ink: #1a1a1a;
  --ink-soft: #4a4a4a;
  --gold: #c5a572;
  --rule: #d9d2c3;
  --shadow: 0 6px 18px rgba(10, 35, 66, 0.08);
  --header-height: 88px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: "Georgia", "Times New Roman", serif;
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  font-size: 17px;
  overflow-x: hidden;
}

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

a { color: var(--navy); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--red); }

/* ---------- Top stripe ---------- */
.flag-stripe {
  height: 6px;
  background:
    linear-gradient(to right,
      var(--navy) 0 33.33%,
      var(--paper) 33.33% 66.66%,
      var(--red) 66.66% 100%);
}

/* ---------- Header ---------- */
.site-header {
  background: var(--navy);
  color: var(--paper);
  padding: 1.25rem 1.5rem;
  border-bottom: 4px solid var(--red);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 12px rgba(0,0,0,0.15);
}

.header-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--paper);
  flex-shrink: 0;
}

.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--cream);
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Georgia", serif;
  font-weight: bold;
  font-size: 1.3rem;
  border: 3px solid var(--gold);
  flex-shrink: 0;
  letter-spacing: 1px;
}

.brand-text { line-height: 1.2; }
.brand-name { font-size: 1.15rem; font-weight: bold; letter-spacing: 0.5px; }
.brand-title { font-size: 0.85rem; color: #d8c79a; font-style: italic; }

/* ---------- Hamburger button (mobile only) ---------- */
.menu-toggle {
  display: none;
  background: transparent;
  border: 2px solid rgba(255,255,255,0.4);
  color: var(--paper);
  width: 44px;
  height: 44px;
  border-radius: 4px;
  cursor: pointer;
  padding: 0;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.menu-toggle:hover,
.menu-toggle:focus { background: rgba(255,255,255,0.08); border-color: var(--gold); outline: none; }

.menu-toggle .bars { display: block; width: 22px; height: 14px; position: relative; }
.menu-toggle .bars::before,
.menu-toggle .bars::after,
.menu-toggle .bars span {
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--paper);
  transition: transform 0.25s ease, top 0.25s ease, opacity 0.2s ease;
  border-radius: 2px;
}
.menu-toggle .bars::before { top: 0; }
.menu-toggle .bars span { top: 6px; }
.menu-toggle .bars::after  { top: 12px; }

/* X state when nav is open */
body.nav-open .menu-toggle .bars::before { top: 6px; transform: rotate(45deg); }
body.nav-open .menu-toggle .bars::after  { top: 6px; transform: rotate(-45deg); }
body.nav-open .menu-toggle .bars span    { opacity: 0; }

/* ---------- Nav ---------- */
.site-nav {
  display: flex;
  gap: 1.25rem;
  align-items: center;
  flex-wrap: wrap;
}

.site-nav a {
  color: var(--paper);
  text-decoration: none;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  padding: 0.4rem 0;
  border-bottom: 2px solid transparent;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: #ffd66e;
  border-bottom-color: var(--gold);
}

.site-nav .donate-btn {
  background: var(--red);
  border: 2px solid var(--red);
  border-radius: 4px;
  padding: 0.45rem 1rem;
  color: var(--paper);
}
.site-nav .donate-btn:hover {
  background: var(--paper);
  color: var(--red);
  border-color: var(--paper);
}

/* ---------- Mobile nav ---------- */
@media (max-width: 860px) {
  .site-header { padding: 0.85rem 1rem; }
  .brand-mark { width: 44px; height: 44px; font-size: 1.05rem; border-width: 2px; }
  .brand-name { font-size: 1rem; }
  .brand-title { font-size: 0.75rem; }

  .menu-toggle { display: inline-flex; }

  .site-nav {
    position: fixed;
    inset: 0;
    background: var(--navy-dark);
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    padding: calc(72px + 1rem) 1.5rem 2rem;
    z-index: 90;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(.4,.0,.2,1);
    overflow-y: auto;
  }

  body.nav-open { overflow: hidden; }
  body.nav-open .site-nav { transform: translateX(0); }

  .site-nav a {
    padding: 1.1rem 0.5rem;
    font-size: 1.05rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    text-align: left;
  }
  .site-nav a:last-child { border-bottom: 0; }
  .site-nav a:hover,
  .site-nav a.active { border-bottom-color: var(--gold); }

  .site-nav .donate-btn {
    margin-top: 1rem;
    text-align: center;
    border-radius: 4px;
    padding: 1rem;
    border: 2px solid var(--red);
  }
  .site-nav .donate-btn:hover { background: var(--paper); color: var(--red); border-color: var(--paper); }
}

/* ---------- Hero ---------- */
.hero {
  background:
    linear-gradient(rgba(10, 35, 66, 0.85), rgba(10, 35, 66, 0.85)),
    repeating-linear-gradient(135deg, #0a2342 0 40px, #102a52 40px 80px);
  color: var(--paper);
  padding: 4rem 1.5rem;
  border-bottom: 6px solid var(--red);
}

.hero-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 3rem;
  align-items: center;
}

.hero-text { text-align: left; }

.hero-portrait {
  background: var(--paper);
  padding: 0.6rem;
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow: 0 12px 30px rgba(0,0,0,0.4);
  border-radius: 4px;
}

.hero-portrait img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 2px;
}

.hero-eyebrow {
  font-family: "Helvetica Neue", Arial, sans-serif;
  text-transform: uppercase;
  letter-spacing: 4px;
  font-size: 0.85rem;
  color: var(--gold);
  margin-bottom: 1rem;
}

.hero-cta { display: flex; gap: 1rem; flex-wrap: wrap; }

.hero h1 {
  font-size: clamp(2rem, 6vw, 3.4rem);
  margin: 0 0 0.5rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  line-height: 1.15;
}

.hero h2 {
  font-size: clamp(1rem, 2.5vw, 1.5rem);
  font-weight: 400;
  font-style: italic;
  margin: 0 0 1.5rem;
  color: #e8d8b0;
  line-height: 1.35;
}

.hero-tagline {
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  margin: 0 0 2rem;
  font-style: italic;
  border-top: 1px solid rgba(197, 165, 114, 0.5);
  border-bottom: 1px solid rgba(197, 165, 114, 0.5);
  padding: 1rem 0;
}

@media (max-width: 860px) {
  .hero { padding: 2.5rem 1.25rem; }
  .hero-inner { grid-template-columns: 1fr; gap: 1.75rem; text-align: center; max-width: 480px; }
  .hero-text { text-align: center; }
  .hero-portrait { max-width: 240px; margin: 0 auto; }
  .hero-cta { justify-content: center; }
  .hero-tagline { font-size: 1rem; }
}

@media (max-width: 480px) {
  .hero { padding: 2rem 1rem; }
  .hero-portrait { max-width: 200px; }
  .hero-cta .btn { flex: 1 1 100%; text-align: center; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 0.85rem 1.75rem;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-size: 0.9rem;
  text-decoration: none;
  border-radius: 4px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease, transform 0.1s ease;
  -webkit-tap-highlight-color: transparent;
}

.btn:active { transform: scale(0.97); }

.btn-primary { background: var(--red); color: var(--paper); border-color: var(--red); }
.btn-primary:hover { background: var(--red-dark); border-color: var(--red-dark); color: var(--paper); }

.btn-outline { background: transparent; color: var(--paper); border-color: var(--paper); }
.btn-outline:hover { background: var(--paper); color: var(--navy); }

.btn-navy { background: var(--navy); color: var(--paper); border-color: var(--navy); }
.btn-navy:hover { background: var(--navy-dark); color: var(--paper); border-color: var(--navy-dark); }

/* ---------- Page header (interior pages) ---------- */
.page-header {
  background: var(--navy);
  color: var(--paper);
  padding: 3rem 1.5rem;
  text-align: center;
  border-bottom: 4px solid var(--red);
}

.page-header h1 { font-size: clamp(1.6rem, 4.5vw, 2.6rem); margin: 0 0 0.4rem; }
.page-header p { margin: 0; font-style: italic; color: #d8c79a; font-size: clamp(0.95rem, 2vw, 1.05rem); }

@media (max-width: 600px) {
  .page-header { padding: 2.25rem 1.25rem; }
}

/* ---------- Main containers ---------- */
main { padding: 3rem 1.5rem; }

.container { max-width: 1100px; margin: 0 auto; }
.container-narrow { max-width: 780px; margin: 0 auto; }

section { margin-bottom: 3rem; }

@media (max-width: 600px) {
  main { padding: 2rem 1.25rem; }
  section { margin-bottom: 2.25rem; }
}

h2.section-title {
  font-size: clamp(1.4rem, 3.5vw, 1.75rem);
  color: var(--navy);
  margin-top: 0;
  margin-bottom: 0.25rem;
  text-align: center;
  line-height: 1.2;
}

h2.section-title::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background: var(--red);
  margin: 0.6rem auto 1.5rem;
}

h3 { color: var(--navy); font-size: clamp(1.1rem, 2.5vw, 1.25rem); margin-bottom: 0.5rem; }

/* ---------- Cards ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.card {
  background: var(--paper);
  border-top: 4px solid var(--red);
  border-radius: 4px;
  padding: 1.75rem 1.5rem;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(10, 35, 66, 0.13);
}

.card h3 {
  margin-top: 0;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.card .icon {
  display: inline-block;
  width: 32px;
  height: 32px;
  background: var(--navy);
  color: var(--paper);
  border-radius: 50%;
  text-align: center;
  line-height: 32px;
  font-size: 0.95rem;
  font-weight: bold;
  flex-shrink: 0;
}

.card p { margin-bottom: 0; color: var(--ink-soft); }

@media (max-width: 600px) {
  .card-grid { grid-template-columns: 1fr; gap: 1rem; }
  .card { padding: 1.4rem 1.25rem; }
}

/* ---------- About page bio block ---------- */
.bio-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2.5rem;
  align-items: start;
}

.bio-photo {
  background: var(--paper);
  padding: 0.75rem;
  border: 1px solid var(--rule);
  box-shadow: var(--shadow);
  text-align: center;
}

.bio-photo img {
  width: 100%;
  height: auto;
  display: block;
}

.bio-photo .photo-placeholder {
  width: 100%;
  aspect-ratio: 4/5;
  background: linear-gradient(135deg, #173a6b, #0a2342);
  color: var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-weight: bold;
  letter-spacing: 2px;
  font-size: 0.85rem;
  text-align: center;
  padding: 1rem;
}

.bio-photo .caption {
  font-size: 0.85rem;
  font-style: italic;
  color: var(--ink-soft);
  margin-top: 0.6rem;
}

@media (max-width: 720px) {
  .bio-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .bio-photo { max-width: 280px; margin: 0 auto; }
}

/* ---------- Quote callout ---------- */
.pull-quote {
  background: var(--paper);
  border-left: 5px solid var(--red);
  padding: 1.5rem 1.75rem;
  margin: 2rem 0;
  font-style: italic;
  font-size: clamp(1rem, 2.5vw, 1.1rem);
  color: var(--navy);
  box-shadow: var(--shadow);
}

.pull-quote cite {
  display: block;
  margin-top: 0.75rem;
  font-style: normal;
  font-size: 0.9rem;
  color: var(--ink-soft);
  font-family: "Helvetica Neue", Arial, sans-serif;
  letter-spacing: 0.5px;
}

@media (max-width: 600px) {
  .pull-quote { padding: 1.25rem 1.25rem; }
}

/* ---------- Experience timeline ---------- */
.timeline {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
  position: relative;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--rule);
}

.timeline li {
  position: relative;
  padding-left: 2rem;
  margin-bottom: 1rem;
}

.timeline li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 18px;
  height: 18px;
  background: var(--red);
  border: 3px solid var(--paper);
  box-shadow: 0 0 0 2px var(--red);
  border-radius: 50%;
}

.timeline strong { color: var(--navy); }

/* ---------- News list ---------- */
.news-list { display: flex; flex-direction: column; gap: 1.5rem; }

.news-item {
  background: var(--paper);
  border: 1px solid var(--rule);
  padding: 1.5rem 1.75rem;
  border-radius: 4px;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.news-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(10, 35, 66, 0.12);
}

.news-item .news-meta {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--red);
  margin-bottom: 0.4rem;
}

.news-item h3 { margin: 0 0 0.5rem; font-size: clamp(1.05rem, 2.5vw, 1.2rem); }
.news-item p { margin: 0 0 0.75rem; color: var(--ink-soft); }

.news-item .read-more {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

@media (max-width: 600px) {
  .news-item { padding: 1.25rem 1.25rem; }
}

/* ---------- Contact / donate ---------- */
.split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 2rem;
}

@media (max-width: 720px) {
  .split-grid { grid-template-columns: 1fr; gap: 1.25rem; }
}

.panel {
  background: var(--paper);
  padding: 2rem;
  border-radius: 4px;
  border-top: 4px solid var(--navy);
  box-shadow: var(--shadow);
}

.panel.accent { border-top-color: var(--red); }

.panel h3 { margin-top: 0; }

.contact-list { list-style: none; padding: 0; margin: 1rem 0 0; }

.contact-list li {
  padding: 0.6rem 0;
  border-bottom: 1px dashed var(--rule);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.contact-list li:last-child { border-bottom: 0; }

.contact-list .label {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--ink-soft);
  min-width: 90px;
}

@media (max-width: 600px) {
  .panel { padding: 1.5rem 1.25rem; }
}

/* ---------- Vote banner ---------- */
.vote-banner {
  background: var(--red);
  color: var(--paper);
  padding: 2.5rem 1.5rem;
  text-align: center;
  margin: 3rem 0;
  border-radius: 4px;
  background-image: repeating-linear-gradient(45deg, rgba(255,255,255,0.04) 0 14px, transparent 14px 28px);
}

.vote-banner h2 { margin: 0 0 0.5rem; font-size: clamp(1.25rem, 3.5vw, 1.6rem); }
.vote-banner p { margin: 0 0 1.25rem; font-style: italic; font-size: clamp(0.95rem, 2vw, 1.05rem); }
.vote-banner .btn-outline { color: var(--paper); border-color: var(--paper); }
.vote-banner .btn-outline:hover { background: var(--paper); color: var(--red); }

@media (max-width: 600px) {
  .vote-banner { padding: 2rem 1.25rem; margin: 2rem 0; }
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy-dark);
  color: #cdd6e3;
  padding: 2.5rem 1.5rem 1.5rem;
  border-top: 4px solid var(--red);
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 2rem;
}

@media (max-width: 720px) {
  .footer-inner { grid-template-columns: 1fr; gap: 1.5rem; }
}

.footer-col h4 {
  color: var(--paper);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin: 0 0 0.75rem;
}

.footer-col a { color: #cdd6e3; text-decoration: none; }
.footer-col a:hover { color: #ffd66e; text-decoration: underline; }

.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { padding: 0.25rem 0; font-size: 0.95rem; }

.disclaimer {
  max-width: 1100px;
  margin: 1.5rem auto 0;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255,255,255,0.15);
  font-size: 0.8rem;
  color: #99a4b8;
  text-align: center;
  font-style: italic;
}

/* ---------- Utility ---------- */
.center { text-align: center; }
.lead { font-size: clamp(1rem, 2.4vw, 1.15rem); color: var(--ink-soft); }

/* ---------- Scroll animations ----------
   Elements get .reveal as a starting style; JS adds .is-visible
   when the element scrolls into view. Direction variants supported.
   Falls back to immediately visible if user prefers reduced motion. */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(.4,.0,.2,1), transform 0.7s cubic-bezier(.4,.0,.2,1);
  will-change: opacity, transform;
}

.reveal.from-left  { transform: translateX(-32px); }
.reveal.from-right { transform: translateX(32px); }
.reveal.zoom       { transform: scale(0.94); }

.reveal.is-visible {
  opacity: 1;
  transform: translate(0, 0) scale(1);
}

/* Stagger children when wrapped with .reveal-stagger */
.reveal-stagger > .reveal:nth-child(1) { transition-delay: 0s; }
.reveal-stagger > .reveal:nth-child(2) { transition-delay: 0.08s; }
.reveal-stagger > .reveal:nth-child(3) { transition-delay: 0.16s; }
.reveal-stagger > .reveal:nth-child(4) { transition-delay: 0.24s; }
.reveal-stagger > .reveal:nth-child(5) { transition-delay: 0.32s; }
.reveal-stagger > .reveal:nth-child(6) { transition-delay: 0.40s; }
.reveal-stagger > .reveal:nth-child(7) { transition-delay: 0.48s; }
.reveal-stagger > .reveal:nth-child(8) { transition-delay: 0.56s; }

/* Respect user motion preferences */
@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal.from-left, .reveal.from-right, .reveal.zoom {
    opacity: 1;
    transform: none;
    transition: none;
  }
  html { scroll-behavior: auto; }
}

/* ---------- Focus styles for accessibility ---------- */
a:focus-visible,
button:focus-visible,
.btn:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}
