/* Adapted from the approved model site's editorial civic styling, but mapped
   onto the DB-backed PHP homepage shell so the live county content can render
   with the same lighter desktop/tablet/mobile visual system. */
:root {
  --navy-950: #070d17;
  --navy-900: #0d1b2f;
  --navy-800: #142c4a;
  --navy-700: #1b3d65;
  --navy-600: #234e80;
  --navy-500: #2c5f9a;
  --navy-400: #4a7db8;
  --navy-300: #7aa3d1;
  --navy-200: #a9c5e3;
  --navy-100: #d4e2f1;
  --navy-50: #eef3f9;
  --gold-700: #8a6a2f;
  --gold-600: #a47d38;
  --gold-500: #c4973b;
  --gold-400: #d4ab54;
  --gold-300: #e0c07a;
  --gold-200: #ebd5a5;
  --gold-100: #f5ebd0;
  --parchment: #f8f5ef;
  --parchment-warm: #f3ede3;
  --stone-100: #e8e3da;
  --stone-200: #d4cfc5;
  --stone-300: #b8b3a8;
  --stone-400: #9c978c;
  --stone-500: #807b70;
  --red-600: #c53030;
  --red-50: #fef2f2;
  --green-600: #2d7a3a;
  --green-50: #f0fdf4;
  --amber-600: #b45309;
  --amber-50: #fffbeb;
  --shadow-sm: 0 1px 2px rgba(13, 27, 47, 0.06);
  --shadow-md: 0 4px 12px rgba(13, 27, 47, 0.08);
  --shadow-lg: 0 8px 30px rgba(13, 27, 47, 0.1);
  --shadow-xl: 0 20px 50px rgba(13, 27, 47, 0.12);
  --shadow-gold: 0 4px 20px rgba(196, 151, 59, 0.15);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --container-max: 1280px;
  --header-height: 80px;
}

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

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

body.modern-homepage-body {
  margin: 0;
  font-family: "Outfit", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.65;
  color: var(--navy-900);
  background: var(--parchment);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.gold-ribbon {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1001;
  height: 4px;
  background: linear-gradient(90deg, var(--gold-700), var(--gold-400), var(--gold-700));
}

.modern-container {
  width: min(var(--container-max), calc(100% - 48px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 4px;
  z-index: 1000;
  height: var(--header-height);
  background: rgba(13, 27, 47, 0.97);
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.18);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 100%;
  width: min(var(--container-max), calc(100% - 48px));
  margin: 0 auto;
}

.site-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.site-brand-icon {
  width: 78px;
  height: 78px;
  flex-shrink: 0;
  object-fit: contain;
}

.site-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.site-brand-name {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.25rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: -0.01em;
}

.site-brand-sub {
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--gold-300);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.nav-link {
  position: relative;
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--navy-200);
  transition: color 150ms ease, background 150ms ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.nav-link.is-active::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 16px;
  height: 2px;
  border-radius: 1px;
  background: var(--gold-400);
}

.nav-cta {
  margin-left: 8px;
  border-radius: var(--radius-sm);
  padding: 8px 20px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--navy-900);
  background: linear-gradient(135deg, var(--gold-400), var(--gold-500));
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.nav-cta:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-gold);
}

.nav-toggle {
  display: none;
  border: 0;
  background: transparent;
  padding: 8px;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  margin: 5px 0;
  background: #fff;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: calc(var(--header-height) + 44px) 0 72px;
  background: linear-gradient(170deg, var(--navy-900) 0%, var(--navy-800) 40%, var(--navy-700) 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='600' viewBox='0 0 600 600'%3E%3Cpath d='M300 60c130 0 240 110 240 240S430 540 300 540 60 430 60 300 170 60 300 60z' fill='none' stroke='%23c4973b' stroke-width='0.5'/%3E%3Cpath d='M300 100c110 0 200 90 200 200S410 500 300 500 100 410 100 300 190 100 300 100z' fill='none' stroke='%23c4973b' stroke-width='0.5'/%3E%3Cpath d='M300 140c88 0 160 72 160 160s-72 160-160 160-160-72-160-160 72-160 160-160z' fill='none' stroke='%23c4973b' stroke-width='0.5'/%3E%3Cpath d='M300 180c66 0 120 54 120 120s-54 120-120 120-120-54-120-120 54-120 120-120z' fill='none' stroke='%23c4973b' stroke-width='0.5'/%3E%3Cpath d='M300 220c44 0 80 36 80 80s-36 80-80 80-80-36-80-80 36-80 80-80z' fill='none' stroke='%23c4973b' stroke-width='0.5'/%3E%3C/svg%3E");
  background-position: center;
  background-size: 600px 600px;
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 120px;
  background: linear-gradient(to top, var(--parchment), transparent);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.hero-label,
.modern-section-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--gold-300);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.hero-label::before,
.modern-section-label::before {
  content: "";
  width: 24px;
  height: 1px;
  background: var(--gold-500);
}

.hero h1 {
  margin: 16px 0 18px;
  color: #fff;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(2.8rem, 5vw, 3.75rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.hero h1 em {
  color: var(--gold-300);
  font-style: italic;
}

.hero-description {
  max-width: 480px;
  margin-bottom: 26px;
  color: var(--navy-200);
  font-size: 1.125rem;
  line-height: 1.7;
}

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

.modern-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius-sm);
  padding: 14px 24px;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.4;
  transition: all 300ms ease;
}

.modern-btn-primary {
  color: var(--navy-900);
  background: linear-gradient(135deg, var(--gold-400), var(--gold-600));
  box-shadow: 0 2px 8px rgba(196, 151, 59, 0.3);
}

.modern-btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(196, 151, 59, 0.4);
}

.modern-btn-secondary {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: transparent;
}

.modern-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.4);
}

.modern-btn-outline {
  color: var(--navy-700);
  border: 1px solid var(--stone-200);
  background: transparent;
}

.modern-btn-outline:hover {
  color: var(--navy-900);
  border-color: var(--navy-400);
  background: var(--navy-50);
}

.hero-quick-links {
  position: relative;
  z-index: 1;
}

.quick-links-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.quick-link-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.06);
  transition: all 300ms ease;
}

.quick-link-card:hover {
  transform: translateY(-2px);
  border-color: var(--gold-500);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.quick-link-icon,
.modern-dept-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.quick-link-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
  font-size: 1.125rem;
}

.quick-link-text h4 {
  margin: 0 0 2px;
  color: #fff;
  font-family: "Outfit", sans-serif;
  font-size: 0.875rem;
  font-weight: 600;
}

.quick-link-text p {
  margin: 0;
  color: var(--navy-300);
  font-size: 0.75rem;
  line-height: 1.4;
}

.modern-section {
  padding: 80px 0;
  background: var(--parchment);
}

.modern-section-alt {
  background: #fff;
}

.modern-section-dark {
  position: relative;
  overflow: hidden;
  background: var(--navy-900);
  color: #fff;
}

.modern-section-dark::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='400' height='400' viewBox='0 0 400 400'%3E%3Cpath d='M200 50c80 0 150 70 150 150s-70 150-150 150S50 280 50 200 120 50 200 50z' fill='none' stroke='%231b3d65' stroke-width='1'/%3E%3Cpath d='M200 80c66 0 120 54 120 120s-54 120-120 120S80 266 80 200 134 80 200 80z' fill='none' stroke='%231b3d65' stroke-width='1'/%3E%3Cpath d='M200 110c50 0 90 40 90 90s-40 90-90 90-90-40-90-90 40-90 90-90z' fill='none' stroke='%231b3d65' stroke-width='1'/%3E%3Cpath d='M200 140c33 0 60 27 60 60s-27 60-60 60-60-27-60-60 27-60 60-60z' fill='none' stroke='%231b3d65' stroke-width='1'/%3E%3C/svg%3E");
  background-size: 400px 400px;
  pointer-events: none;
}

.modern-section-dark > .modern-container {
  position: relative;
  z-index: 1;
}

.modern-section-notice {
  background: var(--parchment);
  padding-top: 72px;
  padding-bottom: 40px;
}

.modern-section-header {
  margin-bottom: 48px;
}

.modern-section-header-split {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.modern-section-header-center {
  text-align: center;
}

.modern-section-header-center .modern-section-label {
  justify-content: center;
}

.modern-section-header h2 {
  margin: 12px 0 16px;
  color: var(--navy-900);
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(2.25rem, 4vw, 3rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.015em;
}

.modern-section-header p {
  max-width: 600px;
  margin: 0;
  color: var(--stone-500);
  font-size: 1.125rem;
}

.modern-section-dark .modern-section-label {
  color: var(--gold-300);
}

.modern-section-dark .modern-section-header h2,
.modern-section-dark .modern-section-header p,
.modern-section-dark .modern-empty-state {
  color: #fff;
}

.modern-section-dark .modern-section-header p {
  color: var(--navy-200);
}

.modern-notice-banner {
  display: block;
  padding: 20px 24px;
  border: 1px solid var(--gold-200);
  border-left: 4px solid var(--gold-500);
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--amber-50), #fff);
}

.modern-notice-banner h4 {
  margin: 0 0 4px;
  color: var(--navy-900);
  font-family: "Outfit", sans-serif;
  font-size: 1rem;
  font-weight: 600;
}

.modern-notice-banner p {
  margin: 0;
  color: var(--stone-500);
  font-size: 0.875rem;
}

.modern-notice-meta {
  margin-top: 8px;
  color: var(--stone-400);
  font-size: 0.75rem;
}

.modern-road-summary {
  padding: 24px;
  border: 1px solid var(--stone-100);
  border-radius: var(--radius-md);
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.modern-road-summary p,
.modern-empty-state {
  margin: 0;
  color: var(--stone-500);
  font-size: 0.95rem;
  line-height: 1.6;
}

.modern-road-list {
  margin: 16px 0 0;
  padding-left: 18px;
  color: var(--navy-900);
}

.modern-road-list li + li {
  margin-top: 8px;
}

.modern-road-actions {
  margin-top: 20px;
}

.modern-news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 24px;
}

.modern-news-card {
  overflow: hidden;
  border: 1px solid var(--stone-100);
  border-radius: var(--radius-lg);
  background: #fff;
  transition: all 300ms ease;
}

.modern-news-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.modern-news-card-body {
  padding: 24px;
}

.modern-news-card-dept {
  display: inline-block;
  margin-bottom: 12px;
  padding: 2px 12px;
  border-radius: 100px;
  background: var(--navy-50);
  color: var(--navy-600);
  font-size: 0.75rem;
  font-weight: 600;
}

.modern-card-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
  color: var(--stone-400);
  font-size: 0.875rem;
}

.modern-news-card h3,
.modern-resource-card h3,
.modern-dept-copy h3,
.modern-event-copy h3 {
  margin: 0 0 12px;
  font-size: 1rem;
  font-family: "Outfit", sans-serif;
  font-weight: 600;
  line-height: 1.35;
}

.modern-news-card h3 a {
  color: var(--navy-900);
}

.modern-news-card h3 a:hover {
  color: var(--gold-600);
}

.modern-news-card p,
.modern-resource-card p,
.modern-dept-copy p,
.modern-event-copy p {
  margin: 0;
  color: var(--stone-500);
  font-size: 0.875rem;
  line-height: 1.6;
}

.modern-event-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modern-event-item {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 20px;
  align-items: start;
  padding: 20px;
  border: 1px solid var(--stone-100);
  border-radius: var(--radius-md);
  background: #fff;
  transition: all 300ms ease;
}

.modern-event-item:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--gold-200);
}

.modern-event-date {
  padding: 12px;
  border-radius: var(--radius-sm);
  background: var(--navy-900);
  color: var(--gold-300);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: center;
}

.modern-dept-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.modern-dept-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.04);
  transition: all 300ms ease;
}

.modern-dept-card:hover {
  transform: translateY(-2px);
  border-color: rgba(224, 192, 122, 0.26);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
}

.modern-dept-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(196, 151, 59, 0.2), rgba(196, 151, 59, 0.1));
  color: var(--gold-300);
  font-size: 1.25rem;
}

.modern-dept-copy h3 {
  color: #fff;
}

.modern-dept-copy p {
  color: var(--navy-300);
}

.modern-resource-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.modern-resource-card {
  padding: 28px;
  border: 1px solid var(--stone-100);
  border-radius: var(--radius-lg);
  background: #fff;
  transition: all 300ms ease;
}

.modern-resource-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--gold-200);
}

.site-footer {
  background: var(--navy-950);
  color: var(--navy-200);
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.site-footer-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 40px;
  padding: 56px 0 28px;
}

.site-footer-title {
  margin: 0 0 16px;
  color: #fff;
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.05rem;
  font-weight: 600;
}

.site-footer-copy {
  color: var(--navy-300);
  font-size: 0.9rem;
  line-height: 1.9;
}

.site-footer-heading {
  margin: 0 0 18px;
  color: var(--gold-300);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.site-footer-links {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.site-footer-links a {
  color: var(--navy-300);
  font-size: 0.9rem;
}

.site-footer-links a:hover {
  color: var(--gold-300);
}

.site-footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 0 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  color: var(--navy-400);
  font-size: 0.78rem;
}

@media (max-width: 1180px) {
  .main-nav {
    gap: 2px;
  }

  .nav-link {
    padding: 7px 10px;
    font-size: 0.82rem;
  }

  .hero-content {
    gap: 40px;
  }
}

@media (max-width: 960px) {
  .site-header {
    height: auto;
  }

  .header-inner {
    position: relative;
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
    padding: 14px 0;
  }

  .nav-toggle {
    display: inline-flex;
    position: absolute;
    top: 20px;
    right: 0;
    flex-direction: column;
  }

  .main-nav {
    display: none;
    width: 100%;
    padding-top: 4px;
    flex-direction: column;
    align-items: stretch;
  }

  .site-header.nav-open .main-nav {
    display: flex;
  }

  .hero {
    padding-top: 124px;
  }

  .hero-content,
  .modern-resource-grid,
  .site-footer-inner {
    grid-template-columns: 1fr;
  }

  .modern-section-header-split,
  .site-footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }

  .modern-dept-grid,
  .modern-news-grid,
  .quick-links-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 700px) {
  .modern-container {
    width: min(100% - 28px, var(--container-max));
  }

  .site-brand-icon {
    width: 54px;
    height: 54px;
  }

  .site-brand-name {
    font-size: 1.05rem;
  }

  .hero {
    padding-top: 106px;
    padding-bottom: 52px;
  }

  .hero h1 {
    font-size: 2.45rem;
  }

  .hero-description,
  .modern-section-header p {
    font-size: 1rem;
  }

  .hero-actions,
  .quick-links-grid,
  .modern-dept-grid,
  .modern-news-grid,
  .modern-resource-grid {
    grid-template-columns: 1fr;
  }

  .hero-actions {
    display: flex;
    flex-direction: column;
  }

  .modern-btn {
    width: 100%;
  }

  .modern-event-item {
    grid-template-columns: 1fr;
  }

  .modern-event-date {
    max-width: 160px;
  }
}
