/* The home page: each part placed and sized with the tokens of system.css (design\components.md holds the patterns). */

/* ---------- 1. the header (kit rotate, full-bleed footage, the quiz on the right) ---------- */
.hero { position: relative; isolation: isolate; color: var(--c-on-ink); background: var(--c-paper-alt); min-height: clamp(660px, calc(100svh - var(--header-h)), 900px); display: grid; align-items: center; padding: clamp(2.5rem, 5vh, 4rem) 0 clamp(5rem, 9vh, 7rem); box-sizing: border-box; }
.hero__stage { position: absolute; inset: 0; z-index: 0; overflow: hidden; background: var(--c-brand); }
.hero__depth { position: absolute; inset: -18px; }
.hero__slides { position: absolute; inset: 0; }
/* the kit's header that changes its picture: its CSS is shared (design\components.css) */
/* where each clip's people sit: the slide's own crop (set per clip once they come) */
.hero__slide video, .hero__slide .kit-first { object-position: var(--focus, 62% 50%); }
.hero__slide--mirror video, .hero__slide--mirror .kit-first { transform: scaleX(-1); }
.hero__grade { position: absolute; inset: 0; z-index: 3; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(8, 24, 15, 0.9) 0%, rgba(8, 24, 15, 0.74) 30%, rgba(8, 24, 15, 0.34) 52%, rgba(8, 24, 15, 0.06) 66%, rgba(8, 24, 15, 0.12) 80%, rgba(8, 24, 15, 0.42) 100%),
    linear-gradient(0deg, rgba(8, 24, 15, 0.5) 0%, rgba(8, 24, 15, 0) 34%),
    linear-gradient(180deg, rgba(8, 24, 15, 0.32) 0%, rgba(8, 24, 15, 0) 22%); }
.hero__edge { --edge-color: var(--c-paper-alt); z-index: 4; }
.hero__in { position: relative; z-index: 5; display: grid; grid-template-columns: minmax(0, 1fr) minmax(370px, 420px); gap: clamp(2rem, 6vw, 6.5rem); align-items: center; }
.hero__copy { max-width: 46rem; }
.hero__title { font-size: min(var(--fs-display), 4.1rem); line-height: 0.98; letter-spacing: 0.005em; color: var(--c-paper); text-wrap: balance; }
.hero__title-a, .hero__title-b { display: block; }
.hero__title-b { color: var(--c-accent-on-ink); }
.hero__line { margin-top: clamp(1rem, 2vh, 1.5rem); font-size: var(--fs-lead); line-height: 1.5; color: rgba(247, 245, 238, 0.9); max-width: 33rem; text-shadow: 0 1px 12px rgba(8, 24, 15, 0.5); }
.hero__actions { margin-top: clamp(1.4rem, 3vh, 2rem); }
.hero__promises { position: relative; margin-top: clamp(1.75rem, 4vh, 3rem); min-height: 84px; }
.promise { position: absolute; left: 0; top: 0; display: none; align-items: flex-start; gap: 0.8rem; padding: 0.95rem 1.2rem 1rem 1rem; max-width: 25rem; box-sizing: border-box; }
.promise p { display: grid; gap: 0.15rem; }
.promise b { font: 700 1.12rem/1.2 var(--font-display); color: var(--c-paper); }
.promise p span { color: var(--c-on-ink-soft); font-size: var(--fs-small); }
.promise__mark { flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--c-accent); color: var(--c-on-accent); }
.promise__mark .icon { width: 17px; height: 17px; stroke-width: 2.6; }
/* one card a slide: it shows with its slide and rises once that picture is half in; the one before fades as it goes */
.hero:not(:has([data-kit-on])) .promise[data-promise="1"],
.hero:has(.hero__slide--1[data-kit-on]) .promise[data-promise="1"],
.hero:has(.hero__slide--2[data-kit-on]) .promise[data-promise="2"] { display: flex; animation: promise-in 760ms var(--ease-out) 650ms both; }
.hero:has(.hero__slide--1[data-prev]) .promise[data-promise="1"],
.hero:has(.hero__slide--2[data-prev]) .promise[data-promise="2"] { display: flex; animation: promise-out 600ms var(--ease-out) both; }
.hero:not(:has([data-prev])) .promise[data-promise="1"] { animation: none; }
@keyframes promise-in { from { opacity: 0; transform: translateY(18px) scale(0.97); } to { opacity: 1; transform: none; } }
@keyframes promise-out { from { opacity: 1; transform: none; } to { opacity: 0; transform: translateY(-10px); } }
/* the quiz hangs low on the right, over the gable edge, so the people in the footage keep their faces clear */
.hero { --hang: clamp(9rem, 22vh, 13rem); z-index: 3; }
.hero__quiz { justify-self: end; align-self: end; width: 100%; margin-bottom: calc(-1 * var(--hang)); position: relative; z-index: 6; }
.hero + .services { padding-top: calc(var(--hang) + var(--section-y) * 0.55); }
@media (max-width: 960px) { .hero { --hang: 0px; } .hero__quiz { margin-bottom: 0; } .hero + .services { padding-top: var(--section-y); } }
/* the drone clips: the house and its roof sit between the headline and the quiz */
.hero__slide--1 { --focus: 58% 50%; } .hero__slide--2 { --focus: 56% 46%; }
.hero__stop { left: var(--gutter); bottom: calc(clamp(5rem, 9vh, 7rem) - 52px); }
@media (min-width: 1500px) { .hero__stop { left: calc((100vw - var(--max-w)) / 2); } }

@media (max-width: 960px) {
  .hero { display: block; min-height: 0; padding: 0 0 var(--space-5); background: var(--c-paper-alt); }
  .hero__stage { bottom: auto; height: var(--hero-media-h, 600px); }
  .hero__in { grid-template-columns: 1fr; gap: 0; }
  .hero__copy { min-height: var(--hero-media-h, 600px); box-sizing: border-box; padding: clamp(2rem, 7vw, 3rem) 0 calc(var(--space-6) + 10px); display: flex; flex-direction: column; justify-content: flex-end; }
  .hero__grade { background: linear-gradient(0deg, rgba(8, 24, 15, 0.92) 0%, rgba(8, 24, 15, 0.7) 45%, rgba(8, 24, 15, 0.2) 75%, rgba(8, 24, 15, 0.3) 100%); }
  .hero__quiz { margin-top: calc(-1 * var(--space-5)); justify-self: stretch; }
  .hero__promises { min-height: 76px; margin-top: var(--space-4); }
  .hero__stop { left: auto; right: var(--gutter); top: 16px; bottom: auto; }
}
@media (max-width: 960px) { .hero { --hero-media-h: min(640px, 78svh); } }
@media (max-width: 520px) {
  .hero { --hero-media-h: 640px; }
  .hero__promises { display: none; }
  .hero__slide--1 { --focus: 62% 50%; } .hero__slide--2 { --focus: 60% 50%; }
  .hero__title { font-size: clamp(2.3rem, 9.4vw, 2.9rem); }
  .hero__line { font-size: 1.08rem; }
  .promise { padding: 0.75rem 0.9rem; }
  .promise b { font-size: 1.02rem; }
}

/* ---------- 2. services, stacked ---------- */
.services { overflow: clip; }
.services__texture { position: absolute; inset: 0; z-index: -1; color: color-mix(in srgb, var(--c-brand) 9%, transparent); -webkit-mask-image: radial-gradient(120% 80% at 30% 40%, #000 30%, transparent 80%); mask-image: radial-gradient(120% 80% at 30% 40%, #000 30%, transparent 80%); }
.services__shingles { position: absolute; inset: -12% 0; }
.services__shingles svg { display: block; }
.services__grid { display: grid; grid-template-columns: minmax(250px, 0.7fr) minmax(0, 1.3fr); gap: clamp(2rem, 5vw, 5rem); align-items: start; }
.services__side { position: sticky; top: calc(var(--header-h) + 40px); }
.services__side .head { margin-bottom: var(--space-5); }
.services__index { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; counter-reset: none; }
.services__index a { position: relative; display: flex; align-items: baseline; gap: 0.9rem; padding: 0.62rem 0.9rem; border-radius: var(--radius-s); color: var(--c-ink-soft); text-decoration: none; font: 700 1.08rem/1.2 var(--font-display); transition: color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out); }
.services__n { font: 600 0.85rem/1 var(--font-ui); color: var(--c-ink-soft); min-width: 1.6em; }
.services__index a::before { content: ""; position: absolute; left: 0; top: 18%; bottom: 18%; width: 3px; border-radius: 3px; background: var(--c-accent); transform: scaleY(0); transition: transform var(--dur-med) var(--ease-out); }
.services__index a[aria-current="true"] { color: var(--c-ink); background: var(--c-card); box-shadow: var(--shadow-s); }
.services__index a[aria-current="true"]::before { transform: scaleY(1); }
.services__index a[aria-current="true"] .services__n { color: var(--c-accent-text); }
@media (hover: hover) { .services__index a:hover { color: var(--c-ink); } }
/* the 3D roof on a sticky stage: the page's scroll past it picks the case it plays (home.js), the index jumps there */
.services { --step: 56vh; --stage-h: clamp(430px, calc(100svh - var(--header-h) - 96px), 650px); }
.services__run { position: relative; height: calc(var(--stage-h) + 6 * var(--step) + 40px); }
.services__stage { position: sticky; top: calc(var(--header-h) + 30px); z-index: 2; }
.services__frame { --rise: 4.5cqi; filter: drop-shadow(0 26px 36px rgba(14, 38, 25, 0.2)); }
.services__frame .gable__media { height: var(--stage-h); border-radius: 0 0 var(--radius-xl) var(--radius-xl);
  background: radial-gradient(110% 85% at 52% 36%, #fbfaf4 0%, #eff1e6 52%, #dde3d1 100%); }
.services__scene { position: absolute; inset: 0; }
.services__mark { position: absolute; left: 0; top: calc(var(--i) * var(--step)); width: 1px; height: 1px; scroll-margin-top: calc(var(--header-h) + 30px); pointer-events: none; }
.services__stop { position: absolute; right: 14px; top: calc(4.5cqi + 16px); z-index: 6; }
.services__card { position: absolute; left: clamp(12px, 2cqi, 22px); bottom: clamp(12px, 2cqi, 22px); z-index: 5; display: grid; gap: 0.3rem; padding: clamp(0.9rem, 2cqi, 1.3rem) clamp(1rem, 2.4cqi, 1.5rem); max-width: min(54%, 25rem); box-sizing: border-box;
  opacity: 0; transform: translateY(12px); pointer-events: none; transition: opacity 300ms var(--ease-out), transform 420ms var(--ease-out); }
.services__card[data-on] { opacity: 1; transform: none; pointer-events: auto; transition-delay: 120ms; }
.services__num { font: 600 0.82rem/1 var(--font-ui); color: var(--c-accent-text); letter-spacing: 0.04em; }
.services__num span { color: var(--c-ink-soft); }
.services__title { font-size: clamp(1.35rem, 1.1rem + 0.9vw, 1.9rem); font-weight: 800; color: var(--c-ink); }
.services__line { color: var(--c-ink-soft); font-size: 1.02rem; }
/* each case's own action (a long scroll part carries its own): a small free estimate, beside the case's link */
.services__acts { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; margin-top: 0.45rem; }
.services__card .link { font-size: 0.98rem; }
.services__proof { position: absolute; z-index: 5; right: clamp(12px, 2cqi, 22px); bottom: clamp(12px, 2cqi, 22px); display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem 1.05rem 0.8rem 0.8rem; max-width: 38%; box-sizing: border-box;
  opacity: 0; transform: translateY(10px); pointer-events: none; transition: opacity 300ms var(--ease-out), transform 400ms var(--ease-out); }
.services__proof[data-on] { opacity: 1; transform: none; transition-delay: 1.8s; }
.services__proof b { display: block; font: 700 1.02rem/1.2 var(--font-display); color: var(--c-paper); }
.services__proof > span > span { display: block; font-size: 0.92rem; color: var(--c-on-ink-soft); }
.ring { flex: none; position: relative; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--c-accent); color: var(--c-on-accent); }
.ring .icon { width: 19px; height: 19px; }
.services__proof--ring .ring::after { content: ""; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid var(--c-accent); opacity: 0; animation: ring-pulse 1.6s var(--ease-out) infinite; }
.services__proof--ring .ring .icon { animation: ring-shake 1.6s ease-in-out infinite; }
@keyframes ring-pulse { 0% { transform: scale(0.8); opacity: 0.9; } 100% { transform: scale(1.45); opacity: 0; } }
@keyframes ring-shake { 0%, 40%, 100% { transform: rotate(0); } 8%, 24% { transform: rotate(-14deg); } 16%, 32% { transform: rotate(14deg); } }
.ring--done { background: var(--c-brand); color: var(--c-accent); box-shadow: inset 0 0 0 2px var(--c-accent); }
.services[data-held] .ring::after, .services[data-held] .ring .icon { animation-play-state: paused; }
/* without WebGL the stage shows Tosi's own finished roof in its place */
.services__scene[data-no3d] { background: url("https://files.webmediacdn.com/tosiroofing-com-10832a/assets/img/tosi-gbp05-red-brick-garage-1280.webp") 50% 50% / cover no-repeat; }
@media (max-width: 960px) {
  /* the card sits under the picture, in a space of its own (--card-h, its action row included) */
  .services { --step: 60vh; --card-h: 162px; --stage-h: min(74svh, 640px); }
  .services__grid { grid-template-columns: 1fr; }
  .services__side { position: static; }
  .services__index { display: none; }
  .services__side .head { margin-bottom: var(--space-4); }
  .services__stage { top: calc(var(--header-h) + 8px); }
  .services__frame { margin-bottom: var(--card-h); }
  .services__frame .gable__media { height: calc(var(--stage-h) - var(--card-h)); border-radius: 0; }
  .services__card { top: 100%; bottom: auto; left: 0; right: 0; max-width: none; min-height: var(--card-h); border-radius: 0 0 var(--radius-xl) var(--radius-xl); background: var(--c-card); backdrop-filter: none; -webkit-backdrop-filter: none; border: 1px solid var(--c-line); border-top: 0; box-shadow: none; transform: none; }
  .services__proof { right: auto; left: 10px; bottom: auto; top: calc(4.5cqi + 10px); max-width: 70%; padding: 0.55rem 0.8rem; gap: 0.55rem; }
  .services__proof b { font-size: 0.92rem; }
  .services__proof > span > span { font-size: 0.82rem; }
  .ring { width: 30px; height: 30px; } .ring .icon { width: 16px; height: 16px; }
  .services__stop { top: calc(4.5cqi + 10px); right: 10px; }
}
/* on a narrow phone the action and the case's link may take a row each, and a line may run to two (tallest 210 px at 360) */
@media (max-width: 600px) { .services { --card-h: 212px; } }

/* ---------- 3. signature: who's still here after the storm ---------- */
.stay { overflow: clip; }
/* the band's own ground: shingle courses and a lit ground behind the map, so the dark map never sits on flat green */
.stay::before { content: ""; position: absolute; inset: 0; z-index: -1; background:
  radial-gradient(55% 50% at 62% 66%, color-mix(in srgb, var(--c-brand-mid) 80%, var(--c-paper) 10%), transparent 72%),
  radial-gradient(70% 60% at 75% 10%, rgba(240, 160, 28, 0.1), transparent 60%),
  radial-gradient(60% 50% at 10% 90%, rgba(255, 255, 255, 0.05), transparent 70%),
  repeating-linear-gradient(180deg, rgba(247, 245, 238, 0.045) 0 1px, transparent 1px 22px); }
.stay__head .head__title { font-size: clamp(2rem, 1.3rem + 2.4vw, 3.3rem); }
/* the new roof goes on as the visitor scrolls (scene roof-build): the track holds the stage on screen under the header
   while the scroll chooses the moment; no stop icon, since nothing moves without the visitor's scroll */
/* under the stage, on screen for the whole track, the band's action: one small free estimate, so the scene keeps its
   size and its look (Tomer, 22 Nov); --stay-cta is the button and its gap */
.stay { --stay-cta: 54px; }
.stay__track { position: relative; height: 320vh; margin-top: var(--space-5); }
.stay__pin { position: sticky; top: var(--header-h); height: calc(100vh - var(--header-h)); height: calc(100svh - var(--header-h)); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; }
.stay__build { position: relative; overflow: hidden; width: min(100%, calc((100svh - var(--header-h) - 40px - var(--stay-cta)) * 16 / 9)); aspect-ratio: 16 / 9; box-shadow: 0 30px 60px -32px rgba(0, 0, 0, 0.6); }
.stay__cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 14px; }
/* where the call bar shows (under 900 px) it is the band's action, with the same two buttons: no second row above it */
@media (max-width: 899px) { .stay { --stay-cta: 0px; } .stay__cta { display: none; } }
@media (max-width: 639px) {
  .stay__build { overflow: visible; width: min(100%, calc((100svh - var(--header-h) - 250px - var(--stay-cta)) * 4 / 3)); aspect-ratio: auto; box-shadow: none; }
  /* the larger last card sits on the green band here, not on the picture: amber, so it never sinks into the band */
  .stay [data-scene="roof-build"] .rb-card.rb-last { background: var(--c-accent); color: var(--c-brand); }
  .stay [data-scene="roof-build"] .rb-card.rb-last span { color: var(--c-brand); opacity: 0.9; }
}

/* ---------- 4. our work: a track that slides as the page scrolls ---------- */
.work { padding-block: 0; }
.work__pin { padding-block: var(--section-y); }
.work__head .head { margin-bottom: clamp(2rem, 4vh, 3rem); }
/* a sideways scroller everywhere: on a computer the page's scroll drives it (home.js), on the phone the finger */
.work__viewport { overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.work__viewport::-webkit-scrollbar { display: none; }
.work__track { list-style: none; margin: 0; padding: 0 var(--gutter); display: flex; align-items: flex-end; gap: clamp(1rem, 2vw, 1.75rem); width: max-content; }
@media (min-width: 1500px) { .work__track { padding-left: calc((100vw - var(--max-w)) / 2); } }
.work__item { flex: none; width: clamp(280px, 30vw, 430px); }
.work__item--lead { width: clamp(320px, 44vw, 620px); }
.work__item figure { margin: 0; }
.work__item .gable { --rise: 9cqi; }
.work__item .gable__media { aspect-ratio: 4 / 3.1; }
.work__item--lead .gable__media { aspect-ratio: 4 / 3; }
.work__item .gable__media img { transition: transform 900ms var(--ease-out); }
@media (hover: hover) { .work__item .gable:hover .gable__media img { transform: scale(1.03); } }
.work__item figcaption { margin-top: 0.85rem; font: 700 1.05rem/1.25 var(--font-display); color: var(--c-ink); display: flex; align-items: center; gap: 0.55rem; }
.work__item figcaption::before { content: ""; width: 18px; height: 2px; background: var(--c-accent); flex: none; }
.work__item--more { width: clamp(220px, 20vw, 280px); align-self: stretch; display: flex; padding-bottom: 2.6rem; }
.work__more { flex: 1; display: grid; place-content: center; justify-items: center; gap: 1rem; text-align: center; padding: 2rem; font: 800 1.45rem/1.15 var(--font-display); color: var(--c-brand); }
.work__more-n { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--c-accent); color: var(--c-on-accent); }
.work__more-n .icon { width: 26px; height: 26px; }
.work__more[data-planned] { opacity: 0.7; }
@media (min-width: 961px) { .work[data-pinned] { height: var(--work-h, auto); } .work[data-pinned] .work__pin { position: sticky; top: var(--header-h); min-height: calc(100svh - var(--header-h)); box-sizing: border-box; display: flex; flex-direction: column; justify-content: center; padding-block: clamp(2rem, 6vh, 4rem); } }
@media (max-width: 960px) {
  .work__viewport { overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .work__viewport::-webkit-scrollbar { display: none; }
  .work__track { transform: none; }
  .work__item { scroll-snap-align: center; width: 78vw; }
  .work__item--lead { width: 84vw; }
  .work__item--more { width: 60vw; }
}

/* ---------- 5. reviews (amber) ---------- */
.reviews__grid { display: grid; grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr); gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.reviews__photo { --rise: 12cqi; }
.reviews__photo .gable__media { aspect-ratio: 4 / 4.4; box-shadow: var(--shadow-l); }
.reviews__photo .ridge { background: var(--c-brand); }
.reviews__main { display: grid; gap: var(--space-4); }
.reviews__main .head__title { font-size: clamp(1.9rem, 1.3rem + 2vw, 3rem); color: var(--c-on-accent); }
/* the review card and the week strip are shared parts (Part 2): design\components.css */
.reviews[data-in] .week__day--on::after { transform: rotate(-6deg) scale(1); opacity: 1; }
.reviews__also { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.7rem; margin: 0; font-size: var(--fs-body); color: var(--c-ink); }
.reviews__also .stars { color: var(--c-brand); }
.reviews__actions .link { color: var(--c-on-accent); }
@media (max-width: 900px) { .reviews__grid { grid-template-columns: 1fr; } .reviews__photo .gable__media { aspect-ratio: 4 / 3; } }

/* ---------- 6. how the free estimate works ---------- */
.estimate__grid { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.estimate__steps { list-style: none; margin: 0 0 var(--space-5); padding: 0; display: grid; gap: 0.6rem; }
.estimate__steps li { display: flex; align-items: center; gap: 0.9rem; padding: 0.85rem 1rem; border-radius: var(--radius-m); background: var(--c-card); box-shadow: 0 0 0 1px var(--c-line); font: 700 1.1rem/1.2 var(--font-display); color: var(--c-ink-soft); transition: color var(--dur-med) var(--ease-out), box-shadow var(--dur-med) var(--ease-out), transform var(--dur-med) var(--ease-out); }
.estimate__n { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--c-paper-alt); color: var(--c-brand); font: 800 0.95rem/1 var(--font-display); transition: background var(--dur-med) var(--ease-out), color var(--dur-med) var(--ease-out); }
.estimate__steps li[data-on] { color: var(--c-ink); box-shadow: 0 0 0 2px var(--c-accent), var(--shadow-m); transform: translateX(6px); }
.estimate__steps li[data-on] .estimate__n, .estimate__steps li[data-past] .estimate__n { background: var(--c-accent); color: var(--c-on-accent); }
.estimate__stage { --rise: 9cqi; }
.estimate__stage .gable__media { aspect-ratio: 16 / 12; box-shadow: var(--shadow-l); }
.estimate__stage .gable__media > video { object-position: 50% 50%; }
.estimate__scene { position: absolute; inset: 0; z-index: 2; }
.estimate__stop { right: 14px; bottom: 14px; }
@media (max-width: 960px) { .estimate__grid { grid-template-columns: 1fr; } .estimate__stage { order: -1; } .estimate__stage .gable__media { aspect-ratio: 4 / 3.6; } }

/* ---------- 7. service areas: the band's ground is the plains in 3D, from the air ---------- */
.areas { box-sizing: border-box; padding-block: calc(var(--section-y) * 0.85); min-height: min(900px, calc(100svh - var(--header-h))); display: grid; align-items: center; }
.areas__bg { position: absolute; inset: 0; z-index: -1; overflow: hidden; background: #b9ab8c; }
.areas__bg .areas__map { position: absolute; inset: 0; }
.areas__map[data-no3d] { background: #b9ab8c url("https://files.webmediacdn.com/tosiroofing-com-10832a/assets/img/map-plains-2048.webp") 64% 60% / cover no-repeat; }
.areas__grade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(90deg, rgba(8, 24, 15, 0.9) 0%, rgba(8, 24, 15, 0.72) 30%, rgba(8, 24, 15, 0.18) 58%, rgba(8, 24, 15, 0.06) 100%), linear-gradient(180deg, rgba(8, 24, 15, 0.5), rgba(8, 24, 15, 0) 22%, rgba(8, 24, 15, 0) 78%, rgba(8, 24, 15, 0.55)); }
.areas__grid { display: grid; grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr); gap: clamp(2rem, 4vw, 4rem); align-items: center; }
.areas__copy .head__title { color: var(--c-paper); }
.areas__towns { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.5rem; }
/* Part 2 (Ken's ten towns): so the band still fits one screen, Lubbock takes its own row with its line beside it,
   and the three town pages' towns one row under it, the map naming their roads */
.areas__towns li:first-child { grid-column: 1 / -1; }
.areas__towns li:first-child button { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 0.7rem; }
.areas__towns li:not(:first-child) span { display: none; }
/* each town is an item that shows it on the map: Lubbock's a button (this page is Lubbock's), the others links to
   their town pages, which only show the town until those pages are built */
.areas__towns :is(a, button) { box-sizing: border-box; width: 100%; margin: 0; border: 0; font: inherit; text-align: left; cursor: pointer; display: grid; gap: 0.1rem; padding: 0.8rem 1rem; border-radius: var(--radius-m); background: rgba(247, 245, 238, 0.06); box-shadow: inset 0 0 0 1px var(--c-on-ink-line); color: var(--c-on-ink); text-decoration: none; transition: background var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out); }
.areas__towns b { font: 700 1.12rem/1.2 var(--font-display); }
.areas__towns span { font-size: var(--fs-small); color: var(--c-on-ink-soft); }
.areas__towns :is(a, button):is([data-on], :focus-visible) { background: rgba(240, 160, 28, 0.16); box-shadow: inset 0 0 0 1px var(--c-accent); }
@media (hover: hover) { .areas__towns :is(a, button):hover { background: rgba(240, 160, 28, 0.16); box-shadow: inset 0 0 0 1px var(--c-accent); } }
.areas__towns a[data-planned] { pointer-events: auto; cursor: pointer; }
/* Ken's service area (Part 2): the towns with no page of their own, as small buttons that fly the map there */
.areas__more { margin-top: var(--space-4); }
.areas__also { margin: 0 0 0.6rem; font-size: var(--fs-small); color: var(--c-on-ink-soft); }
.areas__pills { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.45rem; }
.areas__pills button { margin: 0; border: 0; cursor: pointer; min-height: 40px; padding: 0.45rem 0.9rem; border-radius: 999px; background: rgba(247, 245, 238, 0.06); box-shadow: inset 0 0 0 1px var(--c-on-ink-line); color: var(--c-on-ink); font: 700 0.98rem/1.1 var(--font-display); transition: background var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out); }
.areas__pills button:is([data-on], :focus-visible) { background: var(--c-accent); color: var(--c-on-accent); box-shadow: none; }
@media (hover: hover) { .areas__pills button:hover:not([data-on]) { background: rgba(240, 160, 28, 0.16); box-shadow: inset 0 0 0 1px var(--c-accent); } }
@media (pointer: coarse) { .areas__pills button { min-height: 44px; } }
/* the map fills the band: its stop sits on the map at the band's top right, clear of the sticky header, in view as
   soon as the map is; the grid's empty column lets the pointer through to the map and its stop */
.areas__stop { right: 20px; top: calc(var(--header-h) + 14px); bottom: auto; }
.areas__grid { pointer-events: none; }
.areas__copy { pointer-events: auto; }
/* stacked (tablet and phone): the heading, then the map, then the towns as compact buttons right under it, so a tap
   on a town and the map's flight to it are on the screen together */
@media (max-width: 960px) {
  .areas { display: flex; flex-direction: column; align-items: stretch; min-height: 0; padding-bottom: var(--section-y); }
  .areas__grid, .areas__copy { display: contents; }
  .areas .head { order: 1; box-sizing: border-box; width: 100%; max-width: calc(var(--max-w) + 2 * var(--gutter)); margin: 0 auto var(--space-4); padding-inline: var(--gutter); }
  .areas__bg { order: 2; position: relative; inset: auto; z-index: 0; height: min(84vw, 460px); }
  .areas__grade { background: linear-gradient(180deg, var(--c-brand) 0%, rgba(8, 24, 15, 0) 14%, rgba(8, 24, 15, 0) 82%, var(--c-brand) 100%); }
  .areas__towns { order: 3; box-sizing: border-box; width: 100%; max-width: calc(var(--max-w) + 2 * var(--gutter)); margin: var(--space-4) auto 0; padding-inline: var(--gutter); grid-template-columns: 1fr 1fr; }
  .areas__towns :is(a, button) { padding: 0.8rem 0.95rem; min-height: 48px; align-content: center; }
  .areas__towns span { display: none; }
  .areas__towns li:first-child { grid-column: auto; }
  .areas__more { order: 4; box-sizing: border-box; width: 100%; max-width: calc(var(--max-w) + 2 * var(--gutter)); margin: var(--space-4) auto 0; padding-inline: var(--gutter); }
  .areas__stop { top: 14px; right: 14px; }
}

/* ---------- 8. FAQ and 9. close: shared parts (Part 2), in design\components.css ---------- */

@media (prefers-reduced-motion: reduce) {
  .promise { animation: none !important; }
  .services__proof--ring .ring::after, .services__proof--ring .ring .icon { animation: none; }
  .services__card, .services__proof { transition: none; }
}
