/* ========== WILLISHOP – AGENT WORKSPACE STYLES (agent.css) – v17.0 ========== */
/* Clean, neutral design for the customer-service agent interface. */

#agentWorkspace {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: #f5f7fa;
    z-index: 5000;
    font-family: 'Segoe UI', Roboto, system-ui, sans-serif;
    color: #1e293b;
    overflow-y: auto;
}

#agentTopBar {
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    padding: 12px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
}

#agentTopBar .agent-back-btn {
    background: none;
    border: none;
    font-size: 16px;
    color: #2563eb;
    cursor: pointer;
    font-weight: 500;
}

#agentTopBar .agent-title {
    font-size: 16px;
    font-weight: 600;
}

/* Screens */
.agent-screen {
    display: none;
    padding: 24px;
}

.agent-screen.active {
    display: block;
}

/* Search Customer */
.agent-search-input {
    width: 100%;
    padding: 14px;
    border-radius: 12px;
    border: 1px solid #d1d5db;
    font-size: 16px;
    margin-bottom: 20px;
}

.agent-search-results {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.agent-search-card {
    background: white;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    cursor: pointer;
    transition: background 0.2s;
}

.agent-search-card:hover {
    background: #f1f5f9;
}

.agent-search-card .agent-customer-name {
    font-weight: 600;
    font-size: 16px;
}

.agent-search-card .agent-customer-info {
    font-size: 14px;
    color: #64748b;
    margin-top: 4px;
}

/* Identity Verification */
.agent-verify-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    max-width: 400px;
    margin: 0 auto;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.agent-verify-card .agent-verify-btn {
    margin-top: 16px;
    background: #2563eb;
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 24px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

/* Customer Account View */
.agent-customer-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.agent-customer-header .agent-customer-name {
    font-size: 20px;
    font-weight: 700;
}

.agent-customer-header .agent-customer-masked {
    font-size: 13px;
    color: #64748b;
}

.agent-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.agent-tab {
    background: #e2e8f0;
    border: none;
    border-radius: 20px;
    padding: 8px 18px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    color: #334155;
}

.agent-tab.active {
    background: #2563eb;
    color: white;
}

.agent-tab-content {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

/* Chat Layout */
.agent-chat-layout {
    display: flex;
    gap: 20px;
    height: calc(100vh - 100px);
}

.agent-chat-list {
    width: 280px;
    background: white;
    border-radius: 12px;
    overflow-y: auto;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.agent-chat-list-item {
    padding: 14px;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
}

.agent-chat-list-item:hover {
    background: #f8fafc;
}

.agent-chat-list-item .agent-chat-name {
    font-weight: 600;
    font-size: 14px;
}

.agent-chat-list-item .agent-chat-preview {
    font-size: 12px;
    color: #64748b;
    margin-top: 4px;
}

.agent-chat-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: white;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    overflow: hidden;
}

.agent-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.agent-chat-input-area {
    display: flex;
    padding: 12px;
    border-top: 1px solid #e2e8f0;
    gap: 8px;
}

.agent-chat-input-area input {
    flex: 1;
    border-radius: 20px;
    border: 1px solid #d1d5db;
    padding: 10px 16px;
    font-size: 14px;
}

/* BSP Dispute List */
.agent-dispute-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.agent-dispute-card {
    background: white;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    cursor: pointer;
}

.agent-dispute-card:hover {
    background: #f1f5f9;
}

.agent-dispute-detail {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.agent-dispute-detail .agent-decision-btns {
    display: flex;
    gap: 12px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.agent-btn {
    background: #2563eb;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.agent-btn.secondary {
    background: transparent;
    border: 1px solid #2563eb;
    color: #2563eb;
}

.agent-btn.danger {
    background: #ef4444;
}

/* Edit forms */
.agent-form-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    max-width: 500px;
    margin: 0 auto;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.agent-form-card input,
.agent-form-card textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 12px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    font-size: 14px;
}

/* Dark mode overrides for agent workspace (optional – keep light) */
/* The agent workspace intentionally remains light even if the main site uses dark mode,
   but you can add a class .agent-dark if needed in the future. */