/* ==========================================================================
   Dental Leaf — Homepage Conversion Layer
   Loaded after the theme, so these rules win without touching theme files.

   Design intent: quiet, premium, medical. Generous whitespace, one accent
   colour, restrained depth (soft shadows rather than borders), type doing the
   work. Nothing decorative competes with the calls to action.

   Accessibility: every interactive target is >=44x44 (WCAG 2.5.8), focus is
   always visible (2.4.11), and all motion is disabled under
   prefers-reduced-motion (2.3.3).
   ========================================================================== */

:root {
    --dlh-ink: #0f2540;
    --dlh-ink-soft: #5b6b7c;
    --dlh-line: #e6ecf4;
    --dlh-bg-soft: #f5f8fc;
    --dlh-accent: var(--primary-color, #4a7cd2);
    --dlh-call: #1f8a4c;
    --dlh-wa: #178540;   /* PHASE 18: WhatsApp brand green #25D366 gives only
                            1.98:1 behind white text — the worst contrast on the
                            site. The buttons are 15px/600 so the 4.5:1 rule
                            applies, not the 3:1 large-text allowance. #178540
                            is the same hue at 4.71:1 and still reads as the
                            WhatsApp green. */
    --dlh-urgent: #c0392b;
    --dlh-radius: 18px;
    --dlh-shadow: 0 1px 2px rgba(15, 37, 64, .04), 0 12px 32px rgba(15, 37, 64, .07);
    --dlh-shadow-lift: 0 2px 4px rgba(15, 37, 64, .05), 0 22px 48px rgba(15, 37, 64, .12);
}

.dlh section,
section.dlh {
    padding: 92px 0;
}

@media (max-width: 991.98px) {
    section.dlh { padding: 64px 0; }
}

/* Section heading rhythm ---------------------------------------------------- */
.dlh-eyebrow {
    display: inline-block;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--dlh-accent);
    margin-bottom: 14px;
}

.dlh-title {
    font-size: clamp(28px, 3.4vw, 42px);
    line-height: 1.15;
    letter-spacing: -.02em;
    color: var(--dlh-ink);
    margin-bottom: 16px;
}

.dlh-lede {
    font-size: 17px;
    line-height: 1.65;
    color: var(--dlh-ink-soft);
    max-width: 62ch;
}

.dlh-center { text-align: center; }
.dlh-center .dlh-lede { margin-inline: auto; }

/* --------------------------------------------------------------------------
   1. Emergency band
   Dental pain is the highest-intent moment a visitor can arrive in. This sits
   directly below the hero so someone in pain never has to scroll or hunt.
   Deliberately the only red element on the page.
   -------------------------------------------------------------------------- */
.dlh-emergency {
    background: linear-gradient(135deg, #7d1d13 0%, var(--dlh-urgent) 100%);
    color: #fff;
    padding: 30px 0;
}

.dlh-emergency__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    flex-wrap: wrap;
}

.dlh-emergency__copy { flex: 1 1 320px; }

.dlh-emergency__title {
    font-size: clamp(20px, 2.2vw, 26px);
    font-weight: 700;
    margin: 0 0 4px;
    color: #fff;
    letter-spacing: -.01em;
}

.dlh-emergency__sub {
    margin: 0;
    color: rgba(255, 255, 255, .88);
    font-size: 15px;
}

.dlh-emergency__actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.dlh-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 48px;
    padding: 13px 26px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    border: 1px solid transparent;
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease;
    white-space: nowrap;
}

.dlh-btn:hover { transform: translateY(-2px); text-decoration: none; }
.dlh-btn:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }

.dlh-btn--call  { background: #fff;              color: var(--dlh-urgent) !important; }
.dlh-btn--wa    { background: var(--dlh-wa);     color: #fff !important; }
.dlh-btn--solid { background: var(--dlh-accent); color: #fff !important; box-shadow: var(--dlh-shadow); }
.dlh-btn--ghost { background: transparent;       color: var(--dlh-ink) !important; border-color: var(--dlh-line); }
.dlh-btn--ghost:hover { border-color: var(--dlh-accent); }

/* --------------------------------------------------------------------------
   2. Trust strip — the four things a patient checks before calling
   -------------------------------------------------------------------------- */
.dlh-trust {
    background: #fff;
    border-bottom: 1px solid var(--dlh-line);
    padding: 26px 0;
}

.dlh-trust__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

@media (max-width: 767.98px) {
    .dlh-trust__grid { grid-template-columns: repeat(2, 1fr); gap: 20px 8px; }
}

.dlh-trust__item { text-align: center; padding: 4px 10px; }

.dlh-trust__value {
    font-size: clamp(19px, 2vw, 24px);
    font-weight: 700;
    color: var(--dlh-ink);
    line-height: 1.2;
    letter-spacing: -.01em;
}

.dlh-trust__label {
    font-size: 13px;
    color: var(--dlh-ink-soft);
    margin-top: 3px;
}

.dlh-stars { color: #f5a623; letter-spacing: 1px; }

/* --------------------------------------------------------------------------
   3. Card grid — used by Safety, Technology and Payments
   -------------------------------------------------------------------------- */
.dlh-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(268px, 1fr));
    gap: 20px;
}

.dlh-card {
    background: #fff;
    border: 1px solid var(--dlh-line);
    border-radius: var(--dlh-radius);
    padding: 30px 26px;
    transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.dlh-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--dlh-shadow-lift);
    border-color: transparent;
}

.dlh-card__icon {
    width: 46px;
    height: 46px;
    border-radius: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(74, 124, 210, .10);
    color: var(--dlh-accent);
    font-size: 20px;
    margin-bottom: 18px;
}

.dlh-card__title {
    font-size: 17px;
    font-weight: 700;
    color: var(--dlh-ink);
    margin: 0 0 8px;
}

.dlh-card__text {
    font-size: 15px;
    line-height: 1.6;
    color: var(--dlh-ink-soft);
    margin: 0;
}

.dlh-soft { background: var(--dlh-bg-soft); }

/* --------------------------------------------------------------------------
   4. Payments row
   -------------------------------------------------------------------------- */
.dlh-pay {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 22px;
}

.dlh-pay__chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid var(--dlh-line);
    font-size: 14px;
    font-weight: 600;
    color: var(--dlh-ink);
}

/* --------------------------------------------------------------------------
   5. Closing call to action
   -------------------------------------------------------------------------- */
.dlh-cta {
    background: linear-gradient(135deg, #0f2540 0%, #1d4a80 100%);
    color: #fff;
    border-radius: 26px;
    padding: clamp(34px, 5vw, 62px);
    text-align: center;
}

.dlh-cta__title {
    font-size: clamp(26px, 3.2vw, 40px);
    font-weight: 700;
    color: #fff;
    letter-spacing: -.02em;
    margin-bottom: 12px;
}

.dlh-cta__sub {
    color: rgba(255, 255, 255, .85);
    font-size: 17px;
    max-width: 56ch;
    margin: 0 auto 28px;
}

.dlh-cta__actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.dlh-cta .dlh-btn--ghost {
    color: #fff !important;
    border-color: rgba(255, 255, 255, .35);
}

.dlh-cta .dlh-btn--ghost:hover { border-color: #fff; }

.dlh-cta__note {
    margin-top: 18px;
    font-size: 14px;
    color: rgba(255, 255, 255, .7);
}

/* --------------------------------------------------------------------------
   6. Reduced motion
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    .dlh-btn,
    .dlh-card {
        transition: none;
    }
    .dlh-btn:hover,
    .dlh-card:hover {
        transform: none;
    }
}

/* ==========================================================================
   REVIEW WALL — testimonials.html
   --------------------------------------------------------------------------
   Card treatment follows the reference the clinic picked (minpilot.webflow.io):
   32px radius, 32px padding, soft low shadow, round avatar, a rule under the
   reviewer, then the quote, then a footer with the date on the right.

   Three deliberate departures:

   1. The avatar is an initial on a coloured disc, not a photograph. There are
      no patient photos and a stock face against a real person's review would
      be a fabrication. Google shows initials the same way.
   2. No auto-scrolling columns. The reference marquees each column, which
      would need a pause control under WCAG 2.2.2 and makes 61 reviews
      impossible to scan or Ctrl+F.
   3. Masonry columns rather than fixed rows: these reviews run from 19 to 891
      characters, so equal-height rows left two-word reviews floating in
      300px of white space.
   ========================================================================== */

.dlt-wall {
    position: relative;
}

.dlt-cols {
    column-count: 3;
    column-gap: 26px;
}

.dlt-card {
    display: inline-block;
    width: 100%;
    margin: 0 0 26px;
    padding: 30px;
    background: #fff;
    border: 1px solid #eef1f6;
    border-radius: 26px;
    box-shadow: 0 5px 14px rgba(16, 32, 56, .07);
    break-inside: avoid;
    -webkit-column-break-inside: avoid;
    transition: box-shadow .22s ease, border-color .22s ease;
}

.dlt-card:hover {
    border-color: transparent;
    box-shadow: 0 14px 34px rgba(16, 32, 56, .12);
}

/* ---- reviewer ---- */
.dlt-card__head {
    display: flex;
    align-items: center;
    gap: 14px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eceff5;
}

.dlt-avatar {
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-size: 19px;
    font-weight: 700;
    line-height: 1;
    color: #fff;
    background: #4a5568;
}

/* every tone measured at >= 4.5:1 against the white initial */
.dlt-avatar[data-tone="0"] { background: #3168c7; }
.dlt-avatar[data-tone="1"] { background: #1e864a; }
.dlt-avatar[data-tone="2"] { background: #7a3fa8; }
.dlt-avatar[data-tone="3"] { background: #b4531b; }
.dlt-avatar[data-tone="4"] { background: #0f6e86; }
.dlt-avatar[data-tone="5"] { background: #a32b54; }
.dlt-avatar[data-tone="6"] { background: #4a5568; }
.dlt-avatar[data-tone="7"] { background: #166a6a; }

.dlt-who {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.dlt-name {
    font-size: 15.5px;
    font-weight: 600;
    line-height: 1.3;
    color: #1d2733;
    overflow-wrap: anywhere;
}

.dlt-handle {
    font-size: 13.5px;
    line-height: 1.3;
    color: #697687;
}

/* ---- quote ---- */
.dlt-quote {
    margin: 20px 0 0;
    padding: 0;
    border: 0;
}

.dlt-text {
    margin: 0;
    font-size: 15.5px;
    line-height: 1.62;
    color: #3c4959;
}

.dlt-rating {
    margin-top: 18px;
}

/* ---- footer ---- */
.dlt-card__foot {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
    margin-top: 22px;
    font-size: 13.5px;
    color: #6b7584;
}

.dlt-date {
    flex: 0 0 auto;
    white-space: nowrap;
}

/* ==========================================================================
   Collapsed height + "show all"
   --------------------------------------------------------------------------
   61 cards is a 6,000px page. The wall opens capped with a fade, and the
   button lifts the cap.

   The cap is applied only once the script has run (.dl-js), so with
   JavaScript off — and for Googlebot's raw HTML — every review is visible and
   nothing is hidden behind a control that cannot work.
   ========================================================================== */

.dlt-fade,
.dlt-more {
    display: none;
}

.dl-js .dlt-wall[data-collapsed] {
    max-height: 1500px;
    overflow: hidden;
}

.dl-js .dlt-wall[data-collapsed] .dlt-fade {
    display: block;
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 190px;
    pointer-events: none;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0), #fff 88%);
}

.dl-js .dlt-more {
    display: block;
    margin-top: 28px;
}

@media (max-width: 1199px) {
    .dlt-cols { column-count: 2; }
}

@media (max-width: 767px) {
    .dlt-cols { column-count: 1; column-gap: 0; }
    .dlt-card { padding: 26px 22px; border-radius: 22px; }
    .dl-js .dlt-wall[data-collapsed] { max-height: 1200px; }
}

@media (prefers-reduced-motion: reduce) {
    .dlt-card { transition: none; }
}
