/* Base Styles */
body {
    font-family: 'Inter', Arial, sans-serif;
    background-color: #f4f4f9;
    color: #333;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Container Styles */
.container {
    flex: 1;  /* This makes the container expand to push footer down */
}

.card {
    max-width: 400px;
    margin: 0 auto;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Navigation Button Styles - Preserved from current version */
.nav-button {
    display: block;
    width: 100%;
    margin-bottom: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 0.375rem;
    text-decoration: none;
    text-align: center;
    transition: all 0.2s ease-in-out;
}

.nav-button.primary {
    background-color: #0d6efd;
    color: white;
}

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

.nav-button.disabled {
    opacity: 0.75;
    cursor: not-allowed;
}

.nav-button:hover:not(.disabled) {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.nav-button.primary:hover:not(.disabled) {
    background-color: #0b5ed7;
}

.nav-button.secondary:hover:not(.disabled) {
    background-color: #5c636a;
}

/* Footer Styles - Enhanced version */
footer {
    background-color: #f8f9fa;
    padding: 1rem;
    text-align: center;
    border-top: 1px solid #dee2e6;
    margin-top: auto;  /* Push footer to bottom */
    width: 100%;
}

footer a {
    color: #007bff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

footer a:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* Responsive Adjustments */
@media (max-width: 576px) {
    .container {
        padding: 1rem;
    }
    
    .card {
        margin: 0 1rem;
    }
}

/* Header Styles */
header {
    background-color: #007bff;
    color: white;
    padding: 20px;
    text-align: center;
    font-size: 1.5rem;
    font-weight: 600;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

header h1 {
    margin: 0;
    color: white;
}

header p {
    margin: 10px 0 0;
    color: rgba(255, 255, 255, 0.9);
}

/* Agent Selector Styles */
.agent-selector {
    text-align: center;
    margin: 20px 0;
}

label {
    display: block;
    margin-bottom: 5px;
    font-size: 16px;
    font-weight: 600;
}

select {
    padding: 5px;
    font-size: 16px;
    margin-left: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

/* Main Content */
#namePrompt {
    display: flex;
}

#main-content {
    position: relative;
    display: none;
    flex: 1;
    padding: 20px;
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
}

#controls {
    max-width: 600px;
    width: 100%;
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    text-align: center;
}

/* Button Styles */
button {
    padding: 10px 20px;
    margin: 10px;
    border-radius: 5px;
    border: none;
    cursor: pointer;
    font-weight: bold;
    font-size: 0.9rem;
    transition: background-color 0.3s, transform 0.2s;
}

button:hover {
    transform: scale(1.05);
}

button:disabled {
    background-color: #cccccc;
    color: #666666;
    cursor: not-allowed;
    opacity: 0.65;
}

/* Specific Button Styles */
#joinBtn {
    background-color: #28a745;
    color: white;
}

#joinBtn:hover {
    background-color: #218838;
}

#leaveBtn {
    background-color: #dc3545;
    color: white;
}

#leaveBtn:hover {
    background-color: #c82333;
}

#muteBtn {
    background-color: #ffc107;
    color: black;
}

#muteBtn:hover {
    background-color: #e0a800;
}

#muteBtn::before {
    content: "🎤 ";
}

.muted#muteBtn::before {
    content: "🚫 ";
}

#sendBtn {
    background-color: #007bff;
    color: white;
}

#sendBtn:hover {
    background-color: #0056b3;
}

#dialOutBtn {
    background-color: #17a2b8;
    color: white;
}

#dialOutBtn:hover {
    background-color: #117a8b;
}

/* Mute Button States */
.muted {
    background-color: #ff4444;
    color: white;
}

.unmuted {
    background-color: #44ff44;
    color: black;
}

/* Participants List */
#participants {
    position: static; /* Remove absolute positioning */
    margin: 10px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 15px;
}

.user {
    display: flex;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid #eee;
}

.user:last-child {
    border-bottom: none;
}

.icon {
    margin-right: 10px;
}

.you {
    font-weight: bold;
    color: #007bff;
}

/* Input Styles */
input[type="file"],
input[type="tel"] {
    padding: 10px;
    margin: 10px 0;
    width: calc(100% - 20px);
    box-sizing: border-box;
    font-size: 1rem;
    border: 1px solid #ced4da;
    border-radius: 4px;
}

/* Overlay and Name Form */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.name-form {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 300px;
}

.name-form h2 {
    margin-top: 0;
    color: #333;
}

.name-form input {
    width: 100%;
    padding: 8px;
    margin: 10px 0;
    border: 1px solid #ddd;
    border-radius: 4px;
}

/* Audio Controls */
.audio-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 15px 0;
    padding: 10px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.audio-controls input[type="file"] {
    flex: 1;
    min-width: 0;
    margin-right: 10px;
}

.control-button {
    background: none;
    border: 2px solid #007bff;
    color: #007bff;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    font-size: 20px;
    transition: all 0.2s ease;
    margin: 0;
}

.control-button:hover {
    background-color: #007bff;
    color: white;
}

.control-button:active {
    transform: scale(0.95);
}

.control-button:disabled {
    border-color: #cccccc;
    color: #cccccc;
    cursor: not-allowed;
}

/* Text Input Container */
.text-input-container {
    display: none;
    margin: 20px auto;
    max-width: 600px;
}

.text-input-container textarea {
    width: 100%;
    min-height: 150px;
    padding: 12px;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    margin-bottom: 15px;
    font-family: inherit;
    resize: vertical;
    line-height: 1.5;
    font-size: 16px;
}

.text-input-container textarea:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.1);
}

/* Speaking Manager */
.speaking-manager {
    margin: 20px;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: white;
}

.current-speaker {
    margin-bottom: 15px;
    padding: 10px;
    background-color: #f5f5f5;
    border-radius: 4px;
}

.participants-list h3 {
    margin-bottom: 10px;
}

.participants-list ul {
    list-style: none;
    padding: 0;
}

.participants-list li {
    padding: 5px 0;
}

.next-speaker {
    font-weight: bold;
    color: #0066cc;
}

/* Footer */
footer {
    background-color: #f8f9fa;
    padding: 10px 20px;
    text-align: center;
    border-top: 1px solid #dee2e6;
    margin-top: auto;
}

footer a {
    color: #007bff;
    text-decoration: none;
    font-weight: bold;
}

footer a:hover {
    text-decoration: underline;
}

/* Image Upload Styles */
.image-upload-container {
    margin: 20px auto;
    max-width: 600px;
}

.upload-area {
    border: 2px dashed #ccc;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    background-color: #f9f9f9;
    transition: all 0.3s ease;
}

.upload-area:hover {
    border-color: #2a7ae4;
    background-color: #f0f7ff;
}

.preview-container {
    margin-top: 20px;
}

.preview-image {
    max-width: 100%;
    max-height: 300px;
    margin: 10px auto;
    border-radius: 8px;
    display: block;
}

.error-message {
    background-color: #fee2e2;
    border: 1px solid #fecaca;
    color: #dc2626;
    padding: 10px;
    border-radius: 6px;
    margin: 10px 0;
}

/* Summary Container */
.summary-container {
    background-color: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    margin-top: 20px;
}

.summary-container h4 {
    color: #333;
    margin: 0 0 10px 0;
    font-size: 16px;
    font-weight: bold;
}

#summaryText {
    color: #4b5563;
    font-size: 14px;
    line-height: 1.5;
}

/* Button Container */
.button-container {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 15px;
}

.generate-btn {
    background-color: #2a7ae4;
    color: white;
}

.generate-btn:hover {
    background-color: #1756a9;
}

.clear-btn {
    background-color: #6c757d;
    color: white;
}

.clear-btn:hover {
    background-color: #5a6268;
}

.control-button:disabled {
    border-color: #cccccc;
    color: #cccccc;
    cursor: not-allowed;
}

#downloadBtn {
    font-size: 24px;
}

#downloadBtn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}


#muteBtn {
    background-color: #ffc107;
    color: black;
}

#muteBtn:hover {
    background-color: #e0a800;
}
