/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    /* Theme handled by theme.css */
    line-height: 1.6;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Styles */
.header {
    text-align: center;
    color: var(--text-color);
    margin-bottom: 30px;
    padding: 20px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.header h1 {
    font-size: 2.5rem;
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    font-weight: 600;
}

.subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
}

/* Main Content Layout */
.main-content {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 140px);
    gap: 20px;
}

/* Card Styles */
.card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    height: 100%;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.card h2 {
    color: var(--text-color);
    margin-bottom: 20px;
    font-weight: 500;
}

/* Inputs */
input[type="text"] {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--glass-border);
    color: var(--text-color);
    padding: 15px;
    border-radius: 10px;
    outline: none;
    font-family: inherit;
    font-size: 1rem;
}

input[type="text"]:focus {
    border-color: var(--accent-color);
}

/* Buttons (Resetting specific classes to use glass-btn style logic) */
button {
    font-family: inherit;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-primary,
.btn-success {
    background: linear-gradient(90deg, #00f2ea 0%, #00c6fb 100%);
    color: #000;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    padding: 15px;
}

.btn-primary:hover,
.btn-success:hover {
    box-shadow: 0 0 20px rgba(0, 242, 234, 0.4);
    transform: translateY(-2px);
}

.btn-secondary,
.btn-danger {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--glass-border);
    color: white;
    border-radius: 50px;
    padding: 12px 20px;
    font-weight: 500;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-danger {
    background: rgba(255, 99, 71, 0.2);
    border-color: rgba(255, 99, 71, 0.5);
    color: #ff6347;
}

.btn-danger:hover {
    background: rgba(255, 99, 71, 0.4);
}

.info-box {
    margin-top: 30px;
    background: rgba(0, 0, 0, 0.2);
    padding: 20px;
    border-radius: 15px;
    border: 1px solid var(--glass-border);
}

.info-box h3 {
    color: var(--accent-color);
    margin-bottom: 10px;
}

.info-box ul {
    list-style-position: inside;
    color: var(--text-muted);
}

/* Video Container */
.video-container {
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 20px;
    height: 100%;
    min-height: 0;
}

.local-video-wrapper {
    background: #000;
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    border: 1px solid var(--glass-border);
    display: flex;
    flex-direction: column;
}

.remote-videos {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    padding: 15px;
    border: 1px solid var(--glass-border);
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 15px;
    align-content: center;
    overflow-y: auto;
}

video {
    width: 100%;
    height: 100%;
    background: #000;
    object-fit: cover;
}

.local-video-wrapper video {
    height: auto;
    max-height: 250px;
    flex: 1;
}

/* Video Controls Overlay */
.video-controls {
    display: flex;
    gap: 10px;
    padding: 15px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    justify-content: center;
}

.btn-control {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    border: 1px solid var(--glass-border);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.btn-control:hover {
    background: rgba(255, 255, 255, 0.3);
}

.btn-video.active,
.btn-audio.active {
    background: #ff4757;
    border-color: #ff4757;
    box-shadow: 0 0 10px rgba(255, 71, 87, 0.4);
}

/* Chat Controls Bar */
.chat-controls {
    background: var(--glass-bg);
    padding: 15px 20px;
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
}

.status-connected {
    background: rgba(0, 242, 234, 0.1);
    color: var(--accent-color);
    padding: 8px 16px;
    border-radius: 20px;
    border: 1px solid rgba(0, 242, 234, 0.3);
}

.status-disconnected {
    background: rgba(255, 71, 87, 0.1);
    color: #ff4757;
    padding: 8px 16px;
    border-radius: 20px;
    border: 1px solid rgba(255, 71, 87, 0.3);
}

/* Footer */
.footer {
    margin-top: 30px;
    padding: 20px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    color: var(--text-muted);
}

.footer i {
    color: var(--accent-color);
}

/* Responsive */
@media (max-width: 768px) {
    .video-container {
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr;
    }

    .header h1 {
        font-size: 1.8rem;
    }
}