/* ============= AUTH SCREEN ============= */
#auth-screen {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: var(--bg); z-index: 1001;
    display: flex; justify-content: center; align-items: center; overflow-y: auto;
}
#auth-screen.hide { display: none; }
.auth-container {
    max-width: 400px; width: 90%; padding: 32px 24px;
    background: var(--card-bg); border-radius: var(--radius);
    box-shadow: var(--shadow-lg); margin: 20px;
}
.auth-logo { text-align: center; margin-bottom: 32px; }
.auth-logo-icon {
    width: 64px; height: 64px; border-radius: 50%;
    background: var(--primary-light);
    display: flex; align-items: center; justify-content: center; margin: 0 auto 16px;
}
.auth-logo-icon i { font-size: 28px; color: var(--primary); }
.auth-logo h1 { font-size: 24px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.auth-logo p { font-size: 13px; color: var(--text-secondary); }
.auth-tabs {
    display: flex; gap: 8px; margin-bottom: 24px;
    background: var(--bg); border-radius: var(--radius-sm); padding: 4px;
}
.auth-tab {
    flex: 1; padding: 10px; border: none; background: transparent;
    color: var(--text-secondary); font-size: 14px; font-weight: 600;
    border-radius: var(--radius-xs); cursor: pointer;
}
.auth-tab.active { background: var(--primary); color: white; }
.auth-form { display: none; }
.auth-form.active { display: block; }
.auth-form .form-group { margin-bottom: 16px; }
.auth-form input {
    width: 100%; padding: 14px 16px;
    border: 1px solid var(--border); border-radius: var(--radius-xs);
    background: var(--card-bg); color: var(--text); font-size: 14px; outline: none;
}
.auth-form input:focus { border-color: var(--primary); }
.auth-btn {
    width: 100%; padding: 14px; background: var(--primary); color: white;
    border: none; border-radius: var(--radius-xs);
    font-size: 15px; font-weight: 600; cursor: pointer; margin-top: 8px;
}
.guest-login { margin-top: 24px; text-align: center; padding-top: 24px; border-top: 1px solid var(--border); }
.guest-btn {
    padding: 10px 20px; background: transparent;
    border: 1px solid var(--border); border-radius: var(--radius-xs);
    color: var(--text-secondary); font-size: 13px; cursor: pointer;
}
.guest-btn:hover { border-color: var(--primary); color: var(--primary); }
.guest-note { font-size: 11px; color: var(--text-muted); margin-top: 8px; }

/* ============= PASSCODE SCREEN ============= */
#passcode-screen {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: var(--bg); display: none; z-index: 1000;
    justify-content: center; align-items: center;
}
#passcode-screen.active { display: flex; }
.passcode-container { text-align: center; padding: 40px 24px; }
.passcode-logo .logo-icon {
    width: 72px; height: 72px; border-radius: 20px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    display: flex; align-items: center; justify-content: center; margin: 0 auto 20px;
}
.passcode-title { font-size: 28px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.passcode-subtitle { color: var(--text-secondary); margin-bottom: 30px; }
.skip-passcode-btn {
    margin-top: 24px; padding: 12px 24px; background: transparent;
    border: none; color: var(--primary); font-size: 14px; font-weight: 600; cursor: pointer;
}
.passcode-dots { display: flex; gap: 16px; justify-content: center; margin-bottom: 40px; }
.passcode-dots .dot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--border); }
.passcode-dots .dot.filled { background: var(--primary); border-color: var(--primary); }
.numpad { display: grid; grid-template-columns: repeat(3, 80px); gap: 12px; justify-content: center; }
.numpad-btn {
    width: 80px; height: 80px; border-radius: 20px; border: none;
    background: var(--card-bg); font-size: 24px; font-weight: 500;
    color: var(--text); cursor: pointer; box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}
.numpad-btn:active { background: var(--primary-light); transform: scale(0.95); }
.numpad-btn.empty { visibility: hidden; }
.numpad-btn.backspace { background: transparent; box-shadow: none; }

/* ============= FINGERPRINT / BIOMETRIC ============= */
.fingerprint-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    margin-top: 20px;
    padding: 14px 28px;
    background: var(--primary-light);
    border: 2px solid var(--primary);
    border-radius: var(--radius-sm);
    color: var(--primary);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s;
    -webkit-tap-highlight-color: transparent;
}
.fingerprint-btn i { font-size: 32px; }
.fingerprint-btn:hover { background: var(--primary); color: white; }
.fingerprint-btn:active { transform: scale(0.95); }
.fingerprint-btn.scanning i { animation: fp-pulse 1s ease-in-out infinite; }
@keyframes fp-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.5; transform: scale(1.15); }
}

/* Biometric card in settings */
.biometric-card {
    background: var(--card-bg);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow);
    padding: 16px;
    margin-bottom: 16px;
}
.biometric-header {
    display: flex;
    align-items: center;
    gap: 14px;
}
.biometric-icon {
    width: 42px; height: 42px;
    border-radius: 10px;
    background: var(--primary-light);
    color: var(--primary);
    display: flex; align-items: center; justify-content: center;
    font-size: 20px; flex-shrink: 0;
}
.biometric-icon.active { background: var(--green-light); color: var(--green); }
.biometric-icon.unavailable { background: var(--bg); color: var(--text-muted); }
.biometric-info { flex: 1; }
.biometric-title { font-size: 14px; font-weight: 700; }
.biometric-sub { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.biometric-status {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 10px;
    padding: 8px 10px;
    background: var(--bg);
    border-radius: var(--radius-xs);
    display: none;
}
.biometric-status.show { display: block; }
.biometric-status.success { color: var(--green); background: var(--green-light); }
.biometric-status.error   { color: var(--red);   background: var(--red-light);   }

.use-pin-btn {
    margin-top: 12px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: var(--radius-xs);
    text-decoration: underline;
    text-underline-offset: 3px;
}
.use-pin-btn:hover { color: var(--primary); }
