html, body {
    background: #fff;
    color: #111;
}

.voiceview-page .topbar { display: none; }
.voiceview-page > main.container {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
}

.voiceview-shell {
    min-height: 100vh;
    background: #fff;
}

.voiceview-header {
    min-height: 64px;
    display: flex;
    align-items: center;
    gap: 18px;
    padding: max(12px, env(safe-area-inset-top)) 22px 12px;
    border-bottom: 1px solid #d7dccb;
    background: #e6ead8;
}

.voiceview-brand {
    margin: 0 auto 0 0;
    font-size: 1.25rem;
    font-weight: 700;
    white-space: nowrap;
}

.voiceview-status-group {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 12px 16px;
    font-size: .9rem;
}

.voiceview-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
}

.voiceview-status strong { font-weight: 650; }
.voiceview-status-value { color: #59606a; }
.voiceview-status-value.active { color: #166534; }

.voiceview-switch {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
}

.voiceview-switch input {
    width: 42px;
    height: 24px;
    margin: 0;
    accent-color: #166534;
}

.voiceview-headset {
    width: 42px;
    height: 42px;
    padding: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #b9c0ac;
    border-radius: 50%;
    background: #fff;
    color: #111;
    cursor: pointer;
}

.voiceview-headset svg { width: 25px; height: 25px; }
.voiceview-headset.is-connected { color: #166534; border-color: #86a47c; }
.voiceview-headset:disabled { opacity: .55; cursor: wait; }

.voiceview-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 22px;
    border-bottom: 1px solid #e5e7eb;
}

.voiceview-controls label {
    font-size: .88rem;
    color: #4b5563;
    white-space: nowrap;
}

.voiceview-controls select {
    min-width: 180px;
    max-width: min(420px, 55vw);
    padding: 8px 10px;
    border: 1px solid #d1d5db;
    border-radius: 7px;
    background: #fff;
    font-size: 16px;
}

.voiceview-controls button {
    margin-left: auto;
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 7px;
    background: #fff;
    color: #111;
}

.voiceview-message {
    margin: 10px 22px 0;
    padding: 9px 11px;
    border-radius: 7px;
    background: #f3f4f6;
    color: #374151;
    font-size: .9rem;
}
.voiceview-message.error { background: #fef2f2; color: #991b1b; }

.voiceview-dots {
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 0 18px;
}
.voiceview-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #d1d5db;
    opacity: .5;
}
.voiceview-dots.voice-active .voiceview-dot { animation: vv-pulse .7s ease-in-out infinite alternate; }
.voiceview-dots.processing .voiceview-dot { animation: vv-progress 1.1s linear infinite; }
.voiceview-dots .voiceview-dot:nth-child(3n + 2) { animation-delay: .12s; }
.voiceview-dots .voiceview-dot:nth-child(3n) { animation-delay: .24s; }
@keyframes vv-pulse { to { opacity: 1; transform: scale(1.55); background: #111; } }
@keyframes vv-progress { 0%,60%,100% { opacity:.2; transform:scale(.8); } 25% { opacity:1; transform:scale(1.45); background:#111; } }

.voiceview-main { padding: 0 22px 28px; }
.voiceview-transcript-card {
    min-height: 52vh;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}
.voiceview-transcript-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 44px;
    padding: 8px 14px;
    border-bottom: 1px solid #e5e7eb;
}
.voiceview-transcript-header h2 { margin: 0; font-size: 1rem; }
#remote-transcript {
    min-height: 45vh;
    max-height: 66vh;
    overflow-y: auto;
    padding: 14px 16px 32px;
}
#remote-transcript .k2-stream-line,
#remote-transcript .hub-flight-transcript-line {
    margin: 0 0 15px;
    font-size: 1.15rem;
    line-height: 1.5;
    color: #111;
}
#remote-transcript .partial { opacity: .62; }
#remote-transcript .muted { color: #6b7280; }

.voiceview-recordings-panel {
    margin-top: 12px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    overflow: hidden;
}
.voiceview-recordings-panel h2 {
    margin: 0;
    padding: 11px 14px;
    font-size: 1rem;
    border-bottom: 1px solid #e5e7eb;
}
.voiceview-recordings-list { padding: 0 14px; }
.voiceview-recording-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid #eee;
}
.voiceview-recording-row:last-child { border-bottom: 0; }
.voiceview-recording-row > div:first-child { min-width: 0; flex: 1; }
.voiceview-recording-row strong,
.voiceview-recording-row small { display: block; overflow-wrap: anywhere; }
.voiceview-recording-row small { margin-top: 3px; color: #6b7280; }
.voiceview-recording-actions { display: flex; gap: 8px; }
.voiceview-recording-actions button {
    min-height: 38px;
    padding: 7px 10px;
    border: 1px solid #d1d5db;
    border-radius: 7px;
    background: #fff;
}

.voiceview-runtime {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
}

@media (max-width: 700px) {
    .voiceview-header {
        align-items: flex-start;
        padding-left: 14px;
        padding-right: 14px;
        gap: 10px;
    }
    .voiceview-brand { font-size: 1.05rem; padding-top: 10px; }
    .voiceview-status-group { gap: 8px 10px; font-size: .82rem; }
    .voiceview-controls { padding-left: 14px; padding-right: 14px; flex-wrap: wrap; }
    .voiceview-controls select { flex: 1 1 180px; max-width: 100%; }
    .voiceview-controls button { margin-left: 0; }
    .voiceview-main { padding-left: 10px; padding-right: 10px; }
    .voiceview-message { margin-left: 14px; margin-right: 14px; }
    #remote-transcript { padding-left: 12px; padding-right: 12px; }
    .voiceview-recording-row { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
    .voiceview-dots.voice-active .voiceview-dot,
    .voiceview-dots.processing .voiceview-dot { animation: none; }
}
