/* =============================================
   FTTH Insight Hub - Login Page
   ============================================= */

body {
    font-family: 'Nunito', sans-serif;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background: #0f172a;
    overflow-x: hidden;
}

.auth-wrapper {
    min-height: 100vh;
    position: relative;
}

/* Background Animation */
.auth-background {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 50%, #312e81 100%);
    z-index: 0;
}

.network-nodes .node {
    position: absolute;
    width: 6px; height: 6px;
    background: #818cf8;
    border-radius: 50%;
    animation: pulse 3s infinite;
}

.node:nth-child(1) { top: 15%; left: 10%; animation-delay: 0s; }
.node:nth-child(2) { top: 25%; left: 85%; animation-delay: 0.5s; }
.node:nth-child(3) { top: 60%; left: 20%; animation-delay: 1s; }
.node:nth-child(4) { top: 75%; left: 75%; animation-delay: 1.5s; }
.node:nth-child(5) { top: 40%; left: 50%; animation-delay: 2s; }
.node:nth-child(6) { top: 85%; left: 40%; animation-delay: 0.3s; }
.node:nth-child(7) { top: 10%; left: 60%; animation-delay: 0.8s; }
.node:nth-child(8) { top: 50%; left: 90%; animation-delay: 1.3s; }

.floating-shapes .shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.05;
    animation: float 20s infinite linear;
}

.shape-1 { width: 300px; height: 300px; background: #6366f1; top: -100px; right: -100px; }
.shape-2 { width: 200px; height: 200px; background: #818cf8; bottom: -50px; left: -50px; animation-delay: 7s; }
.shape-3 { width: 150px; height: 150px; background: #a5b4fc; top: 50%; left: 30%; animation-delay: 14s; }

@keyframes pulse {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.8); }
}

@keyframes float {
    0% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-30px) rotate(180deg); }
    100% { transform: translateY(0) rotate(360deg); }
}

/* Content Layout */
.auth-content-wrapper {
    position: relative;
    z-index: 1;
    display: flex;
    min-height: 100vh;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

/* Illustration */
.auth-illustration {
    display: none;
}

@media (min-width: 992px) {
    .auth-content-wrapper {
        justify-content: space-between;
        max-width: 1100px;
        margin: 0 auto;
    }

    .auth-illustration {
        display: flex;
        flex: 1;
        align-items: center;
        justify-content: center;
        padding: 2rem;
    }

    .illustration-content {
        text-align: center;
        max-width: 420px;
    }

    .hero-svg {
        width: 100%;
        max-width: 380px;
        margin-bottom: 2rem;
    }

    .illustration-text h2 {
        color: #fff;
        font-weight: 800;
        font-size: 1.75rem;
        margin-bottom: 0.75rem;
    }

    .illustration-text p {
        color: #a5b4fc;
        font-size: 1rem;
        line-height: 1.6;
    }
}

/* Login Card */
.auth-floating-box {
    width: 100%;
    max-width: 420px;
}

.login-card {
    background: #fff;
    border-radius: 1rem;
    padding: 2.5rem 2rem;
    box-shadow: 0 25px 50px rgba(0,0,0,0.25);
}

.app-brand-logo img {
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
}

.app-brand-text .fs-5 {
    color: #1f2937;
    letter-spacing: 0.03em;
}

/* Form */
.form-control {
    border: 2px solid #e5e7eb;
    border-radius: 0.625rem;
    font-size: 0.9375rem;
    transition: all 0.2s;
}

.form-control:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99,102,241,0.15);
}

.form-label {
    font-weight: 600;
    font-size: 0.875rem;
    color: #374151;
}

/* Login Button */
.btn-login {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    border: none;
    padding: 0.75rem;
    font-size: 0.9375rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    transition: all 0.3s;
}

.btn-login:hover {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    transform: translateY(-1px);
    box-shadow: 0 8px 16px rgba(99,102,241,0.35);
}

.text-brand {
    color: #6366f1;
}

/* SVG Animations */
.pulse-dot { animation: svgPulse 2s infinite; }
@keyframes svgPulse {
    0%, 100% { r: 8; opacity: 1; }
    50% { r: 12; opacity: 0.7; }
}

.wave { animation: waveAnim 2s infinite ease-in-out; }
.wave-2 { animation-delay: 0.3s; }
.wave-3 { animation-delay: 0.6s; }
@keyframes waveAnim {
    0%, 100% { opacity: 0.2; transform: translateX(0); }
    50% { opacity: 0.8; transform: translateX(5px); }
}

.device { animation: deviceFloat 4s infinite ease-in-out; }
.device-2 { animation-delay: 1.3s; }
.device-3 { animation-delay: 2.6s; }
@keyframes deviceFloat {
    0%, 100% { transform: translate(var(--tx, 0), var(--ty, 0)); }
    50% { transform: translate(var(--tx, 0), calc(var(--ty, 0) - 10px)); }
}

.particle { animation: particleFloat 5s infinite ease-in-out; }
.p2 { animation-delay: 1s; } .p3 { animation-delay: 2s; }
.p4 { animation-delay: 3s; } .p5 { animation-delay: 4s; }
@keyframes particleFloat {
    0%, 100% { opacity: 0.3; transform: translateY(0); }
    50% { opacity: 1; transform: translateY(-15px); }
}

.blink { animation: blinkAnim 1.5s infinite; }
@keyframes blinkAnim {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.2; }
}

.conn-line { animation: connPulse 3s infinite; }
@keyframes connPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.7; }
}

/* Preloader */
.preloader {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(255,255,255,0.95);
    z-index: 9999;
    display: flex; align-items: center; justify-content: center;
}
