/* =========================================================
   Lunar Soopoolleaf — 무엇이 궁금하세요? (타로 메뉴)
   ========================================================= */

.tarot-ask {
    width: min(100%, 860px);
    margin: 0 auto 14px;
    padding: 14px 16px 12px;
    border: 1px solid var(--border);
    border-radius: 18px;
    background: var(--surface);
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tarot-ask-copy {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.tarot-ask-title {
    font-size: 15px;
    font-weight: 800;
    letter-spacing: -.3px;
}

.tarot-ask-sub {
    font-size: 12px;
    line-height: 1.6;
    color: var(--text-soft);
    word-break: keep-all;
}

.tarot-ask-chips {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.tarot-ask-chips::-webkit-scrollbar {
    display: none;
}

.tarot-ask-chip {
    flex: 0 0 auto;
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--surface-hover, transparent);
    color: var(--text);
    font: inherit;
    font-size: 12.5px;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
    transition: border-color .16s ease, background-color .16s ease, color .16s ease, transform .12s ease;
}

.tarot-ask-chip:hover {
    transform: translateY(-1px);
}

.tarot-ask-chip.is-on {
    border-color: var(--tarot-accent-border, rgba(82, 183, 136, .6));
    background: var(--tarot-accent-soft, rgba(82, 183, 136, .12));
    color: var(--tarot-accent-strong, var(--primary));
}

.tarot-ask-result {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px 8px;
    padding-top: 8px;
    border-top: 1px dashed var(--border);
}

.tarot-ask-result[hidden] {
    display: none;
}

.tarot-ask-label {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .06em;
    color: var(--tarot-accent-strong, var(--primary));
    margin-right: 2px;
}

.tarot-ask-spreads {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tarot-ask-spread {
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--surface);
    color: var(--text);
    font-size: 12.5px;
    font-weight: 700;
    text-decoration: none;
    transition: transform .12s ease, border-color .16s ease;
}

.tarot-ask-spread:hover {
    transform: translateY(-1px);
    border-color: var(--tarot-accent-border, rgba(82, 183, 136, .6));
}

.tarot-ask-spread.is-first {
    border-color: var(--tarot-accent-border, rgba(82, 183, 136, .6));
    background: var(--tarot-accent-soft, rgba(82, 183, 136, .12));
    color: var(--tarot-accent-strong, var(--primary));
}


/* ---------- 메뉴 항목의 추천 표시 ---------- */

.tarot-item.is-recommended {
    position: relative;
    outline: 2px solid var(--tarot-accent-border, rgba(82, 183, 136, .6));
    outline-offset: -2px;
}

.tarot-ask-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 3;
    padding: 3px 8px;
    border-radius: 999px;
    background: var(--tarot-accent, var(--primary));
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .04em;
    pointer-events: none;
}

@media (max-width: 640px) {
    .tarot-ask {
        padding: 12px 12px 10px;
        border-radius: 16px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .tarot-ask-chip, .tarot-ask-spread {
        transition: none;
    }
}


/* 궁금한 것의 종류 (상대 마음 · 둘 중 하나 …) — v2 */
.tarot-ask-kind { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); }
.tarot-ask-kind .tarot-ask-label { display: block; margin-bottom: 6px; }
.tarot-ask-chip.is-kind { border-style: dashed; }
.tarot-ask-chip.is-kind.is-on { border-style: solid; }
.tarot-ask-why { margin: 0 0 6px; font-size: 12px; line-height: 1.6; color: var(--text-soft); word-break: keep-all; }
.tarot-ask-why[hidden] { display: none; }


/* =========================================================
   세 장으로 바로 보기 — 간단 운세 · 문제 해결 · Yes or No?  (v3)
   가로 3칸 (각 33%)
   ========================================================= */

.tarot-three { margin: 12px 0 0; }
.tarot-three-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: 0 2px 8px; }
.tarot-three-title { font-size: 15px; font-weight: 900; letter-spacing: -.02em; color: var(--text); }
.tarot-three-sub { font-size: 11.5px; color: var(--text-soft); line-height: 1.5; word-break: keep-all; }

.tarot-three-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }

.tarot-three-box {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    min-width: 0;
    padding: 12px 11px 11px;
    border: 1px solid var(--border);
    border-radius: 18px;
    background: var(--surface);
    color: var(--text);
    text-decoration: none;
    box-shadow: 0 6px 18px rgba(20, 31, 25, .05);
    transition: transform .16s ease, border-color .16s ease;
}
.tarot-three-box:hover { transform: translateY(-2px); border-color: var(--tarot-accent, #52b788); }

.tarot-three-cards { display: flex; gap: 3px; margin-bottom: 2px; }
.tarot-three-cards i {
    display: inline-grid;
    place-items: center;
    width: 17px;
    height: 26px;
    border-radius: 4px;
    font-style: normal;
    font-size: 9.5px;
    font-weight: 900;
    color: #fff;
    background: var(--tarot-accent, #52b788);
}
.tarot-three-box.is-solve .tarot-three-cards i { background: #8a7bb8; }
.tarot-three-box.is-yesno .tarot-three-cards i:nth-child(1) { background: #3f9d6b; }
.tarot-three-box.is-yesno .tarot-three-cards i:nth-child(2) { background: #c9a14a; }
.tarot-three-box.is-yesno .tarot-three-cards i:nth-child(3) { background: #c0564b; }

.tarot-three-name { font-size: 13.5px; font-weight: 900; line-height: 1.3; letter-spacing: -.02em; word-break: keep-all; }
.tarot-three-desc { font-size: 11px; line-height: 1.5; color: var(--text-soft); word-break: keep-all; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.tarot-three-go { margin-top: auto; padding-top: 2px; font-size: 11px; font-weight: 800; color: var(--tarot-accent-strong, #2f7a55); }
html[data-theme="dark"] .tarot-three-go { color: var(--tarot-accent, #7fd4a8); }

@media (max-width: 420px) {
    .tarot-three-grid { gap: 6px; }
    .tarot-three-box { padding: 10px 8px 9px; border-radius: 14px; }
    .tarot-three-name { font-size: 12.5px; }
    .tarot-three-desc { font-size: 10.5px; -webkit-line-clamp: 4; }
}

/* 양자택일 / n개 택일 — 선택지 수 고르기 (메뉴의 동그라미) */
.tarot-variant-chooser.is-options { flex-wrap: wrap; row-gap: 6px; }
.tarot-variant-ask { flex-basis: 100%; text-align: center; font-size: 11.5px; font-weight: 800; color: var(--text-soft); line-height: 1.3; }

/* 가볍게 한 장 · 일상 타로 — 메뉴의 네 칸 */
.tarot-life-quick { margin: 14px 0 0; }
.tarot-life-quick .tarot-three-title { text-decoration: none; }
.tarot-life-quick .tarot-three-title::after { content: " →"; color: var(--tarot-accent-strong, #2f7a55); }
.tarot-life-quick-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.tarot-life-quick-tile {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    padding: 11px 10px;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: var(--surface);
    color: var(--text);
    text-decoration: none;
    box-shadow: 0 6px 18px rgba(20, 31, 25, .05);
    transition: transform .16s ease, border-color .16s ease;
}
.tarot-life-quick-tile:hover { transform: translateY(-2px); border-color: var(--tarot-accent, #52b788); }
.tarot-life-quick-icon {
    flex: 0 0 auto;
    display: inline-grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 11px;
    font-size: 17px;
    background: rgba(82, 183, 136, .14);
}
.tarot-life-quick-tile.is-outfit .tarot-life-quick-icon { background: rgba(138, 123, 184, .16); }
.tarot-life-quick-tile.is-contact .tarot-life-quick-icon { background: rgba(201, 161, 74, .18); }
.tarot-life-quick-tile.is-buy .tarot-life-quick-icon { background: rgba(192, 86, 75, .14); }
.tarot-life-quick-tile b { min-width: 0; font-size: 12.5px; font-weight: 900; line-height: 1.3; letter-spacing: -.02em; word-break: keep-all; }
@media (max-width: 560px) {
    .tarot-life-quick-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
}

/* 오늘의 카드 아래 → 일상 타로 링크 */
.tarot-daily-life-link {
    display: inline-block;
    margin-top: 10px;
    font-size: 12.5px;
    font-weight: 800;
    color: inherit;
    opacity: .85;
    text-decoration: underline;
    text-underline-offset: 3px;
}
.tarot-daily-life-link:hover { opacity: 1; }

/* 덱 고르기 — 메이저 22장만 · 읽기 설정 안에서 질문 칸처럼 한 줄 전체 (상자 모양은 .tarot-reading-option) */
.tarot-deck-option { grid-column: 1 / -1; }
.tarot-deck-field { flex: 0 1 62%; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.tarot-deck-option-copy { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tarot-deck-option-kicker { font-size: 10.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--text-soft); }
.tarot-deck-option-title { font-size: 13.5px; font-weight: 900; letter-spacing: -.02em; word-break: keep-all; }
.tarot-deck-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    padding: 9px 12px;
    border: 1.5px solid var(--border);
    border-radius: 14px;
    background: transparent;
    color: var(--text);
    font: inherit;
    text-align: left;
    cursor: pointer;
    transition: border-color .16s ease, background-color .16s ease;
}
.tarot-deck-toggle:hover { border-color: var(--tarot-accent, #52b788); }
.tarot-deck-toggle-box {
    flex: 0 0 auto;
    display: inline-grid;
    place-items: center;
    width: 22px;
    height: 22px;
    border: 1.5px solid var(--border);
    border-radius: 7px;
    background: var(--surface);
}
.tarot-deck-toggle-box svg { width: 14px; height: 14px; fill: none; stroke: #fff; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; opacity: 0; }
.tarot-deck-toggle-copy { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.tarot-deck-toggle-copy strong { font-size: 13px; font-weight: 900; word-break: keep-all; }
.tarot-deck-toggle-copy small { font-size: 11px; color: var(--text-soft); word-break: keep-all; }
.tarot-deck-toggle-cards { flex: 0 0 auto; display: flex; gap: 3px; }
.tarot-deck-toggle-cards i {
    display: inline-grid;
    place-items: center;
    width: 20px;
    height: 30px;
    border-radius: 4px;
    background: linear-gradient(145deg, #1f2d44, #2c2241);
    color: rgba(230, 211, 153, .9);
    font-family: Georgia, 'Times New Roman', serif;
    font-style: normal;
    font-size: 8.5px;
    font-weight: 700;
    opacity: .45;
    transition: opacity .16s ease;
}
.tarot-deck-option-note {
    margin: 0;
    font-size: 11.5px;
    line-height: 1.5;
    color: var(--tarot-accent-strong, #2f7a55);
    word-break: keep-all;
}
.tarot-deck-option-note[hidden] { display: none; }
.tarot-deck-option.is-on .tarot-deck-toggle { border-color: var(--tarot-accent, #52b788); background: var(--tarot-accent-soft, rgba(82, 183, 136, .1)); }
.tarot-deck-option.is-on .tarot-deck-toggle-box { border-color: var(--tarot-accent, #52b788); background: var(--tarot-accent, #52b788); }
.tarot-deck-option.is-on .tarot-deck-toggle-box svg { opacity: 1; }
.tarot-deck-option.is-on .tarot-deck-toggle-cards i { opacity: 1; }
html[data-theme="dark"] .tarot-deck-option-note { color: var(--tarot-accent, #7fd4a8); }
@media (max-width: 640px) {
    .tarot-deck-option { flex-direction: column; align-items: stretch; }
    .tarot-deck-field { flex-basis: auto; }
}
/* 읽기 설정 안의 다른 상자(역방향)와 글자 크기 맞춤 */
.tarot-reading-options .tarot-deck-toggle { padding: 8px 12px; border-radius: 14px; }
.tarot-reading-options .tarot-deck-toggle-copy strong { font-size: 11.5px; font-weight: 800; line-height: 1.3; }
.tarot-reading-options .tarot-deck-toggle-copy small { font-size: 9px; font-weight: 600; line-height: 1.35; }
.tarot-reading-options .tarot-deck-toggle-cards i { width: 18px; height: 27px; font-size: 8px; }

/* 덱 고르기 — 세 갈래 (전체 · 메이저 · 코트) */
.tarot-deck-segment {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    padding: 4px;
    border-radius: 15px;
    background: color-mix(in srgb, var(--surface-hover, rgba(0, 0, 0, .04)) 72%, transparent);
}
.tarot-deck-choice {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-width: 0;
    padding: 8px 6px;
    border: 1.5px solid transparent;
    border-radius: 12px;
    background: transparent;
    color: var(--text-soft);
    font: inherit;
    cursor: pointer;
    transition: border-color .16s ease, background-color .16s ease, color .16s ease;
}
.tarot-deck-choice strong { font-size: 11.5px; font-weight: 800; line-height: 1.25; word-break: keep-all; }
.tarot-deck-choice .tarot-deck-toggle-cards i { width: 13px; height: 20px; font-size: 6.5px; border-radius: 3px; opacity: .55; }
.tarot-deck-choice.is-court .tarot-deck-toggle-cards i { background: linear-gradient(145deg, #4a3a1f, #2c2241); }
.tarot-deck-choice:hover { color: var(--text); }
.tarot-deck-choice.is-selected {
    border-color: var(--tarot-accent, #52b788);
    background: var(--surface);
    color: var(--text);
    box-shadow: 0 4px 12px rgba(20, 31, 25, .08);
}
.tarot-deck-choice.is-selected .tarot-deck-toggle-cards i { opacity: 1; }
.tarot-deck-links { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 4px; }
.tarot-deck-links a { font-weight: 800; color: var(--tarot-accent-strong, #2f7a55); text-decoration: underline; text-underline-offset: 3px; }
html[data-theme="dark"] .tarot-deck-links a { color: var(--tarot-accent, #7fd4a8); }
@media (max-width: 420px) {
    .tarot-deck-choice { flex-direction: column; gap: 4px; padding: 7px 4px; }
    .tarot-deck-choice strong { font-size: 11px; text-align: center; }
}

/* 수트 하나 — 네 수트 고르기 */
.tarot-deck-choice.is-suit .tarot-deck-toggle-cards i:nth-child(1) { background: #c6a25d; color: #fff; }
.tarot-deck-choice.is-suit .tarot-deck-toggle-cards i:nth-child(2) { background: #668fd0; color: #fff; }
.tarot-deck-choice.is-suit .tarot-deck-toggle-cards i:nth-child(3) { background: #df7d62; color: #fff; }
.tarot-deck-suits[hidden] { display: none; }
.tarot-deck-suits { display: flex; flex-direction: column; gap: 6px; }
.tarot-deck-suits-ask { font-size: 11px; font-weight: 800; color: var(--text-soft); }
.tarot-deck-suit-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.tarot-deck-suit {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1px;
    min-width: 0;
    padding: 7px 4px 6px;
    border: 1.5px solid var(--border);
    border-top: 3px solid var(--suit, #888);
    border-radius: 11px;
    background: var(--surface);
    color: var(--text);
    font: inherit;
    cursor: pointer;
    transition: border-color .16s ease, background-color .16s ease;
}
.tarot-deck-suit b { font-size: 11.5px; font-weight: 900; line-height: 1.25; word-break: keep-all; text-align: center; }
.tarot-deck-suit small { font-size: 10px; font-weight: 700; color: var(--text-soft); line-height: 1.3; text-align: center; word-break: keep-all; }
.tarot-deck-suit em {
    position: absolute;
    top: -9px;
    right: 4px;
    padding: 1px 6px;
    border-radius: 999px;
    background: var(--suit, #888);
    color: #fff;
    font-style: normal;
    font-size: 9px;
    font-weight: 900;
}
.tarot-deck-suit em[hidden] { display: none; }
.tarot-deck-suit:hover { border-color: var(--suit, #888); }
.tarot-deck-suit.is-selected { border-color: var(--suit, #888); background: color-mix(in srgb, var(--suit, #888) 12%, var(--surface)); }
@media (max-width: 560px) {
    .tarot-deck-segment { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .tarot-deck-suit-row { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 10px; }
}
@media (min-width: 561px) {
    .tarot-deck-choice strong { white-space: nowrap; }
    .tarot-deck-choice { gap: 6px; padding: 8px 4px; }
}


/* ===== mobile-text v1 — 휴대폰에서 작은 글씨 키우기 (자동 생성: 14px 미만만, 원래 값 → 새 값) ===== */
@media (max-width: 640px) {
  .tarot-ask-sub { font-size: 13px; } /* 12 */
  .tarot-ask-chip { font-size: 13.5px; } /* 12.5 */
  .tarot-ask-label { font-size: 12.5px; } /* 11 */
  .tarot-ask-spread { font-size: 13.5px; } /* 12.5 */
  .tarot-ask-badge { font-size: 11.5px; } /* 10 */
  .tarot-ask-why { font-size: 13px; } /* 12 */
  .tarot-three-sub { font-size: 13px; } /* 11.5 */
  .tarot-three-cards i { font-size: 11.5px; } /* 9.5 */
  .tarot-three-name { font-size: 14px; } /* 13.5 */
  .tarot-three-desc { font-size: 12.5px; } /* 11 */
  .tarot-three-go { font-size: 12.5px; } /* 11 */
  .tarot-variant-ask { font-size: 13px; } /* 11.5 */
  .tarot-life-quick-tile b { font-size: 13.5px; } /* 12.5 */
  .tarot-daily-life-link { font-size: 13.5px; } /* 12.5 */
  .tarot-deck-option-kicker { font-size: 12px; } /* 10.5 */
  .tarot-deck-option-title { font-size: 14px; } /* 13.5 */
  .tarot-deck-toggle-copy strong { font-size: 14px; } /* 13 */
  .tarot-deck-toggle-copy small { font-size: 12.5px; } /* 11 */
  .tarot-deck-toggle-cards i { font-size: 11.5px; } /* 8.5 */
  .tarot-deck-option-note { font-size: 13px; } /* 11.5 */
  .tarot-reading-options .tarot-deck-toggle-copy strong { font-size: 13px; } /* 11.5 */
  .tarot-reading-options .tarot-deck-toggle-copy small { font-size: 11.5px; } /* 9 */
  .tarot-reading-options .tarot-deck-toggle-cards i { font-size: 11.5px; } /* 8 */
  .tarot-deck-choice strong { font-size: 13px; } /* 11.5 */
  .tarot-deck-choice .tarot-deck-toggle-cards i { font-size: 11.5px; } /* 6.5 */
  .tarot-deck-suits-ask { font-size: 12.5px; } /* 11 */
  .tarot-deck-suit b { font-size: 13px; } /* 11.5 */
  .tarot-deck-suit small { font-size: 11.5px; } /* 10 */
  .tarot-deck-suit em { font-size: 11.5px; } /* 9 */
}
