:root {
    /* Tema oscuro azulado (Slate/Blue) */
    --bg-color: #0f172a; /* Slate 900 */
    --surface-color: #1e293b; /* Slate 800 */
    --text-primary: #f8fafc; /* Slate 50 */
    --text-secondary: #94a3b8; /* Slate 400 */
    --accent-color: #3b82f6; /* Blue 500 */
    --accent-hover: #2563eb; /* Blue 600 */
    --border-color: #334155; /* Slate 700 */
    --font-family: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-family);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Tipografía */
h1, h2, h3, h4 { color: var(--text-primary); font-weight: 700; }
.accent-text { color: var(--accent-color); }

/* Botones */
.btn-primary, .btn-primary-small, .btn-submit {
    background-color: var(--accent-color);
    color: #fff;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    display: inline-block;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    text-align: center;
}

.btn-primary-small { padding: 8px 16px; font-size: 0.9rem; }

.btn-primary:hover, .btn-primary-small:hover, .btn-submit:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* Navegación */
.navbar {
    background-color: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
}

.nav-container { display: flex; justify-content: space-between; align-items: center; height: 80px; }
.logo { font-size: 1.5rem; font-weight: 700; letter-spacing: -0.5px; }
.logo span { color: var(--accent-color); }
.nav-links { display: flex; gap: 30px; align-items: center; }
.nav-links a:not(.btn-primary-small):hover { color: var(--accent-color); }

/* Footer */
.footer {
    background-color: var(--surface-color);
    padding: 60px 0 20px;
    border-top: 1px solid var(--border-color);
}

.footer-container { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 40px; margin-bottom: 40px; }
.footer-brand h3 span { color: var(--accent-color); }
.footer-brand p, .footer-contact p { color: var(--text-secondary); margin-top: 10px; }
.footer-links ul { margin-top: 15px; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: var(--text-secondary); }
.footer-links a:hover { color: var(--accent-color); }
.footer-bottom { text-align: center; padding-top: 20px; border-top: 1px solid var(--border-color); color: var(--text-secondary); font-size: 0.9rem; }

/* Animaciones On-Scroll */
.reveal { opacity: 0; transform: translateY(30px); transition: all 0.8s ease-out; }
.reveal.active { opacity: 1; transform: translateY(0); }

/* Main Media Containers (Videos, Imagenes hero) 100% width, 50% height de pantalla */
.main-media-container { width: 100%; height: 50vh; overflow: hidden; margin-bottom: 40px; position: relative; background-color: var(--surface-color); }
.main-media-container video, .main-media-container img { width: 100%; height: 100%; object-fit: cover; }

/* Hero Section */
.hero { min-height: 50vh; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 0 0 50px 0; }
.hero-content { max-width: 800px; margin: 0 auto; padding: 0 20px; }
.hero h1 { font-size: 3.5rem; margin-bottom: 20px; line-height: 1.2; }
.hero p { font-size: 1.2rem; color: var(--text-secondary); margin-bottom: 40px; }

/* Secciones genéricas (About, Services, etc) */
.section-padding { padding: 80px 0; }
.section-title { text-align: center; font-size: 2.5rem; margin-bottom: 50px; }

/* Grillas Horizontales Antiguas */
.grid-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.card { background-color: var(--surface-color); border-radius: 12px; border: 1px solid var(--border-color); transition: transform 0.3s ease, box-shadow 0.3s ease; overflow: hidden; padding-bottom: 20px; }
.card img { width: 100%; height: 200px; object-fit: cover; border-bottom: 1px solid var(--border-color); margin-bottom: 20px; }
.card h3, .card p { padding: 0 20px; text-align: center; }
.card:hover { transform: translateY(-8px); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5); border-color: var(--accent-color); }
.card-desc { color: var(--text-secondary); margin-bottom: 20px; }

/* ===============================
   Services Grid (Feature Cards) 
   =============================== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.service-card {
    background-color: #0b1121;
    border-radius: 12px;
    border: 1px solid #1e293b;
    overflow: hidden;
    transition: transform 0.3s;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.service-card:hover {
    transform: translateY(-5px);
    border-color: #334155;
}

.service-img {
    height: 200px;
    width: 100%;
    overflow: hidden;
}

.service-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.8;
}

.service-content {
    padding: 30px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.service-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: 20px;
    width: fit-content;
}

.service-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: #fff;
}

.service-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 25px;
    flex: 1;
}

.service-features {
    list-style: none;
    margin: 0;
    padding: 0;
}

.service-features li {
    position: relative;
    padding-left: 18px;
    margin-bottom: 12px;
    color: #94a3b8;
    font-size: 0.9rem;
}

.service-features li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    width: 6px;
    height: 6px;
    background-color: #3b82f6;
    border-radius: 50%;
}

/* ===============================
   Pricing Grid (SaaS Style) 
   =============================== */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 80px;
    align-items: stretch;
}

.pricing-card {
    background-color: #0b1121; /* Slightly darker than surface */
    border: 1px solid #1e293b;
    border-radius: 16px;
    padding: 40px 30px;
    position: relative;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.pricing-card:hover {
    border-color: #334155;
}

.pricing-card.popular {
    border-color: var(--accent-color);
    box-shadow: 0 0 40px rgba(59, 130, 246, 0.15);
    background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%);
    transform: scale(1.03);
    z-index: 10;
}

.pricing-card.popular:hover { border-color: #60a5fa; }

.popular-badge {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent-color);
    color: #fff;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.pricing-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 10px;
    color: #fff;
}

.pricing-price {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 20px;
    color: #fff;
    display: flex;
    align-items: baseline;
    letter-spacing: -1px;
}

.pricing-price span {
    font-size: 1.1rem;
    font-weight: 400;
    color: var(--text-secondary);
    margin-left: 5px;
    letter-spacing: 0;
}

.pricing-desc {
    color: var(--text-secondary);
    margin-bottom: 30px;
    font-size: 0.95rem;
    line-height: 1.6;
}

.pricing-features {
    list-style: none;
    margin-bottom: 40px;
    flex: 1; /* Pushes the button to the bottom */
}

.pricing-features li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 16px;
    font-size: 0.95rem;
    color: #e2e8f0;
}

.check-icon {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233b82f6' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 12px;
    margin-right: 12px;
    flex-shrink: 0;
    margin-top: 2px;
    border-radius: 50%;
    background-color: rgba(59, 130, 246, 0.15);
}

/* ===============================
   Modal Form (Pop up) 
   =============================== */
.modal {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal.show-modal {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background-color: #0b1121;
    border: 1px solid #1e293b;
    border-radius: 16px;
    width: 90%;
    max-width: 500px;
    padding: 40px;
    position: relative;
    transform: translateY(-30px);
    transition: transform 0.3s ease;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.8);
}

.modal.show-modal .modal-content {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 25px;
    font-size: 2rem;
    line-height: 1;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.3s;
}

.close-modal:hover {
    color: #ef4444;
}
.btn-pricing {
    display: block;
    width: 100%;
    text-align: center;
    padding: 14px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    text-decoration: none;
    cursor: pointer;
}

.btn-pricing-outline {
    background-color: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
}
.btn-pricing-outline:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
}

.btn-pricing-solid {
    background: linear-gradient(90deg, #3b82f6 0%, #06b6d4 100%);
    color: #fff;
    border: none;
}
.btn-pricing-solid:hover {
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.3);
    transform: translateY(-2px);
}

/* Split Layout 2 Columnas */
.split-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; }

/* Formularios */
.form-container { max-width: 600px; margin: 0 auto; background-color: var(--surface-color); padding: 40px; border-radius: 12px; border: 1px solid var(--border-color); }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; color: var(--text-secondary); }
.form-control { width: 100%; padding: 12px 15px; border-radius: 8px; border: 1px solid var(--border-color); background-color: var(--bg-color); color: var(--text-primary); font-family: inherit; font-size: 1rem; transition: border-color 0.3s; }
.form-control:focus { outline: none; border-color: var(--accent-color); }
.form-submit { width: 100%; padding: 15px; font-size: 1.1rem; }
.form-errors { background-color: rgba(239, 68, 68, 0.1); color: #ef4444; padding: 15px; border-radius: 8px; margin-bottom: 20px; display: none; border: 1px solid rgba(239, 68, 68, 0.2); }

/* FAQ Acordeón */
.faq-container { width: 100%; }
.faq-item { background-color: var(--surface-color); border: 1px solid var(--border-color); border-radius: 8px; margin-bottom: 15px; overflow: hidden; }
.faq-question { padding: 20px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; font-weight: 600; transition: background-color 0.3s; }
.faq-question:hover { background-color: rgba(255, 255, 255, 0.05); }
.faq-icon { font-size: 1.2rem; transition: transform 0.3s; }
.faq-question.active .faq-icon { transform: rotate(45deg); }
.faq-answer { padding: 0 20px; max-height: 0; overflow: hidden; transition: max-height 0.3s ease-out, padding 0.3s ease; color: var(--text-secondary); }
.faq-question.active + .faq-answer { padding: 0 20px 20px 20px; }

/* Carrusel de proyectos */
.carousel-wrapper { overflow: hidden; position: relative; margin-top: 40px; }
.carousel-container { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 20px; padding: 20px 0; scroll-behavior: smooth; }
.carousel-container::-webkit-scrollbar { height: 8px; }
.carousel-container::-webkit-scrollbar-thumb { background: var(--accent-color); border-radius: 4px; }
.carousel-item { scroll-snap-align: center; flex: 0 0 min(100%, 350px); background-color: var(--surface-color); border-radius: 12px; border: 1px solid var(--border-color); overflow: hidden; transition: transform 0.3s ease; cursor: pointer; }
.carousel-item:hover { transform: translateY(-5px); border-color: var(--text-secondary); }
.carousel-item img { width: 100%; height: 220px; object-fit: cover; border-bottom: 1px solid var(--border-color); }
.carousel-item-info { padding: 20px; text-align: center; }

/* Contadores Animados */
.grid-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 30px; }
.stat-number { font-size: 3.5rem; font-weight: 700; margin-bottom: 5px; }
.stat-label { color: var(--text-secondary); font-size: 1.1rem; text-transform: uppercase; letter-spacing: 1px; font-weight: 600; }

/* Testimonios Slider */
.testimonials-wrapper { max-width: 800px; margin: 0 auto; text-align: center; position: relative; }
.testimonial-card { display: none; padding: 40px; background-color: var(--surface-color); border: 1px solid var(--border-color); border-radius: 12px; margin-bottom: 20px; animation: fadeIn 0.5s ease-out; }
.testimonial-card.active { display: block; }
.testimonial-text { font-size: 1.3rem; font-style: italic; margin-bottom: 20px; line-height: 1.8; color: var(--text-primary); }
.testimonial-author { color: var(--accent-color); font-weight: 600; }
.testimonial-controls { display: flex; justify-content: center; gap: 15px; }
.testi-btn { background-color: var(--bg-color); color: var(--accent-color); border: 1px solid var(--accent-color); width: 50px; height: 50px; border-radius: 50%; font-size: 1.5rem; cursor: pointer; transition: all 0.3s; display: flex; align-items: center; justify-content: center;}
.testi-btn:hover { background-color: var(--accent-color); color: #fff; transform: scale(1.1); }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive General */
@media (max-width: 768px) {
    .nav-links { display: none; }
    .hero h1 { font-size: 2.5rem; }
    .split-layout { grid-template-columns: 1fr; }
    .card-vertical { flex-direction: column; text-align: center; }
    .card-vertical img { width: 100%; height: auto; }
}
