/*
 * UPSEX — HOME REAL TABLET Y PC
 * Solo se aplica desde 768px.
 * No cambia el móvil ni el orden del HTML.
 */

@media screen and (min-width:768px){

    html,
    body.upsex-desktop-document-v1{
        width:100%;
        min-width:0;
        max-width:100%;
        margin:0;
        overflow-x:hidden;
    }
    body.upsex-desktop-document-v1 *,
    body.upsex-desktop-document-v1 *::before,
    body.upsex-desktop-document-v1 *::after{
        box-sizing:border-box;
    }

    body.upsex-desktop-document-v1 img,
    body.upsex-desktop-document-v1 video,
    body.upsex-desktop-document-v1 svg,
    body.upsex-desktop-document-v1 iframe{
        max-width:100%;
    }

    /* ========================================================
       HEADER REAL DE TABLET Y PC
       ======================================================== */

    #upsex-desktop-header-v1{
        position:relative;
        z-index:3000;
        display:block;

        width:100%;
        margin:0;

        background:#fffdf8;
        color:#392f2c;

        border-bottom:1px solid rgba(184,138,0,.22);

        box-shadow:
            0 10px 30px
            rgba(51,40,35,.09);
    }

    #upsex-desktop-header-v1 a{
        color:inherit;
        text-decoration:none;
    }

    #upsex-desktop-header-v1 .upsex-dh-top{
        width:100%;
        background:#302724;
        color:#fff;
    }

    #upsex-desktop-header-v1 .upsex-dh-top-inner{
        display:flex;
        align-items:center;
        justify-content:space-between;
        gap:20px;

        width:calc(100% - 48px);
        max-width:1320px;
        min-height:38px;

        margin:0 auto;
    }

    #upsex-desktop-header-v1 .upsex-dh-benefit{
        font-size:13px;
        font-weight:700;
        letter-spacing:.01em;
    }

    #upsex-desktop-header-v1 .upsex-dh-contact{
        display:flex;
        align-items:center;
        gap:18px;

        font-size:13px;
        font-weight:650;
    }

    #upsex-desktop-header-v1 .upsex-dh-main{
        display:grid;
        grid-template-columns:180px minmax(270px,1fr);
        align-items:center;
        gap:20px;

        width:calc(100% - 48px);
        max-width:1320px;

        margin:0 auto;
        padding:16px 0 13px;
    }

    #upsex-desktop-header-v1 .upsex-dh-logo{
        display:flex;
        align-items:center;

        width:100%;
        min-width:0;
        max-width:180px;
    }

    #upsex-desktop-header-v1 .upsex-dh-logo img{
        display:block;

        width:auto;
        max-width:100%;
        max-height:66px;

        object-fit:contain;
    }

    #upsex-desktop-header-v1 .upsex-dh-search{
        width:100%;
        min-width:0;
    }

    #upsex-desktop-header-v1 .upsex-dh-actions{
        grid-column:1 / -1;

        display:flex;
        align-items:center;
        justify-content:flex-end;
        gap:10px;

        min-width:0;
    }

    #upsex-desktop-header-v1 .upsex-dh-action{
        display:flex;
        align-items:center;
        justify-content:center;
        gap:8px;

        min-height:44px;
        padding:9px 13px;

        border:1px solid rgba(184,138,0,.26);
        border-radius:13px;

        background:#fff;
        color:#403633;

        font-size:13px;
        font-weight:750;

        transition:
            border-color .18s ease,
            background .18s ease,
            transform .18s ease;
    }

    #upsex-desktop-header-v1 .upsex-dh-action:hover{
        border-color:#b88a00;
        background:#fff9e9;
        transform:translateY(-1px);
    }

    #upsex-desktop-header-v1 .upsex-dh-action i{
        color:#b88a00;
        font-size:18px;
    }

    /* Buscador existente de OpenCart */

    #upsex-desktop-header-v1 .upsex-dh-search > *{
        width:100%;
        max-width:none;
        margin:0;
    }

    #upsex-desktop-header-v1 #search-by-category{
        position:relative;

        display:flex;
        align-items:stretch;

        width:100%;
        min-height:50px;
        margin:0;

        background:#fff;

        border:1px solid rgba(184,138,0,.34);
        border-radius:15px;

        box-shadow:
            0 7px 20px
            rgba(56,46,41,.06);

        overflow:visible;
    }

    #upsex-desktop-header-v1 #search-by-category .search-container,
    #upsex-desktop-header-v1 #search-by-category .search-content{
        width:100%;
        min-width:0;
        max-width:none;
        margin:0;
    }

    #upsex-desktop-header-v1 #search-by-category .search-container{
        display:flex;
        align-items:stretch;
    }

    #upsex-desktop-header-v1 #search-by-category input,
    #upsex-desktop-header-v1 #search-by-category input[type="text"],
    #upsex-desktop-header-v1 #text-search{
        flex:1 1 auto;

        width:100%;
        min-width:0;
        min-height:48px;

        margin:0;
        padding:0 16px;

        border:0;
        border-radius:15px 0 0 15px;
        outline:0;
        box-shadow:none;

        background:#fff;
        color:#392f2c;

        font-size:15px;
    }

    #upsex-desktop-header-v1 #sp-btn-search,
    #upsex-desktop-header-v1 #btn-search-category,
    #upsex-desktop-header-v1 .btn-search{
        flex:0 0 auto;

        display:flex;
        align-items:center;
        justify-content:center;

        min-width:58px;
        min-height:48px;
        margin:0;
        padding:0 17px;

        border:0;
        border-radius:0 14px 14px 0;

        background:#b88a00;
        color:#fff;

        cursor:pointer;
    }

    #upsex-desktop-header-v1 .search-button{
        display:none;
    }

    #upsex-desktop-header-v1 .search-ajax{
        position:absolute;
        top:calc(100% + 6px);
        right:0;
        left:0;
        z-index:4000;

        max-height:430px;
        overflow:auto;

        background:#fff;
        border-radius:14px;

        box-shadow:
            0 18px 42px
            rgba(45,35,31,.18);
    }

    /* Carrito existente */

    #upsex-desktop-header-v1 .upsex-dh-cart{
        min-width:0;
    }

    #upsex-desktop-header-v1 #cart{
        width:auto;
        min-width:0;
        margin:0;
    }

    #upsex-desktop-header-v1 #cart > button,
    #upsex-desktop-header-v1 #cart .btn{
        display:flex;
        align-items:center;
        justify-content:center;
        gap:8px;

        min-height:44px;
        margin:0;
        padding:9px 14px;

        border:1px solid rgba(184,138,0,.26);
        border-radius:13px;

        background:#fff;
        color:#403633;

        font-size:13px;
        font-weight:750;
    }

    #upsex-desktop-header-v1 #cart .dropdown-menu{
        right:0;
        left:auto;

        width:min(390px,calc(100vw - 40px));
        max-height:480px;
        overflow:auto;

        border:0;
        border-radius:15px;

        box-shadow:
            0 20px 45px
            rgba(45,35,31,.20);
    }

    /* Menú existente */

    #upsex-desktop-header-v1 .upsex-dh-navigation{
        width:100%;

        background:#fff;
        border-top:1px solid rgba(184,138,0,.12);
    }

    #upsex-desktop-header-v1 .upsex-dh-nav-inner{
        width:calc(100% - 48px);
        max-width:1320px;
        margin:0 auto;
    }

    #upsex-desktop-header-v1 .upsex-dh-nav-inner > *{
        width:100%;
        max-width:none;
        margin:0;
    }

    #upsex-desktop-header-v1 #menu,
    #upsex-desktop-header-v1 .navbar{
        min-height:0;
        margin:0;

        border:0;
        border-radius:0;

        background:transparent;
    }

    #upsex-desktop-header-v1 .navbar-header{
        display:none;
    }

    #upsex-desktop-header-v1 .navbar-collapse{
        display:block!important;
        height:auto!important;
        padding:0!important;
    }

    #upsex-desktop-header-v1 .navbar-nav,
    #upsex-desktop-header-v1 #menu > ul{
        display:flex;
        flex-wrap:nowrap;
        align-items:center;
        gap:2px;

        width:100%;
        margin:0;
        padding:0;

        overflow-x:auto;
        scrollbar-width:thin;
    }

    #upsex-desktop-header-v1 .navbar-nav > li,
    #upsex-desktop-header-v1 #menu > ul > li{
        float:none;
        flex:0 0 auto;
    }

    #upsex-desktop-header-v1 .navbar-nav > li > a,
    #upsex-desktop-header-v1 #menu > ul > li > a{
        display:flex;
        align-items:center;

        min-height:48px;
        padding:12px 14px;

        color:#403633;

        font-size:13px;
        font-weight:800;
        white-space:nowrap;
    }

    #upsex-desktop-header-v1 .navbar-nav > li > a:hover,
    #upsex-desktop-header-v1 #menu > ul > li > a:hover{
        background:#fff8e6;
        color:#8b6700;
    }

    #upsex-desktop-header-v1 .dropdown-menu{
        border:0;
        border-radius:12px;

        box-shadow:
            0 18px 42px
            rgba(45,35,31,.17);
    }
}

/* PC — SOLO HEADER CONSERVADO */
@media screen and (min-width:992px){
#upsex-desktop-header-v1 .upsex-dh-main{
        grid-template-columns:
            210px
            minmax(360px,1fr)
            auto;

        gap:24px;
        padding:17px 0;
    }

    #upsex-desktop-header-v1 .upsex-dh-logo{
        max-width:210px;
    }

    #upsex-desktop-header-v1 .upsex-dh-logo img{
        max-height:72px;
    }

    #upsex-desktop-header-v1 .upsex-dh-actions{
        grid-column:auto;
    }
}
