/* =====================================================================
   Firweather Plumbing & Heating: sample site by Haney Web
   World: a regional trail / topographic map sheet.

   REBRANDING FOR A REAL CLIENT (an afternoon's work):
   1. Colours: edit the "Brand palette" block below. --route is the one
      action colour (call buttons, the chosen route, emergency); keep it
      for actions only. --water / --water-deep are the big blue fields.
   2. Fonts: change the Google Fonts <link> in index.html, then
      --font-display / --font-text / --font-water here.
   3. Map: the service-area sketch is inline SVG in index.html (places,
      routes, river names). Drive times live at the top of script.js.
   4. Words: business name, phone (tel: links), email, hours, areas and
      services are plain text in index.html. Search "555-0147" to find
      every phone number.
   5. Form: replace REPLACE_WITH_FORM_ID in the form's action with the
      client's Formspree form ID.
   6. Photos: drop files into images/ with the names in PHOTO-PROMPTS.md.
   7. Remove the .demo-strip and .foot__demo blocks for a real client.
   ===================================================================== */

:root {
  /* Brand palette */
  --paper: #f3f5f2;        /* map-sheet ground, cool white */
  --paper-2: #e6ebe4;      /* panels on the sheet */
  --map-land: #eef1ea;
  --wood: #d9e5cc;         /* woodland tint */
  --wood-line: #b5c9a2;
  --contour: #a86f47;      /* contour linework */
  --contour-deep: #7a4a2a;
  --water: #2a6f97;
  --water-tint: #cfe2ec;
  --water-deep: #12384f;   /* emergency band + footer field */
  --water-ink: #e3eef4;    /* text on water-deep */
  --water-ink-2: #a9c6d6;
  --route: #c2186a;        /* the ONE action colour */
  --route-deep: #970f51;
  --route-tint: #f7dce9;
  --ink: #172320;
  --ink-2: #3d4b47;
  --rule: #c9d1cb;
  --white: #ffffff;

  /* Type */
  --font-display: "Anybody", "Arial Narrow", sans-serif;
  --font-text: "Sofia Sans", "Segoe UI", Roboto, Arial, sans-serif;
  --font-water: "Spectral", Georgia, serif;

  /* Space & shape */
  --gutter: clamp(16px, 4vw, 56px);
  --wrap: 1280px;
  --radius: 4px;
  --space-section: clamp(64px, 9vw, 128px);
  --ease-out: cubic-bezier(.16, 1, .3, 1);

  color-scheme: light;
  scroll-padding-top: 96px;
  scrollbar-color: var(--water) var(--paper-2);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: 1.0625rem;
  line-height: 1.55;
  caret-color: var(--route);
  font-variant-numeric: lining-nums;
}
::selection { background: var(--route); color: var(--white); }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img { max-width: 100%; display: block; }
a { color: inherit; text-underline-offset: .2em; text-decoration-thickness: 1.5px; }
a:hover { text-decoration-color: var(--route); }
:focus-visible { outline: 3px solid var(--route); outline-offset: 3px; border-radius: 2px; }

[hidden] { display: none !important; }
.defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip {
  position: absolute; left: 12px; top: -80px; z-index: 30;
  background: var(--ink); color: var(--white); padding: 10px 16px; font-weight: 700;
}
.skip:focus { top: calc(12px + env(safe-area-inset-top, 0px)); }
.wrap { max-width: var(--wrap); margin: 0 auto; padding-inline: var(--gutter); }

.ico { width: 1.25em; height: 1.25em; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ico--lg { width: 40px; height: 40px; stroke-width: 1.6; }

h1, h2 {
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -.015em;
  text-wrap: balance;
}
h2 { font-size: clamp(2rem, 5vw, 3.25rem); font-stretch: 112%; }
h3 { font-size: 1.1875rem; font-weight: 750; line-height: 1.25; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  min-height: 48px; padding: 10px 20px;
  border-radius: var(--radius); border: 2px solid transparent;
  font: 750 1.0625rem/1.1 var(--font-text);
  text-decoration: none; cursor: pointer;
  transition: background-color .2s var(--ease-out), color .2s var(--ease-out), border-color .2s var(--ease-out), transform .2s var(--ease-out);
}
.btn:active { transform: translateY(1px); }
.btn--lg { min-height: 56px; padding: 14px 24px; font-size: 1.125rem; }
.btn--route { background: var(--route); color: var(--white); box-shadow: 0 6px 16px -8px rgb(151 15 81 / .7); }
.btn--route:hover { background: var(--route-deep); }
.btn--line { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn--line:hover { background: var(--ink); color: var(--paper); }
.btn--line .ico, .btn--route .ico { transition: transform .25s var(--ease-out); }
.btn--line:hover .ico[href], .btn--line:hover .ico { transform: translateX(3px); }

/* ---------- Demo strip ---------- */
.demo-strip {
  background: var(--ink); color: #dfe6e2;
  font-size: .875rem; text-align: center;
  padding: 10px var(--gutter);
  padding-top: calc(10px + env(safe-area-inset-top, 0px));
}
.demo-strip a { color: var(--white); font-weight: 700; }

/* ---------- Masthead ---------- */
.masthead {
  position: relative; z-index: 20;
  background: rgb(243 245 242 / .94);
  backdrop-filter: saturate(1.2) blur(8px);
  border-bottom: 1px solid var(--ink);
  box-shadow: 0 3px 0 -1px var(--paper), 0 4px 0 -1px var(--ink);
}
.masthead__inner {
  max-width: var(--wrap); margin: 0 auto; padding: 10px var(--gutter);
  display: flex; align-items: center; gap: 12px 24px; flex-wrap: wrap;
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--water-deep); margin-right: auto; }
.brand__mark { width: 38px; height: 38px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__name {
  font-family: var(--font-display); font-weight: 800; font-stretch: 130%;
  text-transform: uppercase; letter-spacing: .04em; font-size: 1.25rem;
}
.brand__sub { font-size: .8125rem; font-weight: 600; color: var(--ink-2); margin-top: 3px; letter-spacing: .02em; }
.nav { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter); }
.nav ul { display: flex; gap: 4px 20px; white-space: nowrap; }
.nav a { display: inline-block; padding: 8px 0; font-weight: 650; font-size: .9375rem; text-decoration: none; border-bottom: 2px solid transparent; }
.nav a:hover { border-bottom-color: var(--route); }
.btn--call { min-height: 44px; padding: 8px 14px; font-size: 1rem; }
.btn--call__lead { display: none; }

/* Phone: a docked call/quote bar replaces the sticky header */
.dock {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 25;
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 8px;
  padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px));
  background: rgb(243 245 242 / .96); border-top: 1px solid var(--ink);
  box-shadow: 0 -8px 24px -16px rgb(23 35 32 / .5);
}
.dock .btn { min-height: 50px; padding: 8px 12px; }
.dock .btn--line { background: var(--paper); }
.dock .btn--line:hover { background: var(--ink); color: var(--paper); }
body { padding-bottom: calc(68px + env(safe-area-inset-bottom, 0px)); }
.masthead .btn--call { display: none; }

@media (min-width: 860px) {
  .dock { display: none; }
  body { padding-bottom: 0; }
  .masthead { position: sticky; top: 0; }
  .masthead .btn--call { display: inline-flex; }
  .nav { order: 0; width: auto; margin: 0; padding: 0; overflow: visible; }
  .nav ul { gap: 28px; }
  .btn--call__lead { display: inline; }
  .brand__name { font-size: 1.5rem; }
}

/* ---------- Map sheet (hero) ---------- */
.sheet {
  position: relative;
  margin: clamp(10px, 2vw, 24px) clamp(8px, 2vw, 24px) 0;
  padding: 6px;
  border: 1px solid var(--ink);
}
.sheet__body {
  border: 2px solid var(--ink);
  background: var(--paper) url("images/map-contours.svg") 0 0 / 600px 600px;
  padding: clamp(24px, 4vw, 56px) clamp(16px, 3vw, 48px) clamp(20px, 3vw, 40px);
  display: grid; gap: 32px;
}
.sheet__refs { display: none; }
@media (min-width: 1000px) {
  .sheet { padding: 22px; }
  .sheet__refs {
    display: flex; position: absolute; color: var(--contour-deep);
    font: 700 .75rem/1 var(--font-display); font-stretch: 120%;
  }
  .sheet__refs--top { top: 5px; left: 22px; right: 22px; justify-content: space-around; }
  .sheet__refs--side { top: 22px; bottom: 22px; left: 6px; flex-direction: column; justify-content: space-around; }
}

.cartouche h1 {
  font-size: clamp(2.5rem, 9.6vw, 4.75rem);
  font-stretch: 100%;
  color: var(--ink);
}
.cartouche__lede { margin-top: 18px; max-width: 36rem; font-size: 1.125rem; color: var(--ink-2); }
.cartouche__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.cartouche__actions .btn { flex: 1 1 15rem; }
.cartouche__note {
  display: flex; gap: 10px; align-items: flex-start; margin-top: 20px;
  font-size: .9375rem; color: var(--ink-2); font-weight: 600;
}
.cartouche__note .ico { margin-top: 1px; color: var(--water); }
.cartouche__note.is-open .ico { color: var(--route); }

.atlas { display: grid; gap: 20px; }
.atlas__map {
  position: relative;
  border: 1.5px solid var(--ink);
  background: var(--map-land);
  box-shadow: 0 18px 40px -28px rgb(18 56 79 / .55);
}
.map { display: block; width: 100%; height: auto; }
.atlas__scale {
  position: absolute; left: 12px; bottom: 10px;
  display: flex; align-items: center; gap: 10px;
  font-size: .75rem; font-weight: 600; color: var(--ink-2);
  background: rgb(238 241 234 / .9); padding: 4px 8px;
}
.scalebar { display: inline-flex; border: 1px solid var(--ink); }
.scalebar i { width: 14px; height: 6px; }
.scalebar i:nth-child(odd) { background: var(--ink); }

/* map layers (colours come from the palette above) */
.m-land { fill: var(--map-land); }
.m-wood { fill: var(--wood); }
.hatch { stroke: var(--wood-line); stroke-width: 1.2; }
.m-contours path { fill: none; stroke: var(--contour); stroke-width: 1; opacity: .55; }
.m-contours .c-index { stroke-width: 1.9; opacity: .75; }
.m-water { fill: var(--water-tint); stroke: var(--water); stroke-width: 1.2; }
.m-stream { fill: none; stroke: var(--water); stroke-width: 3; stroke-linecap: round; }
.m-stream--river { stroke-width: 5; }
.m-road { fill: none; stroke: var(--ink); stroke-width: 2.5; stroke-linecap: round; opacity: .75; }
.m-road--hwy { stroke-width: 5; opacity: .85; }
.m-road--minor { stroke-width: 1.4; stroke-dasharray: 5 4; opacity: .5; }
.m-label { paint-order: stroke; stroke: var(--map-land); stroke-width: 4px; stroke-linejoin: round; }
.m-label--range { font: 700 19px var(--font-display); font-stretch: 140%; letter-spacing: .5em; fill: var(--contour-deep); stroke: var(--wood); }
.m-label--water { font: italic 500 16px var(--font-water); fill: var(--water); stroke: none; }
.m-label--road { font: 700 11px var(--font-text); letter-spacing: .08em; text-transform: uppercase; fill: var(--ink-2); }
.m-routes path { fill: none; stroke: var(--route); stroke-width: 2.4; stroke-dasharray: 1 7; stroke-linecap: round; opacity: .6; }
.m-route-live { fill: none; stroke: var(--route); stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; }
.m-place { cursor: pointer; }
.m-place circle { fill: var(--paper); stroke: var(--ink); stroke-width: 2.5; transition: fill .25s var(--ease-out), stroke .25s var(--ease-out); }
.m-place text {
  font: 700 16px var(--font-text); fill: var(--ink);
  paint-order: stroke; stroke: var(--map-land); stroke-width: 4px; stroke-linejoin: round;
}
.m-place:hover circle { stroke: var(--route); }
.m-place.is-active circle { fill: var(--route); stroke: var(--route-deep); }
.m-place.is-active text { fill: var(--route-deep); }
.m-yard rect { fill: var(--water-deep); }
.m-yard text { font: 800 15px var(--font-display); font-stretch: 115%; fill: var(--water-deep); paint-order: stroke; stroke: var(--map-land); stroke-width: 4px; }
.m-north path { fill: var(--ink); }
.m-north text { font: 800 14px var(--font-display); fill: var(--ink); text-anchor: middle; }

@media (max-width: 599px) {
  .m-place text, .m-label--road, .m-north, .m-label--range { display: none; }
  .m-place.is-active text { display: inline; font-size: 30px; stroke-width: 7px; }
  .m-place--east.is-active text { text-anchor: end; }
  .m-label--water { font-size: 24px; }
  .m-place circle { r: 10; }
  .m-yard text { font-size: 26px; }
  .m-route-live { stroke-width: 9; }
  .m-routes path { stroke-width: 4; }
  .atlas__scale { position: static; border-top: 1px solid var(--ink); }
}

.legend-box__title {
  font-family: var(--font-display); font-size: 1.75rem; font-weight: 800; font-stretch: 112%;
  letter-spacing: 0; line-height: 1.1;
}
.areas { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.area {
  min-height: 44px; padding: 8px 14px;
  font: 650 .9375rem/1.1 var(--font-text); color: var(--ink);
  background: var(--paper); border: 1.5px dashed var(--ink-2); border-radius: 999px;
  cursor: pointer;
  transition: background-color .2s var(--ease-out), border-color .2s var(--ease-out), color .2s var(--ease-out);
}
.area:hover { border-color: var(--route); color: var(--route-deep); }
.area[aria-pressed="true"] { background: var(--route); border: 1.5px solid var(--route); color: var(--white); }
.readout { margin-top: 14px; min-height: 3.1em; font-size: 1rem; color: var(--ink-2); max-width: 40rem; }
.readout strong { color: var(--ink); }
.readout a { color: var(--route-deep); font-weight: 700; }

/* ---------- Photo slots with designed fallback ---------- */
.photo {
  position: relative; overflow: hidden;
  background: var(--paper-2);
  border: 1.5px solid var(--ink);
}
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo__ph { display: none; }
.photo.is-missing img { display: none; }
.photo.is-missing {
  background:
    url("images/map-contours.svg") 30% 40% / 420px 420px,
    linear-gradient(var(--paper-2), var(--paper-2));
  outline: 1.5px dashed var(--contour);
  outline-offset: -10px;
}
.photo.is-missing .photo__ph {
  display: flex; flex-direction: column; gap: 2px;
  position: absolute; left: 12px; bottom: 12px; right: 12px;
  font-size: .8125rem; font-weight: 600; color: var(--ink-2);
}
.photo__ph span {
  font: 800 .9375rem/1.2 var(--font-display); font-stretch: 115%; color: var(--water-deep);
}
.photo--inset { aspect-ratio: 4 / 3; }
.photo--legend, .photo--trail { aspect-ratio: 4 / 3; }
.photo--van { aspect-ratio: 8 / 5; }
.photo--order { aspect-ratio: 4 / 5; display: none; }

@media (min-width: 1000px) {
  .sheet__body {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 24px clamp(32px, 4vw, 64px);
    align-items: start;
  }
  .cartouche { padding-top: 8px; position: relative; z-index: 2; }
  .cartouche__actions .btn { flex: 0 1 auto; }
  .atlas { grid-template-columns: minmax(0, 1fr) clamp(180px, 16vw, 250px); gap: 18px 24px; }
  .atlas__map { grid-column: 1 / -1; }
  .legend-box { grid-column: 1; }
  .photo--inset {
    grid-column: 2; grid-row: 2; aspect-ratio: 4 / 5;
    margin-top: clamp(-72px, -4vw, -40px); z-index: 2;
    box-shadow: 0 20px 40px -24px rgb(23 35 32 / .6);
    outline: 6px solid var(--paper);
  }
}
@media (min-width: 1280px) {
  .cartouche h1 { font-stretch: 108%; }
}

/* ---------- Emergency band (billed first) ---------- */
.flood {
  background: var(--water-deep); color: var(--water-ink);
  padding-block: clamp(48px, 7vw, 88px);
  margin-top: clamp(24px, 3vw, 40px);
}
.flood__grid { display: grid; gap: 40px; }
.flood h2 { color: var(--white); font-stretch: 105%; }
.flood__head p { margin-top: 14px; max-width: 32rem; color: var(--water-ink-2); font-size: 1.125rem; }
.flood__head .btn { margin-top: 24px; }
.flood :focus-visible { outline-color: var(--white); }
.flood__steps { display: grid; gap: 28px; counter-reset: step; }
.flood__steps li {
  display: grid; grid-template-columns: 40px 1fr; gap: 4px 18px;
  padding-top: 20px; border-top: 1px dashed rgb(169 198 214 / .45);
}
.flood__steps .ico { grid-row: span 2; color: var(--water-ink-2); }
.flood__steps h3 { color: var(--white); }
.flood__steps h3::before { counter-increment: step; content: counter(step) ". "; color: var(--water-ink-2); }
.flood__steps p { color: var(--water-ink-2); font-size: 1rem; max-width: 34rem; }
@media (min-width: 1000px) {
  .flood__grid { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 6vw, 96px); }
}

/* ---------- Services: map legend ---------- */
.legend { padding-block: var(--space-section); }
.legend__grid { display: grid; gap: 36px; }
.legend__intro p { margin-top: 16px; max-width: 30rem; color: var(--ink-2); font-size: 1.125rem; }
.legend__list { border-top: 2px solid var(--ink); }
.key {
  display: grid; grid-template-columns: 64px 1fr; gap: 20px;
  padding: 24px 0; border-bottom: 1px solid var(--rule);
}
.key__sym {
  position: relative; width: 64px; height: 64px;
  display: grid; place-items: center;
  border: 2px solid var(--ink); border-radius: 50%;
  background: var(--paper);
  color: var(--water);
}
.key__sym svg { width: 30px; height: 30px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.key__sym b {
  position: absolute; right: -6px; top: -6px;
  width: 26px; height: 26px; display: grid; place-items: center;
  background: var(--ink); color: var(--paper); border-radius: 50%;
  font: 800 .8125rem/1 var(--font-display);
}
.key p { margin-top: 6px; color: var(--ink-2); max-width: 36rem; }
.key__link {
  display: inline-flex; align-items: center; min-height: 44px; margin-top: 2px;
  font-weight: 700; color: var(--route-deep);
}
.photo--legend { order: 3; }
@media (min-width: 1000px) {
  .legend__grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    grid-template-rows: auto 1fr;
    column-gap: clamp(40px, 6vw, 96px);
  }
  .legend__intro { grid-column: 1; grid-row: 1; }
  .photo--legend { grid-column: 1; grid-row: 2; align-self: start; order: 0; position: sticky; top: 120px; }
  .legend__list { grid-column: 2; grid-row: 1 / span 2; }
}

/* ---------- Service area ---------- */
.area-sec {
  background: var(--wood);
  border-block: 2px solid var(--ink);
  padding-block: var(--space-section);
}
.area-sec__grid { display: grid; gap: 32px; align-items: center; }
.area-sec__text p { margin-top: 16px; color: var(--ink-2); max-width: 34rem; font-size: 1.125rem; }
.gazetteer {
  margin-top: 24px; columns: 2; column-gap: 24px;
  border-top: 1.5px solid var(--ink);
  padding-top: 12px;
}
.gazetteer li {
  break-inside: avoid; padding: 7px 0 7px 22px; position: relative;
  font-weight: 650; border-bottom: 1px dotted rgb(122 74 42 / .5);
}
.gazetteer li::before {
  content: ""; position: absolute; left: 2px; top: 50%; translate: 0 -50%;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--paper); border: 2px solid var(--ink);
}
.area-sec__text .area-sec__aside { font-size: 1rem; }
@media (min-width: 1000px) {
  .area-sec__grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(40px, 6vw, 96px); }
}

/* ---------- How a call goes + hours ---------- */
.hours { padding-block: var(--space-section); }
.hours__grid { display: grid; gap: 64px; }
.trail__steps { position: relative; margin-top: 28px; display: grid; gap: 26px; }
.trail__steps::before {
  content: ""; position: absolute; left: 11px; top: 14px; bottom: 14px;
  border-left: 3px dotted var(--route);
}
.trail__steps li { position: relative; padding-left: 48px; }
.trail__steps li::before {
  content: ""; position: absolute; left: 0; top: 2px;
  width: 25px; height: 25px; border-radius: 50%;
  background: var(--paper); border: 3px solid var(--ink);
}
.trail__steps li:last-child::before { background: var(--route); border-color: var(--route-deep); }
.trail__steps p { margin-top: 4px; color: var(--ink-2); max-width: 32rem; }
.photo--trail { margin-top: 36px; }

.board {
  background: var(--paper-2);
  border: 2px solid var(--ink);
  padding: clamp(24px, 3.5vw, 40px);
  align-self: start;
}
.board__status {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 10px;
  font-weight: 700; color: var(--water-deep);
}
.board__status::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--water); }
.board__status.is-open::before { background: var(--route); box-shadow: 0 0 0 4px var(--route-tint); }
.board__table { width: 100%; border-collapse: collapse; margin-top: 20px; font-variant-numeric: tabular-nums; }
.board__table th, .board__table td { padding: 11px 8px; border-bottom: 1px solid var(--rule); text-align: left; font-size: 1.0625rem; }
.board__table th { font-weight: 700; }
.board__table td { text-align: right; font-weight: 600; color: var(--ink-2); }
.board__table tr.is-today { background: var(--white); }
.board__table tr.is-today th::after {
  content: "Today"; margin-left: 10px; padding: 2px 8px; border-radius: 999px;
  background: var(--route); color: var(--white); font-size: .75rem; font-weight: 750; vertical-align: 2px;
}
.board__table tr.is-today td { color: var(--ink); }
.board__foot { margin-top: 18px; font-size: .9375rem; color: var(--ink-2); }
@media (min-width: 1000px) {
  .hours__grid { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(40px, 6vw, 96px); }
}

/* ---------- Quote form (work order ticket) ---------- */
.order {
  background: var(--water-tint);
  border-top: 2px solid var(--ink);
  padding-block: var(--space-section);
}
.order__grid { display: grid; gap: 32px; }
.order__intro p { margin-top: 16px; max-width: 30rem; font-size: 1.125rem; color: var(--ink-2); }
.order__urgent { padding-top: 16px; border-top: 1px solid rgb(18 56 79 / .25); }
.order__urgent a { color: var(--route-deep); font-weight: 750; }
@media (min-width: 1000px) {
  .order__grid { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
  .photo--order { display: block; margin-top: 32px; }
}

.ticket {
  background: var(--white);
  border: 2px solid var(--ink);
  padding: 0 clamp(18px, 3vw, 36px) clamp(22px, 3vw, 36px);
  box-shadow: 0 24px 48px -32px rgb(18 56 79 / .6);
  display: grid; gap: 20px;
}
.ticket__head {
  display: flex; justify-content: space-between; gap: 12px;
  margin: 0 calc(clamp(18px, 3vw, 36px) * -1);
  padding: 12px clamp(18px, 3vw, 36px);
  border-bottom: 2px solid var(--ink);
  background: var(--paper-2);
  font: 800 .8125rem/1.2 var(--font-display); font-stretch: 125%;
  text-transform: uppercase; letter-spacing: .14em; color: var(--ink-2); white-space: nowrap;
}
@media (max-width: 420px) { .ticket__head span + span { display: none; } }
.ticket__summary {
  padding: 12px 14px; border: 1.5px solid var(--route-deep); background: var(--route-tint);
  color: var(--route-deep); font-weight: 650; border-radius: var(--radius);
}
.field { display: grid; gap: 6px; min-width: 0; }
.field-row { display: grid; gap: 20px; }
@media (min-width: 640px) { .field-row { grid-template-columns: 1fr 1fr; } }
.field label, .field legend { font-weight: 700; font-size: 1rem; }
.opt { font-weight: 500; color: var(--ink-2); }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
legend { padding: 0; margin-bottom: 8px; }
input[type="text"], input[type="tel"], input[type="email"], select, textarea {
  width: 100%; min-height: 50px; padding: 12px 14px;
  font: 500 1.0625rem/1.3 var(--font-text); color: var(--ink);
  background: var(--paper); border: 1.5px solid var(--ink-2); border-radius: var(--radius);
  transition: border-color .2s var(--ease-out), box-shadow .2s var(--ease-out), background-color .2s var(--ease-out);
}
input::placeholder, textarea::placeholder { color: #5d6a66; }
textarea { resize: vertical; min-height: 130px; }
select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23172320' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; background-size: 20px;
  padding-right: 44px;
}
input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: none; border-color: var(--water); background: var(--white);
  box-shadow: 0 0 0 3px rgb(42 111 151 / .3);
}
[aria-invalid="true"] { border-color: var(--route-deep) !important; background: #fdf3f7 !important; }
.field__hint { font-size: .9375rem; color: var(--ink-2); }
.field__err { font-size: .9375rem; font-weight: 700; color: var(--route-deep); }

.choices__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(100px, 1fr)); gap: 8px; }
.choice {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 8px;
  padding: 12px; min-height: 84px; cursor: pointer;
  border: 1.5px solid var(--ink-2); border-radius: var(--radius); background: var(--paper);
  font-weight: 650; font-size: .9375rem; line-height: 1.2;
  transition: border-color .2s var(--ease-out), background-color .2s var(--ease-out);
}
.choice svg { width: 28px; height: 28px; fill: none; stroke: var(--water); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.choice input, .pill input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice:hover { border-color: var(--ink); }
.choice:has(input:checked) { border: 2px solid var(--route); background: var(--route-tint); }
.choice:has(input:checked) svg { stroke: var(--route-deep); }
.choice:has(input:focus-visible), .pill:has(input:focus-visible) { outline: 3px solid var(--route); outline-offset: 2px; }
.choices.is-invalid .choice { border-color: var(--route-deep); }

.when__row { display: flex; flex-wrap: wrap; gap: 8px; }
.pill {
  position: relative; display: inline-flex; align-items: center; min-height: 44px; padding: 8px 16px;
  border: 1.5px dashed var(--ink-2); border-radius: 999px; background: var(--paper);
  font-weight: 650; font-size: .9375rem; cursor: pointer;
}
.pill:has(input:checked) { border: 1.5px solid var(--ink); background: var(--ink); color: var(--paper); }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.btn--submit { width: 100%; }
.btn--submit[disabled] { opacity: .75; cursor: progress; }
.btn--submit.is-loading .ico { animation: nudge 1s var(--ease-out) infinite; }
@keyframes nudge { 50% { transform: translateX(5px); } }
.ticket__fine { font-size: .875rem; color: var(--ink-2); text-align: center; }

.ticket--done { padding-top: clamp(28px, 4vw, 48px); justify-items: start; align-self: start; }
.ticket__check { width: 52px; height: 52px; fill: none; stroke: var(--white); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; background: var(--route); border-radius: 50%; padding: 11px; }
.ticket--done h3 { font: 800 1.75rem/1.1 var(--font-display); font-stretch: 112%; }
.ticket--done p { color: var(--ink-2); max-width: 34rem; }

/* ---------- Footer ---------- */
.foot {
  background: var(--water-deep); color: var(--water-ink);
  padding-block: clamp(48px, 7vw, 80px) calc(clamp(32px, 4vw, 48px) + env(safe-area-inset-bottom, 0px));
}
.foot__grid { display: grid; gap: 32px; }
.foot__name {
  font-family: var(--font-display); font-weight: 800; font-stretch: 130%;
  text-transform: uppercase; letter-spacing: .04em; font-size: clamp(2rem, 6vw, 3.25rem); line-height: 1;
  color: var(--white);
}
.foot__brand p + p { margin-top: 8px; color: var(--water-ink-2); }
.foot__contact { display: grid; gap: 12px; }
.foot__contact li { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; }
.foot__contact .ico { color: var(--water-ink-2); }
.foot__contact a { color: var(--white); font-weight: 700; }
.foot__contact span { color: var(--water-ink-2); font-size: .9375rem; }
.foot :focus-visible { outline-color: var(--white); }
.foot__demo {
  grid-column: 1 / -1;
  padding-top: 20px; border-top: 1px dashed rgb(169 198 214 / .45);
  font-size: .9375rem; color: var(--water-ink-2); max-width: 60rem;
}
.foot__demo a { color: var(--white); font-weight: 700; }
@media (min-width: 860px) {
  .foot__grid { grid-template-columns: 1fr 1fr; align-items: end; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; scroll-behavior: auto !important; }
}
