/* =========================================================
   MYOTEC PREMIUM HEADER V1.2
   ========================================================= */

:root {
    --myotec-blue: #00c8ff;
    --myotec-blue-2: #00aeea;
    --myotec-black: #000000;
    --myotec-white: #ffffff;
}

/* Masque l'ancien header Elementor / thème */
header.elementor-location-header,
.site-header,
#masthead {
    display: none !important;
}

html,
body {
    max-width: 100%;
    overflow-x: hidden;
}

/* Header */
.myotec-premium-header {
    position: fixed;
    inset: 0 0 auto 0;
    width: 100%;
    z-index: 99990;
    background: transparent;
    isolation: isolate;
    transition:
        background-color 0.32s ease,
        box-shadow 0.32s ease,
        border-color 0.32s ease,
        backdrop-filter 0.32s ease;
}

/* Dégradé haut de page */
.myotec-premium-header::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -2;
    pointer-events: none;
    background:
        linear-gradient(
            180deg,
            rgba(0, 0, 0, 0.86) 0%,
            rgba(0, 0, 0, 0.46) 58%,
            rgba(0, 0, 0, 0) 100%
        );
    opacity: 1;
    transition: opacity 0.32s ease;
}

/* Ligne premium au scroll */
.myotec-premium-header::after {
    content: "";
    position: absolute;
    left: clamp(18px, 5vw, 92px);
    right: clamp(18px, 5vw, 92px);
    bottom: 0;
    height: 1px;
    pointer-events: none;
    background:
        linear-gradient(
            90deg,
            transparent,
            rgba(0, 200, 255, 0.4),
            rgba(255, 255, 255, 0.16),
            rgba(0, 200, 255, 0.4),
            transparent
        );
    opacity: 0;
    transition: opacity 0.32s ease;
}

.myotec-premium-header.is-scrolled,
.myotec-premium-header--solid {
    background:
        radial-gradient(circle at 50% 0%, rgba(0, 200, 255, 0.11), transparent 36%),
        rgba(0, 0, 0, 0.82);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.42);
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
}

.myotec-premium-header.is-scrolled::before,
.myotec-premium-header--solid::before {
    opacity: 0;
}

.myotec-premium-header.is-scrolled::after,
.myotec-premium-header--solid::after {
    opacity: 1;
}

/* Barre interne */
.myotec-premium-header__bar {
    position: relative;
    z-index: 6;
    width: min(100%, 1580px);
    margin: 0 auto;
    padding: 22px clamp(28px, 5.6vw, 92px);
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: clamp(24px, 3vw, 54px);
    transition: padding 0.32s ease;
}

.myotec-premium-header.is-scrolled .myotec-premium-header__bar,
.myotec-premium-header--solid .myotec-premium-header__bar {
    padding-top: 12px;
    padding-bottom: 12px;
}

/* Logo */
.myotec-premium-header__logo {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    text-decoration: none;
}

.myotec-premium-header__logo img {
    display: block;
    width: clamp(118px, 9vw, 154px);
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 9px 20px rgba(0, 0, 0, 0.42));
}

/* Navigation desktop */
.myotec-premium-header__nav {
    display: flex;
    justify-content: center;
    align-items: center;
    min-width: 0;
}

.myotec-premium-header__menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(22px, 2.05vw, 40px);
}

.myotec-premium-header__menu li {
    position: relative;
    margin: 0;
    padding: 0;
}

.myotec-premium-header__menu a {
    position: relative;
    display: inline-flex;
    align-items: center;
    padding: 14px 0;
    font-family: "Agrandir", "Montserrat", Arial, sans-serif;
    font-size: 12.5px;
    font-weight: 950;
    line-height: 1;
    letter-spacing: 1.35px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.94);
    text-decoration: none;
    white-space: nowrap;
    transition:
        color 0.22s ease,
        text-shadow 0.22s ease,
        transform 0.22s ease;
}

.myotec-premium-header__menu a::before {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 2px;
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: var(--myotec-blue);
    box-shadow: 0 0 18px rgba(0, 200, 255, 0.75);
    transform: translateX(-50%) scale(0);
    opacity: 0;
    transition:
        opacity 0.22s ease,
        transform 0.22s ease;
}

.myotec-premium-header__menu a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--myotec-blue), transparent);
    transform: scaleX(0);
    transform-origin: center;
    opacity: 0;
    transition:
        transform 0.24s ease,
        opacity 0.24s ease;
}

.myotec-premium-header__menu a:hover,
.myotec-premium-header__menu .current-menu-item > a,
.myotec-premium-header__menu .current_page_item > a,
.myotec-premium-header__menu .current-menu-ancestor > a {
    color: var(--myotec-blue);
    text-shadow: 0 0 18px rgba(0, 200, 255, 0.32);
    transform: translateY(-1px);
}

.myotec-premium-header__menu a:hover::before,
.myotec-premium-header__menu .current-menu-item > a::before,
.myotec-premium-header__menu .current_page_item > a::before,
.myotec-premium-header__menu .current-menu-ancestor > a::before {
    opacity: 1;
    transform: translateX(-50%) scale(1);
}

.myotec-premium-header__menu a:hover::after,
.myotec-premium-header__menu .current-menu-item > a::after,
.myotec-premium-header__menu .current_page_item > a::after,
.myotec-premium-header__menu .current-menu-ancestor > a::after {
    transform: scaleX(1);
    opacity: 1;
}

/* Sous-menu desktop */
.myotec-premium-header__menu .sub-menu {
    position: absolute;
    top: calc(100% + 12px);
    left: 50%;
    width: max-content;
    min-width: 230px;
    list-style: none;
    margin: 0;
    padding: 12px;
    border-radius: 18px;
    background:
        radial-gradient(circle at 50% 0%, rgba(0, 200, 255, 0.12), transparent 34%),
        rgba(5, 5, 5, 0.94);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.48);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    transform: translateX(-50%) translateY(12px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition:
        transform 0.22s ease,
        opacity 0.22s ease,
        visibility 0.22s ease;
}

.myotec-premium-header__menu li:hover > .sub-menu,
.myotec-premium-header__menu li:focus-within > .sub-menu {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.myotec-premium-header__menu .sub-menu a {
    width: 100%;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 12px;
    letter-spacing: 1px;
    transform: none;
}

.myotec-premium-header__menu .sub-menu a:hover {
    background: rgba(0, 200, 255, 0.1);
}

.myotec-premium-header__menu .sub-menu a::before,
.myotec-premium-header__menu .sub-menu a::after {
    display: none;
}

/* Actions */
.myotec-premium-header__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
}

.myotec-premium-header__phone,
.myotec-premium-header__cta,
.myotec-premium-header__burger {
    appearance: none !important;
    -webkit-appearance: none !important;
    font-family: "Agrandir", "Montserrat", Arial, sans-serif;
    box-shadow: none !important;
    outline: none !important;
}

/* Bouton téléphone */
.myotec-premium-header__phone {
    width: 54px;
    height: 54px;
    padding: 0 !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 2px solid rgba(255, 255, 255, 0.86) !important;
    background:
        radial-gradient(circle at 30% 20%, rgba(0, 200, 255, 0.18), rgba(0, 200, 255, 0) 46%),
        rgba(0, 0, 0, 0.18) !important;
    color: #ffffff !important;
    text-decoration: none !important;
    cursor: pointer;
    transition:
        transform 0.22s ease,
        background 0.22s ease,
        border-color 0.22s ease,
        color 0.22s ease,
        box-shadow 0.22s ease;
}

.myotec-premium-header__phone svg {
    width: 26px;
    height: 26px;
    fill: currentColor;
}

.myotec-premium-header__phone:hover,
.myotec-premium-header__phone:focus,
.myotec-premium-header__phone:active {
    color: #ffffff !important;
    background:
        radial-gradient(circle at 50% 35%, rgba(0, 200, 255, 0.42), rgba(0, 200, 255, 0.06) 54%),
        rgba(0, 191, 243, 0.16) !important;
    border-color: var(--myotec-blue) !important;
    box-shadow:
        0 0 0 4px rgba(0, 200, 255, 0.08),
        0 0 28px rgba(0, 200, 255, 0.28) !important;
    transform: translateY(-1px);
}

/* Bouton contact */
.myotec-premium-header__cta {
    min-width: 132px;
    height: 54px;
    padding: 0 30px !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 2px solid rgba(255, 255, 255, 0.86) !important;
    background: rgba(0, 0, 0, 0.16) !important;
    color: #ffffff !important;
    font-size: 12.5px;
    font-weight: 950;
    letter-spacing: 1.55px;
    line-height: 1;
    text-transform: uppercase;
    text-decoration: none !important;
    cursor: pointer;
    transition:
        transform 0.22s ease,
        background 0.22s ease,
        border-color 0.22s ease,
        color 0.22s ease,
        box-shadow 0.22s ease;
}

.myotec-premium-header__cta:hover,
.myotec-premium-header__cta:focus,
.myotec-premium-header__cta:active {
    color: #000000 !important;
    background: var(--myotec-blue) !important;
    border-color: var(--myotec-blue) !important;
    transform: translateY(-1px);
    box-shadow:
        0 0 0 4px rgba(0, 200, 255, 0.1),
        0 14px 34px rgba(0, 200, 255, 0.22) !important;
}

/* Burger */
.myotec-premium-header__burger {
    display: none;
    width: 50px;
    height: 50px;
    padding: 0 !important;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.58) !important;
    background: rgba(0, 0, 0, 0.18) !important;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.myotec-premium-header__burger:hover,
.myotec-premium-header__burger:focus,
.myotec-premium-header__burger:active {
    background: rgba(0, 191, 243, 0.14) !important;
    border-color: rgba(0, 200, 255, 0.9) !important;
}

.myotec-premium-header__burger span {
    display: block;
    width: 21px;
    height: 2px;
    border-radius: 999px;
    background: #ffffff;
    transition:
        transform 0.25s ease,
        opacity 0.25s ease;
}

.myotec-premium-header.is-menu-open .myotec-premium-header__burger span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.myotec-premium-header.is-menu-open .myotec-premium-header__burger span:nth-child(2) {
    opacity: 0;
}

.myotec-premium-header.is-menu-open .myotec-premium-header__burger span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Mobile panel */
.myotec-premium-header__mobile-panel {
    position: fixed;
    inset: 0;
    z-index: 99995;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background:
        radial-gradient(circle at 18% 0%, rgba(0, 200, 255, 0.24), transparent 34%),
        radial-gradient(circle at 100% 100%, rgba(0, 200, 255, 0.12), transparent 34%),
        linear-gradient(145deg, rgba(0, 0, 0, 0.94), rgba(7, 7, 7, 0.96));
    backdrop-filter: blur(20px) saturate(135%);
    -webkit-backdrop-filter: blur(20px) saturate(135%);
    transform: translateX(100%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition:
        transform 0.34s ease,
        opacity 0.34s ease,
        visibility 0.34s ease;
}

.myotec-premium-header.is-menu-open .myotec-premium-header__mobile-panel {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.myotec-premium-header__mobile-inner {
    height: 100%;
    padding: 96px 24px 28px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.myotec-premium-header__mobile-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
}

.myotec-premium-header__mobile-head span {
    display: block;
    color: var(--myotec-blue);
    font-family: "Agrandir", "Montserrat", Arial, sans-serif;
    font-size: 11px;
    font-weight: 950;
    letter-spacing: 2.8px;
    text-transform: uppercase;
}

.myotec-premium-header__mobile-head strong {
    display: block;
    margin-top: 5px;
    color: #ffffff;
    font-family: "Agrandir", "Montserrat", Arial, sans-serif;
    font-size: 28px;
    font-weight: 950;
    letter-spacing: -0.7px;
    line-height: 1;
}

.myotec-premium-header__mobile-close {
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255, 255, 255, 0.22) !important;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04) !important;
    position: relative;
    cursor: pointer;
}

.myotec-premium-header__mobile-close span {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 18px;
    height: 2px;
    background: #ffffff;
    border-radius: 999px;
}

.myotec-premium-header__mobile-close span:first-child {
    transform: translate(-50%, -50%) rotate(45deg);
}

.myotec-premium-header__mobile-close span:last-child {
    transform: translate(-50%, -50%) rotate(-45deg);
}

.myotec-premium-header__mobile-menu {
    list-style: none;
    margin: 0;
    padding: 0;
}

.myotec-premium-header__mobile-menu li {
    margin: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.11);
}

.myotec-premium-header__mobile-menu a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 19px 0;
    color: #ffffff;
    font-family: "Agrandir", "Montserrat", Arial, sans-serif;
    font-size: clamp(22px, 7vw, 36px);
    font-weight: 950;
    line-height: 1.05;
    letter-spacing: -0.6px;
    text-decoration: none;
    text-transform: uppercase;
}

.myotec-premium-header__mobile-menu a::after {
    content: "→";
    color: var(--myotec-blue);
    font-size: 20px;
    transform: translateX(-4px);
    opacity: 0.78;
}

.myotec-premium-header__mobile-menu .current-menu-item > a,
.myotec-premium-header__mobile-menu .current_page_item > a,
.myotec-premium-header__mobile-menu .current-menu-ancestor > a {
    color: var(--myotec-blue);
}

.myotec-premium-header__mobile-menu .sub-menu {
    list-style: none;
    margin: -4px 0 12px;
    padding: 0 0 0 18px;
}

.myotec-premium-header__mobile-menu .sub-menu li {
    border-bottom: 0;
}

.myotec-premium-header__mobile-menu .sub-menu a {
    padding: 10px 0;
    font-size: 15px;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.72);
}

.myotec-premium-header__mobile-menu .sub-menu a::after {
    display: none;
}

.myotec-premium-header__mobile-bottom {
    margin-top: auto;
    padding-top: 30px;
}

.myotec-premium-header__mobile-bottom p {
    margin: 0 0 16px;
    max-width: 310px;
    color: rgba(255, 255, 255, 0.72);
    font-family: "Montserrat", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.5;
}

.myotec-premium-header__mobile-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.myotec-premium-header__mobile-actions a {
    width: 100%;
    height: 56px;
    border-radius: 999px;
    font-family: "Agrandir", "Montserrat", Arial, sans-serif;
    font-size: 12px;
    font-weight: 950;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.myotec-premium-header__mobile-actions a:first-child {
    border: 0 !important;
    background: var(--myotec-blue) !important;
    color: #000000 !important;
}

.myotec-premium-header__mobile-actions a:last-child {
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    background: transparent !important;
    color: #ffffff !important;
}

/* Body lock */
body.myotec-menu-open {
    overflow: hidden !important;
    touch-action: none;
}

/* Responsive */
@media (max-width: 1280px) {
    .myotec-premium-header__bar {
        padding-left: 36px;
        padding-right: 36px;
        gap: 24px;
    }

    .myotec-premium-header__menu {
        gap: 22px;
    }

    .myotec-premium-header__menu a {
        font-size: 11.5px;
        letter-spacing: 1.1px;
    }

    .myotec-premium-header__cta {
        min-width: 118px;
        padding: 0 24px !important;
    }
}

@media (max-width: 1080px) {
    .myotec-premium-header {
        background: transparent;
    }

    .myotec-premium-header__nav {
        display: none;
    }

    .myotec-premium-header__bar {
        grid-template-columns: auto auto;
        justify-content: space-between;
        padding: 16px 22px;
    }

    .myotec-premium-header.is-scrolled,
    .myotec-premium-header--solid,
    .myotec-premium-header.is-menu-open {
        background:
            radial-gradient(circle at 50% 0%, rgba(0, 200, 255, 0.1), transparent 34%),
            rgba(0, 0, 0, 0.82);
        backdrop-filter: blur(18px) saturate(135%);
        -webkit-backdrop-filter: blur(18px) saturate(135%);
    }

    .myotec-premium-header__burger {
        display: inline-flex;
    }

    .myotec-premium-header__cta {
        display: none;
    }

    .myotec-premium-header__phone {
        width: 48px;
        height: 48px;
    }

    .myotec-premium-header__phone svg {
        width: 23px;
        height: 23px;
    }
}

@media (max-width: 560px) {
    .myotec-premium-header__logo img {
        width: 112px;
    }

    .myotec-premium-header__bar {
        padding-left: 18px;
        padding-right: 18px;
    }

    .myotec-premium-header__actions {
        gap: 9px;
    }

    .myotec-premium-header__phone,
    .myotec-premium-header__burger {
        width: 44px;
        height: 44px;
    }

    .myotec-premium-header__mobile-inner {
        padding-left: 20px;
        padding-right: 20px;
    }
}