/* =========================================================
   RIO / PBEEL-GL
   NAVIGATION & IDENTITÉ
   Version finale — responsive
   ========================================================= */


/* =========================================================
   1. HEADER PRINCIPAL
   ========================================================= */

#header.header {
    position: sticky;
    top: 0;
    z-index: 997;
    width: 100%;B
}

#header > .container {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 0;
}


/* =========================================================
   2. IDENTITÉ / MARQUE RIO
   ========================================================= */

.brand-pbeel {
    display: inline-flex;
    align-items: center;
    flex: 0 1 auto;
    min-width: 0;
    margin: 0 22px 0 0;
    padding: 0;
    text-decoration: none;
    position: relative;
    z-index: 10;
}


/* ---------- Logo ---------- */

.brand-logo {
    position: relative;

    width: 56px;
    height: 56px;

    flex: 0 0 56px;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 4px;

    border-radius: 14px;

    background: #fff;
    border: 1px solid rgba(13, 110, 253, .12);

    box-shadow: 0 4px 14px rgba(13, 110, 253, .10);

    transition:
        transform .25s ease,
        box-shadow .25s ease;
}

.brand-logo img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: contain;
}


/* Animation légère du logo */

.brand-pbeel:hover .brand-logo {
    transform: translateY(-1px);

    box-shadow:
        0 7px 18px rgba(13, 110, 253, .16);
}


/* Petit point décoratif */

.brand-logo::after {
    content: "";

    position: absolute;

    width: 8px;
    height: 8px;

    top: 1px;
    right: 1px;

    border-radius: 50%;

    background: #1bbd36;

    box-shadow:
        0 0 0 4px rgba(19, 198, 232, .12);

    animation: brandPulse 2s ease-in-out infinite;
}


@keyframes brandPulse {

    0%,
    100% {
        transform: scale(1);
        opacity: .8;
    }

    50% {
        transform: scale(1.25);
        opacity: 1;
    }
}


/* =========================================================
   3. TEXTE DE LA MARQUE
   ========================================================= */

.brand-text {
    display: flex;
    flex-direction: column;
    justify-content: center;

    min-width: 0;

    line-height: 1.05;
}


/* RIO */

.brand-text strong {
    display: block;

    margin: 0;

    color: #0d6efd;

    font-size: 20px;
    line-height: 1;

    font-weight: 800;

    letter-spacing: .4px;
}


/* Réseau d'Innovation Organisationnelle */

.brand-text span {
    display: block;

    margin-top: 3px;

    color: #45556b;

    font-size: 9px;
    line-height: 1.1;

    font-weight: 700;

    text-transform: uppercase;

    letter-spacing: .1px;

    white-space: nowrap;
}


/* PBEEL-GL Bourse 2026 */

.brand-text small {
    display: block;

    margin-top: 4px;

    color: #1bbd36;

    font-size: 7.5px;
    line-height: 1;

    font-weight: 800;

    letter-spacing: .7px;

    white-space: nowrap;
}


/* =========================================================
   4. NAVIGATION DESKTOP
   ========================================================= */

#header .navmenu {
    flex: 1 1 auto;

    min-width: 0;

    margin: 0;
    padding: 0;
}


#header .navmenu > ul {
    display: flex;

    align-items: center;

    justify-content: flex-end;

    gap: 2px;

    margin: 0;
    padding: 0;
}


#header .navmenu > ul > li > a {
    white-space: nowrap;
}


/* =========================================================
   5. TABLETTES
   992px → 1199px
   ========================================================= */

@media (max-width: 1199px) and (min-width: 992px) {

    .brand-pbeel {
        gap: 8px;

        margin-right: 14px;
    }


    .brand-logo {
        width: 50px;
        height: 50px;

        flex-basis: 50px;

        border-radius: 12px;
    }


    .brand-text strong {
        font-size: 18px;
    }


    .brand-text span {
        font-size: 8px;
    }


    .brand-text small {
        font-size: 7px;
    }
}


/* =========================================================
   6. MOBILE
   0 → 991px
   ========================================================= */

@media (max-width: 991px) {

    /* -----------------------------------------------------
       HEADER
       ----------------------------------------------------- */

    #header.header {
        width: 100%;

        min-height: 64px;
        height: 64px;

        background: #fff;
    }


    #header > .container {

        width: 100%;
        max-width: 100%;

        height: 64px;

        padding-left: 10px;
        padding-right: 10px;

        display: flex;

        align-items: center;

        justify-content: space-between;

        gap: 0;
    }


    /* -----------------------------------------------------
       MARQUE
       ----------------------------------------------------- */

    .brand-pbeel {

        display: flex;

        align-items: center;

        gap: 8px;

        width: auto;

        max-width: calc(100% - 40px);

        min-width: 0;

        margin: 0;
        padding: 0;

        flex: 0 1 auto;
    }


    /* -----------------------------------------------------
       LOGO MOBILE
       ----------------------------------------------------- */

    .brand-logo {

        width: 44px;
        height: 44px;

        flex: 0 0 44px;

        padding: 3px;

        border-radius: 11px;

        box-shadow:
            0 3px 10px rgba(13, 110, 253, .10);
    }


    .brand-logo::after {

        width: 7px;
        height: 7px;

        top: 0;
        right: 0;

        box-shadow:
            0 0 0 3px rgba(19, 198, 232, .11);
    }


    /* -----------------------------------------------------
       BLOC TEXTE
       ----------------------------------------------------- */

    .brand-text {

        display: grid;

        grid-template-columns: auto 1px minmax(0, 1fr);

        grid-template-rows: auto auto;

        column-gap: 7px;

        row-gap: 2px;

        align-items: center;

        min-width: 0;

        overflow: hidden;
    }


    /* -----------------------------------------------------
       RIO
       ----------------------------------------------------- */

    .brand-text strong {

        grid-column: 1;
        grid-row: 1 / 3;

        display: flex;

        align-items: center;

        margin: 0;

        color: #0d6efd;

        font-size: 18px;

        line-height: 1;

        font-weight: 800;

        letter-spacing: .3px;

        white-space: nowrap;
    }


    /* -----------------------------------------------------
       BARRE VERTICALE
       ----------------------------------------------------- */

    .brand-text::before {

        content: "";

        grid-column: 2;

        grid-row: 1 / 3;

        width: 1px;

        height: 30px;

        background: rgba(69, 85, 107, .35);

        align-self: center;
    }


    /* -----------------------------------------------------
       NOM DE L'ORGANISATION
       ----------------------------------------------------- */

    .brand-text span {

        grid-column: 3;
        grid-row: 1;

        display: block;

        width: 100%;
        max-width: none;

        margin: 0;

        overflow: hidden;

        color: #45556b;

        font-size: 7.4px;

        line-height: 1.1;

        font-weight: 700;

        text-transform: none;

        letter-spacing: 0;

        white-space: nowrap;

        text-overflow: clip;
    }


    /* -----------------------------------------------------
       PBEEL-GL BOURSE 2026
       ----------------------------------------------------- */

    .brand-text small {

        grid-column: 3;
        grid-row: 2;

        display: block;

        width: 100%;

        margin: 0;

        overflow: hidden;

        color: #1bbd36;

        font-size: 6px;

        line-height: 1;

        font-weight: 800;

        letter-spacing: .45px;

        white-space: nowrap;

        text-overflow: clip;
    }


    /* -----------------------------------------------------
       MENU MOBILE
       ----------------------------------------------------- */

    #header .navmenu {

        flex: 0 0 auto;

        width: auto;

        margin: 0;
        padding: 0;
    }


    /* Masquer le menu desktop */

    #header .navmenu > ul {
        display: none;
    }


    /* -----------------------------------------------------
       HAMBURGER
       ----------------------------------------------------- */

    #header .mobile-nav-toggle {

        display: block;

        width: 31px;
        height: 31px;

        flex: 0 0 31px;

        margin: 0 !important;

        padding: 4px !important;

        color: #0d6efd;

        font-size: 22px;

        line-height: 22px;

        cursor: pointer;

        text-align: center;
    }
}


/* =========================================================
   7. SMARTPHONES
   576px → 767px
   ========================================================= */

@media (max-width: 767px) {

    #header > .container {

        padding-left: 10px;
        padding-right: 10px;
    }


    .brand-pbeel {

        gap: 8px;

        max-width: calc(100% - 40px);
    }


    .brand-logo {

        width: 43px;
        height: 43px;

        flex-basis: 43px;
    }


    .brand-text strong {

        font-size: 17px;
    }


    .brand-text span {

        font-size: 10px;
    }


    .brand-text small {

        font-size: 7px;

        letter-spacing: .4px;
    }
}


/* =========================================================
   8. PETITS SMARTPHONES
   ≤ 480px
   ========================================================= */

@media (max-width: 480px) {

    #header.header {

        min-height: 62px;
        height: 62px;
    }


    #header > .container {

        height: 62px;

        padding-left: 9px;
        padding-right: 9px;
    }


    .brand-pbeel {

        gap: 7px;

        max-width: calc(100% - 38px);
    }


    .brand-logo {

        width: 41px;
        height: 41px;

        flex-basis: 41px;

        padding: 3px;

        border-radius: 10px;
    }


    .brand-text {

        column-gap: 6px;

        row-gap: 2px;
    }


    .brand-text strong {

        font-size: 16.5px;
    }


    .brand-text::before {

        height: 28px;
    }


    .brand-text span {

        font-size: 10px;

        line-height: 1.05;
    }


    .brand-text small {

        font-size: 7px;

        letter-spacing: .3px;
    }


    #header .mobile-nav-toggle {

        width: 29px;
        height: 29px;

        flex-basis: 29px;

        padding: 3px !important;

        font-size: 21px;

        line-height: 21px;
    }
}


/* =========================================================
   9. TRÈS PETITS ÉCRANS
   ≤ 380px
   ========================================================= */

@media (max-width: 380px) {

    #header > .container {

        padding-left: 7px;
        padding-right: 7px;
    }


    .brand-pbeel {

        gap: 6px;

        max-width: calc(100% - 36px);
    }


    .brand-logo {

        width: 38px;
        height: 38px;

        flex-basis: 38px;

        border-radius: 9px;
    }


    .brand-text {

        column-gap: 5px;

        row-gap: 1px;
    }


    .brand-text strong {

        font-size: 15px;
    }


    .brand-text::before {

        height: 25px;
    }


    .brand-text span {

        font-size: 10.1px;
    }


    .brand-text small {

        font-size: 7px;

        letter-spacing: .2px;
    }


    #header .mobile-nav-toggle {

        width: 27px;
        height: 27px;

        flex-basis: 27px;

        font-size: 20px;

        line-height: 20px;
    }
}


/* =========================================================
   10. ACCESSIBILITÉ
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

    .brand-logo,
    .brand-pbeel:hover .brand-logo {

        transition: none;
    }


    .brand-logo::after {

        animation: none;
    }
}


/* =========================================================
   FIN — STYLE NAVIGATION
   ========================================================= */
   
   /* =========================================================
   ANIMATION — IDENTITÉ RIO / PBEEL-GL
   ========================================================= */

/* Animation générale de la marque à son apparition */
.brand-pbeel {
    animation: brandEntrance .8s cubic-bezier(.22, 1, .36, 1) both;
}


/* ---------------------------------------------------------
   1. LOGO
   --------------------------------------------------------- */

.brand-logo {
    animation:
        logoEntrance .8s cubic-bezier(.22, 1, .36, 1) both,
        logoFloat 4s ease-in-out 1s infinite;

    transform-origin: center;
}


/* Apparition du logo */
@keyframes logoEntrance {

    0% {
        opacity: 0;
        transform: scale(.65) rotate(-8deg);
    }

    70% {
        opacity: 1;
        transform: scale(1.06) rotate(2deg);
    }

    100% {
        opacity: 1;
        transform: scale(1) rotate(0);
    }
}


/* Petit mouvement permanent très discret */
@keyframes logoFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-2px);
    }
}


/* ---------------------------------------------------------
   2. POINT LUMINEUX DU LOGO
   --------------------------------------------------------- */

.brand-logo::after {

    animation:
        brandPulse 2s ease-in-out infinite,
        brandGlow 2.5s ease-in-out infinite;
}


@keyframes brandGlow {

    0%,
    100% {
        box-shadow:
            0 0 0 3px rgba(19, 198, 232, .10);
    }

    50% {
        box-shadow:
            0 0 0 5px rgba(19, 198, 232, .18),
            0 0 12px rgba(19, 198, 232, .25);
    }
}


/* ---------------------------------------------------------
   3. TEXTE RIO
   --------------------------------------------------------- */

.brand-text strong {

    animation:
        textRIO .65s cubic-bezier(.22, 1, .36, 1) .15s both;
}


@keyframes textRIO {

    0% {
        opacity: 0;
        transform: translateX(-12px);
    }

    100% {
        opacity: 1;
        transform: translateX(0);
    }
}


/* ---------------------------------------------------------
   4. NOM DE L'ORGANISATION
   --------------------------------------------------------- */

.brand-text span {

    animation:
        textOrganization .7s cubic-bezier(.22, 1, .36, 1) .3s both;
}


@keyframes textOrganization {

    0% {
        opacity: 0;
        transform: translateX(12px);
    }

    100% {
        opacity: 1;
        transform: translateX(0);
    }
}


/* ---------------------------------------------------------
   5. PBEEL-GL / BOURSE 2026
   --------------------------------------------------------- */

.brand-text small {

    animation:
        textPbeel .7s cubic-bezier(.22, 1, .36, 1) .45s both;
}


@keyframes textPbeel {

    0% {
        opacity: 0;
        transform: translateY(7px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}


/* ---------------------------------------------------------
   6. BARRE VERTICALE MOBILE
   --------------------------------------------------------- */

@media (max-width: 991px) {

    .brand-text::before {

        animation:
            separatorReveal .6s ease .3s both;

        transform-origin: center;
    }
}


@keyframes separatorReveal {

    0% {
        opacity: 0;
        transform: scaleY(0);
    }

    100% {
        opacity: 1;
        transform: scaleY(1);
    }
}


/* ---------------------------------------------------------
   7. HAMBURGER
   --------------------------------------------------------- */

@media (max-width: 991px) {

    #header .mobile-nav-toggle {

        animation:
            menuEntrance .6s cubic-bezier(.22, 1, .36, 1) .55s both;
    }
}


@keyframes menuEntrance {

    0% {
        opacity: 0;
        transform: translateX(10px) scale(.8);
    }

    100% {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}


/* ---------------------------------------------------------
   8. HOVER DESKTOP
   --------------------------------------------------------- */

@media (min-width: 992px) {

    .brand-pbeel:hover .brand-logo {

        transform:
            translateY(-2px)
            scale(1.03);
    }


    .brand-pbeel:hover .brand-text strong {

        letter-spacing: .8px;
    }


    .brand-pbeel:hover .brand-text span {

        color: #0d6efd;
    }


    .brand-pbeel:hover .brand-text small {

        color: #13c6e8;
    }


    .brand-text strong,
    .brand-text span,
    .brand-text small {

        transition:
            color .25s ease,
            letter-spacing .25s ease;
    }
}


/* ---------------------------------------------------------
   9. RÉDUCTION DES ANIMATIONS
   Pour les utilisateurs ayant activé
   "Réduire les animations" sur leur appareil.
   --------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {

    .brand-pbeel,
    .brand-logo,
    .brand-logo::after,
    .brand-text strong,
    .brand-text span,
    .brand-text small,
    .brand-text::before,
    #header .mobile-nav-toggle {

        animation: none !important;

        transition: none !important;
    }
}