:root {
  color-scheme: light;
  --ink: #35252c;
  --muted: #826c76;
  --faint: #fff7fa;
  --panel: rgba(255, 255, 255, 0.74);
  --panel-strong: rgba(255, 255, 255, 0.92);
  --line: rgba(135, 83, 105, 0.18);
  --rose: #ff5f93;
  --rose-deep: #d92f69;
  --blush: #ffd5e4;
  --peach: #ffb59c;
  --wine: #6e2744;
  --lavender: #eee0ff;
  --shadow: 0 28px 90px rgba(116, 44, 75, 0.18);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 12% 8%, rgba(255, 163, 193, 0.72), transparent 28%),
    radial-gradient(circle at 86% 16%, rgba(255, 198, 174, 0.76), transparent 30%),
    radial-gradient(circle at 72% 82%, rgba(238, 224, 255, 0.78), transparent 34%),
    linear-gradient(135deg, #fff7fa 0%, #ffe8ef 46%, #fff2e9 100%);
  color: var(--ink);
  font-family:
    Inter, "PingFang SC", "Microsoft YaHei", "Noto Sans SC", Arial, sans-serif;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.22) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.2) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.55), transparent 72%);
  content: "";
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(255, 95, 147, 0.35);
  outline-offset: 2px;
}

.page-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 18px 0 56px;
}

.hero-stage {
  position: relative;
  min-height: calc(100vh - 104px);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 32px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.48)),
    rgba(255, 246, 250, 0.72);
  box-shadow: var(--shadow);
}

.ambient {
  position: absolute;
  pointer-events: none;
  filter: blur(4px);
}

.ambient::before,
.ambient::after {
  position: absolute;
  border-radius: 999px;
  background: rgba(255, 95, 147, 0.2);
  content: "";
}

.ambient-one {
  top: 86px;
  left: -32px;
  width: 260px;
  height: 260px;
  animation: floatSlow 9s ease-in-out infinite;
}

.ambient-one::before {
  width: 160px;
  height: 160px;
}

.ambient-one::after {
  top: 112px;
  left: 90px;
  width: 88px;
  height: 88px;
  background: rgba(255, 181, 156, 0.26);
}

.ambient-two {
  right: 18px;
  bottom: 64px;
  width: 220px;
  height: 220px;
  animation: floatSlow 10s ease-in-out infinite reverse;
}

.ambient-two::before {
  right: 0;
  width: 130px;
  height: 130px;
  background: rgba(216, 172, 255, 0.24);
}

.ambient-two::after {
  top: 78px;
  width: 78px;
  height: 78px;
}

.nav-bar {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 26px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--wine);
  font-size: 17px;
  font-weight: 900;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: linear-gradient(135deg, #ff6fa2, #ffad8e);
  color: #fff;
  box-shadow: 0 10px 28px rgba(255, 95, 147, 0.32);
}

.nav-actions,
.hero-actions,
.action-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.text-button,
.soft-button,
.pill-button,
.copy-button,
.reply-chip {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.64);
  color: var(--wine);
  font-weight: 800;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    background 180ms ease;
}

.text-button,
.pill-button,
.soft-button {
  padding: 0 18px;
}

.pill-button,
.soft-button {
  background: #fff;
  box-shadow: 0 12px 34px rgba(116, 44, 75, 0.1);
}

.primary-button,
.pay-button {
  min-height: 50px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--rose), var(--rose-deep));
  color: #fff;
  font-weight: 900;
  box-shadow: 0 18px 42px rgba(217, 47, 105, 0.27);
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    filter 180ms ease;
}

.primary-button {
  padding: 0 24px;
}

.pay-button {
  min-width: 120px;
  padding: 0 18px;
}

button:hover {
  transform: translateY(-2px);
}

.primary-button:hover,
.pay-button:hover {
  box-shadow: 0 22px 48px rgba(217, 47, 105, 0.34);
  filter: saturate(1.05);
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(320px, 0.78fr);
  align-items: center;
  gap: 34px;
  padding: 34px clamp(24px, 5vw, 70px) 52px;
}

.hero-copy {
  animation: fadeUp 560ms ease both;
}

.eyebrow,
.label {
  margin: 0 0 10px;
  color: var(--rose-deep);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  max-width: 720px;
  margin: 0;
  color: #39212d;
  font-size: clamp(46px, 6.2vw, 76px);
  line-height: 0.98;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  font-size: clamp(25px, 3vw, 38px);
  line-height: 1.12;
  letter-spacing: 0;
}

h3 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.35;
  letter-spacing: 0;
}

.hero-lede {
  max-width: 620px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.75;
}

.hero-actions {
  flex-wrap: wrap;
  margin-top: 32px;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.trust-row span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid rgba(255, 95, 147, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.58);
  color: var(--wine);
  font-size: 13px;
  font-weight: 800;
}

.phone-scene {
  display: grid;
  place-items: center;
  min-height: 520px;
  perspective: 1300px;
}

.phone-card {
  position: relative;
  width: min(360px, 100%);
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 34px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 247, 250, 0.9)),
    #fff;
  box-shadow:
    0 34px 90px rgba(116, 44, 75, 0.2),
    inset 0 0 0 10px rgba(255, 218, 230, 0.34);
  transform: rotateY(-10deg) rotateX(4deg);
  animation: phoneFloat 6s ease-in-out infinite;
}

.phone-card::after {
  position: absolute;
  right: -22px;
  bottom: 46px;
  width: 92px;
  height: 92px;
  border-radius: 30px;
  background: linear-gradient(135deg, rgba(255, 95, 147, 0.28), rgba(255, 181, 156, 0.26));
  filter: blur(1px);
  content: "";
}

.phone-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px 18px;
  color: var(--wine);
}

.phone-top span {
  width: 32px;
  height: 6px;
  border-radius: 999px;
  background: #f2ccd9;
}

.message-stack {
  display: grid;
  gap: 10px;
  padding: 12px 4px;
}

.bubble {
  width: fit-content;
  max-width: 82%;
  margin: 0;
  padding: 12px 14px;
  border-radius: 20px;
  line-height: 1.45;
  box-shadow: 0 10px 24px rgba(116, 44, 75, 0.08);
}

.bubble.them {
  background: #fff;
  color: var(--ink);
}

.bubble.me {
  justify-self: end;
  background: linear-gradient(135deg, #ff6f9f, #ff9a8a);
  color: #fff;
}

.signal-card,
.reply-preview {
  position: relative;
  z-index: 1;
  border-radius: 24px;
}

.signal-card {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 14px;
  padding: 16px;
  background: #fff4f8;
  border: 1px solid rgba(255, 95, 147, 0.16);
}

.signal-card div {
  display: grid;
  place-items: center;
  width: 74px;
  height: 74px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: conic-gradient(var(--rose) 0 41%, #f7d7e2 41% 100%);
  color: var(--wine);
}

.signal-card span {
  font-size: 11px;
  font-weight: 900;
}

.signal-card strong {
  font-size: 26px;
  line-height: 1;
}

.signal-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.reply-preview {
  margin-top: 12px;
  padding: 16px;
  background: #402232;
  color: #fff;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.55;
}

.tool-section {
  margin-top: 24px;
  padding: clamp(24px, 4vw, 48px);
  border: 1px solid rgba(255, 255, 255, 0.66);
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
}

.tool-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.tool-header > div {
  max-width: 650px;
}

.tool-header > p {
  max-width: 360px;
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.tool-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.86fr);
  gap: 22px;
  align-items: start;
}

.compose-panel,
.result-panel {
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 28px;
  background: var(--panel);
  box-shadow: 0 20px 60px rgba(116, 44, 75, 0.1);
  backdrop-filter: blur(18px);
}

.compose-panel {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.result-panel {
  position: sticky;
  top: 18px;
  padding: 22px;
}

.segmented-card {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.field {
  display: grid;
  gap: 8px;
}

.field span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--ink);
  outline: none;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    background 160ms ease;
}

select {
  height: 50px;
  padding: 0 14px;
}

input {
  height: 50px;
  padding: 0 14px;
}

textarea {
  min-height: 300px;
  resize: vertical;
  padding: 18px;
  line-height: 1.75;
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(255, 95, 147, 0.55);
  background: #fff;
  box-shadow: 0 0 0 5px rgba(255, 95, 147, 0.12);
}

.upload-row {
  display: grid;
  grid-template-columns: minmax(190px, 230px) minmax(0, 1fr);
  gap: 14px;
}

.upload-box {
  display: grid;
  place-items: center;
  min-height: 142px;
  padding: 14px;
  border: 1px dashed rgba(217, 47, 105, 0.32);
  border-radius: 24px;
  background: rgba(255, 247, 250, 0.78);
  color: var(--wine);
  text-align: center;
  cursor: pointer;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.upload-box:hover {
  transform: translateY(-2px);
  border-color: rgba(217, 47, 105, 0.55);
  background: #fff;
}

.upload-box input {
  display: none;
}

.upload-box small {
  color: var(--muted);
}

.upload-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 16px;
  background: linear-gradient(135deg, #ff6f9f, #ffad8e);
  color: #fff;
  font-size: 30px;
  line-height: 1;
  box-shadow: 0 14px 32px rgba(255, 95, 147, 0.3);
}

.image-preview {
  display: grid;
  place-items: center;
  min-height: 142px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.74);
  color: var(--muted);
  overflow: hidden;
}

.image-preview img {
  width: 100%;
  height: 100%;
  max-height: 230px;
  object-fit: contain;
  background: #fff;
}

.ocr-row,
.mode-row {
  display: grid;
  grid-template-columns: auto minmax(120px, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.58);
}

.mode-row {
  grid-template-columns: minmax(0, 1fr) auto;
}

.progress-track {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(217, 47, 105, 0.12);
}

.progress-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--rose), var(--rose-deep));
  transition: width 160ms ease;
}

.ocr-row small {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.switch-line {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--wine);
  font-weight: 800;
}

.switch-line input {
  width: 18px;
  height: 18px;
  accent-color: var(--rose-deep);
}

.link-button {
  padding: 0;
  background: transparent;
  color: var(--rose-deep);
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.action-row {
  justify-content: space-between;
  flex-wrap: wrap;
}

.action-row p {
  max-width: 430px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.empty-state {
  display: grid;
  align-content: center;
  min-height: 570px;
  text-align: center;
}

.loading-state {
  display: grid;
  align-content: center;
  min-height: 570px;
  text-align: center;
}

.loading-state p {
  max-width: 340px;
  margin: 14px auto 0;
  color: var(--muted);
  line-height: 1.65;
}

.heart-pulse {
  display: grid;
  place-items: center;
  width: 82px;
  height: 82px;
  margin: 0 auto 20px;
  border-radius: 28px;
  background: linear-gradient(135deg, rgba(255, 111, 159, 0.2), rgba(255, 181, 156, 0.24));
  color: var(--rose-deep);
  font-size: 42px;
  animation: pulse 1.8s ease-in-out infinite;
}

.empty-state h2 {
  max-width: 390px;
  margin: 0 auto;
  color: var(--wine);
}

.result-content {
  display: grid;
  gap: 16px;
  animation: fadeUp 360ms ease both;
}

.hidden {
  display: none !important;
}

.score-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 22px;
  border-radius: 26px;
  background:
    linear-gradient(135deg, rgba(90, 34, 58, 0.94), rgba(153, 49, 88, 0.9)),
    #57213a;
  color: #fff;
  box-shadow: 0 20px 48px rgba(116, 44, 75, 0.18);
}

.score-card .label {
  color: #ffd5e4;
}

.score-card p:last-child {
  max-width: 310px;
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.55;
}

.score-ring {
  display: grid;
  place-items: center;
  width: 96px;
  height: 96px;
  flex: 0 0 auto;
  border: 8px solid #ff9ebd;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
}

.score-ring span {
  font-size: 29px;
  font-weight: 950;
  line-height: 1;
}

.score-ring small {
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.meta-row span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 11px;
  border: 1px solid rgba(255, 95, 147, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--wine);
  font-size: 12px;
  font-weight: 900;
}

.insight-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.insight-card,
.profile-dashboard,
.tarot-block,
.advice-block,
.locked-block,
.deep-plan,
.mini-block,
.history-block {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--panel-strong);
}

.insight-card {
  padding: 16px;
}

.insight-card p:last-child,
.locked-block p,
.deep-plan li,
.mini-block li,
.history-list p {
  color: var(--muted);
  line-height: 1.58;
}

.insight-card p:last-child,
.locked-block p,
.history-list p {
  margin: 0;
}

.advice-block,
.profile-dashboard,
.tarot-block,
.deep-plan,
.mini-block,
.history-block {
  padding: 18px;
}

.profile-dashboard {
  display: grid;
  gap: 14px;
  background:
    linear-gradient(135deg, rgba(255, 247, 250, 0.96), rgba(255, 255, 255, 0.9)),
    #fff;
}

.track-count {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(255, 95, 147, 0.12);
  color: var(--rose-deep);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.track-stats {
  display: grid;
  grid-template-columns: 1.25fr 0.88fr 0.88fr;
  gap: 10px;
}

.track-stats div {
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(255, 95, 147, 0.13);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
}

.track-stats span {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.track-stats strong {
  color: var(--wine);
  font-size: 15px;
  line-height: 1.25;
}

.trend-bars {
  display: grid;
  grid-template-columns: repeat(12, minmax(14px, 1fr));
  align-items: end;
  min-height: 96px;
  gap: 8px;
  padding: 10px 4px 0;
}

.trend-bar {
  display: grid;
  grid-template-rows: 72px auto;
  align-items: end;
  gap: 6px;
  min-width: 0;
}

.trend-bar span {
  display: block;
  width: 100%;
  height: var(--bar-height);
  min-height: 10px;
  border-radius: 999px 999px 8px 8px;
  background: linear-gradient(180deg, var(--rose), var(--peach));
  box-shadow: 0 8px 18px rgba(217, 47, 105, 0.16);
}

.trend-bar small {
  color: var(--muted);
  font-size: 10px;
  line-height: 1.1;
  text-align: center;
  white-space: nowrap;
}

.today-action {
  margin: 0;
  padding: 14px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(255, 213, 228, 0.58), rgba(255, 242, 233, 0.8));
  color: var(--wine);
  font-weight: 850;
  line-height: 1.55;
}

.tarot-block {
  display: grid;
  gap: 14px;
  background:
    linear-gradient(135deg, rgba(64, 34, 50, 0.95), rgba(126, 48, 82, 0.9)),
    #402232;
  color: #fff;
  overflow: hidden;
}

.tarot-block .label {
  color: #ffd5e4;
}

.tarot-block h3 {
  color: #fff;
}

.tarot-rule {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

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

.tarot-card {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.tarot-flip {
  display: block;
  width: 100%;
  padding: 0;
  border-radius: 20px;
  background: transparent;
  perspective: 900px;
}

.tarot-inner {
  position: relative;
  min-height: 158px;
  border-radius: 20px;
  transform-style: preserve-3d;
  transition: transform 520ms ease;
}

.tarot-card.revealed .tarot-inner {
  transform: rotateY(180deg);
}

.tarot-face {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 12px;
  border: 1px solid rgba(255, 213, 228, 0.24);
  border-radius: 20px;
  background:
    radial-gradient(circle at 50% 24%, rgba(255, 213, 228, 0.24), transparent 35%),
    linear-gradient(145deg, #fff8df, #f0d1b4);
  color: #4b2436;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  backface-visibility: hidden;
  transform: rotateY(180deg);
  overflow: hidden;
}

.tarot-back {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 12px;
  border: 1px solid rgba(255, 213, 228, 0.24);
  border-radius: 20px;
  background:
    radial-gradient(circle at 50% 50%, rgba(255, 213, 228, 0.28) 0 18%, transparent 19%),
    linear-gradient(45deg, rgba(255, 255, 255, 0.08) 25%, transparent 25% 50%, rgba(255, 255, 255, 0.08) 50% 75%, transparent 75%),
    linear-gradient(145deg, #5a2039, #2f1827);
  background-size: auto, 18px 18px, auto;
  color: #fff;
  backface-visibility: hidden;
  overflow: hidden;
}

.tarot-back::before,
.tarot-face::before {
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 15px;
  content: "";
}

.tarot-back::after,
.tarot-face::after {
  position: absolute;
  inset: 22px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  content: "";
}

.tarot-back span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 213, 228, 0.18);
  color: #ffe5ee;
  font-size: 12px;
  font-weight: 950;
  z-index: 1;
}

.tarot-back strong {
  z-index: 1;
  margin-top: 10px;
  color: #fff;
  font-size: 16px;
}

.tarot-back small {
  z-index: 1;
  color: rgba(255, 255, 255, 0.68);
  font-size: 12px;
  font-weight: 900;
}

.tarot-face span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(94, 42, 58, 0.12);
  color: #6d2e48;
  font-size: 11px;
  font-weight: 950;
  z-index: 1;
}

.tarot-face strong {
  z-index: 1;
  margin-top: 12px;
  color: #4b2436;
  font-size: 17px;
  text-align: center;
}

.tarot-face small {
  z-index: 1;
  margin-top: 8px;
  color: rgba(75, 36, 54, 0.66);
  font-size: 12px;
  font-weight: 900;
}

.tarot-face i {
  position: absolute;
  top: 48px;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: rgba(126, 48, 82, 0.14);
}

.tarot-symbol-heart i {
  border-radius: 18px 18px 8px 8px;
  transform: rotate(45deg);
}

.tarot-symbol-heart i::before,
.tarot-symbol-heart i::after {
  position: absolute;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: inherit;
  content: "";
}

.tarot-symbol-heart i::before {
  left: -14px;
}

.tarot-symbol-heart i::after {
  top: -14px;
}

.tarot-symbol-sun i {
  box-shadow: 0 0 0 10px rgba(126, 48, 82, 0.08), 0 0 0 20px rgba(126, 48, 82, 0.05);
}

.tarot-symbol-moon i {
  background: transparent;
  box-shadow: -12px 0 0 rgba(126, 48, 82, 0.18);
}

.tarot-symbol-star i {
  clip-path: polygon(50% 0, 61% 36%, 99% 36%, 68% 57%, 79% 92%, 50% 70%, 21% 92%, 32% 57%, 1% 36%, 39% 36%);
  border-radius: 0;
}

.tarot-symbol-wheel i {
  background: transparent;
  border: 8px solid rgba(126, 48, 82, 0.16);
}

.tarot-symbol-cups i,
.tarot-symbol-wand i,
.tarot-symbol-lantern i,
.tarot-symbol-gate i,
.tarot-symbol-flower i,
.tarot-symbol-lion i,
.tarot-symbol-path i {
  border-radius: 14px;
}

.tarot-symbol-cups i::before,
.tarot-symbol-gate i::before,
.tarot-symbol-path i::before {
  position: absolute;
  inset: 12px;
  border: 3px solid rgba(126, 48, 82, 0.22);
  border-top: 0;
  border-radius: 0 0 14px 14px;
  content: "";
}

.tarot-reading {
  display: none;
}

.tarot-card.revealed .tarot-reading {
  display: grid;
  gap: 4px;
}

.tarot-reading h4 {
  margin: 0;
  color: #ffd5e4;
  font-size: 12px;
}

.tarot-reading p,
.tarot-summary {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
  line-height: 1.58;
}

.tarot-summary {
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.1);
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.copy-button {
  padding: 0 15px;
}

.reply-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 14px 0;
}

.reply-chip {
  padding: 0 8px;
}

.reply-chip.active {
  border-color: rgba(217, 47, 105, 0.3);
  background: linear-gradient(135deg, rgba(255, 213, 228, 0.9), rgba(255, 238, 244, 0.9));
  color: var(--rose-deep);
}

.reply-text {
  min-height: 78px;
  margin: 0;
  padding: 17px;
  border-radius: 22px;
  background: linear-gradient(135deg, #fff7fa, #fff1f6);
  color: #442636;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.56;
}

.locked-block {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px;
  background:
    linear-gradient(135deg, rgba(255, 236, 201, 0.9), rgba(255, 213, 228, 0.88)),
    #fff0d9;
}

.deep-plan ol {
  margin: 0;
  padding-left: 22px;
}

.mini-block ul {
  margin: 0;
  padding-left: 20px;
}

.deep-plan li + li,
.mini-block li + li {
  margin-top: 8px;
}

.deep-actions,
.history-actions,
.modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.history-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.history-item {
  display: grid;
  gap: 5px;
  padding: 13px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(255, 247, 250, 0.94), rgba(255, 255, 255, 0.86));
  border: 1px solid rgba(255, 95, 147, 0.12);
}

.history-open {
  display: grid;
  gap: 5px;
  width: 100%;
  padding: 0;
  background: transparent;
  color: inherit;
  text-align: left;
}

.history-item strong {
  color: var(--wine);
  font-size: 14px;
}

.history-item span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.danger {
  color: #a92350;
}

button:disabled {
  cursor: not-allowed;
  filter: grayscale(0.2);
  opacity: 0.66;
  transform: none !important;
}

.modal {
  width: min(560px, calc(100% - 28px));
  padding: 0;
  border: 0;
  border-radius: 28px;
  background: transparent;
}

.modal::backdrop {
  background: rgba(48, 22, 36, 0.42);
  backdrop-filter: blur(8px);
}

.modal-card {
  display: grid;
  gap: 16px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(255, 246, 250, 0.94)),
    #fff;
  box-shadow: var(--shadow);
}

.modal-copy {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.icon-button {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--wine);
  font-size: 24px;
  line-height: 1;
}

.qr-card {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 247, 250, 0.78);
}

.qr-placeholder {
  display: grid;
  place-items: center;
  min-height: 150px;
  border-radius: 18px;
  background:
    linear-gradient(45deg, rgba(217, 47, 105, 0.12) 25%, transparent 25% 50%, rgba(217, 47, 105, 0.12) 50% 75%, transparent 75%),
    #fff;
  background-size: 22px 22px;
  color: var(--wine);
  text-align: center;
}

.qr-placeholder span {
  font-size: 30px;
  font-weight: 950;
}

.qr-placeholder small,
.qr-card p {
  color: var(--muted);
  line-height: 1.55;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  z-index: 10;
  max-width: calc(100% - 32px);
  padding: 13px 17px;
  border-radius: 999px;
  background: rgba(64, 34, 50, 0.95);
  color: #fff;
  box-shadow: 0 20px 52px rgba(116, 44, 75, 0.22);
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) translateY(18px);
  transition:
    opacity 160ms ease,
    transform 160ms ease;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes phoneFloat {
  0%,
  100% {
    transform: rotateY(-10deg) rotateX(4deg) translateY(0);
  }

  50% {
    transform: rotateY(-7deg) rotateX(2deg) translateY(-12px);
  }
}

@keyframes floatSlow {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }

  50% {
    transform: translate3d(18px, -18px, 0);
  }
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(255, 95, 147, 0.2);
  }

  50% {
    transform: scale(1.04);
    box-shadow: 0 0 0 16px rgba(255, 95, 147, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

@media (max-width: 980px) {
  .hero-stage {
    min-height: auto;
  }

  .hero-grid,
  .tool-grid {
    grid-template-columns: 1fr;
  }

  .phone-scene {
    min-height: 520px;
  }

  .phone-card {
    transform: none;
  }

  .tool-header {
    align-items: start;
    flex-direction: column;
  }

  .result-panel {
    position: static;
  }
}

@media (max-width: 680px) {
  .page-shell {
    width: min(100% - 20px, 1180px);
    padding-top: 10px;
  }

  .hero-stage,
  .tool-section {
    border-radius: 26px;
  }

  .nav-bar {
    align-items: stretch;
    flex-direction: column;
    gap: 12px;
    padding: 14px 16px;
  }

  .nav-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .hero-grid {
    gap: 12px;
    padding: 14px 18px 24px;
  }

  h1 {
    font-size: 33px;
  }

  .hero-lede {
    margin-top: 13px;
    font-size: 16px;
    line-height: 1.5;
  }

  .hero-actions,
  .action-row,
  .locked-block {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .hero-actions button,
  .action-row button {
    width: 100%;
  }

  .hero-actions {
    margin-top: 14px;
  }

  .trust-row {
    margin-top: 12px;
  }

  .trust-row span {
    min-height: 30px;
    padding: 0 10px;
    font-size: 12px;
  }

  .phone-scene {
    min-height: 222px;
    overflow: hidden;
  }

  .phone-card {
    width: min(224px, 100%);
    padding: 10px;
    border-radius: 28px;
    transform: none;
    animation: none;
  }

  .phone-top {
    padding: 5px 8px 7px;
    font-size: 13px;
  }

  .message-stack {
    gap: 5px;
    padding: 4px 2px;
  }

  .bubble {
    padding: 7px 9px;
    border-radius: 15px;
    font-size: 11px;
  }

  .signal-card {
    gap: 8px;
    margin-top: 5px;
    padding: 8px;
    border-radius: 16px;
  }

  .signal-card div {
    width: 48px;
    height: 48px;
  }

  .signal-card strong {
    font-size: 20px;
  }

  .signal-card p {
    font-size: 12px;
  }

  .reply-preview {
    margin-top: 6px;
    padding: 9px;
    border-radius: 16px;
    font-size: 12px;
  }

  .tool-section {
    padding: 18px;
  }

  .compose-panel,
  .result-panel {
    border-radius: 24px;
    padding: 16px;
  }

  .segmented-card,
  .upload-row,
  .ocr-row,
  .mode-row,
  .insight-grid,
  .reply-options,
  .track-stats,
  .tarot-spread {
    grid-template-columns: 1fr;
  }

  .trend-bars {
    grid-template-columns: repeat(6, minmax(18px, 1fr));
  }

  .qr-card {
    grid-template-columns: 1fr;
  }

  .section-heading {
    align-items: flex-start;
  }

  textarea {
    min-height: 250px;
  }

  .score-card {
    align-items: flex-start;
    flex-direction: column;
  }

  .empty-state {
    min-height: 360px;
  }

  .loading-state {
    min-height: 360px;
  }
}

@media (max-width: 430px) {
  h1 {
    font-size: 32px;
  }

  h2 {
    font-size: 25px;
  }

  .text-button,
  .pill-button {
    min-height: 38px;
    padding: 0 8px;
    font-size: 13px;
  }

  .trust-row span {
    flex: 1 1 auto;
    justify-content: center;
  }

  .phone-scene {
    min-height: 220px;
  }
}
