/* ============================================================
   No. 3 Park West Association — shared stylesheet
   Sonoran desert palette. Mobile-first. No build step.
   ============================================================ */

:root {
  --sand:        #f4ede2;   /* page background */
  --sand-2:      #ece0cf;   /* alternating section */
  --paper:       #fffdf9;   /* cards */
  --ink:         #2b2420;   /* body text */
  --ink-soft:    #5a4f45;   /* secondary text */
  --clay:        #a8471f;   /* primary accent (saguaro-flower red-clay) */
  --clay-dark:   #7f3417;   /* hover */
  --sage:        #5b6b4d;   /* desert sage — links / secondary accent */
  --sage-dark:   #45543a;
  --sky:         #3c6e8f;   /* dusk-sky blue — info accents */
  --line:        #d8c9b3;   /* borders */
  --gold:        #c98a2b;   /* saguaro-sun highlight */
  --shadow:      0 2px 4px rgba(43,36,32,.06), 0 8px 24px rgba(43,36,32,.08);
  --nav-h:       66px;
  --wrap:        1040px;
}

* { box-sizing: border-box; }
/* Makes the hidden attribute reliable (e.g. the switched-off announcement slot). */
[hidden] { display: none !important; }

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

body {
  margin: 0;
  font-family: 'Source Sans 3', system-ui, -apple-system, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--sand);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: 'Fraunces', Georgia, serif;
  line-height: 1.15;
  color: var(--ink);
  font-weight: 600;
}

a { color: var(--clay); text-decoration-thickness: 1px; text-underline-offset: 2px; }
/* A phone number must never break across lines ("520-" / "791-5843"). */
a[href^="tel:"] { white-space: nowrap; }
a:hover { color: var(--clay-dark); }

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

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }

/* ---------- Skip link (a11y) ---------- */
.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: #fff; padding: 10px 16px; z-index: 200;
}
.skip:focus { left: 8px; top: 8px; }

/* ---------- Keyboard focus (a11y) ----------
   A single, on-brand focus ring for keyboard and screen-reader users. Uses
   :focus-visible, so mouse/touch users never see it — it appears only when a
   control is reached by keyboard. The outline follows each element's own
   corner radius, so cards and buttons keep their shape. */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
.card:focus-visible,
.doc:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2.5px solid var(--clay);
  outline-offset: 3px;
}
/* On dark surfaces (nav, footer, hero) clay is too low-contrast; switch the
   ring to saguaro-gold so it stays visible. */
.nav :focus-visible,
.footer :focus-visible,
.hero :focus-visible { outline-color: var(--gold); }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--ink);
  border-bottom: 3px solid var(--clay);
}
.nav-inner {
  max-width: var(--wrap); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  min-height: var(--nav-h); padding: 0 22px;
}
.brand {
  font-family: 'Fraunces', serif; font-weight: 600;
  color: #fff; text-decoration: none; font-size: 18px; line-height: 1.1;
  letter-spacing: .01em;
  /* padding lifts the tap target to 44px+ on phones */
  display: block; padding: 6px 0;
}
.brand:hover { color: #fff; }
.brand small { display: block; font-family: 'Source Sans 3', sans-serif;
  font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--gold); font-weight: 600; margin-top: 3px; }

.nav-toggle {
  display: none; background: none; border: 0; cursor: pointer;
  width: 44px; height: 44px; padding: 10px; margin-right: -10px;
}
.nav-toggle span { display: block; height: 2px; background: #fff; margin: 5px 0;
  transition: transform .2s, opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-links { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-links a {
  /* 11px vertical clears the 44px tap-target minimum on the desktop nav; the
     header has room (min-height 66px), so this costs no layout. */
  display: block; padding: 11px 12px; color: #e8ddcb; text-decoration: none;
  font-size: 14.5px; font-weight: 600; border-radius: 4px;
  letter-spacing: .01em; transition: background .15s, color .15s;
}
.nav-links a:hover { background: rgba(255,255,255,.08); color: #fff; }
.nav-links a[aria-current="page"] { color: var(--gold); }

/* ---------- Page header band ---------- */
.pagehead {
  background: var(--sand-2);
  border-bottom: 1px solid var(--line);
  padding: 34px 0 30px;
}
.pagehead h1 { font-size: clamp(1.7rem, 5vw, 2.5rem); margin: 0 0 6px; letter-spacing: -.012em; }
.pagehead p { margin: 0; color: var(--ink-soft); font-size: 16px; }
.eyebrow {
  font-family: 'Source Sans 3', sans-serif; font-size: 12px; font-weight: 700;
  letter-spacing: .18em; text-transform: uppercase; color: var(--clay);
  margin: 0 0 8px;
}

/* ---------- Hero (home) ---------- */
.hero {
  /* The map behind this is fine line-art; it needs a heavy scrim or the
     headline becomes unreadable. Don't lighten these values much. */
  background:
    linear-gradient(180deg, rgba(43,36,32,.93), rgba(43,36,32,.88)),
    var(--hero-img, #6b4a2f) center/cover no-repeat;
  color: #fff; padding: 72px 0 66px;
}
.hero h1 { color: #fff; font-size: clamp(2rem, 6vw, 3.1rem); margin: 0 0 12px; max-width: 18ch; letter-spacing: -.015em; }
.hero p { color: #f2e9db; font-size: 18px; max-width: 46ch; margin: 0 0 26px; }
.hero .eyebrow { color: var(--gold); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px; justify-content: center;
  padding: 12px 22px; min-height: 46px; border-radius: 6px;
  font-family: 'Source Sans 3', sans-serif; font-size: 15.5px; font-weight: 700;
  text-decoration: none; cursor: pointer; border: 2px solid transparent;
  transition: transform .06s, background .15s, border-color .15s;
}
.btn:active { transform: scale(.985); }
.btn-primary { background: var(--clay); color: #fff; }
.btn-primary:hover { background: var(--clay-dark); color: #fff; }
.btn-outline { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.btn-outline:hover { border-color: #fff; color: #fff; background: rgba(255,255,255,.08); }
.btn-ghost { background: var(--paper); color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--clay); color: var(--clay-dark); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Sections ---------- */
section { padding: 44px 0; }
.section-alt { background: var(--sand-2); }
.section-paper { background: var(--paper); }
.lead { font-size: 19px; color: var(--ink-soft); max-width: 62ch; }

h2.section-title { font-size: clamp(1.5rem, 4vw, 2rem); margin: 0 0 6px; letter-spacing: -.012em; }
.section-sub { color: var(--ink-soft); margin: 0 0 26px; max-width: 60ch; }

/* ---------- Cards / grids ---------- */
.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: 10px;
  padding: 22px 22px 20px; box-shadow: var(--shadow);
  transition: border-color .15s, transform .12s ease;
}
.card h3 { margin: 0 0 8px; font-size: 1.15rem; }
.card p { margin: 0 0 4px; color: var(--ink-soft); font-size: 15.5px; }
.card .icon {
  width: 40px; height: 40px; border-radius: 8px; display: grid; place-items: center;
  background: var(--sand-2); color: var(--clay); margin-bottom: 14px;
}
.card .icon svg { width: 22px; height: 22px; }

/* ---------- Document / download list ---------- */
.doclist { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.doc {
  display: flex; align-items: center; gap: 14px;
  background: var(--paper); border: 1px solid var(--line); border-radius: 9px;
  padding: 14px 16px; box-shadow: var(--shadow); text-decoration: none; color: var(--ink);
  transition: border-color .15s, transform .12s ease;
}

/* ---------- Unified hover for clickable Paper surfaces (cards + doc rows) ----------
   Both are <a> tiles on Paper with a Line border. One shared response: the
   border warms to clay and the tile lifts 2px toward the reader; pressing
   settles it back down. Shadow stays constant (see the Tonal-Depth Rule); the
   color:var(--ink) reset cancels the global a:hover reddening on headings. */
.card:hover,
.doc:hover {
  border-color: var(--clay);
  color: var(--ink);
  transform: translateY(-2px);
}
.card:active,
.doc:active {
  transform: translateY(0);
  transition-duration: .05s;
}
.doc .doc-ico {
  flex: 0 0 auto; width: 42px; height: 42px; border-radius: 7px;
  background: var(--sand-2); color: var(--clay); display: grid; place-items: center;
}
.doc .doc-ico svg { width: 22px; height: 22px; }
.doc .doc-body { flex: 1 1 auto; min-width: 0; }
.doc .doc-title { font-weight: 700; font-size: 16px; display: block; line-height: 1.3; }
.doc .doc-meta { font-size: 13px; color: var(--ink-soft); }
.doc .doc-arrow { flex: 0 0 auto; color: var(--sage); }

/* Archive entry (dated) */
.entry {
  background: var(--paper); border: 1px solid var(--line); border-left: 4px solid var(--clay);
  border-radius: 8px; padding: 16px 18px; box-shadow: var(--shadow);
}
.entry .date {
  font-family: 'Source Sans 3', sans-serif; font-size: 12px; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase; color: var(--clay);
}
.entry h3 { margin: 4px 0 6px; font-size: 1.15rem; }
.entry p { margin: 0 0 10px; color: var(--ink-soft); font-size: 15.5px; }

/* ---------- Callout / notice ---------- */
.notice {
  background: var(--sand-2); border: 1px solid var(--line); border-radius: 10px;
  padding: 20px 22px;
}
.notice.accent { border-left: 4px solid var(--gold); }
.notice h3 { margin: 0 0 6px; }
.notice p { margin: 0 0 6px; color: var(--ink-soft); }
.notice p:last-child { margin-bottom: 0; }

.meeting-dates { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 8px; }
.meeting-dates li {
  display: flex; gap: 10px; align-items: baseline;
  padding: 8px 0; border-bottom: 1px dashed var(--line);
}
.meeting-dates li:last-child { border-bottom: 0; }
.meeting-dates .md-date { font-weight: 700; color: var(--ink); min-width: 148px; }
.meeting-dates .md-where { color: var(--ink-soft); font-size: 15px; }

/* ---------- Contact table ---------- */
.contacts { display: grid; gap: 14px; }
.contact-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: 9px;
  padding: 16px 18px; box-shadow: var(--shadow);
}
.contact-card .role {
  font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--sage-dark); margin: 0 0 3px;
}
.contact-card .name { font-weight: 700; font-size: 17px; margin: 0 0 4px; }
/* inline-block + padding keeps these email/phone links at a 44px+ tap target */
.contact-card a { font-size: 15px; word-break: break-word; display: inline-block; padding: 12px 0; }
.contact-card .ph { color: var(--ink-soft); font-size: 15px; margin: 0; }
.contact-card .ph a { color: var(--ink-soft); }

/* ---------- City services (definition-style) ---------- */
.svc { display: grid; gap: 16px; }
.svc-item {
  background: var(--paper); border: 1px solid var(--line); border-radius: 9px;
  padding: 16px 18px; box-shadow: var(--shadow);
}
.svc-item h3 { margin: 0 0 6px; font-size: 1.05rem; }
/* Cap the measure like the rest of the site (60-66ch), so descriptions wrap into
   balanced lines instead of one long line plus an orphaned fragment.
   text-wrap: pretty further avoids single-word last lines where supported. */
.svc-item p { margin: 0; color: var(--ink-soft); font-size: 15.5px; max-width: 66ch; text-wrap: pretty; }
.svc-item .contact-line { margin-top: 8px; font-weight: 600; color: var(--ink); font-size: 15px; max-width: none; }

/* ---------- Forms (Web3Forms) ---------- */
.form-wrap {
  background: var(--paper); border: 1px solid var(--line); border-radius: 12px;
  padding: 26px 24px; box-shadow: var(--shadow); max-width: 620px;
}
.contact-form .form-field { margin-bottom: 16px; }
.contact-form label {
  display: block; font-size: 12px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--sage-dark); margin-bottom: 6px;
}
.contact-form label .req { color: var(--clay); margin-left: 2px; }
.contact-form label .optional {
  text-transform: none; letter-spacing: .02em; font-style: italic;
  font-size: 11.5px; color: var(--ink-soft); font-weight: 500; margin-left: 5px;
}
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"],
.contact-form select,
.contact-form textarea {
  width: 100%; padding: 11px 13px; background: var(--sand);
  border: 2px solid var(--line); border-radius: 6px; color: var(--ink);
  font-family: inherit; font-size: 16px; -webkit-appearance: none; appearance: none;
  transition: border-color .15s;
}
/* Border shifts to clay on any focus; the outline is suppressed only for
   pointer focus so the :focus-visible ring above still shows for keyboards. */
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus { border-color: var(--clay); }
.contact-form input:focus:not(:focus-visible),
.contact-form select:focus:not(:focus-visible),
.contact-form textarea:focus:not(:focus-visible) { outline: none; }
.contact-form textarea { resize: vertical; min-height: 120px; line-height: 1.55; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.honeypot { position: absolute !important; left: -9999px !important;
  width: 1px !important; height: 1px !important; opacity: 0; }
.form-status { margin-top: 12px; font-size: 15px; font-weight: 600; }
.form-status.err { color: var(--clay-dark); }
.form-success {
  background: #eef3e8; border: 1px solid #b9cda2; border-radius: 10px;
  padding: 24px; text-align: center;
}
.form-success .mark {
  width: 46px; height: 46px; border-radius: 50%; background: var(--sage);
  color: #fff; display: grid; place-items: center; font-size: 24px; margin: 0 auto 12px;
}
.form-success h3 { margin: 0 0 6px; }
.form-success p { margin: 0; color: var(--ink-soft); }

/* ---------- Footer ---------- */
.footer {
  background: var(--ink); color: #d8ccb8; padding: 44px 0 28px; margin-top: 12px;
  border-top: 3px solid var(--clay);
}
.footer a { color: var(--gold); }
/* The email link sits on its own line, so inline-block padding grows the tap
   target to 44px+ without pushing the surrounding text around. */
.footer p a { display: inline-block; padding: 12px 0; }
.footer .foot-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px 48px; }
.footer h4 {
  color: #fff; font-family: 'Fraunces', serif; font-size: 1.05rem; margin: 0 0 14px;
  /* small caps-ish label rhythm, so both column headings read as peers */
  letter-spacing: .01em;
}
.footer p { margin: 0 0 6px; font-size: 14.5px; line-height: 1.6; max-width: 44ch; }

/* One column on phones — "Minutes & Newsletters" needs the full width there. */
.footer .foot-links {
  list-style: none; padding: 0; margin: 0;
  display: grid; grid-template-columns: 1fr; row-gap: 0;
}
/* display:block + padding gives each link a 44px+ tap target on phones.
   The padding replaces the old grid gap — don't add both back. */
.footer .foot-links a {
  text-decoration: none; font-size: 14.5px; display: block; padding: 12px 0;
  border-bottom: 1px solid transparent;   /* reserves space so hover doesn't shift */
}
.footer .foot-links a:hover { text-decoration: none; border-bottom-color: currentColor; }

/* Above the stacking breakpoint, split the list into two columns. grid-auto-flow
   keeps it reading top-to-bottom then across (Home, Documents, Financials...)
   rather than snaking left-to-right, which is how people scan a list of links.
   Four rows means 4 items left, 3 right — which also happens to match the height
   of the address block beside it. */
@media (min-width: 821px) {
  .footer .foot-links {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(4, auto);
    grid-auto-flow: column;
    column-gap: 20px;
  }
}
.footer .legal {
  margin-top: 30px; padding-top: 16px; border-top: 1px solid rgba(255,255,255,.12);
  font-size: 13px; color: #a99b85;
  max-width: none;   /* overrides the 44ch measure on .footer p — this rule spans the page */
}

/* ---------- Utility ---------- */
.mt-0 { margin-top: 0; } .mb-0 { margin-bottom: 0; }
.prose p { max-width: 66ch; }
.prose h2 { margin-top: 30px; }
.prose h3 { margin: 22px 0 6px; font-size: 1.1rem; }
.prose ul, .prose ol { max-width: 66ch; padding-left: 1.4em; }
.prose li { margin: 0 0 6px; }
/* Quoted passages (e.g. CC&R excerpts in a newsletter): sage rule, softer ink. */
.prose blockquote {
  margin: 16px 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--sage);
  color: var(--ink-soft); max-width: 66ch;
}
.prose blockquote p { margin: 0; font-size: 15.5px; }
.center { text-align: center; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 820px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .footer .foot-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none; position: absolute; top: var(--nav-h); left: 0; right: 0;
    flex-direction: column; gap: 0; background: var(--ink);
    border-bottom: 3px solid var(--clay); padding: 8px 12px 16px;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 13px 12px; font-size: 16px; border-radius: 6px; }
  .form-row { grid-template-columns: 1fr; }
  .btn { width: 100%; }
  .btn-row .btn { width: auto; }
  .hero .btn-row .btn { width: 100%; }
}

@media (max-width: 400px) {
  body { font-size: 16px; }
  .wrap { padding: 0 16px; }
  .nav-inner { padding: 0 16px; }
}

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