/**
 * 🏛️ MARCO CMS - TEMA SOBERANO
 * Mobile-First | Dual Mode | Premium Elegance
 */

/* LIBRERIA SOBERANA: @import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600&display=swap'); */

:root {
    /* 🎨 PALETA SOBERANA */
    --color-primary: #3b82f6;
    --color-primary-dark: #2563eb;
    --color-secondary: #8b5cf6;
    --color-accent: #3b82f6;

    /* 🌐 SUPERFICIES */
    --color-bg: #f8fafc;
    --color-surface: #ffffff;
    --color-text: #0f172a;
    --color-text-secondary: #64748b;
    --color-text-muted: #94a3b8;
    --color-text-inverse: #ffffff;
    --color-border: rgba(0, 0, 0, 0.05);

    /* 🔮 EFECTOS */
    --accent-soft: rgba(59, 130, 246, 0.1);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);

    /* 📐 GEOMETRÍA */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    /* 🎭 TIPOGRAFÍA */
    --font-display: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* ⚡ TRANSICIONES */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 🌑 MODO OSCURO */
@media (prefers-color-scheme: dark) {
    :root {
        --color-bg: #0f172a;
        --color-surface: #1e293b;
        --color-text: #f8fafc;
        --color-text-secondary: #94a3b8;
        --color-text-muted: #64748b;
        --color-border: rgba(255, 255, 255, 0.05);
        --accent-soft: rgba(96, 165, 250, 0.1);
        --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
    }
}

/* 🛡️ RESET UNIVERSAL */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-text);
    background: var(--color-bg);
    transition: var(--transition);
}

/* 🏗️ LAYOUT CONTAINERS */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

@media (min-width: 768px) {
    .container {
        padding: 0 2rem;
    }
}

/* 🌋 HERO SECTION - IMPACTO VISUAL */
.hero {
    min-height: 85vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 3rem 1.5rem;
    position: relative;
    overflow: hidden;
    background: radial-gradient(circle at 50% 50%, var(--accent-soft) 0%, transparent 80%);
}

/* Resplandor de fondo */
.hero::before {
    content: '';
    position: absolute;
    width: 600px;
    height: 600px;
    background: var(--color-accent);
    filter: blur(150px);
    opacity: 0.05;
    border-radius: 50%;
    z-index: -1;
}

.hero h1 {
    font-family: var(--font-display);
    font-size: clamp(3rem, 10vw, 5rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--color-text) 0%, var(--color-accent) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: clamp(1rem, 4vw, 1.2rem);
    color: var(--color-text-secondary);
    max-width: 700px;
    margin: 0 auto 3rem;
    line-height: 1.75;
}

.hero .btn {
    padding: 1rem 3rem;
    font-size: 1.1rem;
    border-radius: var(--radius-full);
    box-shadow: 0 10px 20px -5px var(--accent-soft);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

/* 🔝 HEADER - Ultra Minimalist (Restaurado) */
.site-header {
    height: 60px;
    /* Altura cómoda */
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    position: sticky;
    top: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--color-border);
    width: 100%;
    padding: 0 !important;
    /* Sobreescribir resets globales */
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    width: 100%;
}

.site-logo {
    font-size: 1.1rem;
    font-weight: 700;
    font-family: var(--font-display);
    color: var(--color-text);
    text-decoration: none;
}

.main-nav {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    text-decoration: none;
    color: var(--color-text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: var(--color-primary);
}

/* 🎯 BOTONES */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-family: var(--font-display);
    font-weight: 500;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    font-size: 1rem;
}

.btn-primary {
    background: var(--color-primary);
    color: var(--color-text-inverse);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

/* 📦 CARDS */
.card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
    border-color: var(--color-accent);
}

/* 🖋️ TIPOGRAFÍA */
.heading-1 {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 8vw, 4rem);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

.heading-2 {
    font-family: var(--font-display);
    font-size: clamp(2rem, 6vw, 3rem);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.25rem;
}

.heading-3 {
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 5vw, 2.25rem);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
}

.text-body {
    font-size: 1.125rem;
    line-height: 1.75;
    color: var(--color-text-secondary);
}

.text-lead {
    font-size: 1.25rem;
    line-height: 1.75;
    color: var(--color-text-secondary);
}

/* 🦶 FOOTER */
.site-footer {
    border-top: 1px solid var(--color-border);
    padding: 3rem 1rem;
    text-align: center;
    color: var(--color-text-muted);
    font-size: 0.875rem;
}

/* 🎨 UTILIDADES */
.text-center {
    text-align: center !important;
}

.text-left {
    text-align: left !important;
}

.text-right {
    text-align: right !important;
}

.text-primary {
    color: var(--color-primary) !important;
}

.text-secondary {
    color: var(--color-text-secondary) !important;
}

.text-muted {
    color: var(--color-text-muted) !important;
}

.bg-primary {
    background-color: var(--color-primary) !important;
}

.bg-surface {
    background-color: var(--color-surface) !important;
}

.rounded {
    border-radius: var(--radius-md) !important;
}

.rounded-lg {
    border-radius: var(--radius-lg) !important;
}

.rounded-full {
    border-radius: var(--radius-full) !important;
}

.shadow {
    box-shadow: var(--shadow-md) !important;
}

.shadow-lg {
    box-shadow: var(--shadow-lg) !important;
}

/* 📐 SPACING */
.p-xs {
    padding: 0.5rem !important;
}

.p-sm {
    padding: 1rem !important;
}

.p-md {
    padding: 1.5rem !important;
}

.p-lg {
    padding: 2rem !important;
}

.p-xl {
    padding: 3rem !important;
}

.m-xs {
    margin: 0.5rem !important;
}

.m-sm {
    margin: 1rem !important;
}

.m-md {
    margin: 1.5rem !important;
}

.m-lg {
    margin: 2rem !important;
}

.m-xl {
    margin: 3rem !important;
}

/* 🔲 LAYOUT */
.flex {
    display: flex !important;
}

.flex-center {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.flex-between {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
}

.grid {
    display: grid !important;
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)) !important;
    gap: 2rem;
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)) !important;
    gap: 2rem;
}

/* 📱 RESPONSIVE */
@media (max-width: 768px) {
    .hero {
        min-height: 70vh;
        padding: 2rem 1rem;
    }

    .hero h1 {
        font-size: clamp(2.5rem, 8vw, 3.5rem);
    }

    .container {
        padding: 0 1rem;
    }
}

/*  HERO TECHNICAL FIX */
.hero-technical {
    padding: 8rem 2rem 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

.hero-technical h1 {
    color: var(--color-text);
    font-family: var(--font-display);
    font-size: clamp(3rem, 8vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 2rem;
}

/* 🎓 ACADEMIA STYLES - Mobile First, Minimalista, Sofisticado */

/* HERO ACADEMIA: Estructura Dual (Cover + Texto) */

/* 1. SECCIÓN SUPERIOR: Imagen y Título */
#hero-cover {
    min-height: 50vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    /* Título abajo */
    padding: 2rem 0 3rem 0;
    background-image: url('../media/academiagestasai.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    text-align: center;
    width: 100%;
}

/* Container del Cover */
#hero-cover .container {
    max-width: 100%;
    position: relative;
    z-index: 2;
    padding: 0 2rem;
}

/* Overlay Oscuro sobre la imagen */
#hero-cover::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Degradado sutil para que el título resalte pero se vea la imagen */
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.6) 100%);
    z-index: 1;
    pointer-events: none;
}

#hero-main-title {
    font-family: var(--font-display);
    font-size: clamp(3rem, 7vw, 5.5rem);
    /* Título imponente */
    font-weight: 800;
    margin: 0;
    color: white !important;
    position: relative;
    z-index: 2;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    line-height: 1.1;
}

/* 2. SECCIÓN INFERIOR: Texto Descriptivo */
#hero-description {
    background-color: white;
    padding: 4rem 2rem;
    text-align: center;
    border-bottom: 1px solid var(--color-border);
}

#hero-description .container {
    max-width: 900px;
    margin: 0 auto;
}

#hero-philosophy-text {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    line-height: 1.8;
    color: #444 !important;
    /* Gris oscuro elegante */
    font-weight: 400 !important;
    margin: 0 auto;
}

/* Limpieza de selectores obsoletos */
#hero-academia-section,
#hero-bg-image {
    display: none !important;
}

/* Secciones */
.section {
    padding: 5rem 2rem;
}

.section-premium {
    background: linear-gradient(135deg, var(--accent-soft) 0%, transparent 100%);
}

.section-pricing {
    background: var(--color-surface);
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
}

/* Roadmap Cards con Acentos Dinámicos */
.card-roadmap {
    position: relative;
    padding: 0;
    min-height: 400px;
    /* Altura consistente */
    display: flex;
    flex-direction: column;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    /* Borde base sutil */
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Imagen superior */
.card-roadmap .card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid var(--color-border);
}

/* Contenido interno */
.roadmap-content {
    padding: 2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

/* Uso de variable CSS para el acento personalizado */
.card-roadmap[style*="--card-accent"] {
    border-color: var(--card-accent);
    /* Sombra base muy sutil con el color teñido */
    box-shadow: 0 4px 20px -10px var(--card-accent);
}

.card-roadmap[style*="--card-accent"]:hover {
    transform: translateY(-8px);
    /* Sombra hover más pronunciada pero elegante */
    box-shadow: 0 15px 30px -10px var(--card-accent);
}

.roadmap-badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: var(--color-bg);
    /* Fondo neutro */
    color: var(--color-text);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
    align-self: flex-start;
}

/* Si la tarjeta tiene acento, colorear el badge también */
.card-roadmap[style*="--card-accent"] .roadmap-badge {
    color: var(--card-accent);
    border-color: var(--card-accent);
    background: white;
}

.card-roadmap .card-title {
    font-size: clamp(1.2rem, 3vw, 1.4rem);
    margin-bottom: 1rem;
    color: var(--color-text);
    font-weight: 700;
    line-height: 1.3;
}

.card-roadmap .card-text {
    color: var(--color-text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
    font-weight: 400;
}

/* Premium Cards */
.card-premium {
    background: linear-gradient(135deg, var(--color-surface) 0%, var(--accent-soft) 100%);
    border: 2px solid var(--color-border);
    padding: 2.5rem 2rem;
    text-align: center;
    transition: var(--transition);
    min-height: 180px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.card-premium:hover {
    border-color: var(--color-accent);
    transform: translateY(-6px);
}

.premium-badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: var(--color-secondary);
    color: white;
    border-radius: var(--radius-sm);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.card-premium .card-title {
    font-size: clamp(1.15rem, 2.5vw, 1.4rem);
    font-weight: 700;
    color: var(--color-text);
    line-height: 1.4;
}

/* Ethics Section */
.ethics-text {
    max-width: 900px;
    margin: 2rem auto 0;
    line-height: 1.9;
    font-size: clamp(1.05rem, 2.5vw, 1.2rem);
    color: var(--color-text-secondary);
    padding: 0 2rem;
    font-weight: 400;
}

/* 🎠 PREMIUM CAROUSEL - ELEGANT SLIDER */
.premium-carousel {
    max-width: 1100px;
    margin: 4rem auto 0;
    position: relative;
}

/* TRACK DESLIZANTE */
.carousel-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    /* Suavidad en iOS */
    gap: 0;
    border-radius: var(--radius-xl);
    background: var(--color-surface);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--color-border);
    /* Ocultar barra scroll */
    scrollbar-width: none;
    /* Firefox */
}

.carousel-track::-webkit-scrollbar {
    display: none;
    /* Chrome/Safari */
}

/* DIAPOSITIVA INDIVIDUAL */
.carousel-slide {
    flex: 0 0 100%;
    /* Cada slide ocupa 100% ancho */
    scroll-snap-align: start;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    /* Texto más ancho que imagen */
    align-items: center;
    padding: 4rem 5rem;
    gap: 4rem;
    box-sizing: border-box;
}

/* CONTENIDO TEXTO (Izquierda) */
.slide-content {
    text-align: left;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1.5rem;
}

/* BADGE FECHA */
.slide-badge {
    background-color: #7c3aed;
    /* Púrpura vibrante */
    color: white;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    padding: 0.5rem 1.2rem;
    border-radius: 6px;
    align-self: flex-start;
    display: inline-block;
    margin-bottom: 0.5rem;
    box-shadow: 0 4px 10px rgba(124, 58, 237, 0.3);
}

/* TÍTULO SLIDE */
.slide-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 2.75rem);
    font-weight: 700;
    line-height: 1.15;
    color: var(--color-text);
    margin: 0;
}

/* DESCRIPCIÓN SLIDE */
.slide-description {
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--color-text-secondary);
    font-weight: 400;
    max-width: 90%;
}

/* IMAGEN (Derecha) */
.slide-image {
    width: 100%;
    height: auto;
    max-height: 500px;
    object-fit: contain;
    border-radius: var(--radius-lg);
    /* Sombra suave para la imagen */
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.1));
    transition: transform 0.5s ease;
}

/* Hover effect sutil en imagen */
.carousel-slide:hover .slide-image {
    transform: scale(1.02);
}

/* NAVEGACIÓN (Thumbnails) */
.carousel-nav {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
    padding-bottom: 2rem;
}

.nav-dot {
    width: 60px;
    /* Miniatura rectangular pequeña */
    height: 60px;
    background-size: cover;
    background-position: center;
    border-radius: 8px;
    cursor: pointer;
    opacity: 0.5;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    font-size: 0;
    /* Ocultar texto */
    background-color: #ddd;
    /* Placeholder */
}

/* Estilos específicos para cada dot usando nth-child para robustez */
.nav-dot:nth-child(1) {
    background-image: url('../media/promptengineering.jpg');
}

.nav-dot:nth-child(2) {
    background-image: url('../media/eticallm.jpg');
}

.nav-dot:nth-child(3) {
    background-image: url('../media/iaaplicadanegocios.jpg');
}

.nav-dot:nth-child(4) {
    background-image: url('../media/entornoempresarial.jpg');
}

.nav-dot:hover,
.nav-dot:active {
    opacity: 1;
    border-color: var(--color-primary);
    transform: translateY(-2px);
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .premium-carousel {
        margin: 2rem auto;
    }

    .carousel-slide {
        grid-template-columns: 1fr;
        /* Columna única en móviles */
        padding: 2rem;
        gap: 2rem;
        text-align: center;
    }

    .slide-content {
        order: 2;
        /* Texto abajo */
        align-items: center;
        /* Centrar contenidos */
        text-align: center;
    }

    .slide-image {
        order: 1;
        /* Imagen arriba */
        max-height: 300px;
    }

    .slide-badge {
        align-self: center;
    }
}

/* Pricing Cards */
.pricing-grid {
    max-width: 1100px;
    margin: 3rem auto 0;
    gap: 2rem;
}

.card-pricing {
    padding: 3rem 2.5rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    background: var(--color-bg);
    border: 2px solid var(--color-border);
    transition: var(--transition);
}

.card-pricing:hover {
    border-color: var(--color-accent);
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.card-pricing-featured {
    background: linear-gradient(135deg, var(--accent-soft) 0%, var(--color-bg) 100%);
    border-color: var(--color-accent);
    position: relative;
}

.card-pricing-featured::before {
    content: 'POPULAR';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--color-accent);
    color: white;
    padding: 0.4rem 1.5rem;
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.pricing-title {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--color-text);
    margin: 0;
}

.pricing-amount {
    font-family: var(--font-display);
    font-size: clamp(3.5rem, 8vw, 4.5rem);
    font-weight: 800;
    color: var(--color-accent);
    line-height: 1;
}

.pricing-note {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    font-style: italic;
    margin: -1rem 0 0;
    font-weight: 400;
}

.pricing-features {
    color: var(--color-text-secondary);
    line-height: 2;
    font-size: 0.95rem;
    text-align: left;
    padding-left: 1.5rem;
    font-weight: 400;
}

.card-pricing .btn {
    margin-top: auto;
    width: 100%;
    justify-content: center;
    padding: 1.1rem;
    font-weight: 600;
    font-size: 1rem;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .hero-academia {
        min-height: auto;
        padding-top: 4rem;
    }

    .hero-academia .hero-image {
        height: 40vh;
        margin-bottom: 2rem;
    }

    .section {
        padding: 3.5rem 1.5rem;
    }

    .grid-3 {
        grid-template-columns: 1fr !important;
        gap: 1.5rem;
    }

    .grid-2 {
        grid-template-columns: 1fr !important;
        gap: 1.5rem;
    }

    .card-roadmap {
        min-height: auto;
    }

    .pricing-grid {
        gap: 2rem;
    }
}

@media (min-width: 769px) {
    .hero-academia .hero-image {
        max-width: 100%;
    }

    .section {
        padding: 6rem 3rem;
    }

    .grid-3 {
        gap: 2.5rem;
    }
}