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

body {
    font-family: "Inter", sans-serif;
    background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* Animated Background */
.tech-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}

.tech-background::before {
    content: "";
    position: absolute;
    width: 200%;
    height: 200%;
    background-image: linear-gradient(
            90deg,
            rgba(59, 130, 246, 0.03) 1px,
            transparent 1px
        ),
        linear-gradient(180deg, rgba(59, 130, 246, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(50px, 50px);
    }
}

.floating-elements {
    position: absolute;
    width: 100%;
    height: 100%;
}

.floating-elements span {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.2), transparent);
    animation: float 15s infinite ease-in-out;
    pointer-events: none;
}

.floating-elements span:nth-child(1) {
    width: 80px;
    height: 80px;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.floating-elements span:nth-child(2) {
    width: 120px;
    height: 120px;
    top: 60%;
    right: 15%;
    animation-delay: 2s;
}

.floating-elements span:nth-child(3) {
    width: 100px;
    height: 100px;
    bottom: 10%;
    left: 20%;
    animation-delay: 4s;
}

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

/* Login Container */
.auth-main {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-wrapper {
    width: 100%;
    max-width: 480px;
}

.auth-form .card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    overflow: hidden;
    position: relative;
}

.auth-form .card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(
        135deg,
        rgba(59, 130, 246, 0.3),
        rgba(147, 51, 234, 0.3)
    );
    border-radius: 24px 24px 0 0;
    z-index: -1;
}

.card-body {
    padding: 3rem 2.5rem;
}

/* Brand Logo Section */
.brand-section {
    text-align: center;
    margin-bottom: 2.5rem;
}

.brand-section img {
    width: 100px;
    height: auto;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 10px 30px rgba(59, 130, 246, 0.3));
    animation: logoFloat 3s ease-in-out infinite;
}

@keyframes logoFloat {
    0%,
    100% {
        transform: translateY(0px);
        filter: drop-shadow(0 10px 30px rgba(59, 130, 246, 0.3));
    }
    50% {
        transform: translateY(-10px);
        filter: drop-shadow(0 15px 40px rgba(59, 130, 246, 0.5));
    }
}

.brand-tagline {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    font-weight: 300;
    letter-spacing: 0.5px;
}

/* Auth Header */
.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header h2 {
    color: #ffffff;
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.auth-header p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.95rem;
}

/* Form Styles */
#loginForm .form-floating {
    position: relative;
    margin-bottom: 1.5rem;
}

#loginForm .form-floating .form-control {
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    border-radius: 12px !important;
    color: #ffffff !important;
    padding: 1rem !important;
    height: 58px !important;
    font-size: 0.95rem !important;
    transition: all 0.3s ease !important;
}

#loginForm .form-floating .form-control:focus {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2) !important;
    color: #ffffff !important;
    outline: none !important;
}

#loginForm .form-floating .form-control::placeholder {
    color: transparent !important;
    opacity: 0 !important;
}

#loginForm .form-floating .form-control::-webkit-input-placeholder {
    color: transparent !important;
    opacity: 0 !important;
}

#loginForm .form-floating .form-control::-moz-placeholder {
    color: transparent !important;
    opacity: 0 !important;
}

#loginForm .form-floating .form-control:-ms-input-placeholder {
    color: transparent !important;
    opacity: 0 !important;
}

#loginForm .form-floating label {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    height: 100% !important;
    padding: 1rem !important;
    pointer-events: none !important;
    border: 1px solid transparent !important;
    transform-origin: 0 0 !important;
    transition: opacity 0.1s ease-in-out, transform 0.1s ease-in-out !important;
    color: rgba(255, 255, 255, 0.6) !important;
    font-size: 0.95rem !important;
    background: none !important;
    background-color: transparent !important;
    display: flex !important;
    align-items: center !important;
}

#loginForm .form-floating .form-control:focus ~ label,
#loginForm .form-floating .form-control:not(:placeholder-shown) ~ label {
    opacity: 1 !important;
    transform: scale(0.75) translateY(-0.5rem) translateX(0.15rem) !important;
    color: #3b82f6 !important;
    font-weight: 600 !important;
    background: none !important;
    background-color: transparent !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    margin-bottom: 0.25rem !important;
}

/* Remember Me & Forgot Password */
#loginForm .form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

#loginForm .form-check-label {
    color: rgba(255, 255, 255, 0.7) !important;
    font-size: 0.9rem !important;
}

#loginForm .form-check-input {
    background-color: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
}

#loginForm .form-check-input:checked {
    background-color: #3b82f6 !important;
    border-color: #3b82f6 !important;
}

#loginForm .form-check-input:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2) !important;
    border-color: #3b82f6 !important;
}

.forgot-password {
    color: #3b82f6;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.forgot-password:hover {
    color: #60a5fa;
}

/* Submit Button */
.btn-submit {
    width: 100%;
    background: linear-gradient(135deg, #3b82f6 0%, #9333ea 100%);
    border: none;
    border-radius: 12px;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 600;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-submit::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    transition: left 0.5s ease;
}

.btn-submit:hover::before {
    left: 100%;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(59, 130, 246, 0.4);
}

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

.btn-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Alert Messages */
.custom-message .alert {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    color: #ffffff;
    margin-bottom: 1.5rem;
    padding: 1rem;
    backdrop-filter: blur(10px);
}

.alert-danger {
    border-color: rgba(239, 68, 68, 0.5);
    background: rgba(239, 68, 68, 0.1);
}

.alert-success {
    border-color: rgba(34, 197, 94, 0.5);
    background: rgba(34, 197, 94, 0.1);
}

/* Loader */
.loader-bg {
    background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
}

.loader-fill {
    background: linear-gradient(135deg, #3b82f6 0%, #9333ea 100%);
}

/* Responsive */
@media (max-width: 576px) {
    .card-body {
        padding: 2rem 1.5rem;
    }

    .brand-section img {
        width: 100px;
    }

    .brand-tagline {
        font-size: 0.9rem;
    }

    .auth-header h2 {
        font-size: 1.5rem;
    }
}
