/* Modal overlay */
.adexpert-quiz-modal {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.adexpert-quiz-modal--closed {
    display: none;
}

.adexpert-quiz-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
}

.adexpert-quiz-modal__container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 600px;
    height: calc(100dvh - 48px);
    max-height: 850px;
    overflow: hidden;
    margin: 24px 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 24px;
    border-radius: 30px;
    background: #fff;
}
/* @media (max-width: 769px) {

} */

.adexpert-quiz-modal__close {
    margin-top: 16px;
    padding: 0;
    font-size: 14px;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 50%;
    background: #fff;
    color: #333;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.adexpert-quiz-modal__close:hover {
    background: #e9ecef;
}

/* Form */
.adexpert-quiz {
    width: 100%;
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    font-family: inherit;
    box-sizing: border-box;
}

/* Progress */
.adexpert-quiz__progress {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
}

.adexpert-quiz__progress-bar {
    flex: 1;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.adexpert-quiz__progress-fill {
    height: 100%;
    background: #ffd200;
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0;
}

.adexpert-quiz__progress-fraction {
    font-size: 14px;
    color: #666;
    white-space: nowrap;
    min-width: 40px;
    text-align: right;
}

/* Steps */
.adexpert-quiz__step {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    animation: adexpert-fade-in 0.25s ease;
}

@keyframes adexpert-fade-in {
    from { opacity: 0; transform: translateX(10px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Content */
.adexpert-quiz__content {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    margin-bottom: 24px;
}

.adexpert-quiz__intro-title,
.adexpert-quiz__question-title {
    font-size: 22px;
    line-height: 1.3;
    font-weight: bold;
    margin: 0 0 8px;
    color: #091015;
}
.adexpert-quiz__intro-title {
    font-size: 28px;
}

.adexpert-quiz__intro-text {
    font-size: 18px;
    line-height: 1.4;
    font-weight: normal;
    margin: 0 0 8px;
    color: #091015;
}

.adexpert-quiz__question-text {
    font-size: 16px;
    color: #091015;
    margin: 0 0 16px;
}

.adexpert-quiz__hint-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin: 0 0 12px;
}

.adexpert-quiz__hint-row .adexpert-quiz__selection-hint {
    margin: 0;
}

.adexpert-quiz__select-all {
    font-size: 14px;
    color: #444;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    user-select: none;
    white-space: nowrap;
}

.adexpert-quiz__select-all-input {
    cursor: pointer;
}

.adexpert-quiz__selection-hint {
    font-size: 14px;
    color: #444;
    margin: 0 0 12px;
}

/* Answers */
.adexpert-quiz__answers {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 14px;
}

.adexpert-quiz__answers--row {
    flex-direction: row;
    flex-wrap: wrap;
}

.adexpert-quiz__answer-label {
    display: block;
}

.adexpert-quiz__answer-label input {
    margin: 0;
    display: none;
}

.adexpert-quiz__answer-label-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    line-height: 1.2;
    color: #091015;
    border: 2px solid #D9D9D9;
    border-radius: 30px;
    cursor: pointer;
    user-select: none;
    transition: border-color 0.2s, background 0.2s;
}

.adexpert-quiz__answer-label-btn:hover {
    border-color: #c9c9c9;
}

.adexpert-quiz__answer-label input:checked + .adexpert-quiz__answer-label-btn {
    background: #2F7DFA;
    border-color: #2F7DFA;
    color: #fff;
}

/* Buttons */
.adexpert-quiz__buttons {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: center;
}

.adexpert-quiz__btn {
    padding: 10px 20px;
    font-size: 14px;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-weight: bold;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: opacity 0.2s, background 0.2s;
}

.adexpert-quiz__btn--next,
.adexpert-quiz__btn--submit {
    background: #ffd200;
    color: #0D347A;
}

.adexpert-quiz__btn--next:hover,
.adexpert-quiz__btn--submit:hover {
    background: #e6b800;
}

.adexpert-quiz__btn--skip,
.adexpert-quiz__btn--back {
    background: #e9ecef;
    color: #333;
}

.adexpert-quiz__btn--skip:hover,
.adexpert-quiz__btn--back:hover {
    background: #ddd;
}

.adexpert-quiz__btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Success */
.adexpert-quiz__success-title {
    font-size: 22px;
    line-height: 1.3;
    font-weight: bold;
    margin: 0 0 8px;
    color: #091015;
    text-align: center;
}
.adexpert-quiz__success-text {
    font-size: 18px;
    text-align: center;
    color: #333;
    line-height: 1.5;
}
.adexpert-quiz__success-loader {
    width: 100%;
    margin-top: 12px;
    text-align: center;
    color: #303030;
}

/* Message (fallback for GET status) */
.adexpert-quiz__message {
    margin-bottom: 16px;
    padding: 12px 16px;
    border-radius: 6px;
    background: #f0f8ff;
    border: 1px solid #b8daff;
    color: #004085;
}
