/* ==========================================================================
   JALBAR Constructions — shared site stylesheet
   Loaded on every page BEFORE the page's own <style>, so page CSS can
   override anything here. No build step: edit, bump ?v= in the pages, deploy.
   Sections: tokens · base · section headings · buttons · nav · mobile nav ·
   mobile call bar · breadcrumb · hero tagline · contact + enquiry form ·
   footer · cookie notice · accessibility/compliance · reduced motion
   ========================================================================== */

/* --------------------------------------------------------------------------
   DESIGN TOKENS
   -------------------------------------------------------------------------- */
:root {
  --dark: #3a3a3a;          /* charcoal — primary text, primary buttons */
  --charcoal: #3a3a3a;
  --darker: #2a2a2a;
  --mid: #6e6e6e;           /* secondary text — 5.1:1 on white, 4.8:1 on cream */
  --light: #767676;         /* tertiary text — 4.5:1 on white (the old #aaaaaa failed) */
  --border: #e2e2e2;
  --white: #ffffff;
  --bg-soft: #f6f5f3;
  --bg-cream: #faf8f5;
  --warm: #b8a080;          /* decorative only — never small text, never text on it */
  --warm-deep: #8a6f4e;     /* lines, large text, buttons; 4.7:1 on white */
  --warm-text: #7a6043;     /* small warm text on cream/soft backgrounds (5.5:1) */
  --gold: #e8d4b5;          /* accents on dark backgrounds */
  --gold-muted: #d9c2a0;

  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 10px 30px rgba(0,0,0,0.08);
  --shadow-lg: 0 20px 50px rgba(0,0,0,0.12);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --serif: "Cormorant Garamond", Georgia, serif;
  --sans:  "Jost", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --nav-h: 74px;
}

/* --------------------------------------------------------------------------
   BASE
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  font-weight: 300;
  color: var(--dark);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 400;
  color: var(--dark);
  letter-spacing: -0.01em;
  line-height: 1.1;
}
h1 strong, h2 strong { font-weight: 600; }
em { font-style: italic; }
p { font-size: 1rem; }

section {
  padding: clamp(4.5rem, 9vw, 7rem) clamp(1.5rem, 6vw, 4rem);
  position: relative;
}
.container { max-width: 1200px; margin: 0 auto; }

/* --------------------------------------------------------------------------
   SECTION HEADINGS (eyebrow / title / divider / sub)
   -------------------------------------------------------------------------- */
.section-eyebrow {
  font-family: var(--sans);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--warm-text);
  margin-bottom: 1.2rem;
  text-align: center;
}
.section-title {
  font-size: clamp(2rem, 4.5vw, 2.9rem);
  text-align: center;
  font-weight: 300;
  margin: 0 auto 1rem;
  max-width: 780px;
}
.section-title strong { font-weight: 600; }
.section-title em { color: var(--warm-deep); font-weight: 400; }

.divider {
  width: 48px;
  height: 1px;
  background: var(--warm-deep);
  margin: 1.2rem auto 1.5rem;
}

.section-sub {
  text-align: center;
  max-width: 660px;
  margin: 0 auto 3rem;
  color: var(--mid);
  font-size: 1.12rem;
  font-weight: 300;
}

/* --------------------------------------------------------------------------
   BUTTONS
   .btn-primary   charcoal on white / photo backgrounds
   .btn-ghost     outline for DARK backgrounds (white text)
   .btn-dark-ghost outline for LIGHT backgrounds (charcoal text)
   -------------------------------------------------------------------------- */
.btn-primary, .btn-ghost, .btn-dark-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--sans);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  padding: 1rem 2rem;
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.4s var(--ease);
  border: 1px solid transparent;
  white-space: nowrap;
  text-decoration: none;
}
.btn-primary {
  background: var(--dark);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--warm-deep);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(0,0,0,0.18);
}
.btn-ghost {
  background: transparent;
  color: var(--white);
  border-color: rgba(255,255,255,0.55);
}
.btn-ghost:hover {
  background: var(--white);
  color: var(--dark);
  border-color: var(--white);
}
.btn-dark-ghost {
  background: transparent;
  color: var(--dark);
  border-color: var(--dark);
}
.btn-dark-ghost:hover {
  background: var(--dark);
  color: var(--white);
}

/* --------------------------------------------------------------------------
   NAV (fixed, blurred, --nav-h tall)
   -------------------------------------------------------------------------- */
.site-header { position: relative; }

.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(1.25rem, 4vw, 3rem);
  background: rgba(255,255,255,0.88);
  backdrop-filter: saturate(160%) blur(16px);
  -webkit-backdrop-filter: saturate(160%) blur(16px);
  border-bottom: 1px solid transparent;
  transition: all 0.4s var(--ease);
}
.site-nav.scrolled {
  background: rgba(255,255,255,0.96);
  border-bottom-color: var(--border);
  box-shadow: var(--shadow-sm);
}
.nav-logo { display: flex; align-items: center; height: 100%; }
.nav-logo img { height: 36px; width: auto; }
@media (max-width: 560px) { .nav-logo img { height: 30px; } }

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: clamp(1rem, 1.6vw, 2.1rem);
}
.nav-links a {
  font-family: var(--sans);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--dark);
  position: relative;
  padding: 0.4rem 0;
  white-space: nowrap;
  transition: color 0.3s var(--ease);
}
.nav-links a:not(.nav-cta)::after {
  content: "";
  position: absolute;
  left: 0; right: 0;
  bottom: -2px;
  height: 1px;
  background: var(--warm-deep);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s var(--ease);
}
.nav-links a:not(.nav-cta):hover::after { transform: scaleX(1); }
.nav-links a:hover { color: var(--warm-deep); }

.nav-phone { font-weight: 500; letter-spacing: 0.1em !important; }

.nav-cta {
  background: var(--dark);
  color: var(--white) !important;
  padding: 0.7rem 1.4rem !important;
  border-radius: 2px;
  transition: background 0.3s var(--ease);
}
.nav-cta:hover { background: var(--warm-deep); }

/* Hamburger */
.nav-burger {
  display: none;
  width: 44px; height: 44px;
  background: transparent;
  border: 0;
  cursor: pointer;
  padding: 0;
  color: var(--dark);
}
.nav-burger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: currentColor;
  margin: 5px auto;
  transition: transform 0.35s var(--ease), opacity 0.35s var(--ease);
}
.nav-burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

@media (max-width: 1080px) {
  .nav-links { display: none; }
  .nav-burger { display: inline-block; }
}

/* --------------------------------------------------------------------------
   MOBILE OVERLAY NAV
   -------------------------------------------------------------------------- */
.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 190;
  background: var(--darker);
  color: var(--white);
  display: flex;
  flex-direction: column;
  padding: calc(var(--nav-h) + 1.5rem) 2rem 2rem;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.35s var(--ease), transform 0.45s var(--ease), visibility 0s 0.35s;
  overflow-y: auto;
}
.mobile-nav.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition: opacity 0.35s var(--ease), transform 0.45s var(--ease), visibility 0s 0s;
}
.mobile-nav-logo { text-align: center; margin-bottom: 2rem; }
.mobile-nav-logo img { height: 40px; width: auto; margin: 0 auto; filter: brightness(0) invert(1); opacity: 0.85; }
.mobile-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
  text-align: center;
  flex: 1;
  align-items: center;
  justify-content: center;
  padding-bottom: 4rem;
}
.mobile-nav a {
  font-family: var(--serif);
  font-size: 1.9rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--white);
}
.mobile-nav a em { color: var(--gold-muted); }
.mobile-nav .m-cta {
  margin-top: 1.5rem;
  font-family: var(--sans);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  padding: 1rem 2rem;
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 2px;
  display: inline-block;
}
.mobile-nav .m-phone {
  padding-top: 1.5rem;
  text-align: center;
  border-top: 1px solid rgba(255,255,255,0.08);
  width: 100%;
}
.mobile-nav .m-phone a {
  font-family: var(--sans);
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
}

/* --------------------------------------------------------------------------
   MOBILE CALL BAR
   -------------------------------------------------------------------------- */
.mobile-call-bar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 210;
  background: var(--dark);
  color: var(--white);
  display: none;
  box-shadow: 0 -4px 16px rgba(0,0,0,0.2);
}
.mobile-call-bar a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.95rem 1rem;
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  color: var(--white);
}
.mobile-call-icon { font-size: 1rem; }
.mobile-call-icon svg { width: 1em; height: 1em; vertical-align: -0.15em; }
@media (max-width: 700px) {
  .mobile-call-bar { display: block; }
  body { padding-bottom: 54px; }
}

/* --------------------------------------------------------------------------
   BREADCRUMB
   -------------------------------------------------------------------------- */
.breadcrumb {
  background: var(--bg-soft);
  padding: 0.9rem clamp(1.5rem, 6vw, 4rem);
  border-bottom: 1px solid var(--border);
}
.breadcrumb-inner {
  max-width: 1200px;
  margin: 0 auto;
  font-size: 0.78rem;
  color: var(--mid);
  letter-spacing: 0.04em;
}
.breadcrumb-inner a { color: var(--warm-text); }
.breadcrumb-inner a:hover { text-decoration: underline; }

/* --------------------------------------------------------------------------
   HERO TAGLINE — "Built right. Every time." on every hero
   -------------------------------------------------------------------------- */
.hero-tagline {
  font-family: var(--serif);
  font-size: clamp(1.3rem, 2.4vw, 1.7rem);
  font-weight: 600;
  color: var(--white);
  margin-bottom: 1.2rem;
}
.hero-tagline em { font-weight: 400; font-style: italic; color: var(--gold); }

/* --------------------------------------------------------------------------
   CONTACT SECTION + ENQUIRY FORM (dark panel)
   -------------------------------------------------------------------------- */
#contact { background: var(--dark); color: var(--white); }
#contact .section-eyebrow { color: var(--gold-muted); }
#contact .section-title,
#contact .section-title strong,
#contact .section-title em { color: var(--white); }
#contact .section-title em { color: var(--gold); }
#contact .section-sub { color: rgba(255,255,255,0.75); }
#contact .divider { background: var(--gold-muted); }

.contact-layout {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 3.5rem;
}
@media (max-width: 820px) {
  .contact-layout { grid-template-columns: 1fr; }
}

.contact-detail { margin-bottom: 1.8rem; }
.contact-detail-label {
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.65);
  margin-bottom: 0.3rem;
}
.contact-detail-value {
  font-family: var(--serif);
  font-size: 1.3rem;
  color: var(--white);
}
.contact-detail-value a { color: var(--white); transition: color 0.3s var(--ease); }
.contact-detail-value a:hover { color: var(--gold); }

.contact-form {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 2px;
  padding: 2.4rem;
}
@media (max-width: 520px) { .contact-form { padding: 1.6rem 1.2rem; } }
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}
@media (max-width: 520px) {
  .form-row { grid-template-columns: 1fr; }
}
.form-row .form-field { margin-bottom: 0; }
.form-field { margin-bottom: 1rem; }
.form-field label,
.form-field .form-label {
  display: block;
  font-family: var(--sans);
  font-size: 0.7rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  margin-bottom: 0.5rem;
}
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.18);
  color: var(--white);
  font-family: var(--sans);
  font-size: 0.95rem;
  padding: 0.85rem 1rem;
  border-radius: 2px;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--gold-muted);
  background: rgba(255,255,255,0.08);
}
.form-field input::placeholder,
.form-field textarea::placeholder { color: rgba(255,255,255,0.45); }
.form-field select option { background: var(--dark); color: var(--white); }
.form-field textarea { resize: vertical; min-height: 120px; }

/* Pre-qualifying chips: visually-hidden-but-focusable radios + label chips */
.choice-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.choice-group input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}
.form-field .choice-group label {
  display: inline-block;
  width: auto;
  margin: 0;
  padding: 0.65rem 1rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.18);
  color: rgba(255,255,255,0.82);
  font-family: var(--sans);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: none;
  cursor: pointer;
  border-radius: 2px;
  transition: all 0.3s var(--ease);
}
.form-field .choice-group label:hover {
  border-color: rgba(217,194,160,0.55);
  color: var(--white);
  background: rgba(255,255,255,0.07);
}
.choice-group input[type="radio"]:checked + label {
  background: var(--gold-muted);
  border-color: var(--gold-muted);
  color: var(--dark);
}
.choice-group input[type="radio"]:focus-visible + label {
  outline: 2px solid var(--gold-muted);
  outline-offset: 2px;
}

/* Honeypot — off-screen, never shown, never tabbed to */
.jb-extra {
  position: absolute !important;
  left: -9999px !important;
  top: auto !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  overflow: hidden !important;
}

.form-submit {
  width: 100%;
  margin-top: 0.5rem;
  background: var(--white);
  color: var(--dark);
  border: 0;
  font-family: var(--sans);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  padding: 1.1rem;
  cursor: pointer;
  border-radius: 2px;
  transition: all 0.3s var(--ease);
}
.form-submit:hover { background: var(--gold); color: var(--dark); }
.form-submit[disabled] { cursor: default; }

.form-consent { font-size: .75rem; line-height: 1.5; color: inherit; opacity: .9; margin: 0 0 .9rem; }
.form-consent a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.form-status { font-size: .85rem; line-height: 1.55; margin: .9rem 0 0; font-weight: 300; }
.form-status:empty { display: none; }
.form-status a { text-decoration: underline; text-underline-offset: 2px; color: inherit; }
.form-status.is-error, .form-status.is-ok { color: var(--gold); }
.cf-turnstile { margin: 0 0 1rem; }

/* --------------------------------------------------------------------------
   FOOTER
   -------------------------------------------------------------------------- */
.site-footer {
  background: var(--darker);
  color: rgba(255,255,255,0.65);
  padding: 3rem 1.5rem 2rem;
  text-align: center;
  font-size: 0.8rem;
}
.site-footer img {
  height: 34px;
  width: auto;
  margin: 0 auto 1.2rem;
  opacity: 0.9;
}
.site-footer > span { display: block; margin-bottom: 0.3rem; }
.site-footer strong { font-weight: 500; color: rgba(255,255,255,0.85); }
.site-footer a { color: rgba(255,255,255,0.65); text-decoration: underline; text-underline-offset: 3px; transition: color 0.3s var(--ease); }
.site-footer a:hover { color: var(--gold); }
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  gap: 0.25rem 0.55rem;
  max-width: 900px;
  margin: 0.55rem auto 0;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
}
.footer-links-label {
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  margin-right: 0.3rem;
}
.footer-links .sep { color: rgba(255,255,255,0.35); }
.footer-contact { margin-top: 0.9rem !important; }

/* --------------------------------------------------------------------------
   COOKIE / PRIVACY NOTICE
   -------------------------------------------------------------------------- */
.cookie-banner{position:fixed;left:0;right:0;bottom:0;z-index:99990;background:#2a2a2a;color:#f3efe9;box-shadow:0 -6px 24px rgba(0,0,0,.18);font-family:"Jost",-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;}
.cookie-banner[hidden]{display:none;}
.cookie-inner{max-width:1120px;margin:0 auto;padding:1rem 1.25rem;display:flex;gap:.9rem 1.5rem;align-items:center;justify-content:space-between;flex-wrap:wrap;}
.cookie-text{font-size:.85rem;line-height:1.55;font-weight:300;margin:0;flex:1 1 340px;color:#f3efe9;}
.cookie-text a{color:#e8d4b5;text-decoration:underline;text-underline-offset:2px;}
.cookie-actions{display:flex;gap:.6rem;flex:0 0 auto;}
.cookie-btn{font-family:inherit;font-size:.76rem;font-weight:500;letter-spacing:.09em;text-transform:uppercase;cursor:pointer;border:1px solid #7a7a7a;padding:.6rem 1.15rem;border-radius:2px;background:transparent;color:#f3efe9;transition:background .2s,color .2s,border-color .2s;}
.cookie-btn:hover{border-color:#e8d4b5;color:#fff;}
.cookie-accept{background:#e8d4b5;color:#2a2a2a;border-color:#e8d4b5;}
.cookie-accept:hover{background:#f1e4cc;color:#2a2a2a;}
.cookie-btn:focus-visible{outline:2px solid #e8d4b5;outline-offset:2px;}
.cookie-short{display:none;}
/* Mobile: slim strip under the nav so it never covers the hero CTA or the call bar; hidden while the menu is open */
@media(max-width:700px){.cookie-banner{bottom:auto;top:var(--nav-h,70px);box-shadow:0 6px 24px rgba(0,0,0,.18);}.cookie-inner{padding:.55rem 1rem;gap:.6rem;flex-wrap:nowrap;align-items:center;}.cookie-text{font-size:.72rem;line-height:1.35;flex:1 1 auto;}.cookie-long{display:none;}.cookie-short{display:inline;}.cookie-actions{flex:0 0 auto;}.cookie-btn{padding:.45rem .8rem;font-size:.66rem;letter-spacing:.06em;}.cookie-essential{display:none;}.mobile-nav.open~.cookie-banner,body.menu-open .cookie-banner{display:none;}}

/* --------------------------------------------------------------------------
   ACCESSIBILITY / COMPLIANCE
   -------------------------------------------------------------------------- */
.skip-link{position:absolute;left:-9999px;top:auto;width:1px;height:1px;overflow:hidden;z-index:100000;}
.skip-link:focus{left:0;top:0;width:auto;height:auto;padding:.75rem 1.25rem;background:#2a2a2a;color:#fff;font-family:var(--sans);font-size:.9rem;font-weight:500;text-decoration:none;border-radius:0 0 4px 0;}
:focus-visible{outline:2px solid #8a6f4e;outline-offset:2px;}
.form-field input:focus-visible,.form-field select:focus-visible,.form-field textarea:focus-visible{outline:2px solid var(--gold-muted);outline-offset:1px;}
.footer-legal a{text-decoration:underline;text-underline-offset:3px;}
main:focus { outline: none; }

/* --------------------------------------------------------------------------
   REDUCED MOTION
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .site-nav, .mobile-nav, .nav-burger span, .nav-links a, .nav-links a::after,
  .btn-primary, .btn-ghost, .btn-dark-ghost, .form-submit, .form-field input,
  .form-field select, .form-field textarea, .form-field .choice-group label {
    transition: none !important;
  }
  .btn-primary:hover { transform: none; }
}
