.elq-wrapper {
    --elq-bg: #0f172a;
    --elq-panel: #ffffff;
    --elq-text: #111827;
    --elq-muted: #64748b;
    --elq-border: #e5e7eb;
    --elq-primary: #2563eb;
    --elq-primary-dark: #1d4ed8;
    --elq-soft: #eff6ff;
    --elq-success: #16a34a;
    --elq-success-soft: #dcfce7;
    --elq-danger: #dc2626;
    --elq-danger-soft: #fee2e2;
    color: var(--elq-text);
    direction: ltr;
    margin: 24px 0;
    max-width: 100%;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
    -webkit-hyphens: none;
}

.elq-wrapper,
.elq-wrapper button,
.elq-wrapper strong,
.elq-wrapper span,
.elq-wrapper h2,
.elq-wrapper h3,
.elq-wrapper h4,
.elq-wrapper p {
    word-break: normal !important;
    overflow-wrap: normal !important;
    hyphens: none !important;
    -webkit-hyphens: none !important;
}

.elq-wrapper *,
.elq-wrapper *::before,
.elq-wrapper *::after {
    box-sizing: border-box;
}

.quiz-single-summary-card.elq-summary {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, .9fr);
    gap: 16px;
    align-items: stretch;
    padding: 20px;
    margin: 22px 0;
    border-radius: 10px;
    background: linear-gradient(135deg, #0f172a 0%, #111827 55%, #172554 100%);
    color: #fff;
    box-shadow: 0 16px 40px rgba(15, 23, 42, .18);
}

.elq-summary-main h2,
.elq-topbar h3,
.elq-question-area h4 {
    margin: 0;
    line-height: 1.25;
}

.elq-summary-main p,
.elq-topbar p {
    margin: 8px 0 0;
    color: #dbeafe;
    line-height: 1.55;
}

.elq-kicker {
    display: inline-flex;
    align-items: center;
    margin-bottom: 8px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #93c5fd;
}

.elq-summary-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 128px), 1fr));
    gap: 10px;
}

.elq-summary-stats div {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 86px;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 8px;
    background: rgba(255, 255, 255, .08);
    text-align: center;
}

.elq-summary-stats strong {
    display: block;
    font-size: clamp(18px, 1.8vw, 22px);
    line-height: 1.2;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
    -webkit-hyphens: none;
}

.elq-summary-stats span {
    margin-top: 4px;
    font-size: 13px;
    color: #bfdbfe;
}

.elq-level-switch {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 172px), 1fr));
    gap: 8px;
}

.elq-summary-switch {
    grid-column: 1 / -1;
}

.elq-level-switch button {
    width: 100%;
    min-height: 38px;
    padding: 9px 14px;
    border: 1px solid var(--elq-border);
    border-radius: 999px;
    background: #fff;
    color: #1f2937;
    font-weight: 800;
    line-height: 1.25;
    white-space: nowrap;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
    -webkit-hyphens: none;
    cursor: pointer;
    transition: background .18s ease, border-color .18s ease, color .18s ease, transform .18s ease;
}

.elq-summary .elq-level-switch button {
    border-color: rgba(255, 255, 255, .16);
    background: rgba(255, 255, 255, .1);
    color: #fff;
}

.elq-level-switch button:hover,
.elq-level-switch button.is-active {
    border-color: var(--elq-primary);
    background: var(--elq-primary);
    color: #fff;
    transform: translateY(-1px);
}

.quiz-entry-supplement.elq-quiz-card {
    padding: 22px;
    border: 1px solid var(--elq-border);
    border-radius: 10px;
    background: var(--elq-panel);
    box-shadow: 0 10px 28px rgba(15, 23, 42, .08);
    overflow: visible;
}

.elq-topbar {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
    margin-bottom: 16px;
}

.elq-topbar p {
    color: var(--elq-muted);
}

.elq-score-pill {
    flex: 0 0 auto;
    padding: 8px 12px;
    border-radius: 999px;
    background: var(--elq-soft);
    color: var(--elq-primary-dark);
    font-weight: 900;
}

.elq-quiz-switch {
    margin: 12px 0 16px;
}

.elq-progress-track {
    height: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #e5e7eb;
}

.elq-progress-track span {
    display: block;
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #38bdf8, var(--elq-primary));
    transition: width .2s ease;
}

.elq-question-area {
    margin-top: 18px;
}

.elq-question-number {
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 800;
    color: var(--elq-primary);
}

.elq-question-area h4 {
    font-size: 20px;
}

.elq-options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 16px;
}

.elq-option {
    width: 100%;
    min-height: 50px;
    padding: 13px 14px;
    border: 1px solid #dbe1ea;
    border-radius: 8px;
    background: #f8fafc;
    color: #111827;
    direction: ltr;
    text-align: left;
    line-height: 1.4;
    white-space: normal;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
    -webkit-hyphens: none;
    cursor: pointer;
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.elq-selector-option {
    direction: ltr;
    text-align: center;
    font-weight: 900;
}

.elq-option:hover,
.elq-option.is-selected {
    border-color: var(--elq-primary);
    background: var(--elq-soft);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}

.elq-option:disabled {
    cursor: default;
    opacity: 1;
}

.elq-option.is-correct {
    border-color: var(--elq-success);
    background: var(--elq-success-soft);
    color: #14532d;
    box-shadow: 0 0 0 3px rgba(22, 163, 74, .13);
}

.elq-option.is-wrong {
    border-color: var(--elq-danger);
    background: var(--elq-danger-soft);
    color: #7f1d1d;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, .12);
}

.elq-feedback {
    margin-top: 14px;
    padding: 11px 13px;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.5;
}

.elq-feedback span {
    font-weight: 800;
}

.elq-feedback.is-correct {
    border: 1px solid #86efac;
    background: #f0fdf4;
    color: #14532d;
}

.elq-feedback.is-wrong {
    border: 1px solid #fecaca;
    background: #fef2f2;
    color: #7f1d1d;
}

.elq-actions {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 18px;
}

.elq-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 18px;
    border: 0;
    border-radius: 8px;
    background: var(--elq-primary);
    color: #fff;
    font-weight: 900;
    cursor: pointer;
    transition: background .18s ease, opacity .18s ease;
}

.elq-btn:hover {
    background: var(--elq-primary-dark);
}

.elq-btn:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.elq-btn-muted {
    background: #e5e7eb;
    color: #111827;
}

.elq-btn-muted:hover {
    background: #d1d5db;
}

.elq-result {
    margin-top: 20px;
    padding: 18px;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    background: #f0fdf4;
}

.elq-result h4 {
    margin: 0 0 8px;
    font-size: 22px;
}

.elq-result p {
    margin: 8px 0;
}

.elq-result-score {
    display: inline-flex;
    margin-bottom: 8px;
    padding: 6px 10px;
    border-radius: 999px;
    background: #dcfce7;
    color: #166534;
    font-weight: 900;
}

.elq-recommendation {
    margin: 14px 0;
    padding: 14px;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    background: #eff6ff;
    color: #1e3a8a;
}

.elq-recommendation span {
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #2563eb;
}

.elq-recommendation strong {
    display: block;
    font-size: 18px;
    line-height: 1.25;
}

.elq-recommendation p {
    margin: 7px 0 0;
}

.elq-recommendation button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    margin-top: 10px;
    padding: 9px 13px;
    border: 1px solid var(--elq-primary);
    border-radius: 8px;
    background: var(--elq-primary);
    color: #fff;
    font-weight: 900;
    cursor: pointer;
}

.elq-result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.elq-mistakes {
    margin-top: 16px;
    padding: 14px;
    border: 1px solid #fde68a;
    border-radius: 8px;
    background: #fffbeb;
}

.elq-mistakes h5 {
    margin: 0 0 10px;
    font-size: 16px;
}

.elq-mistakes ol {
    display: grid;
    gap: 10px;
    margin: 0;
    padding-left: 22px;
    padding-right: 0;
}

.elq-mistakes li {
    padding-left: 4px;
}

.elq-mistakes span {
    display: block;
    margin-top: 4px;
}

.elq-mistakes-clean {
    border-color: #bbf7d0;
    background: #f0fdf4;
}

.elq-result-actions a,
.elq-result-actions button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 9px 13px;
    border: 1px solid var(--elq-primary);
    border-radius: 8px;
    background: #fff;
    color: var(--elq-primary-dark);
    font-weight: 900;
    text-decoration: none;
    cursor: pointer;
}

@media (max-width: 700px) {
    .quiz-single-summary-card.elq-summary,
    .elq-topbar {
        display: block;
    }

    .quiz-single-summary-card.elq-summary {
        padding: 13px;
        margin: 16px 0;
        border-radius: 8px;
    }

    .elq-summary-main h2 {
        font-size: 20px;
    }

    .elq-summary-main p {
        margin-top: 6px;
        font-size: 13px;
        line-height: 1.45;
    }

    .elq-kicker {
        margin-bottom: 6px;
        font-size: 10px;
    }

    .elq-summary-stats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 6px;
        margin-top: 10px;
    }

    .elq-summary-stats div {
        min-height: 54px;
        padding: 7px 5px;
        border-radius: 7px;
    }

    .elq-summary-stats strong {
        font-size: 15px;
        line-height: 1.15;
    }

    .elq-summary-stats span {
        margin-top: 2px;
        font-size: 10px;
    }

    .elq-level-switch {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
    }

    .elq-options {
        grid-template-columns: 1fr;
    }

    .elq-summary-switch,
    .elq-quiz-switch {
        margin-top: 10px;
    }

    .elq-level-switch button {
        min-height: 34px;
        padding: 7px 8px;
        font-size: 12px;
    }

    .elq-score-pill {
        display: inline-flex;
        margin-top: 12px;
    }
}

@media (min-width: 701px) and (max-width: 980px) {
    .quiz-single-summary-card.elq-summary {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .quiz-entry-supplement.elq-quiz-card {
        padding: 16px;
    }

    .elq-summary-stats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .elq-actions {
        flex-direction: column;
    }

    .elq-btn {
        width: 100%;
    }
}
