/* General Reset & Background */
body {
    margin: 0;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    overflow: hidden;
    /* Prevents scrollbars from the blur edge */
    background-color: #1d3115;
    /* Fallback color */
}

    /* This creates the blurred background layer */
    body::before {
        content: "";
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: -1;
        /* Puts it behind everything */
        background: url('/images/photo-1501854140801-50d01698950b.avif');
        background-size: cover;
        background-position: center;
        filter: blur(8px);
        /* Adjust the pixels to change blur intensity */
        transform: scale(1.1);
        /* Prevents white edges caused by the blur */
    }

/* The Glass Card */
.login-card {
    position: relative;
    width: 350px;
    padding: 60px 30px 40px;
    background: rgba(255, 255, 255, 0.1);
    /* Transparent white */
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    /* The "Glass" effect */
    text-align: center;
    transition: all 250ms ease-in-out;
}

.signup-card {
    width: 450px;
}

    .login-card:hover {
        backdrop-filter: blur(20px);
        scale: 1.02;
    }

/* Floating Avatar Icon */
.avatar-container {
    position: absolute;
    top: -50px;
    left: 50%;
    transform: translateX(-50%);
}

.avatar-circle {
    width: 100px;
    height: 100px;
    background: #111d0b;
    color: #64735c !important;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 40px;
    color: white;
}

/* Input Styles */
.input-group {
    margin-top: 20px;
}

.input-box {
    display: flex;
    align-items: center;
    background: #e0e0e0;
    margin-bottom: 15px;
    border-radius: 4px;
    overflow: hidden;
}

    .input-box i {
        padding: 15px;
        background: #d4d4d4;
        color: #555;
        width: 20px;
    }

    .input-box input {
        border: none;
        outline: none;
        background: none;
        padding: 15px;
        width: 100%;
        font-size: 16px;
    }

/* Remove default button styles */
.toggle-btn {
    background: none;
    /* Matching your previous icon background */
    border: none;
    cursor: pointer;
    width: 45px;
    height: 48px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.2s ease;
    outline: none;
}

#togglePassword i {
    background: none;
    color: #668258 !important;
}
#toggleConfirmPassword i {
    background: none;
    color: #668258 !important;
}

/* Visual cue: Change color on hover */
.toggle-btn:hover {
    background: none;
    color: #1d3115;
    /* Using your forest green for the icon on hover */
}

/* Active state for when password is visible */
.toggle-btn.is-visible {
    color: #3a5a2d !important;
}

.input-box input {
    border: none;
    outline: none;
    background: none;
    padding: 15px;
    width: 100%;
    font-size: 16px;
}

/* Options (Checkbox/Forgot) */
.options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 25px;
}

    .options a {
        color: rgba(255, 255, 255, 0.7);
        text-decoration: none;
    }

/* Login Button */
.login-btn {
    width: 100%;
    padding: 15px;
    background: #1b2e12;
    color: white;
    border: none;
    border-radius: 4px;
    letter-spacing: 2px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

    .login-btn:hover {
        background: #2a471c;
    }

.checkbox-wrapper {
    --checkbox-size: 10px;
    --checkbox-color: #68bf65;
    --checkbox-shadow: rgba(98, 215, 95, 0.3);
    --checkbox-border: rgba(52, 194, 48, 0.7);
    display: flex;
    align-items: center;
    position: relative;
    cursor: pointer;
    padding: 10px;
}

    .checkbox-wrapper input {
        position: absolute;
        opacity: 0;
        cursor: pointer;
        height: 0;
        width: 0;
    }

    .checkbox-wrapper .checkmark {
        position: relative;
        width: var(--checkbox-size);
        height: var(--checkbox-size);
        border: 2px solid var(--checkbox-border);
        border-radius: 5px;
        transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
        display: flex;
        justify-content: center;
        align-items: center;
        background: rgba(0, 0, 0, 0.2);
        box-shadow: 0 0 15px var(--checkbox-shadow);
        overflow: hidden;
    }

        .checkbox-wrapper .checkmark::before {
            content: "";
            position: absolute;
            width: 100%;
            height: 100%;
            background: linear-gradient(45deg, var(--checkbox-color), #00ffcc);
            opacity: 0;
            transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
            transform: scale(0) rotate(-45deg);
        }

    .checkbox-wrapper input:checked ~ .checkmark::before {
        opacity: 1;
        transform: scale(1) rotate(0);
    }

    .checkbox-wrapper .checkmark svg {
        width: 0;
        height: 0;
        color: #1a1a1a;
        z-index: 1;
        transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
        filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.5));
    }

    .checkbox-wrapper input:checked ~ .checkmark svg {
        width: 18px;
        height: 18px;
        transform: rotate(360deg);
    }

    .checkbox-wrapper:hover .checkmark {
        border-color: var(--checkbox-color);
        transform: scale(1.1);
        box-shadow: 0 0 20px var(--checkbox-shadow), 0 0 40px var(--checkbox-shadow), inset 0 0 10px var(--checkbox-shadow);
    }

    .checkbox-wrapper input:checked ~ .checkmark {
        animation: pulse 1s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    }

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 20px var(--checkbox-shadow);
    }

    50% {
        transform: scale(0.9);
        box-shadow: 0 0 30px var(--checkbox-shadow), 0 0 50px var(--checkbox-shadow);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 20px var(--checkbox-shadow);
    }
}

.checkbox-wrapper .label {
    margin-left: 5px;
    font-family: "Segoe UI", sans-serif;
    color: var(--checkbox-color);
    font-size: 13px;
    text-shadow: 0 0 10px var(--checkbox-shadow);
    opacity: 0.9;
    transition: all 0.3s;
}

.checkbox-wrapper:hover .label {
    opacity: 1;
    transform: translateX(5px);
}

/* Glowing dots animation */
.checkbox-wrapper::after,
.checkbox-wrapper::before {
    content: "";
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--checkbox-color);
    opacity: 0;
    transition: all 0.5s;
}

.checkbox-wrapper::before {
    left: -2px;
    top: 50%;
}

.checkbox-wrapper::after {
    right: -5px;
    top: 50%;
}

.checkbox-wrapper:hover::before {
    opacity: 1;
    transform: translateX(-5px);
    box-shadow: 0 0 10px var(--checkbox-color);
}

.checkbox-wrapper:hover::after {
    opacity: 1;
    transform: translateX(5px);
    box-shadow: 0 0 10px var(--checkbox-color);
}


@media screen and (max-width:576px) {
    .login-card {
        width: 250px;
    }

    .avatar-circle {
        width: 80px;
        height: 80px;
        font-size: 30px;
    }

    .input-box input {
        font-size: 12px;
    }

    .login-btn {
        height: 40px;
        font-size: 10px;
    }

    .input-box {
        height: 40px;
    }
}

.error-msg {
    color: #efff49;
    margin-bottom: 5px;
    font-size: 11px;
    text-align: left;
    display: block;
    font-weight: 500;
    display: none;
    transition: opacity 0.3s ease;
}

    .error-msg.visible {
        display: block;
    }

/* Red glow for the input box when invalid */
.input-box.invalid {
    border: 1px solid rgba(255, 138, 138, 0.5) !important;
}
/* Base state for all input boxes */
.input-box {
    border: 1px solid rgba(255, 255, 255, 0.4);
    transition: all 0.3s ease;
}

    /* The Invalid Glow */
    .input-box.invalid {
        border-color: #ff4d4d !important;
        box-shadow: 0 0 12px rgba(255, 77, 77, 0.6);
    }

    /* The Valid Glow (Optional, for positive feedback) */
    .input-box.valid {
        border-color: #4CAF50 !important;
        box-shadow: 0 0 12px rgba(76, 175, 80, 0.4);
    }

a {
    color: #00ffcc;
}

.login-btn:disabled {
    opacity: 0.5;
}