/* ============================================================
   Admin Dashboard Styles
   ============================================================ */

.header-actions {
    display: flex;
    gap: 0.5rem;
}

.admin-section {
    margin-bottom: 2rem;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.section-header h2 {
    font-size: 1.1rem;
    font-weight: 600;
}

.section-header .highlight {
    color: var(--accent-primary-hover);
}

/* Table action buttons */
.action-btns {
    display: flex;
    gap: 0.375rem;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.3rem 0.6rem;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-xs);
    color: var(--text-secondary);
    font-family: var(--font);
    font-size: 0.7rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
}

.action-btn:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
    border-color: var(--accent-primary);
}

.action-btn.danger:hover {
    border-color: var(--error);
    color: var(--error);
    background: rgba(248, 113, 113, 0.08);
}

/* API Key display */
.api-key-display {
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
    color: var(--text-secondary);
    background: var(--bg-input);
    padding: 0.2rem 0.5rem;
    border-radius: var(--radius-xs);
}

.api-key-none {
    color: var(--text-muted);
    font-style: italic;
    font-size: 0.8rem;
}

/* Badge for customer click */
.customer-name-link {
    color: var(--accent-primary-hover);
    cursor: pointer;
    transition: color var(--transition);
}

.customer-name-link:hover {
    color: var(--accent-primary);
    text-decoration: underline;
}

/* Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(15, 17, 23, 0.8);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.modal-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    width: 90%;
    max-width: 480px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.modal-card h3 {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.modal-form-group {
    margin-bottom: 1rem;
}

.modal-form-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.375rem;
}

.modal-form-group input {
    width: 100%;
    padding: 0.625rem 0.875rem;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-xs);
    color: var(--text-primary);
    font-family: var(--font);
    font-size: 0.9rem;
    transition: border-color var(--transition);
    outline: none;
}

.modal-form-group input:focus {
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.modal-form-group .hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.modal-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    margin-top: 1.5rem;
}

.modal-btn {
    padding: 0.625rem 1.25rem;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
}

.modal-btn-primary {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 2px 12px rgba(99, 102, 241, 0.25);
}

.modal-btn-primary:hover {
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
}

.modal-btn-secondary {
    background: var(--bg-input);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.modal-btn-secondary:hover {
    background: var(--bg-card-hover);
}

/* Password display */
.password-display {
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: var(--radius-xs);
    padding: 0.75rem 1rem;
    margin-top: 0.75rem;
}

.password-display label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
    font-weight: 500;
}

.password-display code {
    font-size: 0.95rem;
    color: var(--success);
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* Alert message in modal */
.modal-alert {
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.2);
    color: var(--error);
    padding: 0.75rem 1rem;
    border-radius: var(--radius-xs);
    font-size: 0.85rem;
    margin-bottom: 1rem;
    display: none;
}

.modal-success {
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.2);
    color: var(--success);
}