@charset "UTF-8";
/**
 * Test Manage question editor CSS owner. Extracted in P15.177.
 */

/* M10.011B — visual-only question editor outer shell normalization. */
.test-manage-question-editor-page {
    display: grid;
    gap: var(--spacing-md);
    width: 100%;
    max-width: none;
    margin: 0 auto;
}

.test-manage-question-editor-page__header {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: var(--spacing-md);
    align-items: center;
    margin-bottom: 0;
    padding: var(--spacing-md) var(--spacing-lg);
    border: 1px solid color-mix(in srgb, var(--color-border) 88%, var(--color-primary) 12%);
    border-radius: var(--radius-card);
    background:
        linear-gradient(135deg, var(--color-bg-card) 0%, #f8fbff 100%);
    box-shadow: var(--shadow-card);
}

.test-manage-question-editor-page__header > .btn,
.test-manage-question-editor-page__actions .btn,
.test-manage-questions__form-actions .btn {
    min-height: 40px;
    border-radius: var(--radius-input);
    font-weight: var(--font-weight-semibold);
}

.test-manage-question-editor-page__title h5 {
    margin: 0 0 var(--spacing-xs);
    color: var(--color-text-primary);
    font-size: var(--font-size-h3);
    font-weight: var(--font-weight-bold);
    letter-spacing: var(--letter-spacing-tight);
}

.test-manage-question-editor-page__title .text-muted {
    color: var(--color-text-secondary) !important;
    line-height: 1.45;
}

.test-manage-question-editor-page__actions {
    justify-content: flex-end;
    gap: var(--spacing-sm);
}

.test-manage-question-editor {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
    padding: clamp(var(--spacing-md), 2vw, var(--spacing-xl));
    border: 1px solid color-mix(in srgb, var(--color-border) 93%, #ffffff 7%);
    border-radius: var(--radius-card);
    background: var(--color-bg-card);
    box-shadow: var(--shadow-card);
}

.test-manage-question-type-section {
    max-width: min(100%, 560px);
}

.test-manage-questions__form-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-sm);
    margin-top: 0;
    padding-top: var(--spacing-md);
    border-top: 1px solid color-mix(in srgb, var(--color-border) 88%, #ffffff 12%);
}

.test-manage-question-editor__footer-switches {
    display: grid;
    align-items: start;
    justify-items: start;
    gap: var(--spacing-sm);
    color: var(--color-text-primary);
}

.test-manage-question-editor__footer-switches .form-check.form-switch {
    display: grid;
    grid-template-columns: 42px minmax(0, max-content);
    align-items: center;
    column-gap: var(--spacing-xs);
    margin: 0 !important;
    min-height: 32px;
    padding-left: 0 !important;
}

.test-manage-question-editor__footer-switches .form-check.form-switch .form-check-input {
    grid-column: 1;
    flex: 0 0 auto;
    float: none !important;
    margin: 0 !important;
}

.test-manage-question-editor__footer-switches .form-check.form-switch .form-check-label {
    grid-column: 2;
    margin: 0;
    line-height: 1.25;
}

.test-manage-question-editor__footer-actions {
    justify-content: flex-end;
    gap: var(--spacing-sm);
}

@media (max-width: 992px) {
.test-manage-question-editor-page__header {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

.test-manage-question-editor-page__actions,
    .test-manage-questions__form-actions,
    .test-manage-question-editor__footer-actions {
        justify-content: flex-start;
    }
}

@media (max-width: 576px) {
.test-manage-question-editor-page {
        gap: var(--spacing-sm);
    }

.test-manage-question-editor-page__header,
    .test-manage-question-editor {
        padding: var(--spacing-md);
        border-radius: var(--radius-card-sm, 12px);
    }

.test-manage-question-editor-page__header > .btn,
    .test-manage-question-editor-page__actions .btn,
    .test-manage-questions__form-actions .btn {
        width: 100%;
    }

.test-manage-question-editor-page__actions,
    .test-manage-questions__form-actions,
    .test-manage-question-editor__footer-actions {
        align-items: stretch;
        flex-direction: column;
    }

.test-manage-question-editor__footer-switches {
        align-items: flex-start;
        flex-direction: column;
    }
}

.test-manage-question-main-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 260px);
    gap: 16px;
    align-items: start;
}

.test-manage-question-main-grid__text,
.test-manage-question-main-grid__media {
    min-width: 0;
}

.test-manage-media-panel {
    padding: 10px;
    border: 1px solid rgba(148, 163, 184, 0.28);
    border-radius: 12px;
    background: #f8fafc;
}

.test-manage-media-panel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}

.test-manage-media-thumbs {
    display: grid;
    gap: 8px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.test-manage-media-thumb {
    display: grid;
    gap: 6px;
    padding: 8px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 10px;
    background: #ffffff;
}

.test-manage-media-thumb__image {
    display: block;
    width: 100%;
    max-height: 88px;
    border-radius: 10px;
    background: #e2e8f0;
    object-fit: contain;
}

.test-manage-media-thumb__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.test-manage-media-thumb__caption {
    width: 100%;
    min-height: auto;
}

.test-manage-media-thumb__actions .btn {
    padding: 0.2rem 0.45rem;
    font-size: 0.8rem;
}

.test-manage-media-thumbs__empty {
    padding: 12px;
    border: 1px dashed rgba(148, 163, 184, 0.6);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.7);
}

@media (max-width: 992px) {
.test-manage-question-main-grid {
        grid-template-columns: 1fr;
    }
}

.test-manage-explanation-media .ql-editor img,
.test-manage-rich-editor .ql-editor img {
    max-width: 100%;
    max-height: 260px;
    height: auto;
    object-fit: contain;
}

.test-manage-explanation-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 260px);
    gap: 16px;
    align-items: flex-start;
}

.test-manage-explanation-editor-col,
.test-manage-explanation-media-col {
    min-width: 0;
}

@media (max-width: 992px) {
.test-manage-explanation-layout {
        grid-template-columns: 1fr;
    }
}

.test-manage-explanation-media__header {
    align-items: flex-start;
}

.test-manage-explanation-media__thumbs {
    max-height: 280px;
    overflow: auto;
}

.test-manage-explanation-editor-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

body.test-manage-explanation-fullscreen-open {
    overflow: hidden;
}

.test-manage-explanation-media.is-fullscreen {
    position: fixed;
    inset: 24px;
    z-index: 1090;
    display: flex;
    flex-direction: column;
    padding: 18px;
    border: 1px solid rgba(148, 163, 184, 0.38);
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 24px 72px rgba(15, 23, 42, 0.32);
}

.test-manage-explanation-media.is-fullscreen .test-manage-explanation-layout,
.test-manage-explanation-media.is-fullscreen .test-manage-explanation-editor-col {
    min-height: 0;
    flex: 1 1 auto;
}

.test-manage-explanation-media.is-fullscreen .test-manage-explanation-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 260px);
}

.test-manage-explanation-media.is-fullscreen .test-manage-explanation-editor-col {
    display: flex;
    flex-direction: column;
}

.test-manage-explanation-media.is-fullscreen .test-manage-rich-editor {
    display: flex;
    flex: 1 1 auto;
    min-height: 0;
}

.test-manage-explanation-media.is-fullscreen .test-manage-rich-editor .ql-container {
    flex: 1 1 auto;
    min-height: 0;
}

.test-manage-explanation-media.is-fullscreen .test-manage-rich-editor .ql-editor {
    min-height: 0;
    max-height: none;
}

.test-manage-explanation-media.is-fullscreen .test-manage-explanation-media__panel {
    max-height: calc(100vh - 130px);
    overflow: auto;
}

@media (max-width: 768px) {
.test-manage-explanation-media.is-fullscreen {
        inset: 8px;
        padding: 12px;
        border-radius: 14px;
        overflow: auto;
    }

.test-manage-explanation-media.is-fullscreen .test-manage-explanation-layout {
        grid-template-columns: 1fr;
    }
}
