:root {
    --bg-dark: #f8f9fa;
    --bg-panel: #ffffff;
    --border-color: rgba(0, 0, 0, 0.08);
    --text-primary: #1e293b;
    --text-secondary: #475569;
    --brand-purple: #7044df;
    --brand-purple-hover: #5a36b5;
    --font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-dark);
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    overflow: hidden;
}

/* Glassmorphism Background */
.login-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(135deg, #f8f9fa 0%, #e2e8f0 100%);
}

.login-background::before {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background: var(--brand-purple);
    filter: blur(150px);
    opacity: 0.1;
    top: 10%;
    left: 10%;
    border-radius: 50%;
}

.login-background::after {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: #3b82f6;
    filter: blur(150px);
    opacity: 0.1;
    bottom: 10%;
    right: 10%;
    border-radius: 50%;
}

.login-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 24px;
    padding: 40px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.login-header h1 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
}

.login-header p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 30px;
}

.step-container {
    display: none;
    animation: fadeInSlide 0.4s ease forwards;
}

.step-container.active {
    display: block;
}

@keyframes fadeInSlide {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* List Items (Stores/Users) */
.selection-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 300px;
    overflow-y: auto;
    padding-right: 5px;
}

.input-wrapper select.custom-select {
    width: 100%;
    padding: 14px 15px 14px 45px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: white;
    font-size: 15px;
    appearance: none;
    cursor: pointer;
    transition: all 0.2s;
}

.input-wrapper::after {
    content: '\e94a'; /* ph-caret-down */
    font-family: 'Phosphor';
    position: absolute;
    right: 15px;
    pointer-events: none;
    color: var(--text-secondary);
}

.input-wrapper select.custom-select:focus {
    border-color: var(--brand-purple);
    box-shadow: 0 0 0 4px rgba(112, 68, 223, 0.1);
}

.selection-item {
    background: white;
    border: 1px solid var(--border-color);
    padding: 16px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
}

.selection-item:hover {
    border-color: var(--brand-purple);
    background: rgba(112, 68, 223, 0.02);
    transform: scale(1.02);
}

.selection-item i {
    font-size: 20px;
    color: var(--brand-purple);
}

.selection-item .item-name {
    font-weight: 600;
    font-size: 15px;
}

/* Password Step */
.password-container {
    text-align: left;
}

.user-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--bg-panel-hover);
    border-radius: 12px;
    margin-bottom: 20px;
}

.user-badge img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
}

.user-badge .user-info {
    display: flex;
    flex-direction: column;
}

.user-badge .user-info .name {
    font-size: 14px;
    font-weight: 600;
}

.user-badge .user-info .role {
    font-size: 11px;
    color: var(--text-secondary);
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-secondary);
}

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

.input-wrapper i:not(#toggle-password) {
    position: absolute;
    left: 15px;
    color: var(--text-secondary);
}

.input-wrapper input {
    width: 100%;
    padding: 14px 15px 14px 45px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: white;
    font-size: 15px;
    transition: all 0.2s;
}

.input-wrapper input:focus {
    border-color: var(--brand-purple);
    box-shadow: 0 0 0 4px rgba(112, 68, 223, 0.1);
}

.btn-login {
    width: 100%;
    padding: 14px;
    border-radius: 12px;
    background: var(--brand-purple);
    color: white;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-login:hover {
    background: var(--brand-purple-hover);
    transform: translateY(-2px);
}

.btn-back {
    margin-top: 15px;
    background: transparent;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.btn-back:hover {
    color: var(--text-primary);
}

/* Custom Scrollbar */
.selection-list::-webkit-scrollbar {
    width: 5px;
}
.selection-list::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}

/* Loader */
.loader {
    width: 20px;
    height: 20px;
    border: 2px solid white;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    display: none;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}
/* Mobile Responsiveness */
@media (max-width: 480px) {
    .login-card {
        padding: 24px;
        border-radius: 16px;
        max-width: 340px;
    }

    .login-header h1 {
        font-size: 20px;
    }

    .login-header p {
        font-size: 13px;
        margin-bottom: 20px;
    }

    .input-wrapper input, .input-wrapper select.custom-select {
        padding: 12px 15px 12px 40px;
        font-size: 14px;
    }

    .input-wrapper i, .input-wrapper::after {
        left: 12px;
        font-size: 18px;
    }

    .btn-login {
        padding: 12px;
        font-size: 14px;
    }

    .user-badge {
        padding: 10px;
        margin-bottom: 15px;
    }

    .user-badge img {
        width: 28px;
        height: 28px;
    }
}
