/* PipeVision Plumbers — shared styles. Mobile-first, no framework. */
:root {
  --navy: #0B2545;
  --navy-deep: #071a33;
  --navy-soft: #13335c;
  --blue: #1EA0FF;
  --blue-dark: #0a6fbf; /* AA-contrast blue for text on white */
  --red: #D62828;
  --red-dark: #b11f1f;
  --yellow: #FFC93C;
  --green: #3DDC84;
  --white: #ffffff;
  --ink: #142235;
  --muted: #4a5a70;
  --line: #dbe3ee;
  --bg-soft: #f3f7fc;
  --radius: 12px;
  --shadow: 0 6px 24px rgba(11, 37, 69, .12);
  --max: 1200px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  padding-bottom: 64px; /* room for mobile call bar */
}
img, svg { max-width: 100%; display: block; }
a { color: var(--blue-dark); }
a:hover { color: var(--navy); }
h1, h2, h3 { line-height: 1.15; color: var(--navy); margin: 0 0 .6em; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 6vw, 3.25rem); font-weight: 800; }
h2 { font-size: clamp(1.5rem, 4vw, 2.1rem); font-weight: 800; }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1em; }
ul { padding-left: 1.2em; }
li { margin-bottom: .35em; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; background: var(--white); color: var(--navy); padding: 10px 14px; border-radius: 8px; z-index: 200; font-weight: 700; }
.skip-link:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 48px; padding: .75em 1.3em; border-radius: 999px;
  font-weight: 700; font-size: 1rem; text-decoration: none; line-height: 1.2;
  border: 2px solid transparent; cursor: pointer; transition: background .15s, transform .15s;
}
.btn svg { width: 1.15em; height: 1.15em; flex: none; }
.btn-red { background: var(--red); color: var(--white); }
.btn-red:hover, .btn-red:focus-visible { background: var(--red-dark); color: var(--white); }
.btn-outline { background: transparent; color: var(--white); border-color: rgba(255,255,255,.7); }
.btn-outline:hover { background: rgba(255,255,255,.1); color: var(--white); }
.btn-outline-navy { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-outline-navy:hover { background: var(--navy); color: var(--white); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Header */
.site-header { background: var(--navy); position: sticky; top: 0; z-index: 100; box-shadow: 0 2px 12px rgba(0,0,0,.25); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 68px; }
.brand { display: block; flex: none; }
.brand img { height: 46px; width: auto; }
.header-actions { display: flex; align-items: center; gap: 8px; }
.header-call { display: none; }
.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 10px; border: 1px solid rgba(255,255,255,.3);
  background: transparent; color: var(--white); cursor: pointer;
}
.nav-toggle svg { width: 26px; height: 26px; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

.site-nav { display: none; order: 3; flex-basis: 100%; margin: 0 -20px; width: calc(100% + 40px); border-top: 1px solid rgba(255,255,255,.12); }
.header-inner { flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px; }
.site-nav.is-open { margin-top: 10px; margin-bottom: -10px; }
.site-nav.is-open { display: block; }
.site-nav ul { list-style: none; margin: 0; padding: 8px 0 16px; }
.site-nav li { margin: 0; }
.site-nav a {
  display: block; padding: 12px 20px; color: var(--white); text-decoration: none; font-weight: 600; white-space: nowrap;
}
.site-nav a:hover { color: var(--blue); }
.site-nav a[aria-current="page"] { color: var(--blue); box-shadow: inset 3px 0 0 var(--blue); }

@media (min-width: 700px) {
  .header-call { display: inline-flex; min-height: 44px; padding: .55em 1.1em; }
}
@media (min-width: 1120px) {
  .nav-toggle { display: none; }
  .header-inner { display: grid; grid-template-columns: auto 1fr auto; min-height: 80px; gap: 16px; }
  .brand img { height: 52px; }
  .site-nav, .site-nav.is-open { display: block !important; order: 0; margin: 0; width: auto; border: 0; }
  .header-inner { padding-top: 0; padding-bottom: 0; }
  .site-nav ul { display: flex; justify-content: center; gap: 0; padding: 0; }
  .site-nav a { padding: 10px 9px; font-size: .93rem; border-radius: 8px; }
  .site-nav a[aria-current="page"] { box-shadow: inset 0 -3px 0 var(--blue); border-radius: 0; }
}

/* Hero */
.hero {
  position: relative; overflow: hidden; color: var(--white);
  background: radial-gradient(120% 90% at 80% 10%, #123a6b 0%, var(--navy) 45%, var(--navy-deep) 100%);
}
.hero-pipes {
  position: absolute; inset: 0; width: 100%; height: 100%; opacity: .32; pointer-events: none;
}
@media (min-width: 900px) {
  .hero-pipes { opacity: .6;
    -webkit-mask-image: linear-gradient(90deg, rgba(0,0,0,.25) 0%, rgba(0,0,0,.35) 45%, #000 75%);
    mask-image: linear-gradient(90deg, rgba(0,0,0,.25) 0%, rgba(0,0,0,.35) 45%, #000 75%); }
}
.hero-inner { position: relative; display: grid; gap: 28px; padding: 44px 20px 48px; }
.eyebrow {
  display: inline-block; font-size: .8rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase;
  color: var(--blue); margin-bottom: .8em;
}
.hero h1 { color: var(--white); }
.hero .lead { font-size: 1.15rem; color: #d6e6f8; max-width: 38em; }
.hero-meta { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 8px; color: #cfe0f4; font-size: .98rem; }
.hero-meta li { display: flex; gap: 10px; align-items: flex-start; margin: 0; }
.hero-meta svg { width: 20px; height: 20px; flex: none; margin-top: 3px; color: var(--blue); }
.hero-art { border-radius: 16px; overflow: hidden; background: var(--white); box-shadow: 0 0 0 1px rgba(30,160,255,.35), 0 0 40px rgba(30,160,255,.25); }
.hero-art img { width: 100%; height: auto; }
@media (min-width: 900px) {
  .hero-inner { grid-template-columns: 1.05fr .95fr; align-items: center; padding: 72px 20px 80px; gap: 48px; }
}
.page-hero .hero-inner { padding: 44px 20px 40px; }
.page-hero h1 { font-size: clamp(1.9rem, 5vw, 2.8rem); }
@media (min-width: 900px) { .page-hero .hero-inner { grid-template-columns: 1fr; padding: 64px 20px 56px; } }

/* Pipe flow animation (subtle) */
.flow { stroke-dasharray: 14 22; animation: flow 3.5s linear infinite; }
.flow-slow { animation-duration: 6s; }
@keyframes flow { to { stroke-dashoffset: -72; } }
@media (prefers-reduced-motion: reduce) { .flow { animation: none; } }

/* Sections */
.section { padding: 56px 0; }
.section-soft { background: var(--bg-soft); }
.section-navy { background: var(--navy); color: #d6e6f8; }
.section-navy h2, .section-navy h3 { color: var(--white); }
.section-head { max-width: 46em; margin-bottom: 28px; }
.section-head p { color: var(--muted); }
.section-navy .section-head p { color: #cfe0f4; }
@media (min-width: 900px) { .section { padding: 80px 0; } }

/* Cards */
.grid { display: grid; gap: 18px; }
@media (min-width: 640px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 640px) and (max-width: 899px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow); position: relative;
}
.card h3 { margin-bottom: .4em; }
.card p { color: var(--muted); margin-bottom: .8em; }
.card .more { font-weight: 700; text-decoration: none; }
.card .more::after { content: " →"; }
.card-link { display: flex; flex-direction: column; }
.card-link .more { margin-top: auto; }
.card-link .more::before { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }
.card-link:hover { border-color: var(--blue); }
.card-icon {
  width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center;
  background: var(--navy); color: var(--blue); margin-bottom: 14px;
}
.card-icon svg { width: 26px; height: 26px; }
.pipe-tag { display: block; height: 4px; width: 48px; border-radius: 4px; margin-bottom: 14px; }
.tag-hot { background: var(--red); } .tag-cold { background: var(--blue); }
.tag-gas { background: var(--yellow); } .tag-sewer { background: var(--green); }

.chips { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 0; }
.chips li { margin: 0; padding: 8px 14px; border-radius: 999px; background: var(--white); border: 1px solid var(--line); font-weight: 600; color: var(--navy); font-size: .95rem; }
.section-navy .chips li { background: var(--navy-soft); border-color: rgba(255,255,255,.15); color: var(--white); }

/* Two-column content on service pages */
.split { display: grid; gap: 32px; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; gap: 48px; } }
.checklist { list-style: none; padding: 0; margin: 0; }
.checklist li { position: relative; padding-left: 32px; margin-bottom: .7em; }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: .35em; width: 18px; height: 18px; border-radius: 50%;
  background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L19 7'/%3E%3C/svg%3E") center/12px no-repeat;
}
.checklist.warn li::before {
  background: var(--red) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round'%3E%3Cpath d='M12 6v8M12 18h.01'/%3E%3C/svg%3E") center/12px no-repeat;
}

.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li { counter-increment: step; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 22px 22px 22px; margin: 0; }
.steps li::before {
  content: counter(step); display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%;
  background: var(--navy); color: var(--white); font-weight: 800; margin-bottom: 10px;
}
.steps strong { display: block; color: var(--navy); margin-bottom: 4px; font-size: 1.05rem; }
.steps span { color: var(--muted); }

.callout {
  border-left: 4px solid var(--red); background: #fff5f5; padding: 16px 18px; border-radius: 0 10px 10px 0; margin: 20px 0;
}
.callout p:last-child { margin: 0; }

/* CTA band */
.cta-band { background: linear-gradient(135deg, var(--navy) 0%, #123a6b 100%); color: var(--white); padding: 48px 0; position: relative; overflow: hidden; }
.cta-band::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px;
  background: linear-gradient(90deg, var(--red) 0 25%, var(--blue) 25% 50%, var(--yellow) 50% 75%, var(--green) 75% 100%);
  opacity: .85;
}
.cta-band h2 { color: var(--white); margin-bottom: .3em; }
.cta-band p { color: #cfe0f4; margin-bottom: 1.2em; }
.cta-inner { display: grid; gap: 12px; }
@media (min-width: 900px) { .cta-inner { grid-template-columns: 1.4fr 1fr; align-items: center; } .cta-inner .btn-row { justify-content: flex-end; } }

/* Request form placeholder */
.request-wrap { display: grid; gap: 28px; }
@media (min-width: 900px) { .request-wrap { grid-template-columns: 1.2fr .8fr; align-items: start; } }
#request-form {
  min-height: 220px; border: 2px dashed var(--blue); border-radius: var(--radius); background: var(--white);
  padding: 28px; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 12px;
}
#request-form .fallback-note { color: var(--muted); margin: 0; }
.info-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.info-list li { margin: 0; display: flex; gap: 12px; }
.info-list svg { width: 22px; height: 22px; color: var(--blue-dark); flex: none; margin-top: 3px; }
.info-list strong { display: block; color: var(--navy); }

/* Footer */
.site-footer { background: var(--navy-deep); color: #b9cbe2; padding: 40px 0 28px; font-size: .95rem; }
.footer-inner { display: grid; gap: 22px; }
.footer-line { margin: 0; color: var(--white); font-weight: 600; }
.footer-line a { color: var(--white); text-decoration: none; }
.footer-links { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.footer-links li { margin: 0; }
.footer-links a { color: #b9cbe2; text-decoration: none; }
.footer-links a:hover { color: var(--white); }
.social { display: flex; gap: 10px; }
.social a {
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  background: var(--navy-soft); color: var(--white);
}
.social a:hover { background: var(--blue); color: var(--white); }
.social svg { width: 20px; height: 20px; }
.footer-small { color: #8fa5c2; font-size: .85rem; margin: 0; }
@media (min-width: 900px) { .footer-inner { grid-template-columns: 1fr auto; align-items: center; } }

/* Mobile sticky call bar */
.call-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 150;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 56px; padding: 8px 16px calc(8px + env(safe-area-inset-bottom));
  background: var(--red); color: var(--white); font-weight: 800; font-size: 1.1rem; text-decoration: none;
  box-shadow: 0 -4px 16px rgba(0,0,0,.25);
}
.call-bar:hover, .call-bar:focus-visible { background: var(--red-dark); color: var(--white); }
.call-bar svg { width: 22px; height: 22px; }
@media (min-width: 1000px) { .call-bar { display: none; } body { padding-bottom: 0; } }

/* 404 */
.notfound { text-align: left; }
@media (min-width: 900px) { .checklist.cols-2 { columns: 2; column-gap: 48px; } .checklist.cols-2 li { break-inside: avoid; } }
.nowrap { white-space: nowrap; }
@media (max-width: 479px) { #request-form { padding: 20px; } }
#request-form .btn { padding-left: 1em; padding-right: 1em; font-size: .97rem; }
@media (max-width: 899px) { .hero-art { max-width: 560px; } }
