/* ==========================================================
   Goodysoon 該你順 — Apple-style App Demo v2
   Fork: 真實 App 互動體驗（無左側 nav，iPhone 框架中心）
   Version: v=20260429-v2-1
   ========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+TC:wght@300;400;500;700;900&family=Noto+Sans+TC:wght@300;400;500&family=Inter:wght@300;400;500;600;700&display=swap');

/* ── Design Tokens ── */
:root {
  --ink-900: #0a0a0c;
  --ink-800: #15151a;
  --ink-700: #1f1f26;
  --ink-600: #2a2a34;
  --bg-ink: #0d0e12;
  --bg-ink-soft: #16181d;

  --moon-100: #fafaf7;
  --moon-200: #d4d4d0;
  --moon-300: #a0a098;
  --text-moon: #f5f1e8;
  --text-moon-soft: #d8d2c4;
  --text-moon-mute: #6a6560;

  --gold-500: #c9a66b;
  --gold-400: #e0bc7d;
  --gold-300: #f0d4a0;
  --gold-deep: #8a7440;

  --cyan-500: #6ec1e4;
  --rose-500: #d4827a;
  --sage-500: #93b59a;

  --card-bg: rgba(21, 21, 26, 0.9);
  --card-border: rgba(201, 169, 97, 0.18);
  --card-border-active: rgba(201, 169, 97, 0.45);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);

  /* iPhone dimensions */
  --iphone-w: 375px;
  --iphone-h: 812px;
  --iphone-scale: 1.0;
  --iphone-radius: 56px;
  --iphone-border: 12px;
  --screen-radius: calc(var(--iphone-radius) - var(--iphone-border));
}

/* ── Reset ── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  overflow: hidden;
  background: var(--ink-900);
  color: var(--text-moon);
  font-family: 'Noto Sans TC', 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── Demo Stage ── */
.demo-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100vh;
  width: 100vw;
  gap: 48px;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse 60% 50% at 25% 50%, rgba(201,169,97,0.04) 0%, transparent 60%),
    radial-gradient(ellipse 50% 60% at 75% 50%, rgba(110,193,228,0.03) 0%, transparent 60%),
    var(--ink-900);
}

/* Subtle noise texture overlay */
.demo-stage::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  background-size: 200px 200px;
  opacity: 0.4;
  pointer-events: none;
  z-index: 0;
}

/* ── Stage Left Panel ── */
.stage-left {
  display: flex;
  flex-direction: column;
  gap: 32px;
  min-width: 160px;
  align-items: flex-end;
  position: relative;
  z-index: 1;
}

.brand-mark {
  text-align: right;
}

.brand-logo {
  font-family: 'Noto Serif TC', serif;
  font-weight: 900;
  font-size: 28px;
  letter-spacing: 0.12em;
  color: var(--text-moon);
}

.brand-logo span {
  color: var(--gold-500);
}

.brand-tagline {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--text-moon-mute);
  text-transform: uppercase;
  margin-top: 4px;
}

.stage-desc {
  text-align: right;
}

.desc-line {
  font-size: 12px;
  color: var(--text-moon-mute);
  letter-spacing: 0.05em;
  line-height: 1.8;
}

.stage-hints {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-end;
}

.hint-item {
  font-size: 11px;
  color: var(--text-moon-mute);
  letter-spacing: 0.06em;
  cursor: pointer;
  padding: 3px 8px;
  border-radius: 4px;
  transition: all 0.2s ease;
  border-right: 2px solid transparent;
}

.hint-item:hover {
  color: var(--text-moon-soft);
  border-right-color: var(--gold-500);
}

.hint-item.active {
  color: var(--gold-400);
  border-right-color: var(--gold-500);
}

/* ── Stage Right Panel ── */
.stage-right {
  display: flex;
  flex-direction: column;
  gap: 32px;
  min-width: 160px;
  position: relative;
  z-index: 1;
}

.interaction-guide {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.guide-title {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--text-moon-mute);
  text-transform: uppercase;
}

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

.guide-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.guide-icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-500);
  font-size: 12px;
  flex-shrink: 0;
}

.guide-text {
  font-size: 11px;
  color: var(--text-moon-mute);
  line-height: 1.4;
}

.tech-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  color: var(--text-moon-mute);
  letter-spacing: 0.05em;
}

.tech-badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--sage-500);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* ── iPhone Mockup ── */
.iphone-mockup {
  position: relative;
  z-index: 2;
  flex-shrink: 0;
}

.iphone-shell {
  position: relative;
  width: calc(var(--iphone-w) + var(--iphone-border) * 2);
  height: calc(var(--iphone-h) + var(--iphone-border) * 2);
  background: #000;
  border-radius: var(--iphone-radius);
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.08),
    0 24px 80px rgba(0,0,0,0.8),
    0 8px 24px rgba(0,0,0,0.6),
    inset 0 0 0 1px rgba(255,255,255,0.05);
}

/* Side buttons */
.iphone-btn {
  position: absolute;
  background: #1a1a1a;
  border-radius: 3px;
}

.iphone-btn.vol-up {
  left: -4px;
  top: 140px;
  width: 4px;
  height: 42px;
}

.iphone-btn.vol-down {
  left: -4px;
  top: 196px;
  width: 4px;
  height: 42px;
}

.iphone-btn.power {
  right: -4px;
  top: 168px;
  width: 4px;
  height: 64px;
}

/* Screen area */
.iphone-screen {
  position: absolute;
  top: var(--iphone-border);
  left: var(--iphone-border);
  width: var(--iphone-w);
  height: var(--iphone-h);
  border-radius: var(--screen-radius);
  background: var(--ink-900);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Dynamic Island */
.dynamic-island {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 126px;
  height: 37px;
  background: #000;
  border-radius: 20px;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 16px;
}

.di-camera {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #0a0a10;
  border: 1px solid rgba(255,255,255,0.06);
  box-shadow: inset 0 0 4px rgba(0,0,0,0.8);
}

/* Status Bar */
.status-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 54px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  padding: 0 24px 8px;
  z-index: 90;
  pointer-events: none;
}

.status-time {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 15px;
  color: var(--text-moon);
  letter-spacing: -0.01em;
}

.status-icons {
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-signal {
  display: flex;
  align-items: flex-end;
  gap: 2px;
}

.status-signal span {
  background: var(--text-moon);
  border-radius: 1px;
  width: 3px;
}

.status-signal span:nth-child(1) { height: 4px; }
.status-signal span:nth-child(2) { height: 6px; }
.status-signal span:nth-child(3) { height: 9px; }
.status-signal span:nth-child(4) { height: 12px; }

.status-wifi {
  color: var(--text-moon);
  display: flex;
  align-items: center;
}

.status-battery {
  display: flex;
  align-items: center;
  gap: 1px;
}

.battery-body {
  width: 25px;
  height: 12px;
  border: 1.5px solid var(--text-moon);
  border-radius: 3px;
  padding: 2px;
}

.battery-fill {
  width: 100%;
  height: 100%;
  background: var(--text-moon);
  border-radius: 1px;
}

.battery-tip {
  width: 2px;
  height: 5px;
  background: var(--text-moon);
  border-radius: 0 1px 1px 0;
  opacity: 0.5;
}

/* ── Phone Screen (scrollable content) ── */
.phone-screen {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--ink-900);
  overflow: hidden;
  cursor: default;
  user-select: none;
}

/* Pull hint */
.pull-hint {
  position: absolute;
  top: 60px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 11px;
  color: var(--text-moon-mute);
  letter-spacing: 0.1em;
  z-index: 20;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

/* Push Notification */
.push-notification {
  position: absolute;
  top: 8px;
  left: 12px;
  right: 12px;
  z-index: 200;
  transform: translateY(-120%);
  pointer-events: none;
}

.push-inner {
  background: rgba(30, 30, 36, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 16px;
  padding: 14px 16px 16px;
  border: 1px solid rgba(201,169,97,0.2);
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
}

.push-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.push-app-icon {
  width: 24px;
  height: 24px;
  background: var(--gold-500);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--ink-900);
}

.push-app-name {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-moon-soft);
  flex: 1;
}

.push-time {
  font-size: 11px;
  color: var(--text-moon-mute);
}

.push-title {
  font-family: 'Noto Serif TC', serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-moon);
  margin-bottom: 4px;
  letter-spacing: 0.02em;
}

.push-body {
  font-size: 13px;
  color: var(--gold-400);
  margin-bottom: 2px;
  letter-spacing: 0.02em;
}

.push-action {
  font-size: 13px;
  color: var(--text-moon-soft);
  letter-spacing: 0.02em;
}

/* ── View System ── */
.view {
  position: absolute;
  inset: 0;
  background: var(--ink-900);
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transform: translateX(0);
  will-change: transform, opacity;
  z-index: 1;
}

.view.active {
  opacity: 1;
  pointer-events: all;
  z-index: 2;
}

/* Tappable feedback */
.tappable {
  transition: transform 0.15s ease, opacity 0.15s ease;
  cursor: pointer;
}

.tappable:active {
  transform: scale(0.96);
  opacity: 0.85;
}

/* ── View Header ── */
.view-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  padding: 0 20px 14px;
  background: var(--ink-900);
  z-index: 10;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

.view-back-btn {
  background: none;
  border: none;
  color: var(--cyan-500);
  font-size: 18px;
  cursor: pointer;
  padding: 4px 8px 4px 0;
  font-family: 'Inter', sans-serif;
}

.view-title {
  font-family: 'Noto Serif TC', serif;
  font-size: 17px;
  font-weight: 600;
  color: var(--text-moon);
  letter-spacing: 0.04em;
}

.view-more-btn {
  background: none;
  border: none;
  color: var(--cyan-500);
  font-size: 14px;
  cursor: pointer;
  min-width: 40px;
  text-align: right;
  font-family: 'Inter', sans-serif;
}

/* ── HOME VIEW ── */
#view-home {
  padding-top: 54px;
  padding-bottom: 90px;
}

.home-scroll {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 16px 20px 0;
  scrollbar-width: none;
}

.home-scroll::-webkit-scrollbar {
  display: none;
}

.home-hero {
  margin-bottom: 16px;
  margin-top: 4px;
}

.home-greeting {
  font-family: 'Noto Serif TC', serif;
  font-size: 22px;
  font-weight: 500;
  color: var(--text-moon);
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.home-date {
  font-size: 12px;
  color: var(--text-moon-mute);
  letter-spacing: 0.06em;
}

/* Lucky card small */
.home-top-row {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 12px;
}

.home-lucky-card {
  background: rgba(201,169,97,0.08);
  border: 1px solid rgba(201,169,97,0.25);
  border-radius: 12px;
  padding: 10px 14px;
  min-width: 120px;
}

.lucky-mini-label {
  font-size: 10px;
  color: var(--text-moon-mute);
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

.lucky-mini-nums {
  font-family: 'Inter', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--gold-400);
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.lucky-mini-color {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 10px;
  color: var(--text-moon-mute);
}

.lucky-color-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-400), var(--gold-500));
  flex-shrink: 0;
}

/* Decision Card */
.decision-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 20px;
  padding: 20px;
  margin-bottom: 14px;
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.decision-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(201,169,97,0.3), transparent);
}

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

.decision-date-tag {
  font-size: 11px;
  color: var(--text-moon-mute);
  letter-spacing: 0.1em;
}

.decision-expand-icon {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1px solid rgba(201,169,97,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--gold-400);
  transition: transform 0.3s ease;
}

.decision-sentence {
  font-family: 'Noto Serif TC', serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-moon);
  letter-spacing: 0.04em;
  line-height: 1.4;
  margin-bottom: 14px;
}

.decision-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.detail-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.detail-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  margin-top: 5px;
  flex-shrink: 0;
}

.detail-dot.avoid {
  background: var(--rose-500);
}

.detail-dot.suggest {
  background: var(--sage-500);
}

.detail-text {
  font-size: 13px;
  color: var(--text-moon-soft);
  line-height: 1.5;
  letter-spacing: 0.02em;
}

.detail-label-avoid {
  color: var(--rose-500);
  font-weight: 500;
  margin-right: 4px;
}

.detail-label-suggest {
  color: var(--sage-500);
  font-weight: 500;
  margin-right: 4px;
}

/* Decision expanded area */
.decision-expanded {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s var(--ease-out);
}

.decision-card.expanded .decision-expanded {
  max-height: 300px;
}

.decision-card.expanded .decision-expand-icon {
  transform: rotate(45deg);
}

.expanded-divider {
  height: 1px;
  background: rgba(201,169,97,0.15);
  margin: 14px 0;
}

.expanded-row {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
  padding-left: 4px;
  border-left: 3px solid var(--cyan-500);
}

.expanded-tag {
  font-size: 10px;
  color: var(--cyan-500);
  letter-spacing: 0.1em;
  min-width: 28px;
  padding-top: 2px;
}

.expanded-text {
  font-size: 12px;
  color: var(--text-moon-soft);
  line-height: 1.5;
  letter-spacing: 0.02em;
}

.expanded-cta {
  margin-top: 14px;
}

.btn-full-reading {
  background: rgba(201,169,97,0.1);
  border: 1px solid rgba(201,169,97,0.35);
  color: var(--gold-400);
  font-size: 13px;
  font-family: 'Noto Sans TC', sans-serif;
  letter-spacing: 0.05em;
  padding: 10px 16px;
  border-radius: 10px;
  cursor: pointer;
  width: 100%;
}

/* Home Chat Input */
.home-chat-input {
  background: rgba(110,193,228,0.06);
  border: 1px solid rgba(110,193,228,0.2);
  border-radius: 16px;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.chat-input-icon {
  color: var(--cyan-500);
  font-size: 16px;
  flex-shrink: 0;
}

.chat-input-placeholder {
  flex: 1;
  font-size: 14px;
  color: var(--text-moon-mute);
  letter-spacing: 0.04em;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.chat-input-send {
  color: var(--cyan-500);
  font-size: 14px;
  flex-shrink: 0;
}

/* ── CHAT VIEW ── */
#view-chat {
  padding-top: 100px;
  padding-bottom: 74px;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 16px 16px 8px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scrollbar-width: none;
}

.chat-messages::-webkit-scrollbar {
  display: none;
}

/* User bubble */
.msg-user {
  display: flex;
  justify-content: flex-end;
  opacity: 0;
}

.msg-user-bubble {
  background: var(--cyan-500);
  color: var(--ink-900);
  font-size: 14px;
  font-weight: 500;
  padding: 10px 14px;
  border-radius: 18px 18px 4px 18px;
  max-width: 75%;
  letter-spacing: 0.02em;
  line-height: 1.4;
}

/* AI thinking dots */
.msg-ai-thinking {
  display: flex;
  align-items: center;
  opacity: 0;
}

.thinking-dots {
  display: flex;
  gap: 4px;
  background: var(--ink-700);
  padding: 10px 14px;
  border-radius: 18px 18px 18px 4px;
}

.thinking-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-moon-mute);
  animation: thinking-pulse 1.4s ease-in-out infinite;
}

.thinking-dot:nth-child(1) { animation-delay: 0s; }
.thinking-dot:nth-child(2) { animation-delay: 0.2s; }
.thinking-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes thinking-pulse {
  0%, 80%, 100% { transform: scale(1); opacity: 0.4; }
  40% { transform: scale(1.2); opacity: 1; }
}

/* Source chips */
.msg-sources {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  opacity: 0;
  padding: 0 2px;
}

.source-chip {
  display: flex;
  align-items: center;
  gap: 5px;
  background: var(--ink-700);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 10px;
  padding: 6px 10px;
  opacity: 0;
}

.source-chip-icon {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
}

.source-chip-icon.bzb {
  background: rgba(201,169,97,0.2);
  color: var(--gold-400);
}

.source-chip-icon.zw {
  background: rgba(147,181,154,0.2);
  color: var(--sage-500);
}

.source-chip-icon.tarot {
  background: rgba(212,130,122,0.2);
  color: var(--rose-500);
}

.source-chip-icon.lucky {
  background: rgba(110,193,228,0.2);
  color: var(--cyan-500);
}

.source-chip-label {
  font-size: 11px;
  color: var(--text-moon-mute);
  letter-spacing: 0.04em;
}

/* AI bubble */
.msg-ai {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  opacity: 0;
}

.msg-ai-icon {
  width: 28px;
  height: 28px;
  background: var(--gold-500);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: var(--ink-900);
  flex-shrink: 0;
  margin-top: 2px;
}

.msg-ai-bubble {
  background: var(--ink-700);
  border-radius: 18px 18px 18px 4px;
  border-left: 3px solid var(--gold-500);
  padding: 12px 14px;
  max-width: 82%;
}

.msg-ai-text {
  font-size: 13px;
  color: var(--text-moon-soft);
  line-height: 1.6;
  letter-spacing: 0.02em;
  margin-bottom: 10px;
  min-height: 40px;
}

.msg-ai-action {
  margin-top: 4px;
}

/* Chat input bar */
.chat-input-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 74px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px 8px;
  background: var(--ink-900);
  border-top: 1px solid rgba(255,255,255,0.04);
}

.chat-bar-input {
  flex: 1;
  background: var(--ink-700);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 22px;
  padding: 10px 16px;
  color: var(--text-moon-mute);
  font-size: 14px;
  font-family: 'Noto Sans TC', sans-serif;
  outline: none;
}

.chat-bar-send {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--cyan-500);
  border: none;
  color: var(--ink-900);
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ── FUSION VIEW ── */
#view-fusion {
  padding-top: 100px;
  padding-bottom: 20px;
}

.fusion-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 16px 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  scrollbar-width: none;
}

.fusion-content::-webkit-scrollbar {
  display: none;
}

/* 5 source cards */
.fusion-sources {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.fusion-src-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 12px 14px;
  opacity: 0;
  transform: translateY(20px);
}

.fusion-src-card:last-child {
  grid-column: 1 / -1;
}

.fsrc-tag {
  font-size: 10px;
  color: var(--gold-500);
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

.fsrc-title {
  font-family: 'Noto Serif TC', serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-moon);
  margin-bottom: 4px;
  letter-spacing: 0.02em;
}

.fsrc-text {
  font-size: 11px;
  color: var(--text-moon-mute);
  letter-spacing: 0.02em;
  line-height: 1.4;
}

/* Fusion orb */
.fusion-orb-area {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 0;
}

.fusion-orb {
  position: relative;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: scale(0);
}

.fusion-orb-inner {
  width: 60px;
  height: 60px;
  background: radial-gradient(ellipse at 35% 35%, var(--gold-300), var(--gold-500) 40%, var(--gold-deep) 80%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: var(--ink-900);
  box-shadow:
    0 0 20px rgba(201,169,97,0.4),
    0 0 40px rgba(201,169,97,0.2);
  position: relative;
  z-index: 2;
  animation: orb-breathe 2.5s ease-in-out infinite;
}

@keyframes orb-breathe {
  0%, 100% { box-shadow: 0 0 20px rgba(201,169,97,0.4), 0 0 40px rgba(201,169,97,0.2); }
  50% { box-shadow: 0 0 30px rgba(201,169,97,0.6), 0 0 60px rgba(201,169,97,0.3); }
}

.fusion-orb-ring1,
.fusion-orb-ring2 {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(201,169,97,0.3);
  animation: ring-expand 2.5s ease-in-out infinite;
}

.fusion-orb-ring1 {
  width: 75px;
  height: 75px;
  animation-delay: 0s;
}

.fusion-orb-ring2 {
  width: 90px;
  height: 90px;
  animation-delay: 0.5s;
}

@keyframes ring-expand {
  0%, 100% { opacity: 0.5; transform: scale(1); }
  50% { opacity: 0.8; transform: scale(1.05); }
}

/* Fusion result cards */
.fusion-results {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.result-card {
  background: var(--card-bg);
  border-radius: 14px;
  padding: 14px 16px;
  opacity: 0;
  transform: translateY(10px);
  border-left: 3px solid transparent;
}

.result-card.warn {
  border-left-color: var(--rose-500);
}

.result-card.main {
  border-left-color: var(--gold-500);
}

.result-card.action {
  border-left-color: var(--sage-500);
}

.result-card-tag {
  font-size: 10px;
  letter-spacing: 0.12em;
  margin-bottom: 5px;
}

.warn-tag { color: var(--rose-500); }
.main-tag { color: var(--gold-400); }
.act-tag { color: var(--sage-500); }

.result-card-text {
  font-size: 13px;
  color: var(--text-moon-soft);
  line-height: 1.6;
  letter-spacing: 0.02em;
  min-height: 20px;
}

/* Fusion share row */
.fusion-share-row {
  padding: 0 4px;
}

.btn-share-card {
  width: 100%;
  background: rgba(201,169,97,0.06);
  border: 1px solid rgba(201,169,97,0.25);
  color: var(--gold-400);
  font-size: 13px;
  font-family: 'Noto Sans TC', sans-serif;
  letter-spacing: 0.06em;
  padding: 12px;
  border-radius: 12px;
  cursor: pointer;
}

/* Share modal */
.fusion-share-modal {
  position: absolute;
  inset: 0;
  z-index: 50;
  display: none;
  pointer-events: none;
}

.fusion-share-modal.visible {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  pointer-events: all;
}

.share-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10,10,12,0.7);
  backdrop-filter: blur(4px);
}

.share-modal-sheet {
  position: relative;
  z-index: 1;
  background: var(--ink-800);
  border-radius: 24px 24px 0 0;
  padding: 20px 20px 32px;
  transform: translateY(100%);
}

.share-modal-handle {
  width: 36px;
  height: 4px;
  background: rgba(255,255,255,0.15);
  border-radius: 2px;
  margin: 0 auto 20px;
}

.share-modal-title {
  font-family: 'Noto Serif TC', serif;
  font-size: 17px;
  font-weight: 600;
  color: var(--text-moon);
  text-align: center;
  margin-bottom: 16px;
  letter-spacing: 0.04em;
}

.share-preview-card {
  background: var(--ink-900);
  border-radius: 14px;
  border: 1px solid var(--card-border);
  padding: 16px;
  margin-bottom: 16px;
  text-align: center;
}

.share-card-brand {
  font-size: 13px;
  color: var(--gold-400);
  margin-bottom: 10px;
  letter-spacing: 0.08em;
}

.share-card-text {
  font-family: 'Noto Serif TC', serif;
  font-size: 13px;
  color: var(--text-moon-soft);
  line-height: 1.6;
  margin-bottom: 10px;
  letter-spacing: 0.02em;
}

.share-card-user {
  font-size: 11px;
  color: var(--text-moon-mute);
  letter-spacing: 0.06em;
}

.share-btns-row {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.share-btn {
  flex: 1;
  background: var(--ink-700);
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--text-moon-soft);
  font-size: 12px;
  font-family: 'Noto Sans TC', sans-serif;
  padding: 10px 6px;
  border-radius: 10px;
  cursor: pointer;
  letter-spacing: 0.04em;
}

.share-modal-close {
  width: 100%;
  background: none;
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--text-moon-mute);
  font-size: 14px;
  font-family: 'Noto Sans TC', sans-serif;
  padding: 12px;
  border-radius: 12px;
  cursor: pointer;
}

/* ── TAROT VIEW ── */
#view-tarot {
  padding-top: 100px;
  padding-bottom: 20px;
}

.tarot-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 16px 16px 20px;
  scrollbar-width: none;
}

.tarot-content::-webkit-scrollbar {
  display: none;
}

.tarot-step {
  display: none;
}

.tarot-step.active {
  display: block;
}

.tarot-step-label {
  font-size: 12px;
  color: var(--text-moon-mute);
  letter-spacing: 0.1em;
  margin-bottom: 12px;
}

.tarot-qtype-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}

.tarot-qtype {
  background: var(--ink-700);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 12px;
  padding: 12px 4px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tarot-qtype.active {
  background: rgba(201,169,97,0.12);
  border-color: rgba(201,169,97,0.4);
}

.qtype-icon {
  font-size: 18px;
  margin-bottom: 4px;
  color: var(--text-moon-soft);
}

.tarot-qtype.active .qtype-icon {
  color: var(--gold-400);
}

.qtype-name {
  font-size: 11px;
  color: var(--text-moon-mute);
  letter-spacing: 0.05em;
}

.tarot-qtype.active .qtype-name {
  color: var(--gold-400);
}

.tarot-spread-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 20px;
}

.tarot-spread {
  background: var(--ink-700);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 12px;
  padding: 14px 8px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tarot-spread.active {
  background: rgba(201,169,97,0.12);
  border-color: rgba(201,169,97,0.4);
}

.tarot-spread.locked {
  opacity: 0.4;
  cursor: not-allowed;
}

.spread-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-moon-soft);
  margin-bottom: 4px;
  letter-spacing: 0.02em;
}

.tarot-spread.active .spread-name {
  color: var(--gold-400);
}

.spread-sub {
  font-size: 10px;
  color: var(--text-moon-mute);
  letter-spacing: 0.04em;
}

.btn-start-shuffle {
  width: 100%;
  background: linear-gradient(135deg, rgba(201,169,97,0.2), rgba(201,169,97,0.1));
  border: 1px solid rgba(201,169,97,0.4);
  color: var(--gold-400);
  font-size: 15px;
  font-family: 'Noto Serif TC', serif;
  letter-spacing: 0.1em;
  padding: 14px;
  border-radius: 14px;
  cursor: pointer;
  font-weight: 500;
}

/* Shuffle step */
.shuffle-instruction {
  font-family: 'Noto Serif TC', serif;
  font-size: 14px;
  color: var(--text-moon-mute);
  letter-spacing: 0.1em;
  text-align: center;
  margin-bottom: 30px;
  margin-top: 10px;
}

.card-deck {
  position: relative;
  width: 80px;
  height: 120px;
  margin: 0 auto 24px;
}

.deck-card {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 70px;
  height: 110px;
  background: linear-gradient(145deg, var(--ink-600), var(--ink-700));
  border: 1px solid rgba(201,169,97,0.3);
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.shuffle-status {
  text-align: center;
  font-size: 12px;
  color: var(--text-moon-mute);
  letter-spacing: 0.1em;
}

/* Tarot result step */
.tarot-cards-row {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}

.tarot-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.tarot-card-inner {
  width: 80px;
  height: 128px;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.8s ease;
  will-change: transform;
}

.tarot-card-back,
.tarot-card-front {
  position: absolute;
  inset: 0;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.tarot-card-back {
  background: linear-gradient(145deg, var(--ink-600), var(--ink-700));
  border: 1px solid rgba(201,169,97,0.3);
  font-size: 24px;
  color: var(--gold-500);
}

.tarot-card-front {
  background: linear-gradient(145deg, var(--ink-700), var(--ink-800));
  border: 1px solid rgba(255,255,255,0.08);
  transform: rotateY(180deg);
  gap: 4px;
  padding: 8px;
}

.card-symbol {
  font-size: 22px;
  line-height: 1;
}

.card-name {
  font-family: 'Noto Serif TC', serif;
  font-size: 11px;
  color: var(--text-moon);
  letter-spacing: 0.06em;
  text-align: center;
}

.card-pos {
  font-size: 10px;
  letter-spacing: 0.04em;
}

.card-pos.positive {
  color: var(--sage-500);
}

.card-pos.reversed {
  color: var(--rose-500);
}

.tarot-card-timing {
  font-size: 10px;
  color: var(--text-moon-mute);
  letter-spacing: 0.08em;
}

/* Tarot synthesis */
.tarot-synthesis {
  background: var(--ink-700);
  border-radius: 14px;
  border-left: 3px solid var(--gold-500);
  padding: 14px 16px;
  margin-bottom: 16px;
  opacity: 0;
}

.synthesis-tag {
  font-size: 10px;
  color: var(--gold-400);
  letter-spacing: 0.1em;
  margin-bottom: 6px;
}

.synthesis-text {
  font-size: 13px;
  color: var(--text-moon-soft);
  line-height: 1.6;
  letter-spacing: 0.02em;
  min-height: 40px;
}

.btn-tarot-again {
  width: 100%;
  background: none;
  border: 1px solid rgba(255,255,255,0.1);
  color: var(--text-moon-mute);
  font-size: 13px;
  font-family: 'Noto Sans TC', sans-serif;
  padding: 12px;
  border-radius: 12px;
  cursor: pointer;
  letter-spacing: 0.06em;
}

/* ── LUCKY VIEW ── */
#view-lucky {
  padding-top: 100px;
  padding-bottom: 20px;
}

.lucky-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 16px 16px 20px;
  scrollbar-width: none;
}

.lucky-content::-webkit-scrollbar {
  display: none;
}

.lucky-main-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 20px;
  padding: 20px;
  margin-bottom: 16px;
  text-align: center;
}

.lucky-main-date {
  font-size: 11px;
  color: var(--text-moon-mute);
  letter-spacing: 0.1em;
  margin-bottom: 12px;
}

.lucky-big-nums {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 14px;
}

.lucky-big-num {
  font-family: 'Inter', sans-serif;
  font-size: 48px;
  font-weight: 700;
  color: var(--gold-400);
  letter-spacing: -0.02em;
  line-height: 1;
}

.lucky-sep {
  font-family: 'Inter', sans-serif;
  font-size: 28px;
  color: var(--text-moon-mute);
  font-weight: 300;
}

.lucky-color-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.lucky-color-swatch {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-300), var(--gold-500));
}

.lucky-color-text {
  font-size: 12px;
  color: var(--text-moon-mute);
  letter-spacing: 0.06em;
}

.lucky-scene-label {
  font-size: 12px;
  color: var(--text-moon-mute);
  letter-spacing: 0.1em;
  margin-bottom: 10px;
}

.lucky-scene-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.lucky-scene-chip {
  padding: 7px 12px;
  background: var(--ink-700);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 20px;
  font-size: 12px;
  color: var(--text-moon-mute);
  cursor: pointer;
  letter-spacing: 0.04em;
  transition: all 0.2s ease;
}

.lucky-scene-chip.active {
  background: rgba(201,169,97,0.12);
  border-color: rgba(201,169,97,0.4);
  color: var(--gold-400);
}

.lucky-result {
  background: var(--card-bg);
  border-radius: 16px;
  padding: 16px;
}

.lucky-result-title {
  font-family: 'Noto Serif TC', serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-moon);
  margin-bottom: 12px;
  letter-spacing: 0.04em;
}

.lucky-candidates {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 12px;
}

.lucky-candidate {
  position: relative;
  background: var(--ink-700);
  border-radius: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(255,255,255,0.04);
}

.lucky-candidate.recommended {
  border-color: rgba(201,169,97,0.3);
  background: rgba(201,169,97,0.06);
}

.lc-num {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-moon);
  margin-bottom: 6px;
  letter-spacing: 0.02em;
}

.lucky-candidate.recommended .lc-num {
  color: var(--gold-400);
}

.lc-bar {
  height: 4px;
  background: rgba(255,255,255,0.06);
  border-radius: 2px;
  margin-bottom: 4px;
  overflow: hidden;
}

.lc-fill {
  height: 100%;
  width: 0;
  border-radius: 2px;
  transition: none;
}

.lc-score {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  color: var(--text-moon-mute);
}

.lc-badge {
  position: absolute;
  top: 8px;
  right: 10px;
  background: var(--gold-500);
  color: var(--ink-900);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 10px;
  letter-spacing: 0.04em;
}

.lucky-explain {
  border-left: 3px solid var(--cyan-500);
  padding: 8px 10px;
  background: rgba(110,193,228,0.05);
  border-radius: 0 8px 8px 0;
}

.lucky-explain-text {
  font-size: 12px;
  color: var(--text-moon-mute);
  line-height: 1.6;
  letter-spacing: 0.02em;
}

/* ── SUBSCRIBE VIEW ── */
#view-subscribe {
  padding-top: 100px;
  padding-bottom: 20px;
}

.subscribe-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 16px 14px 20px;
  scrollbar-width: none;
}

.subscribe-content::-webkit-scrollbar {
  display: none;
}

.subscribe-hero {
  text-align: center;
  margin-bottom: 20px;
}

.subscribe-hero-text {
  font-family: 'Noto Serif TC', serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-moon);
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}

.subscribe-hero-sub {
  font-size: 12px;
  color: var(--text-moon-mute);
  letter-spacing: 0.06em;
}

.plan-cards {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.plan-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 16px;
  position: relative;
  overflow: visible;
}

.plan-card.featured {
  border-color: var(--card-border-active);
  background: rgba(22,24,29,0.95);
}

.plan-card.featured::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(201,169,97,0.3), transparent 50%, rgba(110,193,228,0.15));
  z-index: -1;
  pointer-events: none;
}

.plan-badge {
  display: inline-block;
  font-size: 10px;
  color: var(--cyan-500);
  border: 1px solid rgba(110,193,228,0.3);
  padding: 2px 8px;
  border-radius: 10px;
  letter-spacing: 0.06em;
  margin-bottom: 8px;
}

.plan-ribbon {
  position: absolute;
  top: -1px;
  right: 16px;
  background: var(--gold-500);
  color: var(--ink-900);
  font-size: 10px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 0 0 10px 10px;
  letter-spacing: 0.06em;
}

.plan-name {
  font-family: 'Noto Serif TC', serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-moon);
  margin-bottom: 6px;
  letter-spacing: 0.04em;
}

.plan-price {
  font-family: 'Inter', sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--text-moon);
  margin-bottom: 4px;
}

.plan-price span {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-moon-mute);
}

.plan-save {
  font-size: 11px;
  color: var(--sage-500);
  letter-spacing: 0.04em;
  margin-bottom: 10px;
  min-height: 16px;
}

.plan-features {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 14px;
}

.plan-feature {
  font-size: 12px;
  color: var(--text-moon-soft);
  letter-spacing: 0.02em;
  padding-left: 12px;
  position: relative;
}

.plan-feature::before {
  content: '·';
  position: absolute;
  left: 2px;
  color: var(--gold-500);
}

.btn-plan {
  width: 100%;
  background: var(--ink-700);
  border: 1px solid rgba(255,255,255,0.1);
  color: var(--text-moon-soft);
  font-size: 13px;
  font-family: 'Noto Sans TC', sans-serif;
  padding: 12px;
  border-radius: 12px;
  cursor: pointer;
  letter-spacing: 0.06em;
}

.btn-plan.gold {
  background: linear-gradient(135deg, var(--gold-500), var(--gold-400));
  border-color: transparent;
  color: var(--ink-900);
  font-weight: 600;
}

/* Payment Modal */
.payment-overlay {
  position: absolute;
  inset: 0;
  z-index: 100;
  display: none;
  pointer-events: none;
}

.payment-overlay.visible {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  pointer-events: all;
}

.payment-overlay::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(10,10,12,0.7);
  backdrop-filter: blur(4px);
}

.payment-sheet {
  position: relative;
  z-index: 1;
  background: var(--ink-800);
  border-radius: 24px 24px 0 0;
  padding: 20px 20px 36px;
  transform: translateY(100%);
}

.payment-handle {
  width: 36px;
  height: 4px;
  background: rgba(255,255,255,0.15);
  border-radius: 2px;
  margin: 0 auto 20px;
}

.payment-title {
  font-family: 'Noto Serif TC', serif;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-moon);
  margin-bottom: 16px;
  letter-spacing: 0.04em;
}

.payment-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--ink-700);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 14px;
}

.payment-plan-name {
  font-size: 14px;
  color: var(--text-moon-soft);
  letter-spacing: 0.04em;
}

.payment-amount {
  font-family: 'Inter', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--gold-400);
}

.payment-methods {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.payment-method {
  flex: 1;
  background: var(--ink-700);
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--text-moon-mute);
  font-size: 11px;
  font-family: 'Noto Sans TC', sans-serif;
  padding: 9px 4px;
  border-radius: 10px;
  cursor: pointer;
  text-align: center;
}

.payment-method.active {
  border-color: rgba(201,169,97,0.4);
  color: var(--gold-400);
  background: rgba(201,169,97,0.08);
}

.card-number-input {
  width: 100%;
  background: var(--ink-700);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 13px 16px;
  color: var(--text-moon);
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  letter-spacing: 0.15em;
  margin-bottom: 14px;
  outline: none;
}

.btn-confirm-pay {
  width: 100%;
  background: linear-gradient(135deg, var(--gold-500), var(--gold-400));
  border: none;
  color: var(--ink-900);
  font-size: 15px;
  font-family: 'Noto Serif TC', serif;
  font-weight: 700;
  padding: 15px;
  border-radius: 14px;
  cursor: pointer;
  letter-spacing: 0.06em;
}

/* Payment success */
.payment-success {
  position: absolute;
  inset: 0;
  background: var(--ink-800);
  border-radius: 24px 24px 0 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  opacity: 0;
  pointer-events: none;
  padding-bottom: 20px;
}

.success-circle {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--sage-500);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: var(--ink-900);
  font-weight: 700;
  transform: scale(0);
}

.success-msg {
  font-family: 'Noto Serif TC', serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-moon);
  letter-spacing: 0.06em;
}

.success-sub {
  font-size: 13px;
  color: var(--text-moon-mute);
  letter-spacing: 0.06em;
}

/* ── PROFILE VIEW ── */
#view-profile {
  padding-top: 100px;
  padding-bottom: 20px;
}

.profile-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 0 16px 20px;
  scrollbar-width: none;
}

.profile-content::-webkit-scrollbar {
  display: none;
}

.profile-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px 0 24px;
  gap: 8px;
}

.profile-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-500), var(--gold-deep));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Noto Serif TC', serif;
  font-size: 28px;
  font-weight: 700;
  color: var(--ink-900);
  margin-bottom: 4px;
}

.profile-name {
  font-family: 'Noto Serif TC', serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--text-moon);
  letter-spacing: 0.06em;
}

.profile-sub {
  font-size: 12px;
  color: var(--text-moon-mute);
  letter-spacing: 0.06em;
}

.profile-section {
  margin-bottom: 20px;
}

.profile-section-title {
  font-size: 11px;
  color: var(--text-moon-mute);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
  padding-left: 4px;
}

.profile-info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: var(--ink-800);
  border-radius: 10px;
  margin-bottom: 4px;
}

.profile-info-label {
  font-size: 13px;
  color: var(--text-moon-mute);
  letter-spacing: 0.04em;
}

.profile-info-value {
  font-size: 13px;
  color: var(--text-moon-soft);
  letter-spacing: 0.02em;
}

.profile-sub-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--ink-800);
  border-radius: 14px;
  padding: 14px 16px;
  border: 1px solid rgba(201,169,97,0.15);
}

.sub-status-plan {
  font-size: 14px;
  color: var(--text-moon-soft);
  font-weight: 500;
  letter-spacing: 0.04em;
  margin-bottom: 2px;
}

.sub-status-days {
  font-size: 12px;
  color: var(--rose-500);
  letter-spacing: 0.04em;
}

.profile-upgrade-btn {
  background: linear-gradient(135deg, rgba(201,169,97,0.2), rgba(201,169,97,0.1));
  border: 1px solid rgba(201,169,97,0.4);
  color: var(--gold-400);
  font-size: 13px;
  font-family: 'Noto Sans TC', sans-serif;
  padding: 10px 16px;
  border-radius: 12px;
  cursor: pointer;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.profile-setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: var(--ink-800);
  border-radius: 10px;
  margin-bottom: 4px;
  cursor: pointer;
}

.setting-label {
  font-size: 13px;
  color: var(--text-moon-soft);
  letter-spacing: 0.04em;
}

.setting-arrow {
  font-size: 16px;
  color: var(--text-moon-mute);
}

.logout-row {
  margin-top: 8px;
}

.logout-label {
  color: var(--rose-500);
}

/* ── Tab Bar ── */
.tab-bar {
  position: absolute;
  bottom: 30px;
  left: 0;
  right: 0;
  height: 60px;
  background: rgba(15,15,18,0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 8px;
  z-index: 50;
}

.tab-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 6px 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tab-item.active .tab-icon {
  color: var(--gold-400);
}

.tab-item.active .tab-label {
  color: var(--gold-400);
}

.tab-icon {
  font-size: 20px;
  color: var(--text-moon-mute);
  line-height: 1;
  transition: color 0.2s ease;
}

.tab-label {
  font-size: 10px;
  color: var(--text-moon-mute);
  letter-spacing: 0.04em;
  transition: color 0.2s ease;
}

.tab-fab {
  margin-top: -20px;
}

.fab-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-400), var(--gold-500));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: var(--ink-900);
  font-weight: 700;
  box-shadow: 0 4px 16px rgba(201,169,97,0.35);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tab-fab.fab-open .fab-circle {
  transform: rotate(45deg);
  box-shadow: 0 4px 24px rgba(201,169,97,0.5);
}

/* FAB Menu */
.fab-menu {
  position: absolute;
  inset: 0;
  z-index: 80;
  display: none;
  pointer-events: none;
}

.fab-menu.visible {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding-bottom: 100px;
  align-items: center;
  pointer-events: all;
}

.fab-menu-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10,10,12,0.6);
  backdrop-filter: blur(8px);
}

.fab-menu-items {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
}

.fab-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(21,21,26,0.9);
  border: 1px solid rgba(201,169,97,0.2);
  border-radius: 14px;
  padding: 12px 20px;
  min-width: 160px;
  cursor: pointer;
  opacity: 0;
  transform: translateY(20px) scale(0.9);
}

.fab-item-icon {
  font-size: 20px;
  color: var(--gold-400);
}

.fab-item-label {
  font-size: 14px;
  color: var(--text-moon-soft);
  letter-spacing: 0.04em;
}

/* Home Indicator */
.home-indicator {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 140px;
  height: 5px;
  background: rgba(255,255,255,0.3);
  border-radius: 3px;
  z-index: 200;
}

/* ── Responsive scaling for smaller screens ── */
@media (max-height: 900px) {
  :root {
    --iphone-scale: 0.88;
  }
  .iphone-shell {
    transform: scale(0.88);
    transform-origin: center center;
  }
}

@media (max-height: 780px) {
  .iphone-shell {
    transform: scale(0.75);
    transform-origin: center center;
  }
  .stage-left,
  .stage-right {
    display: none;
  }
}
