/* Figma design-conformance fixes, layered after styles.css. Bump ?v on each
   change during review to defeat browser caching of the unhashed /public file. */

/* ── Legal pages (privacy / terms / cookies / complaints) ──
   The design has no legal-page template; these are plain text pages built by
   src/components/LegalPage.tsx. Kept here (not styles.css) so they stay
   distinct from the coder's CSS and reversible. */
.legal-hero {
  background: var(--maroon, #934454);
  color: #fff;
   padding: 70px 0;
}
.legal-hero h1 { margin: 0; color: #fff; }
.legal-updated { margin: 12px 0 0; opacity: 0.85; font-size: 15px; }
.legal-body { padding-top: 60px;  padding-bottom: 0px; }
.legal-intro { font-size: 18px; line-height: 1.6; margin: 0 0 32px; }
.legal-section { margin: 0 0 32px; }
.legal-section h2 { font-size: 22px; line-height: 1.3; margin: 0 0 12px; }
.legal-section p { margin: 0 0 14px; line-height: 1.7; }
.legal-section ul { margin: 0 0 14px; padding-left: 22px; }
.legal-section li { margin: 0 0 8px; line-height: 1.6; }
.legal-section a { color: var(--maroon, #934454); text-decoration: underline; overflow-wrap: anywhere; }
.legal-note {
  margin-top: 40px; padding: 16px 20px; border-left: 3px solid var(--maroon, #934454);
  background: #f7f2f3; font-size: 15px; line-height: 1.6;
}

/* Cookie consent banner (fixed bottom card). */
.cookie-consent {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 200;
  max-width: 1080px; margin: 0 auto;
  display: flex; align-items: center; gap: 22px; flex-wrap: wrap;
  background: #fff; border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 14px 44px rgba(0, 0, 0, 0.18); border-radius: 12px; padding: 18px 24px;
}
.cookie-consent-text { margin: 0; flex: 1 1 320px; font-size: 14px; line-height: 1.55; color: var(--text); }
.cookie-consent-text a { color: var(--maroon); text-decoration: underline; }
.cookie-consent-actions { display: flex; gap: 12px; flex-shrink: 0; }
.cookie-btn { padding: 11px 22px; border-radius: 6px; font-size: 14px; font-weight: 600; cursor: pointer; border: 1px solid var(--maroon); transition: background 0.2s, opacity 0.2s; }
.cookie-btn--solid { background: var(--maroon); color: #fff; }
.cookie-btn--solid:hover { background: #753744; }
.cookie-btn--ghost { background: transparent; color: var(--maroon); }
.cookie-btn--ghost:hover { background: #f7f2f3; }
/* "Turn off analytics cookies": a button styled as an inline link. */
.cookie-consent-link {
  background: none; border: 0; padding: 0; font: inherit; color: var(--maroon);
  text-decoration: underline; cursor: pointer;
}
.cookie-consent:focus { outline: none; }
.cookie-consent:focus-visible { outline: 2px solid var(--maroon); outline-offset: 2px; }
/* Footer "Cookie settings" (reopens the banner): matches the .footer-legal links. */
.footer-cookie-settings {
  background: none; border: 0; padding: 0; margin: 0; font: inherit; line-height: inherit;
  color: var(--text); cursor: pointer; transition: color 0.2s;
}
.footer-cookie-settings:hover, .footer-cookie-settings:focus-visible { color: var(--maroon); }
@media (max-width: 600px) { .footer-cookie-settings { display: block; text-align: left; } }
@media (max-width: 600px) {
  .cookie-consent { flex-direction: column; align-items: stretch; gap: 14px; }
  .cookie-consent-actions { }
  .cookie-btn { flex: 1; }
}

/* Footer social icon links (real profiles). These replaced the single
   .footer-social placeholder image, so reuse its absolute placement inside the
   position:relative .footer-row (logo pinned left, socials pinned right) —
   otherwise the socials fall into normal flow and the absolute logo overlaps
   them. */
.footer-socials { position: absolute; right: 0; bottom: 0; display: inline-flex; align-items: center; gap: 26px; }
.footer-socials a { color: var(--maroon); display: inline-flex; transition: opacity 0.2s; }
.footer-socials a:hover { opacity: 0.65; }
/* Mobile (≤600px): the logo moves bottom-right, so the socials sit top-left —
   mirror the old .footer-social mobile rule exactly. */
@media (max-width: 600px) {
  .footer-socials { left: 0; top: 0; right: auto; bottom: auto; }
}

/* Dentist referral upload: rebuild the "send us your photos" dropzone as a clean,
   centred drag-drop card (was a cramped flex row with an invisible border and a
   confusing "Submit" label). Works full-width on mobile + desktop. */
.site-form-dropzone {
  flex-direction: column;
  gap: 12px;
  text-align: center;
  margin-top: 22px;
  padding: 34px 24px;
  background: #fff;
  border: 2px dashed rgba(147, 68, 84, 0.4);
  border-radius: 12px;
  transition: background 0.2s, border-color 0.2s;
}
.site-form-dropzone:hover,
.site-form-dropzone:focus-within { border-color: #934454; background: #fdf9fa; }
.site-form-dropzone-icon { width: 40px; height: 40px; }
.site-form-dropzone-text { font-size: 15px; color: var(--text); }

/* Virtual (remote) consultation page: the SmileMate embed sits at the top, with
   a centred intro above it; the "How it works" grid is 3-up; scroll-margin keeps
   the anchor-to-top button clear of the sticky header. */
.smilemate-top { padding-top: 30px; padding-bottom: 8px; }
.smilemate-intro { margin: 0 auto 36px; text-align: left; }
.smilemate-intro h1 { margin: 0 0 16px; }
.smilemate-embed { min-height: 200px; max-width: 900px; margin: 0 auto; }
.smilemate-embed iframe, #sm-scan-iframe { border: none !important; }
.smilemate-help { max-width: 900px; margin: 16px auto 0; text-align: center; font-size: 14px; color: var(--text); }
.smilemate-help a { color: var(--maroon); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.bk-happens-grid--3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 600px) { .bk-happens-grid--3 { grid-template-columns: 1fr; } }

@media (max-width: 600px) { .bk-happens-col p { margin-top: 12px; font-size: 16px; } }


/* Header "Free Consultation" CTA: clicking the button goes to /free-consultation;
   hovering reveals a dropdown with the Virtual Consultation (/smile-mate) link.
   Menu sits flush under the button (top:100%) so the hover doesn't break. */
.header-cta-wrap { position: relative; display: inline-block; }
.header-cta-menu {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: -7px;
  min-width: 100%;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.14);
  padding: 6px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.2s var(--ease), transform 0.2s var(--ease), visibility 0.2s;
  z-index: 60;
  white-space: nowrap;
}
/* transparent bridge across the 6px gap so hover survives moving to the menu */
.header-cta-menu::before { content: ""; position: absolute; left: 0; right: 0; top: -8px; height: 8px; }
.header-cta-wrap:hover .header-cta-menu,
.header-cta-wrap:focus-within .header-cta-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.header-cta-menu-link { display: block; padding: 10px 18px; border-radius: 6px; color: var(--maroon); font-size: 15px; font-weight: 600; text-decoration: none; }
.header-cta-menu-link:hover { background: #f7f2f3; }

/* Free-consultation: make the "prefer to get started from home?" note stand out
   as a callout, with the Virtual Consultation link clearly a link (the design
   strips link styling globally). */
.bk-virtual-note {
  display: block;
  max-width: 620px;
  margin: 40px auto 0;
  padding: 18px 28px;
  background: #f7f2f3;
  border: 1px solid rgba(147, 68, 84, 0.28);
  border-radius: 10px;
  text-align: center;
  font-size: 17px;
  font-weight: 500;
}
.bk-virtual-note a {
  color: var(--maroon);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.bk-virtual-note a:hover { text-decoration: none; }

/* Free-consultation hero: the form column had no bottom padding, so the (now
   two-line) small print sat flush against the edge and looked clipped. */
/* .bk-hero-content { padding-bottom: 56px; } */

/* Free-consultation form: Preferred Location select + "over 18" radios, styled
   to match the dark, translucent-white booking form (mirrors the live site's
   fields). The select reuses .bk-input; add a chevron + placeholder colour. */
.bk-select {
  padding: 16px 44px 16px 20px;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='9' height='6' viewBox='0 0 9 6' fill='none'><path d='M1 1l3.5 3.5L8 1' stroke='%23ffffff' stroke-width='1.5'/></svg>");
  background-repeat: no-repeat;
  background-position: right 18px center;
  cursor: pointer;
}
.bk-select:required:invalid { color: rgba(255, 255, 255, 1.85); } 
.bk-select option { color: #333; }
.bk-radio-field { margin: 0 0 17px; padding: 0; border: 0; }
.bk-radio-legend { padding: 0; margin: 0 0 10px; color: rgba(255, 255, 255, 1.85); font-size: 15px; }
.bk-radio-options { display: flex; gap: 28px; }
.bk-radio { display: inline-flex; align-items: center; gap: 8px; color: var(--white); font-size: 15px; cursor: pointer; }
.bk-radio input { width: 18px; height: 18px; accent-color: var(--maroon); cursor: pointer; }

/* Meet Dr Dirk Schuth: make the role subtitle under the H1 more prominent, and
   give the bio a heading that spans both grid columns (matching the other
   section titles on the page). */
.dirk-hero-role { font-size: 22px; line-height: 28px; font-weight: 600; color: var(--maroon); }
.dirk-bio-title { grid-column: 1 / -1; font-family: var(--font); font-weight: 400; font-size: 24px; line-height: 30px; color: var(--text); margin: 0 0 24px; }
.dirk-bio-title b { font-weight: 600; }

/* Information Leaflets download buttons: the default .tr-btn--dark is a maroon
   OUTLINE (low contrast — hard to see until hover), so invert it to a filled
   maroon button by default and outline on hover. Also add breathing room above
   the button (it sits too close to the leaflet description). Scoped to the
   leaflets .benefits section. */
.benefits .benefit .tr-btn--dark { background: var(--white); color: #753744; border-color: var(--white); margin-top: 20px; }
.benefits .benefit .tr-btn--dark:hover { background: transparent; color: var(--white); border-color: var(--white); }

/* Information Leaflets page (merged section, 2026-09-23 feedback): the rule
   above sets a fixed margin-top: 20px on every .benefit button, which beats
   styles.css's `.benefits--leaflets .benefit .tr-btn { margin-top: auto }`
   on specificity ties because this file loads after styles.css. That fixed
   margin is why CTA buttons weren't lining up across a row when card
   descriptions wrapped to different numbers of lines. This re-applies auto
   margin specifically for the leaflets page's flex-column cards so buttons
   sit flush at the bottom of each row again. */
.benefits--leaflets .benefit .tr-btn--dark {
    margin-top: auto;
}

@media (max-width: 600px) {
    .benefits--leaflets .benefit .tr-btn--dark {
        margin-top: 24px;
    }
}


/* Active state for simple dropdown child links */
.nav-drop-link.active { color: var(--maroon); }

/* Compare Treatments table: stripe alternate rows for readability, like the
   cost-page tables (the table uses inline styles, so scope by the table class). */
.ct-compare tbody tr:nth-child(even) { background: #f4f5f6; }
.ct-compare tbody tr:hover { background: #efeaeb; }

/* ── Cost page ──
   .pc-table-section carries margin-top:324px (designed for a SINGLE table after
   the icons band). Now that the page stacks several cost sections + a private-
   costs block, that huge gap repeats between each — collapse it for every
   section after the first. Same for the calculator's 208px top margin. */
.pc-table-section + .pc-table-section { margin-top: 80px; }
.pc-calc { margin-top: 80px; display: none; }
/* Private-costs block is the only child of its section — drop pc-plans' own top
   margin there so it doesn't compound the gap (leaves the in-table plans note,
   which is NOT first-child, untouched). */
.pc-table-section > .pc-plans:first-child { margin-top: 0; }
/* The Additional & Supplementary Costs intro sits under a full-width table, so
   the centred pc-icons-intro reads misaligned — left-align it to the table. */
.pc-table-section .pc-icons-intro { max-width: 820px; margin-left: 0; margin-right: auto; text-align: left; }

/* Two-tone heading callout: the design emphasises a key phrase of each section
   heading in bold (base headings are weight 400). Some section headings had a
   <b> callout and others didn't — this makes the <b> render at the consistent
   callout weight everywhere, including heading classes without their own `b`
   rule (.sbs-text h2, .tr-title, .cta2-heading, all the hero titles). h3 base
   is already 600, so its callout goes to 700 to stay visible. */
h1 b, h2 b { font-weight: 600; }
h3 b { font-weight: 700; }

/* Carousel/treatment card headings + descriptions: clamp so long copy can never
   push the CTA button out of the fixed-height card (QA fix — belt-and-braces
   alongside keeping card copy concise). .tr-card-info is absolutely positioned
   with limited height, so heading ≤2 lines + desc ≤3 lines keeps the button in. */
.tr-card-heading {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.tr-card-desc {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Card CTA buttons: keep the label on a single line AND let the box grow to fit
   it. The design sets a fixed width:184px; longer names (Functional Appliances /
   Speciality Services) overflowed that box. Grow to content, keep 184px as the
   minimum so short buttons (Braces) are unchanged, and add right padding since
   the width is no longer fixed. */
.tr-btn {
  white-space: nowrap;
  width: auto;
  /* min-width: 184px; */
  padding-right: 24px;
}

/* In-content links: the design strips link styling site-wide, so contextual
   links woven into body copy (e.g. "pair with Dental Monitoring") render as
   plain text and are invisible as links. Style unclassed body links inside
   content text — maroon + underline — WITHOUT touching buttons (.tr-btn/.sbs-btn/
   .consult-btn all carry classes) or classed utility links (findus-text etc.). */
.sbs-text p a:not([class]),
.faq-answer a:not([class]),
.hc-desc a:not([class]),
.tr-subtitle a:not([class]),
.ba-header a:not([class]) {
  color: var(--maroon);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 600;
  transition: opacity 0.2s var(--ease);
}
.sbs-text p a:not([class]):hover,
.faq-answer a:not([class]):hover,
.hc-desc a:not([class]):hover,
.tr-subtitle a:not([class]):hover,
.ba-header a:not([class]):hover { text-decoration: none; opacity: 0.8; }

/* Contact location pages — hours grid (day + time on same row) */
.findus-hours-grid { display: flex; flex-direction: column; gap: 8px; }
.findus-hour-row { display: flex; gap: 32px; font-size: 16px; line-height: 24px; color: var(--text); }
.findus-hour-label { min-width: 140px; }

/* Menu overlay — dark scrim behind all nav dropdowns (mega + simple).
   JS adds .trigged on mouseenter of any .has-mega/.has-dropdown nav item.
   z-index 98 sits below .header (100) so the header and its dropdown panels
   always render on top; only the page content below gets darkened. */
.menu-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 98;
  background: rgba(0, 0, 0, 0.45);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}
.menu-overlay.trigged {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Mobile: .findus-map switches to position:static which detaches the absolutely-
   positioned .findus-pin from the map container — pin disappears. Restore the
   positioning context so the pin stays anchored to the map image. */
@media (max-width: 600px) {
  .findus-map { position: relative; }
}

/* Contact Us — practices grid (replaces horizontal slider). */
.practices-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 64px;
}
.practices-grid .tr-card {
  flex: none;
  width: 100%;
}
@media (max-width: 960px) {
  .practices-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .practices-grid { grid-template-columns: 1fr; margin-top: 32px; }
}
