/* Torres Auto Glass Care — shared styles
   Palette pulled from the logo: deep navy, mid blue, ice-blue glass tint,
   plus the green edge-tint of laminated glass as a single accent. */

:root {
  --ink: #08192c;
  --navy: #12355b;
  --blue: #1b5fa8;
  --blue-bright: #3e86d6;
  --ice: #cfe3f2;
  --paper: #f5f8fb;
  --white: #ffffff;
  --laminate: #5fa898;

  --border: rgba(18, 53, 91, 0.14);
  --shadow-sm: 0 1px 2px rgba(8, 25, 44, 0.06), 0 4px 12px rgba(8, 25, 44, 0.06);
  --shadow-lg: 0 18px 50px rgba(8, 25, 44, 0.16);

  --display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Barlow", system-ui, -apple-system, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;

  --wrap: 1140px;
  --pad: clamp(1.15rem, 4vw, 2.5rem);
  --radius: 4px;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--blue); }

h1, h2, h3 {
  font-family: var(--display);
  font-style: italic;
  font-weight: 800;
  letter-spacing: -0.005em;
  line-height: 0.95;
  text-transform: uppercase;
  margin: 0;
}

h1 { font-size: clamp(2.9rem, 9vw, 5.6rem); }
h2 { font-size: clamp(2rem, 5.5vw, 3.1rem); }
h3 { font-size: clamp(1.3rem, 3vw, 1.6rem); }

p { margin: 0 0 1rem; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.eyebrow {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--blue);
  margin: 0 0 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--laminate);
  flex: none;
}

.lede { font-size: 1.12rem; color: #405672; max-width: 56ch; }

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 0.7rem 1rem;
  z-index: 200;
}
.skip:focus { left: 0.5rem; top: 0.5rem; }

:focus-visible {
  outline: 3px solid var(--laminate);
  outline-offset: 2px;
}

/* ---------- Header ---------- */

.masthead {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8, 25, 44, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(207, 227, 242, 0.16);
}

.masthead .wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--white);
  margin-right: auto;
}
.brand-mark {
  width: 74px;
  height: auto;
  flex: none;
}
.brand-name {
  font-family: var(--display);
  font-style: italic;
  font-weight: 800;
  font-size: 1.5rem;
  letter-spacing: 0.01em;
  line-height: 1;
  text-transform: uppercase;
}
.brand-sub {
  font-family: var(--mono);
  font-size: 0.55rem;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: var(--ice);
  display: block;
  margin-top: 3px;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid rgba(207, 227, 242, 0.35);
  color: var(--white);
  border-radius: var(--radius);
  padding: 0.45rem 0.7rem;
  font: 600 0.8rem/1 var(--body);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.6rem;
}

.nav a {
  color: var(--ice);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.3rem 0;
  border-bottom: 2px solid transparent;
}
.nav a:hover { color: var(--white); border-bottom-color: var(--blue-bright); }
.nav a.current { color: var(--white); border-bottom-color: var(--laminate); }

.lang {
  display: inline-flex;
  border: 1px solid rgba(207, 227, 242, 0.35);
  border-radius: var(--radius);
  overflow: hidden;
}
.lang button {
  background: none;
  border: 0;
  color: var(--ice);
  font: 600 0.75rem/1 var(--mono);
  letter-spacing: 0.1em;
  padding: 0.45rem 0.6rem;
  cursor: pointer;
}
.lang button[aria-pressed="true"] { background: var(--blue); color: var(--white); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--display);
  font-style: italic;
  font-weight: 700;
  font-size: 1.15rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  text-decoration: none;
  padding: 0.72rem 1.5rem;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.15s ease, color 0.15s ease;
}
.btn:active { transform: translateY(1px); }

.btn-primary { background: var(--blue); color: var(--white); }
.btn-primary:hover { background: var(--blue-bright); }

.btn-ghost { background: transparent; color: var(--white); border-color: rgba(207, 227, 242, 0.5); }
.btn-ghost:hover { border-color: var(--white); background: rgba(255, 255, 255, 0.08); }

.btn-dark { background: var(--ink); color: var(--white); }
.btn-dark:hover { background: var(--navy); }

.btn-outline { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: var(--white); }

.btn-row { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  background: var(--ink);
  color: var(--white);
  overflow: hidden;
  isolation: isolate;
}

.hero-sky {
  position: absolute;
  inset: 0;
  z-index: -3;
  background:
    radial-gradient(120% 90% at 72% 18%, rgba(62, 134, 214, 0.42), transparent 62%),
    linear-gradient(180deg, #0d233c 0%, #08192c 78%);
}

/* keeps the crack from ever fighting the headline */
.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(100deg, rgba(8, 25, 44, 0.82) 0%, rgba(8, 25, 44, 0.45) 42%, rgba(8, 25, 44, 0) 66%);
  pointer-events: none;
}

.hero-crack {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}
.hero-crack svg { width: 100%; height: 100%; }

.crack line, .crack path {
  fill: none;
  stroke: #eaf4ff;
  stroke-width: 2;
  stroke-linecap: round;
  opacity: 0.75;
  filter: drop-shadow(0 0 6px rgba(234, 244, 255, 0.55));
}
.crack .chip {
  fill: rgba(234, 244, 255, 0.5);
  stroke: none;
  opacity: 0.9;
  transform-box: fill-box;
  transform-origin: center;
}

.hero-inner {
  position: relative;
  z-index: 1;
  padding-block: clamp(3.5rem, 10vh, 6rem) clamp(3rem, 8vh, 4.5rem);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

.logo-plate {
  margin: 0;
  background: #fff;
  border-radius: 6px;
  padding: clamp(1.1rem, 2.6vw, 1.9rem);
  box-shadow: 0 26px 60px rgba(0, 0, 0, 0.45);
}
.logo-plate img { width: 100%; height: auto; }

.hero h1 { max-width: 20ch; text-wrap: balance; }
.hero h1 em { font-style: italic; color: var(--ice); }

.hero-sub {
  font-size: 1.15rem;
  color: var(--ice);
  max-width: 42ch;
  margin: 1.1rem 0 1.9rem;
}

.hero-note {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(207, 227, 242, 0.75);
  margin-top: 1.6rem;
  display: flex;
  align-items: center;
  gap: 0.55rem;
}
.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--laminate);
  flex: none;
  box-shadow: 0 0 0 3px rgba(95, 168, 152, 0.25);
}

/* ---------- Towns strip ---------- */

.towns {
  background: var(--navy);
  color: var(--ice);
  border-top: 1px solid rgba(207, 227, 242, 0.14);
}
.towns .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1.4rem;
  padding-block: 0.9rem;
}
.towns-label {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(207, 227, 242, 0.65);
}
.towns ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.1rem;
  list-style: none;
  margin: 0;
  padding: 0;
  font-family: var(--display);
  font-style: italic;
  font-weight: 700;
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

/* ---------- Sections ---------- */

.band { padding-block: clamp(3.5rem, 9vw, 6rem); }
.band-paper { background: var(--paper); }
.band-ink { background: var(--ink); color: var(--white); }
.band-ink .lede { color: var(--ice); }
.band-ink .eyebrow { color: var(--ice); }

.band-head { max-width: 62ch; margin-bottom: 2.5rem; }

.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 3px solid var(--blue);
  border-radius: var(--radius);
  padding: 1.6rem 1.5rem 1.7rem;
  box-shadow: var(--shadow-sm);
}
.card h3 { margin-bottom: 0.7rem; color: var(--navy); }
.card p { margin-bottom: 0.9rem; color: #405672; }
.card ul {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.95rem;
  color: #405672;
}
.card li { padding-left: 1.1rem; position: relative; margin-bottom: 0.35rem; }
.card li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 6px;
  height: 6px;
  background: var(--laminate);
}

.price-tag {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: var(--navy);
  background: var(--ice);
  display: inline-block;
  padding: 0.25rem 0.55rem;
  border-radius: 2px;
  margin-bottom: 0.9rem;
}

/* ---------- Process (a real sequence, so it's numbered) ---------- */

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.5rem;
  counter-reset: step;
}
.step { border-top: 1px solid rgba(207, 227, 242, 0.28); padding-top: 1rem; }
.step::before {
  counter-increment: step;
  content: "0" counter(step);
  display: block;
  font-family: var(--mono);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  color: var(--laminate);
  margin-bottom: 0.6rem;
}
.steps-plain { counter-reset: none; }
.steps-plain .step::before { content: none; }

.step h3 { font-size: 1.25rem; margin-bottom: 0.4rem; }
.step p { color: var(--ice); font-size: 0.97rem; margin: 0; }

/* ---------- Split (about) ---------- */

.split {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

.facts {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.facts dl { margin: 0; }
.facts dt {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--blue);
  margin-top: 1.1rem;
}
.facts dt:first-child { margin-top: 0; }
.facts dd { margin: 0.25rem 0 0; font-weight: 500; }

.quote-pull {
  border-left: 3px solid var(--laminate);
  padding-left: 1.2rem;
  margin: 2rem 0;
  font-family: var(--display);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  line-height: 1.15;
  color: var(--navy);
}

/* ---------- Form ---------- */

.form-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: clamp(2rem, 5vw, 3.5rem);
  align-items: start;
}

fieldset {
  border: 0;
  border-top: 1px solid var(--border);
  padding: 1.5rem 0 0;
  margin: 0 0 1.8rem;
}
legend {
  font-family: var(--display);
  font-style: italic;
  font-weight: 800;
  font-size: 1.25rem;
  text-transform: uppercase;
  color: var(--navy);
  padding: 0 0.6rem 0 0;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 1rem;
}

.field { display: flex; flex-direction: column; gap: 0.35rem; }
.field-wide { grid-column: 1 / -1; }

.field label {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--navy);
}
.field .hint { font-size: 0.8rem; color: #66798f; font-weight: 400; text-transform: none; letter-spacing: 0; }

input, select, textarea {
  font: 400 1rem/1.4 var(--body);
  color: var(--ink);
  background: var(--white);
  border: 1px solid rgba(18, 53, 91, 0.3);
  border-radius: var(--radius);
  padding: 0.65rem 0.7rem;
  width: 100%;
}
input:focus, select:focus, textarea:focus {
  border-color: var(--blue);
  outline: 3px solid rgba(95, 168, 152, 0.35);
  outline-offset: 0;
}
textarea { min-height: 110px; resize: vertical; }

.checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0.5rem; }
.check {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.95rem;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.6rem 0.7rem;
  cursor: pointer;
}
.check input { width: auto; margin: 0.2rem 0 0; flex: none; }
.check:has(input:checked) { border-color: var(--blue); background: #eaf3fc; }

.channel { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.channel label {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid rgba(18, 53, 91, 0.3);
  border-radius: var(--radius);
  padding: 0.55rem 0.85rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}
.channel label:has(input:checked) {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}
.channel input { width: auto; margin: 0; }

.form-status {
  font-size: 0.95rem;
  margin-top: 0.9rem;
  padding: 0.75rem 0.9rem;
  border-radius: var(--radius);
  border-left: 3px solid var(--laminate);
  background: var(--paper);
}
.form-status[data-state="error"] { border-left-color: #c0392b; background: #fdf1ef; }
.form-status:empty { display: none; }

.aside-card {
  background: var(--ink);
  color: var(--white);
  border-radius: var(--radius);
  padding: 1.6rem;
  position: sticky;
  top: 90px;
}
.aside-card h3 { color: var(--white); margin-bottom: 0.8rem; }
.aside-card p { color: var(--ice); font-size: 0.97rem; }
.aside-card a { color: var(--white); }
.aside-card .big-phone {
  font-family: var(--mono);
  font-size: 1.35rem;
  letter-spacing: 0.02em;
  display: block;
  margin: 0.4rem 0 1.2rem;
  text-decoration: none;
}

/* ---------- CTA ---------- */

.cta {
  background: var(--blue);
  color: var(--white);
  text-align: center;
  padding-block: clamp(3rem, 7vw, 4.5rem);
}
.cta h2 { margin-bottom: 0.8rem; }
.cta p { color: #e2eefb; max-width: 48ch; margin-inline: auto; }
.cta .btn-row { justify-content: center; margin-top: 1.6rem; }

/* ---------- Footer ---------- */

.footer {
  background: var(--ink);
  color: var(--ice);
  padding-block: 3rem 2rem;
  font-size: 0.94rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}
.footer h4 {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(207, 227, 242, 0.6);
  margin: 0 0 0.7rem;
}
.footer a { color: var(--ice); text-decoration: none; }
.footer a:hover { color: var(--white); text-decoration: underline; }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin-bottom: 0.35rem; }
.footer-base {
  margin-top: 2.5rem;
  padding-top: 1.2rem;
  border-top: 1px solid rgba(207, 227, 242, 0.16);
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.5rem;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(207, 227, 242, 0.55);
}

/* ---------- Responsive ---------- */

@media (max-width: 860px) {
  .split, .form-layout { grid-template-columns: 1fr; }
  .hero-inner { grid-template-columns: 1fr; }
  .logo-plate { max-width: 420px; }
  .hero-scrim { background: linear-gradient(180deg, rgba(8, 25, 44, 0.85) 0%, rgba(8, 25, 44, 0.5) 55%, rgba(8, 25, 44, 0.75) 100%); }
  .aside-card { position: static; }
}

@media (max-width: 720px) {
  .nav-toggle { display: inline-block; order: 3; }
  .nav {
    order: 4;
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
    padding-bottom: 1rem;
  }
  .nav.open { display: flex; }
  .nav a { width: 100%; padding: 0.6rem 0; border-bottom: 1px solid rgba(207, 227, 242, 0.12); }
  .masthead .wrap { flex-wrap: wrap; padding-block: 0.6rem; }
  .brand-mark { width: 56px; }
}

/* ---------- Crack animation ---------- */

.crack path {
  stroke-dasharray: var(--len, 900);
  stroke-dashoffset: 0;
  animation: seal 1.5s cubic-bezier(0.55, 0, 0.35, 1) forwards;
  animation-delay: 0.7s;
}
.crack .chip { animation: cure 0.7s ease 2.0s forwards; }

@keyframes seal { to { stroke-dashoffset: var(--len, 900); } }
@keyframes cure { to { opacity: 0; transform: scale(0.4); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .crack path, .crack .chip { animation: none; opacity: 0.28; }
  .btn { transition: none; }
}
