/* ==========================================================
   Shidler for Sheriff — Big Horn County, Wyoming
   ========================================================== */

:root {
  /* Brand palette — patriotic blue & red */
  --color-navy: #14264A;        /* deep campaign navy */
  --color-navy-dark: #0B1A38;
  --color-navy-soft: #1E3563;
  --color-red: #B5252C;         /* campaign red */
  --color-red-dark: #8E1A20;
  --color-red-bright: #C8252D;
  --color-cream: #F8F5EE;       /* off-white background */
  --color-cream-2: #F1ECDE;
  --color-paper: #FFFFFF;
  --color-text: #1A1F2E;
  --color-text-muted: #5A5F6E;
  --color-text-faint: #8E92A0;
  --color-border: #DBD6C7;
  --color-gold: #C9A24A;        /* subtle accent for stars */

  /* Type */
  --font-display: 'Oswald', 'Arial Narrow', Impact, sans-serif;
  --font-body: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;

  --text-xs: 0.8125rem;
  --text-sm: 0.9375rem;
  --text-base: 1.0625rem;
  --text-lg: 1.25rem;
  --text-xl: 1.5rem;
  --text-2xl: clamp(1.875rem, 3.5vw, 2.5rem);
  --text-3xl: clamp(2.25rem, 5vw, 3.5rem);
  --text-hero: clamp(3rem, 9vw, 7rem);

  /* Spacing */
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  --container: 1200px;
  --container-narrow: 760px;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;

  --shadow-sm: 0 1px 3px rgba(20, 38, 74, 0.08);
  --shadow-md: 0 4px 16px rgba(20, 38, 74, 0.10);
  --shadow-lg: 0 18px 50px rgba(20, 38, 74, 0.18);
}

/* ==========================================================
   Base
   ========================================================== */

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

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a { color: var(--color-red); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--color-red-dark); }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.05;
  margin: 0 0 var(--space-4);
  color: var(--color-navy);
  text-transform: uppercase;
}

p { margin: 0 0 1em; }
strong { font-weight: 700; color: var(--color-navy); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 clamp(1.25rem, 4vw, 2.5rem);
}
.container-narrow { max-width: var(--container-narrow); }

.section {
  padding: clamp(4rem, 9vw, 7rem) 0;
}

.section-head {
  margin-bottom: var(--space-12);
  max-width: 760px;
}
.section-head-centered { margin-left: auto; margin-right: auto; text-align: center; }

.eyebrow {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-red);
  margin: 0 0 var(--space-3);
}
.section-head-centered .eyebrow::before,
.section-head-centered .eyebrow::after {
  content: '';
  display: inline-block;
  width: 28px;
  height: 1px;
  background: currentColor;
  vertical-align: middle;
  margin: 0 12px 4px;
}
.section-head:not(.section-head-centered) .eyebrow::after {
  content: '';
  display: inline-block;
  width: 36px;
  height: 1px;
  background: currentColor;
  vertical-align: middle;
  margin: 0 0 4px 12px;
}

h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-xl); }

/* ==========================================================
   Header / Nav
   ========================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 245, 238, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
}

.nav-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0.75rem clamp(1.25rem, 4vw, 2.5rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
}

.nav-logo img {
  height: 56px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  gap: clamp(1rem, 2.2vw, 2rem);
  align-items: center;
}
.nav-links a {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-sm);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-navy);
  padding: 0.5rem 0;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 2px;
  background: var(--color-red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s ease;
}
.nav-links a:hover { color: var(--color-navy); }
.nav-links a:hover::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  padding: 8px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-navy);
  margin: 5px 0;
  transition: transform .25s ease, opacity .2s ease;
}

/* ==========================================================
   Hero
   ========================================================== */

.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  isolation: isolate;
  text-align: center;
  color: #fff;
  padding: var(--space-20) var(--space-4);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('images/hero-vista.jpg');
  background-size: cover;
  background-position: center 38%;
  z-index: -2;
  transform: scale(1.02);
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(11, 26, 56, 0.55) 0%, rgba(11, 26, 56, 0.35) 40%, rgba(11, 26, 56, 0.78) 100%),
    linear-gradient(90deg, rgba(11, 26, 56, 0.45) 0%, rgba(11, 26, 56, 0.10) 50%, rgba(11, 26, 56, 0.45) 100%);
  z-index: -1;
}

.hero-content {
  max-width: 1000px;
  width: 100%;
}

.hero-eyebrow {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: #FFE9B8;
  margin: 0 0 var(--space-6);
  font-weight: 500;
}
.hero-eyebrow .star { color: var(--color-gold); margin: 0 .5rem; }
@media (max-width: 600px) {
  .hero-eyebrow {
    letter-spacing: 0.18em;
    font-size: 0.72rem;
    line-height: 1.6;
  }
  .hero-eyebrow .star { margin: 0 0.3rem; }
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  margin: 0;
  line-height: 0.9;
  text-shadow: 0 4px 28px rgba(0, 0, 0, 0.45);
  color: #fff;
}
.hero-title .hero-first {
  display: block;
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  letter-spacing: 0.18em;
  font-weight: 500;
  color: #FFE9B8;
  margin-bottom: 0.25rem;
}
.hero-title .hero-last {
  display: block;
  font-size: var(--text-hero);
  letter-spacing: 0.01em;
  color: #fff;
}
.hero-title .hero-for {
  display: inline-block;
  font-size: clamp(1.5rem, 3.2vw, 2.25rem);
  letter-spacing: 0.04em;
  background: var(--color-red);
  color: #fff;
  padding: 0.35em 1em;
  margin-top: var(--space-4);
  font-weight: 600;
  box-shadow: 0 4px 18px rgba(181, 37, 44, 0.45);
}

.hero-tagline {
  font-family: var(--font-display);
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin: var(--space-8) 0 var(--space-6);
  color: #fff;
  font-weight: 500;
}

.hero-meta {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1rem;
  font-family: var(--font-display);
  font-size: var(--text-sm);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #E8E6DF;
  font-weight: 400;
}
.hero-meta .dot { color: var(--color-gold); }

.hero-scroll {
  position: absolute;
  left: 50%;
  bottom: 1.5rem;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,0.85);
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  animation: hop 2.4s ease-in-out infinite;
}
@keyframes hop {
  0%, 100% { transform: translate(-50%, 0); opacity: 0.85; }
  50% { transform: translate(-50%, 6px); opacity: 1; }
}

/* ==========================================================
   About
   ========================================================== */

.section-about { background: var(--color-cream); }

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: start;
}

.about-photo {
  margin: 0;
  position: relative;
  isolation: isolate;
}
.about-photo img {
  width: 100%;
  border-radius: 4px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border);
}
.about-photo::before {
  content: '';
  position: absolute;
  inset: 18px -18px -18px 18px;
  background: var(--color-navy);
  border-radius: 4px;
  z-index: -1;
}
.about-photo::after {
  content: '';
  position: absolute;
  top: 18px; bottom: -18px; right: -18px;
  width: 12px;
  background: var(--color-red);
  border-radius: 0 4px 4px 0;
  z-index: -1;
}
.about-photo figcaption {
  margin-top: var(--space-6);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  font-style: italic;
  text-align: center;
}

.about-text p {
  font-size: var(--text-base);
  color: var(--color-text);
  margin-bottom: 1.15em;
}
.about-text p:first-of-type::first-letter {
  font-family: var(--font-display);
  font-size: 3.6em;
  line-height: 0.85;
  float: left;
  padding: 6px 12px 0 0;
  color: var(--color-red);
  font-weight: 700;
}

/* ==========================================================
   Image Dividers (full-bleed)
   ========================================================== */

.image-divider {
  position: relative;
  height: clamp(280px, 40vw, 460px);
  overflow: hidden;
}
.image-divider.divider-tall { height: clamp(380px, 55vw, 620px); }
.image-divider-inner {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}
.divider-rocky { background-image: url('images/rocky-outcrop.jpg'); }
.divider-prairie { background-image: url('images/open-prairie.jpg'); background-position: center 55%; }

.image-divider::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(11, 26, 56, 0.18), rgba(11, 26, 56, 0.45));
}

.divider-quote-wrap {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-8) clamp(1.25rem, 4vw, 3rem);
  text-align: center;
}
.divider-quote {
  font-family: var(--font-display);
  color: #fff;
  font-weight: 500;
  font-size: clamp(1.25rem, 2.5vw, 2rem);
  line-height: 1.25;
  letter-spacing: 0.01em;
  max-width: 880px;
  margin: 0;
  text-shadow: 0 4px 24px rgba(0,0,0,0.5);
  text-transform: uppercase;
}

/* ==========================================================
   Message / Pull Quote
   ========================================================== */

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

.message-body p {
  font-size: var(--text-lg);
  line-height: 1.7;
  color: var(--color-text);
  margin-bottom: 1.25em;
}

.pull-quote {
  margin: var(--space-16) 0 0;
  padding: var(--space-12) var(--space-8);
  border-top: 4px solid var(--color-red);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-cream);
  position: relative;
  text-align: center;
}
.pull-quote::before {
  content: '"';
  position: absolute;
  top: -28px;
  left: 50%;
  transform: translateX(-50%);
  width: 56px;
  height: 56px;
  background: var(--color-red);
  color: #fff;
  font-family: Georgia, serif;
  font-size: 3rem;
  line-height: 56px;
  border-radius: 50%;
}
.pull-quote p {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.4vw, 1.75rem);
  line-height: 1.35;
  color: var(--color-navy);
  font-weight: 500;
  letter-spacing: 0.01em;
  margin: 0 0 var(--space-6);
  font-style: normal;
}
.pull-quote footer {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-red);
  font-weight: 600;
}
.pull-quote .quote-dash { color: var(--color-text-faint); margin-right: 0.4em; }

/* ==========================================================
   Priorities
   ========================================================== */

.section-priorities {
  background: var(--color-navy);
  color: #E8E6DF;
  position: relative;
  overflow: hidden;
}
.section-priorities::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 15% 20%, rgba(255,255,255,0.04), transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(181, 37, 44, 0.10), transparent 40%);
  pointer-events: none;
}
.section-priorities .container { position: relative; }

.section-priorities h2 { color: #fff; }
.section-priorities .eyebrow { color: #FFB8BC; }
.section-priorities .eyebrow::before,
.section-priorities .eyebrow::after { background: #FFB8BC; }

.priorities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-6);
}
@media (min-width: 1100px) {
  .priorities-grid { grid-template-columns: repeat(4, 1fr); }
}

.priority-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.10);
  padding: var(--space-8);
  border-radius: var(--radius-md);
  transition: transform .25s ease, border-color .25s ease, background .25s ease;
}
.priority-card:hover {
  transform: translateY(-4px);
  border-color: var(--color-red-bright);
  background: rgba(255, 255, 255, 0.06);
}

.priority-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-red);
  color: #fff;
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-4);
}
.priority-icon svg { width: 26px; height: 26px; }

.priority-card h3 {
  color: #fff;
  font-size: var(--text-lg);
  margin-bottom: var(--space-3);
  letter-spacing: 0.02em;
}
.priority-card p {
  font-size: var(--text-sm);
  line-height: 1.65;
  color: #CFD1D9;
  margin: 0;
}

/* ==========================================================
   Key Dates
   ========================================================== */

.section-dates {
  background: var(--color-cream-2);
  position: relative;
}

.dates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-6);
  max-width: 760px;
  margin: 0 auto;
}

.date-card {
  background: var(--color-paper);
  border: 1px solid var(--color-border);
  border-top: 6px solid var(--color-navy);
  padding: var(--space-8) var(--space-6);
  text-align: center;
  border-radius: 4px;
  box-shadow: var(--shadow-sm);
}
.date-card-accent { border-top-color: var(--color-red); }

.date-label {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin: 0 0 var(--space-3);
  font-weight: 500;
}
.date-day {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.5vw, 2.75rem);
  font-weight: 700;
  color: var(--color-navy);
  margin: 0;
  line-height: 1;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}
.date-card-accent .date-day { color: var(--color-red); }
.date-year {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  color: var(--color-text-muted);
  margin: var(--space-2) 0 0;
  letter-spacing: 0.08em;
}

/* ==========================================================
   Gallery strip
   ========================================================== */

.gallery-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  background: var(--color-cream-2);
}
.gallery-item {
  aspect-ratio: 4 / 3;
  background-size: cover;
  background-position: center;
  filter: saturate(1.02);
}
.gallery-moose   { background-image: url('images/moose-hill.jpg'); background-position: center 35%; }
.gallery-rocky   { background-image: url('images/rocky-outcrop.jpg'); }
.gallery-prairie { background-image: url('images/open-prairie.jpg'); }

.gallery-caption-wrap {
  background: var(--color-cream-2);
  padding: var(--space-4) 0 var(--space-6);
}
.gallery-caption {
  text-align: center;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  font-style: italic;
  margin: 0 auto;
  max-width: var(--container);
  padding: 0 clamp(1.25rem, 4vw, 2.5rem);
}

/* ==========================================================
   Follow
   ========================================================== */

.section-follow {
  background: var(--color-cream);
  text-align: center;
}
.follow-sub {
  color: var(--color-text-muted);
  font-size: var(--text-base);
  max-width: 540px;
  margin: var(--space-4) auto 0;
}

.social-row {
  display: flex;
  gap: var(--space-4);
  justify-content: center;
  flex-wrap: wrap;
  margin-top: var(--space-8);
}

.social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.85rem 1.6rem;
  background: var(--color-navy);
  color: #fff;
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: var(--text-sm);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 500;
  transition: background .2s ease, transform .2s ease;
  border: 2px solid var(--color-navy);
}
.social-link:hover {
  background: var(--color-red);
  border-color: var(--color-red);
  color: #fff;
  transform: translateY(-2px);
}
.social-link svg { width: 20px; height: 20px; }

/* ==========================================================
   Footer
   ========================================================== */

.site-footer {
  background: var(--color-navy-dark);
  color: #C9CCD6;
  padding: var(--space-16) 0 var(--space-8);
  border-top: 6px solid var(--color-red);
}
.footer-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: var(--space-12);
  align-items: end;
}
.footer-brand img {
  background: #fff;
  padding: 8px 12px;
  border-radius: 4px;
  margin-bottom: var(--space-4);
  height: 70px;
  width: auto;
}
.footer-tag {
  font-family: var(--font-display);
  font-size: var(--text-base);
  letter-spacing: 0.04em;
  color: #fff;
  margin: 0 0 0.4em;
  font-weight: 500;
  text-transform: uppercase;
}
.footer-sub { color: #98A0B4; font-size: var(--text-sm); margin: 0; }

.footer-meta {
  text-align: right;
  font-size: var(--text-sm);
  color: #98A0B4;
}
.footer-meta p { margin: 0 0 0.4em; }
.footer-disclaimer { font-size: var(--text-xs); color: #6F7689; max-width: 320px; margin-left: auto; }

/* ==========================================================
   Responsive
   ========================================================== */

@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-cream);
    padding: var(--space-6);
    gap: var(--space-4);
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow-md);
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: var(--space-8);
  }
  .about-photo {
    max-width: 420px;
    margin: 0 auto;
  }
  .about-photo::before,
  .about-photo::after { display: none; }

  .footer-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .footer-meta { text-align: center; }
  .footer-disclaimer { margin: 0 auto; }
  .footer-brand img { margin-left: auto; margin-right: auto; }

  .gallery-strip { grid-template-columns: 1fr; }
  .gallery-item { aspect-ratio: 16/9; }
}

@media (max-width: 600px) {
  .hero { min-height: 88vh; }
  .hero-title .hero-for { font-size: 1.4rem; padding: 0.4em 0.9em; }
  .hero-meta { font-size: 0.78rem; letter-spacing: 0.1em; }
  .hero-meta .dot { display: none; }
  .hero-meta > span { width: 100%; text-align: center; }

  .pull-quote { padding: var(--space-8) var(--space-4); }

  .priority-card { padding: var(--space-6); }
  .nav-logo img { height: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
