/* 전생 직업 테스트 전용 스타일 (퀴즈형) - 메인 사이트 style.css를 상속받아 덮어씀 */
/* 테마 컬러: #8D6E63 / #FFFFFF */

.custom-theme {
    background-color: #FFFFFF !important;
}

.custom-theme .title-container h1 {
    color: #222;
}

.custom-theme .title-container .subtitle {
    color: #666;
}

/* ===== 이미지 표시: 고정 크기(화면 안) + 비율 유지(contain) ===== */

.main-img-placeholder {
    width: 220px;
    height: 220px;
    margin: 0 auto 35px;
    border-radius: 30px;
    background: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.main-img-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: contain;   /* 잘리지 않고 원본 비율 유지 */
}

/* 결과 타이틀: 진한 색, 크고 굵게 */
.result-title {
    font-size: 1.6rem;
    font-weight: 800;
    color: #222 !important;
}

/* 분석 중 로딩 텍스트 */
.loading-text {
    color: #444 !important;
    font-weight: 700;
    font-size: 1.05rem;
}

/* 결과 설명: 검정 계열 */
.result-desc {
    font-size: 1.05rem;
    line-height: 1.8;
    color: #333;
}

.result-desc p {
    color: #333 !important;
}

/* 추가 코멘트 (extra): 짙은 회색 */
#q-res-extra {
    font-size: 0.95rem;
    color: #555 !important;
}

/* ===== 모바일: 화면 폭 이내로 유지 ===== */
@media (max-width: 480px) {
    .main-img-placeholder {
        width: 200px;
        height: 200px;
    }

    .result-title {
        font-size: 1.35rem;
    }

    .custom-btn {
        padding: 13px 24px;
        font-size: 1rem;
        width: 100%;
        max-width: 300px;
        margin-left: auto;
        margin-right: auto;
        display: block;
    }
}

.custom-btn {
    border-radius: 100px;
    padding: 14px 32px;
    font-size: 1.05rem;
    font-weight: 800;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.custom-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
}

.custom-btn.pulse {
    animation: customPulse 2s infinite;
}

@keyframes customPulse {
    0% { box-shadow: 0 0 0 0 rgba(0, 0, 0, 0.15); }
    70% { box-shadow: 0 0 0 14px rgba(0, 0, 0, 0); }
    100% { box-shadow: 0 0 0 0 rgba(0, 0, 0, 0); }
}

/* 진행 바 */
.quiz-progress {
    max-width: 560px;
    margin: 0 auto 30px;
}

.quiz-progress-text {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--secondary-text);
    margin-bottom: 8px;
    text-align: center;
}

.quiz-progress-bar {
    height: 8px;
    background: #eee;
    border-radius: 100px;
    overflow: hidden;
}

.quiz-progress-fill {
    height: 100%;
    background: #8D6E63;
    border-radius: 100px;
    width: 0%;
    transition: width 0.4s ease;
}

/* 질문 */
.quiz-question-box {
    max-width: 560px;
    margin: 0 auto;
}

.quiz-question-box h2 {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 24px;
    line-height: 1.5;
    letter-spacing: -0.02em;
    text-align: center;
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.quiz-option {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 16px 18px;
    border: 2px solid #eee;
    border-radius: 16px;
    background: #fff;
    font-size: 0.98rem;
    font-weight: 600;
    color: var(--text-main);
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease;
    line-height: 1.4;
}

.quiz-option:hover {
    border-color: #8D6E63;
    background: #8D6E6312;
    transform: translateY(-1px);
}

.quiz-option.selected {
    border-color: #8D6E63;
    background: #8D6E6322;
    box-shadow: 0 4px 14px #8D6E6333;
}

.quiz-option .quiz-option-idx {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #f1f3f5;
    color: #666;
    font-size: 0.85rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
}

.quiz-option.selected .quiz-option-idx {
    background: #8D6E63;
    color: #FFFFFF;
}

.quiz-prev-btn {
    display: block;
    margin: 24px auto 0;
    border-radius: 100px;
    padding: 10px 24px;
    font-weight: 700;
    cursor: pointer;
}

/* 결과 */
.q-result-card {
    max-width: 560px;
    margin: 0 auto;
    border-top: 4px solid;
    border-radius: 20px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
    padding: 24px 20px;
}

.q-result-icon {
    font-size: 4rem;
    text-align: center;
    margin: 10px 0 16px;
}

.q-result-tags {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.q-result-tag {
    padding: 4px 14px;
    border-radius: 100px;
    background: #8D6E63;
    color: #FFFFFF;
    font-size: 0.78rem;
    font-weight: 800;
}

.q-result-extra {
    margin-top: 18px;
    padding: 16px 18px;
    border-radius: 16px;
    font-size: 0.9rem;
    color: var(--text-sub);
    line-height: 1.6;
    text-align: left;
}

#toast {
    position: fixed;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: #222;
    color: #fff;
    padding: 12px 24px;
    border-radius: 100px;
    font-size: 0.9rem;
    font-weight: 600;
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
    z-index: 999;
}

#toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
