/* ==========================================================================
   Bayside Pavers — landing page
   Design tokens are authored in OKLCH (per the design handoff). Each token is
   declared twice: an sRGB hex first as a fallback for engines without oklch()
   support, then the OKLCH value, which overrides it where supported.
   ========================================================================== */

:root {
  /* Surfaces */
  --bg:               #f7f5ee;  --bg:               oklch(97% 0.01 95);
  --surface:          #fcfcf9;  --surface:          oklch(99% 0.004 95);
  --surface-input:    #fdfcf8;  --surface-input:    oklch(99% 0.005 95);
  --surface-option:   #f9f8f5;  --surface-option:   oklch(98% 0.004 95);
  --stone:            #efebe2;  --stone:            oklch(94% 0.012 85);
  --charcoal:         #171611;  --charcoal:         oklch(20% 0.01 95);
  --charcoal-card:    #23221c;  --charcoal-card:    oklch(25% 0.01 95);
  --charcoal-deep:    #0c0b08;  --charcoal-deep:    oklch(15% 0.008 95);

  /* Accents */
  --green:            #213926;  --green:            oklch(32% 0.045 150);
  --green-hover:      #314936;  --green-hover:      oklch(38% 0.045 150);
  --green-progress:   #27422c;  --green-progress:   oklch(35% 0.05 150);
  --green-on-light:   #172f1d;  --green-on-light:   oklch(28% 0.045 150);
  --clay:             #b47548;  --clay:             oklch(62% 0.1 55);
  --clay-star-dark:   #cf8d60;  --clay-star-dark:   oklch(70% 0.1 55);
  --clay-badge-line:  #d49375;  --clay-badge-line:  oklch(72% 0.09 45);
  --clay-badge-mark:  #e8a587;  --clay-badge-mark:  oklch(78% 0.09 45);
  --clay-strong:      #8d5136;  --clay-strong:      oklch(50% 0.09 45);
  --error:            #a04034;  --error:            oklch(50% 0.13 30);

  /* Text on light */
  --text:             #1e1d18;  --text:             oklch(23% 0.01 95);
  --text-strong:      #23221c;  --text-strong:      oklch(25% 0.01 95);
  --text-deep:        #2f2e28;  --text-deep:        oklch(30% 0.01 95);
  --muted:            #494842;  --muted:            oklch(40% 0.01 95);
  --muted-soft:       #57554f;  --muted-soft:       oklch(45% 0.01 95);
  --placeholder:      #82807a;  --placeholder:      oklch(60% 0.01 95);

  /* Text on dark */
  --on-dark:          #f9f8f5;  --on-dark:          oklch(98% 0.005 95);
  --on-dark-lede:     #e5e4e1;  --on-dark-lede:     oklch(92% 0.005 95);
  --on-dark-quote:    #dfdeda;  --on-dark-quote:    oklch(90% 0.006 95);
  --on-dark-meta:     #d9d7d0;  --on-dark-meta:     oklch(88% 0.01 95);
  --on-dark-muted:    #7c7a75;  --on-dark-muted:    oklch(58% 0.008 95);
  --on-dark-byline:   #82807b;  --on-dark-byline:   oklch(60% 0.008 95);
  --cta-lede:         #e0e6e1;  --cta-lede:         oklch(92% 0.01 150);

  /* Lines & tints */
  --border:           #dad7cf;  --border:           oklch(88% 0.012 90);
  --track:            #e1ded5;  --track:            oklch(90% 0.012 90);
  --divider:          #d0cec7;  --divider:          oklch(85% 0.01 90);
  --divider-dark:     #57554f;  --divider-dark:     oklch(45% 0.01 95);
  --hairline:         #e0ded7;  --hairline:         oklch(90% 0.01 90);
  --tint-warm:        #fcefe5;  --tint-warm:        oklch(96% 0.02 60);
  --tint-warm-deep:   #e8dbd1;  --tint-warm-deep:   oklch(90% 0.02 60);

  /* Type */
  --serif: 'Lora', Georgia, 'Times New Roman', serif;
  --sans:  'Work Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;

  /* Rhythm */
  --pad-x:   clamp(20px, 5vw, 56px);
  --pad-y:   clamp(56px, 8vw, 96px);
  --measure: 1280px;
}

/* --------------------------------------------------------------- base ---- */

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-weight: 400;
  overflow-x: hidden;
}

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

h1, h2, h3, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }

[hidden] { display: none !important; }

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

.stars { letter-spacing: 0.05em; }

/* Focus ring — not specified in the handoff, added so every control is
   visibly keyboard-operable. Colour follows the deep-green accent. */
:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
  border-radius: 4px;
}
.hero :focus-visible,
.section--charcoal :focus-visible,
.cta :focus-visible,
.topbar :focus-visible { outline-color: var(--clay-badge-mark); }
.card :focus-visible { outline-color: var(--green); }
h2:focus, h2:focus-visible { outline: none; }

/* ------------------------------------------------------------ 1. topbar -- */

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 16px var(--pad-x);
  background: var(--charcoal);
}

.topbar__logo { height: 32px; width: auto; }

.topbar__meta {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 13px;
  letter-spacing: 0.03em;
  color: var(--on-dark-meta);
}

/* Dividers sit between items; the container gap supplies the space on the
   leading side and the margin the trailing side, so they stay centred. */
.topbar__item + .topbar__item::before {
  content: "";
  display: inline-block;
  vertical-align: middle;
  width: 1px;
  height: 14px;
  margin-right: 14px;
  background: var(--divider-dark);
}

/* -------------------------------------------------------------- 2. hero -- */

.hero {
  position: relative;
  padding: clamp(40px, 6vw, 72px) var(--pad-x);
  background: linear-gradient(180deg, #171611 0%, #171611 40%, #f7f5ee 40%);
  background: linear-gradient(180deg,
              oklch(20% 0.01 95) 0%, oklch(20% 0.01 95) 40%, oklch(97% 0.01 95) 40%);
}

.hero__panel {
  position: relative;
  max-width: var(--measure);
  margin: 0 auto;
  border-radius: 18px;
  overflow: hidden;
  min-height: 560px;
  display: flex;
  align-items: stretch;
}

.hero__media { position: absolute; inset: 0; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; }

.hero__scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg,
              rgba(12,11,7,0.88) 0%, rgba(12,11,7,0.55) 45%, rgba(12,11,7,0.25) 100%);
  background: linear-gradient(115deg,
              oklch(15% 0.01 95 / 0.88) 0%,
              oklch(15% 0.01 95 / 0.55) 45%,
              oklch(15% 0.01 95 / 0.25) 100%);
}

.hero__inner {
  position: relative;
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: clamp(24px, 4vw, 48px);
  padding: clamp(28px, 4vw, 56px);
}

.hero__copy {
  flex: 1 1 440px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 20px;
  padding: 12px 0;
  color: var(--on-dark);
}

.hero__title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(32px, 4.4vw, 54px);
  line-height: 1.08;
  text-wrap: pretty;
}

.hero__lede {
  font-size: clamp(16px, 1.6vw, 19px);
  line-height: 1.55;
  max-width: 520px;
  color: var(--on-dark-lede);
}

.proof {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 8px;
}

.proof__item {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 14px;
}

.proof__badge {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1.5px solid var(--clay-badge-line);
  color: var(--clay-badge-mark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
}

/* ----------------------------------------------------- 2b. the form card -- */

.card {
  flex: 1 1 380px;
  max-width: 440px;
  align-self: center;
  background: var(--surface);
  border-radius: 14px;
  padding: clamp(22px, 3vw, 32px);
  box-shadow: 0 24px 60px rgba(12, 11, 7, 0.35);
  box-shadow: 0 24px 60px oklch(15% 0.01 95 / 0.35);
}

.card__title {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 16px;
}

.form__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.form__steplabel {
  font-size: 12px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted-soft);
  font-weight: 500;
}

.progress {
  height: 4px;
  background: var(--track);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 22px;
}

.progress__fill {
  height: 100%;
  width: 33.3333%;
  background: var(--green-progress);
  border-radius: 4px;
  transition: width 0.4s ease;
}

/* Step 1 — project type */

.options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.option {
  text-align: left;
  padding: 16px 14px;
  border-radius: 10px;
  border: 1.5px solid var(--border);
  background: var(--surface-option);
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 500;
  color: var(--text-strong);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.option:hover {
  border-color: var(--clay-strong);
  background: var(--tint-warm);
}

/* Steps 2 & 3 — fields */

.field__label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 6px;
}

.field {
  width: 100%;
  padding: 13px 14px;
  border-radius: 9px;
  border: 1.5px solid var(--border);
  background: var(--surface-input);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  margin-bottom: 14px;
  transition: border-color 0.2s;
}

.field::placeholder { color: var(--placeholder); opacity: 1; }
.field:hover { border-color: var(--divider); }
.field[aria-invalid="true"] { border-color: var(--error); }

/* Exact per-field spacing from the handoff */
#zip      { margin-bottom: 16px; }
#timeline { margin-bottom: 8px; }
#phone    { margin-bottom: 8px; }

/* Native selects ignore most box styling, so the control is redrawn to match
   the text inputs exactly; the chevron replaces the suppressed native arrow. */
.field--select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' fill='none' stroke='%2357554f' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 12px 8px;
}

.form__error {
  color: var(--error);
  font-size: 13px;
  margin: 6px 0 0;
}

.form__actions {
  display: flex;
  gap: 10px;
  margin-top: 18px;
}

/* Buttons */

.btn {
  font-family: var(--sans);
  border: none;
  border-radius: 9px;
  cursor: pointer;
}

.btn--ghost {
  padding: 13px 16px;
  background: transparent;
  color: var(--muted-soft);
  font-size: 14px;
  transition: color 0.2s;
}
.btn--ghost:hover { color: var(--text); }

.btn--primary {
  flex: 1;
  padding: 13px 16px;
  background: var(--green);
  color: var(--on-dark);
  font-size: 15px;
  font-weight: 600;
  transition: background 0.2s;
}
.btn--primary:hover { background: var(--green-hover); }

.btn--pill {
  padding: 16px 34px;
  background: var(--on-dark);
  color: var(--green-on-light);
  font-size: 16px;
  font-weight: 600;
  transition: background 0.2s;
}
.btn--pill:hover { background: var(--tint-warm-deep); }

/* Step 4 — confirmation */

.confirm { text-align: center; padding: 20px 4px; }

.confirm__mark {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--green);
  color: var(--on-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  margin: 0 auto 16px;
}

.confirm .card__title { margin: 0 0 8px; }

.confirm__copy {
  font-size: 15px;
  line-height: 1.5;
  color: var(--muted-soft);
}

/* ------------------------------------------------------ 3. trust strip --- */

.trust {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 20px;
  padding: 28px var(--pad-x);
  background: var(--bg);
  border-bottom: 1px solid var(--hairline);
  font-size: 14px;
  color: var(--muted);
}

.trust__item + .trust__item::before {
  content: "";
  display: inline-block;
  vertical-align: middle;
  width: 1px;
  height: 16px;
  margin-right: 20px;
  background: var(--divider);
}

.trust__item--rating .stars { color: var(--clay); }
.trust__item--rating strong { color: var(--text-deep); font-weight: 500; }

/* --------------------------------------------------------- section shell -- */

.section { padding: var(--pad-y) var(--pad-x); }
.section--narrow { max-width: var(--measure); margin: 0 auto; }
.section--stone { background: var(--stone); }
.section--charcoal { background: var(--charcoal); }
.section__inner { max-width: var(--measure); margin: 0 auto; }

.section__title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(28px, 3.2vw, 40px);
  max-width: 640px;
  margin: 0 0 36px;
  text-wrap: pretty;
}
.section__title--roomy { margin-bottom: 40px; }
.section__title--tight { margin-bottom: 12px; }
.section__title--onDark {
  font-size: clamp(26px, 3vw, 36px);
  margin-bottom: 40px;
  color: var(--on-dark);
}

.section__lede {
  font-size: 15px;
  color: var(--muted-soft);
  max-width: 560px;
  margin: 0 0 40px;
}

/* ----------------------------------------------------------- 4. gallery -- */

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

.shot {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 4 / 5;
}

.shot img { width: 100%; height: 100%; object-fit: cover; }

.shot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(12,11,7,0.65) 100%);
  background: linear-gradient(180deg, transparent 55%, oklch(15% 0.01 95 / 0.65) 100%);
}

.shot__caption {
  position: absolute;
  left: 14px;
  bottom: 14px;
  z-index: 1;
  color: var(--on-dark);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

/* ------------------------------------------------------ 5. why bayside --- */

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

.why__number {
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--clay);
  margin: 0 0 12px;
}

.why__title {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 10px;
}

.why__copy { font-size: 15px; line-height: 1.6; color: var(--muted); }

/* ----------------------------------------------------------- 6. process -- */

.process {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 32px;
}

.process__badge {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--green);
  color: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 16px;
  margin: 0 0 16px;
}

.process__title {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 8px;
}

.process__copy { font-size: 14px; line-height: 1.6; color: var(--muted-soft); }

/* ------------------------------------------------------ 7. testimonials -- */

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

.quote {
  background: var(--charcoal-card);
  border-radius: 12px;
  padding: 26px;
  height: 100%;
}

.quote__stars { color: var(--clay-star-dark); font-size: 15px; margin: 0 0 14px; }

.quote__text { margin: 0 0 16px; }
.quote__text p { font-size: 15px; line-height: 1.65; color: var(--on-dark-quote); }

.quote__by { font-size: 13px; color: var(--on-dark-byline); }

/* --------------------------------------------------------- 8. final CTA -- */

.cta {
  position: relative;
  padding: var(--pad-y) var(--pad-x);
  text-align: center;
  background: linear-gradient(135deg, #213926 0%, #1a2e1e 60%, #162313 100%);
  background: linear-gradient(135deg,
              oklch(32% 0.045 150) 0%, oklch(28% 0.04 150) 60%, oklch(24% 0.035 140) 100%);
}

.cta__inner { max-width: 640px; margin: 0 auto; }

.cta__title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(28px, 3.4vw, 42px);
  color: var(--on-dark);
  margin: 0 0 14px;
  text-wrap: pretty;
}

.cta__lede { font-size: 16px; color: var(--cta-lede); margin: 0 0 28px; }

/* ----------------------------------------------------------- 9. footer --- */

.footer {
  padding: 28px var(--pad-x);
  background: var(--charcoal-deep);
  text-align: center;
  color: var(--on-dark-muted);
  font-size: 13px;
  line-height: 1.7;
}

.footer p:first-child { margin-bottom: 4px; }

/* ---------------------------------------------------- scroll reveal ------ */
/* Applied only when JS is running, so the page is fully visible without it. */

.js .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.js .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; transition: none; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
