* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

body {
    background-color: #f8f9fd;
    color: #333;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.agent-container {
    background-color: white;
    border-radius: 16px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 600px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 90vh;
    max-height: 800px;
}

/* Header styles */
.agent-header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #eaedf5;
}

.status-section {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
}

#status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    transition: background-color 0.3s ease;
}

#status-indicator.initializing {
    background-color: #ffab00;
    animation: pulse-status 1.5s ease infinite;
}

#status-indicator.connected {
    background-color: #00c853;
}

#status-indicator.listening {
    background-color: #4f46e5;
    animation: pulse-status 1.5s ease infinite;
}

#status-indicator.disconnected,
#status-indicator.error {
    background-color: #ff3d00;
}

@keyframes pulse-status {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

#status-text {
    color: #667085;
    font-size: 14px;
    font-weight: 500;
}

/* Main content */
.agent-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Video container styles */
.video-container {
    flex: 1;
    background-color: #f8f9fd;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

#placeholder-message {
    text-align: center;
    color: #667085;
    padding: 20px;
    font-size: 16px;
    max-width: 80%;
}

.video-container video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-container audio {
    display: none;
}

/* Controls styles */
.controls {
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    border-top: 1px solid #eaedf5;
    background-color: white;
}

.mic-button {
    background-color: #4f46e5;
    color: white;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    position: relative;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.mic-button:hover:not(:disabled) {
    transform: scale(1.05);
    background-color: #4338ca;
}

.mic-button:active:not(:disabled) {
    transform: scale(0.95);
}

.mic-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.mic-button.listening {
    background-color: #ef4444;
}

.mic-button.listening::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 3px solid #ef4444;
    animation: pulse-ring 1.5s ease infinite;
}

@keyframes pulse-ring {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(1.4);
        opacity: 0;
    }
}

.start-message {
    text-align: center;
    color: #667085;
    font-size: 14px;
    margin-top: 8px;
}

.end-button {
    margin-top: 12px;
    padding: 10px 24px;
    background-color: #ef4444;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.end-button:hover {
    background-color: #dc2626;
}

/* Footer */
.agent-footer {
    padding: 16px;
    text-align: center;
    border-top: 1px solid #eaedf5;
    background-color: #fafbff;
}

.back-link {
    color: #4f46e5;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s ease;
}

.back-link:hover {
    color: #4338ca;
}

/* Feedback messages */
.feedback-info,
.feedback-warning,
.feedback-error {
    padding: 12px;
    border-radius: 8px;
    font-size: 14px;
    text-align: center;
}

.feedback-info {
    background-color: #e3f2fd;
    color: #1565c0;
}

.feedback-warning {
    background-color: #fff3e0;
    color: #e65100;
}

.feedback-error {
    background-color: #ffebee;
    color: #c62828;
}

/* Utility buttons (retry, debug, etc.) */
.retry-button,
.debug-button,
.join-call-button {
    margin-top: 12px;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: opacity 0.2s ease;
}

.retry-button {
    background-color: #4a90e2;
    color: white;
}

.retry-button:hover {
    opacity: 0.9;
}

.debug-button {
    background-color: #6c757d;
    color: white;
}

.debug-button:hover {
    opacity: 0.9;
}

.join-call-button {
    background-color: #28a745;
    color: white;
}

.join-call-button:hover {
    opacity: 0.9;
}

/* Debug panel */
.debug-panel {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 16px;
    margin-top: 16px;
    font-family: monospace;
    font-size: 12px;
    max-height: 400px;
    overflow-y: auto;
}

.debug-panel h3 {
    font-size: 14px;
    margin-bottom: 12px;
    font-family: 'Inter', sans-serif;
}

.debug-panel pre {
    background-color: #e9ecef;
    padding: 8px;
    border-radius: 4px;
    overflow-x: auto;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    body {
        padding: 0;
    }
    
    .agent-container {
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
    }
    
    .mic-button {
        width: 56px;
        height: 56px;
    }
}

