/* --- Fuentes ---
   Títulos: 'Syne' o 'UnifrakturCook'
   Cuerpo: 'Inter'
*/

:root {
    --font-title: 'Syne', sans-serif;
    --font-gothic: 'UnifrakturCook', cursive;
    --font-body: 'Inter', sans-serif;
    
    /* Colores base (Oscuro por defecto) */
    --color-bg: #0A0A0A;
    --color-text: #F5F5F5;
    --color-text-subtle: #BDBDBD;
    --color-border: #222;
    --color-surface: #111;

    /* El color de acento se define en el body */
    --color-accent: #FF0000; /* Rojo por defecto */
    --accent-shadow: rgba(255, 0, 0, 0.5);
}

/* --- Definición de Temas de Color --- */
body.red-theme {
    --color-accent: #FF0000;
    --accent-shadow: rgba(255, 0, 0, 0.5);
}
body.green-theme {
    --color-accent: #00FF00;
    --accent-shadow: rgba(0, 255, 0, 0.5);
}
body.purple-theme {
    --color-accent: #9E00FF;
    --accent-shadow: rgba(158, 0, 255, 0.5);
}

/* --- Tema Claro (Reverse Grunge) --- */
body.light-theme {
    --color-bg: #EAEAEA;
    --color-text: #1A1A1A;
    --color-text-subtle: #444;
    --color-border: #CCCCCC;
    --color-surface: #F0F0F0;
}

/* --- Reseteo Básico --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-body);
    overflow-x: hidden; /* Evitar scroll horizontal */
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* --- Efecto de Ruido (Clave para el estilo) --- */
.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-image: url('https://i.imgur.com/SXXjb2z.png'); /* Textura de ruido sutil */
    opacity: 0.05;
    pointer-events: none; /* Para poder hacer clic a través de él */
    z-index: 999;
}

/* --- Animaciones --- */

/* Animación de "flicker" para neón */
@keyframes neon-flicker {
    0%, 100% {
        text-shadow: 0 0 5px var(--color-accent), 0 0 10px var(--color-accent), 0 0 20px var(--accent-shadow);
        color: var(--color-accent);
    }
    50% {
        text-shadow: 0 0 10px var(--color-accent), 0 0 20px var(--accent-shadow), 0 0 30px var(--accent-shadow);
        color: var(--color-accent);
    }
}

/* Animación de fade-in para tarjetas */
@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Header y Logo --- */
.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    border-bottom: 1px solid var(--color-border); /* Borde sutil */
    position: relative; /* Para posicionar los controles */
}

.logo {
    width: 150px; /* Ajusta el tamaño de tu logo */
    filter: brightness(1.2); /* Hacerlo resaltar un poco */
}

.main-nav a {
    color: var(--color-text);
    text-decoration: none;
    margin-left: 20px;
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 1px;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.main-nav a:hover {
    color: var(--color-accent);
    text-shadow: 0 0 10px var(--accent-shadow);
}

/* --- Controles de Tema --- */
.theme-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    /* Descomenta si quieres posicionarlo absoluto */
    /* position: absolute; 
    right: 40px; */
}

.theme-controls button {
    border: 1px solid var(--color-border);
    background: var(--color-surface);
    color: var(--color-text);
    cursor: pointer;
    font-size: 16px;
    transition: all 0.2s ease;
}

.theme-controls button:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

#theme-light {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    font-family: var(--font-body);
}

.color-swatch {
    width: 25px;
    height: 25px;
    border-radius: 50%;
}
.color-swatch:hover {
    transform: scale(1.1);
}

/* --- Sección Hero --- */
.hero {
    min-height: 80vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 40px;
}

.hero-title {
    font-family: var(--font-title);
    font-weight: 800;
    font-size: 7vw; /* Tamaño que se adapta a la pantalla */
    letter-spacing: -2px;
    line-height: 1;
    text-transform: uppercase;
    margin: 0;
}

.hero-title .line-1,
.hero-title .line-3 {
    -webkit-text-stroke: 1px var(--color-text);
    color: transparent;
}

.hero-title .line-2 {
    color: var(--color-text);
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.hero-subtitle {
    font-size: 18px;
    color: var(--color-text-subtle);
    margin-top: 20px;
    max-width: 500px;
}

/* --- Botón CTA (Call to Action) --- */
.cta-button {
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 16px;
    text-decoration: none;
    text-transform: uppercase;
    color: var(--color-bg);
    background-color: var(--color-accent);
    padding: 15px 30px;
    margin-top: 30px;
    display: inline-block;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px var(--accent-shadow);
}

.cta-button:hover {
    background-color: var(--color-text);
    color: var(--color-bg);
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.7);
    transform: scale(1.05);
}

/* --- Estilos del Contador --- */
.countdown-section {
    padding: 40px;
    text-align: center;
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    margin-bottom: 60px;
}

.countdown-section .section-title {
    margin-top: 0;
    margin-bottom: 30px;
    color: var(--color-accent); /* Resaltar el título del drop */
    animation: neon-flicker 2s infinite; /* Aplicar flicker */
}

.countdown-timer {
    display: flex;
    justify-content: center;
    flex-wrap: wrap; /* Para móviles */
    gap: 20px;
    font-family: var(--font-title);
    font-weight: 800;
}

.time-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 20px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    min-width: 100px;
}

.time-value {
    font-size: 3rem;
    color: var(--color-text);
    line-height: 1;
}

.time-label {
    font-size: 0.9rem;
    color: var(--color-text-subtle);
    letter-spacing: 1px;
}


/* --- Sección de Cursos --- */
.section-title {
    text-align: center;
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 24px;
    letter-spacing: 2px;
    color: var(--color-text-subtle);
    margin: 60px 0 40px 0;
}

.course-grid {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    padding-bottom: 60px;
}

.course-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    transition: transform 0.3s ease, border-color 0.3s ease;
    
    /* Animación de entrada */
    animation: fade-in 0.5s ease-out forwards;
    opacity: 0; /* Empezar invisible */
    animation-delay: calc(var(--card-index, 0) * 100ms); /* Efecto escalonado (ver JS) */
}

.course-card:hover {
    transform: translateY(-5px);
    border-color: var(--color-accent);
}

.card-image-container {
    height: 200px;
    background-color: var(--color-border); /* Placeholder para la imagen */
    /* Aquí pondríamos un background-image */
}

.card-content {
    padding: 20px;
}

.course-tag {
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 12px;
    color: var(--color-accent);
    letter-spacing: 1px;
}

.course-title {
    font-family: var(--font-title);
    font-weight: 800;
    font-size: 22px;
    color: var(--color-text);
    margin: 10px 0;
}

.course-desc {
    font-size: 14px;
    color: var(--color-text-subtle);
    line-height: 1.6;
}

.card-link {
    display: inline-block;
    text-decoration: none;
    color: var(--color-text);
    font-weight: 700;
    margin-top: 15px;
}

.card-link:hover {
    color: var(--color-accent);
}


/* --- ESTILOS DE LA PÁGINA DE TUTORIAL --- */

.tutorial-layout {
    display: flex;
    flex-wrap: wrap; /* Para que en móvil se ponga uno debajo de otro */
    width: 90%;
    max-width: 1400px;
    margin: 40px auto;
    gap: 40px;
}

.tutorial-content {
    flex: 3; /* Ocupa 3 partes del espacio */
    min-width: 60%;
}

.tutorial-sidebar {
    flex: 1; /* Ocupa 1 parte del espacio */
    min-width: 250px;
    
    /* Estilo "panel" */
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    padding: 20px;
    height: fit-content; /* Se ajusta al contenido */
}

.tutorial-title {
    font-family: var(--font-title);
    font-weight: 800;
    font-size: 3.5rem; /* 3.5 veces el tamaño base */
    color: var(--color-text);
    margin: 10px 0;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.tutorial-intro {
    font-size: 1.1rem;
    color: var(--color-text-subtle);
    line-height: 1.6;
    margin-bottom: 30px;
    max-width: 700px;
}

/* --- Contenedor del Video --- */
.video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* Proporción 16:9 (9 / 16 = 0.5625) */
    height: 0;
    overflow: hidden;
    background: #000;
    border: 1px solid var(--color-border);
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* --- Pasos y Notas --- */
.tutorial-steps {
    margin-top: 40px;
    border-top: 1px solid var(--color-border);
    padding-top: 30px;
}

.tutorial-steps h2 {
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--color-accent);
    letter-spacing: 1px;
    margin-bottom: 20px;
}

.tutorial-steps p {
    color: var(--color-text-subtle);
    margin-bottom: 20px;
    line-height: 1.6;
}

.tutorial-steps ul {
    list-style: none;
    padding-left: 0;
}

.tutorial-steps li {
    position: relative;
    padding-left: 30px; /* Espacio para el icono */
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 15px;
    color: var(--color-text);
}

/* Usamos un "bullet" custom con el estilo trap */
.tutorial-steps li::before {
    content: '///'; /* Puedes cambiarlo por '►' o '※' */
    position: absolute;
    left: 0;
    top: 0;
    color: var(--color-accent);
    font-weight: 700;
    font-family: var(--font-title);
}

/* --- Sidebar de Recursos --- */
.tutorial-sidebar h3 {
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--color-text);
    letter-spacing: 1px;
    border-bottom: 1px solid var(--color-accent);
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.resource-box {
    margin-bottom: 25px;
}

.resource-box h4 {
    font-family: var(--font-title);
    font-size: 1.1rem;
    color: var(--color-text);
    margin-bottom: 5px;
}

.resource-box p {
    font-size: 0.9rem;
    color: var(--color-text-subtle);
    margin-bottom: 10px;
}

.resource-link {
    display: block;
    text-decoration: none;
    color: var(--color-accent);
    font-weight: 700;
    font-size: 0.9rem;
    padding: 8px 0;
    transition: color 0.3s;
}

.resource-link:hover {
    color: var(--color-text);
}


/* --- Ajustes para Modo Claro --- */
body.light-theme .cta-button {
    color: var(--color-text); /* Texto oscuro */
    box-shadow: 0 0 20px var(--accent-shadow);
}

body.light-theme .cta-button:hover {
    background-color: var(--color-text);
    color: var(--color-bg); /* Texto claro */
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

body.light-theme .hero-title .line-1,
body.light-theme .hero-title .line-3 {
    -webkit-text-stroke: 1px var(--color-text);
}

body.light-theme .logo {
    filter: none; /* Quitar brillo en modo claro */
}


/* --- Media Query para Móviles --- */
@media (max-width: 768px) {
    .main-header {
        flex-direction: column;
        gap: 20px;
    }

    .theme-controls {
        /* Quitar de la esquina y poner en el flujo */
        position: static; 
        margin-top: 10px;
    }

    .hero-title {
        font-size: 12vw; /* Más grande en móvil */
    }

    .tutorial-layout {
        flex-direction: column; /* Apila las columnas */
        gap: 20px;
    }
    
    .tutorial-title {
        font-size: 2.5rem; /* Más pequeño en móvil */
    }
} 
/* --- Footer --- */
.main-footer {
    background-color: var(--color-surface);
    border-top: 1px solid var(--color-border);
    padding: 40px 20px;
    text-align: center;
    margin-top: 80px;
}

.footer-logo-container {
    margin-bottom: 20px;
}

.footer-logo {
    width: 120px; /* Tamaño del logo en el footer */
    filter: brightness(1.2);
}

.footer-nav {
    margin-bottom: 20px;
}

.footer-nav a {
    color: var(--color-text-subtle);
    text-decoration: none;
    font-family: var(--font-body);
    font-size: 14px;
    margin: 0 10px;
    transition: color 0.3s ease;
}

.footer-nav a:hover {
    color: var(--color-accent);
}

.footer-social-links {
    margin-bottom: 20px;
}

.footer-social-links a {
    display: inline-block;
    width: 30px;
    height: 30px;
    line-height: 30px;
    color: var(--color-text-subtle);
    font-size: 18px;
    margin: 0 8px;
    transition: color 0.3s ease;
}

.footer-social-links a:hover {
    color: var(--color-accent);
    transform: scale(1.1);
}

.footer-copyright {
    font-size: 12px;
    color: var(--color-text-subtle);
}

.footer-copyright .tm {
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 14px;
    vertical-align: super;
    line-height: 0;
    margin-left: 2px;
    color: var(--color-accent);
}

/* Ajustes para Modo Claro */
body.light-theme .main-footer .footer-logo {
    filter: none;
}
/* --- Estilos para Páginas de Texto (Privacidad, Términos) --- */
.text-page-container {
    max-width: 800px; /* Ancho estándar para texto legal */
    margin: 40px auto;
    padding: 40px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
}

.text-page-container h1 {
    font-family: var(--font-title);
    font-weight: 800;
    font-size: 2.5rem;
    color: var(--color-text);
    margin-bottom: 20px;
}

.text-page-container h2 {
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--color-accent);
    letter-spacing: 1px;
    margin-top: 30px;
    margin-bottom: 15px;
}

.text-page-container p {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--color-text-subtle);
    margin-bottom: 15px;
}

.text-page-container ul {
    list-style: disc; /* Estilo de lista simple */
    padding-left: 20px;
    margin-bottom: 15px;
}

.text-page-container li {
    color: var(--color-text-subtle);
    line-height: 1.7;
    margin-bottom: 10px;
}

.text-page-container a {
    color: var(--color-accent);
    text-decoration: none;
}

.text-page-container a:hover {
    text-decoration: underline;
}
/* --- Estilos para la Galería de Diseños --- */

.card-image-container {
    /* (Tus estilos existentes están bien) */
    position: relative; /* Necesario para la imagen */
    overflow: hidden; /* Para recortar la imagen */
}

/* NUEVO: Estilo para la imagen DENTRO de la tarjeta */
.card-image-container img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Mágico: cubre el espacio sin deformarse */
    transition: transform 0.4s ease;
}

.course-card:hover .card-image-container img {
    transform: scale(1.05); /* Sutil efecto de zoom al pasar el ratón */
}

/* Ajuste para la descripción (usamos <br> en el HTML) */
.course-card .course-desc {
    line-height: 1.7;
}

.course-card .course-desc strong {
    color: var(--color-text);
    font-weight: 700;
}

/* Para los links dentro de la descripción */
.course-card .course-desc a {
    color: var(--color-accent);
    text-decoration: none;
}
.course-card .course-desc a:hover {
    text-decoration: underline;
}
/* Estilo para links de cursos deshabilitados */
.card-link-disabled {
    display: inline-block;
    text-decoration: none;
    color: var(--color-text-subtle); /* Color gris sutil */
    font-weight: 700;
    margin-top: 15px;
    font-style: italic; /* Opcional: para que se vea más como "coming soon" */
    cursor: not-allowed; /* Muestra el cursor de "no permitido" */
}