/*
 * Enhanced Login Page Design
 * Modern, Clean, Beautiful
 */

/* ========================================
   1. Login Page Background
   ======================================== */
.login-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 20px;
    background:
        radial-gradient(circle at 20% 80%, rgba(37, 99, 235, 0.15), transparent 40%),
        radial-gradient(circle at 80% 20%, rgba(99, 102, 241, 0.12), transparent 40%),
        radial-gradient(circle at 50% 50%, rgba(59, 130, 246, 0.08), transparent 50%),
        linear-gradient(135deg, #f0f4ff 0%, #e0e7ff 50%, #e8eeff 100%);
    background-attachment: fixed;
}

/* Animated particles in background */
.login-page::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        radial-gradient(circle at 25% 25%, rgba(147, 197, 253, 0.4) 1px, transparent 1px),
        radial-gradient(circle at 75% 75%, rgba(167, 139, 250, 0.3) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: particle-drift 60s linear infinite;
    pointer-events: none;
    opacity: 0.4;
}

@keyframes particle-drift {
    0% { background-position: 0 0, 25px 25px; }
    100% { background-position: 50px 50px, 75px 75px; }
}

/* ========================================
   2. Login Shell - Card Container
   ======================================== */
.login-shell {
    width: min(1100px, 100%);
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 0;
    border-radius: 24px;
    overflow: hidden;
    background: #ffffff;
    box-shadow:
        0 20px 60px rgba(37, 99, 235, 0.15),
        0 8px 24px rgba(30, 58, 138, 0.08);
    animation: slideUp 0.6s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   3. Left Panel - Info Section
   ======================================== */
.login-panel-info {
    padding: 50px 45px;
    background: linear-gradient(135deg, #1e40af 0%, #3b82f6 50%, #6366f1 100%);
    color: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

/* Decorative gradient overlay */
.login-panel-info::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.15), transparent 40%),
        radial-gradient(circle at 80% 70%, rgba(99, 102, 241, 0.3), transparent 50%);
    pointer-events: none;
}

.login-panel-info > * {
    position: relative;
    z-index: 1;
}

/* Brand Row */
.login-brand-row {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 30px;
}

.login-brand-row .brand-logo {
    width: 72px;
    height: 72px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    display: grid;
    place-items: center;
    font-size: 32px;
    font-weight: 900;
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.login-brand-row .brand-logo.has-image {
    padding: 8px;
    background: rgba(255, 255, 255, 0.95);
}

.login-brand-row .brand-logo.has-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.login-kicker {
    color: rgba(255, 255, 255, 0.85);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.login-brand-row h1 {
    margin: 6px 0 0;
    font-size: 32px;
    font-weight: 900;
    color: #ffffff;
    line-height: 1.2;
}

/* Lead Text */
.login-lead {
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    line-height: 1.6;
    margin: 0 0 35px;
}

/* Feature Grid */
.login-feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 30px;
}

.login-feature {
    padding: 20px 16px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    text-align: center;
    transition: all 0.3s ease;
}

.login-feature:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-4px);
}

.login-feature i {
    display: block;
    font-size: 28px;
    color: #a5f3fc;
    margin-bottom: 12px;
}

.login-feature span {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.login-feature strong {
    display: block;
    margin-top: 4px;
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
}

/* Login Note */
.login-note {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: 999px;
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #d1fae5;
    font-size: 13px;
    font-weight: 600;
}

.login-note i {
    font-size: 18px;
}

/* ========================================
   4. Right Panel - Login Form
   ======================================== */
.login-panel.login-card {
    padding: 50px 40px;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Brand Login Header */
.brand-login {
    text-align: center;
    margin-bottom: 32px;
}

.brand-login .login-mark {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    border-radius: 16px;
    background: linear-gradient(135deg, #eff6ff, #dbeafe);
    color: #2563eb;
    display: grid;
    place-items: center;
    font-size: 28px;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
}

.brand-login h2 {
    margin: 0 0 8px;
    font-size: 28px;
    font-weight: 900;
    color: #1e293b;
}

.brand-login p {
    margin: 0;
    color: #64748b;
    font-size: 14px;
}

/* Discord Button */
.btn-discord {
    background: #5865f2;
    border: none;
    border-radius: 12px;
    color: #ffffff;
    font-weight: 700;
    padding: 14px 24px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(88, 101, 242, 0.25);
}

.btn-discord:hover:not(:disabled) {
    background: #4752c4;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(88, 101, 242, 0.35);
    color: #ffffff;
}

.btn-discord:disabled {
    background: #cbd5e1;
    color: #94a3b8;
    cursor: not-allowed;
    box-shadow: none;
}

/* Divider */
.login-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
    color: #94a3b8;
    font-size: 13px;
    font-weight: 600;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e2e8f0;
}

/* Form Inputs */
.form-label {
    color: #334155;
    font-weight: 700;
    font-size: 13px;
    margin-bottom: 8px;
}

.input-with-icon {
    position: relative;
}

.input-with-icon i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 18px;
    pointer-events: none;
    z-index: 2;
}

.input-with-icon .form-control {
    padding-left: 48px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    min-height: 52px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.input-with-icon .form-control:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

/* Submit Button */
.login-submit {
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    border: none;
    border-radius: 12px;
    min-height: 52px;
    font-weight: 800;
    font-size: 15px;
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.25);
    transition: all 0.3s ease;
}

.login-submit:hover {
    background: linear-gradient(135deg, #1d4ed8, #2563eb);
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(37, 99, 235, 0.35);
}

/* Login Hint */
.login-hint {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px 16px;
    font-size: 13px;
    color: #64748b;
    font-weight: 600;
}

/* ========================================
   5. Alert Styling
   ======================================== */
.alert {
    border-radius: 12px;
    border: none;
    font-weight: 600;
    margin-bottom: 20px;
}

.alert-danger {
    background: #fef2f2;
    color: #dc2626;
}

/* ========================================
   6. Responsive Design
   ======================================== */
@media (max-width: 992px) {
    .login-shell {
        grid-template-columns: 1fr;
        max-width: 480px;
    }

    .login-panel-info {
        padding: 40px 30px;
    }

    .login-brand-row h1 {
        font-size: 26px;
    }

    .login-feature-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

@media (max-width: 576px) {
    .login-page {
        padding: 16px;
    }

    .login-shell {
        border-radius: 20px;
    }

    .login-panel-info,
    .login-panel.login-card {
        padding: 32px 24px;
    }

    .brand-login h2 {
        font-size: 24px;
    }
}

/* ========================================
   7. Subtle Animations
   ======================================== */
.login-feature {
    animation: fadeInUp 0.6s ease-out backwards;
}

.login-feature:nth-child(1) { animation-delay: 0.1s; }
.login-feature:nth-child(2) { animation-delay: 0.2s; }
.login-feature:nth-child(3) { animation-delay: 0.3s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
