/*!
 * legal-shield consent — styles.
 * Retheme by overriding the custom properties on :root. Keep the contrast
 * ratios: this banner is often the least accessible thing on an otherwise
 * compliant site, which is an embarrassing finding in an ADA complaint.
 */
/* Sweet Homes theme. The site has no dark mode, so neither does the pop-up:
   the skill's dark-scheme blocks are removed rather than overridden.
   Ratios measured on --ls-bg (#fdf8e7). */
:root {
  --ls-bg:        #fdf8e7;   /* --cream-card */
  --ls-fg:        #003420;   /* --green, 13.1:1 */
  --ls-muted:     #755706;   /* --ochre, 6.3:1 */
  --ls-border:    rgba(0, 52, 32, 0.18);   /* decorative dividers only */
  --ls-edge:      #5f7a6e;   /* 4.4:1 — control boundaries (WCAG 1.4.11) */
  --ls-accent:    #003420;   /* --green */
  --ls-accent-fg: #f7efd6;   /* --cream on --green, 12.1:1 */
  --ls-focus:     #003420;
  --ls-radius:    0;
  --ls-shadow:    0 -6px 28px rgba(0, 22, 13, .14);   /* soft lift for the bottom bar */
  --ls-z:         2147483000;
  --ls-font:      "Work Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --ls-display:   "Marcellus", Georgia, "Times New Roman", serif;
  --ls-mono:      "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

.ls-root { position: fixed; z-index: var(--ls-z); color: var(--ls-fg);
  font: 400 15px/1.55 var(--ls-font); }
.ls-root *, .ls-root *::before, .ls-root *::after { box-sizing: border-box; }

.ls-bar, .ls-bottom { inset: auto 0 0 0; }
/* While the bottom bar is open, consent.js sets --ls-bar-h to its height so
   the end of the page can still be scrolled clear of it. */
html.ls-bar-open body { padding-bottom: var(--ls-bar-h, 0px); }
.ls-corner { inset: auto auto 1rem 1rem; max-width: 26rem; }

.ls-banner, .ls-panel {
  background: var(--ls-bg);
  border: 1px solid var(--ls-edge);
  box-shadow: var(--ls-shadow);
  padding: 1.25rem 1.25rem 1.1rem;
}
.ls-bar .ls-banner, .ls-bottom .ls-banner { border-width: 1px 0 0; margin: 0 auto; max-width: 68rem; }
.ls-bar { background: var(--ls-bg); border-top: 1px solid var(--ls-edge); box-shadow: var(--ls-shadow); }
.ls-bar .ls-banner { box-shadow: none; border: 0; }
/* Centred pop-up. Same buttons, same equal weight — only the frame changes. */
.ls-modal .ls-banner { width: min(34rem, 100%); border-radius: var(--ls-radius);
  padding: 1.5rem 1.5rem 1.35rem; max-height: 85vh; overflow-y: auto; }
.ls-modal .ls-actions { justify-content: flex-end; }
.ls-corner .ls-banner { border-radius: var(--ls-radius); }

.ls-title { margin: 0 0 .4rem; font-size: 1.0625rem; font-weight: 650; line-height: 1.3; }
.ls-body  { margin: 0 0 .7rem; color: var(--ls-fg); max-width: 60ch; }
.ls-gpc   { margin: 0 0 .7rem; padding: .55rem .7rem; border-left: 3px solid var(--ls-accent);
            background: color-mix(in srgb, var(--ls-accent) 8%, transparent);
            color: var(--ls-fg); font-size: .9375rem; max-width: 60ch; }
.ls-links { margin: 0 0 .85rem; font-size: .875rem; color: var(--ls-muted); }
.ls-links a { color: var(--ls-accent); text-underline-offset: 2px; }

.ls-actions { display: flex; flex-wrap: wrap; gap: .55rem; align-items: center; }

/* Accept and Reject are deliberately identical. Making one louder than the
   other is a dark pattern and can invalidate the consent it collects. */
.ls-btn {
  font: inherit; font-weight: 600;
  min-height: 44px; min-width: 44px;     /* WCAG 2.2 target size, with margin */
  padding: .55rem 1.1rem;
  border-radius: 8px; border: 1px solid transparent;
  cursor: pointer;
}
.ls-btn-primary { background: var(--ls-accent); color: var(--ls-accent-fg); }
.ls-btn-primary:hover { filter: brightness(.92); }
.ls-btn-quiet {
  background: transparent; color: var(--ls-fg);
  border-color: var(--ls-edge); text-decoration: underline;
}
.ls-btn-quiet:hover { background: color-mix(in srgb, var(--ls-fg) 7%, transparent); }

.ls-root :focus-visible {
  outline: 3px solid var(--ls-focus);
  outline-offset: 2px;
  border-radius: 4px;
}

.ls-overlay {
  inset: 0; display: grid; place-items: center; padding: 1rem;
  background: rgba(8, 11, 18, .6);
  overflow-y: auto;
}
.ls-panel {
  width: min(38rem, 100%); max-height: min(85vh, 46rem); overflow-y: auto;
  border-radius: var(--ls-radius);
}

.ls-cats { margin: .35rem 0 1rem; display: grid; gap: .1rem; }
.ls-cat { padding: .7rem 0; border-bottom: 1px solid var(--ls-border); }
.ls-cat:last-child { border-bottom: 0; }
.ls-cat-label { display: flex; gap: .6rem; align-items: center; cursor: pointer;
                font-weight: 600; min-height: 32px; }
.ls-cat-label:has(.ls-cb:disabled) { cursor: default; }
.ls-cb { width: 20px; height: 20px; accent-color: var(--ls-accent); flex: none; cursor: inherit; }
.ls-cat-desc { margin: .3rem 0 0 1.85rem; color: var(--ls-muted); font-size: .9375rem; max-width: 62ch; }

@media (max-width: 30rem) {
  .ls-actions { flex-direction: column; align-items: stretch; }
  .ls-btn { width: 100%; }
  .ls-corner { inset: auto 0 0 0; max-width: none; }
}

@media (prefers-reduced-motion: reduce) {
  .ls-root, .ls-root * { animation: none !important; transition: none !important; }
}
@media (prefers-contrast: more) {
  .ls-banner, .ls-panel { border-width: 2px; }
  .ls-btn { border-color: currentColor; }
}
@media print { .ls-root { display: none !important; } }

/* Click-to-load facade for gated iframes (YouTube, Maps, Calendly). */
.ls-facade {
  display: grid; place-items: center; gap: .6rem; text-align: center;
  min-height: 12rem; padding: 1.5rem;
  border: 1px dashed var(--ls-edge); border-radius: var(--ls-radius);
  background: color-mix(in srgb, var(--ls-fg) 4%, transparent);
  color: var(--ls-fg);
}
.ls-facade p { margin: 0; max-width: 46ch; color: var(--ls-muted); font-size: .9375rem; }

/* A gated iframe has no src yet — don't reserve empty space next to its facade. */
iframe[data-cc-src]:not([src]) { display: none; }

/* Sweet Homes type: Marcellus titles, mono buttons like the site's .btn. */
/* Reset the legal pages' h2 rule (border-top + padding) so it does not leak in. */
.ls-title { font-family: var(--ls-display); font-weight: 400; font-size: 1.375rem; letter-spacing: .01em;
  border: 0; padding: 0; }
.ls-btn { font-family: var(--ls-mono); font-size: 13px; font-weight: 500;
  letter-spacing: .1em; text-transform: uppercase; border-radius: 0; }
.ls-btn-quiet { text-decoration: none; }
.ls-overlay { background: rgba(0, 22, 13, .8); }
.ls-panel { box-shadow: 0 40px 120px rgba(0, 22, 13, .45); }
