@import url("https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@300;400;500;600;700;800&display=swap");
*{box-sizing:border-box}body{margin:0;font-size:16px;line-height:1.5}button,input{font:inherit}h1{margin:0 0 8px;font-weight:500;line-height:1.2}p{margin:0 0 16px}[hidden]{display:none!important}.form-floating{position:relative}.form-control{display:block;width:100%;height:58px;line-height:1.25}.form-floating>label{position:absolute;top:0;left:0;height:100%;padding:16px 12px;pointer-events:none;transform-origin:0 0;transition:transform .1s,opacity .1s}.form-floating>.form-control:focus,.form-floating>.form-control:not(:placeholder-shown){padding-top:26px;padding-bottom:10px}.form-floating>.form-control:focus~label,.form-floating>.form-control:not(:placeholder-shown)~label{opacity:.65}.mb-4{margin-bottom:24px}.form-check-input{width:16px;height:16px}.input-icon{width:18px;height:18px;fill:currentColor}.password-toggle-btn svg,.btn-login svg{width:18px;height:18px;fill:currentColor}.btn-login svg{vertical-align:-3px;margin-right:8px}.login-footer-social svg{flex:none}.login-feedback:empty{display:none}.login-feedback{color:#842029;margin:0 0 20px}#setup-note{font-size:14px}button:disabled{opacity:.6;cursor:wait}

        body {
            background: #CFE2FF;
            min-height: 100vh;
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            overflow: hidden;
            position: relative;
        }
        
        /* Animated background elements */
        .bg-element {
            position: absolute;
            border-radius: 50%;
            background: rgba(255, 255, 255, 0.6);
            backdrop-filter: blur(8px);
            z-index: 0;
            box-shadow: 0 0 30px rgba(255, 255, 255, 0.4), 0 0 60px rgba(255, 255, 255, 0.2);
            border: 2px solid rgba(255, 255, 255, 0.8);
        }
        
        .element-1 {
            width: 300px;
            height: 300px;
            top: -100px;
            left: -100px;
            animation: float 15s infinite linear;
        }
        
        .element-2 {
            width: 200px;
            height: 200px;
            bottom: -70px;
            right: 10%;
            animation: float 12s infinite linear reverse;
        }
        
        .element-3 {
            width: 150px;
            height: 150px;
            top: 30%;
            right: -60px;
            animation: float 10s infinite linear;
        }
        
        .element-4 {
            width: 100px;
            height: 100px;
            top: 60%;
            left: -30px;
            animation: float 8s infinite linear reverse;
        }
        
        .element-5 {
            width: 80px;
            height: 80px;
            top: 10%;
            left: 60%;
            animation: float 14s infinite linear;
        }
        
        .element-6 {
            width: 120px;
            height: 120px;
            top: 70%;
            left: 20%;
            animation: float 11s infinite linear reverse;
        }
        
        .element-7 {
            width: 60px;
            height: 60px;
            top: 20%;
            left: 80%;
            animation: float 9s infinite linear;
        }
        
        .element-8 {
            width: 90px;
            height: 90px;
            top: 80%;
            right: 20%;
            animation: float 13s infinite linear reverse;
        }
        
        .element-9 {
            width: 40px;
            height: 40px;
            top: 50%;
            left: 10%;
            animation: float 7s infinite linear;
        }
        
        .element-10 {
            width: 70px;
            height: 70px;
            top: 15%;
            left: 30%;
            animation: float 16s infinite linear reverse;
        }
        
        @keyframes float {
            0% { transform: translate(0, 0) rotate(0deg); }
            25% { transform: translate(20px, 15px) rotate(90deg); }
            50% { transform: translate(0, 30px) rotate(180deg); }
            75% { transform: translate(-20px, 15px) rotate(270deg); }
            100% { transform: translate(0, 0) rotate(360deg); }
        }
        
        .login-container {
            min-height: 100vh;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 20px;
            position: relative;
            z-index: 10;
        }
        
        .login-card {
            background: #ffffff;
            border-radius: 15px;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
            border: 1px solid #dee2e6;
            overflow: hidden;
            max-width: 450px;
            width: 100%;
        }
        
        .login-header {
            background: linear-gradient(45deg, #1a2a6c, #b21f1f);
            color: white;
            padding: 30px;
            text-align: center;
            position: relative;
        }
        
        .login-header::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="50" cy="10" r="0.5" fill="rgba(255,255,255,0.05)"/><circle cx="10" cy="60" r="0.5" fill="rgba(255,255,255,0.05)"/><circle cx="90" cy="40" r="0.5" fill="rgba(255,255,255,0.05)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
            opacity: 0.3;
        }
        
        .login-header-content {
            position: relative;
            z-index: 2;
        }
        
        .logo-container {
            margin-bottom: 5px;
            width: 92px;
            height: 92px;
            margin-left: auto;
            margin-right: auto;
            border-radius: 50%;
            background: rgba(255, 255, 255, 0.16);
            display: flex;
            align-items: center;
            justify-content: center;
        }
        
        .logo-container img {
            filter: none;
            background: #ffffff;
            border-radius: 50%;
            height: 76px;
            width: 76px;
            object-fit: contain;
        }
        
        .login-subtitle {
            font-size: 1rem;
            opacity: 0.9;
            margin-bottom: 0;
        }
        
        .login-body {
            padding: 40px 30px;
        }
        
        .form-floating {
            margin-bottom: 20px;
        }
        
        .form-floating > .form-control {
            border: 2px solid #dee2e6;
            border-radius: 10px;
            padding: 1rem 0.75rem 0.25rem 3rem;
            font-size: 1rem;
            transition: all 0.3s ease;
        }
        
        .form-floating > .form-control:focus {
            border-color: #007bff;
            box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
        }
        
        .form-floating > label {
            padding-left: 3rem;
            color: #6c757d;
            font-weight: 500;
        }
        
        .input-icon {
            position: absolute;
            left: 1rem;
            top: 50%;
            transform: translateY(-50%);
            color: #6c757d;
            font-size: 1.1rem;
            z-index: 3;
            pointer-events: none;
        }

        .password-toggle-btn {
            position: absolute;
            right: 0.65rem;
            top: 50%;
            transform: translateY(-50%);
            z-index: 5;
            border: 0;
            background: transparent;
            color: #335c8d;
            width: 2.1rem;
            height: 2.1rem;
            padding: 0;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            border-radius: 999px;
            cursor: pointer;
            transition: color 0.2s ease, background-color 0.2s ease;
        }

        .password-toggle-btn:hover,
        .password-toggle-btn:focus {
            color: #12365f;
            background: rgba(26, 78, 138, 0.09);
            outline: none;
        }
        
        .btn-login {
            background: linear-gradient(45deg, #1a2a6c, #b21f1f);
            border: none;
            border-radius: 10px;
            padding: 12px 24px;
            font-size: 1.1rem;
            font-weight: 600;
            color: white;
            width: 100%;
            transition: all 0.3s ease;
            position: relative;
            overflow: hidden;
        }
        
        .btn-login:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 20px rgba(26, 42, 108, 0.3);
            color: white;
        }
        
        .btn-login:active {
            transform: translateY(0);
        }
        
        .btn-login:focus {
            box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
        }
        
        .btn-login::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
            transition: left 0.5s;
        }
        
        .btn-login:hover::before {
            left: 100%;
        }
        
        .form-check-input:checked {
            background-color: #007bff;
            border-color: #007bff;
        }
        
        .form-check-label {
            color: #6c757d;
            font-weight: 500;
        }
        
        .forgot-password {
            color: #007bff;
            text-decoration: none;
            font-weight: 500;
            transition: color 0.3s ease;
        }
        
        .forgot-password:hover {
            color: #0056b3;
            text-decoration: underline;
        }
        
        .alert {
            border-radius: 10px;
            border: none;
            padding: 15px 20px;
            margin-bottom: 25px;
            font-weight: 500;
        }
        
        .alert-danger {
            background-color: #f8d7da;
            color: #721c24;
        }
        
        .alert-success {
            background-color: #d1edff;
            color: #0c5460;
        }
        
        .alert-info {
            background-color: #d1ecf1;
            color: #0c5460;
        }
        
        .login-footer {
            background: #f8f9fa;
            padding: 20px 30px;
            text-align: center;
            border-top: 1px solid #dee2e6;
        }
        
        .login-footer p {
            margin-bottom: 8px;
            color: #6c757d;
            font-size: 0.9rem;
        }
        
        .login-footer a {
            color: #007bff;
            text-decoration: none;
            font-weight: 500;
        }
        
        .login-footer a:hover {
            text-decoration: underline;
        }
        
        .copyright {
            font-size: 0.8rem;
            color: #adb5bd;
            margin-top: 10px;
        }
        
        /* Responsive adjustments */
        @media (max-width: 576px) {
            .login-container {
                padding: 15px;
            }
            
            .login-body {
                padding: 30px 20px;
            }
            
            .login-header {
                padding: 25px 20px;
            }
            
            .login-title {
                font-size: 1.5rem;
            }
            
            .login-footer {
                padding: 15px 20px;
            }
        }
        
        /* Animation for form elements */
        .form-floating > .form-control:focus ~ label,
        .form-floating > .form-control:not(:placeholder-shown) ~ label {
            transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
        }
        
        /* Loading state */
        .btn-login.loading {
            pointer-events: none;
            opacity: 0.8;
        }
        
        .btn-login.loading::after {
            content: '';
            position: absolute;
            width: 20px;
            height: 20px;
            top: 50%;
            left: 50%;
            margin-left: -10px;
            margin-top: -10px;
            border: 2px solid transparent;
            border-top-color: #ffffff;
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }
        
        @keyframes spin {
            0% { transform: rotate(0deg); }
            100% { transform: rotate(360deg); }
        }
    

        
        :root {
            --epic-primary: #1a4e8a;
            --epic-primary-dark: #12365f;
            --epic-accent: #29c493;
            --epic-bg: #f3f8ff;
            --epic-surface: #ffffff;
            --epic-border: rgba(26, 78, 138, 0.16);
            --epic-shadow-md: 0 18px 38px rgba(8, 31, 62, 0.14);
        }

        body {
            font-family: "Be Vietnam Pro", sans-serif !important;
            color: #0b1a30;
            overflow-x: hidden;
            overflow-y: auto;
            background:
                radial-gradient(circle at 8% -18%, rgba(83, 153, 255, 0.24), transparent 42%),
                radial-gradient(circle at 92% 8%, rgba(41, 196, 147, 0.15), transparent 36%),
                var(--epic-bg) !important;
        }

        .bg-element {
            background: rgba(255, 255, 255, 0.5);
            border: 1px solid rgba(255, 255, 255, 0.8);
            box-shadow: 0 8px 24px rgba(38, 110, 188, 0.12);
        }

        .login-container {
            padding: 26px;
        }

        .login-card {
            border-radius: 22px;
            border: 1px solid var(--epic-border);
            box-shadow: var(--epic-shadow-md);
            background: var(--epic-surface);
            max-width: 500px;
        }

        .login-header {
            background:
                radial-gradient(circle at 20% -30%, rgba(123, 199, 255, 0.24), transparent 48%),
                linear-gradient(150deg, #081a31, #0d2f59) !important;
            padding: 32px 28px;
        }

        .logo-container img {
            filter: none;
            background: #ffffff;
            border-radius: 50%;
            padding: 0;
            height: 78px;
            width: 78px;
            object-fit: contain;
        }

        .login-title {
            font-size: 2rem;
            letter-spacing: -0.01em;
        }

        .login-subtitle {
            opacity: 0.95;
        }

        .login-body {
            padding: 34px 30px;
        }

        .form-floating > .form-control {
            border: 1px solid rgba(26, 78, 138, 0.24);
            border-radius: 14px;
            background: #fbfdff;
        }

        .form-floating > .form-control.password-input {
            padding-right: 2.7rem;
        }

        .form-floating > .form-control:focus {
            border-color: var(--epic-primary);
            box-shadow: 0 0 0 0.2rem rgba(26, 78, 138, 0.18);
            background: #ffffff;
        }

        .input-icon {
            color: #335c8d;
        }

        .btn-login {
            border-radius: 999px;
            background: linear-gradient(130deg, var(--epic-primary), #2368b5) !important;
            box-shadow: 0 12px 24px rgba(18, 74, 139, 0.24);
        }

        .btn-login:hover {
            box-shadow: 0 14px 28px rgba(18, 74, 139, 0.28);
            background: linear-gradient(130deg, #14427a, #1f5b9a) !important;
        }

        .forgot-password,
        .login-footer a {
            color: var(--epic-primary);
        }

        .form-check {
            display: flex;
            align-items: center;
            gap: 8px;
            margin: 0;
            padding-left: 0 !important;
        }

        .form-check .form-check-input {
            margin: 0 !important;
            margin-left: 0 !important;
            float: none;
            accent-color: #1f5f9f;
            cursor: pointer;
        }

        .form-check .form-check-label {
            margin: 0;
            color: #4a5f79;
            font-weight: 500;
            cursor: pointer;
            user-select: none;
            transition: color 0.2s ease, font-weight 0.2s ease;
        }

        .form-check .form-check-input:checked + .form-check-label {
            color: #1f5f9f;
            font-weight: 700;
        }

        .login-footer {
            background: linear-gradient(155deg, #f7fbff, #f2f8ff);
            border-top: 1px solid var(--epic-border);
        }

        .login-footer-row {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 14px;
            flex-wrap: wrap;
            margin-bottom: 14px;
        }

        .login-footer-label {
            margin: 0;
            color: #355b85;
            font-size: 0.92rem;
            font-weight: 600;
            letter-spacing: 0.01em;
            text-align: center;
        }

        .login-footer-actions {
            display: flex;
            align-items: center;
            gap: 0.72rem;
            flex-wrap: nowrap;
            margin-bottom: 0;
            justify-content: center;
        }

        .login-footer-social {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            width: 40px;
            height: 40px;
            padding: 0;
            border-radius: 999px;
            border: 1px solid rgba(53, 91, 143, 0.7);
            text-decoration: none;
            color: #7fb6ff;
            transition: all 0.2s ease;
        }

        .login-footer-social:hover {
            color: #ffffff;
            border-color: transparent;
            text-decoration: none;
        }

        .login-footer-social:focus {
            text-decoration: none;
        }

        .login-footer-social.is-facebook {
            background: transparent;
        }

        .login-footer-social.is-zalo {
            background: transparent;
        }

        .login-footer-social i {
            font-size: 1rem;
            line-height: 1;
        }

        .login-footer-social.is-facebook:hover,
        .login-footer-social.is-facebook:focus {
            background: #1877f2;
        }

        .login-footer-social.is-zalo:hover,
        .login-footer-social.is-zalo:focus {
            background: #0068ff;
        }

        .login-footer-social span {
            position: absolute;
            width: 1px;
            height: 1px;
            padding: 0;
            margin: -1px;
            overflow: hidden;
            clip: rect(0, 0, 0, 0);
            white-space: nowrap;
            border: 0;
        }

        .copyright {
            color: #50719a;
        }

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

            .login-header {
                padding: 26px 20px;
            }

            .login-title {
                font-size: 1.6rem;
            }

            .logo-container img {
                height: 68px;
                width: 68px;
            }

            .login-footer-row {
                justify-content: center;
            }
        }
    
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}}
.form-floating > .form-control::placeholder { color:transparent; }
