/* --- ENLACE A FUENTES PROFESIONALES (Estilo Gaming/Aion) --- */
@import url('https://googleapis.com');

:root {
    /* Paleta corregida por ti (Tonos exactos de tu gradiente) */
    --bg-azul-acero: #4c6474;   /* Esquina superior izquierda */
    --bg-gris-morado: #49384e;  /* Esquina inferior derecha */
    
    --accent-elyos: #e6c687;    /* Dorado Elyos */
    --accent-asmodian: #9c6ca7; /* Morado Asmodian */
    
    --text-white: #ffffff;
    --text-silver: #d1d5db;
    --nav-height: 75px;
}

/* --- REINICIO GLOBAL --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-family: 'Montserrat', sans-serif;
    background-color: var(--bg-azul-acero);
    color: var(--text-white);
}

/* --- MENÚ SUPERIOR FLOTANTE --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--nav-height);
    background-color: rgba(51, 70, 84, 0.35); 
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 4rem;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08); 
}

.logo img {
    height: 60px;
    object-fit: contain;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 3rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-silver);
    font-size: 0.9rem;
    font-weight: 400;
    letter-spacing: 0.5px;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.nav-links a:hover, 
.nav-links a.active {
    color: var(--text-white);
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* --- SECCIONES ADAPTATIVAS CON TU DEGRADADO CONTINUO --- */
.full-screen-section {
    width: 100%;
    /* Altura mínima flexible para asegurar que los renders y textos no se corten abajo */
    min-height: 100vh; 
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    padding-top: calc(var(--nav-height) + 2rem);
    padding-bottom: 2rem;
    
    /* Tu degradado modificado a 45 grados */
    background: linear-gradient(45deg, var(--bg-gris-morado) 0%, #3e4453 50%, var(--bg-azul-acero) 100%) !important;
}

/* --- SECCIÓN 1: INICIO --- */
#inicio {
    background: linear-gradient(45deg, var(--bg-gris-morado) 0%, #3e4453 50%, var(--bg-azul-acero) 100%) !important;
    position: relative;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/aion_transparente_final.png');
    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;
    opacity: 0.95; 
    z-index: 1;    
     /* --- EFECTO DE DESENFOQUE SUTIL DE TU MAQUETA --- */
    filter: blur(3px); /* Aplica el desenfoque sin tocar los logotipos ni textos */
    
    /* --- NOTA CLAVE --- */
    transform: scale(1.03); /* Escala ligeramente la imagen para ocultar los bordes blancos/transparentes que genera el blur en las esquinas */

}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2.2rem;
    z-index: 2;
}

.main-logo {
    max-width: 540px;
    width: 85%;
    height: auto;
}

.welcome-text {
    font-family: 'Cinzel', serif;
    font-size: 1.6rem;
    color: var(--accent-elyos);
    text-shadow: 0 0 8px rgba(230, 198, 135, 0.4);
}

.btn-register {
    display: inline-block;
    padding: 0.9rem 3.5rem;
    background: linear-gradient(180deg, #25497b 0%, #162e54 100%);
    color: var(--text-white);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    letter-spacing: 0.8px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-register:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(37, 73, 123, 0.5);
}

.fecha-texto {
    font-size: 1.4rem;
    color: var(--text-silver);
    font-weight: 300;
    letter-spacing: 1px;
}

/* --- SECCIÓN 2: FACCIONES (Con Emblemas Flotantes Traseros) --- */
.facciones-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 1240px;
    min-height: 80vh; 
    justify-content: space-around;
    gap: 3rem; 
    z-index: 2;
}

.faccion {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    position: relative; 
}

.faccion-logo-bg {
    position: absolute;
    width: 340px; 
    height: 340px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center center;
    opacity: 0.12; 
    z-index: 1;    
    pointer-events: none; 
}

.elyos .faccion-logo-bg {
    background-image: url('../images/Elyos_Logo.webp');
    left: 110px; 
    top: 50%;
    transform: translateY(-50%);
}

.asmodians .faccion-logo-bg {
    background-image: url('../images/Asmodian_Logo.webp');
    right: 110px; 
    top: 50%;
    transform: translateY(-50%);
}

.faccion-info {
    max-width: 540px;
    text-align: center;
    padding: 1rem;
    position: relative;
    z-index: 3; 
}

.faccion-info h3 {
    font-family: 'Cinzel', serif;
    font-size: 2.4rem;
    letter-spacing: 3px;
    margin-bottom: 0.8rem;
    font-weight: 600;
}

.elyos h3 { 
    color: var(--accent-elyos); 
    text-shadow: 0 0 10px rgba(230, 198, 135, 0.2);
}

.asmodians h3 { 
    color: var(--accent-asmodian); 
    text-shadow: 0 0 10px rgba(156, 108, 167, 0.2);
}

.faccion-info p {
    font-size: 0.95rem;
    line-height: 1.65;
    color: var(--text-white);
    font-weight: 300;
}

.render-pj {
    height: 52vh; 
    max-height: 500px; 
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 15px 25px rgba(0, 0, 0, 0.45));
    position: relative;
    z-index: 3; 
    align-self: center; 
}

/* --- SECCIÓN 3: CLASES (ACORDEÓN FLEX UNIFICADO) --- */
#clases {
    background: linear-gradient(45deg, var(--bg-gris-morado) 0%, #3e4453 50%, var(--bg-azul-acero) 100%) !important;
}

#clases h2 {
    font-family: 'Cinzel', serif;
    font-size: 2.6rem;
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
    z-index: 2;
    font-weight: 600;
}

.clases-accordion {
    display: flex;
    width: 95%;
    max-width: 1200px;
    height: 68vh;
    gap: 0.5rem;
    z-index: 2;
}

.clase-card {
    position: relative;
    height: 100%;
    flex: 1; 
    cursor: pointer;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    filter: brightness(40%) grayscale(40%);
    transition: flex 0.5s cubic-bezier(0.25, 1, 0.5, 1), filter 0.4s ease, border-color 0.3s;
}

.clase-card.active {
    flex: 5; 
    filter: brightness(100%) grayscale(0%);
    border-color: var(--accent-elyos);
    cursor: default;
}

.clase-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.5s ease;
}

.clase-title {
    position: absolute;
    bottom: 2rem;
    left: 2rem;
    font-family: 'Cinzel', serif;
    font-size: 2.2rem;
    font-weight: 600;
    color: var(--text-white);
    text-shadow: 2px 2px 12px rgba(0, 0, 0, 0.95);
    white-space: nowrap;
    
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.clase-card.active .clase-title {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.2s; 
}

/* --- SECCIÓN 4: FOOTER --- */
.footer-content {
    text-align: center;
    color: var(--text-silver);
    z-index: 2;
}
/* --- NUEVA SECCIÓN DE NOTICIAS Y REDES EN FOOTER --- */
.news-section-container {
    width: 90%;
    max-width: 1200px;
    margin-bottom: 4rem;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.section-news-title {
    font-family: 'Cinzel', serif;
    font-size: 2.4rem;
    color: var(--accent-elyos);
    letter-spacing: 2px;
    margin-bottom: 2rem;
    text-shadow: 0 0 10px rgba(230, 198, 135, 0.2);
}

/* Contenedores y Controles del Carrusel */
.carousel-wrapper {
    position: relative;
    width: 100%;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.carousel-track-container {
    width: 100%;
    overflow: hidden;
    padding: 1rem 0;
}

.carousel-track {
    display: flex;
    gap: 1.5rem;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    width: 100%;
}

.carousel-control {
    background: rgba(22, 46, 84, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-white);
    font-size: 1.5rem;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.3s, transform 0.2s, border-color 0.3s;
    user-select: none;
    z-index: 10;
}

.carousel-control:hover {
    background: linear-gradient(180deg, #25497b 0%, #162e54 100%);
    border-color: var(--accent-elyos);
    transform: scale(1.05);
}

/* Tarjetas Informativas */
.news-card, .news-card-empty {
    flex: 0 0 calc(33.333% - 1rem); /* Por defecto muestra 3 tarjetas en escritorio */
    background: rgba(51, 70, 84, 0.25);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
    transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
}

@media (max-width: 992px) {
    .news-card, .news-card-empty { flex: 0 0 calc(50% - 0.75rem); } /* 2 en tablets */
}
@media (max-width: 600px) {
    .news-card, .news-card-empty { flex: 0 0 100%; } /* 1 en móviles */
}

.news-card:hover {
    transform: translateY(-4px);
    border-color: rgba(156, 108, 167, 0.4); /* Brillo sutil Asmodian */
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.news-card-img {
    width: 100%;
    height: 160px;
    background-position: center;
    background-size: cover;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.news-card-body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.news-card-body h4 {
    font-size: 1.15rem;
    color: #ffffff;
    margin-bottom: 0.6rem;
    font-weight: 500;
    line-height: 1.3;
}

.news-card-body p {
    font-size: 0.88rem;
    color: var(--text-silver);
    line-height: 1.5;
    margin-bottom: 1.5rem;
    display: -webkit-box;
   -webkit-line-clamp: 3; /* Corta textos muy extensos a 3 renglones */
   -webkit-box-orient: vertical; 
    overflow: hidden;
}

.news-meta {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
}

.news-date { color: var(--accent-elyos); }

/* --- SECCIÓN BOTONERA REDES SOCIALES --- */
.footer-promo-title {
    font-family: 'Cinzel', serif;
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.footer-subtext {
    font-size: 0.95rem;
    color: var(--text-silver);
    margin-bottom: 2rem;
}

.social-networks-box {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.social-link {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.8rem 2.2rem;
    border-radius: 4px;
    color: #ffffff;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

/* Iconos usando la codificación FontAwesome o UTF nativa si la acoplas */
.social-icon {
    font-family: sans-serif, "Font Awesome 5 Brands";
    font-weight: 400;
}

.social-link.facebook {
    background: linear-gradient(180deg, #3b5998 0%, #2d4373 100%);
}
.social-link.facebook:hover {
    border-color: #4e71ba;
    box-shadow: 0 0 15px rgba(59, 89, 152, 0.6);
    transform: translateY(-2px);
}

.social-link.youtube {
    background: linear-gradient(180deg, #c4302b 0%, #a62622 100%);
}
.social-link.youtube:hover {
    border-color: #e5413b;
    box-shadow: 0 0 15px rgba(196, 48, 43, 0.6);
    transform: translateY(-2px);
}
/* --- ESTILOS DE LA VENTANA MODAL DE NOTICIAS --- */
.news-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.news-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.news-modal-container {
    background: #232c33;
    border: 1px solid rgba(230, 198, 135, 0.25);
    box-shadow: 0 0 30px rgba(230, 198, 135, 0.15);
    width: 90%;
    max-width: 700px;
    max-height: 85vh;
    border-radius: 8px;
    overflow-y: auto;
    position: relative;
    display: flex;
    flex-direction: column;
    animation: modalSlide 0.3s ease forwards;
}

@keyframes modalSlide {
    from { transform: translateY(20px); }
    to { transform: translateY(0); }
}

.news-modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    background: rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    font-size: 2rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
    transition: background 0.2s, color 0.2s;
}
.news-modal-close:hover { background: #8b263e; color: #fff; }

.news-modal-banner {
    width: 100%;
    height: 260px;
    background-size: cover;
    background-position: center;
}

.news-modal-body { padding: 2rem; }

#modal-news-title {
    font-family: 'Cinzel', serif;
    font-size: 1.8rem;
    color: var(--accent-elyos);
    margin-bottom: 0.8rem;
    line-height: 1.3;
}

.news-modal-meta {
    font-size: 0.8rem;
    color: var(--text-silver);
    margin-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    padding-bottom: 0.8rem;
}

.news-modal-text {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #ffffff;
    white-space: pre-line; /* Mantiene saltos de línea del admin */
}
/* =========================================================
   MENÚ DESPLEGABLE (DROPDOWN) PARA NAVBAR
   ========================================================= */
.nav-links {
    display: flex;
    align-items: center;
    gap: 1.2rem;
}

.nav-links li {
    position: relative;
    white-space: nowrap; /* Evita que el texto se parta en dos líneas */
}

/* Botón disparador del desplegable */
.dropdown-toggle {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.dropdown-arrow {
    font-size: 0.7rem;
    transition: transform 0.25s ease;
}

.nav-dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
}

/* Caja flotante del submenú */
.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 210px;
    background: rgba(16, 20, 30, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    padding: 0.5rem 0;
    margin-top: 10px;
    list-style: none;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    z-index: 9999;
}

/* Puente invisible para que no se cierre al bajar el mouse */
.nav-dropdown::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 12px;
}

.nav-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Alinear el último menú (Usuario) a la derecha para que no se salga de pantalla */
.dropdown-menu-right {
    left: auto;
    right: 0;
}

.dropdown-menu li {
    width: 100%;
}

.dropdown-menu a {
    display: block;
    padding: 0.65rem 1.2rem;
    color: var(--text-silver, #cfd8e3);
    text-decoration: none;
    font-size: 0.92rem;
    transition: background 0.2s ease, color 0.2s ease, padding-left 0.2s ease;
}

.dropdown-menu a:hover,
.dropdown-menu a.active {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    padding-left: 1.5rem;
}

.dropdown-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0.4rem 0;
}

.dropdown-menu a.logout-item {
    color: #ff6b6b;
}

.dropdown-menu a.logout-item:hover {
    background: rgba(255, 107, 107, 0.12);
    color: #ff8787;
}