.aft-lang-mosaic {
    --lm-ink: #10356D;
    --lm-ink-soft: #4e5366;
    --lm-accent: #f8a800;
    --lm-accent-soft: #fff4d6;
    --lm-rule: #e6e6e6;
    --lm-cream: #fdfcfa;

    position: relative;
    padding: 88px 24px 96px;
    overflow: hidden;
}

.aft-lang-mosaic--white { background: #fff; }
.aft-lang-mosaic--cream { background: var(--lm-cream); }
.aft-lang-mosaic--ink {
    background: var(--lm-ink);
    color: #fff;
    --lm-ink: #ffffff;
    --lm-ink-soft: rgba(255, 255, 255, 0.7);
    --lm-rule: rgba(255, 255, 255, 0.12);
}

/* Soft aurora halo behind the rows — adds depth without distraction. */
.aft-lang-mosaic::before,
.aft-lang-mosaic::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    z-index: 0;
    pointer-events: none;
    opacity: 0.5;
}
.aft-lang-mosaic::before {
    top: -120px; left: -80px;
    width: 360px; height: 360px;
    background: radial-gradient(closest-side, rgba(248, 168, 0, 0.30), transparent 70%);
}
.aft-lang-mosaic::after {
    bottom: -140px; right: -100px;
    width: 420px; height: 420px;
    background: radial-gradient(closest-side, rgba(16, 53, 109, 0.20), transparent 70%);
}

.aft-lang-mosaic__inner {
    position: relative;
    z-index: 1;
    max-width: 1500px;
    margin: 0 auto;
}

.aft-lang-mosaic__header {
    text-align: center;
    margin-bottom: 40px;
    max-width: 760px;
    margin-inline: auto;
}

.aft-lang-mosaic__eyebrow {
    margin: 0 0 8px;
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(20px, 2vw, 26px);
    font-weight: 600;
    font-style: italic;
    color: var(--lm-accent);
    letter-spacing: -0.01em;
    line-height: 1.2;
    text-transform: none;
}

.aft-lang-mosaic__title {
    margin: 0 0 14px;
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(28px, 3.6vw, 44px);
    font-weight: 800;
    color: var(--lm-ink);
    letter-spacing: -0.025em;
    line-height: 1.15;
}

.aft-lang-mosaic__title em {
    font-style: italic;
    font-weight: 500;
    color: var(--lm-accent);
}

.aft-lang-mosaic__intro {
    margin: 0;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 16px;
    line-height: 1.55;
    color: var(--lm-ink-soft);
}

/* ── Flag marquee — two rows, opposite directions ──────────────────────
 * Ported from the /interpretariat-par-telephone/ design. Each track holds
 * two identical copies of its flag set; translateX(-50% - 14px) yields a
 * seamless loop (the 14px = half of the 28px flex gap). Pause on hover.
 */
.aft-lang-mosaic__marquee {
    position: relative;
    overflow: hidden;
    padding: 10px 0;
    margin: 0 -24px 18px;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%);
            mask-image: linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%);
}

.aft-lang-mosaic__marquee:last-of-type { margin-bottom: 0; }

.aft-lang-mosaic__track {
    display: flex;
    gap: 28px;
    width: max-content;
    animation: aft-lang-scroll 42s linear infinite;
    will-change: transform;
}

.aft-lang-mosaic__marquee--reverse .aft-lang-mosaic__track {
    animation-direction: reverse;
    animation-duration: 50s;
}

.aft-lang-mosaic__marquee:hover .aft-lang-mosaic__track {
    animation-play-state: paused;
}

.aft-lang-flag {
    flex: 0 0 auto;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 4px;
    text-decoration: none;
    color: inherit;
    transition: transform 0.35s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.aft-lang-flag:hover { transform: translateY(-4px); }

.aft-lang-flag__img {
    width: 88px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    background: #fff;
    display: block;
    box-shadow: 0 4px 14px rgba(20, 17, 13, 0.10), 0 1px 2px rgba(20, 17, 13, 0.08);
    transition: box-shadow 0.35s ease, transform 0.35s ease;
}

.aft-lang-flag:hover .aft-lang-flag__img {
    box-shadow: 0 10px 24px rgba(20, 17, 13, 0.16), 0 2px 6px rgba(20, 17, 13, 0.10);
}

/* Emoji fallback when a flag image can't be derived. */
.aft-lang-flag__emoji {
    font-size: 46px;
    line-height: 60px;
    width: 88px;
    text-align: center;
    display: block;
}

.aft-lang-flag__label {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: var(--lm-ink-soft);
    letter-spacing: 0.04em;
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    white-space: nowrap;
}

.aft-lang-flag:hover .aft-lang-flag__label {
    opacity: 1;
    transform: translateY(0);
}

@keyframes aft-lang-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(calc(-50% - 14px)); }
}

/* ── "+ N autres langues" line ─────────────────────────────────────── */
.aft-lang-mosaic__more {
    margin: 28px auto 0;
    max-width: 760px;
    text-align: center;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 15px;
    line-height: 1.55;
    color: var(--lm-ink-soft);
}

.aft-lang-mosaic__more strong {
    color: var(--lm-accent);
    font-weight: 700;
}

/* ── Footer CTA ────────────────────────────────────────────────────── */
.aft-lang-mosaic__footer {
    text-align: center;
    margin-top: 36px;
}

.aft-lang-mosaic__cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    background: var(--lm-accent);
    color: #10356D;
    border: 0;
    border-radius: 999px;
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none;
    transition: background-color 0.25s ease, color 0.2s ease, transform 0.2s ease, box-shadow 0.25s ease;
    box-shadow: 0 14px 32px -12px rgba(248, 168, 0, 0.55);
}

.aft-lang-mosaic--ink .aft-lang-mosaic__cta { background: #fff; color: #10356D; }

.aft-lang-mosaic__cta:hover,
.aft-lang-mosaic__cta:focus-visible {
    background: #10356D;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 18px 36px -12px rgba(16, 53, 109, 0.45);
}

/* Respect reduced-motion: stop the scroll, wrap flags into a static,
   readable, centered set with their labels always visible. */
@media (prefers-reduced-motion: reduce) {
    .aft-lang-mosaic__track {
        animation: none;
        flex-wrap: wrap;
        justify-content: center;
        width: auto;
    }
    .aft-lang-mosaic__marquee {
        -webkit-mask-image: none;
                mask-image: none;
    }
    .aft-lang-flag__label { opacity: 1; transform: none; }
}

@media (max-width: 720px) {
    .aft-lang-mosaic { padding: 64px 16px 72px; }
    .aft-lang-mosaic__marquee { margin-inline: -16px; }
    .aft-lang-flag__img { width: 72px; height: 49px; }
    .aft-lang-flag__emoji { width: 72px; font-size: 38px; line-height: 49px; }
    .aft-lang-mosaic__track { gap: 22px; }
    .aft-lang-mosaic__marquee--reverse .aft-lang-mosaic__track,
    .aft-lang-mosaic__track { animation-duration: 32s; }
    .aft-lang-flag__label { opacity: 1; transform: none; } /* touch devices: always show */
}
