/* Desert Midwives site
   Layout: sunrise-mesa hero band, then calm sand pages; forms in a single readable column.
   Palette follows the Desert Midwives flyers; fonts are shared with midwives-at-the-edges.org. */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,600;9..144,700&family=Nunito:wght@400;600;700&display=swap');

:root {
  --terracotta: #B4552D;
  --terracotta-dark: #933F1E;
  --teal: #1F5E5B;
  --teal-soft: #E3EEEC;
  --gold: #C99228;
  --navy: #1C2B3A;
  --sand: #F2E4CB;
  --paper: #FBF6EE;
  --card: #FFFFFF;
  --ink: #2B2118;
  --muted: #6A5848;
  --line: #E2D3BA;
  --good: #2F7A4F;
  --warn: #B07A12;
  --bad: #A23B2A;
  --focus: #1F5E5B;
  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body: 'Nunito', -apple-system, 'Segoe UI', system-ui, sans-serif;
  --radius: 10px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --terracotta: #E07B4F; --terracotta-dark: #F09A70; --teal: #5FB3AC; --teal-soft: #17302F;
    --gold: #E2B355; --navy: #0F1822; --sand: #2A2119; --paper: #1B1612; --card: #241D17;
    --ink: #F3EADB; --muted: #C3B29C; --line: #3D3227; --good: #6CC08F; --warn: #E2B355; --bad: #EF8A76; --focus: #5FB3AC;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --terracotta: #E07B4F; --terracotta-dark: #F09A70; --teal: #5FB3AC; --teal-soft: #17302F;
  --gold: #E2B355; --navy: #0F1822; --sand: #2A2119; --paper: #1B1612; --card: #241D17;
  --ink: #F3EADB; --muted: #C3B29C; --line: #3D3227; --good: #6CC08F; --warn: #E2B355; --bad: #EF8A76; --focus: #5FB3AC;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--paper); color: var(--ink); font: 17px/1.65 var(--font-body); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
[hidden] { display: none !important; }
a { color: var(--terracotta-dark); text-underline-offset: 3px; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.15; text-wrap: balance; margin: 0; color: var(--ink); }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); font-weight: 700; }
h2 { font-size: clamp(1.45rem, 3vw, 2rem); font-weight: 600; }
h3 { font-size: 1.15rem; font-weight: 600; }
p { margin: 0; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

.wrap { max-width: 1080px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.prose { max-width: 680px; }
.eyebrow { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 700; color: var(--terracotta); }

/* Header */
.site-header { background: var(--card); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 10px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand img { width: 52px; }
.brand-name { font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; line-height: 1.1; display: block; }
.brand-sub { font-size: .78rem; color: var(--muted); display: block; }
.nav { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.nav a { text-decoration: none; color: var(--ink); font-weight: 600; font-size: .95rem; padding: 8px 12px; border-radius: 999px; }
.nav a:hover, .nav a[aria-current="page"] { background: var(--sand); }
.nav a.nav-cta { background: var(--terracotta); color: #fff; }
.nav a.nav-cta:hover { background: var(--terracotta-dark); }

/* Hero */
.hero { position: relative; background: linear-gradient(180deg, #F6C88E 0%, #EFA36A 55%, #D9774A 100%); color: #2B2118; overflow: hidden; }
.hero .wrap { position: relative; z-index: 1; padding-block: 56px 132px; }
.hero h1 { color: #2B2118; max-width: 20ch; }
.hero .lede { font-size: 1.15rem; max-width: 56ch; margin-top: 16px; }
.hero .actions { margin-top: 26px; display: flex; gap: 12px; flex-wrap: wrap; }
.hero svg.mesa { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: 120px; }
.hero .sun { position: absolute; right: 9%; top: 38px; width: 150px; height: 150px; border-radius: 50%; background: #FBE3B8; opacity: .55; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font: 700 1rem var(--font-body); padding: 12px 22px; border-radius: 999px; border: 2px solid transparent; cursor: pointer; text-decoration: none; }
.btn-primary { background: var(--teal); color: #fff; }
.btn-primary:hover { filter: brightness(1.1); }
.btn-light { background: #FFF8EC; color: #2B2118; border-color: #2B2118; }
.btn-outline { background: transparent; color: var(--ink); border-color: var(--line); }
.btn[disabled] { opacity: .6; cursor: progress; }

section.band { padding-block: 64px; }
section.band.alt { background: var(--sand); }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; margin-top: 28px; }
.element { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; display: grid; gap: 8px; align-content: start; }
.element .tag { font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--teal); }
.counties { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.chip { display: inline-block; padding: 6px 12px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-weight: 600; font-size: .9rem; }
.split { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: start; }
.split > * { min-width: 0; }
@media (max-width: 760px) { .split { grid-template-columns: 1fr; gap: 24px; } }
.quote { font-family: var(--font-display); font-size: 1.3rem; line-height: 1.4; border-left: 4px solid var(--gold); padding-left: 18px; }

.cta-band { background: var(--teal); color: #fff; }
.cta-band .wrap { padding-block: 48px; display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.cta-band h2 { color: #fff; }

/* Page title band (inner pages) */
.page-head { background: var(--sand); border-bottom: 1px solid var(--line); }
.page-head .wrap { padding-block: 40px 32px; display: grid; gap: 10px; }
.page-head p { max-width: 62ch; color: var(--muted); }

/* Forms */
.form-layout { display: grid; grid-template-columns: minmax(0, 640px) minmax(0, 300px); gap: 40px; padding-block: 40px 64px; }
@media (max-width: 900px) { .form-layout { grid-template-columns: 1fr; } }
.form { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(18px, 4vw, 32px); display: grid; gap: 20px; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .row-2 { grid-template-columns: 1fr; } }
.field { display: grid; gap: 6px; }
.field > label, .field legend { font-weight: 700; font-size: .95rem; }
fieldset.field { border: 0; padding: 0; margin: 0; }
.req { color: var(--terracotta); }
.hint { font-size: .85rem; color: var(--muted); font-weight: 400; }
input[type=text], input[type=email], input[type=tel], input[type=number], select, textarea {
  width: 100%; font: inherit; color: var(--ink); background: var(--paper); border: 1.5px solid var(--line); border-radius: 8px; padding: 10px 12px;
}
textarea { min-height: 110px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--teal); outline: none; box-shadow: 0 0 0 3px var(--teal-soft); }
.choices { display: flex; flex-wrap: wrap; gap: 8px; }
.choices.stack { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.choice { display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 8px; cursor: pointer; background: var(--paper); font-weight: 600; font-size: .95rem; }
.choice input { margin-top: 4px; accent-color: var(--teal); }
.choice:has(input:checked) { border-color: var(--teal); background: var(--teal-soft); }
.weeks-row { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.weeks-row input[type=number] { width: 110px; }
.inline-check { display: flex; gap: 8px; align-items: center; font-weight: 600; font-size: .95rem; }
.inline-check input { accent-color: var(--teal); }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; }
.consent input { margin-top: 5px; accent-color: var(--teal); }
.error-msg { color: var(--bad); font-size: .85rem; font-weight: 700; }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: var(--bad); }
.field.invalid .choices .choice { border-color: var(--bad); }
.honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { font-weight: 700; }
.form-status.err { color: var(--bad); }
.thanks { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; display: grid; gap: 14px; }
.side { display: grid; gap: 18px; align-content: start; }
.side-card { background: var(--sand); border-radius: var(--radius); padding: 20px; display: grid; gap: 8px; font-size: .95rem; }
.side-card h3 { font-size: 1.05rem; }
.demo-note { font-size: .82rem; color: var(--muted); border: 1px dashed var(--line); border-radius: 8px; padding: 10px 12px; }

/* Booking */
.book-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 4vw, 32px); display: grid; gap: 16px; }
.steps { margin: 0; padding-left: 1.2em; display: grid; gap: 6px; }
.slot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.slot { padding: 10px; border: 1.5px solid var(--line); border-radius: 8px; text-align: center; font-weight: 700; font-size: .92rem; background: var(--paper); }
.day-label { font-weight: 700; margin-top: 6px; }

/* Footer */
.site-footer { background: var(--navy); color: #E9E1D3; }
.site-footer .wrap { padding-block: 36px; display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; font-size: .92rem; }
.site-footer a { color: #F6C88E; }
.site-footer strong { font-family: var(--font-display); font-size: 1.1rem; color: #fff; }

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

/* Donate (Donorbox popup, same as midwives-at-the-edges.org) */
.nav a.nav-donate { background: var(--gold); color: #2B2118; }
.nav a.nav-donate:hover { filter: brightness(1.08); background: var(--gold); }
.btn-gold { background: var(--gold); color: #2B2118; }
.btn-gold:hover { filter: brightness(1.08); }
