/* ════════════════════════════════════════════════════════════
   Sage Dental — Warm-Organic Aesthetic
   Palette: eucalyptus green · clay coral · warm linen
   Fonts : Fraunces (display) · Inter (sans)
   ════════════════════════════════════════════════════════════ */

/* ── 1. Custom Properties ─────────────────────────────────── */
:root {
  /* Brand palette (canonical — overridden by per-team presets) */
  --primary:     #28463a;
  --secondary:   #28463a;
  --accent:      #e08a6b;
  --background:  #f4efe6;
  --surface:     #fffaf3;
  --text:        #25302a;
  --muted:       #6f7a70;
  --border:      #e2dccf;
  --dark:        #152620;   /* immutable dark band — use var(--theme-dark-band) for fixed tint */

  /* Immutable design constants (not overridden by preset runtime) */
  --theme-dark-band:   #152620;
  --theme-linen-tint:  #f0e8d8;
  --theme-clay-light:  color-mix(in oklab, var(--accent) 18%, var(--surface));
  --theme-green-tint:  color-mix(in oklab, var(--primary) 8%, var(--background));
  --theme-green-glass: color-mix(in oklab, var(--primary) 12%, transparent);

  /* Fonts */
  --font-sans:    'Inter', system-ui, sans-serif;
  --font-display: 'Fraunces', Georgia, serif;

  /* Shape */
  --radius:    16px;
  --radius-sm: 10px;
  --radius-xl: 28px;
  --radius-blob: 60% 40% 70% 30% / 50% 60% 40% 70%;

  /* Layered shadows (Warm-Organic — warm-tinted, never cold) */
  --shadow-sm: 0 1px 3px rgba(37,48,42,.05), 0 1px 2px rgba(37,48,42,.04);
  --shadow-md: 0 4px 16px rgba(37,48,42,.08), 0 2px 6px rgba(37,48,42,.05);
  --shadow-lg: 0 16px 48px rgba(37,48,42,.12), 0 6px 16px rgba(37,48,42,.07);

  /* Motion tokens — Warm-Organic personality (gentle, soft) */
  --dur-micro:    150ms;
  --dur-ui:       260ms;
  --dur-reveal:   720ms;
  --dur-slow:    1100ms;
  --ease-standard: cubic-bezier(.25, 1, .3, 1);
  --ease-out:      cubic-bezier(.25, 1, .3, 1);
  --ease-spring:   cubic-bezier(.34, 1.4, .64, 1);

  /* Fluid type scale */
  --step--1: clamp(0.83rem, 0.8rem + 0.18vw, 0.94rem);
  --step-0:  clamp(1rem,   0.95rem + 0.25vw, 1.13rem);
  --step-1:  clamp(1.2rem, 1.1rem + 0.5vw,  1.5rem);
  --step-2:  clamp(1.44rem,1.28rem + 0.8vw, 2rem);
  --step-3:  clamp(1.73rem,1.5rem + 1.2vw,  2.66rem);
  --step-4:  clamp(2.07rem,1.7rem + 1.9vw,  3.55rem);
  --step-5:  clamp(2.49rem,1.95rem + 2.7vw, 4.74rem);
}

/* ── 2. Livewire loading (REQUIRED) ──────────────────────── */
[wire\:loading],
[wire\:loading\.delay],
[wire\:loading\.inline-block],
[wire\:loading\.inline] { display: none; }

/* ── 3. Empty image fallback (REQUIRED) ──────────────────── */
img[src=""],
img:not([src])           { display: none !important; }
img[src$="placeholder.jpg"] { display: none !important; }

/* ── 4. Reset & Base ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  background: var(--background);
  color: var(--text);
  line-height: 1.65;
  overflow-x: hidden;
  font-size: var(--step-0);
}
img  { max-width: 100%; height: auto; display: block; }
a    { color: inherit; text-decoration: none; }
button { cursor: pointer; font: inherit; border: none; background: none; }
ul   { list-style: none; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  text-wrap: balance;
}
h1 { font-size: var(--step-5); }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-2); }
p, li { text-wrap: pretty; }

/* ── 5. Layout ───────────────────────────────────────────── */
.container  { max-width: 1200px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 32px); }
.section-pad { padding: clamp(56px, 8vw, 96px) 0; }
.section-alt  { background: var(--theme-green-tint); }
.section-dark { background: var(--theme-dark-band); color: #fff; }

/* ── 6. CSS Scroll-Driven Reveals (baseline, CSS-first) ──── */
@keyframes wb-reveal {
  from { opacity: 0; transform: translateY(32px); }
  to { opacity: 1; }
}
.reveal { opacity: 1; }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .reveal {
      animation: wb-reveal linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 30%;
    }
    .reveal-stagger > * {
      animation: wb-reveal linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 30%;
      animation-delay: calc(var(--i, 0) * 70ms);
    }
  }
}

/* ── 7. Signature Hero Animations (Warm-Organic entrance) ── */
@keyframes hero-fade-up {
  from { opacity: 0; transform: translateY(28px); }
  to { opacity: 1; }
}
@keyframes blob-float {
  0%, 100% { transform: translateY(0) rotate(0deg); border-radius: 60% 40% 70% 30% / 50% 60% 40% 70%; }
  33%       { transform: translateY(-14px) rotate(3deg); border-radius: 40% 60% 50% 50% / 60% 40% 60% 40%; }
  66%       { transform: translateY(8px) rotate(-2deg);  border-radius: 55% 45% 40% 60% / 45% 55% 65% 35%; }
}
@keyframes kinetic-rise {
  from { clip-path: inset(100% 0 0 0); }
  to { clip-path: inset(0% 0 0 0); }
}
@media (prefers-reduced-motion: no-preference) {
  .hero__content { animation: hero-fade-up var(--dur-reveal) var(--ease-out) both; }
  .hero__media    { animation: hero-fade-up var(--dur-reveal) var(--ease-out) 180ms both; }
  .hero__blob-1   { animation: blob-float 8s var(--ease-standard) infinite; }
  .hero__blob-2   { animation: blob-float 11s var(--ease-standard) 1.5s infinite; }
  .kinetic-rise {
    clip-path: inset(0% 0 0 0);
    animation: kinetic-rise var(--dur-slow) var(--ease-out) 200ms both;
  }
}

/* ── 8. View Transitions ─────────────────────────────────── */
@view-transition { navigation: auto; }
@media (prefers-reduced-motion: no-preference) {
  ::view-transition-old(root) { animation: vt-out .22s ease both; }
  ::view-transition-new(root) { animation: vt-in  .32s ease both; }
}
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in  { from { opacity: 0; transform: translateY(6px); } }

/* ── 9. Typography ───────────────────────────────────────── */
.section-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--accent);
  display: block;
  margin-bottom: 10px;
}
.section-eyebrow--light { color: color-mix(in oklab, var(--accent) 80%, #fff); }
.section-header { margin-bottom: 52px; }
.section-header--center { text-align: center; }
.section-subtitle { color: var(--muted); margin-top: 12px; font-size: var(--step-0); }

/* ── 10. Accessibility ───────────────────────────────────── */
:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 4px; }

/* ── 11. Skip link ───────────────────────────────────────── */
.skip-link {
  position: absolute; top: -48px; left: 0;
  background: var(--primary); color: #fff;
  padding: 10px 18px; z-index: 1000;
  border-radius: 0 0 var(--radius-sm) 0;
  transition: top var(--dur-ui) var(--ease-out);
  font-size: 0.875rem; font-weight: 600;
}
.skip-link:focus { top: 0; }

/* ── 12. Scroll progress ─────────────────────────────────── */
#scroll-progress {
  position: fixed; top: 0; left: 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--primary));
  z-index: 10000; width: 0;
  transition: width 80ms linear;
  border-radius: 0 2px 2px 0;
}

/* ── 13. Header ──────────────────────────────────────────── */
.site-header {
  position: sticky; top: 0; z-index: 900;
  background: var(--background, rgba(244,239,230,.95));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow var(--dur-ui) var(--ease-standard);
}
.site-header.scrolled {
  box-shadow: 0 2px 24px rgba(37,48,42,.08);
}
.header__inner {
  display: flex; align-items: center; gap: 20px; height: 72px;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-weight: 600; font-size: 1.15rem;
  color: var(--primary); flex-shrink: 0;
}
.logo img { width: 38px; height: 38px; object-fit: contain; border-radius: 10px; }
.logo__name { white-space: nowrap; letter-spacing: -0.01em; }

/* Desktop nav — scoped to avoid conflict with mobile */
.site-nav {
  display: flex; gap: 2px; margin-left: auto;
}
.site-nav:not(.nav__mobile) .site-nav-item {
  padding: 8px 15px; border-radius: var(--radius-sm);
  font-weight: 500; font-size: 0.88rem;
  color: var(--text);
  transition: background var(--dur-ui) var(--ease-standard), color var(--dur-ui) var(--ease-standard);
}
.site-nav:not(.nav__mobile) .site-nav-item:hover { background: var(--theme-green-tint); color: var(--primary); }

.header__actions { display: flex; align-items: center; gap: 10px; }
.header__phone {
  display: flex; align-items: center; gap: 6px;
  font-size: 0.85rem; font-weight: 600; color: var(--primary);
  padding: 8px 14px; border-radius: var(--radius-sm);
  border: 1.5px solid var(--border);
  transition: background var(--dur-ui) var(--ease-standard);
  white-space: nowrap;
}
.header__phone:hover { background: var(--theme-green-tint); }

.nav__toggle {
  display: none; flex-direction: column; gap: 5px;
  padding: 8px; border-radius: var(--radius-sm);
}
.nav__toggle span {
  display: block; width: 22px; height: 2px;
  background: var(--text); border-radius: 2px;
  transition: all var(--dur-ui) var(--ease-out);
}
.nav__toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle.open span:nth-child(2) { opacity: 0; }
.nav__toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav */
.nav__mobile {
  display: none;
  position: absolute; top: 100%; left: 0; right: 0;
  background: var(--surface, rgba(255,250,243,.98));
  border-bottom: 1px solid var(--border);
  padding: 16px 20px;
  flex-direction: column; gap: 4px;
  box-shadow: 0 8px 28px rgba(37,48,42,.1);
}
.nav__mobile.open { display: flex; }
.nav__mobile a {
  padding: 11px 14px; border-radius: var(--radius-sm);
  font-weight: 500; color: var(--text);
  transition: background var(--dur-ui) var(--ease-standard);
}
.nav__mobile a:hover { background: var(--theme-green-tint); color: var(--primary); }
.nav__mobile .btn { margin-top: 8px; justify-content: center; }

/* ── 14. Buttons ─────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 30px; border-radius: 100px;
  font-family: var(--font-sans); font-weight: 600; font-size: 0.9rem;
  cursor: pointer; white-space: nowrap;
  border: 2px solid transparent;
  transition:
    background   var(--dur-ui) var(--ease-standard),
    color        var(--dur-ui) var(--ease-standard),
    border-color var(--dur-ui) var(--ease-standard),
    box-shadow   var(--dur-ui) var(--ease-standard),
    transform    var(--dur-ui) var(--ease-out);
}
.btn--primary {
  background: var(--primary); color: #fff; border-color: var(--primary);
}
.btn--primary:hover {
  background: var(--primary-dark); border-color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px color-mix(in oklab, var(--primary) 40%, transparent);
}
.btn--accent { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn--accent:hover { background: var(--accent-dark); border-color: var(--accent-dark); transform: translateY(-2px); }
.btn--outline { border-color: var(--primary); color: var(--primary); background: transparent; }
.btn--outline:hover { background: var(--theme-green-tint); }
.btn--outline-warm { border-color: var(--accent); color: var(--accent); background: transparent; }
.btn--outline-warm:hover { background: var(--theme-clay-light); }
.btn--lg  { padding: 16px 40px; font-size: 0.95rem; }
.btn--sm  { padding: 9px 20px; font-size: 0.82rem; }
.btn--full { width: 100%; justify-content: center; }
.btn--magnetic { transition: all var(--dur-ui) var(--ease-spring); }

/* ── 15. Hero — Warm-Organic Signature Moment ────────────── */
.hero {
  background: var(--primary);
  color: #fff;
  min-height: 100svh;
  display: flex; align-items: center;
  overflow: hidden;
  position: relative;
  isolation: isolate;
}

/* Organic blob decorations (signature moment) */
.hero__blob-1,
.hero__blob-2 {
  position: absolute;
  pointer-events: none;
  border-radius: var(--radius-blob);
  opacity: 0.18;
}
.hero__blob-1 {
  width: clamp(280px, 45vw, 560px);
  height: clamp(260px, 40vw, 520px);
  background: var(--accent);
  top: -10%;
  right: -8%;
  filter: blur(40px);
}
.hero__blob-2 {
  width: clamp(200px, 32vw, 400px);
  height: clamp(180px, 28vw, 360px);
  background: color-mix(in oklab, var(--accent) 60%, #fff);
  bottom: 5%;
  left: -5%;
  filter: blur(50px);
  opacity: 0.12;
}
/* Subtle grain texture */
.hero::after {
  content: '';
  position: absolute; inset: 0;
  pointer-events: none;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  z-index: -1;
}

.hero__split {
  max-width: 1200px;
  margin: 0 auto;
  padding: clamp(72px, 10vw, 120px) clamp(16px, 4vw, 32px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  width: 100%;
  position: relative; z-index: 1;
}
.hero__content { display: flex; flex-direction: column; gap: 22px; }
.hero__badge {
  display: inline-flex; align-items: center; gap: 7px;
  background: color-mix(in oklab, var(--accent) 20%, transparent);
  border: 1px solid color-mix(in oklab, var(--accent) 35%, transparent);
  color: color-mix(in oklab, var(--accent) 90%, #fff);
  padding: 6px 16px; border-radius: 100px;
  font-size: 0.76rem; font-weight: 600; letter-spacing: 0.07em;
  width: fit-content;
}
.hero__badge::before {
  content: '';
  width: 6px; height: 6px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
}
.hero__title {
  font-size: var(--step-5);
  line-height: 1.08;
  color: #fff;
}
.hero__title .title-prefix {
  display: block;
  color: color-mix(in oklab, var(--accent) 80%, #fff);
  font-style: italic;
  font-weight: 400;
  font-size: 0.72em;
  margin-bottom: 4px;
}
.hero__title .kinetic-rise { display: block; }
.hero__subtitle { font-size: var(--step-1); color: rgba(255,255,255,.75); line-height: 1.5; }
.hero__body     { color: rgba(255,255,255,.6); line-height: 1.8; font-size: var(--step-0); }
.hero__stats    { display: flex; gap: 36px; margin: 6px 0; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat__num {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  font-weight: 600;
  color: color-mix(in oklab, var(--accent) 85%, #fff);
  line-height: 1;
}
.stat__label { font-size: 0.72rem; color: rgba(255,255,255,.5); margin-top: 2px; font-weight: 500; }
.hero__cta-group { display: flex; gap: 14px; flex-wrap: wrap; }

/* Hero media — organically framed image */
.hero__media { position: relative; }
.hero__media-frame {
  position: relative;
  border-radius: 60% 40% 55% 45% / 45% 55% 45% 55%;
  overflow: hidden;
  background: rgba(255,255,255,.07);
  aspect-ratio: 3 / 4;
  max-height: 560px;
}
.hero__media-frame img {
  width: 100%; height: 100%;
  object-fit: cover; display: block;
}
.hero__trust-chip {
  position: absolute;
  bottom: 20px; left: 50%; transform: translateX(-50%);
  display: flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,.14);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #fff; padding: 10px 20px; border-radius: 100px;
  font-size: 0.78rem; font-weight: 600; white-space: nowrap;
  border: 1px solid rgba(255,255,255,.2);
}

/* Decorative leaf shape behind the image */
.hero__leaf {
  position: absolute;
  top: -12%; right: -8%;
  width: 55%;
  pointer-events: none;
  opacity: 0.14;
}

/* ── 16. About ────────────────────────────────────────────── */
.about__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: center;
}
.about__media { position: relative; }
.about__media img {
  border-radius: 44% 56% 38% 62% / 42% 58% 42% 58%;
  width: 100%; height: 460px;
  object-fit: cover;
}
.about__media-badge {
  position: absolute;
  bottom: 28px; right: -20px;
  background: var(--accent);
  color: #fff;
  padding: 18px 22px;
  border-radius: var(--radius);
  text-align: center;
  box-shadow: var(--shadow-lg);
}
.about__media-badge strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.4rem; font-weight: 600;
}
.about__media-badge span { font-size: 0.78rem; opacity: 0.85; }
.about__content { display: flex; flex-direction: column; gap: 18px; }
.about__body    { color: var(--muted); line-height: 1.8; }
.about__checklist { display: flex; flex-direction: column; gap: 10px; }
.about__checklist li {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 0.92rem; line-height: 1.5;
}
.about__checklist li::before {
  content: '\2713';
  background: color-mix(in oklab, var(--primary) 14%, var(--background));
  color: var(--primary);
  width: 22px; height: 22px; min-width: 22px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.72rem; font-weight: 700;
  margin-top: 1px;
}

/* ── 17. Services ─────────────────────────────────────────── */
.services__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.service-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 30px;
  display: flex; flex-direction: column; gap: 12px;
  transform-style: preserve-3d;
  transition:
    transform   var(--dur-ui) var(--ease-out),
    box-shadow  var(--dur-ui) var(--ease-standard);
  will-change: transform;
}
.service-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}
/* Featured card (nth-child variety) */
.service-card:nth-child(2) {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.service-card:nth-child(2) .service-card__body   { color: rgba(255,255,255,.72); }
.service-card:nth-child(2) .service-card__icon   { background: rgba(255,255,255,.12); color: #fff; }
.service-card:nth-child(2) .service-card__title  { color: #fff; }
.service-card:nth-child(2) .service-card__price  { color: color-mix(in oklab, var(--accent) 85%, #fff); }
.service-card:nth-child(2) .service-card__cta    { color: rgba(255,255,255,.8); border-color: rgba(255,255,255,.3); }
.service-card:nth-child(2) .service-card__subtitle { color: color-mix(in oklab, var(--accent) 80%, #fff); }

.service-card__icon {
  width: 54px; height: 54px;
  background: var(--theme-clay-light);
  color: var(--accent);
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.service-card__title    { font-family: var(--font-display); font-weight: 600; font-size: var(--step-1); }
.service-card__subtitle { font-size: 0.75rem; font-weight: 600; color: var(--accent); text-transform: uppercase; letter-spacing: 0.09em; }
.service-card__body     { color: var(--muted); font-size: 0.88rem; flex: 1; line-height: 1.65; }
.service-card__footer   { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--border); }
.service-card:nth-child(2) .service-card__footer { border-top-color: rgba(255,255,255,.15); }
.service-card__price { font-weight: 700; color: var(--primary); font-family: var(--font-display); font-size: 1.05rem; }
.service-card__cta   { font-size: 0.82rem; font-weight: 600; color: var(--primary); border-bottom: 1px solid var(--primary); padding-bottom: 2px; transition: opacity var(--dur-micro) var(--ease-standard); }
.service-card__cta:hover { opacity: 0.7; }

/* ── 18. Service Areas ────────────────────────────────────── */
.areas__grid { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.area-chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 9px 18px; border-radius: 100px;
  font-size: 0.88rem; font-weight: 500; color: var(--text);
  transition: all var(--dur-ui) var(--ease-standard); cursor: default;
}
.area-chip:hover { border-color: var(--primary); color: var(--primary); background: var(--theme-green-tint); }
.area-chip svg { color: var(--accent); flex-shrink: 0; }
.area-note { font-size: 0.72rem; color: var(--muted); margin-left: 2px; }

/* ── 19. Certifications (dark band) ───────────────────────── */
.certs__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.cert-card {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius);
  padding: 22px;
  display: flex; align-items: center; gap: 16px;
  transition: background var(--dur-ui) var(--ease-standard);
}
.cert-card:hover { background: rgba(255,255,255,.1); }
.cert-card img {
  width: 48px; height: 48px;
  object-fit: contain; flex-shrink: 0;
  border-radius: var(--radius-sm);
}
.cert-card__info { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cert-card__info strong { font-size: 0.88rem; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cert-card__issuer { font-size: 0.72rem; color: rgba(255,255,255,.55); }
.cert-card small  { font-size: 0.68rem; color: rgba(255,255,255,.38); }

/* ── 20. Before / After ──────────────────────────────────── */
.ba-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }
.ba-card {
  background: var(--surface);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: box-shadow var(--dur-ui) var(--ease-standard);
}
.ba-card:hover { box-shadow: var(--shadow-lg); }
.ba-card__images { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.ba-card__side { position: relative; overflow: hidden; }
.ba-card__side img { width: 100%; height: 220px; object-fit: cover; display: block; transition: transform var(--dur-reveal) var(--ease-standard); }
.ba-card:hover .ba-card__side img { transform: scale(1.03); }
.ba-card__label {
  position: absolute; top: 12px; left: 12px;
  padding: 4px 10px; border-radius: 100px;
  font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.07em; text-transform: uppercase;
}
.ba-card__label--before { background: #fee2e2; color: #7f1d1d; }
.ba-card__label--after  { background: color-mix(in oklab, var(--primary) 15%, #fff); color: var(--primary); }
.ba-card__divider {
  width: 36px; height: 36px;
  background: var(--surface); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-sm); color: var(--accent); flex-shrink: 0; z-index: 1;
}
.ba-card__caption { padding: 16px 20px; font-size: 0.83rem; color: var(--muted); text-align: center; line-height: 1.5; }

/* ── 21. Quote / Appointment Request ─────────────────────── */
.quote-section { background: var(--background); }
.quote__wrap {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 72px;
  align-items: start;
}
.quote__info { display: flex; flex-direction: column; gap: 18px; padding-top: 8px; }
.quote__info h2  { color: var(--primary); }
.quote__info > p { color: var(--muted); line-height: 1.7; }
.quote__promises { display: flex; flex-direction: column; gap: 10px; }
.quote__promises li {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.88rem; color: var(--muted);
}
.quote__promises li::before { content: '\2713'; color: var(--primary); font-weight: 700; }
.quote__form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: clamp(24px, 4vw, 40px);
  box-shadow: var(--shadow-md);
  display: flex; flex-direction: column; gap: 16px;
}

/* ── 22. Form elements ───────────────────────────────────── */
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-size: 0.8rem; font-weight: 600; color: var(--text); }
.form-group input,
.form-group select,
.form-group textarea {
  padding: 12px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font: inherit; font-size: 0.88rem;
  background: var(--background);
  color: var(--text);
  transition: border-color var(--dur-ui) var(--ease-standard), box-shadow var(--dur-ui) var(--ease-standard);
  width: 100%;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--primary) 15%, transparent);
}
.form-group textarea { resize: vertical; min-height: 90px; }
.form-group select   { cursor: pointer; }

/* ── 23. Testimonials ────────────────────────────────────── */
.testimonials__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.testimonial-card {
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius);
  padding: 28px;
  display: flex; flex-direction: column; gap: 16px;
  transform-style: preserve-3d;
  transition: transform var(--dur-ui) var(--ease-out), box-shadow var(--dur-ui) var(--ease-standard);
}
.testimonial-card:hover { box-shadow: 0 10px 36px rgba(0,0,0,.24); transform: translateY(-3px); }
.testimonial-card__stars { color: var(--accent); font-size: 1rem; letter-spacing: 2px; }
.testimonial-card__quote { color: rgba(255,255,255,.85); font-style: italic; flex: 1; line-height: 1.7; }
.testimonial-card__author { display: flex; align-items: center; gap: 12px; }
.testimonial-card__author img {
  width: 46px; height: 46px;
  border-radius: 50%; object-fit: cover;
  border: 2px solid color-mix(in oklab, var(--accent) 45%, transparent);
  flex-shrink: 0;
}
.testimonial-card__author strong { display: block; font-size: 0.9rem; color: #fff; }
.testimonial-card__author span   { font-size: 0.78rem; color: rgba(255,255,255,.5); }

/* ── 24. Opening Hours ───────────────────────────────────── */
.hours__wrap { display: grid; grid-template-columns: 1fr 1.2fr; gap: 64px; align-items: center; }
.hours__content { display: flex; flex-direction: column; gap: 18px; }
.hours__content p { color: var(--muted); line-height: 1.7; }
.hours__table-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}
.hours__table { width: 100%; border-collapse: collapse; }
.hours__table tr[data-item] {
  border-bottom: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1.2fr 1.2fr 0.6fr;
  padding: 14px 22px;
  transition: background var(--dur-ui) var(--ease-standard);
}
.hours__table tr[data-item]:last-child { border-bottom: none; }
.hours__table tr[data-item].today-row  { background: var(--theme-green-tint); }
.hours__table tr[data-item].today-row td:first-child { color: var(--primary); font-weight: 700; }
.hours__table td { font-size: 0.88rem; align-self: center; }
.hours__table td:first-child { font-weight: 600; }
.hours__note { font-size: 0.72rem; color: var(--primary); font-weight: 600; text-align: right; }

/* ── 25. FAQs ────────────────────────────────────────────── */
.faqs__list {
  display: flex; flex-direction: column;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 800px;
  margin: 0 auto;
}
.faq-item { border-bottom: 1px solid var(--border); }
.faq-item:last-child { border-bottom: none; }
.faq-item__trigger {
  width: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 26px; text-align: left;
  background: var(--surface); cursor: pointer;
  transition: background var(--dur-ui) var(--ease-standard);
  font-family: var(--font-display); font-weight: 600; font-size: 0.95rem; color: var(--text);
}
.faq-item__trigger:hover { background: var(--theme-green-tint); }
.faq-item__trigger[aria-expanded="true"] { color: var(--primary); }
.faq-item__trigger[aria-expanded="true"] .faq-item__icon { transform: rotate(180deg); color: var(--primary); }
.faq-item__icon { flex-shrink: 0; transition: transform var(--dur-ui) var(--ease-out), color var(--dur-ui); color: var(--muted); }
.faq-item__answer {
  padding: 0 26px 20px;
  color: var(--muted); font-size: 0.88rem; line-height: 1.75;
  background: var(--surface);
}
.faq-item__answer[hidden] { display: none; }

/* ── 26. Contact ─────────────────────────────────────────── */
.contact__grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: 64px; align-items: start; }
.contact__info { display: flex; flex-direction: column; gap: 18px; }
.contact__info h2 { color: var(--primary); }
.contact__details { display: flex; flex-direction: column; gap: 14px; }
.contact__item { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 0.88rem; }
.contact__item svg { color: var(--primary); flex-shrink: 0; }
.contact__item a:hover { color: var(--primary); }
.contact__form-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: clamp(24px, 4vw, 40px);
  box-shadow: var(--shadow-md);
}
.contact__form { display: flex; flex-direction: column; gap: 14px; }

/* ── 27. Footer ──────────────────────────────────────────── */
.site-footer {
  background: var(--theme-dark-band);
  color: rgba(255,255,255,.78);
  padding: 72px 0 28px;
}
/* Footer closer statement */
.footer__statement {
  text-align: center;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  margin-bottom: 56px;
}
.footer__statement h2 {
  font-family: var(--font-display);
  font-size: var(--step-4);
  font-style: italic;
  font-weight: 400;
  color: #fff;
  max-width: 600px;
  margin: 0 auto 20px;
  line-height: 1.25;
}
.footer__statement .btn { margin: 0 auto; }
.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer__brand { display: flex; flex-direction: column; gap: 14px; }
.footer__brand img { width: 40px; height: 40px; object-fit: contain; border-radius: 10px; }
.footer__brand p   { font-size: 0.86rem; color: rgba(255,255,255,.55); line-height: 1.65; }
.footer__social { display: flex; gap: 10px; margin-top: 6px; }
.footer__social a {
  width: 36px; height: 36px;
  background: rgba(255,255,255,.07);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.6);
  transition: all var(--dur-ui) var(--ease-standard);
}
.footer__social a:hover { background: var(--primary); color: #fff; }

.footer__links,
.footer__services,
.footer__contact { display: flex; flex-direction: column; gap: 10px; }
.footer__links h4,
.footer__services h4,
.footer__contact h4 {
  font-family: var(--font-sans);
  font-size: 0.7rem; font-weight: 700;
  color: rgba(255,255,255,.4);
  text-transform: uppercase; letter-spacing: 0.12em;
  margin-bottom: 6px;
}
.footer__links a,
.footer__services a {
  font-size: 0.86rem; color: rgba(255,255,255,.6);
  transition: color var(--dur-ui) var(--ease-standard);
  padding: 2px 0;
}
.footer__links a:hover,
.footer__services a:hover { color: color-mix(in oklab, var(--accent) 80%, #fff); }
.footer__contact p    { font-size: 0.86rem; color: rgba(255,255,255,.55); line-height: 1.6; }
.footer__cta { font-weight: 700; color: color-mix(in oklab, var(--accent) 85%, #fff); font-size: 1.1rem; }
.footer__bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding-top: 20px;
  font-size: 0.78rem;
  color: rgba(255,255,255,.35);
  text-align: center;
}
/* CSS reveal on footer columns (never GSAP) */
.footer__grid .reveal { opacity: 1; }

/* ── 28. Sticky Mobile CTA ───────────────────────────────── */
.sticky-mobile-cta {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 800;
  background: var(--surface, rgba(255,250,243,.98));
  border-top: 1px solid var(--border);
  padding: 12px 20px; gap: 10px;
  box-shadow: 0 -4px 24px rgba(37,48,42,.1);
}
.sticky-mobile-cta__call {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: 7px;
  background: var(--primary); color: #fff;
  padding: 13px; border-radius: 100px;
  font-weight: 600; font-size: 0.88rem;
}
.sticky-mobile-cta__quote {
  flex: 1; display: flex; align-items: center; justify-content: center;
  background: var(--accent); color: #fff;
  padding: 13px; border-radius: 100px;
  font-weight: 600; font-size: 0.88rem;
}

/* ── 29. Back to top ─────────────────────────────────────── */
.back-to-top {
  position: fixed; bottom: 28px; right: 28px;
  width: 46px; height: 46px;
  background: var(--primary); color: #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
  box-shadow: var(--shadow-md);
  opacity: 0; pointer-events: none;
  transition: all var(--dur-ui) var(--ease-out);
  z-index: 700;
}
.back-to-top.visible { opacity: 1; pointer-events: all; }
.back-to-top:hover   { transform: translateY(-3px); }

/* ── 30. Image placeholder states ────────────────────────── */
.hero__media-frame.img-empty {
  min-height: 360px;
  background: rgba(255,255,255,.06);
  border: 2px dashed rgba(255,255,255,.15);
  display: flex; align-items: center; justify-content: center;
}
.about__media.img-empty {
  min-height: 280px;
  background: var(--theme-green-tint);
  border-radius: var(--radius-xl);
  border: 2px dashed var(--border);
}
.ba-card__side.img-empty   { min-height: 140px; background: var(--border); }
.testimonial-card__author .img-empty,
.cert-card.img-empty       { opacity: 0.5; }

/* ── 31. data-list transparency ──────────────────────────── */
[data-list] { display: contents; }

/* ── 32. GSAP anti-FOUC (fallback only) ──────────────────── */
.js-anim { opacity: 0; }

/* ── 33. Reduced motion (REQUIRED) ──────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ── 34. Responsive ──────────────────────────────────────── */
@media (max-width: 1024px) {
  .hero__split  { grid-template-columns: 1fr; gap: 48px; }
  .hero__media  { display: none; }
  .hero         { min-height: 80svh; }
  .about__grid  { grid-template-columns: 1fr; gap: 48px; }
  .about__media { display: none; }
  .services__grid { grid-template-columns: repeat(2, 1fr); }
  .certs__grid  { grid-template-columns: repeat(2, 1fr); }
  .quote__wrap  { grid-template-columns: 1fr; gap: 40px; }
  .hours__wrap  { grid-template-columns: 1fr; gap: 40px; }
  .contact__grid { grid-template-columns: 1fr; gap: 40px; }
  .footer__grid  { grid-template-columns: 1fr 1fr; gap: 32px; }
  .ba-grid       { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .site-nav    { display: none; }
  .header__phone { display: none; }
  .nav__toggle { display: flex; }
  /* One header row on phones: the CTA hands off to the hero, the sticky bar and the menu,
     the toggle pins right, and a long brand name truncates instead of pushing it off-screen. */
  .header__actions { margin-left: auto; }
  .header__actions .btn { display: none; }
  .logo { flex-shrink: 1; min-width: 0; }
  .logo__name { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .section-pad { padding: clamp(40px, 8vw, 64px) 0; }
  .services__grid    { grid-template-columns: 1fr; }
  .testimonials__grid { grid-template-columns: 1fr; }
  .certs__grid       { grid-template-columns: 1fr; }
  .hero__stats       { gap: 22px; }
  .footer__grid      { grid-template-columns: 1fr; gap: 28px; }
  .form-row          { grid-template-columns: 1fr; }
  .sticky-mobile-cta { display: flex; }
  .back-to-top       { bottom: 78px; }
  .hero__split       { padding: 64px clamp(16px, 4vw, 32px); }
  .quote__form       { padding: 24px; }
  .contact__form-wrap { padding: 24px; }
}

@media (max-width: 480px) {
  /* The sticky bottom bar carries the same Book a Visit link at this width. */
  .header__actions .btn { display: none; }
  .hero__cta-group { flex-direction: column; }
  .hero__cta-group .btn { width: 100%; justify-content: center; }
}


/* __wobooks-defensive__ — appended by HtmlZipThemeConverterV2.
   Hide images whose src resolves to empty (e.g. data-src-field bindings
   for Items / categories the owner hasn't uploaded a photo for yet).
   Without this rule, the browser shows the alt-text fallback —
   that's the bug behind the literal word 'image' showing in avatar
   slots and About images on the production Braise theme. */
img[src=""], img:not([src]) { display: none !important; }

/* Grid-collapse fix: [data-list] is the WoBooks repeater wrapper. When the
   grid/flex layout lives on the PARENT, the wrapper would otherwise become
   a single grid/flex item and collapse every [data-item] row into one cell.
   display:contents makes the wrapper layout-transparent so each row
   participates in the parent track. Mirrors TemplateSkeletonGenerator so
   converted themes match skeleton/AI-generated themes. (Convention: never
   put the grid/flex container ON the [data-list] element itself.) */
[data-list] { display: contents; }

/* Palette roles, item 53 (BrandColourRoles, 2026-10-06): text on a band filled with a palette brand colour follows the fill; brand-coloured text on a band this theme draws dark keeps a lightness floor. */
:where(.service-card:nth-child(2)) .service-card__subtitle { color: oklch(from var(--accent) max(l, 0.75) c h); }
:where(.service-card:nth-child(2)) .service-card__body { color: oklch(from var(--primary) clamp(0, (0.57 - l) * 1000, 1) 0 0); }
:where(.service-card:nth-child(2)) .service-card__cta { color: oklch(from var(--primary) max(l, 0.75) c h); }

/* Own contrast (Weave item 54, theme:palette-stress --heal): with no palette, these read 4.5:1 on the theme's own
   backgrounds; each was proven by rendering the page. The palette block (html:root) still overrides the tokens. */
:root {
  --muted: #646e65; /* was #6f7a70 */
}
.cert-card small { color: oklch(from rgba(255, 255, 255, 0.38) calc(l + 0.04) c h / calc(min(1, alpha + 0.12))); }
.footer__links h4, .footer__services h4, .footer__contact h4 { color: oklch(from rgba(255, 255, 255, 0.4) calc(l + 0.04) c h / calc(min(1, alpha + 0.12))); }
.footer__bottom { color: oklch(from rgba(255, 255, 255, 0.35) calc(l + 0.04) c h / calc(min(1, alpha + 0.12))); }

/* Own contrast (Weave item 54, theme:palette-stress --heal): with no palette, these read 4.5:1 on the theme's own
   backgrounds; each was proven by rendering the page. The palette block (html:root) still overrides the tokens. */
.service-card__subtitle { color: oklch(from var(--accent) min(l, 0.526) c h / alpha); }

/* Own contrast (Weave item 54, theme:palette-stress --heal): with no palette, these read 4.5:1 on the theme's own
   backgrounds; each was proven by rendering the page. The palette block (html:root) still overrides the tokens. */
:where([data-section="about"]) .section-eyebrow { color: oklch(from var(--accent) min(l, 0.526) c h / alpha); }
:where([data-section="services"]) .section-eyebrow { color: oklch(from var(--accent) min(l, 0.466) c h / alpha); }
:where([data-section="service_areas"]) .section-eyebrow { color: oklch(from var(--accent) min(l, 0.526) c h / alpha); }
:where([data-section="quote_request"]) .section-eyebrow { color: oklch(from var(--accent) min(l, 0.526) c h / alpha); }
:where([data-section="opening_hours"]) .section-eyebrow { color: oklch(from var(--accent) min(l, 0.526) c h / alpha); }
:where([data-section="contact"]) .section-eyebrow { color: oklch(from var(--accent) min(l, 0.466) c h / alpha); }
:where([data-section="before_after_gallery"]) .section-eyebrow { color: oklch(from var(--accent) min(l, 0.526) c h / alpha); }
.btn--accent { background-color: oklch(from var(--accent) min(l, 0.576) c h / alpha); }

/* Own contrast (Weave item 54, theme:palette-stress --heal): with no palette, these read 4.5:1 on the theme's own
   backgrounds; each was proven by rendering the page. The palette block (html:root) still overrides the tokens. */
@media (max-width: 768px) { .sticky-mobile-cta__quote { background-color: oklch(from var(--accent) min(l, 0.576) c h / alpha); } }
