/* ==========================================================================
   Las Dos HOA — Phase 1  |  Site stylesheet
   "Modern Minimal" design: airy, light, clean sans typography
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  /* Color palette */
  --pinon:       #5E6F50;   /* muted piñon green — primary */
  --pinon-dark:  #3B4632;   /* darker green — headers/buttons */
  --adobe:       #8A6A4F;   /* muted adobe — accent */
  --adobe-dark:  #6E5239;   /* links */
  --sky:         #8FB0C4;   /* high-desert sky — focus ring */
  --sand:        #E7E3DA;   /* light stone — borders */
  --cream:       #FBFBF8;   /* near-white page background */
  --cream-deep:  #F4F2EC;   /* alternate section background */
  --charcoal:    #20231E;   /* body text */
  --charcoal-soft:#5A5E54;
  --white:       #FFFFFF;

  /* Typography */
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  /* Spacing / layout */
  --maxw: 1080px;
  --maxw-narrow: 760px;
  --radius: 14px;
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.05), 0 6px 20px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.10);
}

/* --------------------------------------------------------------- Base --- */
* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 7rem;   /* jump links land below the sticky header */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 18px;             /* large base size for readability */
  line-height: 1.7;
  letter-spacing: -0.005em;
  color: var(--charcoal);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  text-wrap: balance;
  font-family: var(--sans);
  color: var(--pinon-dark);
  line-height: 1.2;
  margin: 0 0 0.5em;
  font-weight: 800;
  letter-spacing: -0.03em;
}

h1 { font-size: 2.6rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.35rem; font-weight: 700; color: var(--pinon); }

p { margin: 0 0 1.1em; }

a {
  color: var(--adobe-dark);
  text-decoration: underline;
  text-underline-offset: 2px;
}
a:hover, a:focus { color: var(--pinon-dark); }

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

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

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--pinon-dark);
  color: var(--white);
  padding: 0.7em 1.2em;
  z-index: 1000;
  border-radius: 0 0 var(--radius) 0;
}
.skip-link:focus { left: 0; color: var(--white); }

/* Heading for screen readers only (keeps heading order without changing the look) */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ------------------------------------------------------- Layout utils --- */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 1.25rem; }
.narrow   { max-width: var(--maxw-narrow); }
.section  { padding: 5rem 0; }
.section-alt { background: var(--cream-deep); }
.center   { text-align: center; }
.lead { font-size: 1.2rem; color: var(--charcoal-soft); }
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--pinon);
  font-family: var(--sans);
  margin-bottom: 0.5rem;
}

/* ----------------------------------------------------------- Header ----- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(251, 251, 248, 0.85);
  -webkit-backdrop-filter: saturate(140%) blur(8px);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--sand);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 1.25rem;
  max-width: var(--maxw);
  margin: 0 auto;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--pinon-dark);
}
.brand .mark {
  width: 42px; height: 42px;
  flex: 0 0 auto;
}
.brand .brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand .brand-name { font-family: var(--serif); font-size: 1.3rem; font-weight: 800; letter-spacing: -0.02em; white-space: nowrap; }
.brand .brand-sub  { font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--adobe); white-space: nowrap; }
.brand .brand-phase { white-space: nowrap; }

.nav-toggle {
  display: none;
  background: var(--pinon);
  color: var(--white);
  border: none;
  font-size: 1rem;
  padding: 0.6rem 0.9rem;
  border-radius: var(--radius);
  cursor: pointer;
  white-space: nowrap;
  flex: 0 0 auto;
  min-height: 44px;
}

.site-nav ul {
  list-style: none;
  display: flex;
  gap: 0.3rem;
  margin: 0; padding: 0;
}
.site-nav a {
  display: block;
  text-decoration: none;
  color: var(--charcoal-soft);
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0.55rem 0.65rem;
  white-space: nowrap;
}
.site-nav a:hover { color: var(--pinon-dark); }
.site-nav a[aria-current="page"] {
  color: var(--pinon-dark);
  box-shadow: inset 0 -2px 0 var(--pinon);
}

/* ------------------------------------------------------------- Hero ----- */
.hero {
  position: relative;
  min-height: 560px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  text-align: left;
  color: var(--white);
  background:
    linear-gradient(90deg, rgba(20,22,18,0.55) 0%, rgba(20,22,18,0.15) 55%, rgba(20,22,18,0) 100%),
    url("../images/welcome.jpeg") center 55% / cover no-repeat;
}
.hero-content { max-width: 600px; margin-left: 4%; padding: 2rem 1.25rem; }
.hero h1 { color: var(--white); font-size: 3.4rem; line-height: 1.05; }
.hero p { font-size: 1.25rem; color: #F2F2EE; margin-bottom: 1.6rem; }
.hero-content .btn { margin: 0 0.5rem 0.75rem 0; }

/* page banner (interior pages) */
.page-banner {
  background: var(--pinon-dark);
  color: var(--white);
  padding: 2.6rem 0;
  text-align: center;
}
.page-banner h1 { color: var(--white); margin: 0; }
.page-banner p { color: var(--sand); margin: 0.4rem 0 0; }

/* ---------------------------------------------------------- Buttons ----- */
.btn {
  display: inline-block;
  font-family: var(--sans);
  font-size: 1.05rem;
  font-weight: 600;
  text-decoration: none;
  padding: 0.85rem 1.6rem;
  border-radius: 6px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.btn-primary { background: var(--pinon-dark); color: var(--white); }
.btn-primary:hover, .btn-primary:focus { background: #2B3325; color: var(--white); }
.btn-ghost { background: transparent; color: var(--white); border-color: var(--white); }
.btn-ghost:hover, .btn-ghost:focus { background: var(--white); color: var(--pinon-dark); }
.btn-green { background: var(--pinon); color: var(--white); }
.btn-green:hover, .btn-green:focus { background: var(--pinon-dark); color: var(--white); }

/* --------------------------------------------------------- Quicklinks --- */
.quicklinks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  margin-top: 2rem;
}
.quickcard {
  background: var(--white);
  border: none;
  border-radius: var(--radius);
  padding: 1.6rem 1.4rem;
  text-decoration: none;
  color: var(--charcoal);
  box-shadow: var(--shadow);
  transition: transform 0.15s, box-shadow 0.15s;
  display: block;
}
.quickcard:hover, .quickcard:focus {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  color: var(--charcoal);
}
.quickcard .ql-icon { width: 38px; height: 38px; margin-bottom: 0.7rem; color: var(--pinon); }
.quickcard h3 { margin: 0 0 0.3rem; color: var(--pinon-dark); }
.quickcard p { margin: 0; font-size: 0.95rem; color: var(--charcoal-soft); }

/* ------------------------------------------------------------ Cards ----- */
.card {
  background: var(--white);
  border: none;
  border-radius: var(--radius);
  padding: 1.6rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.25rem;
}
.card h3 { margin-top: 0; }

/* Long-form story with subheadings (Our Community → Heritage) */
.story h3 { margin-top: 2.25rem; }
.story h3:first-child { margin-top: 0.75rem; }

.info-card {
  background: var(--white);
  border-left: 3px solid var(--pinon);
  border-radius: var(--radius);
  padding: 1.4rem 1.6rem;
  box-shadow: var(--shadow);
}
.info-card h3 { margin-top: 0; color: var(--pinon-dark); }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.grid-2 > * { min-width: 0; }

/* ------------------------------------------------- Document download ---- */
.doc-card {
  display: flex;
  gap: 1.4rem;
  align-items: center;
  background: var(--white);
  border: 1px solid var(--sand);
  border-radius: var(--radius);
  padding: 1.3rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.25rem;
}
.doc-card .thumb {
  flex: 0 0 auto;
  width: 120px;
  border: 1px solid var(--sand);
  border-radius: 6px;
  overflow: hidden;
  background: var(--cream-deep);
}
.doc-card .doc-body { flex: 1 1 auto; min-width: 0; }
.doc-card h3 { margin: 0 0 0.3rem; }
.doc-card p { margin: 0 0 0.8rem; color: var(--charcoal-soft); font-size: 0.97rem; }
.doc-card .doc-meta {
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--pinon);
  margin-bottom: 0.3rem;
}

/* ---------------------------------------------------------- Gallery ----- */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}
.gallery figure {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--white);
}
.gallery a { display: block; }
.gallery img { width: 100%; height: 240px; object-fit: cover; transition: opacity 0.15s; }
.gallery a:hover img { opacity: 0.88; }
.gallery figcaption { padding: 0.6rem 0.8rem; font-size: 0.9rem; color: var(--charcoal-soft); }

/* ----------------------------------------------- Contact / board list -- */
.board-list { list-style: none; padding: 0; margin: 0; }
.board-list li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--sand);
}
.board-list .role { font-weight: 700; font-size: 1.1rem; color: var(--pinon-dark); }
.board-list a { display: inline-block; padding: 0.45rem 0; overflow-wrap: anywhere; }

.small-note { font-size: 0.85rem; color: var(--charcoal-soft); }

/* --------------------------------------------------------------- FAQ ---- */
.faq details {
  background: var(--white);
  border: 1px solid var(--sand);
  border-radius: var(--radius);
  padding: 0 1.2rem;
  margin-bottom: 0.75rem;
  box-shadow: var(--shadow);
}
.faq summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--pinon-dark);
  padding: 1rem 0;
  font-size: 1.08rem;
}
.faq details[open] summary { border-bottom: 1px solid var(--sand); margin-bottom: 0.8rem; }

/* Link list */
.link-list { list-style: none; padding: 0; margin: 0; }
.link-list li { padding: 0.3rem 0; border-bottom: 1px solid var(--sand); }
.link-list a { display: inline-block; padding: 0.45rem 0; font-weight: 600; }
.link-list .desc { display: block; font-size: 0.9rem; color: var(--charcoal-soft); font-weight: 400; }

/* ---------------------------------------------------------- Footer ----- */
.site-footer {
  background: var(--pinon-dark);
  color: var(--cream);
  padding: 3rem 0 1.5rem;
  margin-top: 1rem;
}
.site-footer a { color: var(--sand); }
.site-footer a:hover { color: var(--white); }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2rem;
}
.site-footer h2 { color: var(--white); font-family: var(--sans); font-size: 0.9rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { padding: 0.25rem 0; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  margin-top: 2rem;
  padding-top: 1.2rem;
  font-size: 0.9rem;
  color: var(--sand);
  text-align: center;
}

/* --------------------------------------------------------- Responsive -- */
/* Tablets / small laptops: the full menu doesn't fit beside the logo, so it
   drops to its own centered row instead of overflowing. */
@media (max-width: 1080px) {
  .header-inner { flex-wrap: wrap; row-gap: 0.2rem; }
  .site-nav { width: 100%; }
  .site-nav ul { justify-content: center; }
  .site-nav a { padding-top: 0.8rem; padding-bottom: 0.8rem; }
}

@media (max-width: 800px) {
  .nav-toggle { display: block; }
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--cream);
    border-bottom: 1px solid var(--sand);
    box-shadow: var(--shadow-lg);
  }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; padding: 0.5rem; }
  .site-nav a { padding: 0.9rem 1rem; font-size: 0.95rem; }
  .header-inner { position: relative; flex-wrap: nowrap; }

  .section { padding: 3.5rem 0; }
  .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .site-footer li { padding: 0; }
  .site-footer li a { display: inline-block; padding: 0.55rem 0; }
  /* text spans the full photo on small screens, so darken it evenly for contrast */
  .hero {
    min-height: 480px;
    background:
      linear-gradient(rgba(20,22,18,0.50), rgba(20,22,18,0.40)),
      url("../images/welcome.jpeg") center 55% / cover no-repeat;
  }
  .hero-content { margin-left: 0; }
  .hero h1 { font-size: 2.5rem; }
  .doc-card { flex-direction: column; align-items: flex-start; }
  .doc-card .thumb { width: 100%; max-width: 220px; }
  h1 { font-size: 2rem; }
  h2 { font-size: 1.6rem; }
}

@media (max-width: 430px) {
  .brand .brand-name { font-size: 1.1rem; }
  .brand { min-height: 44px; }
  .brand .brand-sub  { font-size: 0.7rem; letter-spacing: 0.06em; line-height: 1.25; }
  .brand .brand-sep { display: none; }
  .brand .brand-phase { display: block; }
  .brand .mark { width: 38px; height: 38px; }
}

/* Narrowest phones (e.g., 320px): tighten the header so the Menu button stays on screen */
@media (max-width: 360px) {
  .header-inner { padding-left: 1rem; padding-right: 1rem; gap: 0.5rem; }
  .brand { gap: 0.5rem; }
  .brand .mark { width: 32px; height: 32px; }
  .brand .brand-sub { font-size: 0.65rem; letter-spacing: 0.04em; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
