* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
header {
    text-align: center;
    color: white;
    margin-bottom: 30px;
}

header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

header p {
    opacity: 0.9;
    font-size: 1.1em;
}

/* Screens */
.screen {
    display: none;
    flex: 1;
}

.screen.active {
    display: block;
}

/* Card */
.card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.card h2 {
    margin-bottom: 25px;
    color: #333;
    text-align: center;
}

/* Form */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #555;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
}

/* Buttons */
.btn {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

.btn-small {
    width: auto;
    padding: 8px 16px;
    font-size: 14px;
}

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

/* Chat Screen */
.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: white;
    padding: 15px 20px;
    border-radius: 15px;
    margin-bottom: 20px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.room-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.badge {
    background: #667eea;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
}

/* Audio Visualizer */
.audio-visualizer {
    background: white;
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 20px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

#visualizer {
    width: 100%;
    height: 150px;
    border-radius: 10px;
    background: #f8f9fa;
    margin-bottom: 15px;
}

#status-text {
    color: #666;
    font-size: 14px;
}

/* Push to Talk */
.controls {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.btn-ptt {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 10px 40px rgba(102, 126, 234, 0.4);
    transition: all 0.2s;
    user-select: none;
}

.btn-ptt:active,
.btn-ptt.recording {
    transform: scale(0.95);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.6);
    background: linear-gradient(135deg, #ff4757 0%, #ff6348 100%);
}

.ptt-icon {
    font-size: 40px;
}

.ptt-text {
    font-size: 12px;
    font-weight: 600;
}

/* Translation Log */
.translation-log {
    background: white;
    border-radius: 20px;
    padding: 20px;
    flex: 1;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.translation-log h3 {
    margin-bottom: 15px;
    color: #333;
}

#log-container {
    max-height: 200px;
    overflow-y: auto;
}

.log-item {
    padding: 10px;
    border-radius: 10px;
    margin-bottom: 10px;
    background: #f8f9fa;
}

.log-item .lang {
    font-size: 12px;
    color: #667eea;
    font-weight: 600;
}

.log-item .text {
    margin-top: 5px;
    color: #333;
}

/* Status Bar */
.status-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255,255,255,0.2);
    padding: 10px 20px;
    border-radius: 10px;
    margin-top: 20px;
    color: white;
    font-size: 14px;
}

.status-connected {
    color: #2ed573;
}

.status-disconnected {
    color: #ff4757;
}

/* Animations */
@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.recording {
    animation: pulse 1s infinite;
}

/* Responsive */
@media (max-width: 480px) {
    .container {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2em;
    }
    
    .card {
        padding: 20px;
    }
    
    .btn-ptt {
        width: 120px;
        height: 120px;
    }
}
