/* ── TradingChart Auth Styles ────────────────────────────────────────────────── */

/* Modal Overlay */
.auth-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.auth-modal-overlay.visible {
    opacity: 1;
    visibility: visible;
}

/* Modal Card */
.auth-modal {
    background: var(--bg-secondary, #1a1d23);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
    border-radius: 16px;
    width: 400px;
    max-width: 90vw;
    padding: 32px;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.05);
    transform: translateY(20px) scale(0.95);
    transition: transform 0.3s ease;
}

.auth-modal-overlay.visible .auth-modal {
    transform: translateY(0) scale(1);
}

/* Header */
.auth-modal-header {
    text-align: center;
    margin-bottom: 24px;
}

.auth-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--accent, #6c5ce7);
    font-size: 22px;
    font-weight: 700;
    font-family: 'Inter', sans-serif;
}

.auth-brand svg {
    color: var(--accent, #6c5ce7);
}

/* Tabs */
.auth-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 24px;
    background: var(--bg-tertiary, rgba(255, 255, 255, 0.04));
    border-radius: 10px;
    padding: 3px;
}

.auth-tab {
    flex: 1;
    padding: 10px 16px;
    border: none;
    background: transparent;
    color: var(--text-muted, #8b8d95);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
}

.auth-tab:hover {
    color: var(--text-primary, #e4e6eb);
}

.auth-tab.active {
    background: var(--accent, #6c5ce7);
    color: #fff;
    box-shadow: 0 2px 8px rgba(108, 92, 231, 0.3);
}

/* Form */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.auth-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.auth-field label {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-muted, #8b8d95);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: 'Inter', sans-serif;
}

.auth-field input {
    padding: 12px 14px;
    background: var(--bg-primary, #0f1117);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
    border-radius: 10px;
    color: var(--text-primary, #e4e6eb);
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    outline: none;
}

.auth-field input:focus {
    border-color: var(--accent, #6c5ce7);
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.15);
}

.auth-field input::placeholder {
    color: var(--text-muted, #555);
}

/* Error */
.auth-error {
    padding: 10px 14px;
    background: rgba(235, 87, 87, 0.1);
    border: 1px solid rgba(235, 87, 87, 0.3);
    border-radius: 8px;
    color: #eb5757;
    font-size: 13px;
    font-family: 'Inter', sans-serif;
}

/* Submit Button */
.auth-submit-btn {
    padding: 12px 20px;
    background: var(--accent, #6c5ce7);
    border: none;
    border-radius: 10px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: 'Inter', sans-serif;
    margin-top: 4px;
}

.auth-submit-btn:hover:not(:disabled) {
    background: var(--accent-hover, #5b4bd5);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(108, 92, 231, 0.35);
}

.auth-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.auth-btn-loading {
    display: inline-flex;
    align-items: center;
}

.auth-spinner {
    animation: auth-spin 0.8s linear infinite;
}

@keyframes auth-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Footer */
.auth-footer {
    margin-top: 20px;
    text-align: center;
    border-top: 1px solid var(--border-color, rgba(255, 255, 255, 0.06));
    padding-top: 16px;
}

.auth-footer p {
    font-size: 12px;
    color: var(--text-muted, #8b8d95);
    margin: 0 0 10px;
    font-family: 'Inter', sans-serif;
}

.auth-skip-btn {
    padding: 8px 20px;
    background: transparent;
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.12));
    border-radius: 8px;
    color: var(--text-muted, #8b8d95);
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
}

.auth-skip-btn:hover {
    border-color: var(--text-muted, #8b8d95);
    color: var(--text-primary, #e4e6eb);
}

/* ── Sidebar User Section ────────────────────────────────────────────────── */

.auth-user-section {
    padding: 8px 12px;
    margin: 4px 8px;
}

.auth-user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--bg-tertiary, rgba(255, 255, 255, 0.04));
    border-radius: 10px;
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.06));
}

.auth-avatar {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--accent, #6c5ce7), #a29bfe);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    flex-shrink: 0;
    font-family: 'Inter', sans-serif;
}

.auth-user-details {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.auth-user-name {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary, #e4e6eb);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: 'Inter', sans-serif;
}

.auth-user-role {
    font-size: 11px;
    color: var(--text-muted, #8b8d95);
    text-transform: capitalize;
    font-family: 'Inter', sans-serif;
}

.auth-logout-btn {
    background: none;
    border: none;
    color: var(--text-muted, #8b8d95);
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.auth-logout-btn:hover {
    background: rgba(235, 87, 87, 0.1);
    color: #eb5757;
}

/* Login button in sidebar */
.auth-login-sidebar-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 10px 14px;
    background: rgba(99, 102, 241, 0.08); /* Premium transparent indigo background */
    border: 1px solid rgba(99, 102, 241, 0.25); /* Subtle indigo border */
    border-radius: 10px;
    color: #818cf8; /* Light indigo text */
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
}

.auth-login-sidebar-btn:hover {
    background: rgba(99, 102, 241, 0.16);
    border-color: #6366f1;
    color: #fff;
    box-shadow: 0 0 12px rgba(99, 102, 241, 0.25);
}

.auth-login-sidebar-btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: #818cf8;
    transition: color 0.2s ease;
}

.auth-login-sidebar-btn:hover svg {
    color: #fff;
}

/* Collapsed sidebar — hide text */
body.sidebar-collapsed #sidebar .auth-user-details,
body.sidebar-collapsed #sidebar .auth-login-sidebar-btn span,
body.sidebar-collapsed #sidebar .auth-logout-btn {
    display: none !important;
}

body.sidebar-collapsed #sidebar .auth-user-section {
    padding: 8px 0 !important;
    margin: 4px 10px !important;
}

body.sidebar-collapsed #sidebar .auth-user-info {
    justify-content: center;
    padding: 10px;
}

body.sidebar-collapsed #sidebar .auth-login-sidebar-btn {
    justify-content: center;
    padding: 12px;
}

/* Global button and clickable text reset (prevents text-selection cursor & caret blinking on buttons) */
button,
a,
.btn,
.nav-item,
.auth-tab,
.auth-login-sidebar-btn,
.auth-skip-btn,
.sidebar-toggle-btn,
.sidebar-collapse-btn {
    cursor: pointer !important;
    user-select: none !important;
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    -ms-user-select: none !important;
}



