/* ==========================================
   COMPONENTS CSS - SoloTurnos Landing
   Badges, tickets, TV frames, split-panel, WhatsApp
   ========================================== */

/* --- PREMIUM BADGES --- */
.premium-badge { 
    position: absolute; 
    padding: 12px 36px; 
    border-radius: 9999px; 
    font-size: 28px; 
    font-weight: 800; 
    letter-spacing: 0.03em; 
    text-transform: uppercase; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    white-space: nowrap; 
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05); 
}

.badge-orange { 
    color: white; 
    background-color: #f2722b; 
}

.badge-dark { 
    color: white; 
    background-color: #0f172a; 
}

/* --- TICKET BASE (Empresas) --- */
.ticket-base { 
    background: white; 
    border-bottom: 6px dotted #cbd5e1; 
    position: relative; 
    box-shadow: 0 15px 35px rgba(0,0,0,0.1); 
}

/* --- TV FRAME (Pantallas) --- */
.tv-frame { 
    background: #0f172a; 
    border: 8px solid #1e293b; 
    border-radius: 14px; 
    box-shadow: 0 30px 60px rgba(0,0,0,0.25); 
    overflow: hidden; 
    position: relative; 
}

.tv-grid { 
    position: absolute; 
    inset: 0; 
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.1) 50%); 
    background-size: 100% 4px; 
    z-index: 10; 
    pointer-events: none; 
    opacity: 0.2; 
}

/* --- TRUCK ELEMENTS (Empresas) --- */
.truck-top { 
    display: flex; 
    align-items: center; 
}

.truck-trailer { 
    width: 50px; 
    height: 18px; 
    background: #1e293b; 
    border-radius: 2px; 
}

.truck-cab { 
    width: 16px; 
    height: 16px; 
    background: #2563eb; 
    border-radius: 0 4px 4px 0; 
    margin-left: 2px; 
    position: relative; 
}

/* --- SPLIT CONTAINER (Gateway) --- */
.split-container { 
    position: relative; 
    width: 100%; 
    height: 100vh; 
    overflow: hidden; 
    display: flex; 
    background-color: #0f172a; 
}

.split-panel { 
    position: absolute; 
    top: 0; 
    height: 100%; 
    width: 100%; 
    transition: clip-path 0.8s cubic-bezier(0.25, 1, 0.5, 1); 
    -webkit-transform: translateZ(0); 
    transform: translateZ(0); 
    backface-visibility: hidden; 
}

.split-panel-content { 
    position: absolute; 
    top: 45%; 
    transform: translateY(-50%); 
    width: 50%; 
    padding: 0 4rem; 
    z-index: 20; 
}

.split-left { 
    left: 0; 
    clip-path: polygon(0 0, 53% 0, 47% 100%, 0 100%); 
    z-index: 10; 
}

.split-right { 
    right: 0; 
    clip-path: polygon(48% 0, 100% 0, 100% 100%, 42% 100%); 
    z-index: 5; 
}

.split-left .split-panel-content { left: 0; }
.split-right .split-panel-content { right: 0; }

.slide-content-text { 
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.5s; 
}

.slide-content-btn { 
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.5s; 
    cursor: pointer; 
}

.overlay-grad { 
    transition: opacity 0.8s ease; 
    opacity: 1; 
}

/* Split hover effects - Desktop */
@media (min-width: 1024px) {
    .split-container:has(.split-left:hover) .split-left { 
        clip-path: polygon(0 0, 63% 0, 57% 100%, 0 100%); 
    }
    .split-container:has(.split-left:hover) .split-right { 
        clip-path: polygon(58% 0, 100% 0, 100% 100%, 52% 100%); 
    }
    .split-container:has(.split-left:hover) .split-left .slide-content-text { 
        transform: translateY(-8px); 
    }
    .split-container:has(.split-left:hover) .split-left .slide-content-btn { 
        transform: scale(1.05); 
    }
    .split-container:has(.split-left:hover) .split-right .overlay-grad { 
        opacity: 0.98; 
    }
    .split-container:has(.split-left:hover) .split-right .split-panel-content { 
        opacity: 0.2; 
        pointer-events: none; 
    }
    .split-container:has(.split-right:hover) .split-left { 
        clip-path: polygon(0 0, 43% 0, 37% 100%, 0 100%); 
    }
    .split-container:has(.split-right:hover) .split-right { 
        clip-path: polygon(38% 0, 100% 0, 100% 100%, 32% 100%); 
    }
    .split-container:has(.split-right:hover) .split-right .slide-content-text { 
        transform: translateY(-8px); 
    }
    .split-container:has(.split-right:hover) .split-right .slide-content-btn { 
        transform: scale(1.05); 
    }
    .split-container:has(.split-right:hover) .split-left .overlay-grad { 
        opacity: 0.98; 
    }
    .split-container:has(.split-right:hover) .split-left .split-panel-content { 
        opacity: 0.2; 
        pointer-events: none; 
    }
}

/* Split mobile layout */
@media (max-width: 1023px) {
    .split-container { 
        flex-direction: column; 
        height: auto; 
    }
    .split-panel { 
        position: relative; 
        height: 70vh; 
        width: 100%; 
        transition: none; 
    }
    .split-left { 
        clip-path: none;
        z-index: 10; 
        margin-bottom: -8vh; 
    }
    .split-right { 
        clip-path: none;
        height: 70vh; 
    }
    .split-panel-content { 
        width: 100%; 
        padding: 0 2rem; 
        text-align: center; 
    }
    .split-left .split-panel-content { top: 38%; align-items: center; }
    .split-right .split-panel-content { top: 39%; align-items: center; }
}

/* --- SLIDESHOW KEN BURNS --- */
.slideshow-container { 
    position: absolute; 
    inset: -10%; 
    width: 120%; 
    height: 120%; 
    z-index: 0; 
    background-color: #020617; 
}

.bg-slide { 
    position: absolute; 
    inset: 0; 
    width: 100%; 
    height: 100%; 
    background-size: cover; 
    background-position: center; 
    opacity: 0; 
    z-index: 1; 
    transition: opacity 1.5s ease-in-out, transform 20s linear; 
    backface-visibility: hidden; 
    -webkit-backface-visibility: hidden; 
    transform: translateZ(0) scale(1.0); 
}

.bg-slide.active { 
    opacity: 1; 
    z-index: 3; 
    transform: translateZ(0) scale(1.15); 
}

.bg-slide.prev { 
    opacity: 1; 
    z-index: 2; 
    transform: translateZ(0) scale(1.15); 
}

/* Disable Ken Burns zoom + oversized container on mobile */
@media (max-width: 1023px) {
    .slideshow-container { 
        inset: 0; 
        width: 100%; 
        height: 100%; 
    }
    .bg-slide { 
        transition: opacity 1.5s ease-in-out; 
        transform: scale(1.0); 
    }
    .bg-slide.active, 
    .bg-slide.prev { 
        transform: scale(1.0); 
    }
}

/* --- CARRUSEL INFINITO (Ticker Flow) --- */
.ticker-wrapper-flow {
    width: 100%;
    overflow: hidden;
    display: flex;
    background-color: transparent;
    pointer-events: auto;
}

/* Desktop only: mask for smooth edges */
@media (min-width: 1024px) {
    .ticker-wrapper-flow {
        mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
        -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    }
}

.ticker-track-flow {
    display: flex;
    width: max-content;
    transform: translateZ(0); 
    -webkit-transform: translate3d(0, 0, 0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

/* Prevent buttons from shrinking so blockWidth is calculated correctly */
.ticker-track-flow a {
    flex-shrink: 0;
}

.ticker-track-flow.animated {
    animation: marquee-flow 200s linear infinite;
}

.ticker-track-flow:hover { 
    animation-play-state: paused; 
}

@keyframes marquee-flow {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* --- WHATSAPP FLOATING BUTTON --- */
.whatsapp-float {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 150;
    background-color: #25D366;
    color: white;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.875rem;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    transition: transform 0.3s;
}

.whatsapp-float:hover {
    transform: scale(1.1);
}

/* --- FAQ ITEM --- */
.faq-item {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    overflow: hidden;
    transition: border-color 0.3s, box-shadow 0.3s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.faq-item:hover {
    border-color: #93c5fd;
}

.faq-item.is-open {
    border-color: #60a5fa;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

/* --- EMBEDDED ANIM CONTAINER --- */
.embedded-anim-container {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

/* --- INPUT FIELD (Forms) --- */
.input-field { 
    transition: border-color 0.3s ease, box-shadow 0.3s ease; 
}

.input-field:focus { 
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15); 
    border-color: #3b82f6; 
}

/* --- RUBRO BUTTON (Hero Marquee) --- */
.rubro-btn {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 1.25rem;
    border-radius: 1rem;
    background-color: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: background-color 0.3s, border-color 0.3s, transform 0.3s;
    text-decoration: none;
}

.rubro-btn:hover {
    transform: translateY(-4px);
    background-color: rgba(255, 255, 255, 0.1);
}

.rubro-btn-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    transition: background-color 0.3s, color 0.3s;
}

.rubro-btn-label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
    font-weight: 600;
    white-space: nowrap;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    transition: color 0.3s;
}

.rubro-btn:hover .rubro-btn-label {
    color: white;
}

/* Variant: Orange */
.rubro-btn--orange .rubro-btn-icon {
    background-color: rgba(249, 115, 22, 0.2);
    color: #fb923c;
}

.rubro-btn--orange:hover {
    border-color: rgba(249, 115, 22, 0.5);
    box-shadow: 0 4px 20px rgba(249, 115, 22, 0.2);
}

.rubro-btn--orange:hover .rubro-btn-icon {
    background-color: #f97316;
    color: white;
}

/* Variant: Indigo */
.rubro-btn--indigo .rubro-btn-icon {
    background-color: rgba(99, 102, 241, 0.2);
    color: #818cf8;
}

.rubro-btn--indigo:hover {
    border-color: rgba(99, 102, 241, 0.5);
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.2);
}

.rubro-btn--indigo:hover .rubro-btn-icon {
    background-color: #4f46e5;
    color: white;
}

/* --- MARQUEE WINDOW (Fade mask) --- */
.marquee-window {
    width: 100%;
    height: 100%;
    overflow: hidden;
    position: relative;
    pointer-events: auto;
    padding: 10px 0;
}

/* Fade masks for marquee edges — smooth transition at split center */
.marquee-window--fade-right {
    -webkit-mask-image: linear-gradient(to right, black calc(100% - 120px), transparent 100%);
    mask-image: linear-gradient(to right, black calc(100% - 120px), transparent 100%);
}

.marquee-window--fade-left {
    -webkit-mask-image: linear-gradient(to left, black calc(100% - 120px), transparent 100%);
    mask-image: linear-gradient(to left, black calc(100% - 120px), transparent 100%);
}

/* --- MARQUEE TRACK --- */
.marquee-track {
    display: flex;
    align-items: center;
    height: 100%;
    width: max-content;
    transform: translateZ(0);
}
.marquee-track.is-dragging,
.marquee-track.is-dragging * {
    pointer-events: none !important;
}

/* --- PHONE FRAME COMPONENT --- */
.phone-frame {
    position: relative;
    width: 320px;
    height: 640px;
    background: #000;
    border-radius: 44px;
    padding: 9px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}
.phone-frame::before {
    content: '';
    position: absolute;
    top: 9px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 28px;
    background: #000;
    border-radius: 0 0 16px 16px;
    z-index: 50;
}
.phone-frame__screen {
    width: 100%;
    height: 100%;
    border-radius: 36px;
    overflow: hidden;
}
.phone-frame__btn {
    position: absolute;
    background: #6b7280;
    border-radius: 2px;
}
.phone-frame__btn--silent { left: -3px; top: 120px; width: 3px; height: 24px; }
.phone-frame__btn--vol-up { left: -3px; top: 160px; width: 3px; height: 40px; }
.phone-frame__btn--vol-down { left: -3px; top: 210px; width: 3px; height: 40px; }
.phone-frame__btn--power { right: -3px; top: 160px; width: 3px; height: 60px; }
/* Suppress default notch when phone has a custom Dynamic Island inner div */
.phone-frame--no-notch::before { display: none; }
/* Size variants for non-standard containers */
.phone-frame--md { width: 350px; height: 670px; border-radius: 40px; padding: 8px; }
.phone-frame--md .phone-frame__screen { border-radius: 33px; }
.phone-frame--lg { width: 360px; height: 720px; border-radius: 44px; padding: 9px; }
.phone-frame--lg .phone-frame__screen { border-radius: 36px; }

/* --- COUNTRY SELECTOR --- */
.country-selector-wrapper {
    position: relative;
}

.country-dropdown {
    transition: opacity 0.3s, transform 0.3s;
}

/* --- CLIENT LOGOS MARQUEE --- */
#clientes-marquee { display: flex; flex-direction: column; width: 80%; }
/* .marquee-row { width: max-content; }
.marquee-row.animate-marquee-left { animation: scrollLogosLeft 3000s linear infinite; }
.marquee-row.animate-marquee-right { animation: scrollLogosRight 3000s linear infinite; }
@keyframes scrollLogosLeft { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
@keyframes scrollLogosRight { 0% { transform: translateX(-50%); } 100% { transform: translateX(0); } } */
.scrollbar-hide::-webkit-scrollbar { display: none; }
.scrollbar-hide { -ms-overflow-style: none; scrollbar-width: none; }
