/* Site styles. One file, no build step. Tokens and rationale live in work/DESIGN.md. */

@font-face {
  font-family: "Archivo";
  src: url("/assets/fonts/archivo-var-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ink: oklch(0.22 0.035 268);
  --text: oklch(0.33 0.03 268);
  --muted: oklch(0.46 0.025 268);
  --bg: oklch(1 0 0);
  --surface: oklch(0.972 0.008 268);
  --tint: oklch(0.95 0.02 268);
  --line: oklch(0.9 0.012 268);
  --line-strong: oklch(0.6 0.025 268);
  --brand: oklch(0.42 0.12 268);
  --brand-deep: oklch(0.29 0.08 268);
  --brand-soft: oklch(0.94 0.025 268);
  --on-dark: oklch(0.97 0.008 268);
  --on-dark-muted: oklch(0.83 0.03 268);
  --footer: oklch(0.2 0.04 268);
  --cta: oklch(0.85 0.155 84);
  --cta-hover: oklch(0.8 0.16 76);
  --cta-ink: var(--ink);
  --focus: var(--brand);

  --font: "Archivo", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --fs-body: clamp(1rem, 0.94rem + 0.22vw, 1.25rem);
  --fs-lede: clamp(1.0625rem, 0.96rem + 0.42vw, 1.5rem);
  --fs-big: clamp(1.125rem, 1rem + 0.5vw, 1.625rem);
  --fs-h1: clamp(2.125rem, 1.4rem + 2.6vw, 5rem);
  --fs-h2: clamp(1.75rem, 1.3rem + 1.5vw, 3.25rem);
  --fs-h3: clamp(1.125rem, 1.04rem + 0.36vw, 1.5rem);
  --fs-small: clamp(0.875rem, 0.85rem + 0.1vw, 1rem);

  --pad-x: clamp(16px, 4vw, 96px);
  --section-y: clamp(3.5rem, 2rem + 5vw, 8.5rem);
  --gap: clamp(1.5rem, 1rem + 2.4vw, 5rem);
  --r: 6px;
  --shadow: 0 1px 2px oklch(0.29 0.08 268 / 0.08), 0 12px 32px -8px oklch(0.29 0.08 268 / 0.22);

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-out-quint: cubic-bezier(0.22, 1, 0.36, 1);

  --z-header: 20;
  --z-callbar: 30;
  --z-skip: 40;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 6rem; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  overflow-wrap: break-word;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--brand); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
p { margin: 0 0 1em; max-width: none; text-wrap: pretty; }
h1, h2, h3 {
  margin: 0 0 0.5em;
  color: var(--ink);
  font-stretch: 112%;
  font-weight: 760;
  line-height: 1.08;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
h1 { font-size: var(--fs-h1); letter-spacing: -0.03em; line-height: 1.02; }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); line-height: 1.2; letter-spacing: -0.01em; }
ul[role="list"] { list-style: none; margin: 0; padding: 0; }
.nowrap { white-space: nowrap; }
.vh { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 2px; }
.on-dark :focus-visible, .on-dark:focus-visible { --focus: var(--cta); }

.wrap { width: 100%; max-width: 150rem; margin-inline: auto; padding-inline: var(--pad-x); }
.section { padding-block: var(--section-y); }

.skip {
  position: absolute; left: var(--pad-x); top: -4rem; z-index: var(--z-skip);
  background: var(--ink); color: var(--on-dark); padding: 0.75rem 1rem; border-radius: var(--r);
  font-weight: 700; text-decoration: none;
}
.skip:focus { top: 0.75rem; }

/* Icons: Tabler Icons paths (MIT), stroke 2 */
.ico { width: 1.15em; height: 1.15em; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55em;
  min-height: 48px; padding: 0.7em 1.25em;
  border: 2px solid transparent; border-radius: var(--r);
  font: inherit; font-weight: 700; font-stretch: 106%; line-height: 1.15;
  text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: transform 160ms var(--ease-out), background-color 180ms ease, border-color 180ms ease, color 180ms ease, box-shadow 180ms ease;
}
.btn:active { transform: scale(0.97); }
.btn-cta { background: var(--cta); color: var(--cta-ink); box-shadow: inset 0 -2px 0 oklch(0.22 0.035 268 / 0.18); }
.btn-ghost { background: transparent; color: var(--brand); border-color: currentColor; }
.btn-light { background: var(--bg); color: var(--brand-deep); }
.btn-lg { min-height: 56px; padding: 0.85em 1.5em; font-size: clamp(1rem, 0.95rem + 0.2vw, 1.1875rem); }
@media (hover: hover) and (pointer: fine) {
  .btn-cta:hover { background: var(--cta-hover); }
  .btn-ghost:hover { background: var(--brand-soft); }
  .btn-light:hover { background: var(--brand-soft); }
}
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.75rem; }

/* Brand mark: roof line over three courses of lap siding */
.brand { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--ink); text-decoration: none; min-width: 0; }
.brand-mark { width: 2.25rem; height: 2.25rem; flex: none; }
.bm-bg { fill: var(--brand); }
.bm-roof { fill: none; stroke: var(--on-dark); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.bm-course { fill: var(--on-dark); }
.bm-first { fill: var(--cta); }
.brand-name { font-weight: 800; font-stretch: 112%; font-size: clamp(1.0625rem, 1rem + 0.25vw, 1.3125rem); line-height: 1.1; letter-spacing: -0.015em; }

/* Header: copy verbatim to every page; add aria-current="page" to the matching nav link */
.site-header { background: var(--bg); border-bottom: 1px solid var(--line); }
.header-in {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "brand call" "nav nav";
  align-items: center; column-gap: 1rem; row-gap: 0.5rem; padding-block: 0.75rem 0.5rem;
}
.site-header .brand { grid-area: brand; }
.nav { grid-area: nav; display: flex; gap: 0.25rem clamp(0.75rem, 2vw, 2rem); flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 0.35rem; }
.nav a { display: inline-flex; align-items: center; min-height: 44px; color: var(--text); font-weight: 600; text-decoration: none; position: relative; }
.nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 8px; height: 2px; background: var(--brand);
  transform: scaleX(0); transform-origin: left; transition: transform 200ms var(--ease-out);
}
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a[aria-current="page"] { color: var(--brand); }
.btn-call { grid-area: call; min-height: 44px; padding-inline: 1rem; }
.btn-call .num { display: none; }
@media (min-width: 30rem) { .btn-call .num { display: inline; } }
@media (min-width: 64rem) {
  .site-header { position: sticky; top: 0; z-index: var(--z-header); }
  .header-in { grid-template-columns: auto 1fr auto; grid-template-areas: "brand nav call"; padding-block: 0.75rem; }
  .nav { justify-content: flex-end; flex-wrap: nowrap; border-top: 0; padding-top: 0; }
  .brand-name { white-space: nowrap; }
}

/* Hero */
.hero { padding-block: clamp(2rem, 1rem + 4vw, 6rem) calc(var(--section-y) * 0.5); }
.hero-grid { display: grid; gap: clamp(2.5rem, 2rem + 2vw, 5rem); align-items: center; }
.hero-copy .lede { font-size: var(--fs-lede); line-height: 1.55; color: var(--text); }
.hero-media { position: relative; }
.hero-photo { overflow: hidden; border-radius: var(--r); background: var(--tint); }
.hero-photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 55% 40%; }
@media (min-width: 60rem) {
  .hero-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr); }
  .hero-photo img { aspect-ratio: auto; height: clamp(26rem, 68vh, 56rem); }
}

/* Courses: the lap siding motif used in the brand mark and the vinyl band */
.courses { display: grid; align-content: end; --c1: oklch(0.97 0.008 268); --c2: oklch(0.9 0.018 268); --c3: oklch(0.7 0.03 268); --h: clamp(0.85rem, 0.6rem + 0.7vw, 1.6rem); }
.courses span {
  display: block; height: var(--h);
  background: linear-gradient(180deg, var(--c1) 0%, var(--c2) 82%, var(--c3) 82%, var(--c3) 100%);
}

/* Services */
.services-grid { display: grid; gap: var(--gap); }
.services-media { border-radius: var(--r); overflow: hidden; background: var(--tint); }
.services-media img { width: 100%; height: 100%; aspect-ratio: 16 / 7; object-fit: cover; }
.svc-list { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, max(19rem, 30%)), 1fr)); margin-top: 2.25rem; }
.svc {
  position: relative; display: flex; flex-direction: column; padding: clamp(1.25rem, 1rem + 0.8vw, 2rem);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  transition: border-color 200ms ease, background-color 200ms ease, transform 160ms var(--ease-out);
}
.svc h3 { margin-bottom: 0.45em; }
.svc h3 a { color: var(--ink); text-decoration: none; }
.svc h3 a::after { content: ""; position: absolute; inset: 0; border-radius: var(--r); }
.svc h3 .ico { display: inline-block; vertical-align: -0.16em; margin-left: 0.35em; color: var(--brand); transition: transform 200ms var(--ease-out); }
.svc p { margin: 0; color: var(--muted); }
.svc:active { transform: scale(0.985); }
.svc:focus-within { border-color: var(--brand); }
.svc h3 a:focus-visible { outline: none; }
.svc:has(a:focus-visible) { outline: 3px solid var(--focus); outline-offset: 3px; }
@media (hover: hover) and (pointer: fine) {
  .svc:hover { border-color: var(--brand); background: var(--bg); }
  .svc:hover h3 .ico { transform: translateX(4px); }
}
.more { margin: 2rem 0 0; }
.link-arrow { display: inline-flex; align-items: center; gap: 0.45em; min-height: 44px; font-weight: 700; font-stretch: 106%; }
@media (min-width: 64rem) {
  .services-grid { grid-template-columns: minmax(0, 2fr) minmax(0, 5fr); }
  .services-media { align-self: start; position: sticky; top: 6.5rem; }
  .services-media img { height: auto; aspect-ratio: 4 / 5; }
}

/* Vinyl only band: the page's one color block */
.band { background: var(--brand-deep); color: var(--on-dark); padding-block: var(--section-y); }
.band h2 { color: var(--on-dark); }
.band p { color: var(--on-dark-muted); font-size: var(--fs-big); line-height: 1.55; margin: 0; }
.band-grid { display: grid; gap: var(--gap); align-items: center; }
.band .courses {
  --c1: oklch(0.47 0.1 268); --c2: oklch(0.4 0.095 268); --c3: oklch(0.24 0.07 268); --h: clamp(1.4rem, 1rem + 1.4vw, 3rem);
  border-radius: var(--r); overflow: hidden; box-shadow: 0 0 0 1px oklch(0.47 0.1 268 / 0.5);
}
.band .courses span:last-child { --c1: var(--cta); --c2: oklch(0.8 0.15 80); --c3: oklch(0.62 0.12 70); }
@media (min-width: 60rem) { .band-grid { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); } }

/* Free estimate: photo with an overlapping answer panel */
.overlap { display: grid; }
.overlap-photo { border-radius: var(--r); overflow: hidden; background: var(--tint); }
.overlap-photo img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.overlap-panel {
  position: relative; margin: -3rem 0.75rem 0; padding: clamp(1.5rem, 1rem + 2vw, 3.5rem);
  background: var(--bg); border-radius: var(--r); box-shadow: var(--shadow);
}
.overlap-panel p { font-size: var(--fs-big); line-height: 1.55; margin: 0; }
@media (min-width: 60rem) {
  .overlap { grid-template-columns: repeat(12, minmax(0, 1fr)); align-items: center; }
  .overlap-photo { grid-column: 1 / 9; grid-row: 1; }
  .overlap-photo img { aspect-ratio: 16 / 10; }
  .overlap-panel { grid-column: 7 / 13; grid-row: 1; margin: 0; }
}

/* Price */
.price { background: var(--surface); border-block: 1px solid var(--line); }
.price-grid { display: grid; gap: var(--gap); align-items: center; }
.price-media { border-radius: var(--r); overflow: hidden; background: var(--tint); }
.price-media img { width: 100%; aspect-ratio: 23 / 10; object-fit: cover; }
.linkline { margin-top: 1.5rem; border-top: 1px solid var(--line); font-weight: 650; }
.linkline li { border-bottom: 1px solid var(--line); }
.linkline li + li { padding-left: 1.25rem; }
.linkline a { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 52px; text-decoration: none; }
.linkline .ico { transition: transform 200ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .linkline a:hover { text-decoration: underline; } .linkline a:hover .ico { transform: translateX(4px); } }
@media (min-width: 60rem) {
  .price-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: stretch; }
  .price-media img { height: 100%; min-height: 22rem; aspect-ratio: auto; }
}

/* FAQ */
.faq-grid { display: grid; gap: var(--gap); grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); margin-top: 2rem; }
.qa { border-top: 3px solid var(--brand); padding-top: 1.25rem; }
.qa p { margin: 0; }

/* Inner pages: breadcrumbs, page hero, and question and answer rows */
.crumbs { font-size: var(--fs-small); color: var(--muted); margin-bottom: 1.25rem; }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.25rem 0.5rem; }
.crumbs li { display: inline-flex; align-items: center; gap: 0.5rem; }
.crumbs li + li::before { content: "/"; color: var(--line-strong); }
.crumbs a { display: inline-flex; align-items: center; min-height: 44px; }
.crumbs [aria-current="page"] { color: var(--text); }
.page-hero { padding-block: clamp(1.5rem, 1rem + 2.5vw, 4rem) clamp(2.5rem, 2rem + 3vw, 5.5rem); border-bottom: 1px solid var(--line); }
.page-hero-grid { display: grid; gap: var(--gap); align-items: center; }
.page-hero .lede { font-size: var(--fs-lede); line-height: 1.55; }
.page-hero-media { border-radius: var(--r); overflow: hidden; background: var(--tint); }
.page-hero-media img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
@media (min-width: 60rem) { .page-hero-grid:has(> .page-hero-media), .page-hero-grid:has(> .form-panel) { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.page-hero .actions + .cta-lead, .answer-body .cta-lead { margin: 1.25rem 0 0; }
.answers { display: grid; }
.answer { display: grid; gap: 0.75rem var(--gap); padding-block: clamp(2rem, 1.5rem + 2vw, 4rem); border-top: 1px solid var(--line); scroll-margin-top: 6rem; }
.answer:first-child { border-top: 0; padding-top: 0; }
.answer h2 { margin: 0; }
.answer-body { font-size: clamp(1.0625rem, 0.98rem + 0.32vw, 1.375rem); }
.answer-body > :last-child { margin-bottom: 0; }
.answer .faq-grid { margin-top: 0; }
@media (min-width: 64rem) { .answer { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); } }

/* Closing CTA band plus the short form */
.cta { background: var(--tint); padding-block: var(--section-y); }
.cta-grid { display: grid; gap: var(--gap); align-items: start; }
.cta-lead { font-size: var(--fs-big); font-weight: 700; font-stretch: 106%; color: var(--brand); line-height: 1.35; margin-bottom: 1rem; }
@media (min-width: 60rem) { .cta-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }

.form-panel { background: var(--bg); border-radius: var(--r); box-shadow: var(--shadow); padding: clamp(1.25rem, 1rem + 2vw, 3rem); }
.form-title { font-size: var(--fs-h3); font-weight: 760; font-stretch: 112%; color: var(--ink); line-height: 1.2; margin: 0 0 0.3em; }
.form-note { color: var(--muted); margin-bottom: 1.5rem; }
.form-grid { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); }
.form-row { margin-top: 1.1rem; }
.field label { display: block; font-weight: 650; color: var(--ink); margin-bottom: 0.4rem; }
.field input, .field select {
  width: 100%; min-height: 52px; padding: 0.7rem 0.9rem; font: inherit; color: var(--ink);
  background: var(--bg); border: 1px solid var(--line-strong); border-radius: var(--r);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}
.field select {
  appearance: none; padding-right: 2.75rem; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2331478e' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6l6 -6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 0.85rem center; background-size: 1.25rem;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--bg), 0 0 0 6px var(--brand); }
.btn-submit { width: 100%; margin-top: 1.5rem; }
@media (min-width: 60rem) { .btn-submit { width: auto; min-width: min(100%, 20rem); } }
.form-alt { margin: 1rem 0 0; color: var(--muted); }
.form-err {
  margin: 0 0 1.25rem; padding: 0.85rem 1rem; border-radius: var(--r);
  background: oklch(0.96 0.03 25); color: oklch(0.42 0.15 25); border: 1px solid oklch(0.8 0.08 25); font-weight: 600;
}
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Footer: copy verbatim to every page */
.site-footer { background: var(--footer); color: var(--on-dark-muted); padding-block: clamp(3rem, 2rem + 3vw, 6rem) 2rem; font-size: var(--fs-small); }
.site-footer a { color: var(--on-dark); }
.site-footer .brand { color: var(--on-dark); margin-bottom: 2.5rem; }
.site-footer .bm-bg { fill: oklch(0.42 0.12 268); }
.footer-cols { display: grid; gap: 2rem var(--gap); grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); }
.f-h { color: var(--on-dark); font-weight: 750; font-stretch: 108%; font-size: 1.0625rem; margin-bottom: 0.75rem; }
.footer-cols ul { list-style: none; margin: 0; padding: 0; }
.footer-cols li { margin: 0; }
.footer-cols li a, .footer-cols p a { display: inline-flex; align-items: center; min-height: 44px; }
.footer-cols p { margin-bottom: 0.25rem; }
.footer-bottom { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid oklch(0.42 0.05 268); display: flex; flex-wrap: wrap; gap: 0.25rem 2rem; }
.footer-bottom p { margin: 0; }

/* Sticky mobile call bar */
.callbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: var(--z-callbar);
  display: grid; grid-template-columns: 1.45fr 1fr; gap: 0.5rem;
  padding: 0.5rem max(0.5rem, env(safe-area-inset-left)) calc(0.5rem + env(safe-area-inset-bottom)) max(0.5rem, env(safe-area-inset-right));
  background: var(--footer); box-shadow: 0 -6px 24px oklch(0.2 0.04 268 / 0.25);
}
.callbar .btn { min-height: 48px; padding-inline: 0.6rem; font-size: 0.9375rem; }
.callbar-single { grid-template-columns: 1fr; }
/* Keep the bar off the form while someone is typing (phone keyboards push it over the fields) */
body:has(#contact-form :focus) .callbar { display: none; }
body { padding-bottom: calc(4rem + env(safe-area-inset-bottom)); }
@media (min-width: 64rem) {
  .callbar { display: none; }
  body { padding-bottom: 0; }
}

/* Motion: opt in under html.js, only when the visitor has not asked for reduced motion */
@media (prefers-reduced-motion: no-preference) {
  .js .hero-copy > * { animation: rise 700ms var(--ease-out) both; }
  .js .hero-copy > :nth-child(2) { animation-delay: 80ms; }
  .js .hero-copy > :nth-child(3) { animation-delay: 160ms; }
  .js .hero-photo { animation: frame-open 1100ms var(--ease-out-quint) both; }
  .js .hero-photo img { animation: settle 1400ms var(--ease-out-quint) both; }

  .js.rv-on .band .courses span { clip-path: inset(0 100% 0 0); }
  .js.rv-on .band .courses.in span { animation: course-in 520ms var(--ease-out) both; animation-delay: calc(var(--i, 0) * 90ms); }

  .js.rv-on .rv { opacity: 0; }
  /* backwards fill: once revealed, normal styles (and the press scale) take over again */
  .js.rv-on .rv.in { opacity: 1; animation: rise 600ms var(--ease-out) backwards; animation-delay: calc(var(--i, 0) * 60ms); }
}
@keyframes rise { from { opacity: 0.01; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes frame-open { from { clip-path: inset(7% 5% 7% 5% round var(--r)); } to { clip-path: inset(0 0 0 0 round var(--r)); } }
@keyframes settle { from { transform: scale(1.07); } to { transform: none; } }
@keyframes course-in { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }

@media print {
  .callbar, .skip, .nav, .btn-call, .form-panel { display: none !important; }
  .site-header { position: static; }
  body { padding-bottom: 0; color: #000; }
  .band, .cta, .price, .site-footer { background: none; color: #000; }
  .band h2, .band p, .site-footer a, .f-h { color: #000; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .rv, .hero-copy > *, .courses span { opacity: 1 !important; transform: none !important; clip-path: none !important; }
}
