/* ==========================================================================
   ARAZIPRO AUTH STYLES - Modern Login Page
   ========================================================================== */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    --secondary: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --dark: #0f172a;
    --dark-light: #1e293b;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --white: #ffffff;
    --font-main: 'Inter', -apple-system, sans-serif;
    --font-heading: 'Montserrat', sans-serif;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --radius: 14px;
    --radius-lg: 24px;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font-main);
    color: var(--gray-800);
    background: var(--dark);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* ============================================================
   LOGIN PAGE LAYOUT
   ============================================================ */
.login-page {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

/* ============================================================
   BACKGROUND
   ============================================================ */
.login-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

.bg-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #0a0e27 0%, #1a1f4b 40%, #0f172a 100%);
}

.bg-glow-1 {
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.25) 0%, transparent 70%);
    top: -150px;
    left: -100px;
    filter: blur(60px);
    animation: orbFloat 12s ease-in-out infinite;
}

.bg-glow-2 {
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.2) 0%, transparent 70%);
    bottom: -100px;
    right: -50px;
    filter: blur(60px);
    animation: orbFloat 10s ease-in-out infinite reverse;
}

.bg-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    opacity: 0.5;
}

.bg-particles {
    position: absolute;
    inset: 0;
}

/* ============================================================
   LOGIN CARD
   ============================================================ */
.login-card {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 440px;
    animation: cardSlideUp 0.6s ease-out;
}

.login-card-inner {
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-lg);
    padding: 48px 40px 36px;
    box-shadow: var(--shadow-xl);
}

/* Logo Area */
.login-logo-area {
    text-align: center;
    margin-bottom: 32px;
}

.login-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    margin-bottom: 16px;
}

.login-brand-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 22px;
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3);
    animation: iconPulse 3s ease-in-out infinite;
}

.login-brand-text {
    font-family: var(--font-heading);
    font-size: 28px;
    font-weight: 800;
    color: var(--dark);
    letter-spacing: -1px;
}

.login-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(37, 99, 235, 0.08);
    color: var(--primary);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.login-badge-dot {
    width: 6px;
    height: 6px;
    background: var(--primary);
    border-radius: 50%;
    animation: badgePulse 2s infinite;
}

/* Welcome Text */
.login-welcome {
    text-align: center;
    margin-bottom: 32px;
}

.login-welcome h1 {
    font-family: var(--font-heading);
    font-size: 26px;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.login-welcome p {
    color: var(--gray-500);
    font-size: 15px;
}

/* ============================================================
   FORM
   ============================================================ */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 8px;
}

.input-wrapper {
    position: relative;
}

.input-wrapper i:first-child {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-400);
    font-size: 16px;
    transition: var(--transition);
}

.input-wrapper input {
    width: 100%;
    padding: 14px 44px 14px 48px;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius);
    font-family: var(--font-main);
    font-size: 15px;
    color: var(--gray-800);
    background: var(--white);
    transition: var(--transition);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.input-wrapper input:focus + .toggle-password + i,
.input-wrapper input:focus ~ i:first-child {
    color: var(--primary);
}

.input-wrapper input::placeholder { color: var(--gray-400); }

.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--gray-400);
    cursor: pointer;
    font-size: 15px;
    padding: 0;
    transition: var(--transition);
}

.toggle-password:hover { color: var(--gray-700); }

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    margin-top: 2px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    color: var(--gray-600);
    font-weight: 500;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
    cursor: pointer;
}

.forgot-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 13px;
    transition: var(--transition);
}

.forgot-link:hover { text-decoration: underline; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: var(--radius);
    font-family: var(--font-main);
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-lg {
    padding: 16px 32px;
    font-size: 16px;
    border-radius: var(--radius);
}

.btn-block { width: 100%; }

/* Loading state */
.btn.loading {
    position: relative;
    color: transparent !important;
    pointer-events: none;
}

.btn.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: var(--white);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* ============================================================
   DIVIDER & REGISTER
   ============================================================ */
.login-divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 28px 0;
    color: var(--gray-400);
    font-size: 13px;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--gray-200);
}

.login-register {
    text-align: center;
    margin-bottom: 28px;
}

.login-register p {
    font-size: 14px;
    color: var(--gray-600);
}

.login-register a {
    color: var(--primary);
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
}

.login-register a:hover { text-decoration: underline; }

.checkbox-label a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

.checkbox-label a:hover { text-decoration: underline; }

/* ============================================================
   MINI STATS
   ============================================================ */
.login-mini-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding-top: 24px;
    border-top: 1px solid var(--gray-200);
}

.mini-stat {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 16px;
    color: var(--gray-500);
    font-size: 12px;
    font-weight: 600;
}

.mini-stat i {
    color: var(--primary);
    font-size: 13px;
}

.mini-stat-divider {
    width: 1px;
    height: 20px;
    background: var(--gray-200);
}

/* ============================================================
   FOOTER
   ============================================================ */
.login-footer {
    position: relative;
    z-index: 2;
    margin-top: 24px;
    text-align: center;
}

.login-footer p {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.4);
}

/* ============================================================
   TOAST
   ============================================================ */
.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--danger);
    color: var(--white);
    padding: 14px 24px;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 10000;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.toast.success { background: var(--secondary); }

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes cardSlideUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes orbFloat {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(40px, -30px); }
}

@keyframes iconPulse {
    0%, 100% { box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3); }
    50% { box-shadow: 0 8px 30px rgba(37, 99, 235, 0.5); }
}

@keyframes badgePulse {
    0% { box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.5); }
    70% { box-shadow: 0 0 0 8px rgba(37, 99, 235, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 99, 235, 0); }
}

@keyframes floatParticle {
    0%, 100% { transform: translateY(0) translateX(0); opacity: 0.3; }
    25% { transform: translateY(-20px) translateX(10px); opacity: 0.8; }
    50% { transform: translateY(-10px) translateX(-5px); opacity: 0.5; }
    75% { transform: translateY(-30px) translateX(5px); opacity: 0.9; }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 480px) {
    .login-page { padding: 20px 16px; }
    
    .login-card-inner {
        padding: 32px 24px;
    }
    
    .login-brand-text { font-size: 24px; }
    
    .login-welcome h1 { font-size: 22px; }
    
    .login-mini-stats {
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .mini-stat-divider { display: none; }
    
    .mini-stat {
        padding: 4px 8px;
        font-size: 11px;
    }
}
