/* ==========================================================================
   ARTESANÍA INKA ROCA - HOJA DE ESTILOS PRINCIPAL
   ========================================================================== */

/* Importar Fuentes Premium desde Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&display=swap');

/* -------------------------------------------------------------
   VARIABLES DE DISEÑO Y TEMAS (CLARO / OSCURO)
   ------------------------------------------------------------- */
:root {
    /* Tipografías */
    --font-heading: 'Playfair Display', Georgia, serif;
    --font-body: 'Outfit', system-ui, -apple-system, sans-serif;

    /* Colores Base de Acento (Andino y Natural) */
    --accent-gold: #987f4c;
    --accent-gold-rgb: 152, 127, 76;
    --accent-terracotta: #b85d43;
    --accent-terracotta-rgb: 184, 93, 67;

    /* Configuración por Defecto: TEMA CLARO (Marrón Dorado Suave / Arena) */
    --bg-primary: #f2ead8;
    /* Arena Cálida */
    --bg-secondary: #faf4e8;
    /* Crema Dorado Claro */
    --bg-tertiary: #e7dbbe;
    /* Arena Dorado de Contraste */
    --text-primary: #1c1c18;
    /* Carbón Oscuro */
    --text-secondary: #5a5a50;
    /* Gris Mate */
    --border-color: rgba(152, 127, 76, 0.2);
    --shadow-sm: 0 2px 8px rgba(152, 127, 76, 0.05);
    --shadow-md: 0 8px 30px rgba(152, 127, 76, 0.1);
    --shadow-lg: 0 16px 40px rgba(152, 127, 76, 0.15);
    --glass-bg: rgba(242, 234, 216, 0.85);
    --glass-border: rgba(152, 127, 76, 0.15);
}

/* Variables del TEMA OSCURO (Marrón Dorado Oscuro / Bronce) */
[data-theme="dark"] {
    --bg-primary: #1c1812;
    /* Café Oscuro Andino */
    --bg-secondary: #262018;
    /* Carbón Marrón Cálido */
    --bg-tertiary: #30291e;
    /* Bronce Oscuro Card */
    --text-primary: #f5f4f0;
    /* Hueso Claro */
    --text-secondary: #a5a49a;
    /* Gris Claro */
    --border-color: rgba(152, 127, 76, 0.3);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.5);
    --glass-bg: rgba(28, 24, 18, 0.85);
    --glass-border: rgba(152, 127, 76, 0.25);
}

/* Reset y Estilos Globales */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

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

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    line-height: 1.3;
}

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

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* -------------------------------------------------------------
   NAVBAR (CABECERA FLOTANTE GLASSMORPHISM)
   ------------------------------------------------------------- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 75px;
    z-index: 1000;
    background-color: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    transition: background-color 0.4s ease, border-color 0.4s ease;
}

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

.logo-link {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-img {
    height: 50px;
    width: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent-gold);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.logo-link:hover .logo-img {
    transform: rotate(360deg);
}

.brand-name {
    font-size: 1.3rem;
    letter-spacing: 1px;
    font-weight: 700;
    color: var(--text-primary);
}

.brand-name span {
    color: var(--accent-gold);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 0;
    align-items: center;
}

.nav-menu li {
    display: flex;
    align-items: center;
}

.nav-menu li:not(:last-child)::after {
    content: '';
    display: block;
    width: 1px;
    height: 14px;
    background-color: var(--accent-gold);
    opacity: 0.45;
    margin: 0 18px;
    pointer-events: none;
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    position: relative;
    padding: 5px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-gold);
    transition: width 0.3s ease;
}

.nav-link:hover {
    color: var(--accent-gold);
}

.nav-link:hover::after {
    width: 100%;
}

.theme-btn-container {
    display: flex;
    align-items: center;
}

.theme-btn {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    cursor: pointer;
    font-size: 1.1rem;
    padding: 8px 12px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.theme-btn:hover {
    background-color: var(--accent-gold);
    color: #ffffff;
    border-color: var(--accent-gold);
    transform: scale(1.1);
}

/* -------------------------------------------------------------
   SECCIÓN HERO (BIENVENIDA IMPACTANTE)
   ------------------------------------------------------------- */
.hero-section {
    position: relative;
    min-height: 100vh;
    padding-top: 75px;
    /* Altura Navbar */
    display: flex;
    align-items: center;
    color: #ffffff;
    overflow: hidden;
}

/* Carrusel de fondos */
.hero-slideshow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    will-change: transform;
}

.hero-slide {
    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.5s ease-in-out;
}

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

/* Filtro oscuro para contraste en lectura */
.hero-slideshow::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right,
            rgba(28, 28, 24, 0.85) 40%,
            rgba(28, 28, 24, 0.4) 100%);
    z-index: 2;
}

@media (max-width: 768px) {
    .hero-slideshow::after {
        background: rgba(28, 28, 24, 0.75);
    }
}

.hero-container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.hero-content {
    max-width: 650px;
}

.badge {
    background-color: rgba(152, 127, 76, 0.25);
    border: 1px solid var(--accent-gold);
    color: var(--accent-gold);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    display: inline-block;
    margin-bottom: 20px;
    backdrop-filter: blur(5px);
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 20px;
    font-family: var(--font-heading);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.hero-desc {
    font-size: 1.15rem;
    margin-bottom: 35px;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 300;
}

.hero-actions {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.btn {
    padding: 14px 30px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background-color: var(--accent-gold);
    color: #ffffff;
    border: 1px solid var(--accent-gold);
    box-shadow: 0 4px 15px rgba(152, 127, 76, 0.4);
    position: relative;
    overflow: hidden;
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent);
    transition: none;
}

.btn-primary:hover::after {
    left: 100%;
    transition: left 0.8s ease-in-out;
}

.btn-primary:hover {
    background-color: #836d40;
    border-color: #836d40;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(152, 127, 76, 0.5);
}

.btn-secondary {
    background-color: transparent;
    color: #ffffff;
    border: 2px solid #ffffff;
}

.btn-secondary:hover {
    background-color: #ffffff;
    color: var(--text-primary);
    transform: translateY(-2px);
}

/* -------------------------------------------------------------
   SECCIONES COMUNES
   ------------------------------------------------------------- */
section {
    padding: 100px 0;
}

.section-container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 60px auto;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
    padding-bottom: 15px;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--accent-gold);
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1.05rem;
}

/* -------------------------------------------------------------
   LA RUTA DE LA TRADICIÓN (DEL HILO AL TELAR)
   ============================================================= */
.process-section {
    background-color: var(--bg-secondary);
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
    gap: 30px;
}

.process-card {
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
}

.process-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background-color: var(--accent-gold);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
    z-index: 10;
}

.process-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(152, 127, 76, 0.3);
}

.process-card:hover::before {
    transform: scaleX(1);
}

.process-img-container {
    height: 220px;
    position: relative;
    overflow: hidden;
    background-color: #e0e0e0;
}

.process-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.process-card:hover .process-img {
    transform: scale(1.08);
}

.process-number {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: var(--accent-gold);
    color: #ffffff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275), background-color 0.4s ease;
    z-index: 5;
}

.process-card:hover .process-number {
    transform: rotate(360deg) scale(1.1);
    background-color: var(--accent-terracotta);
}

.process-info {
    padding: 25px;
}

.process-info h3 {
    font-size: 1.35rem;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.process-info p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.process-more {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--accent-gold);
    font-size: 0.9rem;
    font-weight: 600;
}

.process-more i {
    transition: transform 0.3s ease;
}

.process-card:hover .process-more i {
    transform: translateX(4px);
}

/* -------------------------------------------------------------
   MURAL DE REDES (INTEGRACIONES SOCIALES)
   ============================================================= */
.mural-section {
    background-color: var(--bg-primary);
}

.mural-container {
    max-width: 1000px;
    margin: 0 auto;
}

.mural-tabs {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
}

.tab-btn {
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 10px 24px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tab-btn:hover {
    background-color: var(--bg-secondary);
    border-color: var(--accent-gold);
}

.tab-btn.active {
    background-color: var(--accent-gold);
    color: #ffffff;
    border-color: var(--accent-gold);
}

.mural-content {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 30px;
    box-shadow: var(--shadow-md);
    min-height: 520px;
}

.tab-panel {
    display: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.tab-panel.active {
    display: block;
    opacity: 1;
}

/* Panel de Facebook responsivo */
.fb-panel-layout {
    display: grid;
    grid-template-columns: 1.2fr 1.8fr;
    gap: 30px;
    align-items: center;
}

.fb-info-card {
    padding-right: 15px;
}

.fb-info-card h4 {
    font-size: 1.6rem;
    margin-bottom: 15px;
}

.fb-info-card p {
    color: var(--text-secondary);
    margin-bottom: 25px;
}

.fb-embed-container {
    display: flex;
    justify-content: center;
    background-color: #f0f2f5;
    border-radius: 12px;
    padding: 15px;
    overflow: hidden;
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] .fb-embed-container {
    background-color: #1e1e1e;
}

.iframe-responsive {
    border: none;
    overflow: hidden;
    width: 340px;
    height: 500px;
    max-width: 100%;
}

/* Panel de Video del Taller */
.video-panel-layout {
    display: grid;
    grid-template-columns: 1.8fr 1.2fr;
    gap: 30px;
    align-items: center;
}

.video-container {
    position: relative;
    padding-bottom: 56.25%;
    /* Relación 16:9 */
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* -------------------------------------------------------------
   ACADEMIA Y ALIANZAS
   ============================================================= */
.academy-section {
    background-color: var(--bg-secondary);
}

.academy-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.academy-card {
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 40px;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.academy-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.academy-icon {
    font-size: 2.5rem;
    color: var(--accent-gold);
    margin-bottom: 25px;
}

.academy-card h3 {
    font-size: 1.8rem;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.academy-card p {
    color: var(--text-secondary);
    margin-bottom: 30px;
    font-size: 1.05rem;
}

.academy-features {
    list-style: none;
    margin-bottom: 30px;
}

.academy-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    color: var(--text-primary);
    font-weight: 500;
}

.academy-features i {
    color: var(--accent-gold);
}

/* -------------------------------------------------------------
   CONTACTO INTELIGENTE
   ============================================================= */
.contact-section {
    background-color: var(--bg-primary);
}

.contact-layout {
    display: grid;
    grid-template-columns: 1.1fr 1.9fr;
    gap: 50px;
}

.contact-info {
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 40px;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 30px;
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

.contact-info:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: var(--accent-gold);
}

.contact-info h3 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.contact-info-desc {
    color: var(--text-secondary);
    font-size: 1.05rem;
}

.info-item {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.info-icon {
    background-color: rgba(152, 127, 76, 0.1);
    color: var(--accent-gold);
    width: 50px;
    height: 50px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.info-content h4 {
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.info-content p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.contact-map-container {
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 15px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    height: 450px;
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

.contact-map-container:hover {
    transform: translateY(-5px);
    border-color: var(--accent-gold);
    box-shadow: var(--shadow-md);
}

.contact-map-iframe {
    width: 100%;
    height: 100%;
    border: 0;
    border-radius: 8px;
    display: block;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-gold);
    box-shadow: 0 0 0 3px rgba(152, 127, 76, 0.15);
}

select.form-control {
    cursor: pointer;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

/* -------------------------------------------------------------
   PIE DE PÁGINA (FOOTER)
   ------------------------------------------------------------- */
footer {
    background-color: #1c1c18;
    color: #a5a49a;
    padding: 80px 0 30px 0;
    border-top: 1px solid rgba(152, 127, 76, 0.2);
}

.footer-layout {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.footer-logo-img {
    height: 45px;
    width: 45px;
    border-radius: 50%;
    border: 1px solid var(--accent-gold);
}

.footer-logo h3 {
    color: #ffffff;
    font-size: 1.25rem;
}

.footer-logo h3 span {
    color: var(--accent-gold);
}

.footer-about p {
    font-size: 0.95rem;
    line-height: 1.6;
}

.footer-links h4,
.footer-contact h4 {
    color: #ffffff;
    font-size: 1.1rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-links h4::after,
.footer-contact h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background-color: var(--accent-gold);
}

.footer-links ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a:hover {
    color: #ffffff;
}

.footer-contact ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.footer-contact li {
    display: flex;
    gap: 12px;
    font-size: 0.95rem;
}

.footer-contact i {
    color: var(--accent-gold);
    margin-top: 4px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    font-size: 0.9rem;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-icon {
    background-color: rgba(255, 255, 255, 0.05);
    color: #ffffff;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.social-icon:hover {
    background-color: var(--accent-gold);
    transform: translateY(-3px);
}

/* -------------------------------------------------------------
   BOTÓN FLOTANTE DE WHATSAPP (CONVERSOR RÁPIDO)
   ------------------------------------------------------------- */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: #ffffff;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    z-index: 999;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.whatsapp-float:hover {
    transform: scale(1.1) rotate(15deg);
    background-color: #20ba5a;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
}

/* Tooltip para el botón flotante */
.whatsapp-float::before {
    content: 'Contáctanos';
    position: absolute;
    right: 75px;
    background-color: #1c1c18;
    color: #ffffff;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-family: var(--font-body);
    font-weight: 600;
    letter-spacing: 0.5px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    white-space: nowrap;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.whatsapp-float:hover::before {
    opacity: 1;
    visibility: visible;
    right: 70px;
}

/* -------------------------------------------------------------
   MODAL DE DETALLES DEL PROCESO
   ------------------------------------------------------------- */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
}

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

.modal-container {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    width: 90%;
    max-width: 750px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    position: relative;
    transform: scale(0.9);
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    flex-direction: column;
    max-height: 90vh;
}

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

.modal-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: rgba(0, 0, 0, 0.5);
    color: #ffffff;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    z-index: 10;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.modal-close-btn:hover {
    background-color: var(--accent-gold);
    transform: rotate(90deg);
}

.modal-image-wrapper {
    height: 320px;
    background-color: #1a1a16;
    overflow: hidden;
    position: relative;
}

.modal-slider {
    display: flex;
    height: 100%;
    width: 100%;
    transition: transform 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.modal-slider img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    flex-shrink: 0;
}

/* Flechas de navegación del carrusel */
.modal-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(26, 26, 22, 0.6);
    color: #ffffff;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    z-index: 10;
}

.modal-nav-btn:hover {
    background-color: var(--accent-gold);
    color: #ffffff;
}

.modal-nav-btn.prev {
    left: 15px;
}

.modal-nav-btn.next {
    right: 15px;
}

/* Indicadores de puntos */
.modal-dots {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.modal-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
}

.modal-dot.active {
    background-color: var(--accent-gold);
    width: 16px;
    border-radius: 4px;
}

.modal-content-info {
    padding: 30px 35px 35px 35px;
    overflow-y: auto;
}

.modal-content-info h3 {
    font-size: 1.8rem;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.modal-content-info p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.7;
}

/* Ficha Técnica Educativa */
.modal-educational-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid var(--border-color);
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.meta-item i {
    font-size: 1.35rem;
    color: var(--accent-gold);
    background-color: rgba(152, 127, 76, 0.1);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.meta-item div {
    display: flex;
    flex-direction: column;
}

.meta-item strong {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-primary);
}

.meta-item span {
    font-size: 0.95rem;
    color: var(--text-secondary);
}

@media (max-width: 576px) {
    .modal-image-wrapper {
        height: 220px;
    }
    .modal-content-info {
        padding: 20px;
    }
    .modal-educational-meta {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

/* -------------------------------------------------------------
   ANIMACIONES DE SCROLL (ESTADOS)
   ------------------------------------------------------------- */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.165, 0.84, 0.44, 1),
        transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

.delay-1 {
    transition-delay: 0.1s;
}

.delay-2 {
    transition-delay: 0.2s;
}

.delay-3 {
    transition-delay: 0.3s;
}

/* -------------------------------------------------------------
   DISEÑO RESPONSIVO (MEDIAS QUERIES)
   ------------------------------------------------------------- */
@media (max-width: 992px) {
    .hero-title {
        font-size: 2.8rem;
    }

    .academy-layout,
    .contact-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .fb-panel-layout,
    .video-panel-layout {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .fb-info-card {
        padding-right: 0;
        text-align: center;
    }

    .footer-layout {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }

    .footer-logo,
    .footer-links h4::after,
    .footer-contact h4::after {
        justify-content: center;
    }

    .footer-links h4::after,
    .footer-contact h4::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
        /* Simplificado para móviles en esta iteración */
    }

    .hero-section {
        text-align: center;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-title {
        font-size: 2.3rem;
    }

    section {
        padding: 70px 0;
    }

    .section-header h2 {
        font-size: 2rem;
    }

    .contact-info {
        padding: 30px 20px;
    }

    .contact-map-container {
        padding: 10px;
        height: 350px;
    }

    .modal-image-wrapper {
        height: 200px;
    }
}

/* -------------------------------------------------------------
   INTEGRACIONES SOCIALES ADICIONALES (4 TARJETAS CON ANIMACIONES)
   ------------------------------------------------------------- */
.social-grid-layout {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
}

.social-card {
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 35px 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: var(--shadow-sm);
}

.social-card-icon {
    font-size: 3.2rem;
    margin-bottom: 18px;
    color: var(--accent-gold);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), color 0.3s ease;
}

.social-card h5 {
    font-size: 1.35rem;
    margin-bottom: 5px;
    color: var(--text-primary);
    font-family: var(--font-heading);
}

.social-card p {
    color: var(--accent-gold);
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.social-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 25px;
    flex-grow: 1;
    line-height: 1.55;
}

/* Efectos de Elevación y Sombra de la Tarjeta */
.social-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-gold);
}

.social-card:hover .social-card-icon {
    transform: scale(1.15) rotate(5deg);
}

/* Cambios de color individuales en Hover de cada red */
.facebook-card:hover .social-card-icon {
    color: #1877f2;
}

.youtube-card:hover .social-card-icon {
    color: #ff0000;
}

.instagram-card:hover .social-card-icon {
    color: #e1306c;
}

.tiktok-card:hover .social-card-icon {
    color: #00f2fe;
    text-shadow: 2px 2px 0px #fe0979;
}

/* Estilos del mapa reubicado al contenedor principal derecho */

@media (max-width: 992px) {
    .social-grid-layout {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .social-grid-layout {
        grid-template-columns: 1fr;
    }
}

/* -------------------------------------------------------------
   SECCIÓN LEGADO E HISTORIA (STORYTELLING)
   ============================================================= */
.legacy-section {
    background-color: var(--bg-secondary);
}

.legacy-layout {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 60px;
    align-items: center;
}

.legacy-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.legacy-info h2 {
    font-size: 2.5rem;
    margin-bottom: 25px;
    color: var(--text-primary);
}

.legacy-text {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.legacy-text p {
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.75;
}

.legacy-visual {
    display: flex;
    justify-content: center;
    position: relative;
}

.legacy-slider-container {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
    width: 100%;
    max-width: 450px;
    height: 520px;
    background-color: #1a1a16;
    transition: border-color 0.4s ease;
}

.legacy-slider-container:hover {
    border-color: var(--accent-gold);
}

.legacy-slides {
    position: relative;
    width: 100%;
    height: 100%;
}

.legacy-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
}

.legacy-slide.active {
    opacity: 1;
    visibility: visible;
}

.legacy-img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.legacy-slide-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.4) 60%, rgba(0,0,0,0) 100%);
    color: #ffffff;
    padding: 40px 20px 25px 20px;
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.4;
    text-shadow: 0 1px 4px rgba(0,0,0,0.5);
    box-sizing: border-box;
    z-index: 5;
}

/* Controles del Slider de Historia */
.legacy-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(26, 26, 22, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    color: #ffffff;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    z-index: 10;
}

.legacy-nav-btn:hover {
    background-color: var(--accent-gold);
}

.legacy-nav-btn.prev {
    left: 15px;
}

.legacy-nav-btn.next {
    right: 15px;
}

.legacy-dots {
    position: absolute;
    bottom: 25px;
    left: 20px;
    display: flex;
    gap: 8px;
    z-index: 10;
}

.legacy-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
}

.legacy-dot.active {
    background-color: var(--accent-gold);
    width: 16px;
    border-radius: 4px;
}

.legacy-slider-container .legacy-badge-over {
    position: absolute;
    top: 20px;
    right: 20px;
    background-color: var(--accent-gold);
    color: #ffffff;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 8px 16px;
    border-radius: 50px;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(152, 127, 76, 0.4);
    z-index: 12;
}

@media (max-width: 992px) {
    .legacy-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .legacy-info h2 {
        font-size: 2.2rem;
    }
}

/* -------------------------------------------------------------
   TRANSICIÓN RADIAL DE MODO OSCURO (VIEW TRANSITIONS API)
   ============================================================= */
::view-transition-old(root) {
    animation: none;
    mix-blend-mode: normal;
}
::view-transition-new(root) {
    animation: circular-reveal 0.6s ease-in;
    mix-blend-mode: normal;
}

@keyframes circular-reveal {
    from {
        clip-path: circle(0% at 90% 40px);
    }
    to {
        clip-path: circle(150% at 90% 40px);
    }
}