:root {
    /* Paleta de colores Fuego: Naranja a Rojo */
    --primary-gradient: linear-gradient(135deg, #1a1a2e 0%, #0f0f1a 100%);
    --accent-color: #ff416c;
    /* Rojo fuego */
    --secondary-accent: #ff8c00;
    /* Naranja fuego */
    --fire-gradient: linear-gradient(135deg, #ff8c00 0%, #ff416c 100%);
}

body {
    background-color: #05050a;
    margin: 0;
    overflow: hidden;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    position: fixed;
    width: 100%;
}

/* Canvas para los fuegos artificiales */
#fireworksCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

.login-container {
    width: 100%;
    max-width: 420px;
    padding: 15px;
    z-index: 10;
    max-height: 100vh;
    overflow-y: auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card {
    border: none;
    border-radius: 1.5rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
    overflow: hidden;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    width: 100%;
}

.card-header {
    background: var(--fire-gradient);
    color: white;
    text-align: center;
    padding: 2.5rem 1.2rem;
    border: none;
}

.card-header h2 {
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 5px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    font-size: calc(1.4rem + 0.6vw);
}

.btn-primary {
    background: var(--fire-gradient);
    border: none;
    padding: 0.9rem;
    font-weight: 700;
    border-radius: 0.75rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 65, 108, 0.4);
    position: relative;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(255, 65, 108, 0.6);
    opacity: 0.95;
}

.form-control {
    padding: 0.8rem 1rem;
    border-radius: 0.75rem;
    background-color: rgba(255, 255, 255, 0.95);
    border: 1px solid #ddd;
    font-size: 16px;
}

.form-control:focus {
    box-shadow: 0 0 0 0.25rem rgba(255, 140, 0, 0.25);
    border-color: var(--secondary-accent);
}

.input-group-text {
    border-radius: 0.75rem;
    background-color: #f8f9fa;
    border-color: #ddd;
}

.icon-container {
    background: rgba(255, 255, 255, 0.25);
    width: 64px;
    height: 64px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    transform: rotate(-10deg);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

#togglePassword {
    border-left: none;
    background-color: #f8f9fa;
    color: #6c757d;
    border-top-right-radius: 0.75rem;
    border-bottom-right-radius: 0.75rem;
}

.hidden {
    display: none !important;
}

/* Ajustes Responsivos específicos */
@media (max-width: 480px) {
    .card-header {
        padding: 1.8rem 1rem;
    }

    .icon-container {
        width: 50px;
        height: 50px;
        margin-bottom: 0.8rem;
    }

    .card-body {
        padding: 1.5rem !important;
    }

    .login-container {
        padding: 10px;
    }
}

@media (max-height: 600px) {
    .card-header {
        padding: 1.2rem;
    }

    .icon-container {
        display: none;
    }

    .card-body {
        padding: 1rem !important;
    }
}

.text-accent {
    color: #d32f2f;
    font-weight: 600;
    cursor: pointer;
}

.form-check-input:checked {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
}

.back-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    margin-top: 1.5rem;
    text-decoration: none;
    color: #6c757d;
    font-weight: 600;
    transition: color 0.3s;
}

.back-link:hover {
    color: var(--accent-color);
}