/* H5 公共样式 */
* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", sans-serif;
    background: #f5f7fb;
    color: #1f2937;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

.page {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    padding-left: env(safe-area-inset-left, 0);
    padding-right: env(safe-area-inset-right, 0);
}

.page-header {
    padding: 24px 16px 12px;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #fff;
}

.page-title {
    margin: 0;
    font-size: 22px;
}

.page-subtitle {
    margin: 8px 0 0;
    font-size: 13px;
    opacity: 0.9;
}

.page-main {
    flex: 1;
    padding: 16px;
}

.page-footer {
    padding: 12px 16px calc(20px + env(safe-area-inset-bottom, 0));
    text-align: center;
    font-size: 12px;
    color: #9ca3af;
}

.page-footer a {
    color: #6b7280;
    text-decoration: none;
}

.page-footer a:hover {
    text-decoration: underline;
}

.footer-note {
    margin: 0 0 6px;
    line-height: 1.5;
}

.footer-beian {
    margin: 0;
    line-height: 1.6;
}

.footer-sep {
    margin: 0 6px;
    color: #d1d5db;
}

.home-desc-sub {
    margin-top: 8px;
    font-size: 13px;
    color: #6b7280;
}

.card {
    background: #fff;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}

.card-title {
    margin: 0 0 12px;
    font-size: 16px;
}

.status-text {
    margin: 0 0 12px;
    font-size: 14px;
    line-height: 1.6;
    color: #4b5563;
}

.status-text.ok {
    color: #059669;
}

.status-text.error {
    color: #dc2626;
}

.btn {
    display: inline-block;
    border: none;
    border-radius: 8px;
    padding: 10px 16px;
    font-size: 14px;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.btn-primary {
    background: #2563eb;
    color: #fff;
}

.btn-default {
    background: #e5e7eb;
    color: #374151;
}

.btn-danger {
    background: #ef4444;
    color: #fff;
}

.btn-small {
    padding: 6px 10px;
    font-size: 12px;
    margin-right: 6px;
}

.input {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 14px;
    outline: none;
}

.input:focus {
    border-color: #2563eb;
}

.form-row {
    display: flex;
    gap: 8px;
}

.form-row .input {
    flex: 1;
}

.tip-text {
    margin: 10px 0 0;
    font-size: 13px;
    min-height: 18px;
}

.tip-text.ok {
    color: #059669;
}

.tip-text.error {
    color: #dc2626;
}

.card-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.card-title-inline {
    margin: 0;
}

.table-wrap {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.data-table th,
.data-table td {
    border-bottom: 1px solid #f3f4f6;
    padding: 10px 8px;
    text-align: left;
    vertical-align: middle;
}

.data-table th {
    color: #6b7280;
    font-weight: 600;
    background: #f9fafb;
}

.empty-cell {
    text-align: center;
    color: #9ca3af;
}

.modal.hidden {
    display: none;
}

.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
}

.modal-mask {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
}

.modal-panel {
    position: relative;
    width: calc(100% - 32px);
    max-width: 420px;
    margin: 30vh auto 0;
    background: #fff;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.2);
}

.modal-title {
    margin: 0 0 8px;
    font-size: 16px;
}

.modal-desc {
    margin: 0 0 12px;
    font-size: 13px;
    color: #6b7280;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 16px;
}

.menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.menu-item {
    padding: 12px 0;
    border-bottom: 1px solid #f3f4f6;
    font-size: 14px;
}

.menu-item:last-child {
    border-bottom: none;
}

.menu-item-disabled {
    color: #9ca3af;
}

.hidden {
    display: none !important;
}

.view.hidden {
    display: none;
}

.btn-block {
    width: 100%;
}

.btn-text {
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    cursor: pointer;
    padding: 0;
}

.home-main {
    display: flex;
    align-items: center;
    justify-content: center;
}

.home-card {
    width: 100%;
    max-width: 520px;
}

.interview-main {
    width: 100%;
    max-width: 720px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.interview-main.live-main-active {
    max-width: none;
    padding: 12px 16px 0;
}

#interviewView.interview-live-active {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.page.interview-live-page .page-footer {
    display: none;
}

.phase-card {
    margin-bottom: 12px;
}

#livePhase.live-phase-active {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    margin-bottom: 0;
    padding-bottom: calc(72px + env(safe-area-inset-bottom, 0));
}

#livePhase.live-phase-active .live-layout {
    flex: 1;
    min-height: 0;
    margin-top: 0;
}

#livePhase.live-phase-active .live-main-col {
    display: flex;
    flex-direction: column;
    min-height: 0;
    flex: 1;
}

#livePhase.live-phase-active .dialogue-list,
#livePhase.live-phase-active .dialogue-columns {
    flex: 1;
    min-height: 0;
    max-height: none;
    height: calc(80vh - 180px);
    height: calc(80dvh - 180px);
}

#livePhase.live-phase-active .dialogue-columns .dialogue-list {
    height: 100%;
    max-height: none;
}

#livePhase.live-phase-active .question-history-list {
    max-height: calc(80dvh - 180px);
}

#livePhase.live-phase-active #answerPanel:not(.hidden) ~ #dialogueList,
#livePhase.live-phase-active #answerPanel:not(.hidden) ~ #dialogueColumns {
    height: calc(50dvh - 120px);
}

@media (min-width: 768px) {
    .page-header {
        padding: 28px 24px 16px;
    }

    .page-main {
        padding: 20px 24px;
    }

    .interview-main.live-main-active {
        padding: 16px 24px 0;
    }

    #livePhase.live-phase-active .dialogue-list,
    #livePhase.live-phase-active .dialogue-columns {
        height: calc(80vh - 160px);
        height: calc(80dvh - 160px);
    }

    .btn-record {
        min-width: 140px;
    }
}

@media (max-width: 360px) {
    .record-row {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-record {
        width: 100%;
    }
}

.phase-script {
    margin: 0 0 20px;
    padding: 16px;
    font-size: 16px;
    line-height: 1.8;
    color: #1f2937;
    background: #f9fafb;
    border-radius: 8px;
    text-align: center;
}

.voice-timer {
    margin: 0 0 16px;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.5;
    color: #2563eb;
    text-align: center;
}

.voice-timer.hidden {
    display: none;
}

.phase-desc {
    margin: 0 0 16px;
    font-size: 15px;
    line-height: 1.7;
    color: #374151;
}

.record-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-record {
    min-width: 120px;
}

.home-desc {
    margin: 0 0 16px;
    font-size: 14px;
    line-height: 1.7;
    color: #4b5563;
}

.interview-header {
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.interview-header-main {
    flex: 1;
    min-width: 0;
}

.btn-text-end {
    flex-shrink: 0;
    white-space: nowrap;
    margin-top: 2px;
}

.btn-text-end:disabled {
    opacity: 0.55;
}

.page-title-sm {
    font-size: 18px;
}

#sessionIdText {
    word-break: break-all;
}

.btn-record.recording {
    background: #dc2626;
}

.record-status {
    font-size: 13px;
    color: #6b7280;
}

.live-correct-hint {
    margin: 0 0 12px;
    padding: 10px 12px;
    font-size: 13px;
    line-height: 1.6;
    color: #4b5563;
    background: #f8fafc;
    border-radius: 8px;
    border-left: 3px solid #2563eb;
}

.live-status-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.live-status {
    font-size: 13px;
    color: #059669;
}

.live-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #d1d5db;
}

.live-indicator.active {
    background: #ef4444;
    animation: pulse 1.2s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.35; }
    100% { opacity: 1; }
}

.dialogue-list {
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dialogue-empty {
    margin: 0;
    text-align: center;
    color: #9ca3af;
    font-size: 13px;
}

.dialogue-empty.error {
    color: #dc2626;
}

.dialogue-item {
    display: flex;
    flex-direction: column;
    max-width: 92%;
}

.dialogue-row {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    max-width: 100%;
}

.dialogue-item.candidate .dialogue-row,
.dialogue-item.mixed .dialogue-row {
    flex-direction: row;
}

.dialogue-item.interviewer .dialogue-row {
    flex-direction: row-reverse;
}

.dialogue-actions {
    position: relative;
    flex-shrink: 0;
}

.dialogue-more-btn {
    width: 28px;
    height: 28px;
    border: none;
    background: #f3f4f6;
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    line-height: 28px;
    color: #6b7280;
    padding: 0;
    text-align: center;
}

.dialogue-more-btn:hover {
    background: #e5e7eb;
    color: #374151;
}

.dialogue-menu {
    position: absolute;
    top: calc(100% + 4px);
    min-width: 132px;
    padding: 4px 0;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
    z-index: 30;
}

.dialogue-item.candidate .dialogue-menu,
.dialogue-item.mixed .dialogue-menu {
    right: 0;
}

.dialogue-item.interviewer .dialogue-menu {
    left: 0;
}

.dialogue-menu.hidden {
    display: none;
}

.dialogue-menu-item {
    display: block;
    width: 100%;
    box-sizing: border-box;
    border: none;
    background: transparent;
    text-align: left;
    padding: 8px 12px;
    font-size: 13px;
    color: #374151;
    cursor: pointer;
    white-space: nowrap;
}

.dialogue-menu-item:hover {
    background: #f3f4f6;
}

.dialogue-menu-item:disabled {
    color: #9ca3af;
    cursor: default;
    background: transparent;
}

.dialogue-item.candidate {
    align-self: flex-start;
}

.dialogue-item.interviewer {
    align-self: flex-end;
    align-items: flex-end;
}

.dialogue-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 4px;
}

.dialogue-role-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.4;
}

.dialogue-role-badge.candidate {
    background: #dbeafe;
    color: #1d4ed8;
}

.dialogue-role-badge.interviewer {
    background: #d1fae5;
    color: #047857;
}

.dialogue-correct-btn {
    display: none;
}

.dialogue-corrected-tag {
    font-size: 11px;
    color: #9ca3af;
}

.dialogue-bubble {
    flex: 1;
    min-width: 0;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.6;
    word-break: break-word;
}

.dialogue-item.candidate .dialogue-bubble {
    background: #eff6ff;
    color: #1e3a8a;
}

.dialogue-item.interviewer .dialogue-bubble {
    background: #ecfdf5;
    color: #065f46;
}

.calibration-card {
    margin-bottom: 14px;
    padding: 16px 14px;
    border-radius: 12px;
    background: linear-gradient(180deg, #fffbeb 0%, #ffffff 100%);
    border: 1px solid #fcd34d;
    text-align: center;
}

.calibration-title {
    margin: 0 0 12px;
    font-size: 14px;
    line-height: 1.6;
    color: #92400e;
    font-weight: 600;
}

.calibration-score {
    margin: 0 0 8px;
    font-size: 12px;
    color: #b45309;
}

.calibration-text {
    margin: 0 0 16px;
    padding: 14px 12px;
    font-size: 16px;
    line-height: 1.7;
    color: #1f2937;
    background: #ffffff;
    border-radius: 10px;
    border: 1px dashed #f59e0b;
    word-break: break-word;
}

.calibration-actions {
    display: flex;
    gap: 12px;
}

.btn-calibration {
    flex: 1;
    padding: 12px 10px;
    font-size: 15px;
    font-weight: 600;
    border: none;
    border-radius: 10px;
    color: #fff;
}

.btn-calibration-left {
    background: #2563eb;
}

.btn-calibration-right {
    background: #059669;
}

.mode-select-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 12px 0;
}

.mode-card {
    display: block;
    padding: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
}

.mode-card input {
    margin-right: 8px;
}

.mode-card-title {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
}

.mode-card-desc {
    display: block;
    font-size: 12px;
    color: #6b7280;
}

.answer-mode-row {
    margin: 12px 0 16px;
    font-size: 14px;
}

.answer-mode-row label {
    margin-right: 12px;
}

.dialogue-columns {
    display: flex;
    gap: 10px;
    min-height: 0;
}

.dialogue-columns.hidden {
    display: none;
}

.dialogue-col {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.dialogue-col-title {
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    margin-bottom: 8px;
    text-align: center;
}

.dialogue-col-interviewer .dialogue-item.interviewer {
    align-self: flex-end;
    align-items: flex-end;
}

.dialogue-col-candidate .dialogue-item.candidate {
    align-self: flex-start;
}

.dialogue-col .dialogue-list {
    min-height: 0;
}

.dialogue-item.mixed {
    align-self: center;
    max-width: 92%;
}

.dialogue-role-badge.mixed {
    background: #f3f4f6;
    color: #4b5563;
}

.job-id-row {
    margin-bottom: 16px;
}

.job-id-row label {
    display: block;
    font-size: 13px;
    color: #4b5563;
    margin-bottom: 6px;
}

.job-id-input {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
}

.category-select-section {
    margin-bottom: 16px;
}

.category-select-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 10px;
}

.direction-tab-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.direction-tab-bar.hidden {
    display: none;
}

.direction-tab-btn {
    border: 1px solid #d1d5db;
    background: #fff;
    color: #374151;
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 13px;
    cursor: pointer;
}

.direction-tab-btn.active {
    border-color: #2563eb;
    background: #eff6ff;
    color: #1d4ed8;
    font-weight: 600;
}

.category-direction-title {
    font-size: 14px;
    font-weight: 600;
    color: #111827;
}

.category-select-hint {
    font-size: 12px;
    color: #6b7280;
}

.category-select-hint.selected {
    color: #059669;
}

.category-select-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.category-option-card {
    display: block;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 12px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.category-option-card input {
    display: none;
}

.category-option-card.active {
    border-color: #2563eb;
    box-shadow: 0 0 0 1px #2563eb;
    background: #eff6ff;
}

.category-option-title {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #111827;
    margin-bottom: 4px;
}

.category-option-count {
    display: block;
    font-size: 12px;
    color: #6b7280;
}

.category-loading-text,
.category-empty-text {
    grid-column: 1 / -1;
    font-size: 13px;
    color: #6b7280;
    text-align: center;
    padding: 12px 0;
}

.manual-voice-btn.recording {
    background: #dc2626;
    color: #fff;
}

.raw-question-fold {
    margin: 8px 0 12px;
    font-size: 13px;
    color: #6b7280;
}

.raw-question-fold summary {
    cursor: pointer;
    color: #2563eb;
}

.deep-answer-btn {
    margin-top: 10px;
    width: 100%;
}

.voice-bubble {
    position: fixed;
    left: 50%;
    bottom: 88px;
    transform: translateX(-50%);
    max-width: 90%;
    padding: 10px 36px 10px 14px;
    background: #1f2937;
    color: #fff;
    border-radius: 12px;
    font-size: 14px;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.voice-bubble.hidden {
    display: none;
}

.live-main-col.mode-distinguish #dialogueList {
    display: none;
}

.live-main-col.mode-distinguish #dialogueColumns {
    display: flex;
}

.live-main-col.mode-no-distinguish #dialogueColumns {
    display: none;
}

.live-correct-hint.distinguish-only.hidden {
    display: none;
}

.live-layout {
    display: flex;
    gap: 12px;
    margin-top: 12px;
}

.live-main-col {
    flex: 1;
    min-width: 0;
}

.question-history-panel {
    width: 180px;
    flex-shrink: 0;
    border-left: 1px solid #e5e7eb;
    padding-left: 8px;
}

.question-history-panel.expanded {
    width: 50%;
}

.question-history-list {
    max-height: 50vh;
    overflow-y: auto;
}

.history-item {
    display: block;
    width: 100%;
    text-align: left;
    padding: 8px;
    margin-bottom: 6px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #fff;
    font-size: 12px;
    cursor: pointer;
}

.history-item.active {
    border-color: #2563eb;
    background: #eff6ff;
}

.answer-panel {
    margin-bottom: 12px;
    padding: 12px;
    background: #f8fafc;
    border: 1px solid #dbeafe;
    border-radius: 10px;
    max-height: 50vh;
    overflow-y: auto;
}

.answer-tabs {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    margin-bottom: 10px;
}

.answer-tab {
    flex-shrink: 0;
    padding: 6px 10px;
    border: 1px solid #cbd5e1;
    border-radius: 16px;
    background: #fff;
    font-size: 12px;
    cursor: pointer;
}

.answer-tab.active {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}

.answer-point-title,
.answer-point-heading {
    margin: 0 0 8px;
    font-size: 15px;
    font-weight: 600;
    color: #1e293b;
}

.answer-point {
    margin-bottom: 14px;
}

.answer-markdown {
    font-size: 14px;
    line-height: 1.65;
    color: #334155;
    word-break: break-word;
}

.answer-markdown > :first-child {
    margin-top: 0;
}

.answer-markdown > :last-child {
    margin-bottom: 0;
}

.answer-markdown h1,
.answer-markdown h2,
.answer-markdown h3,
.answer-markdown h4,
.answer-markdown h5,
.answer-markdown h6 {
    margin: 12px 0 8px;
    font-weight: 600;
    color: #0f172a;
    line-height: 1.4;
}

.answer-markdown h1 { font-size: 20px; }
.answer-markdown h2 { font-size: 18px; }
.answer-markdown h3 { font-size: 16px; }
.answer-markdown h4 { font-size: 15px; }
.answer-markdown h5 { font-size: 14px; }
.answer-markdown h6 { font-size: 13px; }

.answer-markdown p {
    margin: 8px 0;
}

.answer-markdown strong,
.answer-markdown b {
    font-weight: 700;
    color: #0f172a;
}

.answer-markdown em,
.answer-markdown i {
    font-style: italic;
}

.answer-markdown ul,
.answer-markdown ol {
    margin: 8px 0;
    padding-left: 1.4em;
}

.answer-markdown ul {
    list-style-type: disc;
}

.answer-markdown ol {
    list-style-type: decimal;
}

.answer-markdown li {
    margin: 4px 0;
}

.answer-markdown li > ul,
.answer-markdown li > ol {
    margin-top: 4px;
    margin-bottom: 4px;
}

.answer-markdown code {
    font-family: Consolas, "Courier New", monospace;
    font-size: 12px;
    padding: 2px 5px;
    border-radius: 4px;
    background: #f1f5f9;
    color: #be123c;
}

.answer-markdown pre {
    margin: 10px 0;
    padding: 12px;
    border-radius: 8px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    overflow-x: auto;
}

.answer-markdown pre code {
    display: block;
    padding: 0;
    background: transparent;
    color: inherit;
    font-size: 12px;
    line-height: 1.5;
    white-space: pre;
}

.answer-markdown table {
    width: 100%;
    margin: 10px 0;
    border-collapse: collapse;
    font-size: 13px;
}

.answer-markdown th,
.answer-markdown td {
    border: 1px solid #e2e8f0;
    padding: 8px 10px;
    text-align: left;
    vertical-align: top;
}

.answer-markdown th {
    background: #f1f5f9;
    font-weight: 600;
}

.answer-markdown blockquote {
    margin: 8px 0;
    padding: 8px 12px;
    border-left: 3px solid #93c5fd;
    background: #eff6ff;
    color: #475569;
}

.answer-markdown hr {
    margin: 12px 0;
    border: none;
    border-top: 1px solid #e2e8f0;
}

.answer-markdown a {
    color: #2563eb;
    text-decoration: underline;
}

.answer-markdown .hljs {
    background: transparent;
}

.candidate-answer {
    margin-top: 10px;
    padding: 8px;
    background: #ecfdf5;
    border-radius: 8px;
    font-size: 13px;
}

.bottom-input-bar {
    display: flex;
    gap: 8px;
    align-items: stretch;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0));
    background: #fff;
    border-top: 1px solid #e5e7eb;
    box-shadow: 0 -2px 10px rgba(15, 23, 42, 0.06);
}

.bottom-input-bar.hidden {
    display: none !important;
}

.manual-input-group {
    flex: 4;
    display: flex;
    gap: 8px;
    min-width: 0;
}

.manual-question-input {
    flex: 1;
    min-width: 0;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
}

.manual-submit-btn {
    flex-shrink: 0;
    min-width: 64px;
    padding-left: 12px;
    padding-right: 12px;
}

.manual-voice-btn {
    flex: 1;
    min-width: 0;
}

.voice-script-choice {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 8px 0 10px;
}

.voice-script-option {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    cursor: pointer;
}

.voice-script-text {
    margin: 0 0 12px;
    padding: 10px 12px;
    background: #f9fafb;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.6;
    color: #374151;
}

.voice-bubble {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 90px;
    padding: 12px;
    background: #1f2937;
    color: #fff;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 20;
}

.feedback-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    margin-bottom: 12px;
    resize: vertical;
}

.live-main-col.mode-no-distinguish #dialogueList {
    align-items: flex-start;
}

.live-main-col.mode-no-distinguish .dialogue-item.mixed {
    align-self: flex-start;
    align-items: flex-start;
    max-width: 85%;
}

.live-main-col.mode-no-distinguish .dialogue-item.mixed .dialogue-bubble {
    width: auto;
}

.dialogue-item.mixed .dialogue-bubble {
    background: #f3f4f6;
    color: #111827;
}

@media (max-width: 768px) {
    .question-history-panel {
        position: fixed;
        top: 72px;
        right: 0;
        width: 0;
        overflow: hidden;
        background: #fff;
        z-index: 15;
        border-left: none;
        box-shadow: -2px 0 8px rgba(0,0,0,0.08);
        transition: width 0.2s;
    }
    .question-history-panel.expanded {
        width: 50%;
        padding: 8px;
    }
    .answer-panel {
        max-height: 70vh;
    }
}
