/* =============================================
   MomoBytes – Hoja de estilos global
   Complementa la configuración de Tailwind CSS
   ============================================= */

/* --- Tipografía base --- */
body {
    font-family: 'Space Grotesk', sans-serif;
}

/* --- Variante Inter (usada en automatizacion-con-ia.html) --- */
body.font-inter {
    font-family: 'Inter', sans-serif;
}

/* --- Logos de clientes en escala de grises con hover a color --- */
.grayscale-logo {
    filter: grayscale(100%);
    opacity: 0.6;
    transition: all 0.3s ease;
}

.grayscale-logo:hover {
    filter: grayscale(0%);
    opacity: 1;
}

/* --- Navbar con glassmorphism --- */
.glass-nav {
    backdrop-filter: blur(10px);
    background-color: rgba(255, 255, 255, 0.8);
}

/* --- Formulario de contacto: color de foco personalizado --- */
.form-input-focus:focus {
    border-color: #00f0a0;
    --tw-ring-color: #00f0a0;
}

/* --- Íconos Material Symbols: variante de fuente por defecto --- */
.material-symbols-outlined {
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* =============================================
   Logo recortado (elimina espacio en blanco)
   ============================================= */
.logo-nav {
    /* Amplía y recorta el espacio blanco del logo */
    height: 48px;
    width: auto;
    /* El logo PNG tiene ~25% de padding en cada lado, compensamos */
    margin: -8px -12px;
    max-width: none;
}

.logo-footer {
    height: 36px;
    width: auto;
    margin: -6px -10px;
    max-width: none;
}

/* =============================================
   Cookie Consent Banner — MomoBytes
   ============================================= */

#mb-cookie-banner {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(calc(100% + 32px));
    z-index: 9999;
    width: calc(100% - 48px);
    max-width: 780px;
    background: #ffffff;
    border: 1px solid rgba(0, 240, 160, 0.25);
    border-radius: 1rem;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.04);
    opacity: 0;
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1),
        opacity 0.35s ease;
}

#mb-cookie-banner.mb-cookie-show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

#mb-cookie-banner.mb-cookie-hide {
    transform: translateX(-50%) translateY(calc(100% + 32px));
    opacity: 0;
}

.mb-cookie-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 20px;
    flex-wrap: wrap;
}

.mb-cookie-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.mb-cookie-icon {
    font-size: 22px;
    flex-shrink: 0;
    line-height: 1;
}

.mb-cookie-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 13px;
    line-height: 1.5;
    color: #475569;
    font-family: 'Space Grotesk', sans-serif;
}

.mb-cookie-text strong {
    font-size: 14px;
    font-weight: 700;
    color: #0f172a;
}

.mb-cookie-text a {
    color: #00f0a0;
    font-weight: 600;
    text-decoration: none;
}

.mb-cookie-text a:hover {
    text-decoration: underline;
}

.mb-cookie-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.mb-btn-deny,
.mb-btn-accept {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 13px;
    font-weight: 700;
    padding: 8px 18px;
    border-radius: 9999px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    border: none;
    outline: none;
}

.mb-btn-deny {
    background: transparent;
    color: #64748b;
    border: 1.5px solid #e2e8f0;
}

.mb-btn-deny:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #334155;
}

.mb-btn-accept {
    background: #00f0a0;
    color: #0f172a;
}

.mb-btn-accept:hover {
    filter: brightness(1.06);
    transform: scale(1.03);
}

@media (max-width: 560px) {
    #mb-cookie-banner {
        bottom: 12px;
        width: calc(100% - 24px);
    }

    .mb-cookie-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .mb-cookie-actions {
        width: 100%;
        justify-content: flex-end;
    }
}

/* =============================================
   Hamburger Menu Button
   ============================================= */

#mb-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    border-radius: 8px;
    padding: 4px;
    transition: background 0.2s;
    flex-shrink: 0;
}

#mb-hamburger:hover {
    background: rgba(0, 240, 160, 0.08);
}

#mb-hamburger .hb-line {
    display: block;
    width: 22px;
    height: 2px;
    background: #0f172a;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.2s ease;
    transform-origin: center;
}

#mb-hamburger.is-active .hb-line:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

#mb-hamburger.is-active .hb-line:nth-child(2) {
    opacity: 0;
}

#mb-hamburger.is-active .hb-line:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Ocultar CTA + language switcher del nav en móvil/tablet */
@media (max-width: 767px) {
    #mb-hamburger {
        display: flex;
    }

    #mb-nav-right {
        display: none !important;
    }
}

/* =============================================
   Mobile Menu Drawer
   ============================================= */

#mb-mobile-menu {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9998;
}

#mb-mobile-menu.mb-menu-open {
    display: block;
}

#mb-mobile-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(2px);
    animation: mbFadeIn 0.25s ease forwards;
}

@keyframes mbFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

#mb-mobile-drawer {
    position: absolute;
    top: 0;
    right: 0;
    width: 88%;
    max-width: 340px;
    height: 100%;
    background: #ffffff;
    box-shadow: -4px 0 40px rgba(0, 0, 0, 0.12);
    display: flex;
    flex-direction: column;
    animation: mbSlideIn 0.3s cubic-bezier(0.34, 1.2, 0.64, 1) forwards;
    overflow: hidden;
}

@keyframes mbSlideIn {
    from {
        transform: translateX(110%);
    }

    to {
        transform: translateX(0);
    }
}

.mb-mobile-link {
    display: block;
    padding: 13px 16px;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    color: #334155;
    text-decoration: none;
    transition: background 0.15s, color 0.15s;
    font-family: 'Space Grotesk', sans-serif;
}

.mb-mobile-link:hover {
    background: rgba(0, 240, 160, 0.1);
    color: #009960;
}

.mb-mobile-link.active {
    color: #00a070;
    font-weight: 700;
    background: rgba(0, 240, 160, 0.08);
}

/* =============================================
   Chat Widget (Chatbase)
   ============================================= */

#cb-chat-btn {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9990;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #00f0a0;
    color: #0f172a;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 24px rgba(0, 240, 160, 0.35), 0 2px 8px rgba(0, 0, 0, 0.12);
    transition: transform 0.2s, box-shadow 0.2s;
}

#cb-chat-btn:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 32px rgba(0, 240, 160, 0.45);
}

#cb-chat-panel {
    position: fixed;
    bottom: 92px;
    right: 24px;
    z-index: 9991;
    width: 370px;
    height: 560px;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 8px 48px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    transform: translateY(12px) scale(0.97);
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

#cb-chat-panel.cb-open {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

#cb-chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid #f1f5f9;
    background: #ffffff;
    flex-shrink: 0;
}

#cb-iframe {
    flex: 1;
    width: 100%;
    border: none;
}

@media (max-width: 480px) {
    #cb-chat-panel {
        right: 8px;
        left: 8px;
        width: auto;
        bottom: 88px;
        height: 70vh;
    }
}