.guide-quiz {
    max-width: 1040px;
    margin: 32px auto 42px;
    padding: 0 18px;
    font-family: "Noto Sans TC", "Microsoft JhengHei", sans-serif;
}

.guide-quiz__intro,
.guide-quiz__panel,
.guide-thinking,
.guide-result__inner {
    background: #fff;
    border: 1px solid #eadfce;
    border-radius: 22px;
    box-shadow: 0 18px 48px rgba(90, 64, 38, .12);
    padding: 34px;
    box-sizing: border-box;
}

.guide-quiz__intro {
    background:
        radial-gradient(circle at top left, rgba(206, 168, 102, .22), transparent 34%),
        linear-gradient(135deg, #fffaf2, #ffffff);
}

.guide-quiz__eyebrow,
.guide-result__eyebrow {
    margin: 0 0 8px;
    color: #9a6a28;
    font-size: 15px;
    letter-spacing: .08em;
    font-weight: 700;
}

.guide-quiz h1,
.guide-question h2,
.guide-thinking h2,
.guide-result h2 {
    margin: 0 0 14px;
    color: #332414;
    line-height: 1.35;
}

.guide-quiz__intro p,
.guide-thinking p,
.guide-result p {
    color: #5d5042;
    line-height: 1.9;
    font-size: 16px;
}

.guide-quiz__actions,
.guide-question__footer,
.guide-result__actions {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    align-items: center;
    margin-top: 24px;
}

.guide-quiz__primary-btn,
.guide-quiz__secondary-btn,
.guide-option,
.guide-result-card__link {
    border: 0;
    cursor: pointer;
    text-decoration: none;
    font-family: inherit;
}

.guide-quiz__primary-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 24px;
    border-radius: 999px;
    background: #8b5a20;
    color: #fff;
    font-weight: 700;
    font-size: 16px;
}

.guide-quiz__primary-btn:hover {
    background: #704717;
}

.guide-quiz__secondary-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 22px;
    border-radius: 999px;
    background: #f4eadc;
    color: #6e4a1e;
    font-weight: 700;
    font-size: 15px;
}

.guide-quiz__secondary-link {
    color: #8b5a20;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 4px;
}

.guide-question__progress {
    display: inline-flex;
    padding: 5px 12px;
    margin-bottom: 14px;
    border-radius: 999px;
    background: #f5edde;
    color: #815a24;
    font-size: 14px;
    font-weight: 700;
}

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

.guide-option {
    min-height: 64px;
    padding: 16px 18px;
    border-radius: 16px;
    border: 1px solid #e5d6bf;
    background: #fffdf9;
    color: #3d2f20;
    font-size: 16px;
    line-height: 1.55;
    text-align: left;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.guide-option:hover {
    transform: translateY(-2px);
    border-color: #c79345;
    box-shadow: 0 12px 28px rgba(104, 72, 30, .13);
}

.guide-question__textarea {
    width: 100%;
    min-height: 140px;
    margin-top: 18px;
    padding: 16px;
    border-radius: 16px;
    border: 1px solid #dfcfb9;
    font-size: 16px;
    line-height: 1.8;
    box-sizing: border-box;
    resize: vertical;
}

.guide-thinking {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity .45s ease, transform .45s ease;
}

.guide-thinking.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.guide-thinking ul {
    list-style: none;
    padding: 0;
    margin: 22px 0 0;
}

.guide-thinking li {
    position: relative;
    padding: 10px 0 10px 34px;
    color: #7d7164;
    opacity: .42;
    transform: translateY(6px);
    transition: opacity .4s ease, transform .4s ease, color .4s ease;
}

.guide-thinking li::before {
    content: "○";
    position: absolute;
    left: 0;
    top: 10px;
    color: #b89456;
}

.guide-thinking li.is-done {
    opacity: 1;
    transform: translateY(0);
    color: #3d2f20;
}

.guide-thinking li.is-done::before {
    content: "✓";
    color: #8b5a20;
    font-weight: 700;
}

.guide-result {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity .6s ease, transform .6s ease;
}

.guide-result.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.guide-result__expectation {
    margin: 20px 0;
    padding: 16px 18px;
    border-left: 4px solid #b8863b;
    background: #fff9ef;
    border-radius: 12px;
}

.guide-result__expectation p {
    margin: 6px 0 0;
}

.guide-result__cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-top: 22px;
}

.guide-result-card {
    opacity: 0;
    transform: translateY(18px);
    padding: 20px;
    border: 1px solid #e6d8c2;
    border-radius: 18px;
    background: #fffdf9;
    transition: opacity .55s ease, transform .55s ease, box-shadow .25s ease;
}

.guide-result-card.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.guide-result-card:hover {
    box-shadow: 0 12px 32px rgba(96, 64, 24, .12);
}

.guide-result-card__rank {
    display: inline-flex;
    margin-bottom: 10px;
    padding: 4px 10px;
    border-radius: 999px;
    background: #f0e2cc;
    color: #81561f;
    font-size: 13px;
    font-weight: 700;
}

.guide-result-card h3 {
    margin: 0 0 8px;
    color: #332414;
    font-size: 21px;
}

.guide-result-card__label {
    margin: 0 0 8px;
    color: #8b5a20 !important;
    font-weight: 700;
}

.guide-result-card__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    margin-top: 12px;
    padding: 0 18px;
    border-radius: 999px;
    background: #8b5a20;
    color: #fff;
    font-weight: 700;
}

.guide-result-card__link:hover {
    background: #704717;
    color: #fff;
}

@media (max-width: 768px) {
    .guide-quiz {
        margin: 20px auto 32px;
        padding: 0 12px;
    }

    .guide-quiz__intro,
    .guide-quiz__panel,
    .guide-thinking,
    .guide-result__inner {
        padding: 24px 18px;
        border-radius: 18px;
    }

    .guide-options,
    .guide-result__cards {
        grid-template-columns: 1fr;
    }

    .guide-option {
        min-height: auto;
    }

    .guide-quiz__actions,
    .guide-question__footer,
    .guide-result__actions {
        flex-direction: column;
        align-items: stretch;
    }

    .guide-quiz__primary-btn,
    .guide-quiz__secondary-btn,
    .guide-result-card__link {
        width: 100%;
        box-sizing: border-box;
    }
}

.guide-quiz__history {
    margin-bottom: 18px;
}

.guide-history__box {
    padding: 24px 26px;
    border-radius: 20px;
    border: 1px solid #e5d6bf;
    background: linear-gradient(135deg, #fffdf8, #f8efe1);
    box-shadow: 0 12px 30px rgba(90, 64, 38, .09);
}

.guide-history__meta {
    margin-bottom: 6px;
    color: #9a6a28;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .06em;
}

.guide-history__box h2 {
    margin: 0 0 12px;
    color: #332414;
    line-height: 1.35;
}

.guide-history__expectation {
    margin: 0 0 16px;
    color: #5d5042;
    font-size: 16px;
    line-height: 1.9;
}

.guide-history__services {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin: 12px 0 18px;
    color: #6b5540;
}

.guide-history__service {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 0 12px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid #dec8aa;
    color: #7b4f1c;
    font-weight: 700;
    text-decoration: none;
}

.guide-history__service:hover {
    color: #fff;
    background: #8b5a20;
    border-color: #8b5a20;
}

.guide-history__actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 16px;
}

.guide-history__note {
    margin: 12px 0 0;
    color: #88776a;
    font-size: 13px;
}

@media (max-width: 768px) {
    .guide-history__box {
        padding: 22px 18px;
    }

    .guide-history__actions {
        flex-direction: column;
        align-items: stretch;
    }
}

.guide-quiz--home {
    margin-top: 0;
    margin-bottom: 34px;
}

.guide-quiz--home .guide-quiz__intro {
    padding-top: 30px;
    padding-bottom: 30px;
}

@media (max-width: 768px) {
    .guide-quiz--home {
        margin-top: 0;
        margin-bottom: 26px;
    }
}

/* Homepage guide quiz tuning */
.guide-quiz--home {
    max-width: 1180px;
}

.guide-result-card {
    display: flex;
    flex-direction: column;
}

.guide-result-card__link {
    margin-top: auto;
    align-self: flex-start;
}

.guide-result-card__label {
    min-height: 3.2em;
}

/* Mobile history layout tuning */
@media (max-width: 768px) {
    .guide-history__services {
        display: block;
    }

    .guide-history__services > span {
        display: block;
        margin-bottom: 10px;
    }

    .guide-history__service {
        margin: 0 8px 10px 0;
        min-height: 34px;
    }

    .guide-history__actions {
        gap: 10px;
    }

    .guide-history__actions .guide-quiz__secondary-btn,
    .guide-history__actions .guide-quiz__primary-btn {
        width: 100%;
        justify-content: center;
    }

    .guide-quiz--home .guide-quiz__intro p {
        line-height: 1.9;
    }
}

@media (max-width: 768px) {
    .guide-quiz__actions {
        margin-top: 22px;
    }

    .guide-quiz--home .guide-quiz__primary-btn {
        min-height: 54px;
        font-size: 17px;
    }
}

/* History archive action */
.guide-history__actions {
    gap: 10px;
}

.guide-history__actions .guide-quiz__secondary-btn {
    background: #f6efe5;
}

@media (max-width: 768px) {
    .guide-history__actions .guide-quiz__secondary-btn,
    .guide-history__actions .guide-quiz__primary-btn {
        width: 100%;
        margin-bottom: 0;
    }
}

.guide-quiz__version {
    display: inline-flex;
    margin: 0 0 10px;
    padding: 4px 10px;
    border-radius: 999px;
    background: #f4ead9;
    color: #8b5a20;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .03em;
}

@media (max-width: 768px) {
    .guide-quiz__version {
        margin-left: 2px;
        font-size: 11px;
    }
}

/* Guide quiz version note */
.guide-quiz {
    position: relative;
}

.guide-quiz__version {
    position: absolute;
    right: 24px;
    bottom: 18px;
    margin: 0;
    opacity: .72;
    transform: scale(.92);
    transform-origin: right bottom;
}

@media (max-width: 768px) {
    .guide-quiz__version {
        position: static;
        display: inline-flex;
        margin: 14px 0 0;
        opacity: .68;
        transform: none;
    }
}

@media (max-width: 768px) {
    .guide-quiz__version {
        display: flex;
        width: fit-content;
        margin: 10px 0 0 auto;
        opacity: .62;
    }
}

/* Guide quiz blessing message */
.guide-blessing {
    margin: 0 0 28px;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity .45s ease, transform .45s ease;
}

.guide-blessing.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.guide-blessing__label {
    margin-bottom: 8px;
    color: #9a6424;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: .08em;
}

.guide-blessing__text {
    min-height: 1.8em;
    color: #38271a;
    font-size: 28px;
    font-weight: 900;
    line-height: 1.7;
    letter-spacing: .03em;
}

.guide-blessing__sign {
    display: none;
}

@media (max-width: 768px) {
    .guide-blessing {
        margin: 0 0 24px;
    }

    .guide-blessing__text {
        font-size: 23px;
        line-height: 1.7;
    }
}

/* Blessing message tone tuning */
.guide-blessing {
    text-align: center;
}

.guide-blessing__label {
    text-align: center;
}

.guide-blessing__text {
    text-align: center;
}

.guide-blessing--green .guide-blessing__text {
    color: #2f7d5b;
}

.guide-blessing--sky .guide-blessing__text {
    color: #2f79a8;
}

.guide-blessing--pink .guide-blessing__text {
    color: #c45d83;
}

.guide-blessing--violet .guide-blessing__text {
    color: #7b5aa6;
}

.guide-blessing--gold .guide-blessing__text {
    color: #9a6424;
}

.guide-blessing--green .guide-blessing__label {
    color: #4f8b69;
}

.guide-blessing--sky .guide-blessing__label {
    color: #4f8fb6;
}

.guide-blessing--pink .guide-blessing__label {
    color: #bf6f8b;
}

.guide-blessing--violet .guide-blessing__label {
    color: #8065a8;
}

.guide-blessing--gold .guide-blessing__label {
    color: #9a6424;
}

/* Blessing soft reveal animation */
.guide-blessing__text {
    opacity: 0;
    filter: blur(8px);
    transform: translateY(10px);
    transition:
        opacity 1.25s ease,
        filter 1.35s ease,
        transform 1.25s ease;
}

.guide-blessing.is-visible .guide-blessing__text {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0);
}

.guide-blessing__label {
    opacity: 0;
    transform: translateY(6px);
    transition:
        opacity .9s ease,
        transform .9s ease;
}

.guide-blessing.is-visible .guide-blessing__label {
    opacity: .9;
    transform: translateY(0);
}
