:root {
    --primary: #6366f1;
    --accent: #a855f7;
    --bg: #0b0f1a;
    --glass: rgba(255, 255, 255, 0.03);
    --border: rgba(255, 255, 255, 0.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', sans-serif; scroll-behavior: smooth; }

body { background: var(--bg); color: #fff; overflow-x: hidden; }

/* Reutilizable Glass */
.glass {
    background: var(--glass);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--border);
    border-radius: 24px;
}

/* Navbar & Mobile Menu */
.navbar {
    position: fixed;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 95%;
    max-width: 1100px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 2rem;
    z-index: 2000;
    transition: 0.4s;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-img {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary), var(--accent));
}

.logo-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.logo { font-weight: 800; font-size: 1.4rem; }
.logo span { color: var(--primary); }

.nav-links { display: flex; list-style: none; gap: 2rem; align-items: center; }
.nav-links a { text-decoration: none; color: #94a3b8; font-size: 0.95rem; transition: 0.3s; }
.nav-links a:hover { color: #fff; }

.btn-nav { background: var(--primary); color: white !important; padding: 0.6rem 1.2rem; border-radius: 12px; }

.menu-toggle { display: none; cursor: pointer; flex-direction: column; gap: 5px; }
.bar { width: 25px; height: 3px; background: white; transition: 0.4s; border-radius: 2px; }

/* Hero con Video */
.hero { 
    height: 100vh; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    text-align: center; 
    position: relative;
    overflow: hidden;
}

.hero-video-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(11, 15, 26, 0.7) 0%,
        rgba(11, 15, 26, 0.5) 50%,
        rgba(11, 15, 26, 0.9) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 1;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.hero h1 { font-size: clamp(2.5rem, 8vw, 4.5rem); line-height: 1.1; margin-bottom: 10px; }
.hero p { font-size: 1.1rem; color: #94a3b8; max-width: 500px; margin-bottom: 10px; }
.gradient-text { background: linear-gradient(to right, #818cf8, #c084fc); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

.cta-main { 
    display: inline-block;
    text-decoration: none; 
    color: #fff; 
    border: 1px solid var(--primary); 
    padding: 1rem 2rem; 
    border-radius: 50px; 
    transition: 0.3s; 
    margin-top: 10px;
}
.cta-main:hover { background: var(--primary); box-shadow: 0 0 20px rgba(99, 102, 241, 0.4); }

/* Servicios */
.section { padding: 80px 5%; max-width: 1200px; margin: 0 auto; }
.section-title { font-size: 2.5rem; text-align: center; margin-bottom: 50px; }
.grid-services { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }

.card { padding: 2.5rem; text-align: center; display: flex; flex-direction: column; align-items: center; }
.card i { width: 45px; height: 45px; color: var(--primary); margin-bottom: 1.5rem; }
.card h3 { margin-bottom: 0.5rem; }
.card p { color: #94a3b8; margin-bottom: 1rem; }

.service-question {
    margin: 1rem 0;
    width: 100%;
}

.why-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: transparent;
    border: 1px dashed var(--border);
    color: #94a3b8;
    padding: 0.6rem 1rem;
    border-radius: 10px;
    cursor: pointer;
    transition: 0.3s;
    font-size: 0.85rem;
    width: 100%;
}

.why-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.why-btn i {
    width: 16px;
    height: 16px;
    margin: 0;
}

.btn-service { 
    margin-top: auto;
    background: transparent; 
    border: 1px solid var(--border); 
    color: #fff; 
    padding: 0.6rem 1.5rem; 
    border-radius: 10px; 
    cursor: pointer; 
    transition: 0.3s; 
}
.btn-service:hover { background: #25D366; border-color: #25D366; color: #000; }

/* Modal de Beneficios */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    opacity: 0;
    visibility: hidden;
    transition: 0.3s;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    max-width: 500px;
    width: 90%;
    padding: 2.5rem;
    position: relative;
    transform: scale(0.9);
    transition: 0.3s;
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    transition: 0.3s;
}

.modal-close:hover {
    color: #fff;
}

.modal-close i {
    width: 24px;
    height: 24px;
}

#modal-title {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.benefits-list {
    list-style: none;
    margin-bottom: 2rem;
}

.benefits-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0.8rem 0;
    border-bottom: 1px solid var(--border);
    color: #e2e8f0;
}

.benefits-list li:last-child {
    border-bottom: none;
}

.benefits-list li::before {
    content: '✓';
    color: #25D366;
    font-weight: bold;
    font-size: 1.1rem;
}

.btn-modal-cta {
    width: 100%;
    padding: 1rem;
    background: #25D366;
    border: none;
    border-radius: 12px;
    color: #000;
    font-weight: 700;
    cursor: pointer;
    transition: 0.3s;
}

.btn-modal-cta:hover {
    background: #128C7E;
    color: #fff;
}

/* Blog con Expansión */
.grid-blog { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.blog-card { overflow: hidden; height: fit-content; }
.blog-img { height: 180px; background-size: cover; background-position: center; }
.blog-content { padding: 1.5rem; position: relative; }

.text-container {
    max-height: 80px;
    overflow: hidden;
    position: relative;
    transition: max-height 0.5s ease-in-out;
}

.fade-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40px;
    background: linear-gradient(transparent, var(--bg));
    pointer-events: none;
    transition: 0.3s;
}

.blog-card.expanded .text-container { max-height: 500px; }
.blog-card.expanded .fade-overlay { opacity: 0; }

.expand-btn {
    background: none;
    border: none;
    color: var(--primary);
    cursor: pointer;
    display: block;
    margin: 10px auto 0;
    transition: 0.3s;
}

.blog-card.expanded .expand-btn { transform: rotate(180deg); }

/* Equipo */
.bg-dark { background: rgba(0, 0, 0, 0.3); max-width: 100%; padding: 80px 5%; }
.bg-dark .section-title, .bg-dark .grid-team { max-width: 1200px; margin: 0 auto; }
.grid-team { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.team-card { padding: 2rem; text-align: center; }
.member-img { width: 100px; height: 100px; border-radius: 50%; margin: 0 auto 1rem; background-size: cover; border: 2px solid var(--primary); }

/* Contacto */
.contact-container { max-width: 600px; margin: 0 auto; padding: 3rem; }

.contact-header {
    text-align: center;
    margin-bottom: 2rem;
}

.contact-header h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.contact-header p {
    color: #94a3b8;
    font-size: 0.95rem;
}

input, textarea { 
    width: 100%; 
    padding: 1rem; 
    background: rgba(255,255,255,0.03); 
    border: 1px solid var(--border); 
    border-radius: 12px; 
    color: #fff; 
    margin-bottom: 1rem; 
    font-size: 1rem;
}

input::placeholder, textarea::placeholder {
    color: #64748b;
}

input:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.phone-input-container {
    display: flex;
    gap: 10px;
    margin-bottom: 1rem;
}

.country-select-wrapper {
    flex-shrink: 0;
}

.country-select {
    padding: 1rem;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: #fff;
    font-size: 1rem;
    cursor: pointer;
    min-width: 120px;
}

.country-select:focus {
    outline: none;
    border-color: var(--primary);
}

.country-select option {
    background: var(--bg);
    color: #fff;
}

.phone-input-container input {
    margin-bottom: 0;
    flex: 1;
}

.btn-send { 
    width: 100%; 
    padding: 1rem; 
    background: var(--primary); 
    border: none; 
    border-radius: 12px; 
    color: white; 
    font-weight: 700; 
    cursor: pointer; 
    transition: 0.3s;
    font-size: 1rem;
}

.btn-send:hover {
    background: var(--accent);
    box-shadow: 0 0 20px rgba(168, 85, 247, 0.4);
}

/* Footer */
.footer { text-align: center; padding: 2rem; color: #64748b; font-size: 0.9rem; }

/* Responsive */
@media (max-width: 768px) {
    .menu-toggle { display: flex; }
    
    .nav-links {
        position: absolute;
        top: 80px;
        right: -100%;
        flex-direction: column;
        background: rgba(11, 15, 26, 0.95);
        backdrop-filter: blur(20px);
        width: 100%;
        padding: 2rem;
        border-radius: 20px;
        transition: 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    }
    
    .nav-links.active { right: 0; }
    
    .grid-team { grid-template-columns: 1fr; }
    
    .hero h1 { font-size: 2.8rem; }
    
    .hero-content {
        padding: 0 15px;
    }
    
    .contact-container {
        padding: 2rem 1.5rem;
    }
    
    .contact-header h2 {
        font-size: 1.5rem;
    }
    
    .phone-input-container {
        flex-direction: column;
    }
    
    .country-select {
        width: 100%;
    }
    
    .modal-content {
        padding: 1.5rem;
    }
    
    #modal-title {
        font-size: 1.25rem;
    }
    
    .logo-img {
        width: 30px;
        height: 30px;
    }
    
    .logo {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .hero h1 { font-size: 2rem; }
    .hero p { font-size: 0.95rem; }
    
    .section-title { font-size: 2rem; }
    
    .card { padding: 1.5rem; }
    
    .why-btn {
        font-size: 0.8rem;
        padding: 0.5rem 0.8rem;
    }
}