/* ══════════════════════════════════════════════════════════
   i-WebCMS — Premium Login Page with Particle Animation
   ══════════════════════════════════════════════════════════ */

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background: #000;
}

/* ── Particle Canvas ── */
#particleCanvas {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: auto;
}

/* ── Animated Glow Orbs ── */
.login-page::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: linear-gradient(-45deg, #020108, #0a0520, #030320, #010108, #080318, #020108);
    background-size: 400% 400%;
    animation: gradientShift 20s ease infinite;
    z-index: 0;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    25% { background-position: 100% 0%; }
    50% { background-position: 100% 50%; }
    75% { background-position: 0% 100%; }
    100% { background-position: 0% 50%; }
}

.login-page::after {
    content: '';
    position: absolute;
    width: 600px; height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(60,80,220,0.12) 0%, transparent 70%);
    top: -15%; right: -10%;
    animation: glowPulse 6s ease-in-out infinite;
    z-index: 0;
}

.login-orb-2 {
    position: absolute;
    width: 500px; height: 500px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(100,50,200,0.1) 0%, transparent 70%);
    bottom: -15%; left: -5%;
    animation: glowPulse 8s ease-in-out infinite reverse;
    z-index: 0;
}

.login-orb-3 {
    position: absolute;
    width: 300px; height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0,140,255,0.08) 0%, transparent 70%);
    top: 40%; left: 50%;
    transform: translate(-50%, -50%);
    animation: glowPulse 10s ease-in-out infinite 2s;
    z-index: 0;
}

@keyframes glowPulse {
    0%, 100% { transform: scale(1); opacity: 0.6; }
    50% { transform: scale(1.2); opacity: 1; }
}

/* ── Glass Card ── */
.login-card {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 420px;
    padding: 40px;
    background: rgba(8, 8, 20, 0.75);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-radius: 20px;
    border: 1px solid rgba(100, 130, 255, 0.12);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.6),
                0 0 80px rgba(60, 80, 220, 0.08),
                inset 0 1px 0 rgba(255, 255, 255, 0.04);
    animation: cardEnter 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* ── Glow border animation on card ── */
.login-card::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 21px;
    background: linear-gradient(135deg, rgba(100,130,255,0.2), transparent 40%, transparent 60%, rgba(140,80,220,0.2));
    z-index: -1;
    animation: borderGlow 4s ease-in-out infinite alternate;
}

@keyframes borderGlow {
    0% { opacity: 0.3; }
    100% { opacity: 0.8; }
}

.login-logo {
    width: 56px; height: 56px;
    border-radius: 14px;
    background: linear-gradient(135deg, #4060ff 0%, #7040cc 100%);
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 8px 32px rgba(80, 100, 255, 0.35), 0 0 60px rgba(80, 100, 255, 0.1);
    animation: logoGlow 3s ease-in-out infinite alternate;
}

@keyframes logoGlow {
    0% { box-shadow: 0 8px 32px rgba(80, 100, 255, 0.35), 0 0 60px rgba(80, 100, 255, 0.1); }
    100% { box-shadow: 0 8px 40px rgba(80, 100, 255, 0.5), 0 0 80px rgba(80, 100, 255, 0.15); }
}

.login-logo .mud-icon-root { color: white; font-size: 1.8rem; }

/* ── Animated Title (typewriter target) ── */
.login-title {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #f1f5f9;
    margin-bottom: 4px;
    min-height: 2em;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-title::after {
    content: '|';
    animation: blink 0.8s infinite;
    color: rgba(100, 130, 255, 0.8);
    margin-left: 2px;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.login-subtitle {
    text-align: center;
    font-size: 0.85rem;
    color: #64748b;
    margin-bottom: 32px;
}

/* ── Form Fields ── */
.login-card .mud-input-control { margin-bottom: 20px; }

.login-card .mud-input-outlined {
    border-color: rgba(100, 130, 255, 0.15) !important;
    border-radius: 10px !important;
    background: rgba(8, 8, 20, 0.4) !important;
    transition: all 0.25s ease !important;
}

.login-card .mud-input-outlined:hover { border-color: rgba(100, 130, 255, 0.3) !important; }

.login-card .mud-input-outlined.mud-focused,
.login-card .mud-input-focused .mud-input-outlined {
    border-color: #4060ff !important;
    box-shadow: 0 0 0 3px rgba(64, 96, 255, 0.15) !important;
    background: rgba(8, 8, 20, 0.6) !important;
}

.login-card .mud-input-label { color: #64748b !important; }
.login-card .mud-input-label.mud-focused { color: #8090ff !important; }

/* ── Submit Button ── */
.login-btn {
    height: 46px !important;
    border-radius: 10px !important;
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    letter-spacing: 0.01em;
    background: linear-gradient(135deg, #4060ff 0%, #7040cc 100%) !important;
    border: none !important;
    color: white !important;
    box-shadow: 0 4px 20px rgba(64, 96, 255, 0.35) !important;
    transition: all 0.25s ease !important;
    text-transform: none !important;
    margin-top: 8px;
}

.login-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 32px rgba(64, 96, 255, 0.5) !important;
}

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

/* ── Error Message ── */
.login-error {
    text-align: center;
    color: #fca5a5;
    font-size: 0.85rem;
    margin-bottom: 16px;
    padding: 10px;
    border-radius: 8px;
    background: rgba(255, 82, 82, 0.08);
    border: 1px solid rgba(255, 82, 82, 0.15);
}

/* ── Footer ── */
.login-footer {
    text-align: center;
    margin-top: 28px;
    font-size: 0.75rem;
    color: #3a4a5c;
    letter-spacing: 0.02em;
}

.login-card .mud-progress-circular { color: white !important; }

@media (max-width: 480px) {
    .login-card { margin: 16px; padding: 28px 24px; }
}
