/* ================================================================
   EDGE 2 HEDGES — Global Stylesheet
   Used on every page (loaded via <link> in each .html file).
   Brand tokens locked from Website Template v1.0.
   ================================================================ */

/* ----------------------------------------------------------------
   1. Design Tokens
   ---------------------------------------------------------------- */

:root {
  --color-forest: #1A5632;
  --color-forest-dark: #14422A;
  --color-lime: #5CB85C;
  --color-rust: #C75B2A;
  --color-rust-dark: #A84A20;
  --color-rust-darker: #8E3D1A;
  --color-cream: #FDF8F0;
  --color-charcoal: #2B2B2B;
  --color-soft-forest: #E6F2EB;
  --color-white: #FFFFFF;
  --color-text-muted: #555555;
  --color-border: rgba(0, 0, 0, 0.08);

  --font-heading: 'Barlow Semi Condensed', system-ui, -apple-system, sans-serif;
  --font-body: 'Source Sans 3', system-ui, -apple-system, sans-serif;

  --fs-h1: 52px;  --lh-h1: 58px;
  --fs-h2: 38px;  --lh-h2: 46px;
  --fs-h3: 26px;  --lh-h3: 34px;
  --fs-body: 17px; --lh-body: 28px;
  --fs-small: 14px; --lh-small: 20px;
  --fs-cta: 18px; --lh-cta: 24px;
  --fs-nav: 15px; --lh-nav: 20px;

  --max-content: 1200px;
  --max-prose: 720px;
  --section-py: 80px;

  --shadow-card: 0 2px 16px rgba(0, 0, 0, 0.07);
  --shadow-card-hover: 0 6px 24px rgba(0, 0, 0, 0.11);
  --radius-card: 12px;
  --radius-btn: 8px;
}

@media (max-width: 1024px) {
  :root {
    --fs-h1: 42px;  --lh-h1: 48px;
    --fs-h2: 32px;  --lh-h2: 38px;
    --fs-h3: 24px;  --lh-h3: 30px;
    --fs-body: 16px; --lh-body: 26px;
    --fs-cta: 16px; --lh-cta: 22px;
    --section-py: 48px;
  }
}

@media (max-width: 640px) {
  :root {
    --fs-h1: 34px;  --lh-h1: 40px;
    --fs-h2: 28px;  --lh-h2: 34px;
    --fs-h3: 22px;  --lh-h3: 28px;
    --fs-small: 13px; --lh-small: 18px;
    --fs-nav: 18px; --lh-nav: 24px;
    --section-py: 32px;
  }
}

/* ----------------------------------------------------------------
   2. Reset & 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(--fs-body);
  line-height: var(--lh-body);
  color: var(--color-charcoal);
  background: var(--color-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a { color: var(--color-forest); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  margin: 0 0 0.5em;
  color: var(--color-charcoal);
}
h1 { font-size: var(--fs-h1); line-height: var(--lh-h1); }
h2 { font-size: var(--fs-h2); line-height: var(--lh-h2); }
h3 { font-size: var(--fs-h3); line-height: var(--lh-h3); }
p { margin: 0 0 1em; }

button { font-family: inherit; cursor: pointer; }

ul, ol { padding-left: 1.2em; }

/* ----------------------------------------------------------------
   3. Utilities
   ---------------------------------------------------------------- */

.container {
  max-width: var(--max-content);
  margin: 0 auto;
  padding: 0 24px;
}

.section { padding: var(--section-py) 0; }
.section--cream  { background: var(--color-cream); }
.section--white  { background: var(--color-white); }
.section--forest { background: var(--color-forest); color: var(--color-white); }
.section--forest h1, .section--forest h2, .section--forest h3 { color: var(--color-white); }

.section-title { text-align: center; margin-bottom: 16px; }
.section-subtitle { text-align: center; color: var(--color-text-muted); margin: -8px 0 32px; }

.section-eyebrow {
  display: block; text-align: center;
  font-family: var(--font-heading);
  font-size: 13px; text-transform: uppercase;
  letter-spacing: 2px; color: var(--color-rust);
  font-weight: 700; margin-bottom: 12px;
}

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--color-forest); color: var(--color-white);
  padding: 12px 16px; z-index: 10000;
}
.skip-link:focus { left: 12px; top: 12px; }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ----------------------------------------------------------------
   4. Buttons
   ---------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 32px;
  border-radius: var(--radius-btn);
  font-family: var(--font-heading);
  font-size: var(--fs-cta);
  line-height: var(--lh-cta);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
  text-decoration: none;
  min-height: 56px;
}
.btn:hover { text-decoration: none; }
.btn:focus-visible { outline: 3px solid var(--color-forest); outline-offset: 2px; }

.btn--rust { background: var(--color-rust); color: var(--color-white); }
.btn--rust:hover  { background: var(--color-rust-dark); }
.btn--rust:active { background: var(--color-rust-darker); }

.btn--forest { background: var(--color-forest); color: var(--color-white); }
.btn--forest:hover { background: var(--color-forest-dark); }

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

.btn--white-outline {
  background: transparent;
  border-color: var(--color-white);
  color: var(--color-white);
}
.btn--white-outline:hover { background: rgba(255, 255, 255, 0.15); color: var(--color-white); }

.btn--small { padding: 12px 24px; min-height: auto; font-size: 15px; }

/* ================================================================
   5. SITE HEADER (loaded via include.js into #site-header)
   ================================================================ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--color-white);
  border-bottom: 1px solid var(--color-border);
  transition: box-shadow 0.2s ease;
}
.site-header[data-scrolled] { box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 80px;
  transition: height 0.2s ease;
}
.site-header[data-scrolled] .header-inner { height: 64px; }

.brand {
  display: flex;
  flex-direction: column;
  line-height: 0.95;
  color: var(--color-forest);
  font-family: var(--font-heading);
  font-weight: 800;
  letter-spacing: 0.5px;
  text-decoration: none;
}
.brand__line1 { font-size: 14px; letter-spacing: 1.5px; }
.brand__line2 { font-size: 26px; letter-spacing: 2px; }

.nav--desktop > ul {
  display: flex;
  list-style: none;
  gap: 28px;
  margin: 0;
  padding: 0;
}
.nav--desktop a {
  font-family: var(--font-heading);
  font-size: var(--fs-nav);
  line-height: var(--lh-nav);
  color: var(--color-charcoal);
  font-weight: 600;
  padding: 8px 0;
  border-bottom: 2px solid transparent;
  text-decoration: none;
  display: inline-block;
}
.nav--desktop a:hover { color: var(--color-forest); }
.nav--desktop a.is-active {
  color: var(--color-forest);
  border-bottom-color: var(--color-forest);
}

.has-dropdown { position: relative; }
.dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--color-white);
  box-shadow: var(--shadow-card);
  border-radius: var(--radius-card);
  list-style: none;
  margin: 8px 0 0;
  padding: 8px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s;
}
.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown a {
  display: block;
  padding: 10px 16px;
  border-bottom: none !important;
  font-size: 15px;
}
.dropdown a:hover { background: var(--color-soft-forest); color: var(--color-forest); }

.header-actions { display: flex; align-items: center; gap: 16px; }

.phone-link {
  display: flex;
  align-items: baseline;
  gap: 6px;
  color: var(--color-forest);
  font-weight: 600;
  text-decoration: none;
  font-size: 15px;
}
.phone-link__label { font-family: var(--font-heading); font-size: 13px; letter-spacing: 0.5px; }
.phone-link__number { font-family: var(--font-heading); font-size: 16px; }

.hamburger {
  display: none;
  background: transparent;
  border: 0;
  width: 44px;
  height: 44px;
  padding: 10px;
  flex-direction: column;
  justify-content: space-between;
}
.hamburger span {
  display: block;
  height: 2px;
  background: var(--color-charcoal);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav--mobile {
  background: var(--color-white);
  border-top: 1px solid var(--color-border);
}
.nav--mobile ul {
  list-style: none;
  margin: 0;
  padding: 16px 24px 24px;
  display: flex;
  flex-direction: column;
}
.nav--mobile li { border-bottom: 1px solid var(--color-border); }
.nav--mobile a {
  display: block;
  padding: 16px 0;
  font-family: var(--font-heading);
  font-size: 18px;
  color: var(--color-charcoal);
  font-weight: 600;
  text-decoration: none;
}
.nav--mobile a.is-active { color: var(--color-forest); }
.nav--mobile [hidden] { display: none; }
.mobile-cta { border-bottom: 0 !important; padding-top: 16px; }
.mobile-cta .btn { width: 100%; }

@media (max-width: 1024px) {
  .nav--desktop, .phone-link { display: none; }
  .hamburger { display: flex; }
  .header-cta { padding: 10px 16px; min-height: auto; font-size: 14px; }
}

/* ================================================================
   6. SITE FOOTER (loaded via include.js into #site-footer)
   ================================================================ */

.site-footer {
  background: var(--color-charcoal);
  color: rgba(255, 255, 255, 0.7);
  padding: 64px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
}
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 600px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.footer-brand {
  display: flex;
  flex-direction: column;
  line-height: 0.95;
  color: var(--color-white);
  font-family: var(--font-heading);
  font-weight: 800;
  text-decoration: none;
  margin-bottom: 16px;
}
.footer-brand__line1 { font-size: 14px; letter-spacing: 1.5px; }
.footer-brand__line2 { font-size: 26px; letter-spacing: 2px; }

.footer-tagline {
  font-style: italic;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.5);
  margin: 0 0 20px;
  max-width: 320px;
}

.footer-contact {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.footer-contact a { color: rgba(255, 255, 255, 0.7); text-decoration: none; font-size: 15px; }
.footer-contact a:hover { color: var(--color-white); }
.footer-contact__phone { color: var(--color-rust) !important; font-weight: 600; font-size: 16px !important; }
.footer-hours, .footer-address { font-size: 14px; color: rgba(255, 255, 255, 0.55); }

.footer-col h4 {
  color: var(--color-white);
  font-family: var(--font-heading);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 0 0 16px;
}
.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-col a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 15px;
}
.footer-col a:hover { color: var(--color-white); }
.footer-view-all { color: var(--color-rust) !important; font-weight: 600; }

.footer-social a { font-size: 14px; }
.footer-cta { margin-top: 16px; }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 20px 0;
  background: #1f1f1f;
}
.footer-bottom__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.45);
}
.footer-bottom p { margin: 0; }
.footer-legal {
  display: flex;
  list-style: none;
  padding: 0;
  margin: 0;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-legal a { color: rgba(255, 255, 255, 0.55); text-decoration: none; }
.footer-legal a:hover { color: var(--color-white); }

/* ================================================================
   7. Shared Components
   ================================================================ */

/* --- Tim's Callout Box --- */
.tim-callout {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background: var(--color-cream);
  border-left: 4px solid var(--color-rust);
  padding: 20px 24px;
  border-radius: 0 var(--radius-card) var(--radius-card) 0;
  margin: 0 0 32px;
}
.tim-callout--compact { padding: 14px 18px; }

.tim-callout__avatar {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--color-forest);
  color: var(--color-white);
  display: grid;
  place-items: center;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 18px;
  overflow: hidden;
}
.tim-callout__body {
  font-style: italic;
  color: var(--color-charcoal);
  font-size: 17px;
  line-height: 1.6;
}
.tim-callout__body p { margin: 0; }
.tim-callout__body p + p { margin-top: 8px; }

/* --- FAQ accordion --- */
.faq { display: flex; flex-direction: column; gap: 12px; max-width: 800px; margin: 0 auto; }
.faq__item {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  padding: 0;
  transition: box-shadow 0.15s ease;
}
.faq__item[open] { box-shadow: var(--shadow-card); border-color: transparent; }
.faq__item summary {
  cursor: pointer;
  list-style: none;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 18px;
  color: var(--color-charcoal);
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item:hover summary { background: var(--color-soft-forest); border-radius: var(--radius-card); }
.faq__icon {
  color: var(--color-rust);
  font-size: 24px;
  font-weight: 400;
  transition: transform 0.2s ease;
  line-height: 1;
}
.faq__item[open] .faq__icon { transform: rotate(45deg); }
.faq__answer {
  padding: 0 24px 20px;
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text-muted);
}
.faq__answer a { color: var(--color-forest); font-weight: 600; }

/* --- Mobile sticky CTA bar --- */
.mobile-cta-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 999;
  box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.1);
}
.mobile-cta-bar__btn {
  flex: 1;
  min-height: 56px;
  display: grid;
  place-items: center;
  color: var(--color-white);
  font-family: var(--font-heading);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  text-decoration: none;
}
.mobile-cta-bar__btn--call  { background: var(--color-forest); }
.mobile-cta-bar__btn--quote { background: var(--color-rust); }
@media (max-width: 768px) {
  .mobile-cta-bar { display: flex; }
  body { padding-bottom: 56px; }
}
