/* MCU API Integration Styles */

/* Recordings Section */
.recordings-section {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    padding: 20px;
}

/* WebRTC Bridge Section */
.webrtc-section {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    padding: 20px;
}

/* Bridge Status Cards */
.bridge-status {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
}

.status-card {
    background-color: #f8f9fa;
    border-radius: 6px;
    flex: 1;
    min-width: 200px;
    padding: 15px;
    text-align: center;
}

.status-card h3 {
    color: #333;
    font-size: 16px;
    margin-bottom: 10px;
}

.status-card p {
    color: #007bff;
    font-size: 24px;
    font-weight: 700;
    margin: 0;
}

/* WebRTC Events */
.webrtc-events {
    margin-top: 20px;
}

.events-container {
    background-color: #f8f9fa;
    border-radius: 6px;
    height: 200px;
    margin-top: 10px;
    overflow-y: auto;
    padding: 10px;
}

.events-list {
    display: flex;
    flex-direction: column;
}

.event-item {
    border-bottom: 1px solid #e9ecef;
    display: flex;
    font-size: 14px;
    padding: 8px 5px;
}

.event-item:last-child {
    border-bottom: none;
}

.event-item.error {
    background-color: #fff5f5;
}

.event-time {
    color: #6c757d;
    flex: 0 0 80px;
}

.event-type {
    color: #343a40;
    flex: 1;
    font-weight: 500;
    text-transform: capitalize;
}

.event-endpoint {
    color: #007bff;
    flex: 0 0 120px;
    text-align: right;
}

/* Room Control Buttons */
.room-control-buttons {
    display: flex;
    gap: 10px;
    margin: 15px 0;
}

/* Participant Control Buttons */
.small-btn {
    font-size: 12px;
    padding: 3px 8px;
}

.danger-btn {
    background-color: #dc3545;
    color: white;
}

.danger-btn:hover {
    background-color: #c82333;
}

.warning-btn {
    background-color: #ffc107;
    color: #212529;
}

.warning-btn:hover {
    background-color: #e0a800;
}

/* Room Status Info */
.room-status-info {
    background-color: #f8f9fa;
    border-radius: 6px;
    margin: 15px 0;
    padding: 10px;
}

.room-status-info p {
    margin: 5px 0;
}

/* Participants Table */
.participants-table {
    margin-top: 15px;
    width: 100%;
}

.participants-table th,
.participants-table td {
    font-size: 14px;
    padding: 8px;
    text-align: left;
}

/* Section Header with Refresh Button */
.section-header {
    align-items: center;
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
}

.section-header h2 {
    margin: 0;
}

/* Status Badge */
.status-badge {
    border-radius: 4px;
    display: inline-block;
    font-size: 12px;
    font-weight: 500;
    padding: 3px 8px;
    text-transform: uppercase;
}

.status-badge.active {
    background-color: #28a745;
    color: white;
}

.status-badge.completed {
    background-color: #6c757d;
    color: white;
}

/* Form Hint */
.form-hint {
    color: #6c757d;
    display: block;
    font-size: 12px;
    margin-top: 5px;
}

/* Dial-Out Button Styling */
#dial-out-btn {
    background-color: #17a2b8;
    border-color: #17a2b8;
}

#dial-out-btn:hover {
    background-color: #138496;
    border-color: #117a8b;
}

/* Dial-Out Section in Room Details */
.dial-out-section {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    margin: 15px 0;
    padding: 15px;
}

.dial-out-section h3 {
    color: #333;
    font-size: 16px;
    margin: 0 0 12px 0;
}

.dial-out-form-inline {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.dial-out-input {
    border: 1px solid #ced4da;
    border-radius: 4px;
    flex: 1;
    font-size: 14px;
    padding: 8px 12px;
}

.dial-out-input:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
    outline: none;
}

/* Dial-Out Status Container */
.dial-out-status-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 200px;
    overflow-y: auto;
}

/* Dial-Out Status Card */
.dial-out-status-card {
    align-items: center;
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    display: flex;
    justify-content: space-between;
    padding: 10px 12px;
    transition: all 0.3s ease;
}

.dial-out-status-card.status-ringing {
    background-color: #fff3cd;
    border-color: #ffc107;
}

.dial-out-status-card.status-connecting {
    background-color: #cce5ff;
    border-color: #007bff;
}

.dial-out-status-card.status-connected {
    background-color: #d4edda;
    border-color: #28a745;
}

.dial-out-status-card.status-failed {
    background-color: #f8d7da;
    border-color: #dc3545;
}

.dial-out-status-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dial-out-address {
    color: #333;
    font-weight: 500;
}

.dial-out-state {
    align-items: center;
    color: #666;
    display: flex;
    font-size: 13px;
    gap: 6px;
}

/* Status Icons */
.status-icon {
    border-radius: 50%;
    display: inline-block;
    height: 10px;
    width: 10px;
}

.status-icon.ringing {
    animation: pulse 1s infinite;
    background-color: #ffc107;
}

.status-icon.connecting {
    animation: pulse 0.8s infinite;
    background-color: #007bff;
}

.status-icon.connected {
    background-color: #28a745;
}

.status-icon.failed {
    background-color: #dc3545;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 currentColor;
        opacity: 1;
    }
    50% {
        box-shadow: 0 0 0 4px currentColor;
        opacity: 0.7;
    }
    100% {
        box-shadow: 0 0 0 0 currentColor;
        opacity: 1;
    }
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .bridge-status {
        flex-direction: column;
    }

    .status-card {
        min-width: 100%;
    }

    .room-control-buttons {
        flex-wrap: wrap;
    }
}