/* AnatoBase — 마이페이지 팝업(공용) 스타일. global/mypage-modal.js 와 짝.
   학습하기(content)와 제품 페이지(pages/*.html) 헤더 「내 계정」이 같은 팝업을 쓴다(2026-09-13 통일).
   content/css/style.css 에서 이관 — --h8-* 변수는 제품 페이지에 없으니 전부 폴백값을 둔다(값 = global/variables.css).
   .auth-modal-overlay/.auth-modal-card/.am-* 는 global/auth-modal.css(먼저 로드). */
.my-page-view { max-width: 720px; margin: 0 auto; }
.mp-hidden { display: none !important; }
.mypage-modal-card { max-width: 560px; padding: 28px 8px 8px; }
.mypage-modal-card .my-page-view { max-width: none; margin: 0; padding: 8px 24px 24px; }
@media (max-width: 760px) { .mypage-modal-card { width: 95%; max-height: 92vh; } }

.mypage-modal-card .mp-row-loading .mp-row-label { color: var(--h8-color-text-muted, #999); font-weight: 400; }
/* 구매 내역 줄은 배지(padding 3px)가 라벨보다 4px 높다 → 로딩 줄·내역 줄 모두 같은 최소 높이로(열릴 때 팝업 높이 불변) */
.mypage-modal-card .mp-purchase-list .mp-row { min-height: 48px; box-sizing: border-box; }
/* 💳 마이페이지 구매 내역 (이용권/퀴즈/메모 통계 카드 대체 — 요청 2026-09-10) */
.mp-purchase-date { color: var(--h8-color-text-muted, #999); font-weight: 400; margin-left: 8px; font-size: 12px; }
.mp-purchase-badge { font-size: 12px; line-height: 18px; padding: 3px 10px; border-radius: 999px; background: #e8f3ea; color: #3d7a4c; white-space: nowrap; }
.mp-purchase-badge.off { background: #eee; color: #888; }

/* 마이페이지 모달 정리 (요청 2026-09-10 — "디자인 좀 이상하다") : 헤더(아바타·이메일·플랜 배지) + 섹션 리듬 통일 */
.mp-head { display: flex; align-items: center; gap: 14px; padding: 2px 4px 16px; border-bottom: 1px solid var(--h8-color-border, #e8e2df); margin-bottom: 16px; }
.mp-avatar { width: 44px; height: 44px; border-radius: 50%; background: #2d2a29; color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 17px; flex: none; }
.mp-head-title { font-size: 16px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
/* 닉네임(2026-09-13): 「마이페이지」 작게 위 → 닉네임 크게 + ✎ → 이메일. ✎ 누르면 그 자리에 입력칸 */
.mp-head-main { min-width: 0; flex: 1; }
.mp-head-kicker { font-size: 11px; font-weight: 600; color: var(--h8-color-text-muted, #999); letter-spacing: 0.04em; margin-bottom: 2px; }
.mp-head-nick { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; min-height: 26px; }
.mp-nick { font-size: 17px; font-weight: 700; color: var(--h8-color-text, #2d2a29); word-break: break-all; }
.mp-nick-loading { color: var(--h8-color-text-muted, #999); font-weight: 400; }
.mp-nick-edit { border: none; background: none; cursor: pointer; color: var(--h8-color-text-muted, #999); font-size: 14px; line-height: 1; padding: 3px 5px; border-radius: 6px; }
.mp-nick-edit:hover { color: var(--h8-color-text, #2d2a29); background: rgba(0,0,0,0.05); }
.mp-nick-form { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.mp-nick-input { width: 160px; max-width: 100%; padding: 5px 9px; border: 1.5px solid #ddd; border-radius: 6px; font: inherit; font-size: 14px; font-weight: 600; color: var(--h8-color-text, #2d2a29); background: #fff; }
.mp-nick-input:focus { outline: none; border-color: #bb5d5d; box-shadow: 0 0 0 3px rgba(187,93,93,0.1); }
.mp-nick-err { flex-basis: 100%; font-size: 12px; color: #bb5d5d; }
.mp-nick-err:empty { display: none; }
.mp-head-badge { font-size: 11px; font-weight: 600; padding: 2px 9px; border-radius: 999px; background: #2d2a29; color: #fff; }
.mp-head-email { font-size: 12.5px; color: var(--h8-color-text-muted, #999); margin-top: 3px; }
.mypage-modal-card .mp-settings-section { margin-bottom: 12px; padding: 14px 18px; }
.mypage-modal-card .mp-settings-section:last-child { margin-bottom: 0; }
.mypage-modal-card .mp-settings-title { font-size: 12px; font-weight: 600; color: var(--h8-color-text-muted, #999); letter-spacing: 0.02em; margin-bottom: 2px; }

.mp-settings-section {
    border: 1px solid var(--h8-color-border, #e8e2df);
    border-radius: 10px;
    padding: 16px;
}
.mp-settings-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--h8-color-text, #2d2a29);
    margin-bottom: 8px;
}
.mp-btn-sm {
    padding: 5px 12px;
    border: 1px solid var(--h8-color-border, #e8e2df);
    border-radius: 6px;
    background: var(--h8-color-bg, #ffffff);
    color: var(--h8-color-text, #2d2a29);
    font-size: 12px;
    cursor: pointer;
    transition: background 0.15s;
}
/* 마이페이지 「로그인 수단」 칩 — 이메일+비밀번호 · Google · 카카오(소셜 이메일이 계정과 다르면 작게 병기) */
.mp-row-methods { align-items: flex-start; }
.mp-methods { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; max-width: 70%; }
.mp-method { display: inline-flex; align-items: baseline; gap: 5px; padding: 3px 9px; border-radius: 999px; background: #f1f1f1; color: #333; font-size: 0.8125rem; line-height: 1.5; }
.mp-method small { font-size: 0.6875rem; color: #777; }
.mp-method-google { background: #eef3fd; color: #1a4fb0; }
.mp-method-kakao { background: #fff4b8; color: #4a3b00; }
.mp-btn-sm:hover { background: var(--h8-color-bg-hover, #f0eeed); }
.mp-btn-sm.mp-btn-danger {
    color: #e74c3c;
    border-color: #e74c3c50;
    background: transparent;
}
.mp-btn-sm.mp-btn-danger:hover { background: #e74c3c10; }

.mp-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--h8-color-border, #e8e2df);
}
.mp-row:last-child { border-bottom: none; }
.mp-row-label {
    font-size: 13px;
    color: var(--h8-color-text, #2d2a29);
}

.pwc-card { max-width: 400px; }
.pwc-note { font-size: 0.8125rem; color: #666; background: #f8f7f6; border: 1px solid #eee; border-radius: 8px; padding: 10px 12px; margin: 0 0 14px; line-height: 1.5; }
