/* ===================================================================
   Hoffman & Sons Plumbing — shared styles for every page.
   One stylesheet so the home page, service pages, service area and
   projects all look like one site.
   =================================================================== */

/* ===================================================================
   1. PALETTE + THEME  (defined once, reused everywhere)
   - The 4 brand colors never change (primary/mid/dark blues + accent).
   - The "themeable" vars flip between light and dark.
   =================================================================== */
:root {
  /* Brand palette (fixed) */
  --primary:#0B5FA5;   /* deep water blue — trust + plumbing nod */
  --mid:#084C84;
  --dark:#06375F;
  --accent:#E4622E;    /* warm copper-orange — CALL BUTTONS ONLY */
  --accent-hover:#c9521f;

  /* Themeable (LIGHT defaults) */
  --bg:#ffffff;
  --surface:#f4f7fb;
  --text:#0e1720;
  --muted:#586472;
  --border:#e3e9f1;
  --header-bg:rgba(255,255,255,.82);
  --link:#0B5FA5;

  /* HERO PHOTO SLOT — Justin and Jessica are sending the photo.
     When it arrives: save it as /img/hero.jpg (about 2400px wide) and change
     `none` below to url('/img/hero.jpg'). The dark overlay keeps the text readable. */
  --hero-image:none;
}

/* DARK — applied automatically when the device is in dark mode,
   UNLESS the visitor has manually forced light with the toggle. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg:#0b1017;
    --surface:#121a24;
    --text:#eef3f8;
    --muted:#9aa8b7;
    --border:#223141;
    --header-bg:rgba(11,16,23,.82);
    --link:#6fb1ea;
  }
}
/* DARK — applied when the visitor manually picks Dark. */
:root[data-theme="dark"] {
  --bg:#0b1017;
  --surface:#121a24;
  --text:#eef3f8;
  --muted:#9aa8b7;
  --border:#223141;
  --header-bg:rgba(11,16,23,.82);
  --link:#6fb1ea;
}

/* ===================================================================
   2. BASE
   =================================================================== */
* { box-sizing:border-box; margin:0; padding:0; }
html { scroll-behavior:smooth; scroll-padding-top:76px; }
body {
  font-family:'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background:var(--bg);
  color:var(--text);
  line-height:1.6;
  font-size:17px;
  -webkit-font-smoothing:antialiased;
  transition:background .25s ease, color .25s ease;
  min-height:100vh; display:flex; flex-direction:column;
}
main { flex:1; }
h1,h2,h3 { font-family:'Poppins', sans-serif; line-height:1.15; }
a { color:inherit; text-decoration:none; }
.wrap { max-width:1080px; margin:0 auto; padding:0 22px; }
.skip { position:absolute; left:-999px; top:8px; background:var(--bg); color:var(--text); padding:8px 14px; border-radius:8px; z-index:100; }
.skip:focus { left:8px; }
:focus-visible { outline:2px solid var(--primary); outline-offset:3px; }

/* ===================================================================
   3. HEADER (sticky, blurred, logo-home on left, call always visible)
   =================================================================== */
header {
  position:sticky; top:0; z-index:50;
  background:var(--header-bg);
  backdrop-filter:saturate(180%) blur(12px);
  -webkit-backdrop-filter:saturate(180%) blur(12px);
  border-bottom:1px solid var(--border);
}
.nav { display:flex; align-items:center; gap:18px; height:64px; position:relative; }
/* Logo IS the home link — never a separate "Home" nav item */
.logo {
  font-family:'Poppins',sans-serif; font-weight:700;
  font-size:18px; letter-spacing:-.01em; color:var(--text);
  display:flex; align-items:center; gap:9px; margin-right:auto;
}
.logo .drop { width:20px; height:20px; color:var(--primary); flex:none; }

.anchors { display:flex; gap:22px; }
.anchors a {
  font-size:14px; font-weight:500; color:var(--muted);
  letter-spacing:.01em; transition:color .2s;
}
.anchors a:hover, .anchors a[aria-current="page"] { color:var(--text); }

/* Theme toggle — System / Light / Dark, remembers the pick */
.theme {
  display:flex; align-items:center; gap:2px;
  background:var(--surface); border:1px solid var(--border);
  border-radius:999px; padding:3px;
}
.theme button {
  display:grid; place-items:center;
  width:30px; height:28px; border:0; background:transparent;
  border-radius:999px; color:var(--muted); cursor:pointer;
  transition:background .2s, color .2s;
}
.theme button svg { width:16px; height:16px; }
.theme button.active { background:var(--bg); color:var(--primary); box-shadow:0 1px 2px rgba(0,0,0,.12); }

/* The star of the page: the call button (warm accent, always visible) */
.btn-call {
  display:inline-flex; align-items:center; gap:8px;
  background:var(--accent); color:#fff; font-weight:600; font-size:15px;
  padding:10px 18px; border-radius:999px;
  box-shadow:0 4px 14px rgba(228,98,46,.35);
  transition:background .2s, transform .1s;
  white-space:nowrap;
}
.btn-call:hover { background:var(--accent-hover); }
.btn-call:active { transform:translateY(1px); }
.btn-call svg { width:16px; height:16px; }

/* Mobile menu button (hidden on desktop) */
.menu-btn { display:none; background:transparent; border:0; color:var(--text); cursor:pointer; width:32px; height:32px; }
.menu-btn svg { width:24px; height:24px; }

/* ---- Mobile: hide anchor row, show menu button ---- */
@media (max-width:760px) {
  .anchors {
    position:fixed; top:64px; left:0; right:0;
    flex-direction:column; gap:0;
    background:var(--bg); border-bottom:1px solid var(--border);
    padding:8px 0; display:none;
  }
  .anchors.open { display:flex; }
  .anchors a { padding:12px 22px; font-size:16px; }
  .menu-btn { display:grid; place-items:center; }
  .logo span.full { display:none; }   /* shorten name on small screens */
}
@media (max-width:400px) {
  .nav { gap:10px; }
  .theme button { width:26px; }
  .btn-call { padding:9px 13px; }
}

/* ===================================================================
   4. HERO (the 5-second decision zone: headline + giant call button)
   Always a dark band so it reads the same with or without the photo.
   =================================================================== */
.hero {
  position:relative; isolation:isolate;
  text-align:center; color:#fff;
  padding:clamp(64px, 10vw, 124px) 0 clamp(56px, 8vw, 96px);
  overflow:hidden;
  background-color:#06243d;
  background-image:
    linear-gradient(180deg, rgba(4,20,36,.72), rgba(4,20,36,.86)),
    var(--hero-image);
  background-size:cover; background-position:center;
}
/* Placeholder until the photo arrives: a quiet blueprint grid + glow, not a stock photo */
.hero::before {
  content:""; position:absolute; inset:0; z-index:-1;
  background:
    radial-gradient(60% 70% at 50% 0%, rgba(11,95,165,.45), transparent 70%),
    linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px) 0 0 / 44px 44px,
    linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px) 0 0 / 44px 44px;
}
.hero .eyebrow {
  font-size:clamp(11.5px, 1.5vw, 13.5px); font-weight:600; letter-spacing:.09em; text-transform:uppercase;
  color:#9fd0ff; margin:0 auto 18px; max-width:72ch; text-wrap:balance;
}
.hero h1 {
  font-size:clamp(38px, 6.6vw, 72px); font-weight:700;
  letter-spacing:-.02em; max-width:15ch; margin:0 auto;
}
.hero h1 .accentword { color:#6fb1ea; }
.hero p.sub {
  font-size:clamp(17px, 2.1vw, 20px); color:rgba(255,255,255,.82);
  max-width:50ch; margin:22px auto 0;
}
.hero .license {
  margin-top:26px; font-size:14px; color:rgba(255,255,255,.7); letter-spacing:.02em;
}
.cta-row {
  display:flex; flex-wrap:wrap; gap:14px; justify-content:center;
  margin-top:34px;
}
/* The GIANT call button — bigger than the header one, impossible to miss */
.btn-call-lg {
  display:inline-flex; align-items:center; gap:11px;
  background:var(--accent); color:#fff; font-weight:700;
  font-size:clamp(18px, 2.4vw, 21px);
  padding:17px 32px; border-radius:999px;
  box-shadow:0 10px 30px rgba(228,98,46,.4);
  transition:background .2s, transform .1s;
}
.btn-call-lg:hover { background:var(--accent-hover); }
.btn-call-lg:active { transform:translateY(1px); }
.btn-call-lg svg { width:22px; height:22px; }
/* Secondary "Text us" — quiet outline, doesn't compete with the call */
.btn-text {
  display:inline-flex; align-items:center; gap:9px;
  background:transparent; color:var(--text); font-weight:600;
  font-size:clamp(16px, 2.2vw, 18px);
  padding:16px 26px; border-radius:999px;
  border:1.5px solid var(--border);
  transition:border-color .2s, background .2s;
}
.btn-text:hover { border-color:var(--primary); }
.btn-text svg { width:19px; height:19px; color:var(--muted); }
.hero .btn-text { color:#fff; border-color:rgba(255,255,255,.32); }
.hero .btn-text svg { color:rgba(255,255,255,.75); }
.hero .btn-text:hover { border-color:#fff; background:rgba(255,255,255,.06); }

/* ===================================================================
   5. TRUST STRIP (thin row under the hero — "are these people legit?")
   =================================================================== */
.trust {
  background:var(--surface);
  border-bottom:1px solid var(--border);
  padding:18px 0;
}
.trust ul {
  list-style:none;
  display:flex; flex-wrap:wrap; justify-content:center;
  gap:14px 34px;
}
.trust li {
  display:flex; align-items:center; gap:9px;
  font-size:15px; font-weight:500; color:var(--text);
  white-space:nowrap;
}
.trust svg { width:17px; height:17px; color:var(--primary); flex:none; }
@media (max-width:560px) {
  .trust ul { display:grid; grid-template-columns:1fr 1fr; gap:12px 16px; justify-items:start; }
  .trust li { font-size:14px; white-space:normal; align-items:flex-start; }
}

/* ===================================================================
   6. SHARED SECTION STYLES (reused by every section below)
   =================================================================== */
.section { padding:clamp(56px, 8vw, 96px) 0; }
.section.alt { background:var(--surface); border-top:1px solid var(--border); border-bottom:1px solid var(--border); }
.section-head { text-align:center; max-width:52ch; margin:0 auto clamp(34px, 5vw, 52px); }
/* Small blue label over headings. Doubled selectors beat the muted `.x p` rules below. */
.eyebrow, .section-head p.eyebrow, .page-head p.eyebrow, .detail p.eyebrow {
  font-size:13px; font-weight:600; letter-spacing:.08em; text-transform:uppercase;
  color:var(--link); margin:0 0 12px;
}
.section-head h2 { font-size:clamp(28px, 4.2vw, 42px); font-weight:700; letter-spacing:-.02em; text-wrap:balance; }
.section-head p { color:var(--muted); margin-top:14px; font-size:17px; }
.section-head .lead { color:var(--text); font-weight:600; font-size:clamp(16px,2vw,18px); letter-spacing:.02em; }
.prose a, .link { color:var(--link); font-weight:600; }
.prose a:hover, .link:hover { text-decoration:underline; }

/* ===================================================================
   7. WHAT WE DO — two service cards, then the full detail panels
   =================================================================== */
.services-grid {
  display:grid; gap:16px;
  grid-template-columns:repeat(auto-fit, minmax(280px, 1fr));
}
.service {
  display:block;
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:16px;
  padding:28px 26px;
  transition:border-color .2s, transform .2s;
}
a.service:hover { border-color:var(--primary); transform:translateY(-2px); }
.service .icon {
  width:44px; height:44px; border-radius:11px;
  display:grid; place-items:center;
  background:color-mix(in srgb, var(--primary) 12%, transparent);
  color:var(--link);
  margin-bottom:16px;
}
.service .icon svg { width:23px; height:23px; }
.service h3 { font-size:19px; font-weight:600; margin-bottom:7px; }
.service p { font-size:15.5px; color:var(--muted); line-height:1.55; }
.service .more { display:inline-block; margin-top:14px; font-size:14.5px; font-weight:600; color:var(--link); }

.detail {
  display:grid; gap:clamp(22px,4vw,48px);
  grid-template-columns:minmax(0,1fr) minmax(0,1.1fr);
  align-items:start;
}
.detail + .detail { margin-top:clamp(44px,6vw,72px); padding-top:clamp(44px,6vw,72px); border-top:1px solid var(--border); }
.detail h2 { font-size:clamp(26px,3.6vw,36px); font-weight:700; letter-spacing:-.02em; margin-bottom:14px; }
.detail p { color:var(--muted); }
.detail p + p { margin-top:14px; }
.detail .closer { color:var(--text); font-weight:500; }
.checklist {
  list-style:none; display:grid; gap:10px 22px;
  grid-template-columns:repeat(auto-fit, minmax(220px,1fr));
  background:var(--surface); border:1px solid var(--border);
  border-radius:16px; padding:24px 24px;
}
.section.alt .checklist, .section.alt .trustline { background:var(--bg); }
.checklist li { display:flex; gap:10px; align-items:flex-start; font-size:15.5px; line-height:1.45; }
.checklist li::before {
  content:""; flex:none; width:16px; height:16px; margin-top:3px;
  background:var(--link);
  -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / contain no-repeat;
          mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / contain no-repeat;
}
@media (max-width:820px) { .detail { grid-template-columns:1fr; } }

/* ===================================================================
   7c. SERVICE AREA ("do you even come to my town?")
   =================================================================== */
.area-groups { display:grid; gap:clamp(26px,4vw,40px); grid-template-columns:repeat(auto-fit, minmax(300px,1fr)); max-width:920px; margin:0 auto; }
.area-groups h3 { font-size:17px; font-weight:600; margin-bottom:14px; text-align:center; }
.area-list {
  display:flex; flex-wrap:wrap; gap:10px; justify-content:center;
  max-width:760px; margin:0 auto;
}
.area-list span, .area-list li {
  list-style:none;
  background:var(--surface); border:1px solid var(--border);
  border-radius:999px; padding:8px 17px;
  font-size:14.5px; font-weight:500;
}
.section.alt .area-list li, .section.alt .area-list span { background:var(--bg); }
.area-note {
  text-align:center; color:var(--muted); font-size:15.5px;
  margin-top:28px; max-width:52ch; margin-left:auto; margin-right:auto;
}

/* ===================================================================
   7d. REPUTATION — a factual trust line, NOT invented quotes or star ratings.
   Real quotes replace this the moment Justin supplies them.
   =================================================================== */
.trustline {
  background:var(--surface); border:1px solid var(--border);
  border-radius:18px; padding:clamp(34px,5vw,52px) 28px;
  text-align:center; max-width:720px; margin:0 auto;
}
.trustline h3 {
  font-family:'Poppins',sans-serif; font-size:clamp(20px,2.8vw,26px);
  font-weight:600; letter-spacing:-.01em; line-height:1.35; max-width:26ch; margin:0 auto;
}
.trustline p { color:var(--muted); margin-top:16px; font-size:16px; max-width:46ch; margin-left:auto; margin-right:auto; }

/* ===================================================================
   7e. FAQ (plain answers people and AI assistants can quote)
   =================================================================== */
.faq { max-width:760px; margin:0 auto; display:grid; gap:12px; }
.faq details {
  background:var(--surface); border:1px solid var(--border); border-radius:14px;
  padding:4px 20px;
}
.section.alt .faq details { background:var(--bg); }
.faq summary {
  cursor:pointer; list-style:none; padding:16px 28px 16px 0; position:relative;
  font-weight:600; font-size:16.5px;
}
.faq summary::-webkit-details-marker { display:none; }
.faq summary::after {
  content:"+"; position:absolute; right:0; top:50%; transform:translateY(-50%);
  font-size:22px; font-weight:400; color:var(--primary);
}
.faq details[open] summary::after { content:"\2212"; }
.faq details p { color:var(--muted); padding:0 0 18px; font-size:16px; }

/* ===================================================================
   8. FINAL CTA (the person who scrolled this far is ready — ask again)
   =================================================================== */
.final {
  background:var(--surface);
  border-top:1px solid var(--border);
  text-align:center;
  padding:clamp(56px,8vw,92px) 0;
}
.final .statement { font-size:clamp(17px,2.2vw,20px); max-width:52ch; margin:0 auto; color:var(--text); line-height:1.65; }
.final h2 { font-size:clamp(20px,2.6vw,24px); font-weight:600; letter-spacing:.06em; text-transform:uppercase; margin:clamp(30px,4vw,42px) 0 22px; }

/* ===================================================================
   9. INNER PAGES (service pages, service area, projects)
   =================================================================== */
.page-head { text-align:center; padding:clamp(52px,8vw,88px) 0 clamp(30px,4vw,44px); }
.page-head h1 { font-size:clamp(32px,5vw,52px); font-weight:700; letter-spacing:-.02em; max-width:20ch; margin:0 auto; text-wrap:balance; }
.page-head p { color:var(--muted); max-width:52ch; margin:16px auto 0; }
.page-head .cta-row { margin-top:26px; }
.crumbs { font-size:13.5px; color:var(--muted); margin-bottom:14px; }
.crumbs a { color:var(--link); }

/* Photo grid — Jessica drops images in here over time. */
.project-grid {
  display:grid; gap:18px;
  grid-template-columns:repeat(auto-fit, minmax(280px,1fr));
  padding-bottom:clamp(48px,7vw,80px);
}
.project { background:var(--surface); border:1px solid var(--border); border-radius:16px; overflow:hidden; }
.project img { width:100%; aspect-ratio:4/3; object-fit:cover; display:block; }
.project .body { padding:18px 20px; }
.project h3 { font-size:17px; font-weight:600; margin-bottom:5px; }
.project p { font-size:14.5px; color:var(--muted); }

/* Empty state — shown until real photos go in */
.empty {
  border:1.5px dashed var(--border); border-radius:18px;
  padding:clamp(40px,7vw,68px) 26px; text-align:center;
  margin-bottom:clamp(48px,7vw,80px);
}
.empty svg { width:38px; height:38px; color:var(--primary); opacity:.55; margin-bottom:16px; }
.empty h3 { font-size:20px; font-weight:600; margin-bottom:8px; }
.empty p { color:var(--muted); max-width:44ch; margin:0 auto 22px; }

/* ===================================================================
   10. FOOTER (how do I reach these people — make it effortless)
   =================================================================== */
footer { padding:40px 0 34px; border-top:1px solid var(--border); text-align:center; }
footer .brand { color:var(--text); font-family:'Poppins',sans-serif; font-weight:700; font-size:17px; margin-bottom:6px; }
footer .row { color:var(--muted); font-size:14.5px; line-height:1.95; }
footer a.strong { color:var(--text); font-weight:600; }
footer a.strong:hover { color:var(--primary); }
footer .links { display:flex; flex-wrap:wrap; justify-content:center; gap:6px 20px; margin:14px 0 10px; }
footer .links a:hover { color:var(--text); }
footer .fine { font-size:13px; margin-top:8px; }
