/* Hermitage Rapid Plumbing — shared styles */

:root {
  --forest: #12459A;
  --forest-dark: #0A2C63;
  --cream: #FFF6E7;
  --white: #FFFFFF;
  --brass: #F2661C;
  --brass-light: #FF8A42;
  --ink: #17191D;
  --hairline: #F0DCC0;
  --alert: #E5342A;

  --radius: 6px;
  --shadow-sm: 0 1px 2px rgba(26, 29, 33, 0.06), 0 2px 8px rgba(26, 29, 33, 0.06);
  --shadow-md: 0 4px 12px rgba(26, 29, 33, 0.08), 0 2px 4px rgba(26, 29, 33, 0.06);
  --shadow-lg: 0 12px 32px rgba(10, 44, 99, 0.18);

  --container: 1180px;
  --gap: clamp(3rem, 6vw, 6rem);

  --font-head: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", "SFMono-Regular", Menlo, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--ink);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.02;
  margin: 0;
  letter-spacing: 0.2px;
}

h1 { font-size: clamp(2.75rem, 7vw, 5rem); }
h2 { font-size: clamp(2.1rem, 4.5vw, 3.2rem); }
h3 { font-size: clamp(1.4rem, 2.5vw, 1.75rem); }

p { margin: 0 0 1rem; }

em { font-style: italic; color: inherit; }

a { color: inherit; text-decoration: none; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brass);
  margin-bottom: 0.9rem;
}

section { position: relative; }

.section {
  padding: clamp(3.5rem, 8vw, 6.5rem) 0;
}

.section--white { background: var(--white); }
.section--cream { background: var(--cream); }

.section-head {
  max-width: 640px;
  margin-bottom: clamp(2rem, 5vw, 3.25rem);
}

.section-head--center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.lede {
  font-size: 1.1rem;
  color: #4a4f47;
  max-width: 56ch;
  margin-top: 0.9rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.98rem;
  padding: 0.85rem 1.6rem;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 150ms ease, background 150ms ease, border-color 150ms ease;
  white-space: nowrap;
}

.btn-brass {
  background: var(--brass);
  color: var(--white);
  box-shadow: var(--shadow-sm);
}
.btn-brass:hover { background: #C74F12; box-shadow: var(--shadow-md); transform: translateY(-1px); }

.btn-forest {
  background: var(--forest);
  color: var(--cream);
  box-shadow: var(--shadow-sm);
}
.btn-forest:hover { background: var(--forest-dark); box-shadow: var(--shadow-md); transform: translateY(-1px); }

.btn-outline {
  background: transparent;
  border-color: rgba(255,255,255,0.55);
  color: inherit;
}
.btn-outline:hover { background: rgba(255,255,255,0.12); }

.btn-ghost-dark {
  background: transparent;
  border-color: var(--forest);
  color: var(--forest);
}
.btn-ghost-dark:hover { background: var(--forest); color: var(--cream); }

.btn-lg { padding: 1.05rem 2.1rem; font-size: 1.05rem; }
.btn-block { width: 100%; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(245, 241, 232, 0.94);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--hairline);
  transition: box-shadow 200ms ease;
}
.site-header.is-scrolled { box-shadow: var(--shadow-sm); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
}

.brand {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}
.brand-name {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.45rem;
  color: var(--forest);
  letter-spacing: 0.2px;
}
.brand-area {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #6b6558;
  margin-top: 0.15rem;
}

.main-nav {
  display: none;
  align-items: center;
  gap: 1.9rem;
  font-weight: 600;
  font-size: 0.95rem;
}
.main-nav a { padding: 0.3rem 0; border-bottom: 2px solid transparent; transition: border-color 150ms ease, color 150ms ease; }
.main-nav a:hover, .main-nav a[aria-current="page"] { border-color: var(--brass); color: var(--forest); }

.header-actions { display: flex; align-items: center; gap: 0.9rem; }

.header-call {
  display: none;
}

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius);
  border: 1px solid var(--hairline);
  background: var(--white);
  cursor: pointer;
}
.nav-toggle svg { width: 20px; height: 20px; }

.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.5rem 0 1.1rem;
  border-top: 1px solid var(--hairline);
}
.mobile-nav.is-open { display: flex; }
.mobile-nav a {
  padding: 0.85rem 0.25rem;
  font-weight: 600;
  border-bottom: 1px solid var(--hairline);
}

@media (min-width: 900px) {
  .main-nav { display: flex; }
  .header-call { display: inline-flex; }
  .nav-toggle { display: none; }
  .mobile-nav { display: none !important; }
}

/* Hero */
.hero {
  position: relative;
  min-height: min(88vh, 720px);
  display: flex;
  align-items: flex-end;
  color: var(--white);
  background-size: cover;
  background-position: center;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18,69,154,0.55) 0%, rgba(10,44,99,0.68) 55%, rgba(10,44,99,0.85) 100%);
}
.hero-inner {
  position: relative;
  z-index: 1;
  padding-bottom: clamp(2.5rem, 6vw, 4.5rem);
  padding-top: clamp(6rem, 14vw, 9rem);
}
.hero h1 {
  color: var(--white);
  text-shadow: 0 2px 24px rgba(0,0,0,0.25);
  max-width: 15ch;
}
.hero-sub {
  margin-top: 1.1rem;
  font-size: 1.15rem;
  max-width: 42ch;
  color: rgba(245,241,232,0.92);
}
.hero-actions {
  margin-top: 1.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

/* Proof strip */
.proof-strip {
  background: var(--forest);
  color: var(--cream);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.85rem 0;
  text-align: center;
}
.proof-strip .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem 0.9rem;
}
.proof-strip .dot { opacity: 0.5; }
.proof-strip .star { color: var(--brass-light); }

/* Emergency band */
.emergency-band {
  background: var(--alert);
  color: var(--white);
  padding: 1.6rem 0;
}
.emergency-band .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem 1.6rem;
  text-align: center;
}
.emergency-band p {
  margin: 0;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(1.15rem, 2.6vw, 1.55rem);
  letter-spacing: 0.2px;
}
.emergency-band .btn-outline { border-color: rgba(255,255,255,0.7); }
.emergency-band .btn-outline:hover { background: rgba(255,255,255,0.16); }

/* Grid layouts */
.grid {
  display: grid;
  gap: 1.4rem;
}
.grid-3 { grid-template-columns: repeat(1, 1fr); }
.grid-2 { grid-template-columns: repeat(1, 1fr); }
.grid-4 { grid-template-columns: repeat(1, 1fr); }
@media (min-width: 640px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { 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); }
}

/* Cards */
.card {
  background: var(--white);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 1.9rem 1.7rem;
  transition: box-shadow 200ms ease, transform 200ms ease;
}
.card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

.service-card { display: flex; flex-direction: column; gap: 0.6rem; }
.service-card .icon {
  width: 44px; height: 44px;
  border-radius: var(--radius);
  background: var(--cream);
  display: flex; align-items: center; justify-content: center;
  color: var(--brass);
  margin-bottom: 0.4rem;
}
.service-card .icon svg { width: 24px; height: 24px; }
.service-card h3 { color: var(--forest); }
.service-card p { color: #4a4f47; margin: 0; }
.service-card .card-link {
  margin-top: 0.5rem;
  font-weight: 700;
  color: var(--brass);
  font-size: 0.92rem;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

/* Why us numbered blocks */
.why-block { display: flex; gap: 1.2rem; align-items: flex-start; }
.why-num {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 3.2rem;
  color: var(--brass);
  line-height: 0.9;
  flex-shrink: 0;
  width: 3ch;
}
.why-text h3 { color: var(--forest); margin-bottom: 0.4rem; }
.why-text p { color: #4a4f47; margin: 0; }

/* Testimonials */
.testimonial { display: flex; flex-direction: column; gap: 0.8rem; }
.stars { color: var(--brass); letter-spacing: 0.1em; font-size: 1rem; }
.testimonial p { color: #333; margin: 0; font-size: 1rem; }
.testimonial-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #6b6558;
  margin-top: 0.3rem;
}

/* Image band */
.image-band {
  height: clamp(220px, 38vw, 420px);
  background-size: cover;
  background-position: center;
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
}

/* Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.7rem;
}
@media (min-width: 700px) {
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
}
.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  aspect-ratio: 4 / 3;
  box-shadow: var(--shadow-sm);
}
.gallery-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 450ms ease;
}
.gallery-item:hover img { transform: scale(1.06); }
.gallery-caption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 0.6rem 0.8rem 0.55rem;
  background: linear-gradient(0deg, rgba(10,44,99,0.78), rgba(10,44,99,0));
  color: var(--cream);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* CTA bands */
.cta-band {
  background: var(--forest);
  color: var(--cream);
  border-radius: var(--radius);
  padding: clamp(2.2rem, 5vw, 3.2rem);
  text-align: center;
  box-shadow: var(--shadow-md);
}
.cta-band h2, .cta-band h3 { color: var(--white); }
.cta-band p { color: rgba(245,241,232,0.85); }
.cta-band .btn-actions {
  margin-top: 1.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  justify-content: center;
}
.cta-inline {
  margin-top: clamp(2rem, 5vw, 3rem);
}

/* Services page detail */
.service-detail {
  padding: clamp(2.4rem, 5vw, 3.2rem) 0;
  border-bottom: 1px solid var(--hairline);
}
.service-detail:last-of-type { border-bottom: none; }
.service-detail-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
}
@media (min-width: 860px) {
  .service-detail-grid { grid-template-columns: 1fr 1.1fr; align-items: start; }
}
.service-detail h3 { color: var(--forest); font-size: clamp(1.7rem, 3vw, 2.1rem); margin-bottom: 0.9rem; }
.service-detail ul {
  margin: 1.1rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.55rem;
}
.service-detail li {
  padding-left: 1.5rem;
  position: relative;
  color: #3d4238;
}
.service-detail li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.5em;
  width: 8px; height: 8px;
  border-radius: 2px;
  background: var(--brass);
}
.service-detail p { color: #4a4f47; }

/* Service area list */
.area-list {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1rem;
}
@media (min-width: 640px) {
  .area-list { grid-template-columns: repeat(2, 1fr); }
}
.area-card {
  background: var(--white);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  padding: 1.3rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.area-card .town { font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; color: var(--forest); }
.area-card .zip { font-family: var(--font-mono); font-size: 0.85rem; color: #6b6558; }

/* Owner section */
.owner-block {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
  align-items: center;
}
@media (min-width: 760px) {
  .owner-block { grid-template-columns: 0.8fr 1.2fr; }
}
.owner-photo {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  aspect-ratio: 4 / 5;
}
.owner-photo img { width: 100%; height: 100%; object-fit: cover; }
.owner-copy .sig {
  margin-top: 1.2rem;
  font-family: var(--font-head);
  font-size: 1.4rem;
  color: var(--forest);
}
.owner-copy .sig span { display: block; font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.06em; text-transform: uppercase; color: #6b6558; margin-top: 0.2rem; }

/* Contact page */
.tap-call-block {
  background: var(--forest);
  color: var(--white);
  border-radius: var(--radius);
  padding: clamp(2rem, 5vw, 3rem);
  text-align: center;
  box-shadow: var(--shadow-md);
}
.tap-call-block .eyebrow { color: var(--brass-light); }
.tap-call-block a.phone-link {
  display: inline-block;
  margin-top: 0.8rem;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: clamp(2.2rem, 7vw, 3.6rem);
  color: var(--white);
  letter-spacing: 0.5px;
}
.tap-call-block a.phone-link:hover { color: var(--brass-light); }
.tap-call-block .btn { margin-top: 1.5rem; }

.form-card {
  background: var(--white);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: clamp(1.8rem, 4vw, 2.6rem);
}
.form-row { margin-bottom: 1.2rem; }
.form-row label {
  display: block;
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
  color: var(--forest);
}
.form-row input,
.form-row select {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  background: var(--cream);
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
}
.form-row input:focus,
.form-row select:focus {
  outline: 2px solid var(--brass);
  outline-offset: 1px;
  background: var(--white);
}
.form-note {
  margin-top: 1rem;
  font-size: 0.88rem;
  color: #6b6558;
}
.form-success {
  display: none;
  background: #eef4ee;
  border: 1px solid #b9d3ba;
  color: #24512a;
  border-radius: var(--radius);
  padding: 1rem 1.2rem;
  margin-bottom: 1.2rem;
  font-weight: 600;
}
.form-success.is-visible { display: block; }

.hours-table {
  width: 100%;
  border-collapse: collapse;
}
.hours-table td {
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--hairline);
}
.hours-table td:last-child { text-align: right; font-weight: 600; color: var(--forest); }
.hours-table tr:last-child td { border-bottom: none; }

/* Footer */
.site-footer {
  background: var(--forest-dark);
  color: rgba(245,241,232,0.82);
  padding: clamp(3rem, 6vw, 4.5rem) 0 6.5rem;
}
.footer-grid {
  display: grid;
  gap: 2.2rem;
  grid-template-columns: 1fr;
}
@media (min-width: 760px) {
  .footer-grid { grid-template-columns: 1.3fr 1fr 1fr 1fr; }
}
.footer-brand { font-family: var(--font-head); font-weight: 800; font-size: 1.5rem; color: var(--white); }
.footer-tag { margin-top: 0.6rem; font-size: 0.92rem; max-width: 32ch; color: rgba(245,241,232,0.7); }
.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brass-light);
  margin-bottom: 0.8rem;
}
.footer-col p, .footer-col a { display: block; font-size: 0.92rem; color: rgba(245,241,232,0.82); margin-bottom: 0.5rem; }
.footer-col a:hover { color: var(--white); }
.footer-bottom {
  margin-top: 2.8rem;
  padding-top: 1.6rem;
  border-top: 1px solid rgba(245,241,232,0.14);
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.2rem;
  justify-content: space-between;
  font-size: 0.8rem;
  color: rgba(245,241,232,0.55);
}
.footer-bottom .demo-note { font-style: italic; }

/* Fixed mobile call bar */
.mobile-call-bar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 200;
  background: var(--forest);
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 0.7rem 1rem;
  padding-bottom: calc(0.7rem + env(safe-area-inset-bottom));
  display: flex;
  align-items: center;
  justify-content: center;
}
.mobile-call-bar a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
  max-width: 480px;
  color: var(--white);
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.15rem;
  padding: 0.65rem;
  background: var(--brass);
  border-radius: var(--radius);
}
.mobile-call-bar svg { width: 20px; height: 20px; }
body { padding-bottom: 68px; }
@media (min-width: 900px) {
  .mobile-call-bar { display: none; }
  body { padding-bottom: 0; }
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 400ms ease, transform 400ms ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .gallery-item img { transition: none; }
  .gallery-item:hover img { transform: none; }
}

/* Utility */
.text-center { text-align: center; }
.mt-lg { margin-top: clamp(2.5rem, 5vw, 4rem); }
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}
