:root {
  --text: #6b6375;
  --text-h: #08060d;
  --bg: #fff;
  --border: #e5e4e7;
  --code-bg: #f4f3ec;
  --accent: #aa3bff;
  --accent-bg: rgba(170, 59, 255, 0.1);
  --accent-border: rgba(170, 59, 255, 0.5);
  --social-bg: rgba(244, 243, 236, 0.5);
  --shadow:
    rgba(0, 0, 0, 0.1) 0 10px 15px -3px, rgba(0, 0, 0, 0.05) 0 4px 6px -2px;

  --sans: system-ui, 'Segoe UI', Roboto, sans-serif;
  --heading: system-ui, 'Segoe UI', Roboto, sans-serif;
  --mono: ui-monospace, Consolas, monospace;

  font: 18px/145% var(--sans);
  letter-spacing: 0.18px;
  color-scheme: light dark;
  color: var(--text);
  background: var(--bg);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  @media (max-width: 1024px) {
    font-size: 16px;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --text: #9ca3af;
    --text-h: #f3f4f6;
    --bg: #16171d;
    --border: #2e303a;
    --code-bg: #1f2028;
    --accent: #c084fc;
    --accent-bg: rgba(192, 132, 252, 0.15);
    --accent-border: rgba(192, 132, 252, 0.5);
    --social-bg: rgba(47, 48, 58, 0.5);
    --shadow:
      rgba(0, 0, 0, 0.4) 0 10px 15px -3px, rgba(0, 0, 0, 0.25) 0 4px 6px -2px;
  }

  #social .button-icon {
    filter: invert(1) brightness(2);
  }
}

body {
  margin: 0;
}

#root {
  width: 1126px;
  max-width: 100%;
  margin: 0 auto;
  text-align: center;
  border-inline: 1px solid var(--border);
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

h1,
h2 {
  font-family: var(--heading);
  font-weight: 500;
  color: var(--text-h);
}

h1 {
  font-size: 56px;
  letter-spacing: -1.68px;
  margin: 32px 0;
  @media (max-width: 1024px) {
    font-size: 36px;
    margin: 20px 0;
  }
}
h2 {
  font-size: 24px;
  line-height: 118%;
  letter-spacing: -0.24px;
  margin: 0 0 8px;
  @media (max-width: 1024px) {
    font-size: 20px;
  }
}
p {
  margin: 0;
}

code,
.counter {
  font-family: var(--mono);
  display: inline-flex;
  border-radius: 4px;
  color: var(--text-h);
}

code {
  font-size: 15px;
  line-height: 135%;
  padding: 4px 8px;
  background: var(--code-bg);
}
.legal-footer-bar {
  padding: 24px 20px 40px;
  text-align: center;
  border-top: 1px solid #f3f4f6;
  margin-top: 16px;
}

.legal-footer-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
}

.legal-footer-btn {
  background: none;
  border: none;
  font-size: 12px;
  color: #9ca3af;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-footer-btn:active {
  color: #6b7280;
}

.legal-footer-sep {
  font-size: 12px;
  color: #d1d5db;
}

.legal-footer-biz {
  font-size: 11px;
  color: #c0c4cc;
  line-height: 1.8;
  margin: 0;
}
.input-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #fff;
}

/* 헤더 */
.input-header {
  padding: 48px 24px 24px;
  background: linear-gradient(135deg, #6c5ce7 0%, #a855f7 100%);
  color: #fff;
}

.input-title {
  font-size: 26px;
  font-weight: 700;
  margin: 0 0 6px;
  letter-spacing: -0.5px;
}

.input-subtitle {
  font-size: 14px;
  margin: 0;
  opacity: 0.85;
}

/* 본문 */
.input-body {
  flex: 1;
  padding: 28px 24px 100px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

/* 필드 그룹 */
.field-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.field-label {
  font-size: 13px;
  font-weight: 600;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* 텍스트 인풋 */
.text-input {
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid #e8e8e8;
  border-radius: 12px;
  font-size: 16px;
  color: #1a1a1a;
  background: #fafafa;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s, background 0.2s;
  -moz-appearance: textfield;
}

.text-input::-webkit-outer-spin-button,
.text-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
}

.text-input:focus {
  border-color: #6c5ce7;
  background: #fff;
}

/* 버튼 그룹 (성별, 양/음력) */
.button-group,
.calendar-toggle {
  display: flex;
  gap: 8px;
}

.toggle-btn {
  flex: 1;
  padding: 13px;
  border: 1.5px solid #e8e8e8;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 500;
  color: #888;
  background: #fafafa;
  cursor: pointer;
  transition: all 0.18s;
}

.toggle-btn:hover {
  border-color: #a855f7;
  color: #6c5ce7;
}

.toggle-btn.active {
  border-color: #6c5ce7;
  background: #6c5ce7;
  color: #fff;
  font-weight: 600;
}

/* 날짜 입력 행 */
.date-row {
  display: flex;
  gap: 8px;
}

.date-input {
  text-align: center;
}

.date-row .date-input:first-child {
  flex: 2;
}

.date-row .date-input:not(:first-child) {
  flex: 1;
}

/* 윤달 / 시각모름 체크박스 */
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  color: #444;
  cursor: pointer;
  user-select: none;
}

.checkbox-label input[type='checkbox'] {
  width: 18px;
  height: 18px;
  accent-color: #6c5ce7;
  cursor: pointer;
  flex-shrink: 0;
}

/* 시간 선택 행 */
.time-row {
  display: flex;
  gap: 8px;
}

/* 장소 선택 행 */
.location-row {
  display: flex;
  gap: 8px;
}

/* 셀렉트 */
.select-wrap {
  flex: 1;
  position: relative;
}

.select-wrap::after {
  content: '▾';
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #aaa;
  pointer-events: none;
  font-size: 13px;
}

.select-input {
  width: 100%;
  padding: 14px 36px 14px 16px;
  border: 1.5px solid #e8e8e8;
  border-radius: 12px;
  font-size: 15px;
  color: #1a1a1a;
  background: #fafafa;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  transition: border-color 0.2s;
  box-sizing: border-box;
}

.select-input:focus {
  border-color: #6c5ce7;
  background: #fff;
}

.select-input:disabled {
  color: #bbb;
  cursor: not-allowed;
}

/* 에러 메시지 */
.error-text {
  font-size: 13px;
  color: #e53e3e;
  margin: 0;
}

/* 하단 버튼 */
.input-footer {
  padding: 12px 24px 32px;
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 480px;
  background: #fff;
  border-top: 1px solid #f0f0f0;
  z-index: 10;
}

.submit-btn {
  width: 100%;
  padding: 17px;
  border: none;
  border-radius: 14px;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: -0.3px;
}

.submit-btn.enabled {
  background: linear-gradient(135deg, #6c5ce7 0%, #a855f7 100%);
  color: #fff;
  box-shadow: 0 4px 16px rgba(108, 92, 231, 0.35);
}

.submit-btn.enabled:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(108, 92, 231, 0.45);
}

.submit-btn.enabled:active {
  transform: translateY(0);
}

.submit-btn.disabled {
  background: #f0f0f0;
  color: #bbb;
  cursor: not-allowed;
}

/* 스텝 인디케이터 */
.step-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.step-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: rgba(255,255,255,0.45);
  flex-shrink: 0;
}

.step-dot.current {
  background: #fff;
  border-color: #fff;
  color: #6c5ce7;
}

.step-dot.done {
  background: rgba(255,255,255,0.25);
  border-color: rgba(255,255,255,0.6);
  color: #fff;
}

.step-line {
  width: 32px;
  height: 2px;
  background: rgba(255,255,255,0.3);
  border-radius: 2px;
}

/* ── 칩 공통 ── */
.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* 직업: 2열 그리드 */
.chip-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.chip {
  padding: 11px 16px;
  border: 1.5px solid #e8e8e8;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 500;
  color: #555;
  background: #fafafa;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
  text-align: center;
}

.chip:hover {
  border-color: #a855f7;
  color: #6c5ce7;
}

.chip.active {
  background: #6c5ce7;
  border-color: #6c5ce7;
  color: #fff;
  font-weight: 600;
}

.chip.chip-maxed {
  opacity: 0.3;
  cursor: not-allowed;
}


/* ── 고민 힌트 ── */
.field-label-hint {
  font-size: 12px;
  font-weight: 600;
  color: #6c5ce7;
}

/* ── Step 2 푸터 ── */
.step2-footer {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

/* step2는 footer가 더 높으므로 body 하단 여백 추가 */
.step2-footer ~ * { display: none; }
.input-screen:has(.step2-footer) .input-body {
  padding-bottom: 140px;
}

.step2-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 4px;
}

.text-btn {
  background: none;
  border: none;
  font-size: 14px;
  color: #aaa;
  cursor: pointer;
  padding: 4px 0;
  font-weight: 500;
  transition: color 0.15s;
}

.text-btn:hover {
  color: #555;
}

/* 개인정보 동의 체크박스 */
.privacy-consent {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #666;
  cursor: pointer;
  user-select: none;
  margin-bottom: 12px;
}

.privacy-consent input[type='checkbox'] {
  width: 18px;
  height: 18px;
  accent-color: #6c5ce7;
  cursor: pointer;
  flex-shrink: 0;
}

.privacy-link {
  background: none;
  border: none;
  padding: 0;
  font-size: 14px;
  color: #6c5ce7;
  text-decoration: underline;
  cursor: pointer;
  font-weight: 600;
}

/* 이미 계정이 있어요 — 자연스러운 텍스트 링크 */
.login-link-btn {
  display: block;
  width: 100%;
  margin-top: 12px;
  background: none;
  border: none;
  padding: 6px 0;
  font-size: 14px;
  color: #aaa;
  text-align: center;
  cursor: pointer;
  font-weight: 500;
  transition: color 0.15s;
}
.login-link-btn:hover {
  color: #6c5ce7;
}

/* 개인정보처리방침 오버레이 */
.privacy-overlay {
  position: fixed;
  inset: 0;
  background: #fff;
  z-index: 100;
  display: flex;
  flex-direction: column;
  max-width: 480px;
  margin: 0 auto;
}

.privacy-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 48px 24px 20px;
  background: linear-gradient(135deg, #6c5ce7 0%, #a855f7 100%);
  color: #fff;
}

.privacy-title {
  font-size: 22px;
  font-weight: 700;
  margin: 0;
}

.privacy-close {
  background: rgba(255,255,255,0.2);
  border: none;
  color: #fff;
  font-size: 18px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.privacy-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.privacy-updated {
  font-size: 12px;
  color: #aaa;
  margin: 0;
}

.privacy-section h3 {
  font-size: 14px;
  font-weight: 700;
  color: #6c5ce7;
  margin: 0 0 6px;
  text-align: left;
}

.privacy-section p {
  font-size: 14px;
  color: #444;
}
.pwa-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 12px 16px 24px;
  padding: 12px 14px;
  background: #f5f3ff;
  border: 1px solid #ddd6fe;
  border-radius: 14px;
}

.pwa-banner-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.pwa-banner-text {
  flex: 1;
  min-width: 0;
}

.pwa-banner-title {
  font-size: 13px;
  font-weight: 700;
  color: #5b21b6;
  margin: 0 0 2px;
}

.pwa-banner-desc {
  font-size: 12px;
  color: #7c3aed;
  margin: 0;
}

.pwa-banner-btn {
  flex-shrink: 0;
  padding: 6px 14px;
  background: #7c3aed;
  color: #fff;
  border: none;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.pwa-banner-btn:active {
  opacity: 0.85;
}

.pwa-banner-close {
  flex-shrink: 0;
  background: none;
  border: none;
  color: #a78bfa;
  font-size: 14px;
  cursor: pointer;
  padding: 2px 4px;
}
@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.4; }
  40% { transform: scale(1); opacity: 1; }
}

@keyframes complete-pop {
  0%   { opacity: 0; transform: translateX(-50%) translateY(8px) scale(0.85); }
  100% { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
}

@keyframes confetti-fly {
  0%   { transform: translateY(0) scale(0.4); opacity: 1; }
  60%  { opacity: 1; }
  100% { transform: translateY(-56px) scale(1.2); opacity: 0; }
}

.home-tab {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
  padding-bottom: 80px;
}

/* 헤더 */
.home-header {
  background: linear-gradient(180deg, #6c5ce7 0%, #a855f7 100%);
  box-sizing: border-box;
  height: 110px;
  padding: 40px 20px 0;
  display: flex;
  flex-direction: column;
}

.home-name {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.home-header-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.home-date {
  font-size: 12px;
  color: rgba(255,255,255,0.55);
  margin: 0;
  font-weight: 500;
}

.home-iljin {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.1);
  border-radius: 99px;
  padding: 3px 14px;
}

.home-iljin-label {
  font-size: 11px;
  color: rgba(255,255,255,0.55);
  font-weight: 600;
}

.home-iljin-val {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
}

.home-iljin-wx {
  font-size: 11px;
  color: rgba(255,255,255,0.65);
}

/* 바디 */
.home-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* 로딩 */
.home-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 40px 0;
}

.home-loading-text {
  font-size: 14px;
  color: #aaa;
  margin: 0;
}

.loading-dots {
  display: flex;
  gap: 6px;
}

.loading-dots span {
  width: 8px;
  height: 8px;
  background: #6c5ce7;
  border-radius: 50%;
  animation: bounce 1.2s infinite ease-in-out;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

/* 에러 */
.home-error {
  background: #fff1f2;
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 13px;
  color: #be123c;
}

/* 로그인 유도 배너 */
.home-login-banner {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  border-radius: 14px;
  padding: 14px 16px;
  margin-bottom: 12px;
}
.home-login-banner-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.home-login-banner-title {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
}
.home-login-banner-btn {
  flex-shrink: 0;
  background: #fff;
  color: #7c3aed;
  border: none;
  border-radius: 8px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.home-login-banner-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.home-login-badge {
  background: rgba(255,255,255,0.2);
  border: 1px solid rgba(255,255,255,0.35);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  border-radius: 20px;
  padding: 4px 10px;
}

/* 공통 카드 */
.home-card {
  background: #fff;
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.home-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.home-card-label {
  font-size: 14px;
  font-weight: 700;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0;
}

.home-card-link {
  font-size: 12px;
  font-weight: 600;
  color: #6c5ce7;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

/* 운세 요약 */
.home-fortune-overall {
  font-size: 15px;
  font-weight: 700;
  color: #1a1a1a;
  line-height: 1.6;
  margin: 0 0 14px;
  padding: 12px 14px;
  background: #f5f3ff;
  border-radius: 10px;
  border-left: 3px solid #6c5ce7;
}

.home-fortune-areas {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.home-fortune-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.home-fortune-icon {
  font-size: 18px;
  flex-shrink: 0;
}

.home-fortune-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.home-fortune-area {
  font-size: 11px;
  font-weight: 700;
  color: #aaa;
}

.home-fortune-summary {
  font-size: 13px;
  color: #333;
  line-height: 1.4;
}

.home-fortune-level {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 99px;
  flex-shrink: 0;
  white-space: nowrap;
}

/* 미션 */
.home-mission-count {
  font-size: 12px;
  font-weight: 700;
  color: #6c5ce7;
}

.home-mission-progress {
  height: 4px;
  background: #f0f0f0;
  border-radius: 99px;
  margin-bottom: 14px;
  overflow: hidden;
}

.home-mission-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #6c5ce7, #a855f7);
  border-radius: 99px;
  transition: width 0.4s ease;
}

.home-missions-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.home-mission-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: 100%;
  background: #f9fafb;
  border: 1.5px solid #f0f0f0;
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s;
}

.home-mission-item.done {
  background: #f5f3ff;
  border-color: #c4b5fd;
  opacity: 0.8;
}

.home-mission-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid #d1d5db;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #6c5ce7;
  flex-shrink: 0;
  margin-top: 1px;
  transition: all 0.2s;
}

.home-mission-item.done .home-mission-check {
  background: #6c5ce7;
  border-color: #6c5ce7;
  color: #fff;
}

.home-mission-body {
  flex: 1;
  min-width: 0;
}

.home-mission-top {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 3px;
}

.home-mission-icon { font-size: 14px; }

.home-mission-category {
  font-size: 10px;
  font-weight: 700;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.home-mission-text {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0 0 3px;
  line-height: 1.4;
}

.home-mission-item.done .home-mission-text {
  text-decoration: line-through;
  color: #999;
}

.home-mission-detail {
  font-size: 12px;
  color: #888;
  margin: 0;
  line-height: 1.4;
}

.home-mission-complete-top {
  position: absolute;
  top: -6px;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
  background: linear-gradient(135deg, #6c5ce7, #a855f7);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  padding: 7px 16px;
  border-radius: 99px;
  box-shadow: 0 4px 12px rgba(108, 92, 231, 0.35);
  z-index: 11;
  animation: complete-pop 0.4s 0.3s ease-out both;
}

/* confetti */
.home-card-mission {
  position: relative;
  overflow: visible;
}

.home-confetti {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 0;
  overflow: visible;
  z-index: 10;
  pointer-events: none;
}

.home-confetti span {
  position: absolute;
  font-size: 20px;
  top: 0;
  left: calc(var(--ci) * 20% + 5%);
  animation: confetti-fly 1s calc(var(--ci) * 0.08s) ease-out both;
}

/* 개운법 인카드 버튼 */
.home-card-gaeun {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 100%;
  margin-top: 14px;
  padding: 10px;
  background: #f5f3ff;
  border: 1.5px solid #c4b5fd;
  border-radius: 10px;
  color: #6c5ce7;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s;
}

.home-card-gaeun:hover { background: #ede9fe; }

.service-tab {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
  padding-bottom: 80px;
}

.service-tab-header {
  background: linear-gradient(180deg, #6c5ce7 0%, #a855f7 100%);
  box-sizing: border-box;
  height: 110px;
  padding: 40px 20px 0;
  display: flex;
  flex-direction: column;
}

.service-tab-title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.service-tab-sub {
  font-size: 12px;
  color: rgba(255,255,255,0.75);
  margin: 0;
}

.service-tab-body {
  padding: 16px;
}

.service-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.service-card {
  border: 1.5px solid transparent;
  border-radius: 18px;
  padding: 10px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  cursor: pointer;
  text-align: left;
  transition: transform 0.18s, box-shadow 0.18s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.service-card:active {
  transform: scale(0.97);
}

.service-card-badge-row {
  min-height: 20px;
  display: flex;
  align-items: center;
}

.service-badge {
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  white-space: nowrap;
}

.service-card-content {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
}

.service-icon {
  font-size: 30px;
  line-height: 1;
  flex-shrink: 0;
}

.service-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  flex: 1;
  min-width: 0;
}

.service-name {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
}

.service-desc {
  font-size: 11px;
  line-height: 1.4;
}

.service-arrow {
  font-size: 20px;
  font-weight: 300;
  flex-shrink: 0;
  opacity: 0.7;
}

.service-card-locked {
  opacity: 0.72;
}

.service-lock {
  font-size: 12px;
  opacity: 0.6;
}
.ps-wrap {
  position: relative;
}

.ps-trigger {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.18);
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 20px;
  padding: 5px 10px 5px 6px;
  cursor: pointer;
  color: #fff;
}

.ps-avatar {
  width: 24px;
  height: 24px;
  background: rgba(255,255,255,0.35);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.ps-name {
  font-size: 13px;
  font-weight: 600;
  max-width: 60px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ps-chevron {
  font-size: 16px;
  font-weight: 300;
  transition: transform 0.2s;
  display: inline-block;
  line-height: 1;
}
.ps-chevron.up { transform: rotate(90deg); }

/* 드롭다운 */
.ps-backdrop {
  position: fixed;
  inset: 0;
  z-index: 99;
}

.ps-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.16);
  min-width: 200px;
  z-index: 100;
  overflow: hidden;
  padding-bottom: 6px;
}

.ps-dropdown-title {
  font-size: 11px;
  font-weight: 600;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 12px 16px 8px;
  margin: 0;
}

.ps-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 14px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s;
}
.ps-item:hover { background: #f8f8f8; }
.ps-item.active { background: #faf5ff; }

.ps-item-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6c5ce7, #a855f7);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ps-item-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ps-item-name {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a1a;
}

.ps-item-date {
  font-size: 11px;
  color: #aaa;
}

.ps-item-check {
  color: #6c5ce7;
  font-weight: 700;
  font-size: 14px;
}

.ps-add-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  width: calc(100% - 20px);
  margin: 6px 10px 4px;
  padding: 10px 14px;
  background: #f5f0ff;
  border: 1.5px dashed #c4b5fd;
  border-radius: 10px;
  color: #6c5ce7;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s;
}
.ps-add-btn:hover { background: #ede9fe; }

/* 프로필 행 (아이템 + 삭제 버튼) */
.ps-item-row {
  display: flex;
  align-items: center;
}

.ps-item-row .ps-item {
  flex: 1;
}

.ps-delete-btn {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 14px;
  color: #ccc;
  border-radius: 8px;
  margin-right: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}
.ps-delete-btn:hover { background: #fff0f0; }

/* 삭제 확인 팝업 */
.ps-confirm-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 200;
  padding-bottom: 20px;
}

.ps-confirm-box {
  background: #fff;
  border-radius: 24px 24px 16px 16px;
  padding: 28px 24px 24px;
  width: min(440px, 100%);
  margin: 0 12px;
  text-align: center;
}

.ps-confirm-icon {
  font-size: 36px;
  margin: 0 0 12px;
  line-height: 1;
}

.ps-confirm-title {
  font-size: 18px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0 0 6px;
}

.ps-confirm-name {
  font-size: 15px;
  font-weight: 600;
  color: #6c5ce7;
  margin: 0 0 12px;
}

.ps-confirm-desc {
  font-size: 14px;
  color: #e05c2a;
  font-weight: 600;
  line-height: 1.6;
  margin: 0 0 20px;
}

.ps-confirm-btns {
  display: flex;
  gap: 10px;
}

.ps-confirm-cancel {
  flex: 1;
  padding: 14px;
  border-radius: 12px;
  background: #f5f5f5;
  border: none;
  color: #666;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.ps-confirm-delete {
  flex: 2;
  padding: 14px;
  border-radius: 12px;
  background: linear-gradient(135deg, #ef4444, #dc2626);
  border: none;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}
@keyframes sg-fade-in {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.sg-list { display: flex; flex-direction: column; gap: 10px; }

.sg-header { display: flex; align-items: center; justify-content: space-between; padding: 0 2px 4px; }

.sg-count { font-size: 12px; font-weight: 700; color: #aaa; letter-spacing: 0.4px; }

.sg-toggle-all { font-size: 12px; font-weight: 600; color: #6c5ce7; background: none; border: none; cursor: pointer; padding: 4px 0; }

.sg-item {
  background: var(--sg-bg);
  border: 1.5px solid var(--sg-border);
  border-top: 3px solid var(--sg-accent);
  border-radius: 14px;
  padding: 16px;
  cursor: pointer;
  transition: box-shadow 0.18s, transform 0.18s;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
  user-select: none;
}
.sg-item:active { transform: scale(0.99); }
.sg-item.open { box-shadow: 0 4px 20px rgba(0,0,0,0.13); }

.sg-row { display: flex; align-items: center; gap: 12px; }

.sg-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; line-height: 1; flex-shrink: 0;
  background: #fff;
  border: 1.5px solid var(--sg-border);
  border-radius: 12px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

.sg-info { flex: 1; min-width: 0; }

.sg-title { font-size: 14px; font-weight: 700; color: var(--sg-text); margin: 0 0 4px; line-height: 1.4; }

.sg-summary { font-size: 13px; color: var(--sg-text); opacity: 0.8; margin: 0; line-height: 1.5; font-style: italic; }

.sg-chevron {
  font-size: 22px; color: var(--sg-accent); font-weight: 300;
  flex-shrink: 0; margin-left: 4px;
  transition: transform 0.22s ease;
  line-height: 1; display: inline-block;
}
.sg-chevron.up { transform: rotate(90deg); }

.sg-detail { margin-top: 14px; padding-top: 14px; border-top: 1.5px solid var(--sg-border); animation: sg-fade-in 0.2s ease; }

.sg-detail p { font-size: 14px; color: var(--sg-text); line-height: 1.85; margin: 0; white-space: pre-line; text-align: justify; }

.sg-disclaimer { font-size: 11px; color: #bbb; text-align: center; padding: 12px 16px 4px; line-height: 1.5; margin: 0; }
.mysaju-tab {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
  padding-bottom: 80px;
}

.mysaju-header {
  background: linear-gradient(180deg, #6c5ce7 0%, #a855f7 100%);
  box-sizing: border-box;
  height: 110px;
  padding: 40px 20px 0;
  display: flex;
  flex-direction: column;
}

.mysaju-header-top {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  position: relative;
  margin-bottom: 4px;
}

.mysaju-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0;
  letter-spacing: -0.5px;
  pointer-events: none;
}

.mysaju-sub {
  font-size: 12px;
  color: rgba(255,255,255,0.75);
  margin: 0;
}

/* 히스토리 섹션 */
.ms-history-card { padding: 16px; }

.ms-hist-service { border-bottom: 1px solid #f0f0f0; }
.ms-hist-service:last-child { border-bottom: none; }

.ms-hist-service-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  padding: 12px 4px;
  background: none;
  border: none;
  font-size: 14px;
  font-weight: 600;
  color: #333;
  cursor: pointer;
  text-align: left;
}

.ms-hist-count {
  margin-left: auto;
  font-size: 11px;
  color: #aaa;
  font-weight: 400;
  margin-right: 4px;
}

.ms-hist-chevron {
  font-size: 18px;
  color: #aaa;
  transition: transform 0.2s;
  display: inline-block;
}
.ms-hist-chevron.up { transform: rotate(90deg); }

.ms-hist-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-bottom: 12px;
}

.ms-hist-item {
  background: #f8f8fb;
  border-radius: 10px;
  padding: 12px;
  border-left: 3px solid #c4b5fd;
  width: 100%;
  text-align: left;
  cursor: pointer;
  border-top: none;
  border-right: none;
  border-bottom: none;
  transition: background 0.15s;
}
.ms-hist-item:active {
  background: #ede9fe;
}

.ms-hist-item-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.ms-hist-item-no {
  font-size: 11px;
  font-weight: 700;
  color: #6c5ce7;
  background: #ede9fe;
  padding: 2px 6px;
  border-radius: 6px;
}

.ms-hist-item-time {
  font-size: 11px;
  color: #aaa;
}

.ms-hist-meta {
  font-size: 11px;
  color: #6c5ce7;
  background: #f3e8ff;
  padding: 2px 7px;
  border-radius: 10px;
}

.ms-hist-preview {
  font-size: 13px;
  color: #555;
  line-height: 1.5;
  margin: 4px 0 0;
}

.ms-hist-tap-hint {
  font-size: 11px;
  color: #a78bfa;
  margin: 8px 0 0;
  text-align: right;
}

/* 히스토리 상세 바텀시트 */
.ms-hist-detail-sheet {
  width: 100%;
  background: #fff;
  border-radius: 24px 24px 0 0;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}

.ms-hist-detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 20px 14px;
  border-bottom: 1px solid #f0f0f0;
  flex-shrink: 0;
}

.ms-hist-detail-title {
  display: block;
  font-size: 16px;
  font-weight: 700;
  color: #1a1a1a;
}

.ms-hist-detail-date {
  display: block;
  font-size: 12px;
  color: #aaa;
  margin-top: 3px;
}

.ms-hist-detail-close {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  border: none;
  background: #f5f5f5;
  border-radius: 50%;
  font-size: 14px;
  color: #555;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ms-hist-detail-body {
  overflow-y: auto;
  flex: 1;
  padding: 8px 0 32px;
}

.mysaju-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ms-card {
  background: #fff;
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.ms-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.ms-card-label {
  font-size: 14px;
  font-weight: 700;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0 0 14px;
}

.ms-card-top .ms-card-label { margin: 0; }

.ms-label-with-help {
  display: flex;
  align-items: center;
  gap: 6px;
}

.edit-profile-btn {
  background: #f4f4f8;
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  color: #6c5ce7;
  cursor: pointer;
}

/* 사주표 */
.ms-saju-chart {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}

.ms-pillar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.ms-pillar-label { font-size: 11px; color: #bbb; font-weight: 600; }

.ms-cell {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 700;
  color: #1a1a1a;
}

.ms-cell.목 { background: #dcfce7; }
.ms-cell.화 { background: #fee2e2; }
.ms-cell.토 { background: #fef9c3; }
.ms-cell.금 { background: #f1f5f9; }
.ms-cell.수 { background: #dbeafe; }

.ms-animal { font-size: 10px; color: #bbb; }

.ms-birth-info {
  display: flex;
  gap: 6px;
  font-size: 12px;
  color: #aaa;
  justify-content: center;
  flex-wrap: wrap;
}

/* 오행 분포 */
.ms-wuxing {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ms-wuxing-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ms-wuxing-label {
  font-size: 13px;
  font-weight: 700;
  width: 44px;
  flex-shrink: 0;
}

.ms-bar-bg {
  flex: 1;
  height: 8px;
  background: #f0f0f0;
  border-radius: 99px;
  overflow: hidden;
}

.ms-bar-fill {
  height: 100%;
  border-radius: 99px;
  transition: width 0.8s ease;
}

.ms-bar-count {
  font-size: 12px;
  font-weight: 700;
  color: #aaa;
  width: 14px;
  text-align: right;
}

/* 2열 행 */
.ms-two-col {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.ms-two-col > .ms-card {
  flex: 1;
  min-width: 0;
  padding: 14px 12px;
}

/* 일간 특성 compact */
.ms-igan-card {
  border-radius: 16px !important;
}

.ms-igan-compact {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ms-igan-symbol-sm {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  align-self: center;
}

.ms-igan-hanja {
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  line-height: 1;
}

.ms-igan-sub {
  font-size: 10px;
  color: rgba(255,255,255,0.75);
  line-height: 1;
}

.ms-igan-ohaeng-sm {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: 12px;
  margin: 0;
}

.ms-igan-keywords {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: center;
}

.ms-igan-kw {
  font-size: 10px;
  font-weight: 600;
  padding: 3px 7px;
  border-radius: 99px;
}

.ms-igan-desc-sm {
  font-size: 13px;
  color: #666;
  line-height: 1.5;
  margin: 0;
  padding-top: 8px;
  border-top: 1px solid rgba(0,0,0,0.06);
  text-align: center;
}

/* 오행 분포 compact */
.ms-wuxing-compact .ms-wuxing-label {
  width: 36px;
  font-size: 11px;
}

.ms-wuxing-compact .ms-bar-count {
  font-size: 11px;
}

/* 서비스 연결 버튼 */
.ms-link-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin-top: 14px;
  padding: 11px;
  background: transparent;
  border: 1.5px solid rgba(0,0,0,0.08);
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  color: #555;
  cursor: pointer;
  transition: all 0.15s;
}

.ms-link-btn:hover {
  background: rgba(0,0,0,0.03);
  color: #222;
}

/* 앱 정보 푸터 */
.ms-app-footer {
  padding: 24px 4px 8px;
  text-align: center;
}

.ms-account-btn {
  display: block;
  width: 100%;
  background: #fff;
  border: 1.5px solid #e5e7eb;
  border-radius: 12px;
  padding: 14px;
  font-size: 14px;
  font-weight: 600;
  color: #374151;
  cursor: pointer;
  margin-bottom: 16px;
  transition: background 0.15s;
}

.ms-account-btn:active {
  background: #f9fafb;
}

.ms-legal-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
}

.ms-legal-btn {
  background: none;
  border: none;
  font-size: 12px;
  color: #9ca3af;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
}

.ms-legal-sep {
  font-size: 12px;
  color: #d1d5db;
}

.ms-biz-info {
  font-size: 11px;
  color: #c0c4cc;
  line-height: 1.8;
  margin: 0 0 6px;
}

.ms-version {
  font-size: 11px;
  color: #d1d5db;
  margin: 0;
}

/* 용신 */
.ms-yongshin-card {
  border-radius: 16px !important;
}

.ms-ys-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.ms-ys-help-btn {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1.5px solid #bbb;
  background: #fff;
  color: #888;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  line-height: 1;
}

/* 용신 설명 모달 */
.ms-info-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex;
  align-items: flex-end;
  z-index: 100;
}

.ms-info-box {
  width: 100%;
  background: #fff;
  border-radius: 24px 24px 0 0;
  padding: 28px 24px 36px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.ms-info-title {
  font-size: 17px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0;
}

.ms-info-item {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.ms-info-badge {
  display: inline-block;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 99px;
  width: fit-content;
}

.ms-info-item p {
  font-size: 13px;
  color: #444;
  margin: 0;
  line-height: 1.6;
}

.ms-info-example {
  font-size: 12px;
  color: #888;
  background: #f9fafb;
  border-radius: 10px;
  padding: 10px 12px;
  margin: 0;
  line-height: 1.6;
}

.ms-info-close {
  margin-top: 4px;
  width: 100%;
  padding: 14px;
  background: #f4f4f8;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  color: #444;
  cursor: pointer;
}

.ms-ys-row {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.ms-ys-item {
  flex: 1;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 6px;
  gap: 4px;
}

.ms-ys-item.main {
  flex: 1.3;
}

.ms-ys-emoji { font-size: 20px; }

.ms-ys-name {
  font-size: 18px;
  font-weight: 800;
  color: #fff;
}
.ms-ys-item.sub .ms-ys-name,
.ms-ys-item.avoid .ms-ys-name {
  font-size: 16px;
}

.ms-ys-tag {
  font-size: 10px;
  font-weight: 700;
  color: rgba(255,255,255,0.85);
  background: rgba(255,255,255,0.2);
  border-radius: 99px;
  padding: 2px 7px;
}
.ms-ys-item.sub .ms-ys-tag,
.ms-ys-item.avoid .ms-ys-tag {
  background: rgba(0,0,0,0.06);
}

.ms-ys-tips {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-bottom: 10px;
}

.ms-ys-tip-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  color: #444;
  line-height: 1.5;
}

.ms-ys-tip-icon { font-size: 14px; flex-shrink: 0; margin-top: 1px; }

.ms-ys-note {
  font-size: 11px;
  color: #bbb;
  margin: 0;
  padding-top: 10px;
  border-top: 1px solid rgba(0,0,0,0.06);
}

/* 대운 */
.ms-daeun-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.ms-daeun-start {
  font-size: 12px;
  color: #888;
}

.ms-daeun-dir {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 99px;
}
.ms-daeun-dir.forward { background: #eff6ff; color: #2563eb; }
.ms-daeun-dir.reverse { background: #fdf4ff; color: #a21caf; }

.ms-daeun-track {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.ms-daeun-track::-webkit-scrollbar { display: none; }

.ms-daeun-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  position: relative;
  padding: 8px 6px;
  border-radius: 12px;
  background: #f9fafb;
  min-width: 52px;
  transition: all 0.2s;
}

.ms-daeun-item.current {
  background: #eef2ff;
  box-shadow: 0 0 0 2px #6c5ce7;
}

.ms-daeun-now-badge {
  position: absolute;
  top: -8px;
  font-size: 9px;
  font-weight: 700;
  background: #6c5ce7;
  color: #fff;
  padding: 1px 6px;
  border-radius: 99px;
}

.ms-daeun-age {
  font-size: 10px;
  color: #aaa;
  font-weight: 600;
  margin-top: 6px;
}

.ms-daeun-comment {
  margin: 12px 0 0;
  padding: 10px 14px;
  background: #f5f3ff;
  border-radius: 10px;
  font-size: 13px;
  color: #4c1d95;
  line-height: 1.5;
}

.ms-daeun-gan,
.ms-daeun-zhi {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  font-weight: 700;
  color: #fff;
}

/* 추가 정보 */
.ms-optional {
  font-size: 11px;
  color: #bbb;
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
}

.ms-extra-fields {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.ms-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ms-field-label {
  font-size: 12px;
  font-weight: 600;
  color: #888;
}

.ms-input {
  padding: 12px 14px;
  border: 1.5px solid #e8e8e8;
  border-radius: 10px;
  font-size: 15px;
  color: #1a1a1a;
  background: #fafafa;
  outline: none;
  transition: border-color 0.2s;
}

.ms-input:focus {
  border-color: #6c5ce7;
  background: #fff;
}

.ms-save-btn {
  width: 100%;
  padding: 13px;
  background: #6c5ce7;
  border: none;
  border-radius: 12px;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}

.ms-save-btn.saved {
  background: #10b981;
}

.ms-save-btn:hover {
  opacity: 0.9;
}
/* ───── 버튼 2개 나란히 ───── */
.share-btn-row {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}

.share-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 13px 0;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.18s;
  border: 1.5px solid transparent;
}
.share-btn:active { transform: scale(0.97); }

/* 친구에게 공유 — 외곽선 */
.share-btn-link {
  background: #fff;
  border-color: #e5e7eb;
  color: #555;
}
.share-btn-link:hover {
  background: #f5f3ff;
  border-color: #c4b5fd;
  color: #6d28d9;
}

/* 결과 저장·공유 — 채운 보라 */
.share-btn-save {
  background: linear-gradient(135deg, #7c3aed 0%, #a855f7 100%);
  color: #fff;
}
.share-btn-save:hover { opacity: 0.88; }
.share-btn-save:disabled { opacity: 0.6; cursor: not-allowed; }


/* ───── 캡처용 오버레이 ───── */
.share-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(0, 0, 0, 0.72);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.share-overlay-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.share-overlay-hint {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
}


/* ───── 카드 본체 (v2 — 캐릭터·말풍선 디자인) ───── */
.share-card-square {
  width: 480px;
  height: 480px;
  border-radius: 28px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 22px 24px 18px;
  box-sizing: border-box;
  position: relative;
  font-family: -apple-system, 'Apple SD Gothic Neo', 'Noto Sans KR', sans-serif;
}

/* 반짝이 장식 */
.sc2-deco {
  position: absolute;
  opacity: 0.35;
  font-size: 18px;
  line-height: 1;
}
.sc2-deco1 { top: 62px; right: 34px; }
.sc2-deco2 { top: 150px; left: 18px; font-size: 13px; }
.sc2-deco3 { bottom: 120px; right: 20px; font-size: 14px; opacity: 0.25; }

/* 상단: 칩 + 날짜 */
.sc2-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  flex-shrink: 0;
}
.sc2-chip {
  background: #ffffff;
  border-radius: 99px;
  font-size: 14px;
  font-weight: 700;
  padding: 6px 16px;
  letter-spacing: -0.3px;
}
.sc2-date {
  font-size: 13px;
  color: #a1a1b5;
  font-weight: 500;
}

/* 캐릭터 + 말풍선 */
.sc2-hero {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
  flex-shrink: 0;
}
.sc2-chara {
  width: 84px;
  height: auto;
  flex-shrink: 0;
}
.sc2-bubble {
  position: relative;
  flex: 1;
  min-width: 0;
  background: #ffffff;
  border-radius: 18px;
  padding: 13px 16px;
}
.sc2-bubble-tail {
  position: absolute;
  left: -9px;
  top: 34px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-right: 10px solid #ffffff;
}
.sc2-quote {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.55;
  color: #2b2440;
  letter-spacing: -0.4px;
  margin: 0;
}

/* 이름 줄 */
.sc2-name {
  font-size: 20px;
  font-weight: 800;
  color: #2b2440;
  letter-spacing: -0.5px;
  margin: 0 0 10px;
  white-space: nowrap;
  overflow: hidden;
  flex-shrink: 0;
}
.sc2-name-sub {
  font-size: 15px;
  font-weight: 600;
  color: #8b84a3;
}

/* 키워드 3개 */
.sc2-kw-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  flex: 1;
  min-height: 0;
}
.sc2-kw {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.85);
  border-radius: 14px;
  padding: 10px 15px;
}
.sc2-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 14px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.sc2-kw-text { flex: 1; min-width: 0; text-align: left; }
.sc2-kw-title {
  font-size: 14px;
  font-weight: 700;
  color: #2b2440;
  letter-spacing: -0.3px;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
}
.sc2-kw-sub {
  font-size: 12px;
  color: #8b84a3;
  margin: 3px 0 0;
  white-space: nowrap;
  overflow: hidden;
}

/* 푸터: 브랜딩 (하단 고정 — 카드와 겹침 방지) */
.sc2-footer {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 14px;
  flex-shrink: 0;
}
.sc2-brand {
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.3px;
  margin: 0;
}
.sc2-url {
  font-size: 12px;
  color: #a1a1b5;
  margin: 0;
}
.rac-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 200;
  padding-bottom: 20px;
}

.rac-box {
  background: #fff;
  border-radius: 24px 24px 16px 16px;
  padding: 28px 24px 24px;
  width: min(440px, 100%);
  margin: 0 12px;
  text-align: center;
}

.rac-icon {
  font-size: 36px;
  margin-bottom: 12px;
  line-height: 1;
}

.rac-title {
  font-size: 18px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0 0 10px;
}

.rac-desc {
  font-size: 14px;
  color: #555;
  line-height: 1.7;
  margin: 0 0 8px;
}

.rac-caution {
  color: #e05c2a;
  font-size: 12px;
  font-weight: 600;
}

.rac-caution-big {
  color: #e05c2a;
  font-size: 16px;
  font-weight: 700;
  margin: 0 0 20px;
}

.rac-btns {
  display: flex;
  gap: 10px;
}

.rac-btn-cancel {
  flex: 1;
  padding: 14px;
  border-radius: 12px;
  background: #f5f5f5;
  border: none;
  color: #666;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.rac-btn-confirm {
  flex: 2;
  padding: 14px;
  border-radius: 12px;
  background: linear-gradient(135deg, #6c5ce7, #a855f7);
  border: none;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}
@keyframes ls-pop {
  0%,100% { opacity: 0; transform: translateY(4px) scale(0.8); }
  40%,60% { opacity: 1; transform: translateY(-4px) scale(1.1); }
}

@keyframes ls-shimmer {
  0%   { background-position: -400px 0; }
  100% { background-position:  400px 0; }
}

.ls-wrap {
  display: flex;
  flex-direction: column;
  margin: 12px 16px 24px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
}

/* ── 상단 이모지 영역 ── */
.ls-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 28px 20px 20px;
  gap: 10px;
}

.ls-main-emoji {
  font-size: 56px;
  line-height: 1;
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.ls-emoji-in  { opacity: 1; transform: translateY(0) scale(1); }
.ls-emoji-out { opacity: 0; transform: translateY(-8px) scale(0.8); }

.ls-particles {
  display: flex;
  gap: 10px;
}
.ls-particle {
  font-size: 20px;
  opacity: 0;
  animation: ls-pop 1.8s ease-in-out infinite;
}

.ls-msg {
  font-size: 13px;
  color: rgba(255,255,255,0.85);
  text-align: center;
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  transition: opacity 0.28s ease, transform 0.28s ease;
}
.ls-visible { opacity: 1; transform: translateY(0); }
.ls-hidden  { opacity: 0; transform: translateY(4px); }

.ls-bar-track {
  width: 100%;
  max-width: 220px;
  height: 3px;
  background: rgba(255,255,255,0.2);
  border-radius: 99px;
  overflow: hidden;
}
.ls-bar-fill {
  height: 100%;
  background: rgba(255,255,255,0.7);
  border-radius: 99px;
  transition: width 0.35s ease-out;
}

/* ── 하단 스켈레톤 ── */
.ls-skeleton-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  background: #f8f8fb;
  padding: 10px 12px 14px;
}

.ls-sk-card {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border-radius: 10px;
  padding: 12px 13px;
  margin-bottom: 7px;
  border: 1px solid #f0f0f0;
}
.ls-sk-card:last-child { margin-bottom: 0; }

.ls-sk {
  background: linear-gradient(90deg, #ebebeb 25%, #f5f5f5 50%, #ebebeb 75%);
  background-size: 800px 100%;
  animation: ls-shimmer 1.5s infinite linear;
  border-radius: 6px;
}

.ls-sk-icon {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  flex-shrink: 0;
}
.ls-sk-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.ls-sk-line {
  height: 10px;
}
.ls-sk-chev {
  width: 8px;
  height: 14px;
  flex-shrink: 0;
}

.error-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
  text-align: center;
  gap: 8px;
}

.error-state-icon {
  font-size: 40px;
  margin-bottom: 4px;
}

.error-state-title {
  font-size: 16px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0;
}

.error-state-desc {
  font-size: 13px;
  color: #6b7280;
  margin: 0;
  line-height: 1.5;
  max-width: 260px;
}

.error-state-retry {
  margin-top: 12px;
  padding: 10px 24px;
  background: #7c3aed;
  color: #fff;
  border: none;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.error-state-retry:active {
  opacity: 0.85;
}
@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.analysis-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
}

/* 헤더 */
.analysis-header {
  background: linear-gradient(135deg, #6c5ce7 0%, #a855f7 100%);
  padding: 36px 20px 12px;
  color: #fff;
}

.back-btn {
  background: rgba(255,255,255,0.2);
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 8px;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  cursor: pointer;
  margin-bottom: 14px;
  display: inline-block;
}

.analysis-title {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.analysis-name {
  font-size: 14px;
  opacity: 0.85;
}

/* 본문 */
.analysis-body {
  padding: 16px 16px 40px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* 정보 카드 (사주표, 오행) */
.info-card {
  background: #fff;
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.info-card-title {
  font-size: 12px;
  font-weight: 700;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0 0 14px;
}

/* 사주팔자표 */
.saju-chart {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.chart-pillar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.chart-label {
  font-size: 11px;
  color: #aaa;
  font-weight: 600;
}

.chart-cell {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 700;
  color: #1a1a1a;
}

.chart-cell.목 { background: #dcfce7; }
.chart-cell.화 { background: #fee2e2; }
.chart-cell.토 { background: #fef9c3; }
.chart-cell.금 { background: #f1f5f9; }
.chart-cell.수 { background: #dbeafe; }

.chart-animal {
  font-size: 10px;
  color: #aaa;
}

/* 오행 분포 */
.wuxing-bars {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.wuxing-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.wuxing-label {
  font-size: 12px;
  font-weight: 700;
  width: 44px;
  flex-shrink: 0;
}

.wuxing-bar-bg {
  flex: 1;
  height: 8px;
  background: #f0f0f0;
  border-radius: 99px;
  overflow: hidden;
}

.wuxing-bar-fill {
  height: 100%;
  border-radius: 99px;
  transition: width 0.8s ease;
}

.wuxing-count {
  font-size: 12px;
  font-weight: 700;
  color: #aaa;
  width: 14px;
  text-align: right;
}

/* 로딩 */
.loading-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 0;
  gap: 14px;
}

.loading-dots {
  display: flex;
  gap: 6px;
}

.loading-dots span {
  width: 10px;
  height: 10px;
  background: #a855f7;
  border-radius: 50%;
  animation: bounce 1.2s infinite ease-in-out;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

.loading-text {
  font-size: 14px;
  color: #aaa;
  margin: 0;
}

.error-text {
  font-size: 14px;
  color: #dc2626;
  margin: 0;
}

/* 카드 섹션 */
.cards-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cards-hint {
  font-size: 12px;
  color: #aaa;
  text-align: center;
  margin: 0;
}

/* 스와이프 트랙 */
.cards-track {
  display: flex;
  overflow-x: scroll;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  gap: 12px;
  padding: 4px 2px 8px;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.cards-track::-webkit-scrollbar {
  display: none;
}

/* 분석 카드 */
.analysis-card {
  min-width: calc(100% - 4px);
  scroll-snap-align: start;
  border-radius: 20px;
  padding: 32px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
  transition: transform 0.15s;
  user-select: none;
}

.analysis-card:active {
  transform: scale(0.98);
}

.card-icon {
  font-size: 48px;
  line-height: 1;
}

.card-title {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  margin: 0;
  letter-spacing: -0.3px;
}

.card-summary {
  font-size: 15px;
  color: rgba(255,255,255,0.92);
  line-height: 1.6;
  margin: 0;
  font-style: italic;
}

.card-tap-hint {
  font-size: 12px;
  color: rgba(255,255,255,0.65);
  margin-top: 8px;
}

/* 점 인디케이터 */
.dots {
  display: flex;
  justify-content: center;
  gap: 6px;
}

.dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ddd;
  transition: all 0.2s;
}

.dot.active {
  background: #6c5ce7;
  width: 18px;
  border-radius: 3px;
}

/* 모달 */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 100;
  animation: fadeIn 0.2s ease;
}

.modal-box {
  width: 100%;
  max-width: 480px;
  background: #fff;
  border-radius: 24px 24px 0 0;
  overflow: hidden;
  animation: slideUp 0.3s ease;
}

.modal-header {
  padding: 28px 24px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.modal-icon {
  font-size: 40px;
}

.modal-title {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

.modal-body {
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.modal-summary {
  font-size: 15px;
  font-weight: 600;
  color: #6c5ce7;
  font-style: italic;
  margin: 0;
  line-height: 1.6;
}

.modal-detail {
  font-size: 15px;
  color: #333;
  line-height: 2.0;
  margin: 0;
  word-break: keep-all;
}

.modal-close {
  width: calc(100% - 48px);
  margin: 0 24px 28px;
  padding: 15px;
  background: #f4f4f8;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  display: block;
}

.modal-close:hover {
  background: #ebebeb;
}

@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

@keyframes slideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }

.gaeun-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
}

.gaeun-header {
  background: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
  padding: 36px 20px 12px;
  color: #fff;
}

.back-btn {
  background: rgba(255,255,255,0.2);
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 8px;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  cursor: pointer;
  margin-bottom: 14px;
  display: inline-block;
}

.gaeun-title {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.gaeun-sub {
  font-size: 12px;
  opacity: 0.85;
}

.gaeun-body {
  padding: 16px 16px 40px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.info-card {
  background: #fff;
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.info-card-title {
  font-size: 12px;
  font-weight: 700;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0 0 14px;
}

/* 오행 요약 */
.ohaeng-summary {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ohaeng-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ohaeng-sub-label {
  font-size: 12px;
  color: #aaa;
  font-weight: 600;
  width: 60px;
  flex-shrink: 0;
}

.ohaeng-tags {
  display: flex;
  gap: 6px;
}

.ohaeng-tag {
  font-size: 13px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
}

.ohaeng-bars {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

.ohaeng-bar-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ohaeng-bar-bg {
  flex: 1;
  height: 7px;
  background: #f0f0f0;
  border-radius: 99px;
  overflow: hidden;
}

.ohaeng-bar-fill {
  height: 100%;
  border-radius: 99px;
  transition: width 0.8s ease;
}

/* 로딩 */
.loading-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 0;
  gap: 14px;
}

.loading-dots {
  display: flex;
  gap: 6px;
}

.loading-dots span {
  width: 10px;
  height: 10px;
  background: #f59e0b;
  border-radius: 50%;
  animation: bounce 1.2s infinite ease-in-out;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

.loading-text {
  font-size: 14px;
  color: #aaa;
  margin: 0;
}

.error-text { font-size: 14px; color: #dc2626; margin: 0; }

/* 카드 */
.cards-section { display: flex; flex-direction: column; gap: 12px; }

.cards-hint {
  font-size: 12px;
  color: #aaa;
  text-align: center;
  margin: 0;
}

.cards-track {
  display: flex;
  overflow-x: scroll;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  gap: 12px;
  padding: 4px 2px 8px;
  -ms-overflow-style: none;
  scrollbar-width: none;
}
.cards-track::-webkit-scrollbar { display: none; }

.gaeun-card {
  min-width: calc(100% - 4px);
  scroll-snap-align: start;
  border-radius: 20px;
  padding: 32px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
  transition: transform 0.15s;
  user-select: none;
}
.gaeun-card:active { transform: scale(0.98); }

.card-icon { font-size: 48px; line-height: 1; }
.card-title { font-size: 18px; font-weight: 700; color: #fff; margin: 0; }
.card-summary { font-size: 15px; color: rgba(255,255,255,0.92); line-height: 1.6; margin: 0; font-style: italic; }
.card-tap-hint { font-size: 12px; color: rgba(255,255,255,0.65); margin-top: 8px; }

/* 점 인디케이터 */
.dots { display: flex; justify-content: center; gap: 6px; }
.dot { width: 6px; height: 6px; border-radius: 50%; background: #ddd; transition: all 0.2s; }
.dot.active { background: #f59e0b; width: 18px; border-radius: 3px; }

/* 모달 */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.5);
  display: flex; align-items: flex-end; justify-content: center;
  z-index: 100;
  animation: fadeIn 0.2s ease;
}

.modal-box {
  width: 100%; max-width: 480px;
  background: #fff;
  border-radius: 24px 24px 0 0;
  overflow: hidden;
  animation: slideUp 0.3s ease;
}

.modal-header {
  padding: 28px 24px 20px;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
}
.modal-icon { font-size: 40px; }
.modal-title { font-size: 18px; font-weight: 700; color: #fff; margin: 0; }

.modal-body { padding: 20px 24px; display: flex; flex-direction: column; gap: 12px; }
.modal-summary { font-size: 15px; font-weight: 600; color: #f59e0b; font-style: italic; margin: 0; line-height: 1.6; }
.modal-detail { font-size: 15px; color: #333; line-height: 2.0; margin: 0; word-break: keep-all; }

.modal-close {
  width: calc(100% - 48px); margin: 0 24px 28px;
  padding: 15px; background: #f4f4f8;
  border: none; border-radius: 12px;
  font-size: 15px; font-weight: 600; color: #666;
  cursor: pointer; display: block;
}
.modal-close:hover { background: #ebebeb; }

@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

.luck-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
}

/* 헤더 */
.luck-header {
  background: linear-gradient(135deg, #3b82f6 0%, #6366f1 100%);
  padding: 36px 20px 12px;
}

.back-btn {
  background: rgba(255,255,255,0.2);
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  margin-bottom: 12px;
  display: inline-block;
}

.luck-title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.luck-sub {
  font-size: 12px;
  color: rgba(255,255,255,0.75);
}

/* 기간 탭 */
.luck-period-tabs {
  display: flex;
  background: #fff;
  border-bottom: 1.5px solid #ebebeb;
  position: sticky;
  top: 0;
  z-index: 10;
}

.luck-period-tab {
  flex: 1;
  padding: 14px 0;
  background: none;
  border: none;
  font-size: 14px;
  font-weight: 600;
  color: #aaa;
  cursor: pointer;
  border-bottom: 2.5px solid transparent;
  transition: all 0.18s;
}

.luck-period-tab.active {
  color: #3b82f6;
  border-bottom-color: #3b82f6;
}

/* 바디 */
.luck-body {
  padding: 16px;
  flex: 1;
}

/* 잠금 탭 */
.luck-period-tab.locked {
  opacity: 0.5;
}

/* 페이월 */
.luck-paywall {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 60px 24px;
  gap: 10px;
}
.luck-paywall-icon { font-size: 40px; margin: 0; }
.luck-paywall-title {
  font-size: 17px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0;
}
.luck-paywall-desc {
  font-size: 14px;
  color: #6b7280;
  margin: 0;
}
.luck-paywall-btn {
  margin-top: 12px;
  background: #7c3aed;
  color: #fff;
  border: none;
  border-radius: 12px;
  padding: 14px 28px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

/* 섹션 버튼 리스트 */
.luck-sections-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.luck-section-btn {
  width: 100%;
  background: var(--bg-color, #f9fafb);
  border: 1.5px solid var(--border-color, #e5e7eb);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.luck-section-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.luck-section-btn:active {
  transform: translateY(0);
}

.luck-section-left {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex: 1;
}

.luck-section-icon {
  font-size: 26px;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}

.luck-section-text {
  flex: 1;
}

.luck-section-title {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 4px;
}

.luck-section-summary {
  font-size: 13px;
  color: #555;
  margin: 0;
  line-height: 1.5;
}

.luck-section-arrow {
  font-size: 22px;
  color: #ccc;
  font-weight: 300;
  flex-shrink: 0;
  margin-left: 8px;
}

/* 로딩 */
.luck-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 0;
  gap: 12px;
}

.luck-loading-text {
  font-size: 14px;
  color: #888;
  margin: 0;
}

.loading-dots {
  display: flex;
  gap: 6px;
}

.loading-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #3b82f6;
  animation: bounce 1.2s infinite ease-in-out;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

/* 에러 */
.luck-error {
  background: #fff5f5;
  border: 1.5px solid #fca5a5;
  border-radius: 12px;
  padding: 16px;
  font-size: 14px;
  color: #dc2626;
  text-align: center;
}

/* 모달 */
.luck-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0 0 0 0;
}

.luck-modal-box {
  background: #fff;
  border-radius: 24px 24px 0 0;
  width: 100%;
  max-width: 480px;
  max-height: 80vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.luck-modal-header {
  padding: 24px 24px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-radius: 24px 24px 0 0;
}

.luck-modal-icon {
  font-size: 32px;
}

.luck-modal-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}

.luck-modal-body {
  padding: 16px 24px 8px;
}

.luck-modal-summary {
  font-size: 15px;
  font-weight: 600;
  color: #444;
  margin: 0 0 14px;
  line-height: 1.6;
  font-style: italic;
}

.luck-modal-detail {
  font-size: 15px;
  color: #333;
  line-height: 1.8;
  margin: 0;
}

.luck-modal-close {
  margin: 16px 24px 24px;
  padding: 14px;
  background: #3b82f6;
  border: none;
  border-radius: 12px;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.luck-modal-close:hover {
  opacity: 0.9;
}

@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

.career-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
}

.career-header {
  background: linear-gradient(135deg, #7c3aed 0%, #4f46e5 100%);
  padding: 36px 20px 12px;
}

.back-btn {
  background: rgba(255,255,255,0.2);
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  margin-bottom: 12px;
  display: inline-block;
}

.career-title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.career-sub {
  font-size: 12px;
  color: rgba(255,255,255,0.75);
}

.career-body {
  padding: 16px;
  flex: 1;
}

/* 직업 정보 배지 */
.career-info-badge {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.career-info-badge span {
  background: #fff;
  border: 1.5px solid #e0d9ff;
  border-radius: 20px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 600;
  color: #6d28d9;
}

/* 섹션 버튼 */
.career-sections-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.career-section-btn {
  width: 100%;
  background: var(--bg-color, #f9fafb);
  border: 1.5px solid var(--border-color, #e5e7eb);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.career-section-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.career-section-btn:active {
  transform: translateY(0);
}

.career-section-left {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex: 1;
}

.career-section-icon {
  font-size: 26px;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}

.career-section-text {
  flex: 1;
}

.career-section-title {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 4px;
}

.career-section-summary {
  font-size: 13px;
  color: #555;
  margin: 0;
  line-height: 1.5;
}

.career-section-arrow {
  font-size: 22px;
  color: #ccc;
  font-weight: 300;
  flex-shrink: 0;
  margin-left: 8px;
}

/* 로딩 */
.career-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 0;
  gap: 12px;
}

.career-loading-text {
  font-size: 14px;
  color: #888;
  margin: 0;
}

.loading-dots {
  display: flex;
  gap: 6px;
}

.loading-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #7c3aed;
  animation: bounce 1.2s infinite ease-in-out;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

/* 에러 */
.career-error {
  background: #fff5f5;
  border: 1.5px solid #fca5a5;
  border-radius: 12px;
  padding: 16px;
  font-size: 14px;
  color: #dc2626;
  text-align: center;
}

/* 모달 */
.career-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.career-modal-box {
  background: #fff;
  border-radius: 24px 24px 0 0;
  width: 100%;
  max-width: 480px;
  max-height: 80vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.career-modal-header {
  padding: 24px 24px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-radius: 24px 24px 0 0;
}

.career-modal-icon {
  font-size: 32px;
}

.career-modal-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}

.career-modal-body {
  padding: 16px 24px 8px;
}

.career-modal-summary {
  font-size: 15px;
  font-weight: 600;
  color: #444;
  margin: 0 0 14px;
  line-height: 1.6;
  font-style: italic;
}

.career-modal-detail {
  font-size: 15px;
  color: #333;
  line-height: 1.8;
  margin: 0;
}

.career-modal-close {
  margin: 16px 24px 24px;
  padding: 14px;
  background: #7c3aed;
  border: none;
  border-radius: 12px;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.career-modal-close:hover {
  opacity: 0.9;
}

@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

.wealth-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
}

.wealth-header {
  background: linear-gradient(135deg, #059669 0%, #10b981 100%);
  padding: 36px 20px 12px;
}

.back-btn {
  background: rgba(255,255,255,0.2);
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  margin-bottom: 12px;
  display: inline-block;
}

.wealth-title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.wealth-sub {
  font-size: 12px;
  color: rgba(255,255,255,0.75);
}

.wealth-body {
  padding: 16px;
  flex: 1;
}

.wealth-sections-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.wealth-section-btn {
  width: 100%;
  background: var(--bg-color, #f9fafb);
  border: 1.5px solid var(--border-color, #e5e7eb);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.wealth-section-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.wealth-section-btn:active { transform: translateY(0); }

.wealth-section-left {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex: 1;
}

.wealth-section-icon {
  font-size: 26px;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}

.wealth-section-text { flex: 1; }

.wealth-section-title {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 4px;
}

.wealth-section-summary {
  font-size: 13px;
  color: #555;
  margin: 0;
  line-height: 1.5;
}

.wealth-section-arrow {
  font-size: 22px;
  color: #ccc;
  font-weight: 300;
  flex-shrink: 0;
  margin-left: 8px;
}

.wealth-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 0;
  gap: 12px;
}

.wealth-loading-text { font-size: 14px; color: #888; margin: 0; }

.loading-dots { display: flex; gap: 6px; }

.loading-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #059669;
  animation: bounce 1.2s infinite ease-in-out;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

.wealth-error {
  background: #fff5f5;
  border: 1.5px solid #fca5a5;
  border-radius: 12px;
  padding: 16px;
  font-size: 14px;
  color: #dc2626;
  text-align: center;
}

.wealth-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.wealth-modal-box {
  background: #fff;
  border-radius: 24px 24px 0 0;
  width: 100%;
  max-width: 480px;
  max-height: 80vh;
  overflow-y: auto;
}

.wealth-modal-header {
  padding: 24px 24px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-radius: 24px 24px 0 0;
}

.wealth-modal-icon { font-size: 32px; }

.wealth-modal-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}

.wealth-modal-body { padding: 16px 24px 8px; }

.wealth-modal-summary {
  font-size: 15px;
  font-weight: 600;
  color: #444;
  margin: 0 0 14px;
  line-height: 1.6;
  font-style: italic;
}

.wealth-modal-detail {
  font-size: 15px;
  color: #333;
  line-height: 1.8;
  margin: 0;
}

.wealth-modal-close {
  margin: 16px 24px 24px;
  padding: 14px;
  background: #059669;
  border: none;
  border-radius: 12px;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  width: calc(100% - 48px);
}

.wealth-modal-close:hover { opacity: 0.9; }

@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

.health-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
}

.health-header {
  background: linear-gradient(135deg, #0d9488 0%, #10b981 100%);
  padding: 36px 20px 12px;
}

.back-btn {
  background: rgba(255,255,255,0.2);
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  margin-bottom: 12px;
  display: inline-block;
}

.health-title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.health-sub {
  font-size: 12px;
  color: rgba(255,255,255,0.75);
}

.health-body {
  padding: 16px;
  flex: 1;
}

.health-sections-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.health-section-btn {
  width: 100%;
  background: var(--bg-color, #f9fafb);
  border: 1.5px solid var(--border-color, #e5e7eb);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.health-section-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.health-section-btn:active { transform: translateY(0); }

.health-section-left {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex: 1;
}

.health-section-icon {
  font-size: 26px;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}

.health-section-text { flex: 1; }

.health-section-title {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 4px;
}

.health-section-summary {
  font-size: 13px;
  color: #555;
  margin: 0;
  line-height: 1.5;
}

.health-section-arrow {
  font-size: 22px;
  color: #ccc;
  font-weight: 300;
  flex-shrink: 0;
  margin-left: 8px;
}

.health-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 0;
  gap: 12px;
}

.health-loading-text { font-size: 14px; color: #888; margin: 0; }

.loading-dots { display: flex; gap: 6px; }

.loading-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #0d9488;
  animation: bounce 1.2s infinite ease-in-out;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

.health-error {
  background: #fff5f5;
  border: 1.5px solid #fca5a5;
  border-radius: 12px;
  padding: 16px;
  font-size: 14px;
  color: #dc2626;
  text-align: center;
}

.health-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.health-modal-box {
  background: #fff;
  border-radius: 24px 24px 0 0;
  width: 100%;
  max-width: 480px;
  max-height: 80vh;
  overflow-y: auto;
}

.health-modal-header {
  padding: 24px 24px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-radius: 24px 24px 0 0;
}

.health-modal-icon { font-size: 32px; }

.health-modal-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}

.health-modal-body { padding: 16px 24px 8px; }

.health-modal-summary {
  font-size: 15px;
  font-weight: 600;
  color: #444;
  margin: 0 0 14px;
  line-height: 1.6;
  font-style: italic;
}

.health-modal-detail {
  font-size: 15px;
  color: #333;
  line-height: 1.8;
  margin: 0;
}

.health-modal-close {
  margin: 16px 24px 24px;
  padding: 14px;
  background: #0d9488;
  border: none;
  border-radius: 12px;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  width: calc(100% - 48px);
}

.health-modal-close:hover { opacity: 0.9; }

@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

.compat-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
}

.compat-header {
  background: linear-gradient(135deg, #ec4899 0%, #a855f7 100%);
  padding: 36px 20px 12px;
}

.back-btn {
  background: rgba(255,255,255,0.2);
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  margin-bottom: 12px;
  display: inline-block;
}

.compat-title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.compat-sub {
  font-size: 12px;
  color: rgba(255,255,255,0.75);
}

.compat-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.compat-card {
  background: #fff;
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.compat-card-label {
  font-size: 12px;
  font-weight: 700;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0 0 12px;
}

/* 관계 유형 */
.compat-relation-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.compat-relation-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 4px;
  background: #f4f4f8;
  border: 1.5px solid #ebebeb;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  transition: all 0.18s;
}

.compat-relation-btn span:first-child { font-size: 20px; }

.compat-relation-btn.active {
  background: #fdf2f8;
  border-color: #e879f9;
  color: #a21caf;
}

/* 입력 필드 */
.compat-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}

.compat-field:last-child { margin-bottom: 0; }

.compat-field-label {
  font-size: 12px;
  font-weight: 600;
  color: #888;
}

.compat-input {
  padding: 12px 14px;
  border: 1.5px solid #e8e8e8;
  border-radius: 10px;
  font-size: 15px;
  color: #1a1a1a;
  background: #fafafa;
  outline: none;
  transition: border-color 0.2s;
  width: 100%;
  box-sizing: border-box;
}

.compat-input:focus {
  border-color: #e879f9;
  background: #fff;
}

.compat-input.small {
  width: 70px;
  flex-shrink: 0;
}

/* 성별 버튼 */
.compat-gender-btns {
  display: flex;
  gap: 8px;
}

.compat-gender-btn {
  flex: 1;
  padding: 10px;
  background: #f4f4f8;
  border: 1.5px solid #ebebeb;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  transition: all 0.18s;
}

.compat-gender-btn.active {
  background: #fdf2f8;
  border-color: #e879f9;
  color: #a21caf;
}

/* 시각 입력 */
.compat-time-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.compat-unknown-check {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  font-weight: 600;
  color: #888;
  cursor: pointer;
}

.compat-select {
  flex: 1;
  padding: 12px 10px;
  border: 1.5px solid #e8e8e8;
  border-radius: 10px;
  font-size: 14px;
  color: #1a1a1a;
  background: #fafafa;
  outline: none;
  cursor: pointer;
  transition: border-color 0.2s;
}

.compat-select:focus { border-color: #e879f9; background: #fff; }
.compat-select:disabled { opacity: 0.4; cursor: not-allowed; }

/* 지역 선택 */
.compat-location-row {
  display: flex;
  gap: 8px;
}

.compat-error-text {
  font-size: 13px;
  color: #dc2626;
  margin: 4px 0 0;
}

/* 분석 버튼 */
.compat-analyze-btn {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, #ec4899, #a855f7);
  border: none;
  border-radius: 14px;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.2s;
}

.compat-analyze-btn:hover { opacity: 0.9; }

/* 결과 파트너 배지 */
.compat-partner-badge {
  background: linear-gradient(135deg, #fdf2f8, #faf5ff);
  border: 1.5px solid #f0abfc;
  border-radius: 14px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.compat-partner-relation {
  background: linear-gradient(135deg, #ec4899, #a855f7);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  flex-shrink: 0;
}

.compat-partner-name {
  font-size: 15px;
  font-weight: 700;
  color: #a21caf;
}

/* 섹션 버튼 */
.compat-sections-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.compat-section-btn {
  width: 100%;
  background: var(--bg-color, #f9fafb);
  border: 1.5px solid var(--border-color, #e5e7eb);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.compat-section-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.compat-section-btn:active { transform: translateY(0); }

.compat-section-left {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex: 1;
}

.compat-section-icon { font-size: 26px; line-height: 1; flex-shrink: 0; margin-top: 2px; }
.compat-section-text { flex: 1; }

.compat-section-title { font-size: 14px; font-weight: 700; margin: 0 0 4px; }
.compat-section-summary { font-size: 13px; color: #555; margin: 0; line-height: 1.5; }
.compat-section-arrow { font-size: 22px; color: #ccc; font-weight: 300; flex-shrink: 0; margin-left: 8px; }

/* 로딩 */
.compat-loading { display: flex; flex-direction: column; align-items: center; padding: 48px 0; gap: 12px; }
.compat-loading-text { font-size: 14px; color: #888; margin: 0; }

.loading-dots { display: flex; gap: 6px; }
.loading-dots span {
  width: 8px; height: 8px; border-radius: 50%;
  background: #ec4899;
  animation: bounce 1.2s infinite ease-in-out;
}
.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

.compat-error-box {
  background: #fff5f5; border: 1.5px solid #fca5a5;
  border-radius: 12px; padding: 16px;
  font-size: 14px; color: #dc2626; text-align: center;
}

/* 모달 */
.compat-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 100; display: flex; align-items: flex-end; justify-content: center;
}

.compat-modal-box {
  background: #fff; border-radius: 24px 24px 0 0;
  width: 100%; max-width: 480px; max-height: 80vh; overflow-y: auto;
}

.compat-modal-header {
  padding: 24px 24px 16px;
  display: flex; align-items: center; gap: 12px;
  border-radius: 24px 24px 0 0;
}

.compat-modal-icon { font-size: 32px; }
.compat-modal-title { font-size: 18px; font-weight: 700; margin: 0; }
.compat-modal-body { padding: 16px 24px 8px; }
.compat-modal-summary { font-size: 15px; font-weight: 600; color: #444; margin: 0 0 14px; line-height: 1.6; font-style: italic; }
.compat-modal-detail { font-size: 15px; color: #333; line-height: 1.8; margin: 0; }

.compat-modal-close {
  margin: 16px 24px 24px; padding: 14px;
  background: linear-gradient(135deg, #ec4899, #a855f7);
  border: none; border-radius: 12px; color: #fff;
  font-size: 15px; font-weight: 700; cursor: pointer;
  width: calc(100% - 48px);
}
.compat-modal-close:hover { opacity: 0.9; }

@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

.date-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
}

.date-header {
  background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  padding: 36px 20px 12px;
}

.back-btn {
  background: rgba(255,255,255,0.2);
  border: none; border-radius: 8px;
  padding: 6px 12px; font-size: 13px; font-weight: 600;
  color: #fff; cursor: pointer; margin-bottom: 12px; display: inline-block;
}

.date-title { font-size: 20px; font-weight: 700; color: #fff; margin: 0 0 4px; letter-spacing: -0.5px; }
.date-sub { font-size: 12px; color: rgba(255,255,255,0.75); }

.date-body { padding: 16px; display: flex; flex-direction: column; gap: 12px; }

.date-event-section {
  background: #fff;
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.date-event-label {
  font-size: 13px; font-weight: 700; color: #555; margin: 0 0 12px;
}

.date-event-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.date-event-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 12px 4px;
  background: #f4f4f8;
  border: 1.5px solid #ebebeb;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.18s;
}

.date-event-icon { font-size: 22px; }
.date-event-label-text { font-size: 11px; font-weight: 600; color: #666; }

.date-event-btn.active {
  background: #eff6ff;
  border-color: #93c5fd;
}
.date-event-btn.active .date-event-label-text { color: #1d4ed8; }

.date-result-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #eff6ff;
  border: 1.5px solid #93c5fd;
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 700;
  color: #1d4ed8;
}

.date-sections-list { display: flex; flex-direction: column; gap: 10px; }

.date-section-btn {
  width: 100%;
  background: var(--bg-color, #f9fafb);
  border: 1.5px solid var(--border-color, #e5e7eb);
  border-radius: 14px; padding: 16px;
  display: flex; align-items: center; justify-content: space-between;
  cursor: pointer; text-align: left;
  transition: all 0.18s;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.date-section-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.date-section-btn:active { transform: translateY(0); }

.date-section-left { display: flex; align-items: flex-start; gap: 12px; flex: 1; }
.date-section-icon { font-size: 26px; line-height: 1; flex-shrink: 0; margin-top: 2px; }
.date-section-text { flex: 1; }
.date-section-title { font-size: 14px; font-weight: 700; margin: 0 0 4px; }
.date-section-summary { font-size: 13px; color: #555; margin: 0; line-height: 1.5; }
.date-section-arrow { font-size: 22px; color: #ccc; font-weight: 300; flex-shrink: 0; margin-left: 8px; }

.date-loading { display: flex; flex-direction: column; align-items: center; padding: 48px 0; gap: 12px; }
.date-loading-text { font-size: 14px; color: #888; margin: 0; }

.loading-dots { display: flex; gap: 6px; }
.loading-dots span {
  width: 8px; height: 8px; border-radius: 50%;
  background: #2563eb;
  animation: bounce 1.2s infinite ease-in-out;
}
.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

.date-error {
  background: #fff5f5; border: 1.5px solid #fca5a5;
  border-radius: 12px; padding: 16px;
  font-size: 14px; color: #dc2626; text-align: center;
}

.date-placeholder {
  text-align: center; padding: 48px 0;
  font-size: 14px; color: #aaa; line-height: 1.8;
}

/* 상황 입력 박스 */
.date-situation-box {
  background: #fff;
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.date-situation-label {
  font-size: 13px;
  font-weight: 700;
  color: #555;
}

.date-situation-optional {
  font-weight: 400;
  color: #aaa;
}

.date-situation-input {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid #e8e8e8;
  border-radius: 12px;
  font-size: 14px;
  color: #1a1a1a;
  background: #fafafa;
  outline: none;
  resize: none;
  line-height: 1.6;
  box-sizing: border-box;
  font-family: inherit;
  transition: border-color 0.2s;
}

.date-situation-input:focus {
  border-color: #6c5ce7;
  background: #fff;
}

.date-situation-input::placeholder {
  color: #bbb;
  font-size: 13px;
}

.date-analyze-btn {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, #6c5ce7 0%, #a855f7 100%);
  border: none;
  border-radius: 12px;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.2s;
}

.date-analyze-btn:hover {
  opacity: 0.9;
}

.date-reanalyze-btn {
  background: none;
  border: none;
  font-size: 13px;
  color: #aaa;
  cursor: pointer;
  padding: 4px 0;
  font-weight: 500;
}

.date-reanalyze-btn:hover { color: #555; }

.date-modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.45);
  z-index: 100; display: flex; align-items: flex-end; justify-content: center;
}

.date-modal-box {
  background: #fff; border-radius: 24px 24px 0 0;
  width: 100%; max-width: 480px; max-height: 80vh; overflow-y: auto;
}

.date-modal-header { padding: 24px 24px 16px; display: flex; align-items: center; gap: 12px; border-radius: 24px 24px 0 0; }
.date-modal-icon { font-size: 32px; }
.date-modal-title { font-size: 18px; font-weight: 700; margin: 0; }
.date-modal-body { padding: 16px 24px 8px; }
.date-modal-summary { font-size: 15px; font-weight: 600; color: #444; margin: 0 0 14px; line-height: 1.6; font-style: italic; }
.date-modal-detail { font-size: 15px; color: #333; line-height: 1.8; margin: 0; }

.date-modal-close {
  margin: 16px 24px 24px; padding: 14px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  border: none; border-radius: 12px; color: #fff;
  font-size: 15px; font-weight: 700; cursor: pointer;
  width: calc(100% - 48px);
}
.date-modal-close:hover { opacity: 0.9; }

@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

.dream-screen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 480px;
  margin: 0 auto;
  background: #f4f4f8;
}

.dream-header {
  background: linear-gradient(135deg, #1e1b4b 0%, #4c1d95 100%);
  padding: 36px 20px 12px;
}

.back-btn {
  background: rgba(255,255,255,0.15);
  border: none; border-radius: 8px;
  padding: 6px 12px; font-size: 13px; font-weight: 600;
  color: #fff; cursor: pointer; margin-bottom: 12px; display: inline-block;
}

.dream-title { font-size: 20px; font-weight: 700; color: #fff; margin: 0 0 4px; letter-spacing: -0.5px; }
.dream-sub { font-size: 12px; color: rgba(255,255,255,0.65); }

.dream-body { padding: 16px; display: flex; flex-direction: column; gap: 12px; }

.dream-card {
  background: #fff;
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.dream-card-label {
  font-size: 12px; font-weight: 700; color: #aaa;
  text-transform: uppercase; letter-spacing: 0.5px; margin: 0 0 12px;
}

/* 분위기 선택 */
.dream-mood-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.dream-mood-btn {
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  padding: 12px 4px;
  background: #f4f4f8; border: 1.5px solid #ebebeb;
  border-radius: 12px; cursor: pointer; transition: all 0.18s;
}

.dream-mood-icon { font-size: 24px; }
.dream-mood-label { font-size: 11px; font-weight: 600; color: #666; }

.dream-mood-btn.active {
  background: #f5f3ff; border-color: #c4b5fd;
}
.dream-mood-btn.active .dream-mood-label { color: #6d28d9; }

/* 텍스트 입력 */
.dream-textarea {
  width: 100%;
  padding: 14px;
  border: 1.5px solid #e8e8e8;
  border-radius: 12px;
  font-size: 14px;
  color: #1a1a1a;
  background: #fafafa;
  outline: none;
  resize: none;
  line-height: 1.7;
  box-sizing: border-box;
  transition: border-color 0.2s;
  font-family: inherit;
}

.dream-textarea:focus {
  border-color: #c4b5fd;
  background: #fff;
}

.dream-char-count {
  font-size: 11px; color: #bbb; text-align: right; margin: 4px 0 0;
}

.dream-error-text { font-size: 13px; color: #dc2626; margin: 0; }

.dream-analyze-btn {
  width: 100%; padding: 16px;
  background: linear-gradient(135deg, #4c1d95, #6366f1);
  border: none; border-radius: 14px;
  color: #fff; font-size: 16px; font-weight: 700;
  cursor: pointer; transition: opacity 0.2s;
}
.dream-analyze-btn:hover { opacity: 0.9; }

/* 결과 */
.dream-result-badge {
  display: flex; align-items: center; gap: 8px;
  background: #f5f3ff; border: 1.5px solid #c4b5fd;
  border-radius: 12px; padding: 12px 16px;
  font-size: 22px;
}

.dream-result-text { font-size: 14px; font-weight: 700; color: #6d28d9; }

.dream-sections-list { display: flex; flex-direction: column; gap: 10px; }

.dream-section-btn {
  width: 100%;
  background: var(--bg-color, #f9fafb);
  border: 1.5px solid var(--border-color, #e5e7eb);
  border-radius: 14px; padding: 16px;
  display: flex; align-items: center; justify-content: space-between;
  cursor: pointer; text-align: left;
  transition: all 0.18s; box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.dream-section-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,0.08); }
.dream-section-btn:active { transform: translateY(0); }

.dream-section-left { display: flex; align-items: flex-start; gap: 12px; flex: 1; }
.dream-section-icon { font-size: 26px; line-height: 1; flex-shrink: 0; margin-top: 2px; }
.dream-section-text { flex: 1; }
.dream-section-title { font-size: 14px; font-weight: 700; margin: 0 0 4px; }
.dream-section-summary { font-size: 13px; color: #555; margin: 0; line-height: 1.5; }
.dream-section-arrow { font-size: 22px; color: #ccc; font-weight: 300; flex-shrink: 0; margin-left: 8px; }

.dream-loading { display: flex; flex-direction: column; align-items: center; padding: 48px 0; gap: 12px; }
.dream-loading-text { font-size: 14px; color: #888; margin: 0; }

.loading-dots { display: flex; gap: 6px; }
.loading-dots span {
  width: 8px; height: 8px; border-radius: 50%;
  background: #6366f1;
  animation: bounce 1.2s infinite ease-in-out;
}
.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

.dream-error-box {
  background: #fff5f5; border: 1.5px solid #fca5a5;
  border-radius: 12px; padding: 16px;
  font-size: 14px; color: #dc2626; text-align: center;
}

.dream-modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.55);
  z-index: 100; display: flex; align-items: flex-end; justify-content: center;
}

.dream-modal-box {
  background: #fff; border-radius: 24px 24px 0 0;
  width: 100%; max-width: 480px; max-height: 80vh; overflow-y: auto;
}

.dream-modal-header { padding: 24px 24px 16px; display: flex; align-items: center; gap: 12px; border-radius: 24px 24px 0 0; }
.dream-modal-icon { font-size: 32px; }
.dream-modal-title { font-size: 18px; font-weight: 700; margin: 0; }
.dream-modal-body { padding: 16px 24px 8px; }
.dream-modal-summary { font-size: 15px; font-weight: 600; color: #444; margin: 0 0 14px; line-height: 1.6; font-style: italic; }
.dream-modal-detail { font-size: 15px; color: #333; line-height: 1.8; margin: 0; }

.dream-modal-close {
  margin: 16px 24px 24px; padding: 14px;
  background: linear-gradient(135deg, #4c1d95, #6366f1);
  border: none; border-radius: 12px; color: #fff;
  font-size: 15px; font-weight: 700; cursor: pointer;
  width: calc(100% - 48px);
}
.dream-modal-close:hover { opacity: 0.9; }

@keyframes bounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.4; }
  40% { transform: translateY(-8px); opacity: 1; }
}

.ds-screen {
  display: flex;
  flex-direction: column;
  height: 100%;
  max-width: 480px;
  margin: 0 auto;
  background: #f9fafb;
  overflow: hidden;
}

/* 헤더 */
.ds-header {
  background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
  padding: 44px 20px 20px;
  flex-shrink: 0;
}

.ds-back-btn {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  margin-bottom: 12px;
  display: inline-block;
}

.ds-title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
}

.ds-sub {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.75);
  margin: 0;
}

/* 바디 */
.ds-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ds-info-text {
  font-size: 13px;
  color: #888;
  text-align: center;
  margin: 0 0 4px;
}

/* 대운 카드 */
.ds-daeun-card {
  background: #fff;
  border-radius: 14px;
  border: 1.5px solid #e5e7eb;
  overflow: hidden;
}

.ds-daeun-card.current {
  border-color: #6c5ce7;
  box-shadow: 0 2px 12px rgba(108, 92, 231, 0.12);
}

.ds-daeun-header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
}

.ds-daeun-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.ds-now-badge {
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  background: #6c5ce7;
  border-radius: 20px;
  padding: 2px 8px;
}

.ds-daeun-age {
  font-size: 14px;
  font-weight: 700;
  color: #333;
  min-width: 70px;
}

.ds-daeun-ganzhi {
  display: flex;
  gap: 4px;
}

.ds-gan,
.ds-zhi {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
}

.ds-daeun-ohaeng {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 600;
}

.ds-dot {
  color: #ccc;
}

.ds-chevron {
  font-size: 11px;
  color: #aaa;
  flex-shrink: 0;
}

/* 세운 펼침 영역 */
.ds-seyun-wrap {
  padding: 0 16px 16px;
  border-top: 1px solid #f0f0f0;
}

.ds-seyun-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-top: 12px;
}

.ds-seyun-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  transition: background 0.15s;
}

.ds-seyun-item.this-year {
  background: #f5f3ff;
}

.ds-seyun-year-col {
  display: flex;
  flex-direction: column;
  min-width: 44px;
}

.ds-seyun-yr {
  font-size: 14px;
  font-weight: 700;
  color: #222;
}

.ds-seyun-age-sm {
  font-size: 11px;
  color: #aaa;
}

.ds-seyun-ganzhi {
  display: flex;
  gap: 6px;
  min-width: 36px;
}

.ds-seyun-gz {
  font-size: 16px;
  font-weight: 700;
}

.ds-seyun-ohaeng {
  display: flex;
  gap: 4px;
  font-size: 12px;
  font-weight: 600;
  flex: 1;
}

/* 평가 점 */
.ds-eval-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.ds-eval-dot.good { background: #22c55e; }
.ds-eval-dot.neutral { background: #facc15; }
.ds-eval-dot.caution { background: #ef4444; }

/* 범례 */
.ds-legend {
  display: flex;
  gap: 14px;
  justify-content: flex-end;
  font-size: 11px;
  color: #888;
  margin: 8px 0 14px;
  align-items: center;
}

.ds-legend span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* 분석 버튼 */
.ds-analyze-btn,
.ds-detail-btn {
  width: 100%;
  padding: 13px;
  border-radius: 10px;
  border: none;
  background: linear-gradient(135deg, #6c5ce7, #a29bfe);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 4px;
}

/* 로딩 */
.loading-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 20px 0;
}

.loading-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #6c5ce7;
  animation: bounce 1.2s infinite;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

/* 에러 */
.ds-error {
  font-size: 13px;
  color: #ef4444;
  text-align: center;
  padding: 12px 0;
}

/* 코멘트 로딩 */
.ds-comments-loading {
  text-align: center;
  padding: 20px 0 8px;
}
.ds-comments-loading-text {
  font-size: 13px;
  color: #888;
  margin: 8px 0 0;
}
.ds-comments-error {
  font-size: 13px;
  color: #ef4444;
  text-align: center;
  padding: 10px 0;
}

/* 대운 한줄 코멘트 */
.ds-daeun-comment {
  font-size: 12.5px;
  color: #6c5ce7;
  font-weight: 500;
  padding: 0 16px 12px;
  line-height: 1.4;
}
.ds-daeun-comment--loading {
  color: #ccc;
  letter-spacing: 2px;
}

/* 세운 아이템 — 리레이아웃 */
.ds-seyun-item {
  display: flex;
  flex-direction: column;
  padding: 8px 10px;
  border-radius: 8px;
  transition: background 0.15s;
}
.ds-seyun-item.this-year {
  background: #f5f3ff;
}
.ds-seyun-left-col {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
}
.ds-seyun-top-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* 세운 한줄 코멘트 */
.ds-seyun-comment {
  font-size: 11.5px;
  color: #555;
  line-height: 1.4;
  padding-left: 56px;
}
.ds-seyun-comment--loading {
  color: #ccc;
  letter-spacing: 2px;
}

@keyframes bounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.4; }
  40% { transform: translateY(-8px); opacity: 1; }
}

.dd-screen {
  display: flex;
  flex-direction: column;
  height: 100%;
  max-width: 480px;
  margin: 0 auto;
  background: #f9fafb;
  overflow: hidden;
}

/* 헤더 */
.dd-header {
  background: linear-gradient(135deg, #7c3aed 0%, #6c5ce7 100%);
  padding: 44px 20px 20px;
  flex-shrink: 0;
  text-align: center;
}

.dd-back-btn {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  margin-bottom: 12px;
  display: inline-block;
}

.dd-title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 8px;
  width: 100%;
}

.dd-ganjhi {
  display: inline-flex;
  gap: 2px;
  background: rgba(255,255,255,0.22);
  border-radius: 8px;
  padding: 2px 10px;
  font-size: 18px;
  font-weight: 800;
}

.dd-sub {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.75);
  margin: 0;
}

/* 바디 */
.dd-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* 로딩 */
.dd-loading {
  text-align: center;
  padding: 60px 0;
}
.dd-loading-text {
  font-size: 14px;
  color: #888;
  margin: 12px 0 0;
}
.loading-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
}
.loading-dots span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #7c3aed;
  animation: bounce 1.2s infinite;
}
.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

/* 에러 */
.dd-error {
  text-align: center;
  padding: 40px 0;
}
.dd-error p {
  font-size: 14px;
  color: #ef4444;
  margin-bottom: 12px;
}
.dd-retry-btn {
  padding: 10px 20px;
  border-radius: 8px;
  border: none;
  background: #7c3aed;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

/* 연도별 세운 섹션 */
.dd-seyun-section {
  background: #fff;
  border-radius: 14px;
  border: 1.5px solid #e5e7eb;
  padding: 16px;
}

.dd-seyun-title {
  font-size: 15px;
  font-weight: 700;
  color: #333;
  margin: 0 0 14px;
}

.dd-seyun-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.dd-seyun-item {
  padding: 11px 10px;
  border-radius: 10px;
  border-bottom: 1px solid #f3f4f6;
  transition: background 0.15s;
}
.dd-seyun-item:last-child {
  border-bottom: none;
}
.dd-seyun-item.this-year {
  background: #f5f3ff;
  border-left: 3px solid #7c3aed;
  padding-left: 12px;
}

.dd-seyun-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 5px;
}

.dd-seyun-year {
  font-size: 14px;
  font-weight: 800;
  color: #222;
  min-width: 38px;
}

.dd-seyun-age {
  font-size: 12px;
  color: #aaa;
  min-width: 30px;
}

.dd-seyun-ganjhi {
  font-size: 15px;
  font-weight: 700;
  display: flex;
  gap: 2px;
}

.dd-seyun-comment {
  font-size: 13px;
  color: #444;
  line-height: 1.55;
  margin: 0;
}

.acc-screen {
  min-height: 100vh;
  background: #f4f4f8;
  max-width: 480px;
  margin: 0 auto;
}

.acc-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 52px 20px 16px;
  background: #fff;
  border-bottom: 1px solid #f3f4f6;
}

.acc-back {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: #374151;
  padding: 0;
  line-height: 1;
}

.acc-title {
  font-size: 18px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0;
}

/* 비로그인 */
.acc-guest {
  text-align: center;
  padding: 80px 24px;
}

.acc-guest-icon {
  font-size: 56px;
  margin: 0 0 16px;
}

.acc-guest-msg {
  font-size: 16px;
  color: #6b7280;
  line-height: 1.6;
  margin: 0 0 28px;
}

.acc-login-btn {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  border: none;
  border-radius: 14px;
  padding: 16px 32px;
  cursor: pointer;
}

/* 프로필 */
.acc-profile {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px;
  background: #fff;
  margin-bottom: 12px;
}

.acc-avatar {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: #fff;
  font-weight: 700;
  flex-shrink: 0;
}

.acc-name {
  font-size: 16px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 2px;
}

.acc-email {
  font-size: 13px;
  color: #6b7280;
  margin: 0;
}

/* 섹션 */
.acc-section {
  background: #fff;
  margin-bottom: 12px;
  padding: 20px;
}

.acc-section-title {
  font-size: 15px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 16px;
}

.acc-loading,
.acc-empty {
  font-size: 14px;
  color: #9ca3af;
  text-align: center;
  padding: 16px 0;
  margin: 0;
}

.acc-purchase-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.acc-purchase-item {
  display: flex;
  align-items: center;
  gap: 12px;
}

.acc-purchase-icon {
  font-size: 28px;
  flex-shrink: 0;
}

.acc-purchase-info {
  flex: 1;
}

.acc-purchase-name {
  font-size: 15px;
  font-weight: 600;
  color: #1a1a2e;
  margin: 0 0 2px;
}

.acc-purchase-date {
  font-size: 12px;
  color: #9ca3af;
  margin: 0;
}

.acc-purchase-price {
  font-size: 14px;
  font-weight: 700;
  color: #7c3aed;
}

/* 로그아웃 */
.acc-bottom {
  padding: 8px 20px 40px;
}

.acc-signout {
  width: 100%;
  background: #fff;
  border: 1.5px solid #e5e7eb;
  border-radius: 12px;
  padding: 14px;
  font-size: 15px;
  color: #ef4444;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.acc-signout:hover {
  background: #fef2f2;
}

.acc-signout:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.acc-legal-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
}

.acc-legal-btn {
  background: none;
  border: none;
  font-size: 11px;
  color: #9ca3af;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
}

.acc-legal-sep {
  font-size: 11px;
  color: #d1d5db;
}

/* ── 회원탈퇴 ─────────────────────────── */
.acc-delete-link {
  display: block;
  margin: 12px auto 0;
  background: none;
  border: none;
  font-size: 12px;
  color: #9ca3af;
  cursor: pointer;
  text-decoration: underline;
}

.acc-delete-confirm {
  margin-top: 12px;
  padding: 16px;
  border: 1px solid #fecaca;
  border-radius: 12px;
  background: #fef2f2;
}

.acc-delete-warn {
  font-size: 13px;
  line-height: 1.6;
  color: #7f1d1d;
  margin: 0 0 12px;
}

.acc-delete-error {
  font-size: 12px;
  color: #dc2626;
  margin: 0 0 8px;
}

.acc-delete-actions {
  display: flex;
  gap: 8px;
}

.acc-delete-cancel,
.acc-delete-go {
  flex: 1;
  padding: 10px 0;
  border-radius: 10px;
  font-size: 14px;
  cursor: pointer;
}

.acc-delete-cancel {
  border: 1px solid #d1d5db;
  background: #fff;
  color: #374151;
}

.acc-delete-go {
  border: none;
  background: #dc2626;
  color: #fff;
  font-weight: 600;
}

.acc-delete-cancel:disabled,
.acc-delete-go:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

.pr-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: #f4f4f8;
  padding: 24px;
}

.pr-loading {
  text-align: center;
  color: #6b7280;
}

.pr-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #e5e7eb;
  border-top-color: #7c3aed;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 16px;
}

.pr-card {
  background: #fff;
  border-radius: 24px;
  padding: 40px 28px;
  text-align: center;
  width: 100%;
  max-width: 360px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
}

.pr-icon-big {
  font-size: 56px;
  margin: 0 0 16px;
}

.pr-title {
  font-size: 22px;
  font-weight: 800;
  color: #1a1a2e;
  margin: 0 0 10px;
}

.pr-sub {
  font-size: 15px;
  color: #6b7280;
  line-height: 1.6;
  margin: 0 0 28px;
}

.pr-btn {
  width: 100%;
  border: none;
  border-radius: 12px;
  padding: 16px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.15s;
}

.pr-btn:active { opacity: 0.85; }

.pr-btn-main {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
}

.login-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 200;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}

.login-sheet {
  background: #fff;
  border-radius: 24px 24px 0 0;
  width: 100%;
  max-width: 480px;
  padding: 12px 24px 40px;
  animation: slideUp 0.3s ease;
}

.login-handle {
  width: 40px;
  height: 4px;
  background: #e5e7eb;
  border-radius: 2px;
  margin: 0 auto 24px;
}

.login-top {
  text-align: center;
  margin-bottom: 28px;
}

.login-emoji {
  font-size: 40px;
  margin: 0 0 12px;
}

.login-title {
  font-size: 20px;
  font-weight: 700;
  color: #1a1a2e;
  line-height: 1.4;
  margin: 0 0 10px;
}

.login-sub {
  font-size: 14px;
  color: #6b7280;
  line-height: 1.6;
  margin: 0;
}

.login-rewards {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 16px;
}

.login-reward-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  background: #f5f3ff;
  border-radius: 12px;
  padding: 12px 14px;
  min-width: 80px;
}

.login-reward-icon {
  font-size: 22px;
}

.login-reward-text {
  font-size: 11px;
  font-weight: 600;
  color: #7c3aed;
  text-align: center;
}

.login-error {
  background: #fef2f2;
  color: #dc2626;
  font-size: 13px;
  padding: 10px 14px;
  border-radius: 8px;
  margin-bottom: 16px;
  text-align: center;
}

.login-btns {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.login-btn-kakao {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: #FEE500;
  color: #191919;
  font-size: 16px;
  font-weight: 700;
  border: none;
  border-radius: 12px;
  padding: 16px;
  cursor: pointer;
  transition: opacity 0.15s;
}

.login-btn-kakao:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.login-btn-kakao:active {
  opacity: 0.85;
}

.login-kakao-icon {
  width: 22px;
  height: 22px;
}

.login-btn-guest {
  background: none;
  border: 1.5px solid #e5e7eb;
  color: #6b7280;
  font-size: 15px;
  border-radius: 12px;
  padding: 14px;
  cursor: pointer;
  transition: background 0.15s;
}

.login-btn-guest:active {
  background: #f9fafb;
}

.login-notice {
  font-size: 11px;
  color: #9ca3af;
  text-align: center;
  line-height: 1.6;
  margin: 0;
}

.login-notice span {
  text-decoration: underline;
  cursor: pointer;
}

.login-biz-info {
  font-size: 10px;
  color: #c4b5fd;
  text-align: center;
  margin-top: 8px;
}
.legal-screen {
  min-height: 100vh;
  background: #fff;
  max-width: 480px;
  margin: 0 auto;
}

.legal-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 52px 20px 16px;
  background: #fff;
  border-bottom: 1px solid #f3f4f6;
  position: sticky;
  top: 0;
  z-index: 10;
}

.legal-back {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: #374151;
  padding: 0;
  line-height: 1;
}

.legal-title {
  font-size: 18px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0;
}

.legal-body {
  padding: 24px 20px 60px;
  text-align: left;
}

.legal-effective {
  font-size: 12px;
  color: #9ca3af;
  margin: 0 0 24px;
}

.legal-section {
  margin-bottom: 28px;
}

.legal-section-title {
  font-size: 15px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 10px;
  padding-bottom: 6px;
  border-bottom: 1.5px solid #f3f4f6;
}

.legal-section p {
  font-size: 13px;
  color: #4b5563;
  line-height: 1.75;
  margin: 0 0 8px;
}

.legal-section p:last-child {
  margin-bottom: 0;
}

.legal-indent {
  padding-left: 14px;
  font-size: 13px;
  color: #4b5563;
  line-height: 1.75;
  margin: 4px 0;
}

.legal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin: 8px 0;
}

.legal-table th {
  background: #f9fafb;
  padding: 8px 10px;
  text-align: left;
  font-weight: 700;
  color: #374151;
  border: 1px solid #e5e7eb;
}

.legal-table td {
  padding: 8px 10px;
  color: #4b5563;
  border: 1px solid #e5e7eb;
  vertical-align: top;
  line-height: 1.5;
}

.legal-footer {
  margin-top: 32px;
  padding: 16px;
  background: #f9fafb;
}
.pay-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 200;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}

.pay-sheet {
  background: #fff;
  border-radius: 24px 24px 0 0;
  width: 100%;
  max-width: 480px;
  padding: 12px 24px 40px;
  animation: slideUp 0.3s ease;
}

.pay-handle {
  width: 40px;
  height: 4px;
  background: #e5e7eb;
  border-radius: 2px;
  margin: 0 auto 20px;
}

.pay-service-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.pay-service-icon {
  font-size: 36px;
  line-height: 1;
}

.pay-service-name {
  font-size: 17px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 4px;
}

.pay-service-desc {
  font-size: 13px;
  color: #6b7280;
  margin: 0;
}

.pay-divider {
  height: 1px;
  background: #f3f4f6;
  margin-bottom: 20px;
}

.pay-amount-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.pay-amount-label {
  font-size: 15px;
  color: #6b7280;
}

.pay-amount-value {
  font-size: 22px;
  font-weight: 800;
  color: #7c3aed;
}

.pay-info {
  background: #f9fafb;
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 16px;
}

.pay-info p {
  font-size: 12px;
  color: #6b7280;
  margin: 0 0 4px;
  line-height: 1.5;
}

.pay-info p:last-child {
  margin-bottom: 0;
}

.pay-error {
  background: #fef2f2;
  color: #dc2626;
  font-size: 13px;
  padding: 10px 14px;
  border-radius: 8px;
  margin-bottom: 16px;
  text-align: center;
}

/* 카카오페이 버튼 */
.pay-btn-kakao {
  width: 100%;
  background: #FEE500;
  color: #3C1E1E;
  font-size: 17px;
  font-weight: 700;
  border: none;
  border-radius: 14px;
  padding: 18px;
  cursor: pointer;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.pay-btn-kakao:active {
  opacity: 0.85;
}
.fb-bar {
  margin: 8px 0 24px;
  padding: 14px 16px;
  background: #f9fafb;
  border-radius: 14px;
  border: 1px solid #f3f4f6;
}

.fb-vote-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.fb-label {
  font-size: 13px;
  color: #6b7280;
}

.fb-btns {
  display: flex;
  gap: 6px;
  align-items: center;
}

.fb-btn {
  background: #fff;
  border: 1.5px solid #e5e7eb;
  border-radius: 8px;
  width: 36px;
  height: 36px;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.fb-btn:disabled { cursor: default; }

.fb-btn-active {
  background: #ede9fe;
  border-color: #7c3aed;
}

.fb-btn-report {
  font-size: 14px;
}

.fb-sent {
  font-size: 12px;
  color: #10b981;
  font-weight: 600;
}

.fb-thanks {
  font-size: 12px;
  color: #7c3aed;
  margin: 8px 0 0;
  text-align: center;
}

.fb-report-box {
  margin-top: 12px;
}

.fb-report-input {
  width: 100%;
  border: 1.5px solid #e5e7eb;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 13px;
  color: #374151;
  resize: none;
  box-sizing: border-box;
  font-family: inherit;
  line-height: 1.5;
}

.fb-report-input:focus {
  outline: none;
  border-color: #7c3aed;
}

.fb-report-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
  justify-content: flex-end;
}

.fb-report-cancel {
  background: none;
  border: 1.5px solid #e5e7eb;
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 13px;
  color: #6b7280;
  cursor: pointer;
}

.fb-report-send {
  background: #7c3aed;
  border: none;
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  transition: opacity 0.15s;
}

.fb-report-send:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.tab-bar {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 480px;
  background: #fff;
  border-top: 1px solid #ebebeb;
  display: flex;
  z-index: 50;
  padding-bottom: env(safe-area-inset-bottom);
}

.tab-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 10px 0 12px;
  background: none;
  border: none;
  cursor: pointer;
  transition: all 0.15s;
}

.tab-icon {
  font-size: 22px;
  line-height: 1;
  transition: transform 0.15s;
}

.tab-item.active .tab-icon {
  transform: scale(1.15);
}

.tab-label {
  font-size: 10px;
  font-weight: 600;
  color: #bbb;
  letter-spacing: -0.2px;
}

.tab-item.active .tab-label {
  color: #6c5ce7;
}
*, *::before, *::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo',
    'Pretendard', 'Noto Sans KR', sans-serif;
  background: #f4f4f8;
  -webkit-font-smoothing: antialiased;
}

.app {
  min-height: 100vh;
}

/* 임시 홈 화면 */
.placeholder-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  gap: 16px;
  padding: 24px;
  text-align: center;
}

.placeholder-screen h2 {
  font-size: 24px;
  color: #1a1a1a;
  margin: 0;
}

.placeholder-screen p {
  font-size: 15px;
  color: #888;
  margin: 0;
}

.placeholder-screen button {
  margin-top: 8px;
  padding: 12px 24px;
  border: 1.5px solid #6c5ce7;
  border-radius: 10px;
  background: #fff;
  color: #6c5ce7;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

/* ─── 서비스 헤더 타이틀 무게감 강화 ─── */
.analysis-title, .career-title, .luck-title, .gaeun-title,
.wealth-title, .health-title, .compat-title, .dream-title,
.date-title, .ds-title, .dd-title, .mysaju-title {
  font-weight: 800 !important;
  letter-spacing: -0.8px !important;
}

/* ─── 서비스 헤더 공통 뒤로가기 버튼 ─── */
.back-btn {
  background: rgba(255,255,255,0.18) !important;
  border: 1px solid rgba(255,255,255,0.35) !important;
  border-radius: 20px !important;
  padding: 6px 14px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  color: #fff !important;
  cursor: pointer;
  margin-bottom: 14px;
  display: inline-block;
  transition: background 0.15s;
}
.back-btn:active {
  background: rgba(255,255,255,0.3) !important;
}

/* ─── 다시 분석하기 버튼 (전체 서비스 공통) ─── */
.reanalyze-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: calc(100% - 32px);
  margin: 8px 16px 4px;
  padding: 13px;
  border-radius: 12px;
  background: #fff;
  border: 1.5px solid #d1c4e9;
  color: #7c3aed;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.reanalyze-btn:active {
  background: #f5f0ff;
  border-color: #7c3aed;
}
