/* QLD Property Audits — redesign per Kerry's spec (relayed via Drew) */

:root {
  --forest: #0d3b2e;
  --deep: #0a2e24;
  --gold: #c9a961;
  --cream: #f5f5f0;
  --body: #d8dbd6;
  --muted: #a9ada7;
  --line: rgba(201, 169, 97, 0.25);
  --tint: rgba(201, 169, 97, 0.08);
  --display: "Playfair Display", Georgia, "Times New Roman", serif;
  --text: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --side: 220px;
}

*, *::before, *::after { box-sizing: border-box; }
:root { color-scheme: dark; padding-top: env(safe-area-inset-top,0px); padding-bottom: env(safe-area-inset-bottom,0px); }
html { scroll-behavior: smooth; scroll-padding-top: env(safe-area-inset-top,0px); background: var(--forest); }

body {
  margin: 0;
  background: var(--forest);
  color: var(--body);
  font-family: var(--text);
  font-size: 15.5px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--cream); text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 2px; }

.skip { position: absolute; left: -999px; top: 0; background: var(--gold); color: var(--deep); padding: .6rem 1rem; z-index: 50; }
.skip:focus { left: 0; }

/* ---------- Shell ---------- */

.shell { display: flex; min-height: 100vh; }

.side {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  height: 100vh;
  flex: none;
  width: var(--side);
  background: var(--deep);
  border-right: 1px solid var(--line);
  padding: 28px 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow-y: auto;
}

.brand { display: flex; align-items: center; gap: 10px; padding: 0 20px 24px; text-decoration: none; }
.brand-mark { width: 52px; height: 52px; border: 2px solid var(--gold); border-radius: 50%; display: grid; place-items: center; color: var(--gold); flex: none; }
.brand-mark svg { width: 30px; height: 30px; }
.brand-name { display: none; }

.menu-btn { display: none; }

.nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.nav a {
  padding: 11px 20px 11px 17px;
  color: var(--muted);
  text-decoration: none;
  font-family: var(--text);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .2px;
  border-left: 3px solid transparent;
}
.nav a::before { content: "|"; font-weight: 700; margin-right: 10px; color: var(--gold); }
.nav a:hover { color: var(--cream); }
.nav a[aria-current="page"] { background: var(--tint); color: var(--cream); border-left-color: var(--gold); }

.nav a.nav-book {
  margin: 14px 20px 0;
  padding: 12px 14px;
  background: var(--gold);
  color: var(--deep);
  text-align: center;
  font-weight: 600;
  border-radius: 6px;
  border-left: 0;
}
.nav a.nav-book::before { content: none; }
.nav a.nav-book:hover { background: #d8b876; color: var(--deep); }
.nav a.nav-book[aria-current="page"] { background: var(--gold); color: var(--deep); }

/* ---------- Content ---------- */

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
main { flex: 1; }

.panel { padding: clamp(32px, 6vw, 56px) clamp(20px, 5vw, 48px); }

.header {
  text-align: center;
  margin-bottom: clamp(28px, 5vw, 44px);
}
.wordmark {
  font-family: var(--display);
  color: var(--cream);
  font-size: clamp(24px, 3vw, 30px);
  font-weight: 600;
  letter-spacing: 1.5px;
}
.header-rule { width: 130px; height: 1px; background: var(--gold); margin: 12px auto 10px; border: 0; }
.tagline { color: var(--gold); font-size: 11px; letter-spacing: 3px; font-weight: 600; margin: 0; }

.container { max-width: 720px; margin: 0 auto; text-align: left; }

.page-title { font-family: var(--display); color: var(--cream); font-size: 28px; font-weight: 600; margin: 0 0 10px; }
.gold-rule { width: 60px; height: 2px; background: var(--gold); border: 0; margin: 0 0 28px; }

h1, h2, h3 { font-family: var(--display); color: var(--cream); font-weight: 600; margin: 0; }
p { margin: 0 0 16px; }
.container > p:last-child { margin-bottom: 0; }

.center { text-align: center; }
.center p { max-width: 640px; margin-inline: auto; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  background: var(--gold);
  color: var(--deep);
  padding: 13px 34px;
  border-radius: 6px;
  font-family: var(--text);
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: .3px;
  text-decoration: none;
  border: 0;
  cursor: pointer;
}
.btn:hover { background: #d8b876; }
.btn-wrap { text-align: center; margin-top: 8px; }

/* ---------- Home: question list ---------- */

.questions { list-style: none; margin: 20px 0; padding: 0; }
.questions li {
  position: relative;
  padding-left: 1.5em;
  color: var(--gold);
  font-weight: 600;
  font-size: 15.5px;
  margin-bottom: 10px;
}
.questions li::before { content: "\2022"; position: absolute; left: 0; top: 0; }

/* ---------- Home: hero row ---------- */

.hero-row { display: flex; gap: 40px; align-items: flex-start; margin: 28px 0; }
.hero-row .text { flex: 1; min-width: 0; }
.hero-row .text p { text-align: left; }

.photo-placeholder {
  flex: none;
  width: 180px;
  aspect-ratio: 3 / 4;
  border: 2px dashed var(--gold);
  background: var(--tint);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 10px;
  padding: 16px;
}
.photo-placeholder svg { width: 34px; height: 34px; color: var(--gold); }
.photo-placeholder .lbl { color: var(--gold); font-size: 11px; font-weight: 700; letter-spacing: .5px; }
.photo-placeholder .sub { color: var(--muted); font-size: 10.5px; font-style: italic; }

/* ---------- Services ---------- */

.pkg { border: 1px solid rgba(201, 169, 97, 0.35); border-radius: 8px; padding: 26px 28px; margin-bottom: 20px; }
.pkg.featured { border-color: var(--gold); background: var(--tint); }
.pkg-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.pkg-label { color: var(--gold); font-weight: 700; font-size: 16px; letter-spacing: .3px; text-transform: uppercase; display: inline-flex; align-items: center; gap: 10px; }
.pill { background: var(--gold); color: var(--deep); font-size: 10.5px; font-weight: 700; letter-spacing: .4px; padding: 3px 10px; border-radius: 999px; text-transform: uppercase; }
.pkg-price { color: var(--cream); font-weight: 700; font-size: 20px; white-space: nowrap; }
.pkg-price .gst { color: var(--muted); font-weight: 400; font-size: 13px; margin-left: 6px; }
.pkg h3 { font-family: var(--text); font-weight: 600; font-size: 17px; margin-bottom: 12px; }
.pkg p { font-size: 14.5px; }
.pkg ul { margin: 6px 0 0; padding-left: 20px; font-size: 14.5px; line-height: 1.85; }
.pkg li { margin-bottom: 6px; }

/* ---------- Why: numbered reasons ---------- */

.reasons { list-style: none; margin: 24px 0; padding: 0; }
.reasons li { display: flex; gap: 18px; margin-bottom: 24px; }
.reason-num {
  flex: none;
  width: 38px; height: 38px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  color: var(--gold);
  font-family: var(--display);
  font-weight: 600;
  font-size: 16px;
  display: flex; align-items: center; justify-content: center;
}
.reason-title { color: var(--cream); font-weight: 600; font-size: 15.5px; margin-bottom: 4px; }
.reason-body { color: var(--body); font-size: 14.5px; margin: 0; }

/* ---------- About ---------- */

.about-top { display: flex; align-items: flex-start; gap: 32px; margin-bottom: 8px; }
.portrait { width: 200px; height: 200px; object-fit: cover; border-radius: 8px; border: 2px solid var(--gold); flex: none; }

/* ---------- Testimonials ---------- */

.quotes { display: grid; gap: 22px; }
.quote { margin: 0; border-left: 2px solid var(--gold); padding: 2px 0 2px 20px; }
.quote p { font-family: var(--display); font-size: 20px; font-weight: 600; line-height: 1.45; color: var(--cream); margin-bottom: 6px; }
.quote footer { color: var(--muted); font-size: 13.5px; }

/* ---------- Guarantee ---------- */

.callout { border: 1px solid var(--gold); background: var(--tint); border-radius: 8px; padding: 24px 28px; margin-bottom: 24px; }
.callout h2 { font-size: 21px; margin-bottom: 8px; }
.callout p { margin: 0; font-size: 14.5px; }

/* ---------- Audit process ---------- */

.steps { list-style: none; margin: 0 0 8px; padding: 0; counter-reset: step; }
.steps li { counter-increment: step; position: relative; padding: 0 0 26px 52px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: -4px; font-family: var(--display); font-weight: 600; font-size: 28px; line-height: 1; color: var(--gold); width: 34px; }
.steps li::after { content: ""; position: absolute; left: 11px; top: 32px; bottom: 6px; width: 1px; background: var(--line); }
.steps li:last-child { padding-bottom: 0; }
.steps li:last-child::after { display: none; }
.steps h3 { font-size: 18px; margin-bottom: 4px; }
.steps p { margin: 0; font-size: 14.5px; }

/* ---------- Form ---------- */

.form { display: grid; gap: 16px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
label, legend { display: block; font-size: 13.5px; color: var(--cream); margin-bottom: 5px; padding: 0; font-weight: 500; }
.opt { color: var(--muted); font-weight: 400; }
input[type="text"], input[type="email"], input[type="tel"], select, textarea {
  width: 100%;
  background: rgba(201, 169, 97, 0.06);
  color: var(--cream);
  border: 1px solid rgba(201, 169, 97, 0.3);
  border-radius: 6px;
  padding: 11px 13px;
  font: inherit;
}
textarea { min-height: 116px; resize: vertical; }
select {
  appearance: none;
  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 1l5 5 5-5' fill='none' stroke='%23c9a961' stroke-width='1.6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  padding-right: 36px;
}
select option { color: #0a2e24; background: #f5f5f0; }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.choices { display: flex; gap: 26px; }
.choices label { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 15px; font-weight: 400; }
input[type="radio"] { accent-color: var(--gold); width: 16px; height: 16px; }
.notice { border: 1px solid var(--gold); border-radius: 6px; padding: 14px 18px; color: var(--cream); margin-top: 18px; }
[hidden] { display: none !important; }

/* ---------- Footer ---------- */

.foot {
  padding: 22px clamp(20px, 5vw, 48px);
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  display: flex; flex-wrap: wrap; gap: 4px 24px; justify-content: space-between;
}

/* ---------- Mobile ---------- */

@media (max-width: 760px) {
  .shell { flex-direction: column; }

  .side {
    position: sticky;
    top: 0;
    z-index: 20;
    height: auto;
    max-height: 100vh;
    width: 100%;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    overflow: visible;
  }
  .brand { padding: 0; }
  .brand-mark { width: 40px; height: 40px; }
  .brand-mark svg { width: 24px; height: 24px; }
  .brand-name { display: block; font-family: var(--display); color: var(--cream); font-size: 18px; font-weight: 600; }

  .menu-btn {
    display: inline-flex;
    background: transparent;
    color: var(--cream);
    border: 1px solid rgba(201, 169, 97, 0.4);
    border-radius: 6px;
    padding: 8px 16px;
    font: inherit;
    font-size: 14px;
    cursor: pointer;
  }
  .nav { display: none; width: 100%; padding: 10px 0 6px; }
  .side.open .nav { display: flex; }
  .nav a.nav-book { margin: 10px 0 2px; }

  .hero-row { flex-direction: column; align-items: center; }
  .hero-row .text p { text-align: left; }
  .photo-placeholder { width: 140px; }

  .about-top { flex-direction: column; align-items: center; text-align: center; }
}

/* ---------- Book an Audit (Wix Forms) ---------- */

.form-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-fields .field { grid-column: 1 / -1; min-width: 0; }
.form-fields .field.half { grid-column: auto; }
.req { color: var(--gold); }
.help { color: var(--muted); font-size: 13px; margin: 5px 0 0; }
.field-error { color: #f0a58f; font-size: 13px; margin: 5px 0 0; }
.field-error:empty { display: none; }
.form-error { color: #f0a58f; margin: 0; }
.form-error:empty { display: none; }
[aria-invalid="true"] { border-color: #f0a58f !important; }
input[type="url"], input[type="number"], input[type="date"], input[type="time"], input[type="datetime-local"], input[type="password"] {
  width: 100%; background: rgba(201, 169, 97, 0.06); color: var(--cream);
  border: 1px solid rgba(201, 169, 97, 0.3); border-radius: 6px; padding: 11px 13px; font: inherit;
}
.check { display: flex; align-items: center; gap: 8px; font-weight: 400; }
input[type="checkbox"] { accent-color: var(--gold); width: 16px; height: 16px; }
.choices .other-text { width: auto; padding: 6px 10px; }
.address { display: grid; gap: 12px; }
.form-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.btn:disabled { opacity: .6; cursor: wait; }
.btn-ghost { background: transparent; color: var(--cream); border: 1px solid var(--gold); }
.btn-ghost:hover { background: var(--tint); }
.notice p { margin: 0 0 6px; }
.notice p:last-child { margin: 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.form-skeleton { display: grid; gap: 16px; }
.form-skeleton span { display: block; height: 66px; border-radius: 6px; background: var(--tint); animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .5; } }

@media (max-width: 560px) {
  .row { grid-template-columns: 1fr; }
  .form-fields { grid-template-columns: 1fr; }
  .choices { flex-direction: column; gap: 10px; }
  .pkg { padding: 20px 18px; }
  .pkg-top { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
