/* Variables Globales para diseño Premium (Brandbook MEDITECH) */
:root {
    --bg-color: #F8F9FA; /* Blanco grisáceo muy claro */
    --text-main: #3A3A36; /* Gris muy oscuro, casi negro */
    --text-muted: #6B7280; /* Gris intermedio para textos secundarios */
    --primary-color: #2C7EBD; /* Azul Principal (Pantone 7689 C) */
    --primary-hover: #1f5c8f; /* Tono hover más oscuro del azul principal */
    --accent-cyan: #46ABBE; /* Azul Claro/Cian (Pantone 631 C) */
    --accent-red: #A4001D; /* Rojo Acento (Pantone 7621 C) */
    --border-color: #E5E7EB; /* Borde sutil */
}

/* Reseteo básico y Box Sizing */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Century Gothic', 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased; /* Suavizado vital para ese look "premium" */
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

/* Detalle visual sutil de fondo (Eliminado por reglas de no uso de gradientes) */

/* Header / Navbar Minimalista (Rescate del Header) */
.navbar {
    padding: 20px 48px;
    position: fixed; /* Se mantiene estático y siempre visible */
    top: 0;
    width: 100%;
    z-index: 100; /* Aseguramos que siempre sobresalga */
    background-color: #ffffff; /* Fondo blanco sólido permanente */
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05); /* Sombra sutil y elegante */
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-link {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.logo-img {
    height: 65px; /* Altura ideal para mantener el diseño minimalista */
    width: auto;
    object-fit: contain;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.logo-link:hover .logo-img {
    transform: scale(1.02);
}

/* Enlaces de Navegación Menu Desktop */
.nav-links {
    display: flex;
    gap: 36px;
    align-items: center;
}

.nav-item {
    text-decoration: none;
    color: var(--text-main);
    font-size: 15px;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-item:hover {
    color: var(--primary-color);
}

.nav-btn {
    background-color: var(--primary-color);
    color: white;
    padding: 10px 24px;
    border-radius: 6px; /* Borde sutilmente redondeado (no estilo píldora total) */
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.nav-btn:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
}

/* Menú Móvil Hamburger - Oculto en Escritorio */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-main);
    cursor: pointer;
}

/* Configuración de la sección Hero */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 120px 24px 60px;
    width: 100%;
}

/* Fondos y Superposición */
.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -2;
}

.hero-bg.active {
    opacity: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Overlay oscuro estricto basado en Gris Oscuro Oficial #3A3A36 */
    background: linear-gradient(
        to bottom,
        rgba(58, 58, 54, 0.6) 0%,
        rgba(58, 58, 54, 0.8) 100%
    );
    z-index: -1;
}

.hero-content {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    z-index: 2;
    /* Para transiciones via JS */
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.hero-content.fade-out {
    opacity: 0;
    transform: translateY(15px);
}

.hero-content.fade-in {
    opacity: 1;
    transform: translateY(0);
}

/* Animación de entrada inicial suave */
.fadeUp-initial {
    animation: fadeUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
    transform: translateY(30px);
}

/* Etiqueta de los 3 Pilares - Look de Startup Tech */
.badge {
    display: inline-flex;
    align-items: center;
    font-size: 13px;
    font-weight: 600;
    color: white;
    background-color: var(--primary-color);
    padding: 8px 18px;
    border-radius: 30px;
    margin-bottom: 32px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

/* Tipografía Principal gigante, muchísimo espacio */
.hero-title {
    font-size: clamp(44px, 6vw, 84px);
    font-weight: 800; /* Aumentado a 800 para que brille y el contraste sea masivo */
    letter-spacing: -0.04em;
    line-height: 1.05;
    margin-bottom: 24px;
    color: #ffffff; /* Texto blanco en contraste dramático */
}

.hero-title .title-highlight {
    color: var(--primary-color);
}

/* Descripción sutil */
.hero-description {
    font-size: clamp(18px, 2vw, 24px);
    font-weight: 400;
    color: rgba(255, 255, 255, 0.9); /* Blanco ligeramente atenuado */
    max-width: 680px;
    margin: 0 auto 48px;
    line-height: 1.4;
}

/* Contenedor Botones */
.hero-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Estilos de botones modernos y redondeados */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 32px;
    font-size: 17px;
    font-weight: 600;
    border-radius: 980px; /* Estilo píldora 100% redondeado */
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
}

/* Botón Principal - Flat Design */
.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: scale(1.02);
}

/* Botón Secundario tipo Ghost/Borde */
.btn-secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background-color: white;
    color: var(--text-main);
    transform: scale(1.02);
}

/* Indicadores Interactivos */
.hero-indicators {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 3;
}

.indicator {
    width: 24px;
    height: 4px;
    background-color: var(--border-color);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.indicator:hover {
    background-color: var(--text-muted);
}

.indicator.active {
    background-color: var(--primary-color);
    width: 48px;
}

/* Animaciones */
@keyframes meditechFadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fadeUp-initial {
    animation: meditechFadeUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
    transform: translateY(30px);
}

/* ============================================== */
/* SECCIÓN: NUESTROS PILARES (SERVICIOS)          */
/* ============================================== */

.services-section {
    padding: 120px 24px;
    background-color: #ffffff; /* Fondo blanco inmaculado por reglas premium */
    text-align: center;
}

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

.section-header {
    margin-bottom: 72px;
}

.section-title {
    font-size: clamp(32px, 4vw, 42px);
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.02em;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 18px;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

/* Grilla de 3 columnas para servicios */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

/* Diseño de Tarjetas Minimalistas */
.service-card {
    background-color: #ffffff;
    padding: 56px 40px;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.04); /* Borde gris ultra fino premium */
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.02); /* Sombra levísima */
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease;
    text-align: left;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

/* Sutil elevación al pasar el mouse SIN rebote brusco */
.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.05); /* Sombra un poco más profunda pero suave */
}

/* Contenedor del ícono */
.service-icon-wrapper {
    background-color: var(--bg-color); /* Fondo gris clarito corporativo */
    width: 64px;
    height: 64px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 32px;
}

/* Ícono - Color principal corporativo adaptado para etiquetas IMG (.service-icon) */
.service-icon {
    filter: invert(41%) sepia(87%) saturate(591%) hue-rotate(170deg) brightness(88%) contrast(85%); /* #2C7EBD */
    transition: filter 0.4s ease;
}

/* Hover de tarjeta -> El SVG se vuelve cyan claro suavemente (#46ABBE) */
.service-card:hover .service-icon {
    filter: invert(56%) sepia(50%) saturate(415%) hue-rotate(143deg) brightness(96%) contrast(88%);
}

.service-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 16px;
}

.service-text {
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-muted);
}

/* Responsividad para móviles y tablets */
@media (max-width: 900px) {
    .navbar {
        padding: 24px 24px;
    }
    .nav-links {
        display: none; /* Se ocultan los links en móvil de momento */
    }
    .menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }    
}

@media (max-width: 768px) {
    .badge {
        font-size: 11px;
    }
    .badge .dot {
        margin: 0 6px;
    }
    .services-list {
        display: none;
    }
    .hero-buttons {
        flex-direction: column;
        width: 100%;
        max-width: 320px;
        margin: 0 auto;
    }
    .btn {
        width: 100%;
    }
    .services-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    .service-card {
        padding: 40px 32px;
        align-items: center;
        text-align: center;
    }
}

/* ============================================== */
/* MEDIKA LANDING PAGE STYLES                     */
/* ============================================== */

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

.bg-light {
    background-color: #F8F9FA; /* Gris ultra claro estipulado */
}

.medika-section {
    padding: 100px 0;
    background-color: #ffffff;
}

/* Medika Hero */
.medika-hero {
    position: relative;
    padding: 180px 24px 100px;
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.medika-hero-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-size: cover;
    background-position: center;
    z-index: -2;
}

.medika-hero-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(44, 126, 189, 0.85); /* Azul Principal Oficial con opacidad */
    z-index: -1;
}

.medika-hero-content {
    max-width: 900px;
    z-index: 2;
}

.medika-hero-title {
    font-size: clamp(36px, 5vw, 64px);
    font-weight: 800;
    color: #ffffff;
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -0.03em;
}

.medika-hero-subtitle {
    font-size: clamp(18px, 2vw, 22px);
    font-weight: 400;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.5;
    max-width: 800px;
    margin: 0 auto;
}

/* Benefits Grid (Flotantes, sin borde) */
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 40px; /* Mayor respiro */
}

.benefit-card {
    background-color: transparent;
    padding: 24px;
    border-radius: 12px;
    text-align: left;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.benefit-card:hover {
    transform: translateY(-8px);
    background-color: #ffffff;
    box-shadow: 0 16px 40px rgba(0,0,0,0.06); /* Efecto flotante */
}

.benefit-icon-wrapper {
    background-color: rgba(44, 126, 189, 0.08);
    width: 64px; height: 64px;
    border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 32px;
    color: var(--primary-color);
}

.benefit-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-main);
}

/* ============================================== */
/* PRICING CARDS - PREMIUM SAAS STYLE             */
/* ============================================== */

.pricing-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    align-items: center;
    margin-top: 64px;
}

.pricing-card {
    background: #ffffff;
    border-radius: 24px;
    padding: 48px 40px;
    box-shadow: 0 12px 32px rgba(0,0,0,0.04);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.pricing-card.highlighted {
    transform: scale(1.05); /* Ligeramente más grande */
    box-shadow: 0 24px 64px rgba(44, 126, 189, 0.12); /* Sombra difuminada mas amplia */
    border-top: 6px solid var(--primary-color); /* Borde superior grueso */
    z-index: 2;
}

.pricing-card:not(.highlighted):hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 48px rgba(0,0,0,0.08);
}

.popular-badge {
    position: absolute;
    top: -18px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-color);
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
    padding: 8px 20px;
    border-radius: 40px;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 12px rgba(44, 126, 189, 0.3);
}

.pricing-header {
    text-align: center;
    margin-bottom: 32px;
    padding-bottom: 32px;
    border-bottom: 1px solid rgba(0,0,0,0.06);
}

.plan-name {
    font-size: 22px;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 16px;
}

.plan-price {
    font-size: 56px;
    font-weight: 800;
    color: var(--text-main); /* Tipografía oscura y grande */
    line-height: 1;
    letter-spacing: -2px;
}

.plan-price span {
    font-size: 18px;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: normal;
}

.plan-desc {
    font-size: 15px;
    color: var(--text-muted);
    margin-top: 16px;
    line-height: 1.5;
}

.plan-features {
    list-style: none;
    flex-grow: 1;
    margin-bottom: 40px;
}

.plan-features li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 20px;
    font-size: 16px;
    color: var(--text-main);
    line-height: 1.5;
}

.plan-features li strong {
    font-weight: 700;
}

.plan-features li.disabled {
    color: #a1a1aa;
}

.plan-features .check-icon {
    width: 20px;
    height: 20px;
    color: var(--primary-color);
    flex-shrink: 0;
    margin-top: 2px;
}

.plan-features .x-icon {
    width: 20px;
    height: 20px;
    color: #e4e4e7;
    flex-shrink: 0;
    margin-top: 2px;
}

.plan-savings {
    background-color: #F8F9FA;
    padding: 16px;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 24px;
}

.plan-savings p {
    font-size: 14px;
    color: var(--text-main);
    margin-bottom: 4px;
}

.savings-tag {
    display: inline-block;
    font-size: 13px;
    font-weight: 700;
    color: var(--accent-cyan);
    background: rgba(70, 171, 190, 0.1);
    padding: 4px 12px;
    border-radius: 16px;
}

/* Base styling outline btn added for cards */
.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: white;
}

/* Steps */
.steps-grid {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 32px;
    margin-top: 48px;
    position: relative;
}

.step-card {
    flex: 1;
    text-align: center;
    position: relative;
    z-index: 2;
}

.step-number {
    width: 64px;
    height: 64px;
    background-color: var(--primary-color);
    color: white;
    font-size: 24px;
    font-weight: 800;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    box-shadow: 0 8px 24px rgba(44, 126, 189, 0.3);
}

.step-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 12px;
}

.step-line {
    flex: 1;
    height: 2px;
    background: dashed 2px var(--border-color);
    margin-top: 32px;
}

/* FAQ Accordion */
.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-list {
    margin-top: 40px;
}

.faq-item {
    border-bottom: 1px solid var(--border-color);
}

.faq-btn {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0;
    background: none;
    border: none;
    font-size: 18px;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    text-align: left;
}

.faq-icon {
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

.faq-item.active .faq-icon {
    transform: rotate(180deg);
}

.faq-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.faq-content p {
    padding-bottom: 24px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Footer Global */
.footer {
    background-color: var(--text-main); /* Gris Oscuro Oficial #3A3A36 */
    color: #ffffff;
    padding: 80px 24px 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 64px;
}

.footer-logo {
    height: 48px;
    filter: brightness(0) invert(1);
    margin-bottom: 20px;
}

.footer-desc {
    font-size: 15px;
    line-height: 1.6;
    max-width: 300px;
}

.footer-heading {
    color: white;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 24px;
}

.footer-links p {
    display: block;
    color: #ffffff;
    margin-bottom: 12px;
    font-size: 15px;
}

.footer-links a {
    display: block;
    color: #ffffff;
    text-decoration: none;
    margin-bottom: 12px;
    font-size: 15px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 32px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 14px;
}

/* Desktop and mobile overrides specifically for Medika */
@media (max-width: 1024px) {
    .pricing-cards {
        grid-template-columns: repeat(2, 1fr);
    }
    .pricing-card.highlighted {
        grid-column: span 2;
        transform: scale(1); /* No scale on smaller screens */
        order: -1; /* Mover el plan popular al inicio en pantallas medianas */
    }
}

@media (max-width: 900px) {
    .step-line { display: none; }
    .steps-grid { flex-direction: column; }
    .footer-grid { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 768px) {
    .pricing-cards {
        grid-template-columns: 1fr;
    }
    .pricing-card.highlighted {
        grid-column: span 1;
    }
}
