/* Clearwater Plumbing & Heating — demo stylesheet (Wave 1, V0.4).
   Art direction: a clearwater flow atlas. One concentrated tidal-navy hero carrying
   branching waterline linework and a closed heating loop, then a mineral-white
   editorial service field of five numbered runs divided by fine rules, closed by a
   compact dark call band and a minimal footer. Clear-water teal is the dominant
   secondary colour; a restrained ember is reserved for junction marks only. */

:root {
  --navy: #04212f;
  --navy-2: #062b3d;
  --navy-3: #021821;
  --mineral: #f2f0ea;
  --paper: #fbfaf6;
  --teal: #12a7a2;
  --teal-bright: #2ec9bd;
  --teal-deep: #0a7d7a;
  --ember: #cf7233;
  --ink: #06222f;
  --body: #2b4652;
  --mute: #66808c;
  --rule: rgba(6, 34, 47, 0.16);
  --rule-soft: rgba(6, 34, 47, 0.09);
  --tile: rgba(18, 167, 162, 0.14);
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--mineral);
  color: var(--body);
  font-family: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  overflow-wrap: break-word;
}

h1, h2, h3 {
  margin: 0;
  color: var(--ink);
  font-weight: 800;
  letter-spacing: -0.024em;
  line-height: 1.05;
}

p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
svg { display: block; }

.micro {
  margin: 0;
  color: var(--mute);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(242, 240, 234, 0.96);
  border-bottom: 1px solid var(--rule);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 26px;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  min-height: 44px;
  color: var(--ink);
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.012em;
}

.brand-mark svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: var(--teal-deep);
  stroke-width: 1.8;
  stroke-linecap: round;
}

.brand-mark .mark-core { stroke: var(--ember); stroke-width: 2; }

.site-nav { margin-left: auto; }

.site-nav ul { display: flex; gap: 26px; }

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  color: #33525f;
  font-size: 0.85rem;
  border-bottom: 1px solid transparent;
}

.site-nav a:hover { color: var(--ink); border-bottom-color: var(--teal); }

.header-call {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  background: var(--navy);
  color: #eef7f6;
  font-size: 0.9rem;
  font-weight: 700;
  border-radius: 2px;
}

.header-call:hover { background: var(--teal-deep); }

.menu-toggle { display: none; }

/* ---------- hero ---------- */

.hero {
  position: relative;
  overflow: clip;
  background: var(--navy);
  color: #d7e6e6;
  padding: 74px 0 78px;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    to bottom,
    rgba(46, 201, 189, 0.10) 0 1px,
    transparent 1px 44px
  );
  opacity: 0.75;
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  top: -160px;
  right: -120px;
  width: 620px;
  height: 620px;
  background: radial-gradient(circle at center, rgba(18, 167, 162, 0.24), rgba(4, 33, 47, 0) 68%);
  pointer-events: none;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, 0.94fr);
  gap: 56px;
  align-items: center;
}

.hero-micro { color: var(--teal-bright); margin-bottom: 22px; }

.hero h1 {
  color: #f4f8f7;
  font-size: clamp(2.6rem, 4.7vw, 4.05rem);
  margin-bottom: 22px;
  max-width: 15ch;
}

.hero-key {
  max-width: 40ch;
  color: #a9c6c7;
  font-size: 1rem;
  line-height: 1.6;
  padding-top: 20px;
  border-top: 1px solid rgba(46, 201, 189, 0.24);
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
}

.btn-call {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 58px;
  padding: 0 24px;
  background: var(--teal-bright);
  color: #03202d;
  border-radius: 2px;
}

.btn-call:hover { background: #57ded2; }

.btn-call-label {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  opacity: 0.74;
}

.btn-call-number { font-size: 1.2rem; font-weight: 800; letter-spacing: 0.008em; }

.btn-quiet {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  color: #eaf4f4;
  font-size: 0.93rem;
  font-weight: 700;
  border-bottom: 2px solid rgba(46, 201, 189, 0.42);
}

.btn-quiet:hover { border-bottom-color: var(--teal-bright); }

.hero-figure { margin: 0; }

.atlas { width: 100%; height: auto; }

.hero-figure figcaption {
  margin-top: 16px;
  color: #7fa3a4;
  font-size: 0.65rem;
}

.atlas .halo { fill: rgba(18, 167, 162, 0.09); }

.atlas .pipes path {
  fill: none;
  stroke: #46d6c9;
  stroke-width: 3.2;
  stroke-linecap: round;
  opacity: 0.82;
}

.atlas .pipes.thin path {
  stroke-width: 1.6;
  opacity: 0.5;
}

.atlas .flow path {
  fill: none;
  stroke: #6ee7db;
  stroke-width: 2.2;
  stroke-dasharray: 11 8;
  opacity: 0.95;
}

.atlas .tip { fill: #6ee7db; }

.atlas .ends path {
  fill: none;
  stroke: #46d6c9;
  stroke-width: 3.2;
  stroke-linecap: round;
  opacity: 0.82;
}

.atlas .loop path {
  fill: none;
  stroke: #46d6c9;
  stroke-width: 3.4;
  stroke-linejoin: round;
  opacity: 0.95;
}

.atlas .valves path {
  fill: rgba(207, 114, 51, 0.18);
  stroke: var(--ember);
  stroke-width: 1.6;
  stroke-linejoin: round;
}

.atlas .gauge circle {
  fill: none;
  stroke: #46d6c9;
  stroke-width: 2.4;
  opacity: 0.9;
}

.atlas .gauge .gauge-inner { stroke-width: 1; opacity: 0.5; }

.atlas .gauge .ticks { stroke: #6ee7db; stroke-width: 2; opacity: 0.8; fill: none; }

.atlas .gauge .needle { stroke: var(--ember); stroke-width: 3.4; fill: none; }

.atlas .gauge .hub { fill: var(--ember); stroke: none; }

.atlas .nodes circle { fill: var(--ember); }

/* ---------- services ---------- */

.services {
  padding: 80px 0 88px;
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
}

.section-head h2 {
  font-size: clamp(1.75rem, 2.6vw, 2.35rem);
  margin-top: 14px;
  max-width: 22ch;
}

.runs { margin-top: 54px; }

.run {
  display: grid;
  grid-template-columns: 92px minmax(0, 0.86fr) minmax(0, 1.14fr);
  gap: 0 34px;
  align-items: start;
  padding: 30px 0 34px;
  border-top: 1px solid var(--rule);
}

.runs .run:last-child { border-bottom: 1px solid var(--rule); }

.run-index {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 4px;
}

.run-mark svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: var(--ember);
  stroke-width: 1.5;
  stroke-linejoin: round;
}

.run-no {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  color: var(--teal-deep);
}

.run-title { font-size: 1.22rem; }

.run-labels {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px 18px;
  padding-top: 4px;
}

.run-labels li {
  display: inline-flex;
  align-items: center;
  color: #2b4a56;
  font-size: 0.97rem;
}

.run-labels li + li::before {
  content: "";
  width: 4px;
  height: 4px;
  margin-right: 18px;
  border-radius: 50%;
  background: var(--teal);
  flex: none;
}

/* subtle tile-registration grid, behind the bathroom and kitchen label runs only */
.run--tile .run-labels {
  padding: 12px 18px 12px 14px;
  background-image:
    linear-gradient(to right, var(--tile) 1px, transparent 1px),
    linear-gradient(to bottom, var(--tile) 1px, transparent 1px);
  background-size: 26px 26px;
  -webkit-mask-image: linear-gradient(to right, #000 0%, #000 62%, transparent 100%);
  mask-image: linear-gradient(to right, #000 0%, #000 62%, transparent 100%);
}

/* ---------- address ---------- */

.address {
  padding: 52px 0 56px;
  background: var(--mineral);
  border-bottom: 1px solid var(--rule);
}

.address-inner {
  display: grid;
  grid-template-columns: minmax(0, 0.72fr) minmax(0, 1.28fr);
  gap: 24px 34px;
  align-items: end;
}

.address-id .micro { margin-bottom: 12px; }

.address-id h2 { font-size: 1.5rem; letter-spacing: -0.018em; }

.address-line {
  position: relative;
  padding-left: 26px;
  color: var(--ink);
  font-size: 1.22rem;
  font-weight: 700;
  letter-spacing: -0.012em;
  line-height: 1.4;
}

.address-line::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.34em;
  width: 12px;
  height: 12px;
  border: 2px solid var(--teal-deep);
  border-radius: 50%;
}

.address-line::after {
  content: "";
  position: absolute;
  left: 4px;
  top: calc(0.34em + 4px);
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--ember);
}

/* ---------- contact ---------- */

.contact {
  padding: 62px 0 66px;
  background: var(--navy-2);
  color: #cfe0e0;
}

.contact .micro { color: var(--teal-bright); }

.contact-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: 40px;
  align-items: center;
}

.contact h2 {
  color: #f4f8f7;
  font-size: clamp(1.75rem, 2.7vw, 2.4rem);
  margin: 14px 0 14px;
  max-width: 20ch;
}

.contact-note { color: #a7c2c3; font-size: 1rem; max-width: 36ch; }

.contact-action { display: flex; justify-content: flex-end; }

.contact .btn-call { box-shadow: 0 0 0 1px rgba(46, 201, 189, 0.3); }

/* ---------- footer ---------- */

.site-footer {
  background: var(--navy-3);
  color: #bdd2d2;
  padding: 44px 0 26px;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px 40px;
  padding-bottom: 26px;
  border-bottom: 1px solid rgba(46, 201, 189, 0.18);
}

.footer-name {
  color: #f0f6f5;
  font-weight: 800;
  font-size: 1rem;
  letter-spacing: -0.012em;
}

.footer-phone {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  margin-top: 4px;
  color: #f0f6f5;
  font-size: 1rem;
  font-weight: 700;
  border-bottom: 1px solid rgba(46, 201, 189, 0.36);
}

.footer-phone:hover { border-bottom-color: var(--teal-bright); }

.footer-nav { margin-left: auto; }

.footer-nav ul { display: flex; flex-wrap: wrap; gap: 22px; }

.footer-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  color: #a9c3c3;
  font-size: 0.85rem;
}

.footer-nav a:hover { color: #ffffff; }

.footer-base { padding-top: 20px; }

.footer-base p { color: #7f9b9c; font-size: 0.79rem; }

/* ---------- mobile call bar ---------- */

.mobile-call { display: none; }

/* ---------- narrow viewports ---------- */

@media (max-width: 900px) {
  .wrap { padding: 0 20px; }

  .header-inner { gap: 14px; min-height: 64px; }

  .brand { font-size: 0.79rem; letter-spacing: -0.008em; gap: 8px; }

  .brand-mark svg { width: 22px; height: 22px; }

  .header-call { display: none; }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    margin-left: auto;
    padding: 0 12px;
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--rule);
    border-radius: 2px;
    font: inherit;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    cursor: pointer;
  }

  .menu-bars {
    width: 15px;
    height: 2px;
    background: var(--teal-deep);
    box-shadow: 0 -5px 0 var(--teal-deep), 0 5px 0 var(--teal-deep);
  }

  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--rule);
  }

  .site-header.nav-open .site-nav { display: block; }

  .site-nav ul { flex-direction: column; gap: 0; padding: 6px 20px 14px; }

  .site-nav a {
    min-height: 46px;
    width: 100%;
    border-bottom: 1px solid var(--rule-soft);
  }

  .hero { padding: 40px 0 46px; }

  .hero::after { top: -200px; right: -180px; }

  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 36px; }

  .hero-micro { margin-bottom: 16px; }

  .hero h1 { font-size: clamp(2rem, 9vw, 2.6rem); max-width: none; margin-bottom: 18px; }

  .hero-key { font-size: 0.94rem; padding-top: 16px; margin-bottom: 26px; }

  .hero-actions { gap: 12px; }

  .btn-call {
    min-height: 58px;
    padding: 0 20px;
    width: 100%;
    justify-content: center;
  }

  .btn-quiet { min-height: 42px; }

  .hero-figure { max-width: 320px; margin: 0 auto; }

  .hero-figure figcaption { text-align: center; margin-top: 12px; }

  .services { padding: 54px 0 62px; }

  .section-head h2 { max-width: none; }

  .runs { margin-top: 34px; }

  .run {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    padding: 22px 0 24px;
  }

  .run-index { gap: 10px; padding-top: 0; }

  .run-title { font-size: 1.08rem; }

  .run-labels { gap: 8px 14px; padding-top: 2px; }

  .run-labels li { font-size: 0.9rem; }

  .run-labels li + li::before { margin-right: 14px; }

  .run--tile .run-labels { padding: 10px 14px 10px 12px; background-size: 22px 22px; }

  .address { padding: 44px 0 48px; }

  .address-inner { grid-template-columns: minmax(0, 1fr); gap: 18px; align-items: start; }

  .address-id h2 { font-size: 1.34rem; }

  .address-line { font-size: 1.06rem; padding-left: 24px; }

  .contact { padding: 48px 0 54px; }

  .contact-inner { grid-template-columns: minmax(0, 1fr); gap: 26px; }

  .contact h2 { font-size: 1.6rem; max-width: none; margin: 12px 0 12px; }

  .contact-note { font-size: 0.95rem; }

  .contact-action { justify-content: flex-start; }

  .contact .btn-call { min-height: 60px; }

  .site-footer { padding: 34px 0 20px; }

  .footer-inner { flex-direction: column; align-items: flex-start; gap: 20px; }

  .footer-nav { margin-left: 0; }

  .footer-nav ul { gap: 18px; }

  /* clearance for the fixed call bar — applied to the footer element itself so
     no .wrap rule can override it */
  .site-footer { padding-bottom: 108px; }

  .mobile-call {
    display: block;
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 0;
    z-index: 60;
    visibility: hidden;
    opacity: 0;
    transform: translateY(140%);
    pointer-events: none;
    transition: transform 0.28s ease, opacity 0.28s ease, visibility 0.28s ease;
  }

  .mobile-call.is-visible {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  .mobile-call a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 58px;
    padding: 0 18px;
    background: var(--teal-bright);
    color: #03202d;
    border-radius: 3px;
    box-shadow: 0 12px 28px rgba(2, 24, 33, 0.34);
  }

  .mobile-call-label {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.68rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    opacity: 0.74;
  }

  .mobile-call-number { font-size: 1.06rem; font-weight: 800; }
}