/* ---- Header (ECL EU theme) ---- */
.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 1rem;
    padding-right: 1rem;
}

/* Global banner (top bar) */
.header-top-bar {
    background: #eee;
    color: #000;
    font:
        normal normal 400 0.875rem/1.375rem Inter,
        Arial,
        sans-serif;
    padding: 0.15rem 1rem;
    position: relative;
}

.header-top-bar__text {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.header-top-bar__flag {
    flex-shrink: 0;
}

.header-top-bar__short {
    display: none;
}

.header-top-bar__btn {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    background: none;
    border: none;
    font: inherit;
    color: #0e47cb;
    cursor: pointer;
    padding: 0;
    margin-left: 0.75rem;
    text-decoration: underline;
}

.header-top-bar__btn:hover {
    color: #0b39a2;
}

.header-top-bar__arrow {
    transition: transform 0.2s ease;
}

.header-top-bar__btn[aria-expanded="true"] .header-top-bar__arrow {
    transform: rotate(180deg);
}

.header-top-bar__dropdown {
    position: absolute;
    left: 0;
    top: 100%;
    background: #fff;
    padding: 12px 16px;
    max-width: 500px;
    border: 1px solid #ccc;
    box-shadow: 0 4px 5px 0 rgba(0, 0, 0, 0.4);
    color: #444;
    font:
        normal normal 400 0.875rem/1.375rem Inter,
        Arial,
        sans-serif;
    z-index: 221;
}

.header-top-bar__dropdown p {
    margin: 0 0 0.25rem;
}

.header-top-bar__dropdown a {
    color: #0e47cb;
    text-decoration: underline;
}

@media (max-width: 995px) {
    .header-top-bar {
        display: flex;
        align-items: center;
    }

    .header-top-bar__long {
        display: none;
    }
    .header-top-bar__short {
        display: inline;
    }

    .header-top-bar__btn {
        margin-left: 0.75rem;
    }
}

/* Logo bar */
.header-logo-bar {
    background: #fff;
    padding: 1.4rem 0;
    border-bottom: 1px solid #cfdaf5;
}

.header-logo-bar > .header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: #171a22;
}

.header-logo__flag {
    flex-shrink: 0;
}

.header-logo__text {
    font:
        normal normal 700 1rem/1.25rem Arial,
        sans-serif;
    color: #171a22;
}

.header-logo-bar__right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.header-lang {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font:
        normal normal 400 1rem/1.5rem Arial,
        sans-serif;
    color: #171a22;
}

.header-lang__icon {
    flex-shrink: 0;
}

/* Mobile action buttons (hidden on desktop) */
.header-action-btn {
    display: none;
    align-items: center;
    justify-content: center;
    background: none;
    border: 1px solid transparent;
    border-radius: 4px;
    width: 2.75rem;
    height: 2.75rem;
    cursor: pointer;
    color: #171a22;
    padding: 0;
    position: relative;
    z-index: 54;
}

.header-action-btn:hover {
    border-color: #171a22;
}

.header-action-btn--menu[aria-expanded="true"] {
    background: #cfdaf5;
}

.header-action-btn__close {
    display: none;
}

/* When menu open, swap hamburger to X */
.header-action-btn--menu[aria-expanded="true"] .header-action-btn__open {
    display: none;
}

.header-action-btn--menu[aria-expanded="true"] .header-action-btn__close {
    display: block;
}

/* Nav overlay */
.header-nav__overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 200;
}

.header-nav__overlay.open {
    display: block;
}

/* Mobile menu header (hidden on desktop) */
.header-nav__mobile-header {
    display: none;
}

/* Site name */
.header-site-name {
    background: #fff;
    border-top: 1px solid #cfdaf5;
    padding: 0;
}

.header-site-name__link {
    font-size: 28px;
    font-weight: 400;
    font-family: Arial, sans-serif;
    line-height: 32px;
    color: #262b38;
    text-decoration: none;
    pointer-events: none;
    cursor: default;
    display: block;
    padding: 24px 0;
}

.header-site-name__link:hover {
    text-decoration: none;
}

/* Navigation — matches ECL .ecl-menu */
.header-nav {
    background: linear-gradient(90deg, #0b39a2, #0e47cb);
    position: relative;
    z-index: 50;
}

.header-nav__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 0;
}

.header-nav__item {
    position: relative;
    flex-shrink: 0;
}

.header-nav__list > li > a {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.75rem 0.5rem;
    font:
        normal normal 400 1rem/1.5rem Arial,
        sans-serif;
    color: #fff;
    text-decoration: none;
    white-space: nowrap;
    box-sizing: border-box;
}

.header-nav__list > li > a:hover {
    text-decoration: underline;
    color: #0b39a2;
    background: #fff;
}

/* Caret button — visible on desktop as separate tab stop */
.header-nav__caret {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    color: #fff;
    padding: 0.75rem 0.35rem;
    min-width: 24px;
    min-height: 24px;
}

.header-nav__caret:hover,
.header-nav__caret:focus-visible {
    background: rgba(255, 255, 255, 0.15);
}

.header-nav__caret:focus-visible {
    outline: 2px solid #fff;
    outline-offset: -2px;
}

.header-nav__list > li > a:focus-visible {
    outline: 2px solid #fff;
    outline-offset: -2px;
    background: transparent;
    color: #fff;
}

.header-nav__caret svg {
    width: 0.65em;
    height: 0.65em;
    fill: currentColor;
    stroke: none;
    transition: transform 0.2s ease;
}

.header-nav__item.open > .header-nav__caret svg {
    transform: rotate(180deg);
}

/* Chevron icon inside link — hidden on desktop, caret button replaces it */
.header-nav__chevron {
    display: none;
}

/* Active/current menu item — white tab */
.header-nav__active {
    background: #fff !important;
    color: #0e47cb !important;
    font-weight: 400;
    margin-bottom: -2px;
    padding-bottom: calc(0.75rem + 2px) !important;
    z-index: 16;
}

/* Dropdown mega panel — opens on hover */
.header-nav__mega {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 100%;
    background: #fff;
    border-radius: 0 0 4px 4px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    z-index: 15;
    padding: 2px 0 0;
}

.header-nav__item:hover > .header-nav__mega,
.header-nav__item.open > .header-nav__mega {
    display: flex;
    flex-direction: column;
}

.header-nav__sublist {
    list-style: none;
    margin: 0;
    padding: 0.5rem 0;
}

.header-nav__sublist--cols {
    columns: 2;
    column-gap: 0;
    min-width: 420px;
}

.header-nav__sublist--cols > li {
    break-inside: avoid;
}

.header-nav__sublist a {
    display: block;
    padding: 0.5rem 0.75rem;
    font:
        normal normal 400 1rem/1.5rem Arial,
        sans-serif;
    color: #0e47cb;
    text-decoration: none;
    white-space: normal;
    width: 210px;
}

.header-nav__sublist a:hover {
    color: #0b39a2;
    text-decoration: underline;
}

/* Hero banner */
/* ECL Page header */
.ecl-page-header {
    background: #f2f2f2;
    padding: 1.5rem 0 2rem;
}

.ecl-page-header__container {
    display: flex;
    flex-direction: column;
}

.ecl-page-header__title {
    font: normal normal 400 2rem/2.5rem Arial, sans-serif;
    color: #18234c;
    margin: 1rem 0 0;
}

.ecl-page-header__description-container {
    margin-top: 0.5rem;
}

.ecl-page-header__description {
    color: #4d5a6b;
    font: normal normal 400 1.125rem/1.625rem Arial, sans-serif;
    font-weight: 400;
    margin-block: 0;
    max-width: 80ch;
}

/* ECL Breadcrumb */
.ecl-breadcrumb {
    padding: 0;
}

.ecl-breadcrumb__container {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    font: normal normal 400 0.875rem/1.25rem Arial, sans-serif;
}

.ecl-breadcrumb__segment {
    display: inline-flex;
    align-items: center;
}

.ecl-breadcrumb__icon {
    width: 0.75rem;
    height: 0.75rem;
    margin: 0 0.5rem;
    color: #4d5a6b;
    transform: rotate(90deg);
    flex-shrink: 0;
}

.ecl-breadcrumb__link {
    color: #003399;
    text-decoration: none;
}

.ecl-breadcrumb__link:hover {
    text-decoration: underline;
}

.ecl-breadcrumb__current-page {
    color: #4d5a6b;
}

/* Hero banner */
.header-hero {
    background: #59c2ef url("assets/banner.jpg") center/cover no-repeat;
    aspect-ratio: 3840 / 348;
}

@media (max-width: 768px) {
    .header-hero {
        aspect-ratio: 495 / 205;
    }
}

/* ---- Responsive: below 996px (ECL 'l' breakpoint) ---- */
@media (max-width: 995px) {
    /* Hide desktop lang text, show mobile action icons */
    .header-lang--desktop {
        display: none;
    }

    .header-action-btn {
        display: flex;
    }

    .header-action-btn--search {
        display: none;
    }

    .header-logo-bar__right {
        gap: 0.25rem;
    }

    .header-logo__flag {
        height: 58px;
    }

    /* Site name on mobile — match ECL computed values */
    .header-site-name__link {
        font-size: 28px;
        line-height: 32px;
        padding: 24px 0;
    }

    /* Globan + logo bar stay above menu */
    .header-top-bar {
        position: relative;
        z-index: 221;
    }

    .header-logo-bar {
        position: relative;
        z-index: 220;
    }

    /* Nav: slide-in panel below header bars */
    .header-nav {
        position: fixed;
        top: var(--mobile-nav-top, 0);
        right: 0;
        bottom: 0;
        width: clamp(280px, 42vw, 380px);
        background: #fff;
        z-index: 210;
        overflow-y: auto;
        display: flex;
        flex-direction: column;
        transform: translateX(100%);
        transition: transform 375ms ease;
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
    }

    .header-nav.open {
        transform: translateX(0);
    }

    .header-nav > .header-container {
        max-width: none;
        padding: 0;
        margin: 0;
    }

    .header-nav__overlay {
        z-index: 209;
        top: var(--mobile-nav-top, 0);
    }

    /* Mobile menu header — blue gradient bar (sticky) */
    .header-nav__mobile-header {
        display: flex;
        align-items: center;
        flex-flow: row;
        padding: 0;
        height: 77px;
        background: linear-gradient(90deg, #0b39a2, #0e47cb);
        color: #fff;
        position: sticky;
        top: 0;
        z-index: 211;
        box-shadow:
            rgba(9, 49, 142, 0.08) 0px 2px 4px 0px,
            rgba(9, 49, 142, 0.04) 0px 0px 10px 0px,
            rgba(9, 49, 142, 0.04) 0px 4px 5px 0px,
            rgba(9, 49, 142, 0.04) 0px -4px 4px 0px;
    }

    .header-nav__mobile-title {
        font:
            normal normal 400 24px/28px Arial,
            sans-serif;
        color: #fff;
        padding-left: 16px;
    }

    .header-nav__mobile-close {
        display: none;
    }

    /* Menu list */
    .header-nav__list {
        flex-direction: column;
        padding: 0;
        flex-grow: 1;
        position: relative;
        z-index: 51;
    }

    .header-nav__item {
        width: 100%;
        display: flex;
        flex-wrap: wrap;
        border-bottom: 1px solid #e6e9ef;
    }

    .header-nav__list > li > a {
        color: #0e47cb;
        font-size: 20px;
        font-weight: 400;
        padding: 16px;
        flex-grow: 1;
        box-sizing: border-box;
        justify-content: space-between;
        white-space: normal;
        background: none;
    }

    .header-nav__list > li > a:hover {
        text-decoration: underline;
        background: none;
        color: #0e47cb;
    }

    /* Hide inline chevron on mobile — separate caret button handles it */
    .header-nav__list > li > a > .header-nav__chevron {
        display: none;
    }

    /* Caret button for items with children */
    .header-nav__item--has-caret > a {
        flex-grow: 1;
    }

    .header-nav__caret {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 44px;
        min-height: 60px;
        background: #e7edfa;
        border: 1px solid transparent;
        border-radius: 0;
        cursor: pointer;
        color: #0e47cb;
        padding: 5px 13px;
        margin-left: 2px;
        flex-shrink: 0;
    }

    .header-nav__caret:hover {
        background: #cfdaf5;
    }

    .header-nav__caret svg {
        width: 16px;
        height: 16px;
        stroke: none;
        fill: currentColor;
        transform: rotate(-90deg);
        transition: transform 0.3s ease-in-out;
    }

    .header-nav__item.open > .header-nav__caret svg {
        transform: rotate(0deg);
    }

    /* Current/active item — left blue bar */
    .header-nav__active {
        background: #e7edfa !important;
        color: #0e47cb !important;
        font-weight: 400;
        margin-bottom: 0;
        padding-bottom: 16px !important;
        box-shadow: inset 4px 0 0 0 #0e47cb;
    }

    /* Legacy chevron for items without separate caret */
    .header-nav__chevron {
        width: 0.75em;
        height: 0.75em;
        stroke: #0e47cb;
        transform: rotate(-90deg) !important;
    }

    .header-nav__item.open > a > .header-nav__chevron {
        transform: rotate(0deg) !important;
    }

    /* Dropdowns: accordion */
    .header-nav__mega {
        position: relative;
        box-shadow: none;
        border-radius: 0;
        background: transparent;
        padding: 0;
        width: 100%;
    }

    .header-nav__item:hover > .header-nav__mega {
        display: none;
    }

    .header-nav__item.open > .header-nav__mega {
        display: flex;
        flex-direction: column;
    }

    .header-nav__sublist {
        columns: 1 !important;
        min-width: 0 !important;
    }

    .header-nav__sublist a {
        color: #0e47cb;
        width: auto;
        padding: 0.5rem 1rem 0.5rem 2rem;
        font-size: 16px;
    }

    /* Sub-panel (slides over main list) */
    .header-nav__subpanel {
        display: none;
        position: absolute;
        top: 77px;
        left: 0;
        right: 0;
        bottom: 0;
        background: #fff;
        z-index: 212;
        overflow-y: auto;
        flex-direction: column;
    }

    .header-nav.subpanel-open .header-nav__subpanel {
        display: flex;
    }

    .header-nav.subpanel-open > .header-container {
        display: none;
    }

    .header-nav__subpanel-title {
        font:
            normal normal 400 20px/28px Arial,
            sans-serif;
        color: #0e47cb;
        padding: 16px;
        border-bottom: 1px solid #e6e9ef;
        font-weight: 600;
    }

    .header-nav__subpanel-list {
        list-style: none;
        margin: 0;
        padding: 0;
    }

    .header-nav__subpanel-list li {
        border-bottom: 1px solid #e6e9ef;
    }

    .header-nav__subpanel-list li:last-child {
        border-bottom: none;
    }

    .header-nav__subpanel-list a {
        display: block;
        font:
            normal normal 400 16px/24px Arial,
            sans-serif;
        color: #0e47cb;
        text-decoration: none;
        padding: 16px;
    }

    .header-nav__subpanel-list a:hover {
        text-decoration: underline;
    }

    .header-nav__subpanel-seeall {
        padding: 16px;
        margin-top: 3rem;
        border-top: 1px solid #e6e9ef;
    }

    .header-nav__subpanel-seeall a {
        display: inline-flex;
        align-items: center;
        gap: 0.4em;
        font:
            normal normal 400 16px/24px Arial,
            sans-serif;
        color: #0e47cb;
        text-decoration: none;
    }

    .header-nav__subpanel-seeall a:hover {
        text-decoration: underline;
    }

    .header-nav__seeall-arrow {
        width: 12px;
        height: 12px;
        transform: rotate(90deg);
    }

    /* Back button state for mobile title */
    .header-nav__mobile-title--back {
        cursor: pointer;
        display: inline-flex;
        align-items: center;
        gap: 0.4em;
    }

    .header-nav__mobile-title--back::before {
        content: "";
        display: inline-block;
        width: 0.65em;
        height: 0.65em;
        background: #fff;
        -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='m45 30.12-2.73 2.82-18.24-18.36L5.73 33 3 30.18 24.03 9z'/%3E%3C/svg%3E")
            no-repeat center/contain;
        mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='m45 30.12-2.73 2.82-18.24-18.36L5.73 33 3 30.18 24.03 9z'/%3E%3C/svg%3E")
            no-repeat center/contain;
        transform: rotate(-90deg);
    }

    /* ECL page header mobile */
    .ecl-page-header {
        padding: 1rem 0 1.25rem;
    }

    .ecl-page-header__title {
        font-size: 1.5rem;
        line-height: 2rem;
    }

    /* Breadcrumb mobile: show only last clickable link with back arrow */
    .ecl-breadcrumb__segment {
        display: none;
    }

    .ecl-breadcrumb__segment:nth-last-child(2) {
        display: inline-flex;
    }

    .ecl-breadcrumb__segment:nth-last-child(2) .ecl-breadcrumb__icon {
        display: none;
    }

    .ecl-breadcrumb__segment:nth-last-child(2)::before {
        content: "";
        display: inline-block;
        width: 0.75em;
        height: 0.75em;
        margin-right: 0.4rem;
        background: currentColor;
        -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='m45 30.12-2.73 2.82-18.24-18.36L5.73 33 3 30.18 24.03 9z'/%3E%3C/svg%3E")
            no-repeat center/contain;
        mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='m45 30.12-2.73 2.82-18.24-18.36L5.73 33 3 30.18 24.03 9z'/%3E%3C/svg%3E")
            no-repeat center/contain;
        transform: rotate(-90deg);
        color: #003399;
    }
}

/* ---- Focus indicators (ECL) ---- */
.header-top-bar__btn:focus-visible,
.header-action-btn:focus-visible,
.header-nav__caret:focus-visible,
.header-nav__list > li > a:focus-visible,
.header-nav__sublist a:focus-visible,
.ecl-breadcrumb__link:focus-visible,
.header-logo:focus-visible,
.header-site-name__link:focus-visible,
.header-nav__mobile-close:focus-visible,
.header-nav__subpanel-list a:focus-visible,
.header-nav__subpanel-seeall a:focus-visible,
.header-top-bar__dropdown a:focus-visible,
.footer-list a:focus-visible,
.footer-title-link:focus-visible,
.footer-social-link:focus-visible,
.footer-description a:focus-visible {
    outline: 2px solid #0e47cb;
    outline-offset: 2px;
}

/* ---- Footer (ECL EU theme) ---- */
.site-footer {
    background: #f3f6fc;
    color: #171a22;
    font:
        normal normal 400 1rem/1.5rem Arial,
        sans-serif;
    margin-top: var(--space-xl);
    box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.06);
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2.5rem 1rem;
}

.footer-row {
    border-bottom: 2px solid #cfdaf5;
    padding-bottom: 2rem;
    padding-top: 2rem;
}

.footer-row:first-child {
    padding-top: 0;
}

.footer-row:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.footer-col {
    padding-top: 1.5rem;
}

.footer-col:first-child {
    padding-top: 0;
}

.footer-title-link {
    font:
        normal normal 400 1.25rem/1.75rem Arial,
        sans-serif;
    color: #171a22;
    text-decoration: none;
    display: block;
    margin-bottom: 0;
}

.footer-title-link:hover {
    text-decoration: underline;
}

.footer-heading {
    font:
        normal normal 700 1rem/1.5rem Arial,
        sans-serif;
    color: #171a22;
    margin: 0;
    border-bottom: 1px solid #cfdaf5;
    padding-bottom: 0.75rem;
}

.footer-section {
    padding-top: 1.5rem;
}

.footer-section:first-child {
    padding-top: 0;
}

.footer-eu-logo {
    display: block;
    margin-bottom: 1rem;
}

.footer-description {
    color: #171a22;
    margin-top: 1rem;
    margin-bottom: 0.25rem;
}

.footer-description a {
    color: #0e47cb;
    text-decoration: underline;
}

.footer-list {
    list-style: none;
    padding: 0;
    margin: 0.75rem 0 0;
}

.footer-list li {
    line-height: 1.375rem;
    margin-top: 0.25rem;
}

.footer-list li:first-child {
    margin-top: 0;
}

.footer-list a {
    color: #0e47cb;
    text-decoration: none;
}

.footer-list a:hover {
    text-decoration: underline;
}

.footer-list--social li + li {
    margin-top: 0.25rem;
}

.footer-social-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
}

.footer-social-link svg {
    flex-shrink: 0;
}

@media (min-width: 996px) {
    .footer-container {
        padding: 3rem 1rem;
    }

    .footer-row {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        column-gap: 2rem;
        padding-bottom: 2.5rem;
        padding-top: 2.5rem;
    }

    .footer-col {
        padding-top: 0;
    }

    .footer-section {
        padding-top: 1.5rem;
    }
}

/* ---- Darker link colors for contrast ---- */
.header-top-bar__btn {
    color: #003399;
}

.header-top-bar__btn:hover {
    color: #002266;
}

.header-top-bar__dropdown a {
    color: #003399;
}

.header-nav__sublist a {
    color: #003399;
}

.header-nav__sublist a:hover {
    color: #002266;
}

.footer-list a {
    color: #003399;
}

.footer-description a {
    color: #003399;
}

/* ---- Prefers reduced motion (ECL) ---- */
@media (prefers-reduced-motion: reduce) {
    .header-top-bar__arrow {
        transition: none;
    }

    .header-nav {
        transition: none;
    }

    .header-nav__chevron {
        transition: none;
    }

    .header-nav__caret svg {
        transition: none;
    }
}
