/* ==========================================================================
   Cross Driven Construction
   Design tokens and layout. Translated from the Claude Design prototype,
   which was a fixed 1200px desktop artboard; everything here is fluid.
   ========================================================================== */

@import url("/fonts/fonts.css");

:root{
  /* Surfaces, darkest to lightest */
  --ink:        #121110;
  --ink-panel:  #151310;
  --ink-raised: #1a1815;
  --ink-hover:  #26231d;

  /* Hairlines */
  --line:        #262421;
  --line-soft:   #2b2823;
  --line-card:   #322e29;
  --line-strong: #3b3730;
  --line-bold:   #4a453d;

  /* Text on dark */
  --text:  #ffffff;
  --warm:  #c9c3b9;
  --muted: #a9a299;
  --dim:   #8f887e;

  /* Brand */
  --yellow: #FFE800;

  /* Text on yellow */
  --on-yellow:       #151310;
  --on-yellow-body:  #3d380f;
  --on-yellow-quiet: #5c5312;

  --font:  Archivo, system-ui, -apple-system, "Segoe UI", sans-serif;
  --black: "Archivo Black", Archivo, system-ui, sans-serif;
  --mono:  "IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --gutter: clamp(20px, 4vw, 48px);
  --max:    1200px;
  --bar:    5px;
  --header-h: 78px;

  --section-y: clamp(44px, 7vw, 64px);
}

/* ---------- reset ---------- */
*,*::before,*::after{ box-sizing:border-box; }
html{ -webkit-text-size-adjust:100%; }
body{
  margin:0;
  background:var(--ink);
  color:var(--text);
  font-family:var(--font);
  font-size:16px;
  line-height:1.5;
  -webkit-font-smoothing:antialiased;
  overflow-x:hidden;
}
img,svg,video{ max-width:100%; display:block; }
h1,h2,h3,h4,p,figure,blockquote{ margin:0; }
ul,ol{ margin:0; padding:0; list-style:none; }
button{ font:inherit; color:inherit; background:none; border:0; cursor:pointer; }
a{ color:var(--yellow); text-decoration:none; }
a:hover{ color:var(--text); }

/* Visible keyboard focus everywhere. */
:focus-visible{
  outline:3px solid var(--yellow);
  outline-offset:2px;
}

.skip-link{
  position:absolute; left:-9999px; top:0; z-index:1200;
  background:var(--yellow); color:var(--on-yellow);
  padding:12px 20px; font-weight:700;
}
.skip-link:focus{ left:0; }

.sr-only{
  position:absolute; width:1px; height:1px; padding:0; margin:-1px;
  overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; border:0;
}

/* ---------- layout ---------- */
.wrap{
  width:100%;
  max-width:var(--max);
  margin-inline:auto;
  padding-inline:var(--gutter);
}
.section{ padding-block:var(--section-y); }

/* ---------- type ---------- */
.eyebrow{
  font-family:var(--mono);
  font-size:clamp(10px,1.4vw,11px);
  font-weight:600;
  letter-spacing:.16em;
  text-transform:uppercase;
  color:var(--yellow);
}
.eyebrow--tag{
  display:inline-block;
  align-self:flex-start;
  background:var(--yellow);
  color:var(--on-yellow);
  letter-spacing:.14em;
  padding:6px 11px;
}
.eyebrow--on-yellow{ color:var(--on-yellow-quiet); }

.h1{
  font-family:var(--black);
  font-size:clamp(38px,8.2vw,66px);
  line-height:1;
  letter-spacing:-.02em;
  text-transform:uppercase;
}
.h2{
  font-family:var(--black);
  font-size:clamp(30px,5.6vw,52px);
  line-height:.98;
  letter-spacing:-.025em;
  text-transform:uppercase;
}
.h3{
  font-family:var(--black);
  font-size:clamp(26px,4.4vw,40px);
  line-height:1.02;
  letter-spacing:-.02em;
  text-transform:uppercase;
}
.h4{
  font-family:var(--black);
  font-size:clamp(19px,2.6vw,22px);
  line-height:1.1;
  text-transform:uppercase;
}
.lede{
  font-size:clamp(16px,2.2vw,18px);
  line-height:1.6;
  color:var(--warm);
  text-wrap:pretty;
}
.body{
  font-size:clamp(14px,1.9vw,15px);
  line-height:1.6;
  color:var(--muted);
  text-wrap:pretty;
}
.accent{ color:var(--yellow); }

/* ---------- buttons ---------- */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:.5em;
  padding:16px 26px;
  font-weight:700;
  font-size:clamp(15px,2vw,16px);
  line-height:1;
  text-align:center;
  border:2px solid transparent;
  transition:background-color .15s ease, color .15s ease, border-color .15s ease;
  min-height:48px;
}
.btn--primary{ background:var(--yellow); color:var(--on-yellow); }
.btn--primary:hover{ background:#ffef4d; color:var(--on-yellow); }
.btn--ghost{ border-color:var(--line-bold); color:var(--text); }
.btn--ghost:hover{ border-color:var(--yellow); color:var(--yellow); }
.btn--dark{ background:var(--ink-panel); color:var(--yellow); }
.btn--dark:hover{ background:var(--ink-hover); color:var(--yellow); }
.btn--sm{ padding:13px 20px; min-height:44px; font-size:15px; }
.btn--block{ width:100%; }

/* ---------- top bar + header ---------- */
.topbar{ height:var(--bar); background:var(--yellow); }

.header{
  /* Layer scale: map panes are contained at 0, call bar 900, header 1000,
     drawer 1100, skip link 1200. */
  position:sticky; top:0; z-index:1000;
  background:var(--ink);
  border-bottom:1px solid var(--line);
}
.header__inner{
  display:flex; align-items:center; justify-content:space-between; gap:16px;
  min-height:var(--header-h);
  padding-block:12px;
}
.header__logo img{ height:44px; width:auto; }
.header__nav{ display:none; }
.header__links{
  display:flex; align-items:center; gap:clamp(14px,2vw,26px);
  font-size:13px; font-weight:600;
  letter-spacing:.07em; text-transform:uppercase;
}
.header__links a{ color:var(--dim); white-space:nowrap; }
.header__links a:hover,
.header__links a[aria-current="page"]{ color:var(--text); }
.header__links a[aria-current="page"]{ box-shadow:0 2px 0 var(--yellow); }

.header__call{ display:none; }

/* hamburger */
.navtoggle{
  display:inline-flex; align-items:center; justify-content:center;
  width:48px; height:48px; margin-right:-12px;
  color:var(--text);
}
.navtoggle svg{ width:26px; height:26px; }
.navtoggle .icon-close{ display:none; }
.navtoggle[aria-expanded="true"] .icon-open{ display:none; }
.navtoggle[aria-expanded="true"] .icon-close{ display:block; }

/* mobile drawer */
.drawer{
  position:fixed; inset:0; z-index:1100;
  background:var(--ink);
  padding:calc(var(--bar) + 16px) var(--gutter) 32px;
  display:flex; flex-direction:column;
  transform:translateX(100%);
  transition:transform .22s ease;
  overflow-y:auto;
  visibility:hidden;
}
.drawer[data-open="true"]{ transform:translateX(0); visibility:visible; }
.drawer__head{
  display:flex; align-items:center; justify-content:space-between;
  padding-bottom:18px; margin-bottom:10px;
  border-bottom:1px solid var(--line);
}
.drawer__head img{ height:40px; width:auto; }
.drawer__link{
  display:block;
  padding:16px 0;
  font-family:var(--black);
  font-size:clamp(22px,6vw,28px);
  text-transform:uppercase;
  color:var(--text);
  border-bottom:1px solid var(--line);
}
.drawer__link:hover,
.drawer__link[aria-current="page"]{ color:var(--yellow); }
.drawer__cta{ margin-top:24px; display:flex; flex-direction:column; gap:10px; }

/* ---------- hero ---------- */
.hero{ position:relative; background:#2a2724; isolation:isolate; }
.hero__media{
  position:absolute; inset:0; z-index:-2;
  width:100%; height:100%; object-fit:cover;
  filter:grayscale(1) contrast(1.08);
}
.hero__scrim{
  position:absolute; inset:0; z-index:-1;
  background:linear-gradient(180deg,rgba(18,17,16,.62) 0%,rgba(18,17,16,.92) 72%,rgba(18,17,16,.98) 100%);
}
/* .hero__inner also carries .wrap, so it must NOT set its own max-width:
   a narrower max-width here beats .wrap's 1200px, and .wrap's margin-inline:auto
   then centres that narrow box — which pushed the headline 250px right of every
   other section on desktop. The width limit belongs on the content, not the
   container. */
.hero__inner{
  display:flex; align-items:center;
  min-height:clamp(440px,72vh,560px);
  padding-block:clamp(44px,9vw,60px);
}
.hero__content{
  display:flex; flex-direction:column; gap:20px;
  max-width:700px;
}
.hero__content .lede{ max-width:480px; }
.hero__actions{ display:flex; flex-wrap:wrap; gap:12px; padding-top:6px; }
.hero__actions .btn{ flex:1 1 auto; min-width:190px; }

@media (min-width:760px){
  .hero__scrim{
    background:linear-gradient(90deg,rgba(18,17,16,.96) 0%,rgba(18,17,16,.9) 48%,rgba(18,17,16,.2) 100%);
  }
  .hero__actions .btn{ flex:0 0 auto; }
}

/* ---------- stat bar ---------- */
/* The band is full-bleed but the numbers sit on the same 1200px grid as every
   other section, so nothing is 33px out of line on wide screens. */
.statsband{
  background:var(--ink-raised);
  border-top:1px solid var(--line-soft);
  border-bottom:1px solid var(--line-soft);
}
.stats{
  display:grid;
  grid-template-columns:repeat(2,1fr);
}
.stat{
  padding:20px 16px;
  display:flex; flex-direction:column; gap:5px;
  border-bottom:1px solid var(--line-soft);
}
.stat:nth-child(odd){ border-right:1px solid var(--line-soft); padding-left:0; }
.stat:nth-child(even){ padding-right:0; }
.stat:nth-last-child(-n+2){ border-bottom:0; }
.stat__value{
  font-family:var(--black);
  font-size:clamp(24px,5vw,30px);
  line-height:1;
  color:var(--yellow);
}
.stat__label{
  font-size:clamp(11px,1.7vw,12px);
  letter-spacing:.1em; text-transform:uppercase; color:var(--dim);
}
@media (min-width:760px){
  .stats{ grid-template-columns:repeat(4,1fr); }
  .stat{ padding:26px 20px; border-bottom:0; }
  .stat:nth-child(odd){ border-right:0; padding-left:20px; }
  .stat:nth-child(even){ padding-right:20px; }
  .stat + .stat{ border-left:1px solid var(--line-soft); }
  .stats > .stat:first-child{ padding-left:0; }
  .stats > .stat:last-child{ padding-right:0; }
}

/* ---------- services (the yellow block) ---------- */
.services{ background:var(--yellow); color:var(--on-yellow); }
.services__head{
  display:flex; align-items:flex-end; justify-content:space-between;
  gap:clamp(20px,4vw,40px); flex-wrap:wrap;
  margin-bottom:clamp(26px,4vw,36px);
}
.services__intro{ display:flex; flex-direction:column; gap:14px; max-width:620px; }
.services__intro .h2{ color:var(--on-yellow); }
.services__sub{
  font-size:clamp(15px,2.1vw,17px); line-height:1.6;
  color:var(--on-yellow-body); text-wrap:pretty;
}
.services__grid{
  display:grid; gap:14px;
  grid-template-columns:1fr;
}
.svc{
  background:var(--ink-panel);
  padding:22px 20px;
  display:flex; flex-direction:column; gap:12px;
}
.svc__name{ color:var(--text); }
.svc__blurb{ flex:1; }
.svc__price{ padding-top:14px; border-top:1px solid var(--line-card); }
.svc__from{
  font-size:12px; letter-spacing:.08em; text-transform:uppercase; color:var(--dim);
}
.svc__amount{
  font-family:var(--black);
  font-size:clamp(22px,3.4vw,26px);
  color:var(--yellow);
}
.services__foot{
  display:flex; align-items:center; gap:14px;
  margin-top:clamp(22px,3vw,30px);
}
.services__rule{ width:34px; height:3px; background:var(--on-yellow); flex:none; }
.services__note{
  font-size:clamp(14px,1.9vw,15px); color:var(--on-yellow-body); text-wrap:pretty;
}

@media (min-width:560px){ .services__grid{ grid-template-columns:repeat(2,1fr); } }
@media (min-width:900px){ .services__grid{ grid-template-columns:repeat(3,1fr); } }
@media (min-width:1100px){ .services__grid{ grid-template-columns:repeat(5,1fr); } }

/* ---------- shared section header ---------- */
.sechead{
  display:flex; align-items:flex-end; justify-content:space-between;
  gap:20px; flex-wrap:wrap;
  margin-bottom:clamp(22px,3.4vw,26px);
}
.sechead__text{ display:flex; flex-direction:column; gap:8px; }

/* ---------- gallery teaser ---------- */
.tiles{
  display:grid; gap:12px;
  grid-template-columns:repeat(2,1fr);
}
.tile{
  position:relative; display:block; overflow:hidden;
  background:var(--ink-raised);
  aspect-ratio:4/3;
}
.tile img{
  width:100%; height:100%; object-fit:cover;
  transition:transform .4s ease;
}
.tile:hover img{ transform:scale(1.04); }
.tile__label{
  position:absolute; left:0; bottom:0; right:0;
  padding:26px 14px 12px;
  background:linear-gradient(180deg,transparent,rgba(18,17,16,.9));
  font-size:12px; font-weight:600;
  letter-spacing:.06em; text-transform:uppercase; color:var(--text);
}
.tile--wide{ grid-column:span 2; }
/* Four across only once each tile can still be a reasonable size; at 760px
   four columns leaves 170px thumbnails, which is too small to show off work. */
@media (min-width:1000px){
  .tiles{ grid-template-columns:repeat(4,1fr); }
}

/* ---------- job map teaser ---------- */
.maprow{
  display:grid; gap:clamp(22px,4vw,40px);
  grid-template-columns:1fr;
  align-items:center;
}
.maprow__text{ display:flex; flex-direction:column; gap:14px; align-items:flex-start; }
.mapbox{
  width:100%;
  height:clamp(260px,50vw,380px);
  background:var(--ink-raised);
  border:1px solid var(--line-soft);
  /* Leaflet gives its own panes z-index 200-1000 (tiles 200, markers 600,
     controls 1000). Leaflet sets the container to position:relative but leaves
     z-index:auto, so without this those panes escape into the root stacking
     context and paint straight over the sticky header. Containing them here is
     the fix; raising the header alone would just move the fight. */
  position:relative;
  z-index:0;
  isolation:isolate;
}
.mapbox--idle{
  display:flex; align-items:center; justify-content:center;
  color:var(--dim); font-family:var(--mono); font-size:11px;
  letter-spacing:.12em; text-transform:uppercase;
}
@media (min-width:900px){
  .maprow{ grid-template-columns:0.85fr 1.15fr; }
}

/* Leaflet skin */
.leaflet-container{ background:var(--ink-raised); font-family:var(--font); }
.leaflet-tile{ filter:grayscale(.9) contrast(.92) brightness(.96); }
.leaflet-bar a{ background:var(--ink-panel); color:var(--yellow); border-color:var(--line-card); }
.leaflet-bar a:hover{ background:var(--ink-hover); color:var(--yellow); }
.leaflet-control-attribution{
  background:rgba(21,19,16,.8)!important; color:var(--dim)!important; font-size:10px;
}
.leaflet-control-attribution a{ color:var(--muted)!important; }
.cd-pin{
  background:var(--yellow); border:2px solid var(--ink-panel);
  border-radius:50%; box-shadow:0 1px 3px rgba(0,0,0,.5);
}
.cd-clus{
  background:var(--yellow); border:3px solid var(--ink-panel); border-radius:50%;
  display:flex; align-items:center; justify-content:center;
  font-family:var(--black); color:var(--on-yellow);
}
.leaflet-popup-content-wrapper{
  background:var(--ink-panel); color:var(--text);
  border-radius:0; border-left:3px solid var(--yellow);
}
.leaflet-popup-tip{ background:var(--ink-panel); }
.cd-pop__street{ font-size:14px; font-weight:700; }
.cd-pop__meta{ font-size:12px; color:var(--muted); margin-top:3px; }

/* ---------- testimonials ---------- */
.quotes{
  display:grid; gap:14px;
  grid-template-columns:1fr;
}
.quote{
  background:var(--ink-raised);
  border-left:3px solid var(--yellow);
  padding:22px 20px;
  display:flex; flex-direction:column; gap:14px;
}
.quote__text{
  font-size:clamp(15px,2vw,16px); line-height:1.6; color:var(--warm);
  text-wrap:pretty;
}
.quote__author{
  font-size:12px; letter-spacing:.1em; text-transform:uppercase; color:var(--dim);
}
@media (min-width:860px){ .quotes{ grid-template-columns:repeat(3,1fr); } }

/* ---------- crew ---------- */
.crew{
  display:grid; gap:14px;
  grid-template-columns:repeat(2,1fr);
}
.person{ display:flex; flex-direction:column; gap:10px; }
.person__photo{
  aspect-ratio:1/1;
  background:var(--ink-raised);
  border:1px solid var(--line-soft);
  display:flex; align-items:center; justify-content:center;
  overflow:hidden;
}
.person__photo img{ width:100%; height:100%; object-fit:cover; }

/* No headshot yet: drop the photo box entirely rather than leave an empty
   square on every card, and give the name/role pair a rule so it still reads
   as a designed card. Photos come back automatically once they exist. */
.person--text{
  gap:4px;
  padding-top:12px;
  border-top:2px solid var(--yellow);
}

.person__name{ font-weight:700; font-size:clamp(14px,2vw,16px); }
.person__role{
  font-size:12px; letter-spacing:.08em; text-transform:uppercase; color:var(--dim);
}
@media (min-width:760px){ .crew{ grid-template-columns:repeat(4,1fr); } }

/* ---------- strips ---------- */
.strip{
  display:flex; align-items:center; justify-content:space-between;
  gap:20px; flex-wrap:wrap;
  padding-block:clamp(26px,4vw,34px);
  border-top:1px solid var(--line);
  border-bottom:1px solid var(--line);
}
.strip__text{ display:flex; flex-direction:column; gap:5px; }
.strip__title{ font-family:var(--black); font-size:clamp(20px,3.2vw,26px); text-transform:uppercase; }
.strip__sub{ font-size:clamp(14px,1.9vw,15px); color:var(--muted); }

/* ---------- big call block ---------- */
.callblock{ background:var(--yellow); color:var(--on-yellow); }
.callblock__inner{
  display:flex; align-items:center; justify-content:space-between;
  gap:clamp(20px,4vw,40px); flex-wrap:wrap;
  padding-block:clamp(34px,5vw,48px);
}
.callblock .h3{ color:var(--on-yellow); }
.callblock__sub{
  font-size:clamp(15px,2.1vw,17px); color:var(--on-yellow-body); margin-top:8px;
  text-wrap:pretty;
}
.callblock__actions{ display:flex; flex-direction:column; gap:8px; align-items:flex-start; }
.callblock__number{
  font-family:var(--black);
  font-size:clamp(26px,5.4vw,40px);
  color:var(--on-yellow);
  letter-spacing:-.02em;
  line-height:1.1;
}
.callblock__number:hover{ color:var(--ink); }
.callblock__link{ color:var(--on-yellow-body); font-weight:600; text-decoration:underline; }
.callblock__link:hover{ color:var(--on-yellow); }

/* ---------- footer ---------- */
.footer{ background:var(--ink-panel); border-top:1px solid var(--line); }
.footer__inner{
  display:grid; gap:clamp(26px,4vw,40px);
  grid-template-columns:1fr;
  padding-block:clamp(34px,5vw,48px);
}
.footer__brand{ display:flex; flex-direction:column; gap:14px; align-items:flex-start; }
/* align-self is load-bearing: this is a column flex container, so the default
   align-items:stretch pulls the logo to the full column width and silently
   beats width:auto, squashing it to a 7.6:1 smear. */
.footer__brand img{ height:44px; width:auto; align-self:flex-start; }
.footer__addr{ font-size:14px; line-height:1.7; color:var(--dim); }
.footer__cols{
  display:grid; gap:24px;
  grid-template-columns:repeat(2,1fr);
}
.footer__heading{
  font-family:var(--mono); font-size:11px; font-weight:600;
  letter-spacing:.14em; text-transform:uppercase; color:var(--dim);
  margin-bottom:12px;
}
.footer__list li + li{ margin-top:9px; }
.footer__list a{ color:var(--muted); font-size:14px; }
.footer__list a:hover{ color:var(--yellow); }
.footer__bottom{
  border-top:1px solid var(--line);
  padding-block:20px;
  display:flex; justify-content:space-between; gap:14px; flex-wrap:wrap;
  font-size:12px; color:var(--dim);
}
@media (min-width:760px){
  .footer__inner{ grid-template-columns:1fr 1.4fr; }
  .footer__cols{ grid-template-columns:repeat(3,1fr); }
}

@media (min-width:900px){
  .header__nav{ display:block; }
  .header__call{ display:inline-flex; }
  .navtoggle{ display:none; }
  .drawer{ display:none; }
  .header__logo img{ height:52px; }
}

@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{
    animation-duration:.01ms!important; animation-iteration-count:1!important;
    transition-duration:.01ms!important; scroll-behavior:auto!important;
  }
}
