/* ============================================================
   Mountain Housing Assistance — site stylesheet
   Re-skin: forest / gold / cream · Cormorant Garamond + Montserrat
   Drop-in replacement. Variable NAMES are preserved so the inline
   styles in the existing HTML resolve; only their VALUES change.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&family=Montserrat:wght@300;400;500;600;700&display=swap');

/* ---------- Palette & tokens ---------- */
:root {
  /* Core brand palette */
  --forest:      #1a3a2a;
  --forest-deep: #12281d;
  --forest-mid:  #2d5a3d;
  --forest-soft: #4a7a5a;
  --gold:        #c4a96b;
  --gold-light:  #e0c880;
  --cream:       #f8f4ee;
  --cream-warm:  #f1ebe0;
  --warm-white:  #ffffff;
  --charcoal:    #1a2218;
  --ink:         #1a2218;
  --mid-gray:    #5f6f5d;
  --line:        #e4ded3;

  /* --- Names the existing HTML inline styles depend on (remapped) --- */
  --paper:       #f8f4ee;   /* light surface / light text on dark */
  --pine:        #1a3a2a;   /* dark accent sections */
  --pine-dark:   #12281d;   /* darker green (figure fills on pine) */
  --moss-soft:   #9fb39d;   /* muted light text on dark backgrounds */
  --granite:     #5f6f5d;   /* muted body text on light backgrounds */
  --terracotta:  #c4a96b;   /* accent -> gold */
  --stone:       #8a978a;   /* faint caption gray */

  /* Type roles */
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans:  "Montserrat", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono:  "Montserrat", sans-serif; /* used uppercase + letterspaced as a utility face */
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

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

body {
  font-family: var(--sans);
  background: var(--cream);
  color: var(--charcoal);
  line-height: 1.65;
  font-weight: 400;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: var(--serif); color: var(--forest); line-height: 1.08; font-weight: 600; }
h1 { font-size: clamp(2.4rem, 5vw, 4rem); font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.7rem); }
h3 { font-size: 1.35rem; font-weight: 600; }

p { margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }

a { color: var(--forest-mid); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--gold); }

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

:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

/* ---------- Layout primitives ---------- */
.container { max-width: 1180px; margin: 0 auto; padding: 0 2rem; }
.container--narrow { max-width: 760px; }

section { padding: 5.5rem 0; }

.bg-paper-warm { background: var(--cream-warm); }
.bg-pine { background: var(--forest); color: var(--paper); }
.bg-pine h1, .bg-pine h2, .bg-pine h3 { color: var(--paper); }

.text-center { text-align: center; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.75rem; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 3.5rem; align-items: start; }
.grid-2--asym     { grid-template-columns: 5fr 7fr; }
.grid-2--asym-rev { grid-template-columns: 7fr 5fr; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }

/* ---------- Shared editorial elements ---------- */
.eyebrow {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.72rem; font-weight: 700;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--gold);
}
.bg-pine .eyebrow { color: var(--gold-light); }

.lede {
  font-family: var(--serif);
  font-size: clamp(1.2rem, 1.8vw, 1.5rem);
  font-weight: 400; line-height: 1.5;
  color: var(--mid-gray);
}
.bg-pine .lede { color: var(--moss-soft); }

.section-head { max-width: 720px; margin-bottom: 3rem; }
.section-head .eyebrow { margin-bottom: 0.75rem; }
.section-head h2 { margin-bottom: 1rem; }

.hr-fancy {
  border: 0; height: 1px; background: var(--line);
  position: relative; margin: 2rem 0;
}
.hr-fancy::after {
  content: ""; position: absolute; left: 0; top: -1px;
  width: 48px; height: 3px; background: var(--gold);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--sans);
  font-size: 0.74rem; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase;
  padding: 0.95rem 1.8rem;
  background: var(--forest); color: var(--paper);
  border: 1px solid var(--forest);
  cursor: pointer; transition: all .2s ease;
}
.btn:hover { background: var(--forest-deep); color: var(--gold-light); transform: translateY(-1px); }
.btn--accent { background: var(--gold); color: var(--charcoal); border-color: var(--gold); }
.btn--accent:hover { background: var(--gold-light); color: var(--charcoal); }
.btn--ghost { background: transparent; color: var(--forest); border: 1px solid var(--forest-soft); }
.btn--ghost:hover { border-color: var(--gold); color: var(--gold); background: transparent; }
.arrow { display: inline-block; transition: transform .2s ease; }
.btn:hover .arrow { transform: translateX(3px); }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(8px);
  border-top: 5px solid var(--forest);
  border-bottom: 3px solid var(--forest);
}
.site-header__inner {
  max-width: 1180px; margin: 0 auto; padding: 0.55rem 2rem;
  display: flex; align-items: center; justify-content: space-between;
}
.brand { display: flex; align-items: center; gap: 0.8rem; color: var(--paper); }
.brand:hover { color: var(--paper); }
.brand__mark { width: 38px; height: 38px; flex-shrink: 0; }
.brand__name {
  font-family: var(--serif); font-size: 1.05rem; font-weight: 600;
  color: var(--paper); line-height: 1.15; letter-spacing: 0.01em;
}
.brand__name small {
  display: block; font-family: var(--sans); font-size: 0.6rem; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold);
  margin-top: 2px;
}
.nav { display: flex; align-items: center; gap: 1.9rem; }
.nav a {
  font-family: var(--sans); font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: var(--forest-mid);
}
.nav a:hover { color: var(--forest); }
.nav a.active { color: var(--forest); border-bottom: 2px solid var(--gold); padding-bottom: 2px; }
.nav__toggle {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: 0; cursor: pointer; padding: 6px;
}
.nav__toggle span { width: 24px; height: 2px; background: var(--forest); transition: .2s; }

/* ---------- Hero (light, topo-lined — the format, in the new palette) ---------- */
.hero {
  position: relative; overflow: hidden;
  background: var(--cream);
  padding: 6.5rem 0 5.5rem;
}
.hero--compact { padding: 4.5rem 0 3.5rem; }
.hero .container, .hero__inner { position: relative; z-index: 2; }
.hero__inner { max-width: 820px; }
.hero h1 { color: var(--forest); }
.topo {
  position: absolute; inset: 0; z-index: 1;
  opacity: 0.22; pointer-events: none;
}
.topo svg { width: 100%; height: 100%; }

/* ---------- Mission / generic cards ---------- */
.card {
  background: var(--warm-white);
  border: 1px solid var(--line);
  padding: 2rem 1.75rem;
  transition: box-shadow .2s ease, transform .2s ease;
}
.card:hover { box-shadow: 0 10px 34px rgba(26,58,42,0.09); transform: translateY(-2px); }
.card__num {
  display: block; font-family: var(--mono);
  font-size: 0.66rem; font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 0.9rem;
}
.card h3 { margin-bottom: 0.6rem; }
.card p { font-size: 0.95rem; color: var(--mid-gray); }

/* ---------- Stats ---------- */
.stat__num {
  display: block; font-family: var(--serif);
  font-size: clamp(2.6rem, 5vw, 3.6rem); font-weight: 700;
  color: var(--forest); line-height: 1;
}
.bg-pine .stat__num { color: var(--gold); }
.stat__label {
  display: block; font-family: var(--sans);
  font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--mid-gray); margin-top: 0.5rem; line-height: 1.4;
}
.bg-pine .stat__label { color: var(--moss-soft); }

/* ---------- Figures (image placeholders until art is added) ---------- */
.figure {
  background: var(--cream-warm);
  border: 1px solid var(--line);
  aspect-ratio: 4 / 3;
  display: flex; align-items: center; justify-content: center;
  text-align: center; padding: 1.5rem;
}
.figure--wide { aspect-ratio: 16 / 9; }
.figure--tall { aspect-ratio: 3 / 4; }
.figure__label {
  font-family: var(--mono); font-size: 0.66rem; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--stone);
  line-height: 1.7;
}
.figure__label em {
  display: block; margin-top: 0.5rem; font-family: var(--serif);
  font-style: italic; font-size: 0.95rem; font-weight: 400;
  letter-spacing: 0; text-transform: none; color: var(--mid-gray);
}

/* ---------- Lot table ---------- */
.lot-table { width: 100%; border-collapse: collapse; margin-top: 1.5rem; }
.lot-table th {
  font-family: var(--sans); font-size: 0.66rem; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--mid-gray);
  text-align: left; padding: 0.7rem 1rem;
  background: var(--cream-warm); border-bottom: 2px solid var(--gold);
}
.lot-table td {
  padding: 1rem; font-size: 0.92rem; color: var(--mid-gray);
  border-bottom: 1px solid var(--line); vertical-align: top;
}
.lot-table tr:last-child td { border-bottom: none; }
.lot-table tr:hover td { background: #faf8f3; }
.lot-name {
  display: block; font-family: var(--serif); font-size: 1.1rem;
  font-weight: 600; color: var(--forest); margin-bottom: 2px;
}
.lot-meta {
  display: block; font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--gold);
}

/* ---------- Clean ordered/marker list ---------- */
.list-clean { list-style: none; }
.list-clean li {
  display: flex; gap: 1.25rem; align-items: flex-start;
  padding: 1.1rem 0; border-bottom: 1px solid var(--line);
}
.list-clean li:last-child { border-bottom: none; }
.list-clean li > span {
  flex-shrink: 0; width: 12px; height: 12px; margin-top: 0.4rem;
  background: var(--gold); transform: rotate(45deg);
}
.list-clean h3 { font-size: 1.15rem; }
.list-clean p { font-size: 0.95rem; }

/* ---------- Team ---------- */
.team { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }
.team__member .figure { aspect-ratio: 4 / 5; margin-bottom: 1rem; }
.team__member h3 { font-size: 1.2rem; margin-bottom: 0.25rem; }
.team__role {
  display: block; font-family: var(--sans); font-size: 0.66rem; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold);
  margin-bottom: 0.75rem;
}
.team__bio { font-size: 0.88rem; color: var(--mid-gray); line-height: 1.6; }

/* ---------- Pull quote ---------- */
.pullquote {
  font-family: var(--serif); font-style: italic;
  font-size: clamp(1.4rem, 2.6vw, 1.9rem); line-height: 1.45;
  color: var(--forest); padding-left: 1.75rem;
  border-left: 3px solid var(--gold);
}
.bg-pine .pullquote, .pullquote--light { color: var(--paper); }
.pullquote cite {
  display: block; margin-top: 1.25rem; font-family: var(--sans);
  font-style: normal; font-size: 0.72rem; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold);
}

/* ---------- Letter (Town partnership) ---------- */
.letter { font-family: var(--serif); font-size: 1.18rem; line-height: 1.7; color: var(--charcoal); }
.letter p { margin-bottom: 1.2rem; }
.signature {
  font-family: var(--serif); font-style: italic; font-size: 1.9rem;
  font-weight: 500; color: var(--forest); margin: 0.5rem 0 0.25rem;
}
.sig-title {
  font-family: var(--sans); font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--mid-gray);
  line-height: 1.7;
}

/* ---------- Disclosure / notice ---------- */
.notice {
  background: var(--cream-warm);
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.notice p { font-size: 0.82rem; line-height: 1.7; color: var(--mid-gray); }
.notice strong {
  display: inline-block; font-family: var(--sans); font-size: 0.66rem;
  font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--forest); margin-right: 0.5rem;
}

/* ---------- Form ---------- */
.form { display: grid; gap: 1.1rem; }
.form label {
  display: block; font-family: var(--sans); font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--mid-gray);
  margin-bottom: 0.4rem;
}
.form input, .form select, .form textarea {
  width: 100%; padding: 0.8rem 0.9rem;
  font-family: var(--sans); font-size: 0.95rem; color: var(--charcoal);
  background: var(--warm-white); border: 1px solid var(--line);
  transition: border-color .2s ease;
}
.form input:focus, .form select:focus, .form textarea:focus {
  outline: none; border-color: var(--forest);
}
.form textarea { min-height: 130px; resize: vertical; }

/* ---------- Footer ---------- */
.site-footer { background: var(--forest-deep); color: var(--moss-soft); padding: 3.5rem 0 2rem; }
.site-footer__grid {
  display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 2.5rem;
  padding-bottom: 2.5rem; border-bottom: 1px solid rgba(255,255,255,0.12);
}
.site-footer__brand {
  font-family: var(--serif); font-size: 1.5rem; font-weight: 700;
  color: var(--paper); line-height: 1.1; margin-bottom: 1rem;
}
.site-footer__mission { font-size: 0.85rem; color: var(--moss-soft); line-height: 1.6; }
.site-footer h4 {
  font-family: var(--sans); font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold);
  margin-bottom: 1rem;
}
.site-footer a { color: var(--moss-soft); }
.site-footer a:hover { color: var(--gold); }
.site-footer__bottom {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 0.75rem;
  padding-top: 1.75rem; font-size: 0.72rem; color: rgba(255,255,255,0.45);
  letter-spacing: 0.04em;
}

/* ---------- Entrance animation ---------- */
.rise { opacity: 0; transform: translateY(22px); animation: rise .8s ease forwards; }
.rise-1 { animation-delay: .05s; }
.rise-2 { animation-delay: .18s; }
.rise-3 { animation-delay: .31s; }
.rise-4 { animation-delay: .44s; }
@keyframes rise { to { opacity: 1; transform: translateY(0); } }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 860px) {
  .nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: flex-start; gap: 0;
    background: #fff; padding: 0.5rem 2rem 1.25rem;
    border-bottom: 3px solid var(--forest);
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 0.75rem 0; width: 100%; }
  .nav__toggle { display: flex; }
  .site-header { position: relative; }

  .grid-2, .grid-2--asym, .grid-2--asym-rev, .grid-3 { grid-template-columns: 1fr; gap: 2.25rem; }
  .team { grid-template-columns: repeat(2, 1fr); }
  .site-footer__grid { grid-template-columns: 1fr 1fr; gap: 1.75rem; }
}

@media (max-width: 520px) {
  .container { padding: 0 1.25rem; }
  section { padding: 4rem 0; }
  .team, .site-footer__grid { grid-template-columns: 1fr; }
  .site-footer__bottom { flex-direction: column; }
}

/* ---------- Accessibility: reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .rise { opacity: 1; transform: none; }
}



/* ===== Synced from index inline styles (hero image, logos, grid-4) ===== */
/* ---------- Image hero (home) ---------- */
.hero--image { background: var(--forest-deep); color: var(--paper); padding: 8rem 0 6rem; }
.hero--image .hero__bg {
  position: absolute; inset: 0; z-index: 0;
  width: 100%; height: 100%; object-fit: cover; object-position: center 35%;
}
.hero--image .hero__scrim {
  position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, rgba(18,40,29,0.94) 0%, rgba(18,40,29,0.72) 42%, rgba(18,40,29,0.30) 100%);
}
.hero--image .container { position: relative; z-index: 2; }
.hero--image h1 { color: #fff; }
.hero--image .eyebrow { color: var(--gold-light); }
.hero--image .lede { color: rgba(255,255,255,0.92); max-width: 58ch; }
@media (max-width: 640px) {
  .hero--image .hero__scrim {
    background: linear-gradient(180deg, rgba(18,40,29,0.78) 0%, rgba(18,40,29,0.92) 100%);
  }
}

/* ---------- Brand logo (header + footer) ---------- */
/* ---------- Brand logo (white header band) ---------- */
.brand__logo {
  display: block; height: 64px; width: auto;
  background: none; padding: 0; border-radius: 0;
}
.site-footer__logo {
  display: inline-block; height: 108px; width: auto;
  background: #fff; padding: 8px 12px; border-radius: 6px; margin-bottom: 1rem;
}

/* ---------- Four-up stat grid ---------- */
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }
@media (max-width: 980px) { .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .grid-4 { grid-template-columns: 1fr; } }

.site-footer__disclosure {
  margin-top: 1.5rem; font-size: 0.72rem; color: rgba(255,255,255,0.45); line-height: 1.6;
}
