:root {
    --primary: #0f172a;
    /* Deep Space Navy */
    --primary-light: #1e293b;
    /* Lighter Navy for Cards */
    --accent: #20C997;
    /* Neon Teal/Green */
    --accent-glow: rgba(32, 201, 151, 0.5);
    --text-main: #ffffff;
    --text-muted: #94a3b8;
    --white: #ffffff;
    --error: #ef4444;
    --success: #20C997;
    --gradient-bg: radial-gradient(circle at 50% 0%, #1e3a8a 0%, #0f172a 100%);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--primary);
    background-image: var(--gradient-bg);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    margin: 0;
    color: var(--text-main);
}

.login-container,
.signup-container {
    background: rgba(30, 41, 59, 0.7);
    /* Glassmorphism */
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    padding: 3rem;
    width: 100%;
    max-width: 420px;
    position: relative;
    overflow: hidden;
}

/* Add a subtle top light effect */
.login-container::before,
.signup-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(32, 201, 151, 0.5), transparent);
}

.logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1;
    margin-bottom: 2rem;
}

.logo .top-line {
    font-size: 0.875rem;
    color: var(--accent);
    text-transform: lowercase;
    font-weight: 700;
    text-shadow: 0 0 10px var(--accent-glow);
    /* Glow Effect */
    margin-bottom: 2px;
}

.logo .bottom-line {
    font-size: 1.75rem;
    color: var(--white);
    text-transform: uppercase;
    font-weight: 900;
    letter-spacing: 0.05em;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    /* Subtle White Glow */
}

h1 {
    text-align: center;
    font-size: 1.75rem;
    color: var(--white);
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.subtitle {
    text-align: center;
    color: var(--text-muted);
    margin-bottom: 2rem;
    font-size: 0.95rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.form-group input {
    width: 100%;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    font-size: 1rem;
    color: var(--white);
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.form-group input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(32, 201, 151, 0.1);
    background: rgba(15, 23, 42, 0.9);
}

.form-group input::placeholder {
    color: rgba(148, 163, 184, 0.5);
}

.btn {
    width: 100%;
    padding: 1rem;
    background: var(--accent);
    color: #0f172a;
    /* Dark text for contrast against Neon Green */
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    box-shadow: 0 0 15px var(--accent-glow);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 25px var(--accent-glow);
    background: #34d399;
    /* Slightly lighter green on hover */
}

.btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.forgot-link {
    text-align: right;
    margin-top: 0.75rem;
}

.forgot-link a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    transition: color 0.3s ease;
}

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

.signup-link,
.auth-links {
    text-align: center;
    margin-top: 2rem;
    color: var(--text-muted);
}

.signup-link a,
.auth-links a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.signup-link a:hover,
.auth-links a:hover {
    color: #ffffff;
    text-shadow: 0 0 10px var(--accent-glow);
}

.back-link {
    display: block;
    text-align: center;
    margin-top: 2rem;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.back-link:hover {
    opacity: 1;
    color: var(--white);
}

/* Alert Boxes Overhaul */
.alert {
    padding: 1rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    display: none;
    backdrop-filter: blur(4px);
}

.alert.error {
    background: rgba(239, 68, 68, 0.1);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.alert.success {
    background: rgba(32, 201, 151, 0.1);
    color: var(--accent);
    border: 1px solid rgba(32, 201, 151, 0.2);
}

.alert.show {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}