/* =========================================================
   ISC LUBUMBASHI — HEADER V2
   Fichier : header.css
   ========================================================= */


/* ---------------------------------------------------------
   1. VARIABLES
   --------------------------------------------------------- */

:root {
    --isc-header-blue: #0a2f67;
    --isc-header-blue-dark: #071f46;
    --isc-header-blue-deep: #04152f;
    --isc-header-blue-soft: #edf4fc;

    --isc-header-red: #c62828;
    --isc-header-red-dark: #991b1b;
    --isc-header-red-soft: #ef4444;

    --isc-header-white: #ffffff;
    --isc-header-text: #162033;
    --isc-header-text-soft: #667085;

    --isc-header-border: rgba(10, 47, 103, 0.11);
    --isc-header-border-strong: rgba(10, 47, 103, 0.18);

    --isc-header-shadow:
        0 12px 34px rgba(4, 21, 47, 0.09);

    --isc-header-shadow-sticky:
        0 16px 44px rgba(4, 21, 47, 0.14);

    --isc-header-radius-sm: 12px;
    --isc-header-radius-md: 16px;
    --isc-header-radius-pill: 999px;

    --isc-header-main-height: 98px;
    --isc-header-nav-height: 58px;

    --isc-header-transition: 220ms ease;
}


/* ---------------------------------------------------------
   2. UTILITAIRE ACCESSIBILITÉ
   --------------------------------------------------------- */

.isc-visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}


/* ---------------------------------------------------------
   3. STRUCTURE GÉNÉRALE
   --------------------------------------------------------- */

.isc-site-header {
    position: relative;
    z-index: 100;
    width: 100%;
    color: var(--isc-header-text);
    background: var(--isc-header-white);
}

.isc-header-main {
    position: relative;
    z-index: 12;
    min-height: var(--isc-header-main-height);
    background: var(--isc-header-white);
    border-bottom: 1px solid var(--isc-header-border);
    transition:
        min-height var(--isc-header-transition),
        box-shadow var(--isc-header-transition),
        background var(--isc-header-transition);
}

.isc-header-main__inner {
    display: flex;
    min-height: var(--isc-header-main-height);
    align-items: center;
    justify-content: space-between;
    gap: 36px;
    transition:
        min-height var(--isc-header-transition),
        padding var(--isc-header-transition);
}


/* ---------------------------------------------------------
   4. IDENTITÉ VISUELLE
   --------------------------------------------------------- */

.isc-header-brand {
    display: inline-flex;
    min-width: 0;
    flex: 0 1 auto;
    align-items: center;
    gap: 18px;
    color: var(--isc-header-text);
}

.isc-header-brand__logo {
    display: grid;
    flex: 0 0 76px;
    place-items: center;
    width: 76px;
    height: 76px;
    padding: 4px;
    overflow: hidden;
    border: 1px solid var(--isc-header-border);
    border-radius: 50%;
    background: var(--isc-header-white);
    box-shadow:
        0 10px 24px rgba(4, 21, 47, 0.09);
    transition:
        width var(--isc-header-transition),
        height var(--isc-header-transition),
        flex-basis var(--isc-header-transition),
        box-shadow var(--isc-header-transition),
        transform var(--isc-header-transition);
}

.isc-header-brand:hover .isc-header-brand__logo {
    box-shadow:
        0 14px 30px rgba(4, 21, 47, 0.14);
    transform: translateY(-2px);
}

.isc-header-brand__logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.isc-header-brand__divider {
    width: 1px;
    height: 52px;
    background:
        linear-gradient(
            to bottom,
            transparent,
            var(--isc-header-border-strong),
            transparent
        );
}

.isc-header-brand__content {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.isc-header-brand__name {
    color: var(--isc-header-blue-dark);
    font-size: 1.15rem;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.025em;
}

.isc-header-brand__subtitle {
    color: var(--isc-header-text);
    font-size: 0.84rem;
    font-weight: 700;
    line-height: 1.25;
}

.isc-header-brand__motto {
    color: var(--isc-header-text-soft);
    font-size: 0.66rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}


/* ---------------------------------------------------------
   5. OUTILS DU HEADER
   --------------------------------------------------------- */

.isc-header-tools {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 10px;
}


/* ---------------------------------------------------------
   6. RECHERCHE DESKTOP
   --------------------------------------------------------- */

.isc-header-search {
    position: relative;
    display: flex;
    width: min(360px, 30vw);
    height: 46px;
    align-items: center;
    border: 1px solid var(--isc-header-border);
    border-radius: 14px;
    background: #f8fafc;
    transition:
        border-color var(--isc-header-transition),
        box-shadow var(--isc-header-transition),
        background var(--isc-header-transition);
}

.isc-header-search:focus-within {
    border-color: rgba(10, 47, 103, 0.28);
    background: var(--isc-header-white);
    box-shadow:
        0 0 0 4px rgba(10, 47, 103, 0.07);
}

.isc-header-search input {
    width: 100%;
    min-width: 0;
    height: 100%;
    padding: 0 48px 0 16px;
    color: var(--isc-header-text);
    border: 0;
    outline: 0;
    background: transparent;
    font: inherit;
    font-size: 0.82rem;
}

.isc-header-search input::placeholder {
    color: #98a2b3;
}

.isc-header-search button {
    position: absolute;
    top: 50%;
    right: 5px;
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    padding: 0;
    color: var(--isc-header-blue);
    border: 0;
    border-radius: 10px;
    background: transparent;
    cursor: pointer;
    transform: translateY(-50%);
    transition:
        color var(--isc-header-transition),
        background var(--isc-header-transition),
        transform var(--isc-header-transition);
}

.isc-header-search button:hover {
    color: var(--isc-header-white);
    background: var(--isc-header-blue);
}

.isc-header-search button:active {
    transform:
        translateY(-50%)
        scale(0.95);
}


/* ---------------------------------------------------------
   7. BOUTON RECHERCHE COMPACT
   --------------------------------------------------------- */

.isc-header-search-toggle {
    display: none;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    color: var(--isc-header-blue);
    border: 1px solid var(--isc-header-border);
    border-radius: 13px;
    background: var(--isc-header-white);
    cursor: pointer;
    transition:
        color var(--isc-header-transition),
        border-color var(--isc-header-transition),
        background var(--isc-header-transition),
        transform var(--isc-header-transition);
}

.isc-header-search-toggle:hover {
    color: var(--isc-header-white);
    border-color: var(--isc-header-blue);
    background: var(--isc-header-blue);
    transform: translateY(-2px);
}

.isc-header-search-toggle i {
    font-size: 1.08rem;
}


/* ---------------------------------------------------------
   8. ESPACE ÉTUDIANT
   --------------------------------------------------------- */

.isc-header-student-button {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 0 16px;
    color: var(--isc-header-blue-dark);
    border: 1px solid var(--isc-header-border);
    border-radius: 13px;
    background: var(--isc-header-white);
    font-size: 0.78rem;
    font-weight: 800;
    white-space: nowrap;
    transition:
        color var(--isc-header-transition),
        border-color var(--isc-header-transition),
        background var(--isc-header-transition),
        transform var(--isc-header-transition),
        box-shadow var(--isc-header-transition);
}

.isc-header-student-button:hover {
    color: var(--isc-header-white);
    border-color: var(--isc-header-blue);
    background: var(--isc-header-blue);
    box-shadow:
        0 12px 24px rgba(10, 47, 103, 0.18);
    transform: translateY(-2px);
}

.isc-header-student-button i {
    font-size: 1rem;
}


/* ---------------------------------------------------------
   9. SÉLECTEUR DE LANGUE
   --------------------------------------------------------- */

.isc-header-language {
    position: relative;
}

.isc-header-language__toggle {
    display: inline-flex;
    min-width: 64px;
    height: 44px;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0 12px;
    color: var(--isc-header-blue-dark);
    border: 1px solid var(--isc-header-border);
    border-radius: 13px;
    background: var(--isc-header-white);
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 800;
    transition:
        color var(--isc-header-transition),
        border-color var(--isc-header-transition),
        background var(--isc-header-transition);
}

.isc-header-language__toggle:hover,
.isc-header-language__toggle[aria-expanded="true"] {
    color: var(--isc-header-white);
    border-color: var(--isc-header-blue);
    background: var(--isc-header-blue);
}

.isc-header-language__toggle i {
    font-size: 0.95rem;
    transition: transform var(--isc-header-transition);
}

.isc-header-language__toggle[aria-expanded="true"] i {
    transform: rotate(180deg);
}

.isc-header-language__menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    z-index: 50;
    width: 210px;
    padding: 8px;
    border: 1px solid var(--isc-header-border);
    border-radius: 14px;
    background: var(--isc-header-white);
    box-shadow:
        0 20px 48px rgba(4, 21, 47, 0.16);
}

.isc-header-language__menu::before {
    position: absolute;
    top: -6px;
    right: 18px;
    width: 12px;
    height: 12px;
    content: "";
    border-top: 1px solid var(--isc-header-border);
    border-left: 1px solid var(--isc-header-border);
    background: var(--isc-header-white);
    transform: rotate(45deg);
}

.isc-header-language__menu a {
    display: grid;
    grid-template-columns: 36px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 10px 11px;
    color: var(--isc-header-text);
    border-radius: 10px;
    transition:
        color var(--isc-header-transition),
        background var(--isc-header-transition);
}

.isc-header-language__menu a:hover,
.isc-header-language__menu a.is-active {
    color: var(--isc-header-blue-dark);
    background: var(--isc-header-blue-soft);
}

.isc-header-language__menu a span {
    font-size: 0.78rem;
    font-weight: 800;
}

.isc-header-language__menu a small {
    color: var(--isc-header-text-soft);
    font-size: 0.72rem;
}

.isc-header-language__menu a i {
    color: var(--isc-header-blue);
}


/* ---------------------------------------------------------
   10. BOUTON HAMBURGER MOBILE
   --------------------------------------------------------- */

.isc-header-mobile-toggle {
    display: none;
    width: 44px;
    height: 44px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 0;
    border: 1px solid var(--isc-header-border);
    border-radius: 13px;
    background: var(--isc-header-white);
    cursor: pointer;
    transition:
        border-color var(--isc-header-transition),
        background var(--isc-header-transition),
        transform var(--isc-header-transition);
}

.isc-header-mobile-toggle:hover {
    border-color: var(--isc-header-blue);
    background: var(--isc-header-blue-soft);
    transform: translateY(-2px);
}

.isc-header-mobile-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    border-radius: var(--isc-header-radius-pill);
    background: var(--isc-header-blue-dark);
    transition:
        transform var(--isc-header-transition),
        opacity var(--isc-header-transition);
}


/* ---------------------------------------------------------
   11. BARRE DE NAVIGATION
   --------------------------------------------------------- */

.isc-header-navigation {
    position: relative;
    z-index: 10;
    min-height: var(--isc-header-nav-height);
    color: var(--isc-header-white);
    background:
        linear-gradient(
            90deg,
            var(--isc-header-blue-dark) 0%,
            var(--isc-header-blue) 100%
        );
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.isc-header-navigation::before {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 180px;
    height: 3px;
    content: "";
    background:
        linear-gradient(
            90deg,
            var(--isc-header-red),
            transparent
        );
}

.isc-header-navigation__inner {
    display: flex;
    min-height: var(--isc-header-nav-height);
    align-items: center;
    justify-content: space-between;
    gap: 28px;
}

.isc-header-nav {
    min-width: 0;
    flex: 1 1 auto;
}

.isc-header-nav__list {
    display: flex;
    min-width: 0;
    align-items: stretch;
    gap: 2px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.isc-header-nav__item {
    position: relative;
    display: flex;
    align-items: stretch;
}

.isc-header-nav__item--home {
    margin-right: 4px;
}

.isc-header-nav__link,
.isc-header-nav__home {
    position: relative;
    display: inline-flex;
    min-height: var(--isc-header-nav-height);
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0 15px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.76rem;
    font-weight: 800;
    white-space: nowrap;
    transition:
        color var(--isc-header-transition),
        background var(--isc-header-transition);
}

.isc-header-nav__home {
    width: 46px;
    padding: 0;
    border-radius: 10px;
}

.isc-header-nav__home i {
    font-size: 1rem;
}

.isc-header-nav__link::after,
.isc-header-nav__home::after {
    position: absolute;
    right: 14px;
    bottom: 0;
    left: 14px;
    height: 3px;
    content: "";
    border-radius: 6px 6px 0 0;
    background: var(--isc-header-red);
    transform: scaleX(0);
    transform-origin: center;
    transition: transform var(--isc-header-transition);
}

.isc-header-nav__home::after {
    right: 8px;
    left: 8px;
}

.isc-header-nav__item:hover > .isc-header-nav__link,
.isc-header-nav__item.is-active > .isc-header-nav__link,
.isc-header-nav__home:hover,
.isc-header-nav__home.is-active {
    color: var(--isc-header-white);
    background: rgba(255, 255, 255, 0.07);
}

.isc-header-nav__item:hover > .isc-header-nav__link::after,
.isc-header-nav__item.is-active > .isc-header-nav__link::after,
.isc-header-nav__home:hover::after,
.isc-header-nav__home.is-active::after {
    transform: scaleX(1);
}

.isc-header-nav__link i {
    font-size: 0.92rem;
    transition: transform var(--isc-header-transition);
}

.isc-header-nav__item:hover > .isc-header-nav__link i {
    transform: rotate(180deg);
}


/* ---------------------------------------------------------
   12. SOUS-MENU SIMPLE
   --------------------------------------------------------- */

.isc-header-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 80;
    width: 260px;
    padding: 10px;
    opacity: 0;
    visibility: hidden;
    border: 1px solid var(--isc-header-border);
    border-radius: 0 0 16px 16px;
    background: var(--isc-header-white);
    box-shadow:
        0 22px 50px rgba(4, 21, 47, 0.16);
    transform: translateY(10px);
    transition:
        opacity var(--isc-header-transition),
        visibility var(--isc-header-transition),
        transform var(--isc-header-transition);
}

.isc-header-nav__item:hover > .isc-header-dropdown,
.isc-header-nav__item:focus-within > .isc-header-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.isc-header-dropdown ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.isc-header-dropdown li + li {
    margin-top: 3px;
}

.isc-header-dropdown a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 11px 12px;
    color: var(--isc-header-text);
    border-radius: 10px;
    font-size: 0.78rem;
    font-weight: 700;
    transition:
        color var(--isc-header-transition),
        background var(--isc-header-transition),
        transform var(--isc-header-transition);
}

.isc-header-dropdown a:hover {
    color: var(--isc-header-blue);
    background: var(--isc-header-blue-soft);
    transform: translateX(3px);
}


/* ---------------------------------------------------------
   13. BOUTON CANDIDATURE
   --------------------------------------------------------- */

.isc-header-application-button {
    display: inline-flex;
    min-height: 42px;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 0 17px;
    color: var(--isc-header-white);
    border-radius: 12px;
    background:
        linear-gradient(
            135deg,
            var(--isc-header-red-soft),
            var(--isc-header-red)
        );
    box-shadow:
        0 12px 24px rgba(198, 40, 40, 0.24);
    font-size: 0.76rem;
    font-weight: 800;
    white-space: nowrap;
    transition:
        transform var(--isc-header-transition),
        box-shadow var(--isc-header-transition),
        background var(--isc-header-transition);
}

.isc-header-application-button:hover {
    box-shadow:
        0 16px 30px rgba(198, 40, 40, 0.34);
    transform: translateY(-2px);
}

.isc-header-application-button i {
    font-size: 0.98rem;
}


/* ---------------------------------------------------------
   14. BOUTON MENU TABLETTE
   --------------------------------------------------------- */

.isc-header-tablet-menu-button {
    display: none;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 0 16px;
    color: var(--isc-header-white);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.07);
    cursor: pointer;
    font-size: 0.76rem;
    font-weight: 800;
    transition:
        border-color var(--isc-header-transition),
        background var(--isc-header-transition),
        transform var(--isc-header-transition);
}

.isc-header-tablet-menu-button:hover {
    border-color: rgba(255, 255, 255, 0.24);
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-2px);
}

.isc-header-tablet-menu-button i {
    font-size: 1rem;
}


/* ---------------------------------------------------------
   15. HEADER FIXE ET COMPACT
   --------------------------------------------------------- */

.isc-site-header.is-sticky {
    position: sticky;
    top: 0;
    z-index: 200;
    box-shadow: var(--isc-header-shadow-sticky);
}

.isc-site-header.is-sticky .isc-header-main {
    min-height: 76px;
}

.isc-site-header.is-sticky .isc-header-main__inner {
    min-height: 76px;
}

.isc-site-header.is-sticky .isc-header-brand__logo {
    width: 58px;
    height: 58px;
    flex-basis: 58px;
}

.isc-site-header.is-sticky .isc-header-brand__divider {
    height: 42px;
}

.isc-site-header.is-sticky .isc-header-brand__motto {
    display: none;
}


/* ---------------------------------------------------------
   16. ÉTATS GLOBAUX
   --------------------------------------------------------- */

body.isc-navigation-open {
    overflow: hidden;
}

.isc-site-header a:focus-visible,
.isc-site-header button:focus-visible,
.isc-site-header input:focus-visible {
    outline: 3px solid rgba(198, 40, 40, 0.3);
    outline-offset: 3px;
}


/* ---------------------------------------------------------
   17. RESPONSIVE — LARGE DESKTOP
   --------------------------------------------------------- */

@media (max-width: 1280px) {
    .isc-header-main__inner {
        gap: 24px;
    }

    .isc-header-search {
        width: min(300px, 25vw);
    }

    .isc-header-nav__link {
        padding-inline: 12px;
    }

    .isc-header-brand__name {
        font-size: 1.05rem;
    }

    .isc-header-brand__subtitle {
        font-size: 0.78rem;
    }
}


/* ---------------------------------------------------------
   18. RESPONSIVE — PETITS DESKTOPS
   --------------------------------------------------------- */

@media (max-width: 1120px) {
    .isc-header-search {
        display: none;
    }

    .isc-header-search-toggle {
        display: grid;
    }

    .isc-header-nav__list {
        gap: 0;
    }

    .isc-header-nav__link {
        padding-inline: 10px;
        font-size: 0.72rem;
    }

    .isc-header-application-button {
        padding-inline: 14px;
    }
}


/* ---------------------------------------------------------
   19. RESPONSIVE — TABLETTES
   --------------------------------------------------------- */

@media (max-width: 980px) {
    :root {
        --isc-header-main-height: 84px;
        --isc-header-nav-height: 54px;
    }

    .isc-header-brand__logo {
        width: 64px;
        height: 64px;
        flex-basis: 64px;
    }

    .isc-header-brand__divider {
        height: 44px;
    }

    .isc-header-brand__motto {
        display: none;
    }

    .isc-header-nav {
        display: none;
    }

    .isc-header-tablet-menu-button {
        display: inline-flex;
    }

    .isc-header-navigation__inner {
        justify-content: flex-end;
    }

    .isc-header-application-button {
        margin-left: auto;
    }
}


/* ---------------------------------------------------------
   20. RESPONSIVE — PETITES TABLETTES
   --------------------------------------------------------- */

@media (max-width: 760px) {
    .isc-header-main {
        min-height: 74px;
    }

    .isc-header-main__inner {
        min-height: 74px;
        gap: 16px;
    }

    .isc-header-brand {
        gap: 12px;
    }

    .isc-header-brand__logo {
        width: 56px;
        height: 56px;
        flex-basis: 56px;
    }

    .isc-header-brand__divider {
        display: none;
    }

    .isc-header-brand__subtitle {
        display: none;
    }

    .isc-header-brand__name {
        max-width: 170px;
        overflow: hidden;
        font-size: 0.95rem;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .isc-header-tools {
        gap: 7px;
    }

    .isc-header-student-button {
        width: 44px;
        padding: 0;
    }

    .isc-header-student-button span {
        display: none;
    }

    .isc-header-language {
        display: none;
    }

    .isc-header-mobile-toggle {
        display: flex;
    }

    .isc-header-navigation {
        display: none;
    }

    .isc-site-header.is-sticky .isc-header-main,
    .isc-site-header.is-sticky .isc-header-main__inner {
        min-height: 68px;
    }

    .isc-site-header.is-sticky .isc-header-brand__logo {
        width: 50px;
        height: 50px;
        flex-basis: 50px;
    }
}


/* ---------------------------------------------------------
   21. RESPONSIVE — TÉLÉPHONES
   --------------------------------------------------------- */

@media (max-width: 520px) {
    .isc-header-main__inner {
        gap: 10px;
    }

    .isc-header-brand {
        max-width: calc(100% - 154px);
    }

    .isc-header-brand__name {
        max-width: 145px;
        font-size: 0.88rem;
    }

    .isc-header-tools {
        gap: 5px;
    }

    .isc-header-search-toggle,
    .isc-header-student-button,
    .isc-header-mobile-toggle {
        width: 40px;
        height: 40px;
        border-radius: 11px;
    }
}


/* ---------------------------------------------------------
   22. TRÈS PETITS ÉCRANS
   --------------------------------------------------------- */

@media (max-width: 370px) {
    .isc-header-brand {
        max-width: calc(100% - 138px);
    }

    .isc-header-brand__logo {
        width: 50px;
        height: 50px;
        flex-basis: 50px;
    }

    .isc-header-brand__name {
        max-width: 118px;
        font-size: 0.8rem;
    }

    .isc-header-search-toggle,
    .isc-header-student-button,
    .isc-header-mobile-toggle {
        width: 38px;
        height: 38px;
    }
}


/* ---------------------------------------------------------
   23. MOUVEMENT RÉDUIT
   --------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
    .isc-site-header *,
    .isc-site-header *::before,
    .isc-site-header *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
.isc-site-header a,
.isc-site-header a:hover,
.isc-site-header a:focus,
.isc-site-header a:active {
    text-decoration: none;
}