/* Miami Mobile Window Tinting. Tokens and rules follow design-system/miami-mobile-window-tinting/MASTER.md.
   .field--*  = one flat color section; it sets --bg, --fg, --soft, --rule and the button colors for everything inside
   .ba        = before/after slider (--pos = handle position)
   .shade     = shade picker (--p = progress 0 to 1)
   --tint / --heat = film darkness and sun glare inside the drawn scenes (0 to 1) */

:root {
  --teal: #17C3C9; --black: #0B0B0C; --magenta: #EC2F8C; --sunset: #FF8A1F; --sun: #FFC531; --ink: #0A0E1F;
  --display: Archivo, "Arial Narrow", sans-serif;
  --body: Manrope, system-ui, sans-serif;
  --script: Yellowtail, cursive;
  --pad: clamp(20px, 4vw, 40px);
  --radius: 16px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { font: 400 1.0625rem/1.55 var(--body); background: var(--black); color: #fff; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
ul, ol { padding: 0; list-style: none; }
/* Two-tone focus ring (white inside, ink outside) so it shows on every field color */
:focus-visible { outline: 3px solid #fff; outline-offset: 2px; box-shadow: 0 0 0 8px var(--ink); }

h1, h2, h3, .big {
  font-family: var(--display); font-weight: 900; font-stretch: 70%; text-transform: uppercase;
  line-height: .9; letter-spacing: -.005em; text-wrap: balance;
}
h1 { font-size: clamp(3.2rem, 9.2vw, 8.6rem); line-height: .84; }
h2 { font-size: clamp(2.4rem, 5.4vw, 4.6rem); }
h3 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); }
.lead { font-size: clamp(1.1rem, 1.6vw, 1.3rem); font-weight: 700; max-width: 28em; }
.wrap { width: 100%; max-width: 1180px; margin-inline: auto; padding-inline: var(--pad); }

/* Color fields */
.field { background: var(--bg); color: var(--fg); padding-block: clamp(64px, 9vw, 120px); }
.field--teal { --bg: var(--teal); --fg: var(--ink); --soft: var(--ink); --rule: rgba(10, 14, 31, .3); --btn-bg: var(--ink); --btn-fg: #fff; }
.field--black { --bg: var(--black); --fg: #fff; --soft: #B9BCC4; --rule: rgba(255, 255, 255, .22); --btn-bg: var(--sunset); --btn-fg: #1A0E00; }
.field--white { --bg: #fff; --fg: var(--ink); --soft: #3C4258; --rule: rgba(10, 14, 31, .25); --btn-bg: var(--ink); --btn-fg: #fff; }
.field--magenta { --bg: var(--magenta); --fg: #fff; --soft: var(--ink); --rule: rgba(255, 255, 255, .4); --btn-bg: #fff; --btn-fg: var(--ink); }
.head { margin-bottom: clamp(32px, 5vw, 56px); max-width: 60rem; }
.head .lead { margin-top: 18px; }
.tri { height: 8px; margin-bottom: clamp(36px, 5vw, 56px); background: linear-gradient(90deg, var(--teal) 0 33.3%, var(--magenta) 33.3% 66.6%, var(--sunset) 66.6%); }

/* Buttons and links */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 56px; padding: 0 28px;
  border: 0; border-radius: 999px; background: var(--btn-bg); color: var(--btn-fg); cursor: pointer;
  font: 800 1.1rem/1 var(--display); transition: transform .2s var(--ease);
}
.btn:hover { transform: translateY(-2px); }
.btn svg { width: 20px; height: 20px; flex: none; }
.btn--sm { min-height: 44px; padding: 0 20px; font-size: 1rem; }
.btn--line { background: none; color: #fff; box-shadow: inset 0 0 0 2px #fff; }
.btn--line:focus-visible { box-shadow: inset 0 0 0 2px #fff, 0 0 0 8px var(--ink); }
.link { font-weight: 700; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px; }
.link:hover { text-decoration-color: var(--magenta); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; }

/* Header: clear over the teal hero, black once you scroll */
.hdr {
  position: fixed; inset: 0 0 auto 0; z-index: 50; display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 14px var(--pad); color: var(--ink); --btn-bg: var(--ink); --btn-fg: #fff; transition: background .25s, color .25s;
}
.hdr.is-solid, .hdr.is-open { background: var(--black); color: #fff; --btn-bg: var(--sunset); --btn-fg: #1A0E00; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { width: 46px; height: 46px; }
.brand b { display: block; font: italic 900 1.45rem/1 var(--display); letter-spacing: .01em; }
.brand i { display: block; font: 400 1.1rem/1 var(--script); white-space: nowrap; }
.hdr.is-solid .brand b, .hdr.is-open .brand b, .ftr .brand b { color: var(--teal); }
.hdr.is-solid .brand i, .hdr.is-open .brand i, .ftr .brand i { color: var(--magenta); }
.nav { display: flex; gap: clamp(16px, 2.2vw, 28px); font-weight: 700; white-space: nowrap; }
.hdr .btn { white-space: nowrap; }
.nav a:hover, .nav a[aria-current] { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px; }
.hdr__act { display: flex; align-items: center; gap: 12px; }
.lang { display: flex; border: 2px solid currentColor; border-radius: 999px; overflow: hidden; }
.lang button { min-height: 36px; padding: 0 12px; border: 0; background: none; color: inherit; font: 700 .85rem var(--body); cursor: pointer; }
.lang button[aria-pressed="true"] { background: var(--btn-bg); color: var(--btn-fg); }
.lang button:focus-visible { outline: 3px solid currentColor; outline-offset: -3px; box-shadow: none; } /* the pill clips anything outside */
.menu { display: none; place-items: center; width: 44px; height: 44px; border: 2px solid currentColor; border-radius: 999px; background: none; color: inherit; cursor: pointer; }
.menu svg { width: 22px; height: 22px; }
/* No JavaScript (or main.js failed to load): a plain black header in the page flow, and no controls that need the script */
html:not(.js) .hdr { position: static; flex-wrap: wrap; background: var(--black); color: #fff; --btn-bg: var(--sunset); --btn-fg: #1A0E00; }
html:not(.js) .hdr .brand b { color: var(--teal); }
html:not(.js) .hdr .brand i { color: var(--magenta); }
html:not(.js) .shade__tabs, html:not(.js) .ba__hint, html:not(.js) .ba__bar { display: none; }

/* Home hero */
.hero { position: relative; overflow: hidden; padding-top: clamp(120px, 15vw, 180px); padding-bottom: clamp(170px, 20vw, 230px); }
.hero h1, .hero .lead, .hero .actions { position: relative; z-index: 2; }
.hero h1 { max-width: 9.5em; }
.hero .lead { margin: 28px 0 32px; max-width: 26em; }
.hero__sun { position: absolute; right: -4%; bottom: 0; z-index: 1; width: min(58vw, 720px); transform: translateY(38%); }

/* Service page hero: copy beside the before/after slider */
.hero--split { padding-bottom: clamp(64px, 9vw, 120px); }
.hero--split .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.hero--split h1 { font-size: clamp(2.6rem, 5.6vw, 5rem); line-height: .88; }

/* Before / after slider */
.ba { position: relative; aspect-ratio: 8 / 5; border-radius: var(--radius); overflow: hidden; background: var(--black); --pos: 50%; }
.ba svg, .ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ba__before { --tint: 0; --heat: 1; }
.ba__after { --tint: .62; --heat: .06; clip-path: inset(0 0 0 var(--pos)); }
.ba__tag { position: absolute; top: 14px; padding: 6px 12px; border-radius: 999px; background: var(--black); color: #fff; font-size: .8rem; font-weight: 700; }
.ba__tag--l { left: 14px; }
.ba__tag--r { right: 14px; }
.ba__bar { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 4px; margin-left: -2px; background: #fff; }
.ba__bar::after {
  content: ""; position: absolute; top: 50%; left: 50%; width: 46px; height: 46px; margin: -23px; border-radius: 50%; border: 3px solid var(--ink);
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230A0E1F' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 7l-5 5 5 5M15 7l5 5-5 5'/%3E%3C/svg%3E") center / 24px no-repeat;
}
.ba input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.ba:has(input:focus-visible) { outline: 3px solid var(--ink); outline-offset: 3px; }
.ba__hint { margin-top: 12px; font-size: .95rem; font-weight: 700; }

/* Three services */
.svc { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px; }
.svc a { display: block; }
.svc__art { aspect-ratio: 4 / 3; margin-bottom: 20px; border-radius: var(--radius); overflow: hidden; background: #17171A; }
.svc__art svg, .svc__art img { width: 100%; height: 100%; object-fit: cover; }
.svc h3 { margin-bottom: 8px; font-size: clamp(1.6rem, 2.5vw, 2.3rem); transition: color .2s; }
.svc a:hover h3 { color: var(--magenta); }
.svc p { color: var(--soft); }
.svc .link { display: inline-block; margin-top: 14px; }

/* Benefit points */
.pts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 56px; }
.pts > div { padding: 22px 0 40px; border-top: 3px solid var(--fg); }
.pts h3 { margin-bottom: 8px; font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
.pts p { color: var(--soft); max-width: 32em; }

/* Yellow strip */
.strip { padding: 26px 0; background: var(--sun); color: var(--ink); }
.strip .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 32px; }
.strip b { font-size: clamp(1.4rem, 2.6vw, 2rem); }

/* Steps: a real sequence, so the numbers stay */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; counter-reset: step; }
.steps li { padding-top: 18px; border-top: 3px solid var(--c); counter-increment: step; }
.steps li::before { content: counter(step); display: block; margin-bottom: 12px; color: var(--c); font: 900 clamp(5rem, 10vw, 8rem)/.85 var(--display); font-stretch: 70%; }
.steps li:nth-child(1) { --c: var(--teal); }
.steps li:nth-child(2) { --c: var(--magenta); }
.steps li:nth-child(3) { --c: var(--sunset); }
.steps h3 { margin-bottom: 8px; font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
.steps p { color: var(--soft); }

/* What we tint */
.split { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.split .lead { margin-top: 18px; color: var(--soft); }
.rows { border-top: 3px solid var(--fg); }
.rows li { padding: 22px 0; border-bottom: 1px solid var(--rule); font-size: clamp(1.8rem, 3.4vw, 2.8rem); }

/* Shade picker (Auto page) */
.shade { position: relative; padding-block: 0; }
.shade__pin { padding-block: clamp(64px, 9vw, 110px); }
.shade__grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.shade__grid .tri { grid-column: 1 / -1; order: -2; margin-bottom: 0; }
.shade__copy { display: grid; gap: 20px; }
.shade__num b { display: block; color: var(--sun); font: 900 clamp(6rem, 15vw, 12rem)/.84 var(--display); font-stretch: 70%; }
.shade__descs { display: grid; }
.shade__desc { grid-area: 1 / 1; opacity: 0; visibility: hidden; transition: opacity .3s, visibility 0s .3s; }
.shade__desc.is-on { opacity: 1; visibility: visible; transition-delay: 0s; }
.shade__desc h3 { margin-bottom: 6px; font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
.shade__desc p { color: var(--soft); max-width: 30em; }
.shade__tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.shade__tabs button {
  min-width: 68px; min-height: 52px; padding: 0 16px; border: 2px solid rgba(255, 255, 255, .4); border-radius: 999px;
  background: none; color: #fff; cursor: pointer; font: 900 1.3rem/1 var(--display); font-stretch: 70%;
}
.shade__tabs button:hover { border-color: #fff; }
.shade__tabs button[aria-pressed="true"] { background: var(--teal); border-color: var(--teal); color: var(--ink); }
.shade__note { font-size: .92rem; color: var(--soft); max-width: 34em; }
.shade__stage { padding: clamp(20px, 4vw, 48px) clamp(16px, 3vw, 36px); border-radius: var(--radius); background: var(--sun); }
.shade__stage svg { width: 100%; height: auto; }
.shade__meter { height: 8px; margin-top: 20px; background: rgba(10, 14, 31, .2); }
.shade__meter i { display: block; height: 100%; background: var(--ink); transform-origin: left; transform: scaleX(var(--p, .4)); transition: transform .4s var(--ease); }
/* Pinned scroll stepping. Keep this query in sync with PIN_QUERY in main.js */
@media (min-width: 900px) and (min-height: 700px) and (prefers-reduced-motion: no-preference) {
  .js .shade { height: 400vh; }
  .js .shade__pin { position: sticky; top: 0; height: 100vh; display: grid; align-items: center; padding-block: 90px 40px; }
}

/* Closing call section. The quote form and its pop-up are off the pages for now (owner wants calls first);
   their styles stay so the form in design-system/.../quote-form-removed.html can be put back as-is. */
.quote .wrap { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.quote .lead { margin: 18px 0 24px; color: var(--soft); max-width: 24em; }
.quote__phone { display: inline-block; white-space: nowrap; font-size: clamp(2.6rem, 6vw, 4.6rem); }
.quote__phone:hover { color: var(--ink); }
.quote__call { display: grid; gap: 22px; justify-items: start; }
.qform { padding: clamp(22px, 3.4vw, 40px); border-radius: var(--radius); background: var(--black); color: #fff; color-scheme: dark; --btn-bg: var(--sunset); --btn-fg: #1A0E00; }
.qform__fields { display: grid; gap: 16px; }
.qform label { display: grid; gap: 6px; font-size: .95rem; font-weight: 700; }
.qform input, .qform select, .qform textarea {
  width: 100%; min-height: 48px; padding: 12px 14px; border: 2px solid rgba(255, 255, 255, .25); border-radius: 10px;
  background: #1A1A1E; color: #fff; font: 400 1rem var(--body);
}
.qform input:focus-visible, .qform select:focus-visible, .qform textarea:focus-visible { outline: 3px solid var(--teal); outline-offset: 0; border-color: var(--teal); box-shadow: none; }
.qform .btn { justify-self: start; }
.qform__note { font-size: .85rem; color: #B9BCC4; }
.qform__msg { padding: 14px 16px; border-radius: 10px; font-weight: 700; }
.qform__msg--ok { background: var(--teal); color: var(--ink); }
.qform__msg--err { margin-top: 16px; background: #fff; color: #A3001E; }

/* Quote pop-up: holds the same form while it is open */
.qpop { width: min(560px, calc(100vw - 28px)); max-height: calc(100dvh - 28px); margin: auto; padding: clamp(22px, 4vw, 36px); overflow: auto; border: 0; border-radius: var(--radius); background: var(--black); color: #fff; }
.qpop::backdrop { background: rgba(11, 11, 12, .72); }
.qpop h2 { margin: 0 56px 22px 0; font-size: clamp(2rem, 5vw, 3rem); }
.qpop .qform { padding: 0; }
.qpop__x { position: absolute; top: 16px; right: 16px; width: 44px; height: 44px; border: 2px solid #fff; border-radius: 999px; background: none; color: #fff; font: 400 1.6rem/1 var(--body); cursor: pointer; }
.qpop__x:hover { background: #fff; color: var(--black); }

/* Footer and mobile call bar */
.ftr { padding: 56px 0 40px; background: var(--black); color: #B9BCC4; border-top: 1px solid rgba(255, 255, 255, .14); }
.ftr__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.ftr p { margin-top: 14px; max-width: 24em; }
.ftr h3 { margin-bottom: 10px; color: #fff; font: 700 1rem/1.4 var(--body); font-stretch: 100%; text-transform: none; letter-spacing: 0; }
.ftr li a { display: inline-block; padding: 5px 0; }
.ftr li a:hover { color: #fff; text-decoration: underline; }
.ftr__legal { margin-top: 36px; font-size: .88rem; }
.callbar { display: none; }

@keyframes sunrise { from { transform: translateY(85%); } to { transform: translateY(38%); } }
@media (prefers-reduced-motion: no-preference) {
  .hero__sun { animation: sunrise 1.4s var(--ease) both .15s; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* Between tablet and desktop the header has five things in one row, so tighten it */
@media (max-width: 1100px) {
  .hdr { gap: 12px; }
  .svc { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nav { gap: 14px; font-size: .95rem; }
  .hdr .btn { padding: 0 14px; }
  .brand img { width: 40px; height: 40px; }
  .brand b { font-size: 1.25rem; }
  .brand i { font-size: 1rem; }
}
@media (max-width: 899px) {
  .menu { display: grid; }
  .hdr .btn { display: none; }
  .hdr { flex-wrap: wrap; row-gap: 8px; } /* very large text settings: let the buttons drop to a second row */
  .js .nav { position: absolute; top: 100%; left: 0; right: 0; display: none; flex-direction: column; gap: 0; padding: 4px var(--pad) 20px; background: var(--black); color: #fff; }
  .js .nav.is-open { display: flex; }
  .js .nav a { padding: 16px 0; border-top: 1px solid rgba(255, 255, 255, .2); font: 900 1.7rem/1 var(--display); font-stretch: 70%; text-transform: uppercase; }
  html:not(.js) .menu { display: none; }
  .hero { padding-top: 120px; }
  .hero__sun { right: -22%; width: 92vw; }
  .hero--split { padding-top: 110px; }
  .hero--split .wrap, .svc, .pts, .steps, .split, .shade__grid, .quote .wrap, .ftr__grid { grid-template-columns: minmax(0, 1fr); }
  .svc { gap: 44px; }
  .shade__stage { order: -1; }
  .ftr { padding-bottom: 120px; }
  .callbar {
    position: fixed; inset: auto 0 0 0; z-index: 40; display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: var(--black); --btn-bg: var(--sunset); --btn-fg: #1A0E00;
  }
  .callbar .btn { min-height: 50px; }
}
@media (max-width: 400px) {
  h1 { font-size: 2.9rem; }
  .hero--split h1 { font-size: 2.4rem; }
  .brand img { width: 38px; height: 38px; }
  .brand b { font-size: 1.2rem; }
  .brand i { font-size: .95rem; }
  .lang button { padding: 0 9px; }
  .quote__phone { font-size: 2.4rem; }
}
