/* =================================================================== */
/* ARCHIVO BASE                               */
/* Contiene todos los estilos compartidos por el sitio web.          */
/* =================================================================== */

/* --- Variables Globales y Fuentes --- */
@import url('https://fonts.googleapis.com/css2?family=Lato:wght@400;700&family=Poppins:wght@600;700&display=swap');

:root {
    --morado-principal: #6a0dad;
    --morado-oscuro: #4527a0;
    --morado-claro: #f8f7fa;
    --color-acento: #A9A9A9;
    --gris-oscuro: #333;
    --blanco: #ffffff;
    --rojo-promo: #d92027;
}

/* --- Estilos Generales del Cuerpo --- */
body {
    font-family: 'Lato', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--morado-claro);
    color: var(--gris-oscuro);
    line-height: 1.6;
}

main {
    margin-top: 60px; /* Espacio para la barra de navegación fija */
}

/* --- Barra de Navegación Superior --- */
.top-nav-bar {
    background-color: rgba(106, 13, 173, 0.9);
    backdrop-filter: blur(10px);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 60px;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    box-shadow: 0 3px 12px rgba(0,0,0,0.1);
    box-sizing: border-box;
    transition: background-color 0.4s ease;
}
.top-nav-bar.scrolled {
    background-color: var(--morado-principal);
    box-shadow: 0 3px 12px rgba(0,0,0,0.3);
}
.top-nav-logo {
    height: 45px;
    width: auto;
}
.open-btn-topnav {
    font-size: 16px;
    font-weight: bold;
    color: var(--blanco);
    background-color: transparent;
    border: 2px solid var(--blanco);
    padding: 8px 15px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}
.open-btn-topnav:hover {
    background-color: var(--blanco);
    color: var(--morado-principal);
}

/* --- Menú Lateral (Sidebar) --- */
.sidebar {
    height: 100%;
    width: 0;
    position: fixed;
    z-index: 1002;
    top: 0;
    left: 0;
    background-color: var(--blanco);
    overflow-x: hidden;
    transition: 0.5s cubic-bezier(0.77, 0, 0.175, 1);
    padding-top: 20px;
    box-shadow: 5px 0 20px rgba(0,0,0,0.15);
    display: flex;
    flex-direction: column;
}
.sidebar-header {
    padding: 15px 25px;
    text-align: center;
    border-bottom: 1px solid #f0f0f0;
}
.sidebar-category {
    padding: 20px 25px 10px 25px;
    font-size: 13px;
    color: var(--morado-principal);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: bold;
}
.sidebar a {
    padding: 12px 25px;
    text-decoration: none;
    font-size: 18px;
    color: var(--gris-oscuro);
    display: flex;
    align-items: center;
    transition: 0.3s;
}
.sidebar a:hover {
    color: var(--blanco);
    background-color: var(--morado-principal);
}
.sidebar a .material-symbols-outlined {
    margin-right: 15px;
    font-size: 24px;
    color: var(--morado-principal);
    transition: color 0.3s ease;
}
.sidebar a:hover .material-symbols-outlined {
    color: var(--blanco);
}
.sidebar .close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 36px;
    color: var(--gris-oscuro);
}
.close-btn:hover {
    color: var(--morado-principal);
}
.sidebar-logo {
    width: 80%;
    max-width: 150px;
}
.sidebar-links {
    padding-top: 10px;
    overflow-y: auto;
}
.overlay {
    position: fixed;
    display: none;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background-color: rgba(0,0,0,0.5);
    cursor: pointer;
    z-index: 1001;
}

/* --- Estructura y Contenedores --- */
.container {
    padding: 1.5rem;
    max-width: 1200px;
    margin: auto;
}
.section {
    background-color: var(--blanco);
    margin-bottom: 2rem;
    padding: 2.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
}
.section h2 {
    font-family: 'Poppins', sans-serif;
    color: var(--morado-principal);
    border-bottom: 3px solid var(--color-acento);
    padding-bottom: 0.8rem;
    margin-top: 0;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    font-size: 2.2rem;
}
.section h2 .material-symbols-outlined {
    margin-right: 1rem;
    font-size: inherit;
}
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.8rem;
}

/* --- Componentes Reutilizables: Tarjetas y Botones --- */
.card {
    background: var(--blanco);
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.04), 0 5px 15px rgba(0, 0, 0, 0.08);
    border-left: 4px solid var(--morado-principal);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.06), 0 20px 30px rgba(106, 13, 173, 0.2);
}
.card h3 {
    font-family: 'Poppins', sans-serif;
    margin-top: 0;
    color: var(--gris-oscuro);
    display: flex;
    align-items: center;
    font-size: 1.4rem;
}
.card h3 .material-symbols-outlined {
    margin-right: 0.8rem;
}
.card p {
    flex-grow: 1;
}

/* Tarjeta como enlace (para videos.html y relevamientos.html) */
.card-link {
    display: block;
    background: var(--blanco);
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.04), 0 5px 15px rgba(0, 0, 0, 0.08);
    border-left: 4px solid var(--morado-principal);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    color: var(--gris-oscuro);
}
.card-link:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.06), 0 20px 30px rgba(106, 13, 173, 0.2);
}
.card-link h3 {
    font-family: 'Poppins', sans-serif;
    margin-top: 0;
    color: var(--gris-oscuro);
    display: flex;
    align-items: center;
    font-size: 1.4rem;
}
.card-link h3 .material-symbols-outlined {
    margin-right: 0.8rem;
    color: var(--morado-principal);
    transition: transform 0.3s ease;
}
.card-link:hover h3 .material-symbols-outlined {
    transform: scale(1.1);
}

/* Botones */
.card-button {
    display: inline-block;
    background-image: linear-gradient(to right, var(--morado-principal) 0%, #8e2de2 50%, var(--morado-principal) 100%);
    background-size: 200% auto;
    color: var(--blanco);
    padding: 12px 25px;
    border-radius: 8px;
    text-decoration: none;
    text-align: center;
    font-weight: bold;
    margin-top: 1.5rem;
    border: none;
    transition: all 0.4s ease;
}
.card-button:hover {
    background-position: right center;
    transform: scale(1.05);
}

/* --- Pie de Página --- */
footer {
    background-color: var(--morado-oscuro);
    color: var(--blanco);
    text-align: center;
    padding: 2.5rem 1.5rem;
    margin-top: 2rem;
}
footer p {
    margin: 0.5rem 0;
}
.footer-logo {
    max-width: 150px;
    margin-bottom: 1rem;
}
.social-links {
    padding-top: 1rem;
}
.social-links a {
    margin: 0 15px;
    display: inline-block;
    transition: transform 0.3s;
}
.social-links a:hover {
    transform: scale(1.2);
}
.social-links svg {
    fill: var(--blanco);
    width: 32px;
    height: 32px;
}

/* --- Media Queries (Responsividad) --- */
@media (max-width: 768px) {
    .section {
        padding: 1.5rem;
    }
    .section h2 {
        font-size: 1.7rem;
    }
}

/*Borrar antes de receso inverna*/

/* ====== ESTILOS POP-IN RECESO (DISEÑO MODERNO CON ICONO) ====== */
.receso-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(25, 9, 44, 0.7); /* Tono morado oscuro semitransparente */
    z-index: 2000;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
    backdrop-filter: blur(8px); /* Desenfoque más pronunciado */
}

.receso-overlay.visible {
    opacity: 1;
    pointer-events: auto;
}

.receso-popup-brand {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    background-color: #f9f9fd; /* Fondo ligeramente morado */
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    z-index: 2001;
    width: 90%;
    max-width: 500px;
    opacity: 0;
    transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
    overflow: visible; /* Permitir que el icono se salga */
    text-align: center;
}

.receso-popup-brand.visible {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

/* Contenedor del icono que se superpone */
.receso-popup-brand::before {
    content: '❄️'; /* Puedes usar un emoji o un icono de FontAwesome/Material Icons */
    position: absolute;
    top: -45px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 80px;
    background-color: var(--blanco);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    color: var(--morado-principal);
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
    z-index: 10;
}


.receso-header {
    background-image: linear-gradient(135deg, var(--morado-principal) 0%, var(--morado-oscuro) 100%); /* Degradado */
    padding: 3rem 1rem 1rem 1rem; /* Más padding superior para dejar espacio al icono */
    border-radius: 20px 20px 0 0; /* Bordes redondeados solo arriba */
}

.receso-header img {
    max-width: 150px;
    height: auto;
}

.receso-body {
    padding: 1.5rem 2.5rem 2rem 2.5rem;
    position: relative;
}

.receso-popup-brand h2 {
    font-family: 'Poppins', sans-serif;
    color: var(--morado-oscuro);
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: 1.7rem;
    font-weight: 700;
}

.receso-popup-brand p {
    font-size: 1.05rem;
    color: #444;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.receso-popup-brand p strong {
    color: var(--morado-principal);
    font-weight: 700;
}

.receso-popup-brand p em {
    display: block;
    margin-top: 1.5rem;
    font-weight: bold;
    color: var(--morado-oscuro);
    font-style: normal;
    font-family: 'Poppins', sans-serif;
}

.cerrar-popup {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 2rem;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 20;
}

.cerrar-popup:hover {
    color: var(--blanco);
    transform: scale(1.2);
}
/*hasta aca*/

/* =================================================================== */
/* ESTILOS PARA MODO OSCURO                         */
/* =================================================================== */

body.dark-mode {
    /* --- Paleta de Colores Oscuros --- */
    --morado-principal: #9d4edd; /* Un poco más brillante para mejor contraste */
    --morado-oscuro: #7b2cbf;
    --morado-claro: #1a1024; /* Fondo principal muy oscuro */
    --color-acento: #555;   /* Borde de títulos */
    --gris-oscuro: #e0e0e0;  /* Color de texto principal (claro) */
    --blanco: #2a1a3a;      /* Color de fondo para las tarjetas y secciones */

    /* --- Ajuste de logos e imágenes --- */
    /* Invierte logos simples que son oscuros para que se vean en fondo oscuro */
    --logo-filter: invert(1) hue-rotate(180deg) brightness(1.5);
}

/* --- Ajustes Generales para Componentes en Modo Oscuro --- */

/* Hacer el texto de los títulos más brillante */
body.dark-mode .section h2 {
    color: #c77dff;
}

/* Ajustar el color de los enlaces y botones del menú lateral */
body.dark-mode .sidebar a {
    color: #e0e0e0;
}
body.dark-mode .sidebar a .material-symbols-outlined {
    color: #9d4edd;
}
body.dark-mode .sidebar a:hover {
    color: var(--blanco);
    background-color: var(--morado-principal);
}
body.dark-mode .sidebar a:hover .material-symbols-outlined {
    color: var(--blanco);
}
body.dark-mode .sidebar .close-btn {
    color: #e0e0e0;
}

/* Invertir el logo del footer y los iconos de redes sociales */
body.dark-mode .footer-logo,
body.dark-mode .top-nav-logo {
   filter: var(--logo-filter);
}
body.dark-mode .social-links svg {
    fill: #e0e0e0; /* Cambiar a un color claro en lugar de blanco puro */
}

/* Estilos para el nuevo botón de modo oscuro */
.dark-mode-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: var(--morado-oscuro);
    color: var(--blanco);
    border: 2px solid var(--morado-claro);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 1005;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}
.dark-mode-toggle:hover {
    transform: scale(1.1);
    background-color: var(--morado-principal);
}
.dark-mode-toggle .material-symbols-outlined {
    font-size: 28px;
    transition: transform 0.4s ease;
}

/* Rotación del icono al cambiar de modo */
body.dark-mode .dark-mode-toggle .light-icon {
    transform: rotate(360deg);
}
body:not(.dark-mode) .dark-mode-toggle .dark-icon {
    transform: rotate(360deg);
}
/* --- Estilos para la Tienda --- */
.product-card {
    text-align: center;
    border-left-color: var(--morado-oscuro);
}

.product-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.product-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-content h3 {
    font-size: 1.2rem;
    min-height: 40px; /* Para alinear títulos de varias líneas */
}

.product-description {
    font-size: 0.9rem;
    color: #666;
    flex-grow: 1; /* Empuja el precio y botón hacia abajo */
}

.product-price {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--morado-principal);
    margin: 1rem 0;
}

body.dark-mode .product-description {
    color: #bbb;
}