/* ============================================
   CHAT BOT 
   ============================================ */

:root {
    --primary: #0066B3;
    --primary-dark: #14427a;
    --primary-light: #3385c7;
    --light: #f5f5f7;
    --shadow: 0 10px 30px rgba(0,0,0,0.08);
    --shadow-hover: 0 15px 40px rgba(0,0,0,0.12);
    --gray: #666666;
    --gray-light: #e0e0e0;
    --white: #ffffff;
    --dark: #000000;
}


/* CTA Button */
.cta-button {
    background: var(--dark);
    color: var(--white);
    padding: 12px 28px;
    border-radius: var(--radius);
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    position: relative;
    overflow: hidden;
    margin-left: 20px;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.7s;
}

.cta-button:hover::before {
    left: 100%;
}

.cta-button:hover {
    background: var(--accent);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 168, 89, 0.3);
}



/* --------------------------------------------
   HERO
-------------------------------------------- */
.chatbot-hero {
    position: relative;
    margin-top: 90px;
    padding: 100px 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    overflow: hidden;
}

/* Imagen de fondo */
.chatbot-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../../../../imagenes/chatbot_bg.jpg'); 
    background-size: cover;
    background-position: center;
    animation: zoomBg 20s infinite alternate;
    z-index: 0;
}

@keyframes zoomBg {
    0% { transform: scale(1); }
    100% { transform: scale(1.05); }
}

/* Contenido del hero */
.chatbot-hero-content {
    position: relative;
    max-width: 900px;
    color: white;
    z-index: 2;
    text-align: center;
    margin: 0 auto;
    background: rgba(0, 0, 0, 0.4);
    padding: 40px 30px;
    border-radius: 20px;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    border: 1px solid rgba(255,255,255,0.1);
}

.chatbot-hero-badge {
    display: inline-block;
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 8px 24px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 2px;
    margin-bottom: 30px;
    border: 1px solid rgba(255,255,255,0.3);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.chatbot-hero-title {
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 25px;
    text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

.text-highlight {
    position: relative;
    display: inline-block;
}

.text-highlight::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 0;
    width: 100%;
    height: 8px;
    z-index: -1;
}

.chatbot-hero-description {
    font-size: 1.2rem;
    line-height: 1.8;
    opacity: 0.9;
    max-width: 700px;
    margin: 0 auto;
}

/* --------------------------------------------
   DESCRIPCIÓN PRINCIPAL
-------------------------------------------- */
.chatbot-desc-section {
    padding: 100px 0;
    background: var(--white);
}

.desc-card {
    max-width: 1000px;
    margin: 0 auto;
    padding: 60px 50px;
    background: white;
    border-radius: 30px;
    box-shadow: var(--shadow);
    border: 1px solid var(--gray-light);
    text-align: center;
    transition: all 0.4s ease;
}

.desc-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary);
}

.desc-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 30px;
    font-size: 32px;
    color: white;
    transition: all 0.4s ease;
}

.desc-card:hover .desc-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 10px 25px rgba(26,86,157,0.3);
}

.desc-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 25px;
}

.desc-text p {
    color: var(--primary-dark);
    line-height: 1.8;
    font-size: 1.1rem;
    text-align: justify;
    margin-bottom: 20px;
}

.btn-desc {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--white);
    color: var(--primary);
    padding: 14px 35px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.4s ease;
    border: 2px solid transparent;
    margin-top: 20px;
}

.btn-desc:hover {
    background: var(--gray-light);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(26,86,157,0.2);
}

.btn-desc i {
    transition: transform 0.3s ease;
}

.btn-desc:hover i {
    transform: translateX(5px);
}

/* --------------------------------------------
   GALERÍA DE BENEFICIOS
-------------------------------------------- */
.chatbot-gallery-section {
    padding: 100px 0;
    background: linear-gradient(135deg, var(--light) 0%, #e6f0fa 100%);
}

.chatbot-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
}

.gallery-card {
    background: white;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.4s ease;
    border: 1px solid var(--gray-light);
}

.gallery-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary);
}

.gallery-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.gallery-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.gallery-card:hover .gallery-image img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(26,86,157,0.7) 0%, rgba(20,66,122,0.8) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.gallery-card:hover .gallery-overlay {
    opacity: 1;
}

.gallery-overlay i {
    color: white;
    font-size: 2.5rem;
    transform: scale(0);
    transition: transform 0.4s ease 0.1s;
}

.gallery-card:hover .gallery-overlay i {
    transform: scale(1);
}

.gallery-content {
    padding: 25px 20px;
    text-align: center;
}

.gallery-content h3 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 10px;
}

.gallery-content p {
    color: var(--gray);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* --------------------------------------------
   CTA
-------------------------------------------- */
.chatbot-cta-section {
    padding: 100px 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    text-align: center;
}

.cta-content h2 {
    font-size: 2.8rem;
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.3;
}

.cta-content p {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 40px;
}

.btn-cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: white;
    color: var(--primary);
    padding: 16px 45px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    transition: all 0.4s ease;
    border: 2px solid white;
}

.btn-cta:hover {
    background: transparent;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 20px 30px rgba(0,0,0,0.2);
}

.btn-cta i {
    transition: transform 0.3s ease;
}

.btn-cta:hover i {
    transform: translateX(5px);
}

/* --------------------------------------------
   SECTION HEADER
-------------------------------------------- */
.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 50px;
}

.section-badge {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 6px 20px;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 15px;
}

.section-title {
    font-size: 2.8rem;
    font-weight: 800;
    color: var(--primary-dark);
    margin-bottom: 15px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--gray);
}

/* ============================================
   VENTANA DE CHAT
   ============================================ */
.chat-window {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 350px;
    height: 500px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
    display: none;
    flex-direction: column;
    overflow: hidden;
    z-index: 9999;
    border: 1px solid var(--gray-light);
}

.chat-window.open {
    display: flex;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chat-header {
    background: var(--primary);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
}

.chat-header h4 {
    margin: 0;
    font-size: 1.1rem;
}

.chat-close {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
}

.chat-close:hover {
    opacity: 0.8;
}

.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background: #f9f9f9;
}

.message {
    margin-bottom: 15px;
    display: flex;
}

.message.bot {
    justify-content: flex-start;
}

.message.user {
    justify-content: flex-end;
}

.message p {
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 18px;
    font-size: 0.9rem;
    line-height: 1.4;
    margin: 0;
}

.message.bot p {
    background: var(--primary-light);
    color: white;
    border-bottom-left-radius: 5px;
}

.message.user p {
    background: var(--primary);
    color: white;
    border-bottom-right-radius: 5px;
}

.chat-input {
    display: flex;
    padding: 15px;
    border-top: 1px solid var(--gray-light);
    background: white;
}

.chat-input input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid var(--gray-light);
    border-radius: 30px;
    outline: none;
    font-size: 0.9rem;
}

.chat-input input:focus {
    border-color: var(--primary);
}

.chat-input button {
    background: var(--primary);
    color: white;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    margin-left: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-input button:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

/* ============================================
    RESPONSIVE - CHAT BOT
   ============================================ */

/* Tablets grandes (992px y menos) - HERO */
@media screen and (max-width: 992px) {
    .chatbot-hero {
        padding: 80px 0;
        margin-top: 80px;
    }
    
    .chatbot-hero::before {
        background-position: 70% center;
    }
    
    .chatbot-hero-content {
        max-width: 80%;
        padding: 35px 25px;
    }
    
    .chatbot-hero-title {
        font-size: 3rem;
    }
    
    .chatbot-hero-description {
        font-size: 1.1rem;
        max-width: 600px;
    }
    
    .chatbot-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
    
    .desc-card {
        padding: 50px 40px;
        margin: 0 20px;
    }
}

/* Tablets verticales */
@media screen and (max-width: 768px) {
    .chatbot-hero {
        padding: 60px 0;
    }
    
    .chatbot-hero::before {
        background-position: 65% center;
        animation: none;
        background-attachment: scroll;
    }
    
    .chatbot-hero-content {
        max-width: 90%;
        padding: 30px 20px;
        backdrop-filter: blur(5px);
    }
    
    .chatbot-hero-badge {
        font-size: 12px;
        padding: 6px 20px;
        margin-bottom: 20px;
    }
    
    .chatbot-hero-title {
        font-size: 2.5rem;
        line-height: 1.2;
    }
    
    .text-highlight::after {
        height: 6px;
        bottom: 3px;
    }
    
    .chatbot-hero-description {
        font-size: 1rem;
        max-width: 100%;
        line-height: 1.6;
    }
    
    .chatbot-desc-section,
    .chatbot-gallery-section,
    .chatbot-cta-section {
        padding: 60px 0;
    }
    
    .desc-card {
        padding: 40px 30px;
        margin: 0 15px;
    }
    
    .desc-icon {
        width: 70px;
        height: 70px;
        font-size: 28px;
        margin-bottom: 25px;
    }
    
    .desc-title {
        font-size: 2rem;
        margin-bottom: 20px;
    }
    
    .desc-text p {
        font-size: 0.95rem;
        line-height: 1.7;
        text-align: left;
    }
    
    .btn-desc {
        padding: 12px 30px;
        font-size: 0.95rem;
    }
    
    .chatbot-gallery-grid {
        grid-template-columns: 1fr;
        max-width: 400px;
        margin: 30px auto 0;
        gap: 20px;
    }
    
    .gallery-image {
        height: 220px;
    }
    
    .gallery-content h3 {
        font-size: 1.3rem;
    }
    
    .gallery-content p {
        font-size: 0.9rem;
    }
    
    .section-header {
        margin-bottom: 35px;
        padding: 0 20px;
    }
    
    .section-badge {
        font-size: 11px;
        padding: 5px 16px;
        margin-bottom: 12px;
    }
    
    .section-title {
        font-size: 2rem;
        margin-bottom: 12px;
    }
    
    .section-subtitle {
        font-size: 0.95rem;
        line-height: 1.5;
    }
    
    .cta-content h2 {
        font-size: 2rem;
        padding: 0 20px;
    }
    
    .cta-content p {
        font-size: 1rem;
        padding: 0 20px;
        margin-bottom: 30px;
    }
    
    .btn-cta {
        padding: 14px 35px;
        font-size: 1rem;
    }
    
    /* Ajustes ventana de chat en tablet */
    .chat-window {
        width: 320px;
        height: 450px;
        bottom: 20px;
        right: 20px;
    }
}

/* Móviles pequeños  */
@media screen and (max-width: 576px) {
    .chatbot-hero {
        padding: 50px 0;
    }
    
    .chatbot-hero::before {
        background-position: 60% center;
    }
    
    .chatbot-hero-content {
        max-width: 95%;
        padding: 25px 15px;
    }
    
    .chatbot-hero-badge {
        font-size: 10px;
        padding: 5px 16px;
        letter-spacing: 1px;
    }
    
    .chatbot-hero-title {
        font-size: 2rem;
    }
    
    .chatbot-hero-description {
        font-size: 0.95rem;
    }
    
    .desc-card {
        padding: 30px 20px;
    }
    
    .desc-icon {
        width: 60px;
        height: 60px;
        font-size: 24px;
    }
    
    .desc-title {
        font-size: 1.6rem;
    }
    
    .desc-text p {
        font-size: 0.9rem;
    }
    
    .btn-desc {
        padding: 10px 25px;
        font-size: 0.9rem;
    }
    
    .gallery-image {
        height: 200px;
    }
    
    .gallery-content h3 {
        font-size: 1.2rem;
    }
    
    .gallery-content p {
        font-size: 0.85rem;
    }
    
    .section-title {
        font-size: 1.6rem;
    }
    
    .section-subtitle {
        font-size: 0.9rem;
    }
    
    .cta-content h2 {
        font-size: 1.6rem;
        padding: 0 15px;
    }
    
    .cta-content p {
        font-size: 0.95rem;
        padding: 0 15px;
    }
    
    .btn-cta {
        padding: 12px 30px;
        font-size: 0.95rem;
    }
    
    /* Ventana de chat en móvil */
    .chat-window {
        width: 100%;
        height: 100%;
        bottom: 0;
        right: 0;
        border-radius: 0;
    }
}


@media screen and (max-width: 380px) {
    .chatbot-hero-title {
        font-size: 1.8rem;
    }
    
    .chatbot-hero-badge {
        font-size: 9px;
        padding: 4px 14px;
    }
    
    .chatbot-hero-description {
        font-size: 0.9rem;
    }
    
    .cta-content h2 {
        font-size: 1.4rem;
    }
    
    .btn-cta {
        padding: 10px 25px;
        font-size: 0.9rem;
    }
}


.chatbot-hero::before {
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

@media screen and (max-width: 768px) {
    .chatbot-hero::before {
        background-attachment: scroll;
    }
}


.chatbot-hero {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 500px;
}

.chatbot-hero-content {
    width: 90%;
    max-width: 900px;
}

/* ============================================
   MENÚ RESPONSIVE MODERNO (IGUAL AL PRINCIPAL)
   ============================================ */
@media screen and (max-width: 992px) {
     .header-content {
        position: relative;
        padding: 10px 0;
    }


    .header {
        padding: 10px 0;
    }

    .header-content {
        flex-direction: row;
        gap: 15px;
        min-height: auto;
    }

    .logo {
        height: 50px;
    }

    .logo img {
        width: 150px;
        height: 40px;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }

    .nav {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        background: var(--primary); 
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 1001;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
        max-height: 0;
        overflow: hidden;
    }

    .nav.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
        max-height: 80vh;
        overflow-y: auto;
    }

    .nav ul {
        flex-direction: column;
        width: 100%;
        gap: 0;
        align-items: stretch;
        padding: 10px 0;
    }

    .nav-item {
        width: 100%;
        text-align: left;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        position: relative;
        display: block;
    }

    .nav a {
        padding: 15px 20px;
        font-size: 16px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        position: relative;
        z-index: 1;
        font-family: 'Inter', sans-serif;
    }

    .submenu-toggle {
        display: flex;
        position: absolute;
        right: 0;
        top: 0;
        height: 100%;
        align-items: center;
        justify-content: center;
        width: 50px;
        z-index: 2;
        margin: 0;
        font-family: 'Inter', sans-serif;
    }

    .nav-item.has-submenu > a {
        padding-right: 50px;
    }

    .submenu-toggle.active {
        transform: rotate(90deg);
    }

    .submenu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        box-shadow: none;
        background: rgba(0, 0, 0, 0.1);
        width: 100%;
        margin: 0;
        padding: 0;
        display: block;
    }

    .submenu.active-mobile {
        max-height: 500px;
    }

    .submenu li {
        border-bottom: none;
    }

    .submenu a {
        padding: 12px 20px 12px 40px;
        font-size: 14px;
        background: rgba(0, 0, 0, 0.1);
        position: relative;
        z-index: 1;
        font-family: 'Inter', sans-serif;
    }

    .submenu a:hover {
        background: rgba(255, 255, 255, 0.1);
        padding-left: 45px;
    }
}
