/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --cream: #FAF8F0;
  --cream-dark: #EFEBE0;
  --green: #1E3A20;
  --green-mid: #2C4A2E;
  --green-light: #3A6040;
  --brown: #6B5340;
  --brown-light: #8B7355;
  --gold: #B8933A;
  --gold-muted: #C4A855;
  --text: #2A2A24;
  --text-light: #5A5A50;
  --white: #FEFDFB;
  --border: #D6D0C4;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Source Serif 4', Georgia, serif;
  background-color: var(--cream);
  color: var(--text);
  line-height: 1.75;
  font-size: clamp(16px, 1vw + 14px, 18px);
  font-kerning: normal;
  background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
}

h1, h2, h3, h4 {
  font-family: 'Playfair Display', 'Times New Roman', serif;
  color: var(--green);
  line-height: 1.2;
}

a { color: var(--green); text-decoration: none; transition: color 0.25s ease; }
a:hover { color: var(--gold); }

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

/* ===== LAYOUT ===== */
.container { max-width: 1100px; margin: 0 auto; padding: 0 clamp(20px, 4vw, 48px); }

/* ===== SCROLL REVEAL ===== */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== NAV ===== */
.site-nav {
  background: var(--green);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 12px rgba(0,0,0,0.2);
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 48px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-brand {
  font-family: 'Playfair Display', serif;
  font-size: 1.4rem;
  color: var(--cream);
  font-weight: 700;
  letter-spacing: 0.5px;
}
.nav-brand:hover { color: var(--gold-muted); }

.nav-links { display: flex; gap: 4px; list-style: none; }
.nav-links a {
  color: rgba(250,248,240,0.8);
  padding: 8px 14px;
  border-radius: 4px;
  font-family: 'Source Serif 4', serif;
  font-size: 0.88rem;
  font-weight: 400;
  letter-spacing: 0.2px;
  position: relative;
  transition: background 0.25s ease, color 0.25s ease;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 14px;
  right: 14px;
  height: 1px;
  background: var(--gold-muted);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.nav-links a:hover::after,
.nav-links a.active::after {
  transform: scaleX(1);
  transform-origin: left;
}
.nav-links a:hover,
.nav-links a.active {
  background: rgba(255,255,255,0.08);
  color: var(--cream);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--cream);
  margin: 5px 0;
  transition: 0.3s;
}

/* ===== HERO ===== */
.hero {
  background: var(--green);
  color: var(--cream);
  text-align: center;
  padding: 100px 24px 88px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(255,255,255,0.015) 2px,
    rgba(255,255,255,0.015) 4px
  );
}

/* ===== HERO VIDEO ===== */
.hero.hero-video {
  height: 100vh;
  min-height: 560px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero.hero-video::before { display: none; }

.hero-video video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(30, 58, 32, 0.4) 0%,
    rgba(30, 58, 32, 0.45) 50%,
    rgba(30, 58, 32, 0.55) 100%
  );
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 24px;
  max-width: 800px;
}

/* Hero entrance animation */
.hero h1,
.hero .tagline,
.hero .welcome {
  animation: heroFadeUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.hero .tagline { animation-delay: 0.15s; }
.hero .welcome { animation-delay: 0.3s; }

@keyframes heroFadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero h1 {
  font-size: clamp(2.8rem, 6vw + 0.5rem, 5.5rem);
  font-weight: 900;
  color: var(--cream);
  margin-bottom: 12px;
  position: relative;
  letter-spacing: -0.02em;
  line-height: 1.05;
}
.hero .tagline {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(1.1rem, 2vw + 0.3rem, 1.6rem);
  color: var(--gold-muted);
  margin-bottom: 32px;
  position: relative;
  letter-spacing: 0.02em;
}
.hero .welcome {
  max-width: 560px;
  margin: 0 auto;
  font-size: clamp(1rem, 1vw + 0.6rem, 1.15rem);
  line-height: 1.85;
  opacity: 0.85;
  position: relative;
}

/* ===== ACTION BAR ===== */
.action-bar {
  background: var(--green);
  padding: 32px 0;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.action-row {
  display: flex;
  justify-content: center;
  gap: 12px;
}
.action-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 18px 32px;
  border-radius: 8px;
  color: var(--cream);
  text-decoration: none;
  transition: background 0.25s ease, color 0.25s ease, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.action-item:hover {
  background: rgba(255,255,255,0.1);
  color: var(--gold-muted);
  transform: translateY(-2px);
}
.action-item:active {
  transform: translateY(0);
  transition-duration: 0.1s;
}
.action-icon {
  font-size: 1.6rem;
  line-height: 1;
}
.action-label {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

@media (max-width: 768px) {
  .action-row { flex-wrap: wrap; gap: 8px; }
  .action-item { flex: 1 1 40%; padding: 14px 12px; }
}

/* ===== PAGE HEADER (non-home pages) ===== */
.page-header {
  background: var(--green);
  color: var(--cream);
  padding: clamp(48px, 8vw, 88px) 24px clamp(40px, 7vw, 72px);
  text-align: left;
  overflow: hidden;
}
.page-header h1 {
  color: var(--cream);
  font-size: clamp(2.2rem, 5vw + 0.5rem, 3.8rem);
  font-weight: 900;
  margin-bottom: 8px;
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 clamp(20px, 4vw, 48px);
  letter-spacing: -0.02em;
  animation: headerSlideIn 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.page-header p {
  color: rgba(250,248,240,0.6);
  font-size: clamp(1rem, 1.2vw + 0.5rem, 1.15rem);
  font-style: italic;
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 clamp(20px, 4vw, 48px);
  animation: headerSlideIn 0.7s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
}

@keyframes headerSlideIn {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== SECTION ===== */
.section {
  padding: clamp(64px, 10vw, 120px) 0;
}
.section--alt {
  background: var(--cream-dark);
}
.section-title {
  font-size: clamp(1.8rem, 3vw + 0.5rem, 2.6rem);
  font-weight: 900;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}
.section-subtitle {
  color: var(--text-light);
  margin-bottom: 48px;
  font-size: 1rem;
  font-style: italic;
}
.section-divider {
  width: 48px;
  height: 3px;
  background: var(--gold);
  margin: 16px 0 48px;
  border: none;
}

/* Centered variant for homepage sections */
.section-title:has(+ .section-divider),
.section > .container > .section-title {
  text-align: center;
}
.section > .container > .section-divider {
  margin-left: auto;
  margin-right: auto;
}

/* ===== QUICK FACTS ===== */
.facts-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}
.fact-item {
  padding: 32px 16px;
  position: relative;
}
.fact-item + .fact-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 20%;
  height: 60%;
  width: 1px;
  background: var(--border);
}
.fact-value {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4vw + 0.5rem, 3.2rem);
  color: var(--green);
  font-weight: 900;
  display: block;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
  line-height: 1.1;
  white-space: nowrap;
}
.fact-label {
  font-size: 0.78rem;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-weight: 600;
}

/* ===== CARDS ===== */
.card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}
.card-grid--3 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: var(--white);
  border-radius: 4px;
  padding: 32px;
  border: 1px solid var(--border);
  border-left: 3px solid var(--gold);
  transition: box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.3s ease;
}
.card:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.08);
  border-left-color: var(--green);
}
.card-date {
  font-size: 0.78rem;
  color: var(--gold);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 10px;
}
.card h3 {
  font-size: clamp(1.15rem, 1.5vw + 0.3rem, 1.35rem);
  margin-bottom: 10px;
  font-weight: 700;
}
.card p {
  color: var(--text-light);
  font-size: 0.95rem;
  line-height: 1.7;
}
.card-meta {
  font-size: 0.82rem;
  color: var(--text-light);
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.card-meta span + span::before {
  content: ' \00B7 ';
  color: var(--border);
}

/* ===== BUSINESS CARDS ===== */
.biz-category {
  display: inline-block;
  background: var(--green);
  color: var(--cream);
  font-size: 0.68rem;
  padding: 3px 12px;
  border-radius: 2px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 14px;
  font-weight: 600;
}

.biz-details {
  margin-top: 16px;
  font-size: 0.88rem;
  color: var(--text-light);
  line-height: 1.7;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* ===== FILTER BUTTONS ===== */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 48px;
}
.filter-btn {
  padding: 8px 22px;
  border: 1px solid var(--border);
  border-radius: 2px;
  background: var(--white);
  font-family: 'Source Serif 4', serif;
  font-size: 0.88rem;
  color: var(--text-light);
  cursor: pointer;
  transition: all 0.25s ease;
}
.filter-btn:hover,
.filter-btn.active {
  background: var(--green);
  color: var(--cream);
  border-color: var(--green);
}
.filter-btn:active {
  transform: scale(0.96);
  transition-duration: 0.08s;
}

/* Business card filter transition */
#bizGrid .card {
  transition: box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.3s ease,
              opacity 0.3s ease;
}
#bizGrid .card[style*="display: none"] {
  /* JS sets display:none; we can't transition that, but the opacity
     transition covers the visual for cards that are visible */
}

/* ===== HISTORY / LONG-FORM ===== */
.prose {
  max-width: 680px;
  margin: 0 auto;
}
.prose h2 {
  font-size: clamp(1.5rem, 2.5vw + 0.3rem, 2rem);
  font-weight: 900;
  margin: clamp(48px, 6vw, 72px) 0 20px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  letter-spacing: -0.01em;
}
.prose h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}
.prose p {
  margin-bottom: 24px;
  color: var(--text);
}
.prose p.lead {
  font-size: clamp(1.1rem, 1.5vw + 0.5rem, 1.35rem);
  color: var(--text-light);
  font-style: italic;
  line-height: 1.8;
}

/* ===== NOTABLE PEOPLE ===== */
.notable-people {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin: 32px 0 8px;
}
.notable-person h3 {
  font-size: clamp(1.15rem, 1.5vw + 0.3rem, 1.3rem);
  margin-bottom: 4px;
}
.notable-role {
  font-size: 0.82rem;
  color: var(--gold);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
}
.notable-person p:last-child {
  color: var(--text-light);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 0;
}

@media (max-width: 600px) {
  .notable-people { grid-template-columns: 1fr; gap: 24px; }
}

/* ===== IMAGE PLACEHOLDER ===== */
.img-placeholder {
  background: var(--cream-dark);
  border: 2px dashed var(--border);
  border-radius: 4px;
  padding: 56px 24px;
  text-align: center;
  color: var(--text-light);
  font-size: 0.9rem;
  font-style: italic;
  margin: 40px 0;
}

/* ===== NEWS ARTICLE ===== */
.news-article {
  background: var(--white);
  border: 1px solid var(--border);
  border-left: 3px solid var(--gold);
  border-radius: 4px;
  padding: 40px;
  margin-bottom: 32px;
}
.news-article h2 {
  font-size: clamp(1.4rem, 2vw + 0.3rem, 1.75rem);
  font-weight: 700;
  margin-bottom: 8px;
  border: none;
  padding: 0;
  letter-spacing: -0.01em;
}
.news-article .news-meta {
  font-size: 0.82rem;
  color: var(--gold);
  margin-bottom: 20px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.news-article p {
  color: var(--text-light);
  line-height: 1.8;
  margin-bottom: 14px;
}

/* ===== ABOUT ===== */
.about-box {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: clamp(32px, 5vw, 56px);
  max-width: 720px;
  margin: 0 auto;
}
.about-box h2 {
  margin-bottom: 16px;
  font-weight: 700;
  font-size: clamp(1.3rem, 2vw + 0.3rem, 1.6rem);
}
.about-box h2:not(:first-child) {
  margin-top: 40px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}
.about-box p {
  margin-bottom: 16px;
  color: var(--text-light);
  line-height: 1.8;
}
.about-box a {
  color: var(--gold);
  font-weight: 700;
}

/* ===== LINK / CTA ===== */
.text-link {
  color: var(--gold);
  font-weight: 700;
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease;
}
.text-link:hover { border-bottom-color: var(--gold); }

.cta-link {
  display: inline-block;
  margin-top: 24px;
  padding: 14px 36px;
  background: var(--gold);
  color: var(--white);
  border-radius: 2px;
  font-weight: 700;
  font-size: 0.92rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  transition: background 0.25s ease, transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.cta-link:hover {
  background: var(--brown);
  color: var(--white);
  transform: translateY(-1px);
}
.cta-link:active {
  transform: translateY(1px);
  transition-duration: 0.08s;
}

/* ===== FOOTER ===== */
.site-footer {
  background: var(--green);
  color: rgba(250,248,240,0.65);
  text-align: center;
  padding: clamp(40px, 6vw, 72px) 24px;
  font-size: 0.9rem;
  line-height: 1.75;
  margin-top: 0;
}
.site-footer strong {
  color: var(--cream);
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.1rem, 1.5vw + 0.5rem, 1.4rem);
  margin-bottom: 6px;
  font-weight: 700;
}
.site-footer .disclaimer {
  margin-top: 20px;
  font-size: 0.78rem;
  opacity: 0.5;
  font-style: italic;
}
.site-footer .footer-credit {
  margin-top: 12px;
  font-size: 0.78rem;
  opacity: 0.5;
}
.site-footer .footer-credit a {
  color: var(--gold-muted);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease;
}
.site-footer .footer-credit a:hover {
  border-bottom-color: var(--gold-muted);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--green);
    padding: 0 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s cubic-bezier(0.16, 1, 0.3, 1),
                padding 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  }
  .nav-links.open {
    max-height: 400px;
    padding: 16px 24px;
  }
  .nav-links a { padding: 12px 0; }
  .nav-links a::after { display: none; }

  .hero { padding: 64px 24px 56px; }

  .facts-row { grid-template-columns: repeat(2, 1fr); gap: 0; }
  .fact-item + .fact-item::before { display: none; }
  .fact-item {
    border-bottom: 1px solid var(--border);
    padding: 24px 16px;
  }
  .card-grid, .card-grid--3 { grid-template-columns: 1fr; }

  .page-header { text-align: left; }

  .section-title:has(+ .section-divider),
  .section > .container > .section-title {
    text-align: left;
  }
  .section > .container > .section-divider {
    margin-left: 0;
    margin-right: auto;
  }
}

@media (max-width: 480px) {
  .facts-row { grid-template-columns: 1fr 1fr; }
  .card { padding: 24px; }
  .news-article { padding: 24px; }
}

/* ===== REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {
  .hero h1,
  .hero .tagline,
  .hero .welcome,
  .page-header h1,
  .page-header p {
    animation: none;
    opacity: 1;
    transform: none;
  }
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .action-item,
  .cta-link,
  .card,
  .filter-btn {
    transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
    transform: none !important;
  }
  .nav-links a::after {
    transition: none;
  }
}
