﻿/* Login Page Styles */
body {
    margin: 0;
    padding: 0;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(to bottom, #111, #1a1a1a, #222);
    color: #eee;
    min-height: 100vh;
    overflow: hidden;
    position: relative;
}

/* Background Canvas Styles */
#background-canvas {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 0 !important;
    pointer-events: none !important;
}

.login-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    /* Remove padding from container, add to card instead */
    padding: 0;
}

.login-card {
    background: rgba(26, 26, 26, 0.95);
    border: 1px solid rgb(218, 135, 39);
    border-radius: 12px;
    padding: 3rem 2.5rem;
    width: 100%;
    max-width: 400px;
    backdrop-filter: blur(20px);
    box-shadow:
            0 8px 32px rgba(0, 0, 0, 0.6),
            0 0 0 1px rgba(218, 135, 39, 0.3),
            0 0 30px rgba(218, 135, 39, 0.4);
    position: relative;
}

.login-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.login-header h1 {
    margin: 0 0 0.5rem 0;
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
    background: linear-gradient(
            45deg,
            rgb(218, 135, 39),
            #ffd700,
            rgb(255, 165, 0),
            rgb(218, 135, 39)
    );
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientScroll 3s ease infinite;
}

@keyframes gradientScroll {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.login-subtitle {
    color: #aaa;
    margin: 0;
    font-size: 0.9rem;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    color: #eee;
    font-weight: 500;
    font-size: 0.9rem;
}

.form-group input {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid #555;
    border-radius: 6px;
    color: #eee;
    padding: 0.75rem 1rem;
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
    width: 100%;
}

.form-group input:focus {
    outline: none;
    border-color: rgb(218, 135, 39);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 2px rgba(218, 135, 39, 0.3);
}

.form-group input::placeholder {
    color: #888;
}

.login-btn {
    background: linear-gradient(135deg, rgb(218, 135, 39), #e69c4a);
    border: none;
    border-radius: 6px;
    color: #111;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
    width: 100%;
    box-sizing: border-box;
}

.login-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #e69c4a, rgb(218, 135, 39));
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(218, 135, 39, 0.4);
}

.login-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.btn-text {
    transition: opacity 0.2s ease;
}

.btn-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid transparent;
    border-top: 2px solid #111;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.error-message {
    background: rgba(198, 40, 40, 0.3);
    border: 1px solid rgba(198, 40, 40, 0.6);
    border-radius: 6px;
    color: #ff6b6b;
    padding: 0.75rem 1rem;
    text-align: center;
    font-size: 0.9rem;
    margin-top: 1rem;
    backdrop-filter: blur(10px);
    width: 100%;
}

.hidden {
    display: none !important;
}

/* Responsive Design */
@media (max-width: 480px) {
    .login-card {
        padding: 2rem 1.5rem;
        margin: 0 1rem; /* Less margin on mobile */
    }

    .login-header h1 {
        font-size: 1.75rem;
    }
}