:root {
    --primary-color: #4f46e5;
    --primary-hover: #4338ca;
    --bg-color: #f1f5f9;
    --card-bg: rgba(255, 255, 255, 0.65);
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --input-bg: rgba(255, 255, 255, 0.9);
    --input-border: rgba(148, 163, 184, 0.4);
    --input-focus: #4f46e5;
    --blob-1: rgba(99, 102, 241, 0.6);
    --blob-2: rgba(236, 72, 153, 0.6);
    --font-family: 'Inter', sans-serif;
    --transition-fast: 0.2s ease;
    --transition-smooth: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-family);
}

body {
    background-color: var(--bg-color);
    background-image: url('img/login3.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    position: relative;
}

/* Background Decorations (Blobs) */
.blob {
    position: absolute;
    filter: blur(80px);
    z-index: -1;
    opacity: 0.5;
    animation: float 10s infinite ease-in-out alternate;
}

.blob-1 {
    width: 400px;
    height: 400px;
    background: var(--blob-1);
    border-radius: 50%;
    top: -100px;
    left: -100px;
}

.blob-2 {
    width: 300px;
    height: 300px;
    background: var(--blob-2);
    border-radius: 50%;
    bottom: -50px;
    right: -50px;
    animation-delay: -5s;
}

@keyframes float {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(30px, -50px) scale(1.1);
    }
}

/* Main Container */
.login-container {
    width: 100%;
    max-width: 440px;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

/* Glassmorphism Card */
.login-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 24px;
    padding: 3rem 2.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.1);
    transform: translateY(20px);
    opacity: 0;
    animation: slideUp 0.6s var(--transition-smooth) forwards;
}

@keyframes slideUp {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Header */
.login-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.login-header h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #1e293b, #64748b);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.login-header p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Form Styles */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-group label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: color var(--transition-fast);
}

.input-group:focus-within label {
    color: var(--text-primary);
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 1rem;
    width: 20px;
    height: 20px;
    color: var(--text-secondary);
    transition: color var(--transition-fast);
}

.input-wrapper input,
.custom-select {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    outline: none;
    transition: all var(--transition-fast);
}

.custom-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    cursor: pointer;
    padding-right: 3rem;
}

.custom-select option {
    color: var(--text-primary);
    background: #ffffff;
}

.custom-select:invalid {
    color: rgba(100, 116, 139, 0.6);
}

.select-arrow {
    position: absolute;
    right: 1rem;
    width: 20px;
    height: 20px;
    color: var(--text-secondary);
    transition: transform var(--transition-fast), color var(--transition-fast);
    pointer-events: none;
}

.input-wrapper input::placeholder {
    color: rgba(100, 116, 139, 0.6);
}

.input-wrapper input:focus,
.custom-select:focus {
    border-color: var(--input-focus);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.15);
}

.input-wrapper input:focus+.input-icon,
.input-group:focus-within .input-icon,
.custom-select:focus ~ .select-arrow,
.input-group:focus-within .select-arrow {
    color: var(--input-focus);
}

.custom-select:focus ~ .select-arrow {
    transform: rotate(-180deg);
}

/* Form Actions (Remember & Forgot) */
.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.remember-me input[type="checkbox"] {
    appearance: none;
    width: 18px;
    height: 18px;
    border: 1px solid var(--text-secondary);
    border-radius: 4px;
    background: transparent;
    cursor: pointer;
    position: relative;
    transition: all var(--transition-fast);
}

.remember-me input[type="checkbox"]:checked {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.remember-me input[type="checkbox"]:checked::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: color var(--transition-fast);
}

.forgot-password:hover {
    color: #818cf8;
    text-decoration: underline;
}

/* Submit Button */
.login-button {
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 1rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    transition: all var(--transition-smooth);
    position: relative;
    overflow: hidden;
    margin-top: 0.5rem;
}

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

.login-button:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -10px var(--primary-color);
}

.login-button:hover::before {
    left: 100%;
}

.login-button:active {
    transform: translateY(0);
}

.button-icon {
    width: 20px;
    height: 20px;
    transition: transform var(--transition-smooth);
}

.login-button:hover .button-icon {
    transform: translateX(4px);
}

/* Footer */
.login-footer {
    text-align: center;
    margin-top: 2rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.signup-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color var(--transition-fast);
}

.signup-link:hover {
    color: #818cf8;
    text-decoration: underline;
}

/* Responsive adjustments */
@media (max-width: 480px) {
    .login-container {
        padding: 1rem;
    }

    .login-card {
        padding: 2rem 1.5rem;
        border-radius: 20px;
    }
}