/* Platinum Roofing & Construction mockup. Layout after the BuildPro Idaho homepage.
   Colors from their logo and site CSS: teal #7DD6C6 / #0ABAB4, darkened for readable text. */
:root {
  --teal: #7dd6c6;
  --teal-strong: #0a7c78;   /* white text passes AA (5.2:1) */
  --teal-hover: #086663;
  --dark: #123332;
  --dark-2: #1c4645;
  --ink: #142222;
  --slate: #4d5b5c;
  --light: #f1f7f6;
  --white: #fff;
  --font: "Source Sans 3", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --serif: "Playfair Display", Georgia, serif;
  --pad: 2.5rem;
  --section: 6rem;
  --radius: 10px;
  --radius-lg: 20px;
  --ribbon-h: 1.75rem;
}
@media (max-width: 991px) { :root { --pad: 1.5rem; --section: 4.5rem; } }
@media (max-width: 479px) { :root { --pad: 1rem; --section: 3.75rem; } }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 6rem; }
body { margin: 0; font-family: var(--font); font-size: 1.125rem; line-height: 1.6; color: var(--ink); background: var(--light); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-family: var(--serif); font-weight: 700; line-height: 1.12; color: var(--heading, var(--dark)); text-wrap: balance; }
h2 { font-size: clamp(2rem, 3.4vw, 2.75rem); }
h3 { font-size: 1.3rem; line-height: 1.25; }
:focus-visible { outline: 3px solid var(--teal-strong); outline-offset: 3px; }
.container { width: 100%; max-width: calc(76rem + var(--pad) * 2); margin-inline: auto; padding-inline: var(--pad); }
.section { padding-block: var(--section); }
.stack { display: flex; flex-direction: column; gap: 1rem; align-items: flex-start; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
@media (max-width: 991px) { .grid-2 { grid-template-columns: 1fr; gap: 2.5rem; } }
.section-head { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 3.5rem; }
.section-head.center { align-items: center; text-align: center; }
.measure { max-width: 38rem; }
.muted { color: var(--muted, var(--slate)); }
.small { font-size: .9375rem; }
.tagline { font-size: .875rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent, var(--teal-strong)); }
.s-light { background: var(--light); }
.s-white { background: var(--white); }
.s-dark { background: var(--dark); color: var(--white); --heading: var(--white); --muted: rgb(255 255 255 / .8); --accent: var(--teal); }

/* Ribbon */
.ribbon {
  position: fixed; inset: 0 0 auto; z-index: 70; height: var(--ribbon-h);
  display: flex; align-items: center; justify-content: center; padding-inline: .75rem;
  background: #0b1f1f; color: rgb(255 255 255 / .85); font-size: .75rem; line-height: 1.2; text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
@media (max-width: 599px) { :root { --ribbon-h: 2.25rem; } .ribbon { white-space: normal; font-size: .6875rem; } }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 3.25rem; padding: .8rem 1.6rem; border-radius: 999px; border: 1.5px solid transparent;
  background: var(--teal-strong); color: var(--white); font-size: 1rem; font-weight: 700; line-height: 1.2;
  text-decoration: none; cursor: pointer; font-family: inherit; transition: background-color .2s;
}
.btn:hover { background: var(--teal-hover); }
.btn-light { background: var(--white); color: var(--dark); }
.btn-light:hover { background: var(--light); }
.btn-sm { min-height: 2.75rem; padding: .55rem 1.15rem; font-size: .9375rem; }
.btn-block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; }
.i { width: 1.15rem; height: 1.15rem; fill: currentColor; flex: none; }

/* Nav */
.nav { position: fixed; inset: var(--ribbon-h) 0 auto; z-index: 50; background: var(--dark); box-shadow: 0 2px 16px rgb(0 0 0 / .18); }
.nav-bar { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; height: 4.5rem; }
.logo img { height: 3.1rem; width: auto; }
.nav-links { display: flex; gap: 2rem; }
.nav-links a { color: rgb(255 255 255 / .9); text-decoration: none; font-weight: 600; font-size: 1rem; }
.nav-links a:hover { color: var(--teal); }
.nav-call { background: var(--teal); color: var(--dark); }
.nav-call:hover { background: #a3e4d8; }
@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-bar { height: 4rem; }
  .logo img { height: 2.6rem; }
}

/* Hero */
.hero { padding: calc(var(--ribbon-h) + 4.5rem + 1rem) 1rem 0; }
.hero-card {
  position: relative; isolation: isolate; overflow: hidden; max-width: 90rem; margin-inline: auto;
  min-height: min(40rem, calc(100svh - 8rem)); border-radius: 26px; background: var(--dark);
  display: flex; align-items: flex-end; padding: 6rem 4rem 4rem; color: var(--white);
}
.hero-card > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 60%; z-index: -2; }
.hero-card::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, rgb(10 30 30 / .82) 0%, rgb(10 30 30 / .55) 45%, rgb(10 30 30 / .1) 80%),
              linear-gradient(180deg, rgb(10 30 30 / 0) 50%, rgb(10 30 30 / .45) 100%);
}
.hero-copy { display: flex; flex-direction: column; gap: 1.25rem; max-width: 44rem; }
.hero-copy .tagline { color: var(--teal); }
.hero h1 { font-size: clamp(2.4rem, 4.6vw, 3.9rem); line-height: 1.06; color: var(--white); text-shadow: 0 2px 18px rgb(0 0 0 / .3); }
.lead { font-size: 1.25rem; line-height: 1.5; color: rgb(255 255 255 / .94); max-width: 36rem; }
@media (max-width: 860px) {
  .hero { padding: calc(var(--ribbon-h) + 4rem + .75rem) .75rem 0; }
  .hero-card { min-height: 0; padding: 9rem 1.25rem 1.5rem; border-radius: 20px; }
  .hero-card::before { background: linear-gradient(180deg, rgb(10 30 30 / .1) 0%, rgb(10 30 30 / .55) 35%, rgb(10 30 30 / .9) 70%); }
  .hero-card > img { object-position: 45% 80%; }
  .hero-copy .tagline { font-size: .75rem; }
  .hero h1 { font-size: 1.95rem; }
  .lead { font-size: 1.0625rem; }
  .hero .btn-row { flex-direction: column; }
  .hero .btn { width: 100%; }
}

/* Trust strip */
.trust { padding-block: 2.5rem 1rem; }
.trust-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.trust-item { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .2rem; padding: .5rem 1.25rem; text-decoration: none; }
.trust-item + .trust-item { border-left: 1px solid rgb(20 34 34 / .14); }
.trust-item strong { font-family: var(--serif); font-size: 1.3rem; line-height: 1.2; color: var(--dark); }
.trust-item span { font-size: .9375rem; line-height: 1.4; color: var(--slate); }
.trust-google .stars { color: #b7791f; font-size: 1.1rem; letter-spacing: .1em; }
.trust-google:hover strong { text-decoration: underline; }
@media (max-width: 860px) {
  .trust-grid { grid-template-columns: 1fr 1fr; row-gap: 1.75rem; }
  .trust-item { padding-inline: .5rem; }
  .trust-item + .trust-item { border-left: 0; }
  .trust-item strong { font-size: 1.1rem; }
  .trust-item span { font-size: .875rem; }
}

/* Services */
.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.svc-card { display: flex; flex-direction: column; gap: .6rem; padding: 2rem; border-radius: var(--radius-lg); background: var(--white); box-shadow: 0 2px 14px -8px rgb(18 51 50 / .45); }
.svc-icon { display: grid; place-items: center; width: 3.25rem; height: 3.25rem; border-radius: 12px; background: #dff3ef; color: var(--teal-strong); margin-bottom: .5rem; }
.svc-icon svg { width: 1.7rem; height: 1.7rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.svc-kicker { font-size: .8125rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--teal-strong); }
.svc-card p { color: var(--slate); font-size: 1rem; }
@media (max-width: 991px) { .svc-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 599px) { .svc-grid { grid-template-columns: 1fr; gap: 1rem; } .svc-card { padding: 1.5rem; } }

/* Work gallery */
.work-panel { background: var(--dark); color: var(--white); border-radius: 26px; padding: 3.5rem; --heading: var(--white); }
.work-panel .tagline { color: var(--teal); }
.work-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; margin-bottom: 2.5rem; }
.work-head h2 { margin-top: .75rem; }
.work-head p { max-width: 22rem; color: rgb(255 255 255 / .78); font-size: 1rem; }
.work-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.work-card { position: relative; isolation: isolate; overflow: hidden; margin: 0; aspect-ratio: 4 / 5; border-radius: 18px; background: var(--dark-2); display: flex; align-items: flex-end; }
.work-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.work-card::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgb(10 30 30 / 0) 45%, rgb(10 30 30 / .88) 100%); }
.work-card figcaption { display: flex; flex-direction: column; align-items: flex-start; gap: .5rem; padding: 1.25rem; font-size: 1.2rem; font-weight: 700; line-height: 1.25; }
.work-tag { padding: .25rem .6rem; border-radius: 999px; background: var(--teal); color: var(--dark); font-size: .6875rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
@media (max-width: 860px) {
  .work-panel { padding: 2rem 1.25rem; border-radius: 20px; }
  .work-head { flex-direction: column; align-items: flex-start; gap: .75rem; margin-bottom: 1.5rem; }
  .work-grid { grid-template-columns: 1fr; }
  .work-card { aspect-ratio: 4 / 3; }
}

/* Steps */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem; }
.step { display: flex; flex-direction: column; gap: .75rem; padding-top: 1.5rem; border-top: 2px solid var(--teal); }
.step-num { font-family: var(--serif); font-size: 3.5rem; font-weight: 700; line-height: 1; color: var(--teal-strong); }
.step p { color: var(--slate); font-size: 1rem; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; gap: 2rem; } .step-num { font-size: 2.75rem; } }

/* Service area */
.town-list { display: flex; flex-wrap: wrap; gap: .6rem; margin: 0; padding: 0; list-style: none; }
.town-list li { padding: .55rem 1.1rem; border: 1px solid rgb(20 34 34 / .15); border-radius: 999px; background: var(--white); font-weight: 600; font-size: 1.0625rem; }

/* Form */
.estimate { align-items: start; }
.form { display: grid; gap: 1.1rem; padding: 2rem; border-radius: var(--radius-lg); background: var(--white); color: var(--ink); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }
.field { display: flex; flex-direction: column; gap: .4rem; }
.field label { font-weight: 600; font-size: .9375rem; }
.field input, .field textarea { width: 100%; padding: .8rem 1rem; font: inherit; font-size: 1rem; border: 1.5px solid rgb(20 34 34 / .25); border-radius: var(--radius); background: var(--white); color: var(--ink); }
.field textarea { min-height: 7rem; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--teal-strong); box-shadow: 0 0 0 3px rgb(10 124 120 / .2); }
.form-status { padding: .9rem 1.1rem; border-radius: var(--radius); background: #e3f4f0; color: #0b4a47; font-weight: 600; font-size: 1rem; }
.form-status[hidden] { display: none; }
@media (max-width: 599px) { .form { padding: 1.25rem; } .form-row { grid-template-columns: 1fr; } }

/* Footer */
.footer { background: #0b1f1f; color: rgb(255 255 255 / .82); padding-block: 4rem 2rem; font-size: 1rem; --heading: var(--white); }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 2.5rem; }
.footer-logo { height: 3.5rem; width: auto; }
.footer strong { color: var(--white); }
.footer a { color: rgb(255 255 255 / .9); text-decoration: none; }
.footer a:hover { color: var(--teal); }
.footer-heading { font-family: var(--font); font-size: 1rem; font-weight: 700; }
.footer-bottom { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid rgb(255 255 255 / .15); font-size: .875rem; color: rgb(255 255 255 / .7); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr; gap: 2rem; } }

/* Mobile call bar */
.call-bar { display: none; }
@media (max-width: 767px) {
  body { padding-bottom: calc(5rem + env(safe-area-inset-bottom)); }
  .call-bar {
    display: grid; grid-template-columns: 1fr 1fr; gap: .75rem;
    position: fixed; inset: auto 0 0; z-index: 40;
    padding: .7rem 1rem calc(.8rem + env(safe-area-inset-bottom));
    background: rgb(11 31 31 / .92); border-top: 1px solid rgb(255 255 255 / .1);
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  }
  .call-bar a { display: flex; align-items: center; justify-content: center; min-height: 3.25rem; border-radius: .625rem; font-weight: 700; font-size: 1.0625rem; text-decoration: none; }
  .call-bar-call { background: var(--teal); color: var(--dark); }
  .call-bar-quote { border: 1.5px solid rgb(255 255 255 / .85); color: var(--white); }
}
