/* ============================================================
   LOGIN — VisionOS / Tesla UI / Deep Blue PRO
   Page-specific styles (Inherits from base.css)
   ============================================================ */

.login-page {
    background: radial-gradient(circle at center, #0f172a 0%, #020617 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100dvh;
    padding: 20px;
    margin: 0;
    color: #f3f4f6;
    overflow: hidden;
}

/* Wrapper with GPU Optimized Animation */
.login-wrapper {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    animation: login-slide-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    will-change: transform, opacity;
}

@keyframes login-slide-up {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Card - Extends glass-card */
.login-card {
    background: transparent; /* Prevent double glass */
    border-radius: 32px;
    padding: 40px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Branding */
.login-card .logo {
    font-size: 26px;
    font-weight: 800;
    text-align: center;
    color: #ffffff;
    letter-spacing: 0.15em;
    text-shadow: 0 0 20px rgba(99, 102, 241, 0.3);
}

.login-subtitle {
    font-size: 14px;
    color: #94a3b8;
    text-align: center;
    margin-top: -12px;
}

/* Error Message (correct class name) */
.error-msg {
    background: rgba(239, 68, 68, 0.1);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 16px;
    padding: 12px 16px;
    font-size: 13px;
    text-align: center;
}

/* Form Groups */
.field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.field label {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-left: 4px;
}

/* Input Fields - Deep Blue Tesla Style */
.login-card input[type="email"],
.login-card input[type="text"],
.login-card input[type="password"] {
    width: 100%;
    height: 54px;
    padding: 0 18px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(15, 23, 42, 0.65);
    color: #ffffff;
    font-size: 16px; /* Prevents iOS auto-zoom */
    outline: none;
    transition: all 0.3s ease;
    box-sizing: border-box;
    appearance: none;
}

/* Autofill Polish */
.login-card input:-webkit-autofill {
    -webkit-text-fill-color: #ffffff !important;
    -webkit-box-shadow: 0 0 0px 1000px #1e293b inset !important;
    caret-color: white;
}

.login-card input:focus {
    background: rgba(15, 23, 42, 0.9);
    border-color: #6366f1;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.15);
}

/* Password Toggle Wrapper */
.input-wrapper {
    position: relative;
    width: 100%;
}

.show-pass {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 11px;
    font-weight: 800;
    color: #6366f1;
    cursor: pointer;
    text-transform: uppercase;
    padding: 12px;
    background: transparent;
    border: none;
    z-index: 2;
}

/* Options Area */
.form-options {
    margin-top: 4px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.remember {
    font-size: 14px;
    color: #94a3b8;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
}

/* Sign In Button */
.login-card .btn-primary {
    margin-top: 8px;
    width: 100%;
    height: 56px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 18px;
    border: none;
    cursor: pointer;
    color: #ffffff;
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    box-shadow: 0 10px 20px -5px rgba(99, 102, 241, 0.4);
    transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
}

.login-card .btn-primary:active {
    transform: scale(0.97);
    filter: brightness(0.9);
}

/* Mobile Adaptation */
@media (max-width: 480px) {
    .login-card {
        padding: 30px 24px;
        border-radius: 28px;
    }
    .login-card .logo { font-size: 24px; }
}
