/* =============================================
   Numbers Block — taubenloft/numbers
   Figma 1:2583
   ─────────────────────────────────────────────
   Section bg:    #EAEBE6
   Padding:       96 top / 0 sides / 96 bottom (inner padding-x 240 via container)
   Title row:     eyebrow+heading LEFT (586w) | caption RIGHT (520w)
   Main row:      pill + value 64/76.8 weight 500 + caption (centered, full 1440)
   Title row 2:   2× 720 cells, dark pill + intro 20/28 weight 600
   Data rows:     2× 720 cells, outline pill + value 36/50.4 weight 500 + caption 16/21.8
   ============================================= */

.tl-numbers {
    background: #eaebe6;
    color: #333a42;
    font-family: 'Nunito Sans', 'Nunito Sans Fallback', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    padding: 96px 24px;
}

.tl-numbers__container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 48px;
}

/* ── Header (eyebrow + heading | caption) ───────── */
.tl-numbers__titles {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 48px;
    padding-bottom: 48px;
}
.tl-numbers__titles-left {
    display: flex;
    flex-direction: column;
    gap: 32px;
    flex: 0 1 586px;
}
.tl-numbers__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    font-size: 16px;
    line-height: 21.824px;
    font-weight: 500;
    letter-spacing: 0;
    text-transform: uppercase;
    color: #333a42;
}
.tl-numbers__eyebrow-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #333a42;
    flex: 0 0 20px;
}
.tl-numbers__heading {
    margin: 0;
    font-size: 36px;
    line-height: 50.4px;
    font-weight: 500;
    letter-spacing: 0;
    color: #333a42;
}
.tl-numbers__subcaption {
    margin: 0;
    flex: 0 1 520px;
    font-size: 16px;
    line-height: 24px;
    font-weight: 400;
    color: #333a42;
}

/* ── Pills ─────────────────────────────────────── */
.tl-numbers__pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 24px;
    border-radius: 50px;
    font-size: 16px;
    line-height: 24px;
    font-weight: 400;
    letter-spacing: 0;
    width: -moz-fit-content;
    width: fit-content;
    align-self: center;
}
.tl-numbers__pill--outline {
    background: transparent;
    color: #333a42;
    border: 1px solid #787d84;     /* Figma 2026-05 verified: solid #787D84 */
}
.tl-numbers__pill--dark {
    background: #333a42;
    color: #eaebe6;
}

/* ── Table layout ───────────────────────────────── */
.tl-numbers__table {
    display: flex;
    flex-direction: column;
    border-top: 0.5px solid rgba(51, 58, 66, 0.5);  /* closing top edge of bordered table */
}

.tl-numbers__row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-bottom: 0.5px solid rgba(51, 58, 66, 0.5);
    border-left: 0.5px solid rgba(51, 58, 66, 0.5);    /* Figma 2026-05: outer left edge */
    border-right: 0.5px solid rgba(51, 58, 66, 0.5);   /* Figma 2026-05: outer right edge */
}
.tl-numbers__row--main {
    grid-template-columns: 1fr;
}

.tl-numbers__cell {
    padding: 48px 32px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    text-align: center;
}
/* Cells inside the special __row containers (main, titles) keep the older border logic */
.tl-numbers__row > .tl-numbers__cell:not(:last-child) {
    border-right: 0.5px solid rgba(51, 58, 66, 0.5);
}
.tl-numbers__cell--main {
    border-right: 0;
    border-bottom: 0.5px solid rgba(51, 58, 66, 0.5);
}

/* ── Comparison cells: flat grid, fills left→right ── */
.tl-numbers__cells {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-bottom: 0.5px solid rgba(51, 58, 66, 0.5);   /* closing line under the table */
}
.tl-numbers__cells > .tl-numbers__cell {
    border-top: 0.5px solid rgba(51, 58, 66, 0.5);      /* horizontal divider above each cell */
}
.tl-numbers__cells > .tl-numbers__cell:first-child,
.tl-numbers__cells > .tl-numbers__cell:nth-child(2) {
    border-top: 0;                                     /* first row has divider from title row above */
}
/* Figma 2026-05: each cell has both left and right vertical borders */
.tl-numbers__cells > .tl-numbers__cell {
    border-left: 0.5px solid rgba(51, 58, 66, 0.5);
    border-right: 0.5px solid rgba(51, 58, 66, 0.5);
}
/* Avoid double borders at the seam (right edge of col 1 + left edge of col 2) */
.tl-numbers__cells > .tl-numbers__cell:nth-child(2n) {
    border-left: 0;
}

/* ── Values ─────────────────────────────────────── */
.tl-numbers__value {
    font-size: 36px;
    line-height: 50.4px;
    font-weight: 500;
    color: #333a42;
    margin: 0;
}
.tl-numbers__value--big {
    font-size: 64px;
    line-height: 76.8px;
}
.tl-numbers__caption {
    margin: 0;
    font-size: 16px;
    line-height: 21.824px;
    font-weight: 500;
    color: #787d84;
    text-transform: lowercase;
}
.tl-numbers__intro {
    margin: 0;
    font-size: 20px;
    line-height: 28px;
    font-weight: 600;          /* Figma 2026-05 verified: SemiBold 600 base */
    color: #333a42;
}
.tl-numbers__intro p {
    margin: 0 0 12px;
    font-weight: 600;          /* base paragraphs SemiBold */
}
.tl-numbers__intro p:last-child { margin-bottom: 0; }
/* "→ Verschmutzung..." arrow line — bold per Figma styleOverrides (fw 700) */
.tl-numbers__intro p:nth-child(2),
.tl-numbers__intro p:last-child:not(:first-child) {
    font-weight: 700;
}

/* ── Methodik link ──────────────────────────────── */
.tl-numbers__methodik {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    align-self: flex-start;
    font-size: 16px;
    line-height: 24px;
    font-weight: 400;
    color: #333a42 !important;
    text-decoration: none;
    transition: opacity 0.2s;
}
.tl-numbers__methodik:hover { opacity: 0.7; color: #333a42 !important; }
.tl-numbers__methodik svg { display: block; }

/* ── Footer CTA ─────────────────────────────────── */
.tl-numbers__cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    text-align: center;
    padding-top: 48px;
    margin-top: 48px;
}
.tl-numbers__cta-heading {
    margin: 0;
    font-size: 36px;
    line-height: 50.4px;
    font-weight: 500;
    color: #333a42;
    max-width: 800px;
}
.tl-numbers__cta-caption {
    margin: 0;
    font-size: 16px;
    line-height: 24px;
    font-weight: 400;
    color: #000;                  /* Figma 2026-05 verified: pure black */
    margin-bottom: 24px;
}
.tl-numbers__cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    border-radius: 50px;
    background: #333a42;
    color: #eaebe6 !important;
    text-decoration: none;
    font-size: 16px;
    line-height: 24px;
    font-weight: 400;
    transition: opacity 0.2s, background 0.2s;
}
.tl-numbers__cta-btn:hover,
.tl-numbers__cta-btn:focus {
    background: #4a5159;
    color: #eaebe6 !important;
}
.tl-numbers__cta-btn svg {
    display: block;
    transition: transform 0.25s ease-out;
}
/* → arrow nudges right on hover */
.tl-numbers__cta-btn:hover svg,
.tl-numbers__cta-btn:focus svg {
    transform: translateX(3px);
}
/* Methodik → arrow nudges right */
.tl-numbers__methodik svg {
    transition: transform 0.25s ease-out;
}
.tl-numbers__methodik:hover svg,
.tl-numbers__methodik:focus svg {
    transform: translateX(3px);
}

/* ── Laptop ≤1440 ─────────────────────────────────── */
@media (max-width: 1440px) {
    ; }
}

/* ── Tablet ≤1024 — force-stack titles (heading + caption) ─────────────── */
@media (max-width: 1024px) {
    .tl-numbers { padding: 64px 32px; }
    /* Force-stack heading + caption (heading on top, caption below) at tablet/mobile */
    .tl-numbers__titles {
        display: block !important;
        padding-bottom: 0 !important;              /* gap to table handled by container gap */
    }
    .tl-numbers__titles-left,
    .tl-numbers__subcaption {
        flex: 0 0 auto !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    /* titles-left keeps flex column + gap 32 so eyebrow→heading spacing works on mobile */
    .tl-numbers__titles-left { display: flex !important; flex-direction: column; gap: 32px; }
    .tl-numbers__subcaption { display: block !important; margin-top: 32px; }
    .tl-numbers__heading,
    .tl-numbers__cta-heading { font-size: 28px; line-height: 1.25; }
    .tl-numbers__value--big { font-size: 48px; line-height: 1.2; }
}

/* ── Mobile ≤767 ──────────────────────────────────── */
@media (max-width: 767px) {
    .tl-numbers { padding: 48px 16px; }
    .tl-numbers__container { gap: 48px; }              /* Figma mobile #11 itemSpacing = 48 */
    /* Belt-and-suspenders: force titles to stack even if 1024 MQ doesn't apply */
    .tl-numbers__titles {
        display: block !important;
        flex-direction: column !important;
        padding-bottom: 0 !important;
    }
    .tl-numbers__titles-left,
    .tl-numbers__subcaption {
        width: 100% !important;
        max-width: 100% !important;
        flex: none !important;
    }
    /* titles-left keeps flex column with gap so eyebrow→heading spacing is visible */
    .tl-numbers__titles-left {
        display: flex !important;
        flex-direction: column !important;
        gap: 24px !important;
    }
    .tl-numbers__subcaption {
        display: block !important;
        margin-top: 32px;
    }
    /* Unified eyebrow size across all blocks on mobile: 14/19.1, dot 14×14 */
    .tl-numbers__eyebrow { font-size: 14px; line-height: 19.1px; font-weight: 500; }
    .tl-numbers__eyebrow-dot { width: 14px; height: 14px; flex-basis: 14px; }
    .tl-numbers__heading { font-size: 24px; line-height: 28.8px; }

    /* Main banner row (bestand ~230) stays single-column on mobile */
    .tl-numbers__row--main {
        grid-template-columns: 1fr;
    }
    /* Titles row (two intro pills + headlines) STAYS 2-column on mobile per Figma */
    .tl-numbers__row--titles {
        grid-template-columns: 1fr 1fr;
    }
    .tl-numbers__cell {
        padding: 24px 12px;
        border-right: 0.5px solid rgba(51, 58, 66, 0.5);
        border-bottom: 0.5px solid rgba(51, 58, 66, 0.5);
        min-width: 0;                  /* allow content to shrink inside grid track */
    }
    .tl-numbers__row--main .tl-numbers__cell {
        padding: 32px 16px;
        border-right: 0;
    }
    .tl-numbers__row > .tl-numbers__cell:last-child { border-right: 0; }
    /* Cells inside flat repeater grid: tighter padding so 2-col fits narrow phones */
    .tl-numbers__cells { gap: 0; }
    .tl-numbers__cells > .tl-numbers__cell { padding: 24px 10px; }
    /* Keep the outer RIGHT border on the 2nd-column cells so the grid is closed
       on both sides (mirrors the outer left edge) — the base rule already gives it. */

    .tl-numbers__value--big { font-size: 64px; line-height: 76.8px; }  /* Figma mobile 2026-05: keeps 64/76.8 like desktop */
    .tl-numbers__value { font-size: 28px; line-height: 1.2; }
    .tl-numbers__cta-heading { font-size: 24px; line-height: 28.8px; } /* Figma mobile 2026-05 */
    .tl-numbers__cta-btn { align-self: stretch; justify-content: center; }
    /* Pills — Figma mobile 2026-05: padding 24px sides (titles-row stays smaller) */
    .tl-numbers__pill {
        font-size: 14px;
        font-weight: 400;
        padding: 8px 24px;
        white-space: normal;
        text-align: center;
        max-width: 100%;
        line-height: 19.6px;
    }
    .tl-numbers__row--titles .tl-numbers__pill { padding: 8px 16px; }    /* smaller for 2-col title pills */
    /* Intro (title-row text) — Figma mobile: 16/22.4 (first p regular, arrow line bold) */
    .tl-numbers__intro {
        font-size: 16px;
        line-height: 22.4px;
        font-weight: 400;
    }
    .tl-numbers__intro p:nth-child(2),
    .tl-numbers__intro p:last-child:not(:first-child) {
        font-weight: 700;
    }
    /* Cell value (kotfaktor ~10 kg etc) — Figma mobile: 24/28.8 weight 600 */
    .tl-numbers__cells .tl-numbers__value {
        font-size: 24px;
        line-height: 28.8px;
        font-weight: 600;
    }
    .tl-numbers__caption { font-size: 16px; line-height: 24px; font-weight: 400; }
}

/* ── Narrow phones (≤400) — keep 2-col but shrink content further ───── */
@media (max-width: 400px) {
    .tl-numbers__cells > .tl-numbers__cell { padding: 20px 8px; }
    .tl-numbers__pill { font-size: 13px; padding: 6px 10px; }
    .tl-numbers__intro { font-size: 15px; line-height: 21px; }
    .tl-numbers__value { font-size: 22px; line-height: 1.2; }
    .tl-numbers__value--big { font-size: 32px; line-height: 1.2; }
    .tl-numbers__caption { font-size: 14px; line-height: 1.4; }

    /* Force-stack titles even at narrow widths — guards against long German word overflow */
    .tl-numbers__titles {
        display: block;
    }
    .tl-numbers__titles-left,
    .tl-numbers__subcaption {
        width: 100%;
        max-width: 100%;
    }
    .tl-numbers__subcaption {
        margin-top: 32px !important;
    }
    .tl-numbers__heading,
    .tl-numbers__subcaption,
    .tl-numbers__cta-heading {
        overflow-wrap: break-word;
        word-break: break-word;
    }
    /* Prevent table from leaking outside viewport */
    .tl-numbers__table { margin-left: 0; margin-right: 0; }
    .tl-numbers__cells { grid-template-columns: 1fr 1fr; min-width: 0; }
}
