* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
}

:root {
    --primary-color: #9c27b0;
    --secondary-color: #3f51b5;
    --dark-bg: rgba(13, 14, 23, 0.6);
    --border-color: rgba(255, 255, 255, 0.1);
    --text-color: #fff;
    --shadow-color: rgba(138, 43, 226, 0.3);
}

body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: #000 url("https://images.unsplash.com/photo-1534796636912-3b95b3ab5986?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=2071&q=80") no-repeat;
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
    padding: 20px;
}

body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.6) 100%);
    z-index: -1;
}

.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.star {
    position: absolute;
    width: 2px;
    height: 2px;
    background: #fff;
    border-radius: 50%;
    animation: twinkle var(--duration) infinite ease-in-out;
    opacity: var(--opacity);
}

@keyframes twinkle {
    0%, 100% {
        opacity: var(--opacity);
        transform: scale(1);
    }
    50% {
        opacity: 0.3;
        transform: scale(1.3);
    }
}

.wrapper {
    width: 100%;
    max-width: 420px;
    background-color: var(--dark-bg);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5), 
                0 0 60px rgba(138, 43, 226, 0.2), 
                inset 0 0 15px rgba(138, 43, 226, 0.1);
    color: var(--text-color);
    border-radius: 16px;
    padding: clamp(25px, 5vw, 40px);
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
    overflow: hidden;
    text-align: center;
}

.logo {
    width: clamp(60px, 15vw, 80px);
    height: auto;
    margin-bottom: 20px;
    filter: drop-shadow(0 0 8px rgba(138, 43, 226, 0.7));
    animation: pulse 3s infinite ease-in-out;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 0 8px rgba(138, 43, 226, 0.7));
    }
    50% {
        transform: scale(1.05);
        filter: drop-shadow(0 0 12px rgba(138, 43, 226, 0.9));
    }
}

.wrapper::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to bottom right,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.05) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(30deg);
    pointer-events: none;
}

.wrapper:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.6), 
                0 0 80px rgba(138, 43, 226, 0.3), 
                inset 0 0 15px rgba(138, 43, 226, 0.2);
}

.wrapper h1 {
    font-size: clamp(28px, 7vw, 36px);
    text-align: center;
    margin-bottom: clamp(20px, 5vw, 30px);
    font-weight: 600;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 20px var(--shadow-color);
}

.wrapper .input-box {
    width: 100%;
    height: 50px;
    position: relative;
    margin: 25px 0;
}

.input-box input {
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.07);
    border: none;
    outline: none;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    font-size: clamp(14px, 4vw, 16px);
    color: var(--text-color);
    padding: 20px 45px 20px 20px;
    transition: all 0.3s;
}

.input-box input:focus {
    border-color: rgba(138, 43, 226, 0.5);
    box-shadow: 0 0 15px rgba(138, 43, 226, 0.3);
}

.input-box input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.input-box i {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: clamp(16px, 5vw, 20px);
    color: rgba(255, 255, 255, 0.6);
    transition: all 0.3s;
}

.input-box input:focus + i {
    color: var(--primary-color);
}

.wrapper .remember-forgot {
    display: flex;
    justify-content: space-between;
    font-size: clamp(12px, 3.5vw, 14px);
    margin: -15px 0 20px;
    color: rgba(255, 255, 255, 0.8);
}

.remember-forgot label {
    display: flex;
    align-items: center;
}

.remember-forgot label input {
    accent-color: var(--primary-color);
    margin-right: 8px;
    cursor: pointer;
}

.wrapper .register-link {
    font-size: clamp(12px, 3.5vw, 14px);
    text-align: center;
    margin: 25px 0 15px;
    color: rgba(255, 255, 255, 0.8);
}

.register-link p a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
}

.register-link p a:hover {
    text-decoration: underline;
    text-shadow: 0 0 10px var(--shadow-color);
}

.wrapper .btn {
    width: 100%;
    height: 50px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    border: none;
    outline: none;
    border-radius: 10px;
    box-shadow: 0 0 15px var(--shadow-color);
    cursor: pointer;
    font-size: clamp(14px, 4vw, 16px);
    color: var(--text-color);
    font-weight: 600;
    letter-spacing: 1px;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.wrapper .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.5s;
}

.wrapper .btn:hover::before {
    left: 100%;
}

.wrapper .btn:hover {
    background: linear-gradient(to right, var(--secondary-color), var(--primary-color));
    box-shadow: 0 0 20px rgba(138, 43, 226, 0.5);
}

.alert-error {
    background-color: rgba(220, 53, 69, 0.7);
    color: var(--text-color);
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
    text-align: center;
    border: 1px solid rgba(220, 53, 69, 0.3);
    box-shadow: 0 0 10px rgba(220, 53, 69, 0.3);
    font-size: clamp(13px, 3.5vw, 14px);
}

.d-none {
    display: none;
}

/* Responsive styles */
@media (max-width: 480px) {
    .wrapper {
        padding: 20px;
    }
    
    .wrapper .input-box {
        margin: 20px 0;
    }
    
    .input-box input {
        padding: 15px 40px 15px 15px;
    }
    
    .remember-forgot {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}

@media (max-height: 600px) {
    body {
        padding: 10px;
    }
    
    .wrapper {
        padding: 15px;
    }
    
    .logo {
        margin-bottom: 10px;
    }
    
    .wrapper h1 {
        margin-bottom: 15px;
    }
    
    .wrapper .input-box {
        margin: 15px 0;
        height: 45px;
    }
} 