/* Austin Area Firewise Alliance — rpdiscoverer.com
   Single stylesheet, no build step.

   Palette taken from the AAFA logo: deep green badge, sage ring, orange
   flame, peach highlight. Orange is reserved for emphasis and action —
   never for large fields of color, because on a wildfire site an orange
   block reads as an alert whether or not one is intended. */

:root {
    --green-900: #19462b;
    --green-700: #265438;
    --green-500: #4c784b;
    --sage: #8ca295;
    --sage-text: #5c7265;   /* 4.97:1 on the page background; --sage is 2.6:1 */
    --sage-200: #d7e0d9;
    /* Two oranges on purpose. --orange is the brand tone, used only for
       decoration: dots, rules, card top-borders, focus rings. It is too light
       to carry text (white on it is 3.06:1, well under the 4.5:1 AA needs).
       --orange-dark is the text/action tone: 5.29:1 with white, 4.7:1 on the
       alert background. Anything with words in it uses the dark one. */
    --orange: #da7b37;
    --orange-dark: #a85512;
    --orange-darker: #8f4409;
    --peach: #edbd9b;

    --ink: #1d2a21;
    --muted: #566;
    --page: #fbfaf7;
    --card: #ffffff;
    --line: #e2e0d8;

    --alert-bg: #FDF0E4;
    --alert-line: var(--orange);

    --wrap: 1140px;
    --radius: 12px;
    --shadow: 0 8px 26px rgba(25, 70, 43, .08);
}

* { box-sizing: border-box; }

/* Root size is the hook the Aa control turns. Everything sized in rem
   follows it. 100% (not a px value) is deliberate: it inherits whatever the
   reader has already set as their browser's default font size, so someone who
   configured that once — often the people who need it most — keeps it, and
   the Aa control multiplies from there rather than overriding them. */
html {
    scroll-behavior: smooth;
    font-size: calc(100% * var(--text-scale, 1));
}

body {
    margin: 0;
    background: var(--page);
    color: var(--ink);
    font: 400 1.0625rem/1.65 "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    font-family: Oswald, "Arial Narrow", Ubuntu, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.18;
    margin: 0 0 .5em;
    letter-spacing: .01em;
}

h1 { font-size: clamp(2.1rem, 1.2rem + 2.6vw, 3.2rem); font-weight: 600; text-transform: uppercase; }
h2 { font-size: clamp(1.55rem, 0.9rem + 1.7vw, 2.15rem); font-weight: 600; }
h3 { font-size: 1.18rem; font-weight: 500; }
h4 { font-size: 1rem; font-weight: 600; }

p { margin: 0 0 1em; }

a { color: var(--green-700); }
a:hover { color: var(--orange-dark); }

img { max-width: 100%; }

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

section[id] { scroll-margin-top: 92px; }

.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;
}

/* ---------- Keyboard access ----------

   Skip link: every page repeats the emergency strip, the conditions banner,
   the brand, and five nav links before the content starts. Someone tabbing
   through — or listening to a screen reader — should not have to walk all of
   that on every page. Hidden until focused, then it lands in the top-left.

   Focus ring: the browser default is easy to lose against these backgrounds,
   and it disappears entirely on elements that get a custom background. Using
   :focus-visible means pointer users never see it and keyboard users always
   do. Applied globally rather than per-component so a new link added later
   inherits it without anyone remembering to. */

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 100;
    background: var(--green-900);
    color: #fff;
    padding: 12px 18px;
    border-radius: 0 0 8px 0;
    font-weight: 700;
    text-decoration: none;
}

.skip-link:focus {
    left: 0;
    color: #fff;
}

:focus-visible {
    outline: 3px solid var(--orange-dark);
    outline-offset: 2px;
    border-radius: 3px;
}

/* On the dark green sections the dark orange ring is hard to see. */
.deep :focus-visible,
.emergency :focus-visible,
.site-footer :focus-visible {
    outline-color: var(--peach);
}

/* ---------- Emergency strip ----------
   Always first in the DOM. On a wildfire site the 911 line outranks
   everything else on the page, including the branding. */

.emergency {
    background: var(--green-900);
    color: #fff;
    font-size: .93rem;
    text-align: center;
    padding: 9px 20px;
}

.emergency strong { color: var(--peach); }
.emergency a { color: #fff; }

/* ---------- Conditions banner ----------
   Current fire conditions / burn ban. Edit or remove per season. */

.conditions {
    background: var(--alert-bg);
    border-bottom: 3px solid var(--alert-line);
    padding: 12px 20px;
    font-size: .97rem;
}

.conditions .wrap {
    display: flex;
    gap: 12px;
    align-items: baseline;
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
}

.conditions .label {
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .07em;
    font-size: .78rem;
    color: var(--orange-dark);
}

/* ---------- Header ---------- */

.site-header {
    position: sticky;
    top: 0;
    z-index: 30;
    background: rgba(251, 250, 247, .96);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--line);
}

.site-header .wrap {
    display: flex;
    align-items: center;
    gap: 18px;
    min-height: 72px;
    flex-wrap: wrap;
}

.brand {
    display: flex;
    align-items: center;
    gap: 11px;
    text-decoration: none;
    color: var(--green-900);
}

.brand img { height: 42px; width: auto; }

.brand .brand-text {
    font-family: Oswald, "Arial Narrow", sans-serif;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 1.02rem;
    line-height: 1.1;
    letter-spacing: .02em;
    color: var(--orange-dark);
}

.brand .brand-text span {
    display: block;
    font-size: .66rem;
    letter-spacing: .13em;
    color: var(--sage-text);
}

.site-nav {
    margin-left: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    align-items: center;
}

.site-nav a {
    color: var(--green-900);
    text-decoration: none;
    font-size: .95rem;
    font-weight: 600;
    padding: 4px 0;
    border-bottom: 2px solid transparent;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
    color: var(--orange-dark);
    border-bottom-color: var(--orange);
}

/* ---------- Text size control ----------

   Browser zoom already does this and does it better. This exists for
   discoverability: the audience here skews older, and Ctrl+ is not something
   everyone knows. Three steps rather than a slider, because a slider invites
   fiddling and every intermediate value is a layout we never checked.

   Each button shows its own effect — the letters are literally sized to what
   they do — so the control explains itself without instructions.

   The label is a word, not an "Aa" glyph. "Aa" was the same letterform as the
   buttons beside it, so the row read as four controls rather than a label plus
   three. It is also the readers least fluent with the web who most need this
   control, and they are the least likely to recognise ascending A's as a size
   picker. Below 640px the label drops and the three A's stand alone, which is
   the conventional pattern and needs the room more than it needs the word. */

.text-size {
    display: flex;
    align-items: center;
    gap: 1px;
    border: 1px solid var(--line);
    border-radius: 7px;
    padding: 2px;
    background: var(--card);
}

.text-size .label {
    font-family: Oswald, "Arial Narrow", sans-serif;
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--sage-text);
    padding: 0 6px 0 4px;
    white-space: nowrap;
}

.text-size button {
    font-family: Oswald, "Arial Narrow", sans-serif;
    font-weight: 500;
    line-height: 1;
    color: var(--green-900);
    background: transparent;
    border: 1px solid transparent;
    border-radius: 5px;
    cursor: pointer;

    /* 24x24 is the floor, not a starting point: WCAG 2.5.8 sets it as the
       minimum target size, and this particular control exists for readers
       who may also have less steady hands. Everything else here shrank;
       the tap target did not. Padding is zero because the box is sized
       directly — letting the three different font sizes set the box would
       make three differently-sized targets. */
    display: grid;
    place-items: center;
    min-width: 24px;
    min-height: 24px;
    padding: 0 3px;
}

.text-size button:hover { background: var(--sage-200); }

.text-size button[aria-pressed="true"] {
    background: var(--green-700);
    border-color: var(--green-700);
    color: #fff;
}

.text-size .s1 { font-size: .72rem; }
.text-size .s2 { font-size: .95rem; }
.text-size .s3 { font-size: 1.2rem; }

@media (max-width: 640px) {
    /* Sit beside the brand rather than below the nav. The nav takes the full
       width and wraps to two lines on a phone, so a control placed after it
       claims a third row of permanently-sticky height — about 44px that never
       scrolls away. There is unused space to the right of the brand; put it
       there. */
    .text-size { order: 2; margin-left: auto; }
    .text-size .label { display: none; }
    .site-nav { order: 3; }
}

/* ---------- Buttons ---------- */

.btn {
    display: inline-block;
    padding: 13px 22px;
    border-radius: 8px;
    font-weight: 700;
    font-size: .98rem;
    text-decoration: none;
    border: 2px solid transparent;
    cursor: pointer;
    font-family: inherit;
    transition: transform .12s ease, background-color .12s ease;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary {
    background: var(--orange-dark);
    color: #fff;
    border-color: var(--orange-dark);
}

.btn-primary:hover { background: var(--orange-darker); border-color: var(--orange-darker); color: #fff; }

.btn-green {
    background: var(--green-700);
    color: #fff;
    border-color: var(--green-700);
}

.btn-green:hover { background: var(--green-900); border-color: var(--green-900); color: #fff; }

.btn-outline {
    background: #fff;
    border-color: var(--green-700);
    color: var(--green-900);
}

.btn-outline:hover { background: var(--sage-200); color: var(--green-900); }

/* ---------- Hero ---------- */

.hero {
    padding: 64px 0 52px;
    background:
        linear-gradient(180deg, rgba(140, 162, 149, .18), rgba(251, 250, 247, 0) 70%),
        var(--page);
    border-bottom: 1px solid var(--line);
}

.hero .kicker,
.page-head .kicker {
    text-transform: uppercase;
    letter-spacing: .14em;
    font-size: .78rem;
    font-weight: 700;
    color: var(--green-500);
    margin-bottom: 10px;
}

.hero .lede { font-size: 1.16rem; color: var(--muted); max-width: 64ch; }

.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

/* Interior page header, smaller than the home hero. */
.page-head {
    padding: 44px 0 30px;
    background: linear-gradient(180deg, rgba(140, 162, 149, .16), rgba(251, 250, 247, 0));
    border-bottom: 1px solid var(--line);
}

.page-head h1 { font-size: clamp(1.8rem, 1rem + 2.2vw, 2.6rem); }
.page-head p { color: var(--muted); max-width: 68ch; margin-bottom: 0; }

/* ---------- Sections ---------- */

section { padding: 52px 0; }

.section-head { max-width: 72ch; margin-bottom: 26px; }
.section-head p { color: var(--muted); margin-bottom: 0; }

.alt { background: #f3f5f2; border-block: 1px solid var(--line); }
.deep { background: var(--green-900); color: #eef2ee; }
.deep h2, .deep h3 { color: #fff; }
.deep a { color: var(--peach); }
.deep .section-head p { color: #c8d4ca; }

/* ---------- Cards ---------- */

.grid {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid.two { grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); }

.card {
    background: var(--card);
    border: 1px solid var(--line);
    border-top: 4px solid var(--green-700);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow);
}

.card.accent { border-top-color: var(--orange); }

.card h3 { margin-bottom: .4em; }
.card p:last-child { margin-bottom: 0; }
.card p { color: var(--muted); font-size: .97rem; }

.card .tag {
    display: inline-block;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .09em;
    text-transform: uppercase;
    color: var(--orange-dark);
    margin-bottom: 9px;
}

.deep .card {
    background: rgba(255, 255, 255, .06);
    border-color: rgba(255, 255, 255, .18);
    border-top-color: var(--peach);
    box-shadow: none;
}

.deep .card p { color: #c8d4ca; }

/* ---------- Quick actions ---------- */

.actions {
    display: grid;
    gap: 11px;
    grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
}

.action {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 9px;
    padding: 15px 17px;
    text-decoration: none;
    color: var(--ink);
    font-weight: 600;
    font-size: .96rem;
    transition: border-color .12s ease, transform .12s ease;
}

.action:hover { border-color: var(--orange); transform: translateY(-1px); color: var(--ink); }

.action .dot {
    width: 9px; height: 9px;
    border-radius: 50%;
    background: var(--green-500);
    flex: 0 0 auto;
}

.action:nth-child(3n+2) .dot { background: var(--orange); }
.action:nth-child(3n+3) .dot { background: var(--sage); }

/* External-link marker, so people know they are leaving the Alliance site
   for an official source. */
.ext::after {
    content: " ↗";
    font-size: .82em;
    color: var(--sage-text);
}

/* ---------- Zones (defensible space) ---------- */

.zones { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); }

.zone {
    background: var(--card);
    border: 1px solid var(--line);
    border-left: 6px solid var(--orange);
    border-radius: 10px;
    padding: 20px;
}

.zone:nth-child(2) { border-left-color: var(--green-500); }
.zone:nth-child(3) { border-left-color: var(--sage); }

.zone .dist {
    font-family: Oswald, sans-serif;
    font-size: 1.5rem;
    color: var(--green-900);
    display: block;
    margin-bottom: 2px;
}

.zone ul { margin: 10px 0 0; padding-left: 18px; color: var(--muted); font-size: .95rem; }
.zone li { margin-bottom: 6px; }

/* ---------- Checklist / steps ---------- */

.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: 11px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

.checklist li {
    background: var(--card);
    border: 1px solid var(--line);
    border-left: 4px solid var(--green-500);
    border-radius: 9px;
    padding: 15px 17px;
    color: var(--muted);
    font-size: .96rem;
}

.checklist strong { color: var(--ink); display: block; font-size: 1rem; }

.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }

.steps li {
    counter-increment: step;
    display: grid;
    grid-template-columns: 42px 1fr;
    gap: 16px;
    align-items: start;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 18px 20px;
}

.steps li::before {
    content: counter(step);
    font-family: Oswald, sans-serif;
    font-size: 1.3rem;
    color: #fff;
    background: var(--green-700);
    width: 34px; height: 34px;
    border-radius: 50%;
    display: grid;
    place-items: center;
}

.steps h3 { margin-bottom: .25em; }
.steps p { margin-bottom: 0; color: var(--muted); font-size: .96rem; }

/* Ready / Set / Go */
.rsg { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

.rsg .stage {
    border-radius: 12px;
    padding: 22px;
    color: #fff;
}

.rsg .stage h3 {
    font-size: 1.6rem;
    text-transform: uppercase;
    color: #fff;
    margin-bottom: .3em;
}

.rsg .ready { background: var(--green-700); }
.rsg .set { background: var(--orange-dark); }
.rsg .go { background: #9c2b16; }

.rsg .stage ul { margin: 0; padding-left: 19px; font-size: .96rem; }
.rsg .stage li { margin-bottom: 7px; }

/* ---------- Callout ---------- */

.callout {
    background: var(--alert-bg);
    border-left: 5px solid var(--orange);
    border-radius: 0 10px 10px 0;
    padding: 18px 22px;
    margin: 26px 0;
}

.callout p:last-child { margin-bottom: 0; }
.callout h3 { margin-bottom: .35em; }

.callout.plain { background: var(--sage-200); border-left-color: var(--green-700); }

/* ---------- Forms ---------- */

.signup {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 26px;
    box-shadow: var(--shadow);
    max-width: 640px;
}

.field { margin-bottom: 15px; }

.field label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 6px; }

.field input,
.field select,
.field textarea {
    width: 100%;
    padding: 11px 13px;
    border: 1px solid #c9c9bf;
    border-radius: 8px;
    font: inherit;
    font-size: .97rem;
    background: #fff;
    color: var(--ink);
}

.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
    outline: 3px solid var(--green-700);
    outline-offset: 1px;
}

.hint { font-size: .86rem; color: var(--muted); margin: 8px 0 0; }

/* Honeypot: hidden from people, visible to naive bots. */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-status {
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: 8px;
    font-size: .95rem;
    display: none;
}

.form-status.show { display: block; }
.form-status.ok { background: #E4F0E6; color: #1d5b2c; }
.form-status.err { background: #FBE4E0; color: #8e2412; }
.form-status.info { background: var(--sage-200); color: var(--green-900); }

/* ---------- Footer ---------- */

.site-footer {
    background: var(--green-900);
    color: #c3d0c6;
    padding: 44px 0 28px;
    font-size: .93rem;
}

.site-footer a { color: #fff; }
.site-footer a:hover { color: var(--peach); }

.site-footer .cols {
    display: grid;
    gap: 26px;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    margin-bottom: 26px;
}

.site-footer h4 {
    color: #fff;
    font-size: .92rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    margin: 0 0 11px;
}

.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 7px; }

.legal {
    border-top: 1px solid rgba(255, 255, 255, .16);
    padding-top: 18px;
    color: #9fb0a4;
    font-size: .85rem;
}

.legal p { margin: 0 0 6px; }

@media (max-width: 640px) {
    .site-header .wrap { min-height: 64px; padding-block: 10px; }

    /* Five items have to clear 335px of usable width on a 375px phone, and at
       the desktop label lengths they need 438px — so the nav wrapped to a
       second permanently-sticky row. "Prepare Your Home" drops to "Prepare"
       here and the gap tightens; the accessible name on the link stays the
       full phrase, so a screen reader still announces "Prepare your home".
       (WCAG 2.5.3 is satisfied because the visible text is contained in it.) */
    .site-nav { gap: 10px; width: 100%; margin-left: 0; }
    .site-nav a { font-size: .85rem; }

    .brand img { height: 36px; }

    /* The banner label sat on its own line, costing a full line of a
       three-line block. Inline on a phone; the sentence carries the meaning. */
    .conditions { font-size: .9rem; padding: 10px 16px; }
    .conditions .wrap { gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .btn:hover, .action:hover { transform: none; }
}
