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

body {
    font-family: 'Amazon Ember', Arial, sans-serif;
    background: linear-gradient(135deg, #0f171e 0%, #1a2a3a 100%);
    color: #ffffff;
    min-height: 100vh;
}

.app-container { max-width: 900px; margin: 0 auto; padding: 1rem; }

.header {
    text-align: center;
    padding: 2rem 0 1rem;
}

.logo { font-size: 1.8rem; font-weight: 700; }
.logo-alexa { color: #00a8e1; }
.logo-tv { color: #ffffff; font-weight: 400; margin-left: 0.25rem; }

.main-content { display: flex; flex-direction: column; gap: 1.5rem; }

/* Voice Button */
.voice-area { display: flex; flex-direction: column; align-items: center; gap: 1rem; padding: 2rem 0; }

.voice-btn-large {
    width: 100px; height: 100px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #00a8e1 0%, #0077b6 100%);
    color: white;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: all 0.3s;
    box-shadow: 0 4px 20px rgba(0, 168, 225, 0.3);
}

.voice-btn-large:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 30px rgba(0, 168, 225, 0.5);
}

.voice-btn-large.recording {
    background: linear-gradient(135deg, #ff4444 0%, #ff6666 100%);
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255, 68, 68, 0.7); }
    50% { box-shadow: 0 0 0 20px rgba(255, 68, 68, 0); }
}

.voice-status { font-size: 0.95rem; color: rgba(255,255,255,0.7); }

/* Chat */
.chat-container {
    background: rgba(0,0,0,0.3);
    border-radius: 12px;
    padding: 1rem;
    min-height: 120px;
    max-height: 250px;
    overflow-y: auto;
}

.chat-container::after { content: ""; display: table; clear: both; }

.message {
    margin-bottom: 0.5rem; padding: 0.6rem 0.8rem;
    border-radius: 8px; font-size: 0.9rem;
    display: inline-block; max-width: 85%;
}
.message.user { background: rgba(0,168,225,0.2); float: right; clear: both; text-align: right; }
.message.assistant { background: rgba(255,255,255,0.1); float: left; clear: both; }
.message.system { background: transparent; font-size: 0.8rem; font-style: italic; color: rgba(255,255,255,0.5); float: left; clear: both; }
.role-label { font-size: 0.7rem; font-weight: 600; margin-bottom: 0.3rem; color: rgba(255,255,255,0.5); }

/* Text Input */
.text-input-area { display: flex; gap: 0.5rem; }
.text-input {
    flex: 1; padding: 0.75rem;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 8px; color: white; font-size: 0.9rem; outline: none;
}
.text-input:focus { border-color: #00a8e1; background: rgba(255,255,255,0.15); }
.send-btn {
    padding: 0.75rem 1rem; background: #00a8e1; border: none;
    border-radius: 8px; color: white; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
}
.send-btn:hover { background: #0090c4; }

/* Results Grid - Top 5 Movie Cards */
.results-area { padding: 1rem 0; }
.results-title { font-size: 1.2rem; font-weight: 600; margin-bottom: 1rem; }

.results-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
}

.movie-card {
    background: #1a2332;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.movie-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
}

.movie-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.movie-card-info {
    padding: 0.75rem;
}

.movie-card-title {
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 0.25rem;
}

.movie-card-year {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.5);
}

@media (max-width: 768px) {
    .results-grid { grid-template-columns: repeat(2, 1fr); }
    .voice-btn-large { width: 80px; height: 80px; }
}
