/* --- Reseteo Básico y Variables --- */
:root {
    --color-primary: #007BFF; /* Un azul eléctrico como color de acento. ¡Puedes cambiarlo! */
    --color-dark: #101010;
    --color-light: #FFFFFF;
    --color-secondary: #333;
    --color-texto-secundario: #E0E0E0;
}

body {
    background-color: var(--color-dark);
    color: var(--color-light);
    font-family: 'Roboto', sans-serif; /* Usamos Roboto como fuente base */
    margin: 0;
    line-height: 1.6;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Encabezado y Navegación --- */
.main-header {
    background-color: rgba(16, 16, 16, 0.8); /* Fondo semi-transparente */
    padding: 15px 0;
    position: fixed; /* Lo dejamos fijo en la parte superior */
    width: 100%;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px); /* Efecto de desenfoque para navegadores modernos */
}

.main-header .container {
    display: flex;
    justify-content: space-between; /* Separa el logo de la navegación */
    align-items: center;
}

.logo-img {
    height: 50px; /* Ajusta el tamaño de tu logo */
    filter: brightness(1.2);
}

.main-nav ul {
    margin: 0;
    padding: 0;
    list-style: none; /* Quitamos los puntos de la lista */
    display: flex;
}

.main-nav ul li {
    margin-left: 25px;
}

.main-nav a {
    color: var(--color-light);
    text-decoration: none;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    transition: color 0.3s ease;
}

.main-nav a:hover {
    color: var(--color-primary); /* Cambia de color al pasar el mouse */
}

/* --- Sección Principal (Hero) --- */
.hero-section {
    height: 100vh; /* Ocupa el 100% de la altura de la pantalla */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 80px; /* Espacio para no quedar debajo del header */
    background: linear-gradient(rgba(16, 16, 16, 0.7), rgba(16, 16, 16, 0.7)), url('https://via.placeholder.com/1500x800.png?text=Fondo+Épico') no-repeat center center/cover;
}

.hero-title {
    font-family: 'Poppins', sans-serif;
    font-size: 4rem; /* Tamaño de letra grande */
    font-weight: 700;
    margin-bottom: 1rem;
}

.hero-subtitle {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 2rem auto;
}

/* --- Botones --- */
.btn {
    padding: 12px 28px;
    text-decoration: none;
    border-radius: 5px;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    transition: all 0.3s ease;
    display: inline-block;
}

.btn-primary {
    background-color: var(--color-primary);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-3px); /* Efecto de "levantarse" */
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.4);
}

.btn-secondary {
    background-color: transparent;
    color: var(--color-light);
    border: 2px solid var(--color-secondary);
    margin-left: 15px;
}

.btn-secondary:hover {
    background-color: var(--color-secondary);
    color: white;
}

/* --- Sección de Proyectos --- */
.projects-section {
    padding: 80px 0;
    background-color: #151515; /* Un fondo ligeramente distinto para separar secciones */
}

.section-title {
    text-align: center;
    font-family: 'Poppins', sans-serif;
    font-size: 2.5rem;
    margin-bottom: 50px;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px; /* Espacio entre las tarjetas */
}

.project-card {
    background-color: var(--color-secondary);
    border-radius: 8px;
    overflow: hidden; /* Asegura que la imagen no se salga de los bordes redondeados */
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-10px); /* Efecto de levantar la tarjeta al pasar el mouse */
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
}

.card-img {
    width: 100%;
    height: 200px;
    object-fit: contain; /* Cambiado de 'cover' a 'contain' */
    padding: 10px;      /* Añadido para que el logo respire */
    box-sizing: border-box; /* Asegura que el padding no altere el tamaño total */
}

.card-content {
    padding: 25px;
}

.card-status {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: bold;
    margin-bottom: 15px;
}

.status-active {
    background-color: #28a745; /* Verde */
    color: white;
}

.status-soon {
    background-color: #ffc107; /* Amarillo */
    color: #333;
}

.card-title {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    margin: 0 0 10px 0;
}

.card-description {
    font-size: 0.95rem;
    margin-bottom: 20px;
    color: #E8E8E8;
}

.btn-card {
    background-color: var(--color-primary);
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    display: inline-block;
    transition: background-color 0.3s ease;
}

.btn-card:hover {
    background-color: #0056b3; /* Un azul más oscuro */
}

.btn-card.disabled {
    background-color: #555;
    cursor: not-allowed;
}

/* --- Estilos para Estadísticas en Tarjetas --- */
.card-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 5px;
    padding: 10px;
    margin-bottom: 20px;
}

.card-stats span:first-child {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--color-primary);
    font-family: 'Poppins', sans-serif;
}

.card-stats span:last-child {
    font-size: 0.9rem;
    color: #E8E8E8;
}

/* --- Sección Acerca de Nosotros --- */
.about-section {
    padding: 80px 0;
    background-color: var(--color-dark); /* Mantenemos el fondo oscuro principal */
}

.about-content {
    display: grid;
    grid-template-columns: 2fr 1fr; /* El texto ocupa 2/3 y la imagen 1/3 */
    gap: 50px;
    align-items: center;
}

.about-text .section-title {
    text-align: left; /* Alineamos el título a la izquierda en esta sección */
    margin-bottom: 20px;
}

.about-text p {
    font-size: 1.1rem;
    color: #E8E8E8;
    line-height: 1.8;
    margin-bottom: 15px;
}

.about-image img {
    max-width: 100%;
    opacity: 0.9; /* Logo más visible */
    filter: brightness(1.2);
}

/* --- Footer (Pie de Página) --- */
.main-footer {
    padding: 30px 0;
    background-color: #0a0a0a;
    border-top: 1px solid var(--color-secondary);
}

.main-footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--color-texto-secundario);
}

.social-links a {
    margin-left: 20px;
    text-decoration: none;
    color: var(--color-texto-secundario); /* Aplicamos el color base aquí */
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: var(--color-light); /* Cambiamos el color del enlace en hover */
}

.social-links i {
    font-size: 24px;
    transition: transform 0.3s ease;
}

.social-links a:hover i {
    transform: scale(1.2);
}

/* --- Ajustes para Móviles (Responsive) --- */
@media (max-width: 768px) {
    .about-content {
        grid-template-columns: 1fr; /* En pantallas pequeñas, una columna debajo de la otra */
        text-align: center;
    }
    
    .about-text .section-title {
        text-align: center;
    }
    
    .main-footer .container {
        flex-direction: column;
        gap: 15px;
    }
    
    .main-nav ul {
        flex-direction: column;
        gap: 10px;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
}

/* --- Sección de Noticias --- */
.news-section {
    padding: 80px 0;
    background-color: #151515;
}

.news-grid {
    display: grid;
    grid-template-columns: 1fr; /* Una columna para un formato tipo blog */
    gap: 30px;
}

.news-card {
    background-color: var(--color-secondary);
    border-radius: 8px;
    display: flex;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.news-card:hover {
    transform: scale(1.02);
}

.news-card-img {
    width: 250px;
    object-fit: contain; /* Cambiado de 'cover' a 'contain' */
    padding: 15px;      /* Añadido para que el logo respire */
    box-sizing: border-box; /* Asegura que el padding no altere el tamaño total */
    background-color: #222; /* Añadido un fondo oscuro sutil */
}

.news-card-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
}

.news-card-content p {
    color: #E8E8E8;
    line-height: 1.7;
    flex-grow: 1; /* Empuja el botón hacia abajo */
    margin-bottom: 20px;
}

@media (max-width: 768px) {
    .news-card {
        flex-direction: column;
    }
    
    .news-card-img {
        width: 100%;
        height: 200px;
    }
}

.news-card-title {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-light);
    margin-bottom: 15px;
}

.news-footer {
    display: block;
    margin-top: 20px;
    padding-top: 15px;
    font-size: 0.9rem;
    font-style: italic;
    color: var(--color-texto-secundario);
    border-top: 1px solid var(--color-secondary);
}

.spoiler {
    background-color: #333;
    color: #333;
    padding: 0 4px;
    border-radius: 4px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.spoiler:hover {
    color: var(--color-light);
}

/* --- Sección de Plataformas --- */
.platforms-section {
    padding: 80px 0;
    background-color: var(--color-dark);
}

.section-description {
    font-size: 1.1rem;
    color: #D0D0D0;
    max-width: 700px;
    margin: -30px auto 50px auto;
    text-align: center;
}

.platforms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.platform-card {
    background-color: var(--color-secondary);
    border: 1px solid #444;
    border-radius: 8px;
    padding: 30px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.platform-card .card-image-container {
    height: 100px;
    width: 100px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.platform-card img {
    max-height: 100%;
    max-width: 100%;
    filter: brightness(1.2);
}

.platform-card h3 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.platform-card p {
    color: #E8E8E8;
    flex-grow: 1; /* Empuja el botón hacia abajo */
    margin-bottom: 25px;
}

/* --- EFECTO DE RESPLANDOR (GLOW) --- */
.platform-card:hover {
    transform: translateY(-8px);
    border-color: #58a6ff;
    box-shadow: 0 0 15px 0 rgba(47, 129, 247, 0.6);
}

#comisaria-card:hover {
    border-color: #00ff7f;
    box-shadow: 0 0 15px 0 rgba(0, 255, 127, 0.6);
}

/* --- Estilos para Páginas Secundarias --- */
.subpage-body .main-header {
    position: static; /* El header no será fijo en las subpáginas */
    background-color: #151515;
}

.join-us-hero {
    padding: 60px 0;
    text-align: center;
    background-color: #151515;
}

.join-us-hero .hero-title {
    font-size: 3.5rem;
}

.roles-section {
    padding: 80px 0;
}

.roles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.role-card {
    background-color: var(--color-secondary);
    padding: 30px;
    border-radius: 8px;
    text-align: center;
}

.role-icon {
    font-size: 3rem;
    color: var(--color-primary);
    margin-bottom: 20px;
}

.role-card h3 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 15px;
}

.why-join-section {
    padding: 60px 0;
    background-color: #151515;
    text-align: center;
}

.benefits-list {
    list-style: none;
    padding: 0;
    display: inline-block;
    text-align: left;
    margin-top: 30px;
}

.benefits-list li {
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.benefits-list strong {
    color: var(--color-primary);
}

.cta-section {
    padding: 80px 0;
    text-align: center;
}

.cta-section h2 {
    font-family: 'Poppins', sans-serif;
    font-size: 2.5rem;
}

.cta-section p {
    font-size: 1.1rem;
    color: #E8E8E8;
    margin-top: 10px;
    margin-bottom: 30px;
}

.cta-button {
    font-size: 1.2rem;
    padding: 15px 40px;
}

/* --- Sección de Galería --- */
.gallery-section {
    padding: 80px 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
    margin-top: 50px;
}

.gallery-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    height: 280px;
    background-color: var(--color-secondary);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease-in-out;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
    padding: 40px 20px 20px 20px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease-in-out, transform 0.4s ease-in-out;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
    transform: translateY(0);
}

.gallery-project {
    font-family: 'Poppins', sans-serif;
    font-weight: bold;
    color: white;
    font-size: 1.1rem;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.7);
}

.gallery-author {
    color: #E8E8E8;
    font-size: 0.9rem;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

/* --- Estilos para la animación de scroll --- */
.projects-section, .platforms-section, .about-section, .news-section, .gallery-section {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.projects-section.show, .platforms-section.show, .about-section.show, .news-section.show, .gallery-section.show {
    opacity: 1;
    transform: translateY(0);
}
