/* Leibrands marketing site. Colours from the office building and logo:
   walnut cladding, rust canopy, stone render, teal and orange mark. */
:root {
  --walnut: #3b2a24;
  --walnut-deep: #2e211c;
  --rust: #6e3f2f;
  --orange: #d4874f;
  --orange-deep: #b86f3a;
  --teal: #23696d;
  --teal-bright: #3aa3a8;
  --stone: #efeae2;
  --surface: #fdfcfa;
  --line: #ddd5c8;
  --ink: #1d242c;
  --muted: #575049;
  --on-dark: #f3eee6;
  --on-dark-muted: #cfc4b6;
  --radius: 10px;
  --wrap: 1120px;
  --font-head: "Nunito", "Segoe UI", sans-serif;
  --font-body: "Open Sans", "Segoe UI", Helvetica, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font: 400 17px/1.65 var(--font-body);
  -webkit-text-size-adjust: 100%;
}
img { max-width: 100%; display: block; }
a { color: var(--teal); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 2px;
}
h1, h2, h3 { font-family: var(--font-head); line-height: 1.2; margin: 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }

/* The building's vertical walnut slats, used as the site's signature texture. */
.slats {
  background-color: var(--walnut);
  background-image: repeating-linear-gradient(90deg, rgba(0,0,0,0.18) 0 2px, transparent 2px 9px);
}

/* Mock-up only */
.mockup-note {
  background: #fff4c2; color: #4a3b00; text-align: center;
  font-size: 14px; padding: 6px 16px;
}
mark { background: #fff1a8; color: inherit; padding: 0 2px; border-radius: 2px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  /* Same walnut as the logo image background, so the logo sits seamlessly. */
  background: var(--walnut);
  border-bottom: 3px solid var(--orange);
}
.header-row { display: flex; align-items: center; gap: 24px; min-height: 76px; }
.brand img { width: 96px; height: auto; margin: 6px 0; }
.nav { display: flex; gap: 22px; margin-left: 12px; }
.nav a { color: var(--on-dark); text-decoration: none; font-weight: 600; font-size: 15px; }
.nav a:hover { color: var(--orange); }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 16px; }
.header-phone { color: var(--on-dark); text-decoration: none; font-weight: 600; font-size: 15px; white-space: nowrap; }
.header-phone mark { background: rgba(255, 241, 168, 0.25); }

/* Buttons */
.btn {
  display: inline-block; text-decoration: none; cursor: pointer;
  font: 700 16px/1 var(--font-head); padding: 14px 22px; border-radius: 8px; border: 2px solid transparent;
}
.btn-primary { background: var(--orange); color: #241a15; }
.btn-primary:hover { background: #e19863; }
.btn-ghost { border-color: var(--on-dark-muted); color: var(--on-dark); }
.btn-ghost:hover { border-color: var(--on-dark); }
.btn-ghost mark { background: transparent; color: inherit; text-decoration: underline wavy #fff1a8; }
.btn-login { background: var(--teal); color: #fff; padding: 11px 18px; font-size: 15px; }
.btn-login:hover { background: #2b7f84; }

/* Hero: walnut slat panel beside the building photo */
.hero { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); min-height: 520px; }
.hero-panel { display: flex; align-items: center; justify-content: flex-end; color: var(--on-dark); }
.hero-panel { background-color: var(--walnut); background-image: repeating-linear-gradient(90deg, rgba(0,0,0,0.18) 0 2px, transparent 2px 9px); }
.hero-text { max-width: 500px; padding: 56px 40px 56px 20px; }
.hero h1 { font-size: clamp(34px, 4.4vw, 52px); font-weight: 800; letter-spacing: -0.5px; }
.lede { color: var(--on-dark-muted); font-size: 18px; margin: 20px 0 30px; max-width: 34em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-photo { margin: 0; position: relative; }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 30% 40%; }
.hero-photo figcaption {
  position: absolute; left: 0; bottom: 0;
  background: rgba(46, 33, 28, 0.85); color: var(--on-dark);
  font-size: 14px; padding: 8px 14px; border-top-right-radius: var(--radius);
}

.credentials { list-style: none; margin: -6px 0 28px; padding: 0; display: grid; gap: 6px; }
.credentials li { position: relative; padding-left: 26px; color: var(--on-dark); font-weight: 600; font-size: 15px; }
.credentials li::before {
  content: ""; position: absolute; left: 0; top: 7px; width: 14px; height: 8px;
  border-left: 3px solid var(--teal-bright); border-bottom: 3px solid var(--teal-bright); transform: rotate(-45deg);
}

/* Full services list */
.service-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 32px; }
.service-groups h3 { font-size: 19px; color: var(--rust); padding-bottom: 8px; border-bottom: 2px solid var(--line); }
.service-groups ul { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.service-groups li { color: var(--ink); font-size: 16px; line-height: 1.45; }
.footer-tagline { color: var(--orange); font-family: var(--font-head); font-size: 17px; }

/* Deadlines strip */
.deadlines { background: var(--teal); color: #fff; }
.deadlines-row { display: flex; align-items: center; gap: 24px; padding-top: 16px; padding-bottom: 16px; flex-wrap: wrap; }
.deadlines h2 { font-size: 18px; white-space: nowrap; }
.deadline-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 10px; }
.deadline-list li {
  background: rgba(255,255,255,0.12); border: 1px solid rgba(255,255,255,0.25);
  border-radius: 999px; padding: 5px 14px; font-size: 15px;
}
.deadline-list strong { color: #ffd9b8; margin-left: 4px; }

/* Sections */
.section { padding: 80px 0; }
.section-title { font-size: clamp(28px, 3.2vw, 38px); font-weight: 800; color: var(--walnut); }
.section-intro { color: var(--muted); font-size: 18px; margin: 12px 0 36px; max-width: 40em; }
.section-walnut { color: var(--on-dark); background-color: var(--walnut); background-image: repeating-linear-gradient(90deg, rgba(0,0,0,0.18) 0 2px, transparent 2px 9px); }
.section-walnut .section-title { color: #fff; }
.section-walnut .section-intro { color: var(--on-dark-muted); }
.section-stone { background: var(--stone); }

/* Services written as the client's own problems */
.problems { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 36px 48px; }
.problems li { border-left: 4px solid var(--orange); padding-left: 20px; }
.problems h3 { font-size: 21px; color: var(--ink); }
.problems p { margin: 8px 0 0; color: var(--muted); }

/* Certificate steps (a real sequence, so numbered) */
.cert-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 56px; align-items: start; }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.steps li { counter-increment: step; position: relative; padding: 0 0 26px 64px; }
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: -4px; width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center; font: 800 19px/1 var(--font-head);
  background: var(--orange); color: #241a15;
}
.steps li:not(:last-child)::after {
  content: ""; position: absolute; left: 20px; top: 42px; bottom: 4px; width: 2px; background: rgba(255,255,255,0.25);
}
.steps h3 { font-size: 20px; color: #fff; }
.steps p { margin: 4px 0 0; color: var(--on-dark-muted); }

/* How we work */
.principles { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 32px; margin: 32px 0 0; }
.principles div { border-top: 3px solid var(--teal-bright); padding-top: 16px; }
.principles dt { font: 800 19px/1.3 var(--font-head); color: var(--ink); }
.principles dd { margin: 8px 0 0; color: var(--muted); }

/* Contact */
.contact-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 56px; align-items: start; }
.contact-details { margin: 0; display: grid; gap: 18px; }
.contact-details dt { font: 700 14px/1.2 var(--font-head); color: var(--rust); }
.contact-details dd { margin: 4px 0 0; }
.quote-form {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; display: grid; gap: 16px;
}
.quote-form label { display: grid; gap: 6px; font-weight: 600; font-size: 15px; }
.quote-form input, .quote-form select, .quote-form textarea {
  font: 400 16px/1.4 var(--font-body); color: var(--ink);
  border: 1px solid var(--line); border-radius: 8px; padding: 12px; background: #fff; min-height: 46px;
}
.quote-form button { justify-self: start; }
.form-note { margin: 0; font-size: 14px; color: var(--muted); }

/* Footer */
.site-footer { background: var(--walnut-deep); color: var(--on-dark-muted); font-size: 15px; }
.footer-row { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding-top: 28px; padding-bottom: 28px; }
.site-footer p { margin: 0; }
.site-footer a { color: var(--on-dark); }

/* Phones and small tablets */
@media (max-width: 860px) {
  .header-row { flex-wrap: wrap; gap: 10px 16px; padding-top: 6px; padding-bottom: 8px; }
  .brand img { width: 76px; }
  .nav { order: 3; width: 100%; margin: 0; gap: 18px; overflow-x: auto; padding-bottom: 4px; }
  .header-phone { display: none; }
  .hero, .cert-grid, .contact-grid { grid-template-columns: minmax(0, 1fr); }
  .hero { min-height: 0; }
  .hero-photo { order: -1; }
  .hero-photo img { height: 240px; }
  .hero-panel { justify-content: flex-start; }
  .hero-text { padding: 36px 20px 44px; }
  .section { padding: 56px 0; }
  .cert-grid, .contact-grid { gap: 36px; }
}

/* Inner pages: a slim walnut title band, then readable text */
.page-hero { color: var(--on-dark); background-color: var(--walnut); background-image: repeating-linear-gradient(90deg, rgba(0,0,0,0.18) 0 2px, transparent 2px 9px); }
.page-hero .wrap { padding-top: 56px; padding-bottom: 48px; }
.page-hero h1 { font-size: clamp(32px, 4vw, 46px); font-weight: 800; color: #fff; }
.page-hero p { color: var(--on-dark-muted); font-size: 18px; margin: 12px 0 0; max-width: 40em; }
.prose { max-width: 760px; }
.prose h2 { font-size: 24px; color: var(--walnut); margin: 44px 0 10px; }
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--ink); }
.prose ul { padding-left: 22px; }
.prose li { margin: 6px 0; }
.prose .updated { color: var(--muted); font-size: 15px; margin: 0 0 28px; }
.notice {
  border-left: 4px solid var(--orange); background: var(--stone);
  padding: 14px 18px; border-radius: 0 var(--radius) var(--radius) 0; margin: 0 0 32px;
}
.notice p { margin: 0; }
.steps-plain { margin: 0; padding-left: 22px; }
.steps-plain li { margin: 0 0 10px; }
.legal-line { font-size: 13px; color: var(--on-dark-muted); max-width: 70em; margin: 0; padding-bottom: 24px; }
.legal-line a { color: var(--on-dark); }
.nav a[aria-current="page"] { color: var(--orange); }

/* Form fields fill their column and can shrink on narrow phones. */
.quote-form { grid-template-columns: minmax(0, 1fr); }
.quote-form label { grid-template-columns: minmax(0, 1fr); }
.quote-form input, .quote-form select, .quote-form textarea { width: 100%; min-width: 0; }
@media (max-width: 860px) { .quote-form { padding: 20px; } }

/* Quote form: character counter, hidden bot trap, and the send result */
.char-count { font-weight: 400; font-size: 13px; color: var(--muted); justify-self: end; }
.char-count.is-low { color: var(--rust); font-weight: 600; }
.trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-status { margin: 0; font-size: 15px; }
.form-status:empty { display: none; }
.form-status.is-ok { color: #1f6b3a; font-weight: 600; }
.form-status.is-error { color: #a2341f; font-weight: 600; }
.quote-form { position: relative; }
