/* Pretoria Paving estimator — design tokens from docs/design-system/tokens.json
   Live-site register: Rubik headings, Open Sans body, yellow-led on paper. */

:root {
  --yellow: #F0C000;
  --yellow-light: #F5D44D;
  --yellow-dark: #C9A200;
  --charcoal: #2B2B2B;
  --charcoal-deep: #1A1A1A;
  --charcoal-mid: #3D3D3D;
  --forest: #1C3D2E;
  --forest-light: #4A7C59;
  --paper: #FAFAF8;
  --sand: #F5F1EB;
  --warm: #EDE8E0;
  --rule: #D4CFC8;
  --muted: #6B6560;
  --light: #A09890;
  --text: #1E1E1E;
  --danger: #9B2B2B;
  --display: 'Rubik', Arial, sans-serif;
  --body: 'Open Sans', Arial, sans-serif;
  --shadow-md: 0 4px 12px rgba(0,0,0,0.22);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--body);
  font-size: 15px;
  line-height: 1.65;
  color: var(--text);
  background: var(--paper);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ---------- masthead ---------- */
.masthead {
  background: #fff;
  padding: 20px 24px 16px;
  border-bottom: 3px solid var(--yellow);
  text-align: center;
}
.masthead-logo { height: 56px; width: auto; }
.masthead-tag {
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.04em;
  margin-top: 6px;
}

/* ---------- wizard shell ---------- */
.wizard {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  padding: 28px 20px 56px;
  flex: 1;
}

.steps {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
}
.steps .dot {
  font-family: var(--display);
  font-weight: 700;
  font-size: 13px;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--warm);
  color: var(--muted);
}
.steps .dot.active { background: var(--yellow); color: var(--charcoal); }
.steps .dot.done { background: var(--charcoal); color: var(--yellow); }
.steps .bar { flex: 1; height: 2px; background: var(--rule); }
.steps .bar.done { background: var(--charcoal); }

h1, h2 {
  font-family: var(--display);
  font-weight: 700;
  line-height: 1.15;
  color: var(--text);
}
h1 { font-size: 30px; margin-bottom: 6px; }
.lede { color: var(--muted); margin-bottom: 24px; max-width: 60ch; }

.section-head {
  font-family: var(--display);
  font-weight: 700;
  font-size: 17px;
  padding-bottom: 6px;
  border-bottom: 2px solid var(--yellow);
  margin: 28px 0 14px;
}

/* ---------- service choice ---------- */
.choice {
  display: block;
  width: 100%;
  text-align: left;
  background: #fff;
  border: 1px solid var(--rule);
  border-radius: 8px;
  padding: 18px 18px 16px;
  margin-bottom: 12px;
  cursor: pointer;
  font-family: var(--body);
  transition: border-color 120ms cubic-bezier(0.22,1,0.36,1), box-shadow 120ms cubic-bezier(0.22,1,0.36,1);
}
.choice:hover { border-color: var(--yellow-dark); }
.choice:focus-visible { outline: 3px solid var(--yellow); outline-offset: 1px; }
.choice-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: 18px;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}
.choice-price { font-size: 14px; color: var(--forest-light); white-space: nowrap; font-weight: 700; }
.choice-price .from-label { font-size: 10px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin-right: 4px; }
.choice-desc { color: var(--muted); font-size: 13.5px; margin-top: 4px; }

/* ---------- inputs ---------- */
.field-label {
  display: block;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.02em;
  margin-bottom: 8px;
}
.hint { font-size: 12px; color: var(--muted); margin-top: 6px; }

.area-row { display: flex; gap: 0; align-items: stretch; }
.stepper {
  width: 56px;
  font-size: 24px;
  font-family: var(--display);
  font-weight: 500;
  background: var(--charcoal);
  color: var(--yellow);
  border: none;
  cursor: pointer;
}
.stepper:first-child { border-radius: 8px 0 0 8px; }
.stepper:last-child { border-radius: 0 8px 8px 0; }
.stepper:active { background: var(--charcoal-mid); }
.area-input {
  flex: 1;
  min-width: 0;
  text-align: center;
  font-family: var(--display);
  font-weight: 700;
  font-size: 30px;
  color: var(--text);
  border: 1px solid var(--rule);
  border-left: none;
  border-right: none;
  background: #fff;
  padding: 10px 4px;
}
.area-input:focus { outline: none; box-shadow: inset 0 -3px 0 var(--yellow); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.chip {
  font-family: var(--body);
  font-size: 12.5px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--rule);
  background: #fff;
  cursor: pointer;
}
.chip:hover { border-color: var(--yellow-dark); background: var(--sand); }
.chip.selected { background: var(--charcoal); color: var(--yellow); border-color: var(--charcoal); }

/* ---------- brick picker ---------- */
.tier-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 18px 0 8px;
}
.brick-option {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  background: #fff;
  border: 1px solid var(--rule);
  border-radius: 8px;
  padding: 12px 14px;
  margin-bottom: 8px;
  cursor: pointer;
  font-family: var(--body);
  text-align: left;
}
.brick-option:hover { border-color: var(--yellow-dark); }
.brick-option.selected { border: 2px solid var(--yellow); padding: 11px 13px; background: var(--sand); }
.brick-swatch {
  width: 44px;
  height: 32px;
  border-radius: 4px;
  flex-shrink: 0;
  background: var(--warm);
  background-size: cover;
  background-position: center;
  border: 1px solid rgba(0,0,0,0.12);
}
.brick-name { font-weight: 600; font-size: 14px; }
.brick-rate { margin-left: auto; font-size: 13px; color: var(--forest-light); font-weight: 700; white-space: nowrap; }

/* ---------- toggles ---------- */
.toggle {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 2px;
  cursor: pointer;
  border-top: 1px solid var(--warm);
}
.toggle input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: var(--yellow-dark);
  flex-shrink: 0;
}
.toggle-title { font-weight: 600; font-size: 14px; }
.toggle-desc { font-size: 12.5px; color: var(--muted); }

.colour-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 8px;
}
.colour-option {
  position: relative;
  border: 1px solid var(--rule);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  padding: 0;
  background: #fff;
  font-family: var(--body);
}
.colour-option:hover { border-color: var(--yellow-dark); }
.colour-option.selected { border: 2px solid var(--yellow); box-shadow: var(--shadow-md); }
.colour-swatch {
  display: block;
  width: 100%;
  height: 88px;
  background-size: cover;
  background-position: center;
}
.colour-name {
  display: block;
  text-align: left;
  padding: 8px 12px;
  font-weight: 600;
  font-size: 13.5px;
  background: var(--charcoal);
  color: #fff;
}
.colour-option.selected .colour-name { color: var(--yellow); }
.colour-option.selected::after {
  content: "✓";
  position: absolute;
  top: 6px; right: 6px;
  width: 22px; height: 22px;
  border-radius: 999px;
  background: var(--yellow);
  color: var(--charcoal);
  font-weight: 700;
  font-size: 13px;
  display: grid;
  place-items: center;
}
@media (min-width: 460px) {
  .colour-grid { grid-template-columns: 1fr 1fr 1fr; }
}

/* ---------- result ---------- */
.result-panel {
  background: var(--charcoal);
  border-radius: 12px;
  padding: 26px 24px 22px;
  color: var(--warm);
  box-shadow: var(--shadow-md);
}
.result-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--yellow);
}
.result-figure {
  font-family: var(--display);
  font-weight: 700;
  font-size: 34px;
  line-height: 1.1;
  color: #fff;
  margin-top: 8px;
}
.result-figure .rand { color: var(--yellow); }
.result-vat { font-size: 13px; color: var(--light); margin-top: 6px; }
.result-sub { font-size: 13px; color: var(--warm); margin-top: 2px; }

.breakdown { margin-top: 20px; border-top: 1px solid var(--charcoal-mid); }
.breakdown-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--charcoal-mid);
  font-size: 13.5px;
}
.breakdown-row .amt { white-space: nowrap; color: #fff; font-weight: 600; }

.discount-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-top: 14px;
  padding: 11px 14px;
  border-radius: 8px;
  background: rgba(74,124,89,0.16);
  border: 1px solid var(--forest-light);
  font-size: 13.5px;
  color: #b6e3c4;
}
.discount-row .amt { white-space: nowrap; color: #6fcf97; font-weight: 700; }

.included { margin: 22px 0 4px; }
.included h2 { font-size: 15px; margin-bottom: 8px; }
.included ul { list-style: none; }
.included li {
  padding: 5px 0 5px 26px;
  position: relative;
  font-size: 13.5px;
}
.included li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 10px;
  width: 12px;
  height: 7px;
  border-left: 2.5px solid var(--forest-light);
  border-bottom: 2.5px solid var(--forest-light);
  transform: rotate(-45deg);
}

.disclaimer {
  font-size: 12px;
  color: var(--muted);
  background: var(--sand);
  border-radius: 8px;
  padding: 14px 16px;
  margin-top: 20px;
}
.disclaimer p + p { margin-top: 8px; }

/* ---------- buttons ---------- */
.btn {
  display: block;
  width: 100%;
  text-align: center;
  font-family: var(--display);
  font-weight: 700;
  font-size: 16px;
  padding: 15px 20px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background 120ms cubic-bezier(0.22,1,0.36,1);
}
.btn + .btn { margin-top: 10px; }
.btn-primary { background: var(--yellow); color: var(--charcoal); }
.btn-primary:hover { background: var(--yellow-light); }
.btn-primary:active { background: var(--yellow-dark); }
.btn-whatsapp { background: #25D366; color: #fff; }
.btn-whatsapp:hover { background: #1DAF54; }
.btn-ghost { background: transparent; color: var(--muted); font-family: var(--body); font-weight: 600; font-size: 13.5px; text-decoration: underline; padding: 10px; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }

.cta-block { margin-top: 24px; }
.cta-block > * + * { margin-top: 10px; }
.ty-direct { margin-top: 10px; font-size: 13px; }
.form-success a { color: #fff; text-decoration: underline; }

.nav-row { display: flex; gap: 10px; margin-top: 28px; }
.nav-row .btn-back {
  flex: 0 0 auto;
  width: auto;
  padding: 15px 22px;
  background: var(--warm);
  color: var(--text);
  font-family: var(--body);
  font-weight: 700;
  font-size: 14px;
}
.nav-row .btn-primary { flex: 1; }

/* ---------- email form ---------- */
.email-form { margin-top: 16px; background: #fff; border: 1px solid var(--rule); border-radius: 8px; padding: 18px 16px; }
.email-form .field-label { margin-top: 12px; }
.email-form .field-label:first-child { margin-top: 0; }
.email-form input {
  width: 100%;
  padding: 12px 14px;
  font-family: var(--body);
  font-size: 15px;
  border: 1px solid var(--rule);
  border-radius: 6px;
}
.email-form input:focus-visible { outline: 2px solid var(--yellow); }
.form-error { color: var(--danger); font-size: 12.5px; margin-top: 8px; }
.form-success {
  background: var(--forest);
  color: #fff;
  border-radius: 8px;
  padding: 16px;
  margin-top: 16px;
  font-size: 14px;
}
.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* ---------- trust line ---------- */
.trust-line {
  margin-top: 18px;
  text-align: center;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.5;
}
.trust-stars {
  font-weight: 700;
  color: var(--charcoal);
  background: var(--yellow);
  border-radius: 999px;
  padding: 2px 9px;
  white-space: nowrap;
}
.review-link {
  color: #1a73e8;
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
}
.review-link:hover { opacity: 0.8; }

/* ---------- site-visit accordion ---------- */
.visit-block { margin-top: 12px; }
.btn-visit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  background: #fff;
  color: var(--text);
  border: 1px solid var(--rule);
  border-radius: 8px;
  padding: 14px 18px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
}
.btn-visit:hover { border-color: var(--yellow-dark); }
.btn-visit.open { border-color: var(--yellow); border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.btn-visit .chev { font-size: 12px; color: var(--muted); }
.visit-form { margin-top: 0; border-top-left-radius: 0; border-top-right-radius: 0; border-top: none; }
.visit-intro { font-size: 13px; color: var(--muted); margin-bottom: 4px; }

/* ---------- footer ---------- */
.site-foot {
  background: var(--sand);
  border-top: 1px solid var(--rule);
  padding: 18px 24px 22px;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}
.site-foot a { color: var(--forest-light); }
.site-foot-small { font-size: 11px; margin-top: 4px; color: var(--light); }
.noscript { padding: 24px; text-align: center; }

@media (min-width: 560px) {
  h1 { font-size: 36px; }
  .result-figure { font-size: 42px; }
  .masthead-logo { height: 64px; }
}
