:root {
    --green-1: #00a60b;
    --green-2: #2eb82e;
    --green-3: #66ff72;
    --accent: #ffbf00;
    --white: #ffffff;
    --black: #1a1a1a;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    min-height: 100vh;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    position: relative;
}

/* Animated Gradient Background */
.bg {
    position: fixed;
    top: -50%;
    left: -50%;
    right: -50%;
    bottom: -50%;
    width: 200%;
    height: 200vh;
    background: linear-gradient(
        45deg, 
        var(--green-1) 0%, 
        var(--green-2) 50%, 
        var(--green-3) 100%
    );
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    z-index: -2;
}

.bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(
        circle at center,
        transparent 0%,
        rgba(0, 0, 0, 0.1) 100%
    );
    z-index: -1;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Floating Particles */
.particle {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    animation: float 15s infinite linear;
    z-index: -1;
}

@keyframes float {
    0% { 
        transform: translateY(0) translateX(0) rotate(0deg);
        opacity: 0;
    }
    10% { opacity: 0.8; }
    90% { opacity: 0.8; }
    100% { 
        transform: translateY(-100vh) translateX(100px) rotate(360deg);
        opacity: 0;
    }
}

/* Login Card */
.login-container {
    width: 100%;
    max-width: 380px;
    padding: 20px;
}

.login-card {
    background: white;
    border: none;
    border-radius: 16px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    backdrop-filter: blur(5px);
    color: var(--green-1);
    animation: cardEntrance 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    transform: translateY(20px);
    opacity: 0;
}

@keyframes cardEntrance {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.login-header {
    padding: 30px 25px 5px;
    text-align: center;
    position: relative;
}

.login-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 25%;
    width: 50%;
    height: 3px;
    background: var(--accent);
    border-radius: 3px;
}

.logo {
    width: 80px;
    height: auto;
    margin-bottom: 15px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05) rotate(-5deg);
}

.login-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 5px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.login-subtitle {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-bottom: 0;
}

.card-body {
    padding: 25px;
}

.form-control {
    background: var(--accent);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 12px 15px;
    color: var(--white);
    font-size: 0.95rem;
    height: 46px;
    transition: all 0.3s;
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.form-control:focus {
    background: #ebebeb;
    border-color: var(--green-1);
    box-shadow: 0 0 0 3px rgba(255, 191, 0, 0.3);
    color: #000;
}

.input-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
    transition: all 0.3s;
}

.form-control:focus + .input-icon {
    color: var(--accent);
    transform: translateY(-50%) scale(1.1);
}

.input-with-icon {
    padding-left: 45px !important;
}

.btn-login {
    background: var(--green-1);
    border: none;
    border-radius: 10px;
    padding: 12px;
    font-weight: 600;
    color: var(--black);
    width: 100%;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(255, 191, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-login:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(255, 191, 0, 0.4);
    background: var(--accent);
}

.btn-login:active {
    transform: translateY(0);
}

.btn-login::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to right,
        rgba(255, 255, 255, 0) 20%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0) 80%
    );
    transform: rotate(30deg);
    transition: all 0.7s;
}

.btn-login:hover::after {
    left: 100%;
}

.form-group {
    position: relative;
    margin-bottom: 1.5rem;
}

.footer {
    padding: 15px;
    text-align: center;
    font-size: 0.75rem;
    opacity: 0.8;
}

.error-message {
    font-size: 0.85rem;
    animation: shake 0.5s ease;
    background: rgba(255, 0, 0, 0.2);
    border-left: 3px solid #ff4d4d;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-5px); }
    40%, 80% { transform: translateX(5px); }
}

.invalid-feedback {
    color: #ffcccc;
    font-size: 0.8rem;
    margin-top: 5px;
}