/* ==========================================================================
   CHILE RP - SISTEMA LEGACY (BLUE TACTICAL THEME)
   v2.2 - Footer Compacto
   ========================================================================== */

/* --- 1. FUENTES Y VARIABLES GLOBALES --- */
@import url('https://fonts.googleapis.com/css2?family=Teko:wght@500;700&family=Roboto:wght@400;500;700&display=swap');

:root {
    /* Tipografías */
    --font-display: 'Teko', sans-serif;
    --font-body: 'Roboto', sans-serif;

    /* PALETA DE COLORES: AZUL TÁCTICO (Slate & Sky) */
    --primary-accent: #0ea5e9;       /* Sky 500 */
    --primary-accent-hover: #38bdf8; /* Sky 400 */
    --primary-accent-text: #ffffff;

    /* Fondos y Superficies */
    --dark-bg: #0f172a;              /* Slate 900 */
    --dark-surface: #1e293b;         /* Slate 800 */
    
    /* Elementos de UI */
    --border-color: #334155;         /* Slate 700 */
    --text-primary: #f1f5f9;         /* Slate 100 */
    --text-secondary: #94a3b8;       /* Slate 400 */

    /* Propiedades Globales */
    --main-border-radius: 12px;
    --transition-speed: 0.2s;
}

/* --- 2. RESET Y ESTRUCTURA BASE --- */
html { 
    scroll-behavior: smooth; 
}

body {
    font-family: var(--font-body);
    background-color: var(--dark-bg);
    color: var(--text-primary);
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

#main-content {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    width: 100%;
}

main { 
    flex-grow: 1; 
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center; 
    align-items: center;
}

.container { 
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 0 1rem; 
}

/* Fondo de Video */
#video-bg {
    position: fixed; 
    right: 0; 
    bottom: 0;
    min-width: 100%; 
    min-height: 100%;
    z-index: -2;
    object-fit: cover;
    filter: brightness(0.25) blur(2px);
}

/* --- 3. BARRA DE NAVEGACIÓN --- */
.main-navbar {
    background-color: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    padding: 0.75rem 1rem;
    position: sticky; 
    top: 0; 
    z-index: 1000;
    width: 100%;
    box-sizing: border-box;
}

.navbar-content { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    position: relative;
}

.navbar-brand { 
    display: flex; 
    align-items: center; 
    gap: 15px; 
    text-decoration: none; 
}

.navbar-brand img { 
    height: 40px; 
    transition: transform var(--transition-speed) ease; 
}

.navbar-brand:hover img { 
    transform: rotate(-5deg); 
}

.navbar-brand span { 
    font-family: var(--font-display); 
    font-size: 1.8rem; 
    color: var(--text-primary); 
    letter-spacing: 1px; 
}

.navbar-links a {
    color: var(--text-secondary);
    font-weight: 500;
    margin: 0 0.5rem;
    padding: 8px 12px;
    border-radius: var(--main-border-radius);
    text-decoration: none;
    transition: all var(--transition-speed);
}

.navbar-links a:hover {
    color: var(--text-primary);
    background-color: var(--dark-surface);
}

.user-balance-capsule { 
    background-color: var(--dark-surface); 
    color: var(--text-primary); 
    padding: 6px 16px; 
    border-radius: 999px; 
    font-weight: 600; 
    border: 1px solid var(--border-color); 
    white-space: nowrap; 
}

@media (min-width: 992px) {
    .user-balance-capsule { 
        position: absolute; 
        left: 50%; 
        transform: translateX(-50%); 
    }
}

.menu-toggle { display: none; font-size: 1.5rem; color: var(--text-primary); cursor: pointer; background: none; border: none; }

@media (max-width: 768px) {
    .navbar-links { 
        display: none; 
        position: fixed; 
        top: 67px; 
        right: 0; 
        width: 100%; 
        height: calc(100% - 67px); 
        background-color: var(--dark-bg); 
        flex-direction: column; 
        align-items: center; 
        padding-top: 2rem; 
        gap: 1.5rem; 
    }
    .navbar-links.active { display: flex; }
    .menu-toggle { display: block; }
}


/* --- 4. PANEL DE LOGIN --- */
.login-container {
    width: 100%;
    padding: 1rem;
}

.login-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.25rem;
    width: 100%;
    max-width: 900px;
}

.login-panel {
    max-width: 450px;
    width: 100%;
    padding: 3rem 2.5rem;
    background-color: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
}

.login-logo {
    width: 100px;
    margin-bottom: 1.5rem;
}

.login-panel h1 {
    font-family: var(--font-display);
    font-size: 3rem;
    margin: 0 0 0.5rem 0;
    color: white;
    text-transform: uppercase;
    letter-spacing: 2px;
    line-height: 1;
}

.login-panel p {
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    font-size: 1.1rem;
    line-height: 1.6;
}

#cta-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    width: 100%;
}

/* --- 5. BOTONES --- */
.btn-cta {
    font-family: var(--font-body);
    font-size: 1rem;
    padding: 14px 20px;
    border-radius: var(--main-border-radius);
    border: 1px solid var(--border-color);
    background-color: var(--dark-surface);
    color: var(--text-primary);
    transition: all 0.2s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    width: 100%;
    gap: 12px;
    box-sizing: border-box;
}

.btn-cta:hover {
    transform: translateY(-2px);
    border-color: var(--primary-accent);
    box-shadow: 0 5px 20px rgba(14, 165, 233, 0.25);
    text-decoration: none;
    color: white;
    background-color: rgba(30, 41, 59, 0.8);
}

.btn-cta i, .btn-cta svg {
    font-size: 1.5rem;
    width: 1.5rem;
    height: 1.5rem;
    flex-shrink: 0;
}

.btn-cta.discord {
    background-color: #5865F2;
    border: 1px solid #5865F2;
    color: white !important;
}

.btn-cta.discord:hover {
    background-color: #4752c4;
    box-shadow: 0 5px 20px rgba(88, 101, 242, 0.4);
}

.special-logins {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.special-logins a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease;
}

.special-logins a:hover {
    color: var(--primary-accent);
}

.special-logins span {
    color: var(--border-color);
    font-size: 0.8rem;
}


/* --- 6. MODALES --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    padding: 1rem;
    animation: fadeIn 0.3s ease-out forwards;
}

.modal-content {
    background-color: var(--dark-surface);
    padding: 2rem;
    border-radius: var(--main-border-radius);
    border: 1px solid var(--border-color);
    width: 100%;
    max-width: 600px;
    box-shadow: 0 25px 50px rgba(0,0,0,0.5);
    color: var(--text-primary);
    animation: scaleUp 0.3s ease-out forwards;
}

.modal-content h3 {
    font-family: var(--font-display);
    font-size: 2rem;
    color: var(--primary-accent);
    margin-top: 0;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

.modal-content .form-group { margin-bottom: 1.25rem; }

.modal-content label {
    display: block;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.modal-content input, 
.modal-content textarea, 
.modal-content select {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--dark-bg);
    color: var(--text-primary);
    font-size: 1rem;
    transition: border-color var(--transition-speed);
    box-sizing: border-box;
}

.modal-content input:focus, 
.modal-content textarea:focus {
    outline: none;
    border-color: var(--primary-accent);
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 2rem;
}

.modal-actions button {
    padding: 10px 20px;
    border-radius: 8px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.modal-actions .btn-primary {
    background-color: var(--primary-accent);
    color: white;
}
.modal-actions .btn-primary:hover {
    background-color: var(--primary-accent-hover);
}

.modal-actions .btn-secondary {
    background-color: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
}
.modal-actions .btn-secondary:hover {
    background-color: var(--dark-bg);
    color: var(--text-primary);
}


/* --- 7. FOOTER COMPACTO --- */
.footer {
    background-color: var(--dark-bg);
    border-top: 1px solid var(--border-color);
    padding: 30px 0 20px 0; /* REDUCIDO: Mucho más compacto */
    color: var(--text-secondary);
    width: 100%;
    flex-shrink: 0;
    margin-top: auto;
}

.footer .container {
    padding: 0 1rem;
}

.footer-content { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); 
    gap: 2rem; 
}

.footer-column h5 { 
    font-family: var(--font-display); 
    font-size: 1.3rem; 
    color: var(--text-primary); 
    margin-bottom: 0.8rem; /* REDUCIDO: Menos margen título */
    letter-spacing: 1px;
}

.footer-column ul { list-style: none; padding: 0; margin: 0; }
.footer-column li { margin-bottom: 0.4rem; } /* REDUCIDO: Menos margen items */

.footer-column a { 
    color: var(--text-secondary); 
    text-decoration: none; 
    transition: color 0.2s ease; 
}

.footer-column a:hover { 
    color: var(--primary-accent); 
}

.social-icons { display: flex; gap: 1rem; }
.social-icons a { 
    font-size: 1.4rem; 
    color: var(--text-secondary); 
    transition: transform 0.2s, color 0.2s; 
}
.social-icons a:hover { 
    color: var(--primary-accent); 
    transform: translateY(-2px); 
}

.footer-bottom { 
    border-top: 1px solid var(--border-color); 
    padding-top: 1rem;   /* REDUCIDO */
    margin-top: 1.5rem;  /* REDUCIDO */
    text-align: center; 
    font-size: 0.85rem; 
    opacity: 0.7;
}


/* --- 8. UTILIDADES --- */
.hidden { display: none !important; }

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scaleUp {
    from { transform: scale(0.95); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}