/* =========================================
   HEADER - LOGO LEFT / NAV CENTER / DRAWER RIGHT
========================================= */

.velo-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;

    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 32px;

    min-height: 88px;
    padding: 18px clamp(20px, 4vw, 64px);

    color: #07101f;
    background: transparent;

    transition:
        background 0.25s ease,
        box-shadow 0.25s ease,
        color 0.25s ease,
        backdrop-filter 0.25s ease,
        min-height 0.25s ease,
        padding 0.25s ease;
}

.velo-header.is-scrolled,
body:not(.home) .velo-header {
    min-height: 76px;
    color: var(--velo-ink, #07101f);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 14px 50px rgba(7, 17, 31, 0.09);
    backdrop-filter: blur(18px);
}

/* Hide old text brand if it still exists in header.php */
.velo-header__brand {
    display: none;
}

/* =========================================
   LEFT LOGO
========================================= */

.velo-header__logo {
    grid-column: 1;
    justify-self: start;

    display: flex;
    align-items: center;
    justify-content: flex-start;

    line-height: 0;
}

.velo-header__logo-link,
.velo-header__logo a {
    display: flex;
    align-items: center;
    justify-content: flex-start;

    line-height: 0;
    text-decoration: none;
}

.velo-header__logo img,
.velo-header__logo-img,
.velo-header__center-logo,
.velo-header .custom-logo {
    display: block;

    width: clamp(115px, 8vw, 155px);
    max-width: 155px;
    height: auto;
    max-height: 54px;

    object-fit: contain;

    filter:
        drop-shadow(0 1px 0 rgba(255, 255, 255, 0.85))
        drop-shadow(0 0 10px rgba(69, 217, 255, 0.14));
}

/* =========================================
   CENTER NAVIGATION
========================================= */

.velo-header__nav {
    grid-column: 2;
    justify-self: center;

    display: flex;
    align-items: center;
    justify-content: center;
}

.velo-header__menu,
.velo-header__menu ul {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(18px, 2vw, 36px);

    padding: 0;
    margin: 0;

    list-style: none;
}

.velo-header__menu li {
    padding: 0;
    margin: 0;
    list-style: none;
}

.velo-header__menu a {
    position: relative;

    display: inline-flex;
    align-items: center;

    font-family: "Jura", Arial, sans-serif;
    font-size: clamp(0.98rem, 1.02vw, 1.15rem);
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-decoration: none;

    color: inherit;

    transition:
        color 0.25s ease,
        text-shadow 0.25s ease;
}

.velo-header__menu a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -8px;

    width: 100%;
    height: 2px;

    background: linear-gradient(
        90deg,
        rgba(0, 124, 255, 0),
        rgba(0, 184, 245, 1),
        rgba(0, 124, 255, 0)
    );

    opacity: 0;
    transform: scaleX(0.4);

    transition:
        opacity 0.25s ease,
        transform 0.25s ease;
}

.velo-header__menu a:hover,
.velo-header__menu a:focus-visible {
    color: #008fe8;
    text-shadow: 0 0 18px rgba(69, 217, 255, 0.24);
}

.velo-header__menu a:hover::after,
.velo-header__menu a:focus-visible::after {
    opacity: 1;
    transform: scaleX(1);
}

/* =========================================
   RIGHT HAMBURGER
========================================= */

.velo-menu-toggle {
    grid-column: 3;
    justify-self: end;

    display: grid;
    place-content: center;
    gap: 6px;

    width: 50px;
    height: 50px;
    padding: 0;

    border: 1px solid rgba(7, 16, 31, 0.28);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    color: inherit;

    cursor: pointer;
    backdrop-filter: blur(10px);

    transition:
        background 0.25s ease,
        border-color 0.25s ease,
        box-shadow 0.25s ease,
        transform 0.25s ease;
}

.velo-menu-toggle:hover,
.velo-menu-toggle:focus-visible {
    transform: translateY(-1px);
    background: rgba(255, 255, 255, 0.42);
    border-color: rgba(0, 184, 245, 0.65);
    box-shadow: 0 0 22px rgba(69, 217, 255, 0.22);
}

.velo-menu-toggle span {
    display: block;

    width: 20px;
    height: 2px;

    background: currentColor;
    border-radius: 999px;
}

/* =========================================
   CLIENT STYLE OPTIONS
========================================= */

/* Default: nav + hamburger */
.velo-header--hybrid .velo-header__nav {
    display: flex;
}

.velo-header--hybrid .velo-menu-toggle {
    display: grid;
}

/* Nav only: hide hamburger */
.velo-header--nav-only .velo-header__nav {
    display: flex;
}

.velo-header--nav-only .velo-menu-toggle {
    display: none;
}

/* Drawer only: hide center nav */
.velo-header--drawer-only .velo-header__nav {
    display: none;
}

.velo-header--drawer-only .velo-menu-toggle {
    display: grid;
}

/* =========================================
   DRAWER - HIDDEN UNTIL OPEN
========================================= */

.velo-drawer {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 120;

    width: min(430px, 88vw);
    height: 100vh;
    min-height: 100dvh;

    padding: 34px 34px 42px;

    color: #07101f;
    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.96),
            rgba(241, 249, 255, 0.94)
        );

    box-shadow: -30px 0 80px rgba(7, 17, 31, 0.18);
    backdrop-filter: blur(22px);

    transform: translateX(105%);
    visibility: hidden;
    pointer-events: none;

    transition:
        transform 0.32s ease,
        visibility 0.32s ease;
}

.velo-drawer.is-open,
body.velo-menu-open .velo-drawer {
    transform: translateX(0);
    visibility: visible;
    pointer-events: auto;
}

/* Drawer backdrop */
.velo-drawer-backdrop {
    position: fixed;
    inset: 0;
    z-index: 110;

    background: rgba(7, 17, 31, 0.36);

    opacity: 0;
    visibility: hidden;
    pointer-events: none;

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease;
}

body.velo-menu-open .velo-drawer-backdrop {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* Drawer close button */
.velo-drawer__close {
    margin-left: auto;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 70px;
    min-height: 38px;
    padding: 8px 14px;

    border: 1px solid rgba(7, 16, 31, 0.16);
    background: rgba(255, 255, 255, 0.65);
    color: #07101f;

    font-family: "Jura", Arial, sans-serif;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;

    cursor: pointer;

    transition:
        background 0.25s ease,
        border-color 0.25s ease,
        color 0.25s ease,
        box-shadow 0.25s ease;
}

.velo-drawer__close:hover,
.velo-drawer__close:focus-visible {
    background: #07101f;
    border-color: #07101f;
    color: #ffffff;
    box-shadow: 0 0 22px rgba(69, 217, 255, 0.22);
}

/* Drawer nav */
.velo-drawer__nav {
    margin-top: 60px;
}

.velo-drawer__menu,
.velo-drawer__menu ul {
    display: grid;
    gap: 0;

    padding: 0;
    margin: 0;

    list-style: none;
}

.velo-drawer__menu li {
    padding: 0;
    margin: 0;
    list-style: none;
}

.velo-drawer__menu a {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 18px 0;

    border-bottom: 1px solid rgba(7, 16, 31, 0.12);

    font-family: "Jura", Arial, sans-serif;
    font-size: clamp(1.55rem, 4vw, 2.65rem);
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    text-decoration: none;

    color: #07101f;

    transition:
        color 0.25s ease,
        padding-left 0.25s ease,
        text-shadow 0.25s ease;
}

.velo-drawer__menu a::after {
    content: "→";

    font-size: 0.9rem;
    opacity: 0.45;

    transition:
        transform 0.25s ease,
        opacity 0.25s ease;
}

.velo-drawer__menu a:hover,
.velo-drawer__menu a:focus-visible {
    padding-left: 10px;
    color: #008fe8;
    text-shadow: 0 0 18px rgba(69, 217, 255, 0.22);
}

.velo-drawer__menu a:hover::after,
.velo-drawer__menu a:focus-visible::after {
    opacity: 1;
    transform: translateX(4px);
}

/* Prevent page scroll when drawer is open */
body.velo-menu-open {
    overflow: hidden;
}

/* =========================================
   TABLET
========================================= */

@media (max-width: 1100px) {
    .velo-header {
        gap: 24px;
    }

    .velo-header__menu {
        gap: 18px;
    }

    .velo-header__menu a {
        font-size: 0.76rem;
        letter-spacing: 0.09em;
    }
}

/* =========================================
   MOBILE
========================================= */

@media (max-width: 820px) {
    .velo-header {
        min-height: 74px;
        padding: 14px 18px;
        grid-template-columns: auto 1fr auto;
    }

    .velo-header.is-scrolled,
    body:not(.home) .velo-header {
        min-height: 68px;
    }

    /* Force hide center nav on mobile, even when header is hybrid */
    .velo-header .velo-header__nav,
    .velo-header--hybrid .velo-header__nav,
    .velo-header--nav-only .velo-header__nav,
    .velo-header--drawer-only .velo-header__nav {
        display: none !important;
    }

    /* Force hamburger to show on mobile */
    .velo-header .velo-menu-toggle,
    .velo-header--hybrid .velo-menu-toggle,
    .velo-header--drawer-only .velo-menu-toggle {
        display: grid !important;
    }

    .velo-header__logo img,
    .velo-header__logo-img,
    .velo-header__center-logo,
    .velo-header .custom-logo {
        width: clamp(100px, 32vw, 125px);
        max-width: 125px;
        max-height: 48px;
    }

    .velo-menu-toggle {
        width: 44px;
        height: 44px;
    }

    .velo-menu-toggle span {
        width: 18px;
    }

    .velo-drawer {
        width: min(380px, 90vw);
        padding: 28px;
    }

    .velo-drawer__nav {
        margin-top: 52px;
    }

    .velo-drawer__menu a {
        font-size: clamp(1.35rem, 7vw, 2.15rem);
    }
}