* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: #ffffff;
    text-align: center;
}

h1 {
    margin-top: 30px;
    font-size: 3rem;
    font-weight: 700;
    color: #000;
}

a {
    text-decoration: none;
}

/*============== Home ==============*/
.container {
    position: absolute;
    z-index: 128;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: url(/image/bg-simulador.jpg) no-repeat center;
    background-size: cover;
    user-select: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-wrap: nowrap;
    justify-content: center;
}

.content-logo-principal {
    position: absolute;
    left: 50px;
    top: 25px;
}

.logo-principal {
    width: 310px;
}

.content-logo {
    position: absolute;
    top: 40px;
    left: 0;
    right: 0;
}

.content-title {
    margin-bottom: 3rem;
    max-width: 1000px;
    width: 700px;
    background-color: #000;
    opacity: 92%;
    padding: 1.5rem 2.5rem;
}

.content-title h1 {
    margin-top: 0px;
    line-height: 50px;
    color: #fff;
    font-size: 2.5rem;
    font-style: italic;
    -webkit-text-stroke: 1px black;
}

.content-logo img {
    width: 420px;
}

.btn-simulador {
    position: relative;
    border: none;
    background: transparent;
    padding: 0;
    cursor: pointer;
    outline-offset: 4px;
    transition: filter 250ms;
    user-select: none;
    touch-action: manipulation;
}

.shadow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 12px;
    background: hsl(0deg 0% 0% / 0.25);
    will-change: transform;
    transform: translateY(2px);
    transition: transform 600ms cubic-bezier(.3, .7, .4, 1);
}

.edge {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 12px;
    background: linear-gradient(to left,
            hsl(340deg 100% 16%) 0%,
            hsl(340deg 100% 32%) 8%,
            hsl(340deg 100% 32%) 92%,
            hsl(340deg 100% 16%) 100%);
}

.front {
    display: block;
    position: relative;
    padding: 20px 50px;
    border-radius: 12px;
    font-size: 1.4rem;
    color: white;
    background: hsl(345deg 100% 47%);
    will-change: transform;
    transform: translateY(-4px);
    transition: transform 600ms cubic-bezier(.3, .7, .4, 1);
}

.btn-simulador:hover {
    filter: brightness(110%);
}

.btn-simulador:hover .front {
    transform: translateY(-6px);
    transition: transform 250ms cubic-bezier(.3, .7, .4, 1.5);
}

.btn-simulador:active .front {
    transform: translateY(-2px);
    transition: transform 34ms;
}

.btn-simulador:hover .shadow {
    transform: translateY(4px);
    transition: transform 250ms cubic-bezier(.3, .7, .4, 1.5);
}

.btn-simulador:active .shadow {
    transform: translateY(1px);
    transition: transform 34ms;
}

.btn-simulador:focus:not(:focus-visible) {
    outline: none;
}

.subcontent-name {
    color: #fff !important;
}

/*============== CONTENEDOR AUTO ==============*/
.bg-fondo {
    background: url(/image/bg-studio.jpg);
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    z-index: 1;
    left: 0;
    top: 0;
    background-color: #fff;
    background-position: 50% 50%;

}

.car-container {
    position: relative;
    display: inline-block;
    margin-top: 20px;
}

.car-container img {
    width: 100%;
    max-width: 1100px;
    transition: opacity 0.3s ease;
}

.car-color-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    max-width: 1100px;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.car-color-overlay[src=""],
.car-wheel-overlay[src=""],
.car-tire-overlay[src=""],
.car-color-overlay:not([src]),
.car-wheel-overlay:not([src]), 
.car-tire-overlay:not([src]) {
    display: none;
}

.car-color-overlay,
.car-tire-overlay,
.car-wheel-overlay {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    object-fit: contain;
    transition: opacity 0.4s ease;
    opacity: 0;
    pointer-events: none;
}

.car-color-overlay.active,
.car-wheel-overlay.active {
    opacity: 1;
    z-index: 2;
}

.car-color-overlay.next {
    z-index: 3;
}

.car-tire-overlay.active {
    opacity: 1;
    z-index: 2;
}

.car-wheel-overlay.active {
    opacity: 1;
    z-index: 3; /*Aros encima de llantas*/
}

.car-tire-overlay.next {
    z-index: 4;
}

.car-wheel-overlay.next {
    z-index: 5;
}


/*
Header dinamico de Selección de aros
*/
.aro-info-container {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-bottom: 20px;
}

.aro-info {
    background-color: #fff;
    padding: 12px 20px;
    font-weight: 600;
    border-radius: 10px;
    font-size: 14px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    text-align: center;
    border: 2px solid #e30613;
    color: #333;
    max-width: 400px;
    width: auto;
    margin: 0 auto 20px auto;
    line-height: 1.4;
}

/* MENÚS */
.menus-container {
    position: relative;
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    height: auto;
    min-height: 200px;
}

.menu-principal,
.menu-secundario {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    justify-content: center;
    gap: 2.5rem;
    flex-wrap: wrap;
    transition: opacity 0.4s ease, transform 0.4s ease, visibility 0.4s ease;
}

/* MENÚ PRINCIPAL */
.menu-principal {
    display: flex;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    z-index: 20;
    pointer-events: auto;
}

.menu-principal.oculto {
    opacity: 0;
    transform: translateY(-20px);
    visibility: hidden;
    pointer-events: none;
}

/* MENÚ SECUNDARIO */
.menu-secundario {
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    z-index: 3;
}

.menu-secundario.activo {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

/* CONTENIDO SECUNDARIO EN GRID */
#contenidoSecundario {
    display: flex;
    flex-direction: row;
    gap: 20px;
    justify-content: center;
    align-items: start;
    padding: 15px 50px;
    margin-top: 0;
    transition: all 0.3s ease;
}

/* === Swiper === */
.swiper {
    width: 90%;
    padding: 20px 0;
    position: relative;
}

.swiper-wrapper {
    display: flex;
    transition-timing-function: ease-out;
}

.swiper-slide {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s;
    flex-shrink: 0;
}

.swiper-slide img {
    width: 130px;
    height: 130px;                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          
    object-fit: contain;

}

.swiper-button-next,
.swiper-button-prev {
    color: #e30613 !important;
    width: 38px;
    /* tamaño del círculo */
    height: 38px;
    border: 2px solid #e30613;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.85);
    box-shadow: 0 0 8px rgba(227, 6, 19, 0.4);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;    
}

/* --- Ajuste del tamaño del icono SVG --- */
.swiper-button-next svg,
.swiper-button-prev svg {
    width: 16px !important;
    /* antes 20px */
    height: 16px !important;
    stroke-width: 3px;
    /* hace que la flecha sea más gruesa */
    color: #e30613;
}

/* --- Efecto hover --- */
.swiper-button-next:hover,
.swiper-button-prev:hover {
    background: #e30613;
    color: white !important;
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(227, 6, 19, 0.6);
}

/* --- Cambiar color del ícono SVG al pasar el mouse --- */
.swiper-button-next:hover svg,
.swiper-button-prev:hover svg {
    color: #fff;
    fill: #fff;
}

/* --- Posicionamiento --- */
.swiper-button-next {
    right: 10px;
}

.swiper-button-prev {
    left: 10px;
}

.content-name {
    margin-top: 10px;
    color: #fff !important;
}

/* BOTONES */
.boton {
    background: #fff;
    border: 2px solid #eee;
    border-radius: 15px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    padding: 15px 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.boton:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.boton img {
    width: 120px;
    height: 90px;
    object-fit: contain;
}

.boton p {
    margin-top: 10px;
    font-weight: 600;
    color: #333;
}



/* ITEMS MENU SECUNDARIO */
.menu-secundario .item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-transform: uppercase;
    font-size: 0.9rem;
    cursor: pointer;
}

.menu-secundario .item p {
    font-weight: 600;
    color: #000;
}

.menu-secundario .item img {
    width: 200px;
    height: 140px;
    object-fit: contain;
}

/* BOTÓN CERRAR */
.cerrar {
    background: #fff0f0;
    border: 2px solid #ff4b4b;
    color: #ff4b4b;
    font-weight: bold;
    padding: 15px;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.cerrar:hover {
    background: #ff4b4b;
    color: #fff;
}

/* ANIMACIONES DE APARICIÓN Y DESAPARICIÓN */
.fadeIn {
    animation: fadeIn 0.5s ease forwards;
}

.fadeOut {
    animation: fadeOut 0.5s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }

    to {
        opacity: 0;
        transform: translateY(-20px);
    }
}

.fade-out {
    opacity: 0;
    transition: opacity 0.15s ease;
}

.fadeIn {
    opacity: 0;
    animation: fadeIn 0.3s forwards ease;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

/* Musica */
.musica-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 24px;
    background: #d7c6ff;
    color: #fff;
    border: none;
    padding: 10px 15px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.musica-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.musica-btn:active {
    transform: scale(0.95);
}

/* Contenedor grid */
.contenido-secundario-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    justify-content: center;
    width: 100%;
    padding: 0 20px;
}

#contenidoSecundario:has(.aro-info) {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0;
}

/* ============================
   🎨 BOTONES DE ACCIÓN
============================ */
.action-buttons {
    position: fixed;
    bottom: 30px;
    top: 90px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 1000;
}

.action-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: auto;
}

.action-btn:hover {
    transform: scale(1.1) translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.action-btn:active {
    transform: scale(0.95);
}

.reset-btn {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.download-btn {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.share-btn {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}

/* Animación de captura */
@keyframes flash {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.capturing {
    animation: flash 0.3s ease-in-out;
}

@keyframes spin {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.05); }
    100% { transform: rotate(360deg) scale(1); }
}

/* ============================
   📱 MODAL DE COMPARTIR
============================ */
.modal-compartir {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.modal-compartir.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 20px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #ff4757;
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    color: white;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.modal-close:hover {
    transform: rotate(90deg);
    background: #ff3838;
}

.modal-content h3 {
    margin: 0 0 20px 0;
    font-size: 1.5rem;
    color: #333;
}

.social-buttons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.social-btn {
    padding: 15px;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.social-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.social-btn i {
    font-size: 1.3rem;
}

.whatsapp {
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
}

.facebook {
    background: linear-gradient(135deg, #1877f2 0%, #0d5dbd 100%);
}

.twitter {
    background: linear-gradient(135deg, #1DA1F2 0%, #0d8bd9 100%);
}

.telegram {
    background: linear-gradient(135deg, #0088cc 0%, #006699 100%);
}

.preview-container {
    margin-top: 20px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.preview-container img {
    width: 100%;
    display: block;
}

/* ============================
   🔔 NOTIFICACIONES TOAST
============================ */
.toast-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 16px 24px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    z-index: 10000;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    animation: slideInRight 0.3s ease;
    max-width: 300px;
}

.toast-notification.success {
    background: linear-gradient(135deg, #52c234 0%, #38a169 100%);
}

.toast-notification.error {
    background: linear-gradient(135deg, #ff4757 0%, #ff3838 100%);
}

.toast-notification i {
    font-size: 24px;
}

@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

.toast-notification.hiding {
    animation: slideOutRight 0.3s ease forwards;
}

/* ============================
   📱 LOADING SPINNER
============================ */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 9998;
    display: none;
    align-items: center;
    justify-content: center;
}

.loading-overlay.active {
    display: flex;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}


/* ===============================
📱 MOBILE HORIZONTAL / LANDSCAPE
================================== */
@media (max-width: 915px) and (orientation: landscape) {
    body {
        height: 100vh;
        overflow: hidden;
    }
    .bg-fondo {
        min-height: 100vh !important;
        height: 100vh !important;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 0;
        gap: 10px;
    }

    /* Contenedor del auto a la izquierda */
    .car-container {
        position: relative;
        width: 50%;
        height: 100%;
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0;
        padding: 0;
        flex-shrink: 0;
    }
    .car-container img {
        max-width: 100%;
        max-height: 70vh;
        object-fit: contain;
    }

    .car-color-overlay,
    .car-wheel-overlay,
    .car-tire-overlay {
        max-width: 90%;
        max-height: 70vh;
        width: 100%;
        height: 100%;
        object-fit: contain;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
    }

    /* Info de aro más pequeña*/
    .aro-info {
        position: relative;
        width: 95%;
        max-width: 100%;
        font-size: 0.7rem;
        padding: 8px 10px;
        margin: 0 auto 10px auto;
        text-align: center;
        line-height: 1.3;
        background-color: #fff;
        border-radius: 6px;
        box-shadow: 0 1px 3px rgba(0,0,0,0.15);
        transform: none;
        left: auto;
        top: auto;
        white-space: normal;
        word-wrap: break-word;
    }

    .contenido-secundario-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
        padding: 0 5px;
    }

    /*Boton de Musica*/
    .musica-btn {
        position: fixed;
        top: 10px;
        right: 10px;
        padding: 6px 10px;
        font-size: 18px;
        z-index: 9999;
    }
    /*Contenedor de menus a la derecha*/
    .menus-container {
        width: 50%;
        height: 100vh;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        margin: 0;
        min-height: auto;
        padding: 10px;
        overflow-y: auto;
        position: relative;
        z-index: 10;
    }

    /*Menu principal en landscape*/
    .menu-principal {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 10px;
        width: 100%;
        max-width: 400px;
        position: relative;
        z-index: 20;
        opacity: 1;
        visibility: translateY(0);
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0s;
    }

    .menu-principal.oculto {
        display: none !important;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-20px);
        pointer-events: none;
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0.3s;
    }

    .boton {
        padding: 8px 12px;
        border-radius: 8px;
        position: relative;
        z-index: 21;
        pointer-events: auto;
    }

    .boton img {
        width: 90px !important;
        height: 60px !important;
        pointer-events: none;
    }

    .boton p {
        font-size: 1rem;
        margin-top: 5px;
        pointer-events: none;
    }
    /* Menú secundario en landscape */
    .menu-secundario {
        width: 100%;
        height: 100%;
        display: none;
        flex-direction: column;
        padding: 10px;
        position: relative;
        z-index: 20;
        opacity: 0;
        visibility: hidden;
        transform: translateY(20px);
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0.3s;
    }

    .menu-secundario.activo {   
        display: flex !important;
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        pointer-events: auto;
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0s;
    }

    .menu-secundario .item[data-tipo="llantas"] img {
        width: 100px !important;
        height: 100px !important;
        object-fit: contain;
    }

    .menu-secundario .item[data-tipo="llantas"] p {
        font-size: 0.65rem;
        line-height: 1.2;
        margin-top: 5px;
    }

    .cerrar {
        padding: 8px 16px;
        font-size: 0.85rem;
        margin-bottom: 5px;
        align-self: flex-start;
    }

    /* Contenido secundario ajustado */
    #contenidoSecundario {
        flex: 1;
        overflow-y: auto;
        width: 100%;
        max-height: calc(100vh - 60px);
        padding: 10px;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        align-content: start;
        margin-top: -40px;
    }

    /* Cuando hay Swiper en landscape */
    #contenidoSecundario:has(.swiper),
    #contenidoSecundario.swiper-mode {
        display: flex !important;
        flex-direction: column;
        gap: 10px;
    }

    /* Swiper en landscape */
    .swiper {
        width: 100%;
        height: auto;
        padding: 5px 0;
        margin: 0;
    }

    .swiper-wrapper {
        padding: 0.5px;
    }

    .swiper-slide {
        width: 120px !important;
        flex-shrink: 0;
    }

    .swiper-slide img {
        width: 85px !important;
        height: 85px !important;
        object-fit: contain;
    }

    .swiper-slide p {
        font-size: 0.7rem;
        margin-top: 5px;
        line-height: 1.2;
    }

    .swiper-button-next,
    .swiper-button-prev {
        width: 28px !important;
        height: 28px !important;
    }

    .swiper-button-next svg,
    .swiper-button-prev svg {
        width: 11px !important;
        height: 11px !important;
    }

    #contenidoSecundario:has(.swiper),
    #contenidoSecundario.swiper-mode {
        display: flex !important;
        flex-direction: column;
        gap: 0;
        padding: 10px 5px;
        justify-content: flex-start;
        align-items: center;
    }
    
    .action-buttons {
        position: fixed;
        bottom: 10px;
        left: 10px;
        right: auto;
        flex-direction: row;
        z-index: 50;
    }

    .action-btn {
        width: 45px;
        height: 45px;
        font-size: 18px;
    }

    #contenidoSecundario:has(.subaros-grid) .subaros-grid {
        display: none !important;
    }
    
    #contenidoSecundario:has(.subaros-grid) .swiper {
        display: block !important;
    }
    
    .subaros-grid {
        display: none !important;
    }
}

/* ============================
📱 LANDSCAPE MEDIANO (iPhone 12/13, etc.) - 390x844
============================ */
@media (min-width: 668px) and (max-width: 915px) and (orientation: landscape) {
    .menu-principal {
        grid-template-columns: repeat(2, 1fr);
        max-width: 100%;
        gap: 8px;
        padding: 0px;
        z-index: 20;
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0s;
    }

    .menu-principal.oculto {
        display: none !important;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-20px);
        pointer-events: none;
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0.3s;
    }

    .menu-secundario {
        display: none;
        opacity: 0;
        visibility: hidden;
        transform: translateY(20px);
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0.3s;
    }

    .menu-secundario.activo {
        display: flex !important;
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0s;
    }

    .boton {
        z-index: 21;
        pointer-events: auto;
    }

    .boton img {
        width: 70px;
        height: 55px;
    }

    .boton p {
        font-size: 1rem;
    }

    .aro-info {
        font-size: 1rem;
        padding: 6px 10px;
    }

    .contenido-secundario-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }

    /* Swiper en landscape mediano */
    .swiper-slide {
        width: calc(50% - 5px) !important;
        min-width: calc(50% - 5px) !important;
    }

    .swiper-slide img {
        width: 80px !important;
        height: 80px !important;
    }

    #contenidoSecundario {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        margin-top: -35px;
    }

    .menu-secundario .item img {
        width: 135px;
        height: 75px;
    }

    .action-buttons {
        top: 10px;
        left: 10px;
        right: auto;
        flex-direction: row;
        z-index: 50;
    }

    .action-btn {
        width: 45px;
        height: 45px;
        font-size: 18px;
    }

    .car-color-overlay,
    .car-wheel-overlay,
    .car-tire-overlay {
        max-width: 90%;
        max-height: 70vh;
        width: 100%;
        height: 100%;
        object-fit: contain;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
    }
}

/* ============================
📱 LANDSCAPE EXTRA SMALL (iPhone SE, etc.)
============================ */
@media (max-width: 667px) and (orientation: landscape) {
    .car-container {
        width: 45%;
    }

    .car-container img {
        max-height: 55vh;
        max-width: 95%;
    }

    .car-color-overlay,
    .car-wheel-overlay,
    .car-tire-overlay {
        max-width: 90%;
        max-height: 55vh;
        width: 100%;
        height: 100%;
        object-fit: contain;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
    }

    .menus-container {
        width: 55%;
        padding: 5px;
    }

    .menu-principal {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
        max-width: 280px;
        z-index: 20;
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0s;
    }

    .menu-principal.oculto {
        display: none !important;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-20px);
        pointer-events: none;
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0.3s;
    }

    .menu-secundario {
        display: none;
        opacity: 0;
        visibility: hidden;
        transform: translateY(20px);
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0.3s;
    }

    .menu-secundario.activo {
        display: flex !important;
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0s;
    }

    .boton {
        z-index: 21;
        pointer-events: auto;
    }

    .boton img {
        width: 100px;
        height: 70px;
    }

    .boton p {
        font-size: 0.7rem;
    }

    /* 🔥 ARO INFO AJUSTADO */
    .aro-info {
        font-size: 0.9rem;
        padding: 5px 8px;
        width: 98%;
        margin: 0 auto 8px auto;
        line-height: 1.2;
    }

    .contenido-secundario-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 5px;
    }

    /* 🔥 CONTENIDO SECUNDARIO LANDSCAPE PEQUEÑO */
    #contenidoSecundario {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
        padding: 5px;
        margin-top: -30px;
    }

    /* 🔥 SWIPER EN LANDSCAPE PEQUEÑO - SIN ESPACIOS */
    #contenidoSecundario:has(.swiper),
    #contenidoSecundario.swiper-mode {
        display: flex !important;
        flex-direction: column;
        gap: 5px;
        padding: 5px;
        margin-top: -20px;
    }

    .swiper.mySwiper {
        width: 100% !important;
        max-width: 100% !important;
        padding: 5px 0 !important;
        margin: 0 !important;
        overflow: hidden !important;
    }

    .swiper-wrapper {
        padding: 0 !important;
        margin: 0 !important;
        display: flex !important;
    }

    .swiper-slide {
        width: calc(50% - 4px) !important;
        min-width: calc(50% - 4px) !important;
        max-width: calc(50% - 4px) !important;
        flex-shrink: 0 !important;
        margin-right: 8px !important;
    }

    .swiper-slide:last-child {
        margin-right: 0 !important;
    }

    .swiper-slide img {
        width: 65px !important;
        height: 65px !important;
        object-fit: contain;
    }

    .swiper-slide p {
        font-size: 0.55rem;
        line-height: 1.1;
        margin-top: 3px;
    }

    /* Flechas de navegación */
    .swiper-button-next,
    .swiper-button-prev {
        width: 26px !important;
        height: 26px !important;
    }

    .swiper-button-next svg,
    .swiper-button-prev svg {
        width: 9px !important;
        height: 9px !important;
    }

    .swiper-button-next {
        right: 2px !important;
    }

    .swiper-button-prev {
        left: 2px !important;
    }

    /* Items del menú */
    .menu-secundario .item img {
        width: 75px;
        height: 55px;
    }

    .menu-secundario .item p {
        font-size: 0.65rem;
    }


    /* Botones de acción en landscape extra small */
    .action-buttons {
        top: 10px;
        left: 5px;
        right: auto;
        flex-direction: row;
        gap: 8px;
        z-index: 50;
    }

    .action-btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}
