/**
 * CEPR — Language switcher (segmented FR | EN)
 */

.cepr-locale-switcher--segmented {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
}

.cepr-locale-switcher__legend {
    font-size: 0.8125rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.75);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.cepr-locale-switcher__group {
    display: inline-flex;
    align-items: stretch;
    border: 2px solid var(--cepr-blue-dark, #003366);
    border-radius: 999px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.cepr-locale-switcher__option {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    min-width: 2.75rem;
    padding: 0.4rem 0.7rem;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-decoration: none;
    color: var(--cepr-blue-dark, #003366);
    background: transparent;
    border: none;
    transition: background 0.15s ease, color 0.15s ease;
}

.cepr-locale-switcher__option + .cepr-locale-switcher__option {
    border-left: 1px solid rgba(0, 51, 102, 0.2);
}

.cepr-locale-switcher__option:not(.cepr-locale-switcher__option--selected):hover {
    background: var(--cepr-blue-light, #e6f4fa);
    color: var(--cepr-blue-dark, #003366);
}

.cepr-locale-switcher__option--selected {
    background: var(--cepr-blue-dark, #003366);
    color: var(--cepr-project-gold, #f5c518);
    font-weight: 700;
    cursor: default;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
}

.cepr-locale-switcher__check {
    font-size: 0.625rem;
    opacity: 0.95;
}

.cepr-locale-switcher__code {
    line-height: 1;
}

.cepr-locale-switcher__name {
    font-size: 0.6875rem;
    font-weight: 500;
    opacity: 0.95;
}

/* Compact — admin / platform header */
.cepr-locale-switcher--compact .cepr-locale-switcher__option {
    min-width: 2.5rem;
    padding: 0.35rem 0.65rem;
}

.cepr-locale-switcher--compact .cepr-locale-switcher__name {
    display: none;
}

/* Admin gold top bar */
.cepr-admin-topbar .cepr-locale-switcher__group {
    border-color: var(--cepr-black, #1a1a1a);
    background: rgba(255, 255, 255, 0.95);
}

.cepr-admin-topbar .cepr-locale-switcher__option--selected {
    background: var(--cepr-blue-dark, #003366);
    color: var(--cepr-project-gold, #f5c518);
}

/* Platform header (same gold bar) */
.cepr-platform-header .cepr-locale-switcher__group {
    border-color: var(--cepr-black, #1a1a1a);
    background: rgba(255, 255, 255, 0.95);
}

/* Public navbar — light background */
.cepr-public-nav .cepr-locale-switcher__group,
header .cepr-locale-switcher__group {
    border-color: var(--cepr-blue-mid, #006699);
}

/* Footer — dark background */
.cepr-locale-switcher--footer {
    width: 100%;
}

.cepr-locale-switcher--footer .cepr-locale-switcher__group {
    border-color: rgba(255, 255, 255, 0.45);
    background: rgba(0, 0, 0, 0.2);
}

.cepr-locale-switcher--footer .cepr-locale-switcher__option {
    color: #fff;
}

.cepr-locale-switcher--footer .cepr-locale-switcher__option + .cepr-locale-switcher__option {
    border-left-color: rgba(255, 255, 255, 0.25);
}

.cepr-locale-switcher--footer .cepr-locale-switcher__option:not(.cepr-locale-switcher__option--selected):hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

.cepr-locale-switcher--footer .cepr-locale-switcher__option--selected {
    background: var(--cepr-project-gold, #f5c518);
    color: var(--cepr-black, #1a1a1a);
    box-shadow: none;
}

.cepr-locale-switcher--footer .cepr-locale-switcher__name {
    display: inline;
}

body.cepr-platform .cepr-platform-footer__member .cepr-locale-switcher--footer .cepr-locale-switcher__legend {
    color: rgba(255, 255, 255, 0.75);
}
