/* supervisor.css - Estilos específicos del panel de supervisor */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    background: linear-gradient(135deg, #1e2329 0%, #2b2f36 100%);
    color: #e8eaed;
    padding: 20px;
    min-height: 100vh;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

/* Header */
.header {
    margin-bottom: 40px;
    background: linear-gradient(135deg, #1e2329 0%, #2b2f36 100%);
    padding: 25px 30px;
    border-radius: 12px;
    border: 1px solid #3a3f47;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 20px;
}

.header-left {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 20px;
}

.header-center {
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
}

.header-logo {
    height: 45px;
    width: auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

/* View Switcher */
.view-switcher-supervisor {
    display: flex;
    gap: 8px;
    background: #1a1f2e;
    padding: 4px;
    border-radius: 8px;
    border: 1px solid #3a3f47;
    margin-bottom: 20px;
    width: fit-content;
}

.view-btn-super {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: transparent;
    color: #9ca3af;
    text-decoration: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
}

.view-btn-super:hover {
    background: #2b2f36;
    color: #e8eaed;
}

.view-btn-super.active {
    background: linear-gradient(135deg, #e91e63 0%, #c2185b 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(233, 30, 99, 0.3);
}

.view-icon {
    font-size: 16px;
}

.view-text {
    font-size: 12px;
    letter-spacing: 0.5px;
}

.header-center h1 {
    color: #e91e63;
    font-size: 24px;
    margin-bottom: 8px;
    text-shadow: 0 2px 10px rgba(233, 30, 99, 0.3);
}

.header-center p {
    color: #9ca3af;
    font-size: 14px;
    margin: 0;
}

/* Main Panel Grid */
.main-panel {
    display: grid;
    grid-template-columns: 1.2fr 2fr 1fr;
    gap: 20px;
    align-items: stretch;
    height: calc(100vh - 200px);
}

/* Panel de Agentes */
.agents-panel {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: #2b2f36;
    padding: 20px;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
    border: 1px solid #3a3f47;
}

/* CCP Section */
.ccp-section {
    background: linear-gradient(135deg, #1e2329 0%, #2b2f36 100%);
    border: 1px solid #3a3f47;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.ccp-section h2 {
    color: #e91e63;
    margin-bottom: 15px;
    font-size: 18px;
    font-weight: 600;
}

#ccp-container {
    width: 100%;
    height: 500px;
    border-radius: 8px;
    background: #0f1419;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #8b949e;
    font-size: 16px;
}

/* Controles de Micrófono */
.mic-controls {
    text-align: center;
    padding: 16px;
    background: linear-gradient(135deg, #1e2329 0%, #2b2f36 100%);
    border-radius: 12px;
    margin-bottom: 20px;
    border: 1px solid #3a3f47;
}

.mic-icon {
    font-size: 40px;
    margin-bottom: 12px;
    display: block;
}

.mic-btn {
    background: linear-gradient(135deg, #374151, #1f2937);
    color: #e8eaed;
    border: 1px solid #6b7280;
    padding: 10px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    text-transform: none;
    letter-spacing: 0.5px;
}

.mic-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
    border-color: #e91e63;
}

.mic-btn.active {
    background: linear-gradient(135deg, #059669, #047857);
    color: white;
    border-color: #10b981;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { 
        box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.7);
    }
    50% { 
        box-shadow: 0 0 0 20px rgba(76, 175, 80, 0);
    }
}

#current-status {
    text-align: center;
    padding: 15px;
    margin-top: 15px;
    font-size: 15px;
    color: #9ca3af;
    background: #1e2329;
    border-radius: 8px;
    font-weight: 500;
}

#current-status.active {
    color: #4caf50;
    border: 1px solid #4caf50;
}

/* Lista de Agentes */
.section-title {
    color: #e8eaed;
    font-size: 20px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.agent-list {
    display: grid;
    gap: 12px;
    max-height: 520px;
    overflow: auto;
    padding: 4px 4px 4px 0;
}

.agent-item {
    background: linear-gradient(135deg, #3a3f47 0%, #2b2f36 100%);
    padding: 16px 20px;
    border-radius: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
    border: 1px solid transparent;
    min-height: 60px;
}

.agent-item:hover {
    border-color: #e91e63;
    transform: translateY(-2px);
}

.agent-item.active {
    background: linear-gradient(135deg, #4caf50 0%, #388e3c 100%);
    border-color: #4caf50;
}

.agent-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.status {
    display: inline-block;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    animation: blink 2s infinite;
}

.status-connected {
    background: #4caf50;
    box-shadow: 0 0 10px rgba(76, 175, 80, 0.6);
}

.status-disconnected {
    background: #9e9e9e;
    animation: none;
}

.status-active {
    background: #e91e63;
    box-shadow: 0 0 15px rgba(233, 30, 99, 0.8);
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.agent-name {
    font-weight: 600;
    font-size: 16px;
    color: #e8eaed;
}

.agent-id {
    font-size: 12px;
    color: #9ca3af;
}

/* Botones de Conexión */
.connect-btn, .disconnect-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 12px;
    transition: all 0.3s ease;
}

.connect-btn {
    background: linear-gradient(135deg, #4caf50 0%, #388e3c 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.connect-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(76, 175, 80, 0.5);
}

.connect-btn:disabled {
    background: #555;
    cursor: not-allowed;
    opacity: 0.5;
    transform: none;
}

.disconnect-btn {
    background: linear-gradient(135deg, #f44336 0%, #c62828 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(244, 67, 54, 0.3);
}

.disconnect-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(244, 67, 54, 0.5);
}

/* Panel de Monitoreo */
.monitoring-panel {
    background: linear-gradient(135deg, #1e2329 0%, #2b2f36 100%);
    border: 1px solid #3a3f47;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
    display: flex;
    flex-direction: column;
}

.monitoring-header h3 {
    color: #e91e63;
    margin-bottom: 6px;
    font-size: 16px;
    font-weight: 600;
}

.monitoring-header p {
    color: #9ca3af;
    font-size: 12px;
    margin-bottom: 12px;
}

.monitoring-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
}

.monitoring-option {
    background: #0f1419;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #3a3f47;
}

.monitoring-option h4 {
    color: #e8eaed;
    margin-bottom: 8px;
    font-size: 14px;
}

.monitoring-btn {
    display: inline-block;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    padding: 8px 16px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    margin-bottom: 6px;
}

.monitoring-btn:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.4);
}

.monitoring-desc {
    color: #9ca3af;
    font-size: 11px;
    margin: 0;
    line-height: 1.3;
}

.monitoring-note {
    background: #1a1f2e;
    border: 1px solid #3a3f47;
    border-radius: 6px;
    padding: 8px 12px;
    margin-top: 8px;
    font-size: 11px;
    color: #9ca3af;
    line-height: 1.3;
}

.monitoring-note strong {
    color: #e91e63;
}

/* Instrucciones */
.instruction-step {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 0;
    border-bottom: 1px solid #3a3f47;
}

.instruction-step:last-child {
    border-bottom: none;
}

.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #e91e63 0%, #c2185b 100%);
    color: white;
    border-radius: 50%;
    font-size: 10px;
    font-weight: 600;
    flex-shrink: 0;
}

.step-text {
    color: #e8eaed;
    font-size: 11px;
    line-height: 1.3;
}

/* Notificaciones */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #e91e63;
    color: white;
    padding: 15px 25px;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(233, 30, 99, 0.5);
    z-index: 10000;
    animation: slideIn 0.3s ease;
    font-weight: 500;
}

@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

/* Footer */
.footer {
    text-align: center;
    margin-top: 40px;
    color: #6b7280;
    font-size: 13px;
}

/* Responsive Design */
@media (max-width: 1400px) {
    .main-panel {
        grid-template-columns: 1.2fr 2fr;
        gap: 15px;
    }
    
    .monitoring-panel {
        order: 3;
        grid-column: 1 / -1;
    }
}

@media (max-width: 1024px) {
    .main-panel {
        grid-template-columns: 1fr;
        gap: 15px;
        height: auto;
    }
    
    .agents-panel,
    .ccp-section,
    .monitoring-panel {
        order: unset;
    }
    
    .agent-list {
        max-height: 400px;
    }
    
    #ccp-container {
        height: 400px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .header h1 {
        font-size: 20px;
    }
    
    #ccp-container {
        height: 300px;
    }
}

