:root {
    --primary-color: #ff4d00;
    --primary-dark: #8b0000;
    --primary-light: #ff944d;
    --text-dark: #1b0a00;
    --text-light: #6b7280;
    --bg-gradient: linear-gradient(135deg, #1a0a00 0%, #8b0000 35%, #ff4d00 70%, #ffb067 100%);
    --card-shadow: 0 20px 40px rgba(0,0,0,0.4);
}

body {
    background: var(--bg-gradient);
    min-height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

/* Floating bubbles background */
.bubble {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, rgba(255, 204, 128, 0.18), rgba(255, 77, 0, 0.12), rgba(139, 0, 0, 0) 70%);
    animation: float 10s ease-in-out infinite;
    filter: blur(4px);
    pointer-events: none;
    z-index: 1;
    mix-blend-mode: screen;
    box-shadow: 0 0 60px rgba(255, 77, 0, 0.15);
}

.bubble:nth-child(1) {
    width: 120px;
    height: 120px;
    top: 20%;
    left: 15%;
    animation-delay: 0s;
}

.bubble:nth-child(2) {
    width: 60px;
    height: 60px;
    top: 55%;
    left: 10%;
    animation-delay: 4s;
}

.bubble:nth-child(3) {
    width: 100px;
    height: 100px;
    top: 70%;
    right: 15%;
    animation-delay: 2s;
}

.bubble:nth-child(4) {
    width: 80px;
    height: 80px;
    top: 30%;
    right: 25%;
    animation-delay: 6s;
}

.bubble:nth-child(5) {
    width: 40px;
    height: 40px;
    bottom: 20%;
    left: 30%;
    animation-delay: 8s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) translateX(0);
        opacity: 0.4;
    }
    50% {
        transform: translateY(-20px) translateX(10px);
        opacity: 0.2;
    }
}

/* Login Card */
.login-container {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 400px;
}

.login-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 1.5rem;
    box-shadow: var(--card-shadow);
    overflow: hidden;
    animation: fadeInUp 0.8s ease forwards;
}

.login-header {
    background: radial-gradient(120% 120% at 10% 0%, rgba(255, 200, 128, 0.15), transparent 40%),
                linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    padding: 2.5rem 2rem;
    text-align: center;
    color: white;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.login-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent 30%, rgba(255,255,255,0.1) 50%, transparent 70%);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.icon-circle {
    background: radial-gradient(circle at 50% 40%, rgba(255, 200, 128, 0.25), rgba(255, 85, 0, 0.25));
    width: 140px;
    height: 140px;
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 16px rgba(255, 77, 0, 0.35), inset 0 0 12px rgba(255, 230, 200, 0.25);
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
    overflow: hidden;
}

.icon-circle:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.05);
}

.icon-circle i {
    font-size: 1.5rem;
    color: white;
}

.icon-circle img {
    width: 60%;
    height: 60%;
    border-radius: 50%;
    object-fit: cover;
    display: block;
}

.login-header h1 {
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    position: relative;
    z-index: 2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.45);
}

.login-header p {
    font-weight: 300;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    opacity: 1;
    margin: 0;
    position: relative;
    z-index: 2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.45);
}

/* Form Styles */
.login-form {
    padding: 2.5rem 2rem;
}

.form-floating {
    margin-bottom: 1.5rem;
}

.form-floating .form-control {
    border-radius: 50px;
    border: 2px solid #e5e7eb;
    padding: 1rem 1rem 1rem 3rem;
    font-size: 1rem;
    background-color: #f9fafb;
    transition: all 0.3s ease;
}

.form-floating .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(255, 77, 0, 0.28);
    background-color: white;
}

.form-floating .form-control:focus + label {
    color: var(--primary-color);
}

.form-floating label {
    padding-left: 3rem;
    color: var(--text-light);
}

.input-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #ff7a33;
    z-index: 5;
}

.toggle-password {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: 0;
    padding: 0;
    color: #ff7a33;
    cursor: pointer;
    z-index: 5;
}

.toggle-password:focus {
    outline: none;
}

.has-password-toggle .form-control {
    padding-right: 3rem;
}

.btn-login {
    background: radial-gradient(120% 120% at 80% -20%, rgba(255, 235, 200, 0.18), transparent 40%),
                linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border: none;
    border-radius: 50px;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    padding: 1rem 2rem;
    width: 100%;
    transition: all 0.3s ease;
    box-shadow: 0 6px 20px rgba(255, 69, 0, 0.4);
}

.btn-login:hover {
    background: linear-gradient(135deg, var(--primary-light), var(--primary-color));
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 106, 51, 0.5);
    color: white;
}

.btn-login:active {
    transform: translateY(0);
}

.footer-note {
    text-align: center;
    font-size: 0.875rem;
    color: var(--text-light);
    padding: 1.5rem 2rem;
    border-top: 1px solid #e5e7eb;
    background: #f8fafc;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}

.footer-note i {
    color: var(--primary-color);
}

/* Error Message */
.alert-danger {
    background: linear-gradient(135deg, #dc3545, #c82333);
    border: none;
    border-radius: 15px;
    color: white;
    font-weight: 500;
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
    padding: 0.75rem 1rem;
}

/* Responsive adjustments */
@media (max-width: 576px) {
    .login-container {
        max-width: 100%;
        padding: 0 15px;
    }
    
    .login-card {
        border-radius: 1rem;
    }
    
    .login-header {
        padding: 2rem 1.5rem;
    }
    
    .login-form {
        padding: 2rem 1.5rem;
    }
    
    .login-header h1 {
        font-size: 1rem;
    }
    
    .login-header p {
        font-size: 0.8rem;
    }
    
    .icon-circle {
        width: 56px;
        height: 56px;
    }

    .icon-circle img {
        width: 55%;
        height: 55%;
    }
    
    .icon-circle i {
        font-size: 1.25rem;
    }
}

@media (max-width: 375px) {
    .login-header {
        padding: 1.5rem 1rem;
    }
    
    .login-form {
        padding: 1.5rem 1rem;
    }
}

/* Animation */
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translate3d(0, 40px, 0);
    }
    100% {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

/* Loading state */
.btn-login.loading {
    pointer-events: none;
    opacity: 0.8;
}

.btn-login.loading .spinner-border {
    margin-right: 0.5rem;
}
