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

:root {
  --red: #8B1A1A;
  --red-light: #C41E3A;
  --gold: #B8860B;
  --gold-light: #DAA520;
  --cream: #FFF8F0;
  --cream-dark: #F5EDE0;
  --dark: #1A1A1A;
  --dark-soft: #2C1810;
  --text: #3D3029;
  --text-light: #7A6E65;
  --white: #FFFFFF;
  --radius: 12px;
  --shadow: 0 4px 24px rgba(0,0,0,0.08);
  --shadow-lg: 0 12px 48px rgba(0,0,0,0.12);
}

html {
  scroll-behavior: auto;
}

body {
  font-family: 'Inter', -apple-system, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top, rgba(218, 165, 32, 0.08), transparent 30%),
    linear-gradient(180deg, #fffaf4 0%, #f7ede1 100%);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  scrollbar-width: thin;
  scrollbar-color: rgba(122, 110, 101, 0.45) transparent;
  overflow-x: hidden;
}

/* Use slimmer, low-contrast scrollbars to avoid oversized scroller visuals. */
*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

*::-webkit-scrollbar-thumb {
  background: rgba(122, 110, 101, 0.45);
  border-radius: 999px;
}

*::-webkit-scrollbar-track {
  background: transparent;
}

.container {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

.center { text-align: center; }

.section {
  padding: 80px 0;
}

/* ===== Hero ===== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--dark);
  color: var(--cream);
  text-align: center;
  position: relative;
  overflow: hidden;
  padding: 42px 0 64px;
}

.hero-bg-text {
  position: absolute;
  font-family: 'Noto Serif SC', serif;
  font-size: 45vw;
  color: rgba(255, 255, 255, 0.03);
  user-select: none;
  pointer-events: none;
  line-height: 1;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 24px;
  position: relative;
}

.hero-title .highlight {
  color: var(--gold-light);
}

.hero-subtitle {
  font-size: 1.15rem;
  font-weight: 300;
  color: rgba(255, 248, 240, 0.7);
  max-width: 500px;
  margin: 0 auto 40px;
  line-height: 1.7;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 36px;
  border: none;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.25s ease;
  text-decoration: none;
}

.btn-primary {
  background: var(--red);
  color: var(--cream);
}
.btn-primary:hover {
  background: var(--red-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(139, 26, 26, 0.3);
}

.btn-secondary {
  background: transparent;
  color: var(--red);
  border: 2px solid var(--red);
}
.btn-secondary:hover {
  background: var(--red);
  color: var(--cream);
}

.btn-tertiary {
  background: rgba(139, 26, 26, 0.08);
  color: var(--dark-soft);
  border: 1px solid rgba(139, 26, 26, 0.12);
}

.btn-tertiary:hover {
  background: rgba(139, 26, 26, 0.14);
  transform: translateY(-1px);
}

.btn-full {
  width: 100%;
  padding: 16px;
  font-size: 1.05rem;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
}

.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,248,240,0.3);
  border-top-color: var(--cream);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
.btn-secondary .spinner {
  border-color: rgba(139, 26, 26, 0.2);
  border-top-color: var(--red);
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ===== Form Section ===== */
.form-section {
  background: var(--cream);
}

.section-title {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  font-weight: 600;
  color: var(--dark-soft);
  text-align: center;
  margin-bottom: 8px;
}

.section-desc {
  text-align: center;
  color: var(--text-light);
  margin-bottom: 40px;
}

.name-form {
  background: var(--white);
  padding: 40px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.form-group {
  margin-bottom: 24px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

label {
  display: block;
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--dark-soft);
  margin-bottom: 6px;
}

input, select, textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid #E0D6CC;
  border-radius: 8px;
  font-size: 1rem;
  font-family: 'Inter', sans-serif;
  color: var(--text);
  background: var(--cream);
  transition: border-color 0.2s;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(184, 134, 11, 0.1);
}

textarea {
  resize: vertical;
}

.birth-details-card {
  border: 1px solid #e6d9c8;
  border-radius: 12px;
  padding: 14px 14px 10px;
  background:
    radial-gradient(circle at 92% 12%, rgba(218, 165, 32, 0.12), transparent 42%),
    linear-gradient(145deg, #fffaf4 0%, #fff3e7 100%);
}

.birth-details-head {
  margin-bottom: 12px;
}

.birth-details-head h4 {
  font-family: 'Playfair Display', serif;
  font-size: 1.04rem;
  color: var(--dark-soft);
  margin: 0;
}

.birth-details-head p {
  margin: 4px 0 0;
  color: var(--text-light);
  font-size: 0.83rem;
}

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

.birth-detail-field {
  margin-bottom: 0;
}

.birth-detail-input {
  background: #fff;
  border: 1.5px solid #dcc7ac;
}

.dob-select-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 8px;
}

.dob-select-grid select.birth-detail-input {
  padding: 11px 12px;
}

/* ===== Loading Section ===== */
.loading-section {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 16%, rgba(218, 165, 32, 0.22), transparent 26%),
    radial-gradient(circle at 18% 24%, rgba(139, 26, 26, 0.22), transparent 22%),
    linear-gradient(180deg, #21120f 0%, #150d0c 55%, #110b0a 100%);
  color: var(--cream);
  min-height: 60vh;
  align-items: center;
  justify-content: center;
}

.loading-section::before,
.loading-section::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.loading-section::before {
  background:
    radial-gradient(circle at 50% 22%, rgba(255, 248, 240, 0.04), transparent 14%),
    linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.03) 50%, transparent 100%);
  opacity: 0.9;
}

.loading-section::after {
  background:
    repeating-linear-gradient(
      90deg,
      transparent 0,
      transparent 68px,
      rgba(218, 165, 32, 0.025) 68px,
      rgba(218, 165, 32, 0.025) 69px
    );
  opacity: 0.3;
}

.loading-section .container {
  position: relative;
  z-index: 1;
}

.loading-animation {
  text-align: center;
  max-width: 680px;
  margin: 0 auto;
}

.loading-phase {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 18px;
  margin-bottom: 22px;
  border-radius: 999px;
  border: 1px solid rgba(218, 165, 32, 0.24);
  background:
    linear-gradient(180deg, rgba(255, 248, 240, 0.08), rgba(255, 248, 240, 0.03));
  color: rgba(255, 239, 217, 0.86);
  font-family: 'Noto Serif SC', serif;
  font-size: 0.92rem;
  letter-spacing: 0.1em;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
  transition: opacity 0.32s ease, transform 0.32s ease, filter 0.32s ease;
}

.loading-tableau {
  position: relative;
  width: 360px;
  height: 330px;
  margin: 0 auto 34px;
}

.loading-halo {
  position: absolute;
  inset: 54px 66px 52px;
  z-index: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(218, 165, 32, 0.34) 0%, rgba(218, 165, 32, 0.11) 42%, rgba(255, 248, 240, 0) 74%);
  filter: blur(18px);
  animation: loadingHaloPulse 5s ease-in-out infinite;
}

.loading-moon-gate {
  position: absolute;
  inset: 18px 44px 42px;
  z-index: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 38%, rgba(255, 252, 247, 0.12) 0%, rgba(255, 248, 240, 0.03) 48%, transparent 74%),
    radial-gradient(circle at 50% 50%, rgba(139, 26, 26, 0.26), rgba(31, 18, 15, 0.12));
  border: 1px solid rgba(218, 165, 32, 0.24);
  box-shadow:
    0 32px 90px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    inset 0 0 0 16px rgba(255, 248, 240, 0.02);
  animation: loadingMoonGlow 7.2s ease-in-out infinite;
}

.loading-orbit {
  content: "";
  position: absolute;
  z-index: 1;
  border-radius: 50%;
  border: 1px solid rgba(218, 165, 32, 0.18);
  pointer-events: none;
}

.loading-orbit-outer {
  inset: 6px 28px 30px;
  border-left-color: transparent;
  border-bottom-color: rgba(255, 248, 240, 0.12);
  transform: rotate(-10deg);
  animation: loadingOrbitOuter 12s linear infinite;
}

.loading-orbit-inner {
  inset: 38px 72px 74px;
  border-right-color: transparent;
  border-top-color: rgba(255, 248, 240, 0.16);
  transform: rotate(18deg);
  animation: loadingOrbitInner 9s linear infinite reverse;
}

.loading-cloud {
  position: absolute;
  z-index: 2;
  height: 34px;
  border-radius: 999px;
  background:
    radial-gradient(circle at 18% 52%, rgba(255, 248, 240, 0.58) 0, rgba(255, 248, 240, 0.58) 18px, transparent 19px),
    radial-gradient(circle at 42% 44%, rgba(255, 248, 240, 0.48) 0, rgba(255, 248, 240, 0.48) 20px, transparent 21px),
    radial-gradient(circle at 68% 54%, rgba(255, 248, 240, 0.42) 0, rgba(255, 248, 240, 0.42) 16px, transparent 17px),
    linear-gradient(180deg, rgba(255, 248, 240, 0.2), rgba(255, 248, 240, 0.02));
  filter: blur(1px);
  opacity: 0.65;
  animation: loadingCloudDrift 7.5s ease-in-out infinite;
}

.loading-cloud-a {
  width: 118px;
  top: 74px;
  left: 12px;
}

.loading-cloud-b {
  width: 134px;
  right: 2px;
  bottom: 74px;
  animation-delay: -2.4s;
}

.loading-scroll {
  position: absolute;
  z-index: 4;
  left: 50%;
  top: 44px;
  width: 176px;
  height: 224px;
  transform: translateX(-50%);
  animation: loadingScrollFloat 4.8s ease-in-out infinite;
}

.loading-scroll-rod {
  position: absolute;
  left: 10px;
  right: 10px;
  top: 0;
  height: 10px;
  border-radius: 999px;
  background:
    linear-gradient(90deg, #6f3021 0%, #b8860b 48%, #6f3021 100%);
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.18);
}

.loading-scroll-cap {
  position: absolute;
  top: -3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: linear-gradient(180deg, #c99d45 0%, #7f5311 100%);
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.18);
}

.loading-scroll-cap-left {
  left: 0;
}

.loading-scroll-cap-right {
  right: 0;
}

.loading-scroll-paper {
  position: absolute;
  left: 14px;
  right: 14px;
  top: 14px;
  bottom: 18px;
  border-radius: 26px 26px 34px 34px;
  background:
    linear-gradient(180deg, rgba(255, 252, 247, 0.98) 0%, rgba(245, 231, 212, 0.95) 100%);
  box-shadow:
    0 22px 54px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.72);
  overflow: hidden;
}

.loading-card-sheen {
  position: absolute;
  inset: -26% 56% -26% -24%;
  background: linear-gradient(110deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0));
  transform: rotate(9deg);
  animation: loadingSheen 4.2s ease-in-out infinite;
}

.loading-card-inner {
  position: absolute;
  inset: 18px 18px 26px;
  border-radius: 22px;
  border: 1px solid rgba(184, 134, 11, 0.18);
  background:
    radial-gradient(circle at top left, rgba(218, 165, 32, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 248, 240, 0.85) 100%);
  overflow: hidden;
}

.loading-ink-strokes {
  position: absolute;
  inset: 8px 10px 26px;
  z-index: 1;
  pointer-events: none;
  opacity: 0.92;
}

.loading-ink-stroke {
  position: absolute;
  left: 18px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(44, 24, 16, 0), rgba(44, 24, 16, 0.38), rgba(44, 24, 16, 0.05));
  filter: blur(0.2px);
  transform-origin: left center;
  opacity: 0;
  animation: loadingInkWrite 4.8s cubic-bezier(0.33, 1, 0.68, 1) infinite;
}

.loading-ink-stroke-a {
  top: 30px;
  width: 78px;
}

.loading-ink-stroke-b {
  top: 68px;
  width: 56px;
  left: 42px;
  animation-delay: -1.4s;
}

.loading-ink-stroke-c {
  top: 112px;
  width: 84px;
  left: 24px;
  animation-delay: -2.8s;
}

.loading-ink-brush {
  position: absolute;
  top: 26px;
  left: 22px;
  width: 34px;
  height: 10px;
  border-radius: 999px 6px 6px 999px;
  background:
    linear-gradient(90deg, rgba(111, 48, 33, 0.95) 0%, rgba(200, 142, 59, 0.9) 34%, rgba(57, 37, 28, 0.95) 74%, rgba(30, 18, 15, 0.98) 100%);
  box-shadow:
    0 3px 8px rgba(0, 0, 0, 0.16),
    inset 0 1px 0 rgba(255, 248, 240, 0.14);
  transform-origin: 88% 50%;
  animation: loadingBrushWrite 4.8s cubic-bezier(0.33, 1, 0.68, 1) infinite;
}

.loading-ink-brush::before {
  content: "";
  position: absolute;
  right: -6px;
  top: 50%;
  width: 12px;
  height: 12px;
  border-radius: 50% 70% 65% 45%;
  background: rgba(30, 18, 15, 0.94);
  transform: translateY(-50%) rotate(24deg);
}

.loading-ink-bloom {
  position: absolute;
  right: 30px;
  bottom: 28px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(44, 24, 16, 0.18) 0%, rgba(44, 24, 16, 0.08) 34%, rgba(44, 24, 16, 0) 72%);
  filter: blur(0.5px);
  animation: loadingInkBloom 4.8s ease-in-out infinite;
}

.loading-scroll-script {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 16px;
  font-family: 'Noto Serif SC', serif;
  font-size: 0.78rem;
  letter-spacing: 0.34em;
  color: rgba(139, 26, 26, 0.62);
  text-indent: 0.34em;
}

.loading-tassel {
  position: absolute;
  top: 6px;
  width: 2px;
  height: 74px;
  background: linear-gradient(180deg, rgba(200, 142, 59, 0.16), rgba(200, 142, 59, 0.9));
  transform-origin: top center;
  animation: loadingTassel 3.8s ease-in-out infinite;
}

.loading-tassel::before,
.loading-tassel::after {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.loading-tassel::before {
  top: 14px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(139, 26, 26, 0.86);
  box-shadow: 0 0 0 3px rgba(255, 248, 240, 0.08);
}

.loading-tassel::after {
  bottom: -10px;
  width: 16px;
  height: 24px;
  border-radius: 0 0 12px 12px;
  background: linear-gradient(180deg, rgba(139, 26, 26, 0.96), rgba(196, 30, 58, 0.65));
  box-shadow: 0 8px 12px rgba(0, 0, 0, 0.18);
}

.loading-tassel-left {
  left: 34px;
}

.loading-tassel-right {
  right: 34px;
  animation-delay: -1.4s;
}

.loading-plate {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 102px;
  width: 148px;
  height: 160px;
  transform: translateX(-50%) rotate(-8deg);
  border-radius: 26px;
  background:
    linear-gradient(180deg, rgba(139, 26, 26, 0.72) 0%, rgba(83, 18, 18, 0.84) 100%);
  border: 1px solid rgba(255, 248, 240, 0.08);
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.26);
  animation: loadingPlateFloat 5.4s ease-in-out infinite;
}

.loading-plate-inner {
  position: absolute;
  inset: 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 248, 240, 0.08);
  background:
    radial-gradient(circle at top left, rgba(255, 248, 240, 0.08), transparent 40%),
    linear-gradient(180deg, rgba(255, 248, 240, 0.06), rgba(255, 248, 240, 0.02));
}

.loading-card-glyph {
  position: absolute;
  font-family: 'Noto Serif SC', serif;
  color: rgba(139, 26, 26, 0.78);
}

.loading-card-glyph-main {
  inset: 26px auto auto 50%;
  transform: translateX(-50%);
  font-size: 4.7rem;
  line-height: 1;
  text-shadow: 0 8px 16px rgba(139, 26, 26, 0.08);
}

.loading-card-glyph-accent {
  right: 24px;
  bottom: 18px;
  font-size: 2.1rem;
  opacity: 0.28;
}

.loading-plate .loading-card-glyph {
  color: rgba(255, 248, 240, 0.82);
}

.loading-plate .loading-card-glyph-main {
  inset: 26px auto auto 50%;
  font-size: 4.2rem;
}

.loading-plate .loading-card-glyph-accent {
  right: 22px;
  bottom: 18px;
  opacity: 0.2;
}

.loading-seal {
  position: absolute;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  font-family: 'Noto Serif SC', serif;
  font-size: 1.25rem;
  color: rgba(255, 248, 240, 0.82);
  background:
    linear-gradient(180deg, rgba(139, 26, 26, 0.92), rgba(103, 23, 23, 0.86));
  box-shadow: 0 14px 22px rgba(0, 0, 0, 0.24);
  transform: rotate(-12deg);
  animation: loadingSealBob 4.2s ease-in-out infinite;
}

.loading-seal-a {
  left: 64px;
  top: 70px;
}

.loading-seal-b {
  right: 58px;
  bottom: 64px;
  animation-delay: -1.8s;
}

.loading-mote {
  position: absolute;
  z-index: 6;
  border-radius: 50%;
  background: rgba(255, 248, 240, 0.9);
  box-shadow: 0 0 18px rgba(218, 165, 32, 0.28);
  animation: loadingMoteDrift 5.8s ease-in-out infinite;
}

.loading-mote-a {
  width: 10px;
  height: 10px;
  top: 42px;
  left: 58px;
}

.loading-mote-b {
  width: 7px;
  height: 7px;
  right: 46px;
  top: 112px;
  animation-delay: -1.1s;
}

.loading-mote-c {
  width: 9px;
  height: 9px;
  left: 50px;
  bottom: 58px;
  animation-delay: -2.3s;
}

.loading-progress-wrap {
  position: relative;
  max-width: 468px;
  margin: 0 auto 20px;
}

.loading-progress-track {
  position: relative;
  height: 12px;
  border-radius: 999px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 248, 240, 0.08), rgba(255, 248, 240, 0.02));
  border: 1px solid rgba(218, 165, 32, 0.16);
  box-shadow:
    inset 0 1px 0 rgba(255, 248, 240, 0.08),
    0 12px 24px rgba(0, 0, 0, 0.14);
}

.loading-progress-glow {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(218, 165, 32, 0), rgba(218, 165, 32, 0.12), rgba(218, 165, 32, 0));
  transform: translateX(-100%);
  animation: loadingProgressGlow 3.6s ease-in-out infinite;
}

.loading-progress-fill {
  position: absolute;
  inset: 1px auto 1px 1px;
  width: 8%;
  border-radius: 999px;
  background:
    linear-gradient(90deg, rgba(139, 26, 26, 0.95) 0%, rgba(196, 30, 58, 0.92) 36%, rgba(218, 165, 32, 0.94) 100%);
  box-shadow:
    0 0 18px rgba(196, 30, 58, 0.24),
    inset 0 1px 0 rgba(255, 248, 240, 0.22);
}

.loading-progress-brush {
  position: absolute;
  top: 50%;
  left: 8%;
  width: 34px;
  height: 22px;
  transform: translate(-44%, -50%) rotate(-8deg);
  pointer-events: none;
}

.loading-progress-brush-tip {
  position: absolute;
  right: 0;
  top: 50%;
  width: 18px;
  height: 18px;
  border-radius: 50% 64% 60% 46%;
  background: linear-gradient(180deg, rgba(44, 24, 16, 0.98), rgba(14, 10, 9, 0.98));
  transform: translateY(-50%) rotate(18deg);
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.18);
}

.loading-progress-brush-tail {
  position: absolute;
  left: 0;
  top: 50%;
  width: 24px;
  height: 8px;
  border-radius: 999px 8px 8px 999px;
  background: linear-gradient(90deg, rgba(111, 48, 33, 0.96), rgba(200, 142, 59, 0.9));
  transform: translateY(-50%);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.16);
}

.loading-progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 10px;
  align-items: center;
}

.loading-progress-label {
  color: rgba(255, 239, 217, 0.72);
  font-size: 0.88rem;
  letter-spacing: 0.04em;
}

.loading-progress-percent {
  color: rgba(255, 248, 240, 0.92);
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  min-width: 48px;
  text-align: right;
}

.loading-stage-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.loading-stage-dot {
  position: relative;
  padding: 10px 8px;
  border-radius: 14px;
  text-align: center;
  font-family: 'Noto Serif SC', serif;
  color: rgba(255, 239, 217, 0.48);
  background: rgba(255, 248, 240, 0.03);
  border: 1px solid rgba(255, 248, 240, 0.06);
  transition: transform 0.35s ease, color 0.35s ease, background 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}

.loading-stage-dot.is-passed {
  color: rgba(255, 239, 217, 0.72);
  border-color: rgba(218, 165, 32, 0.12);
}

.loading-stage-dot.is-active {
  color: rgba(255, 248, 240, 0.96);
  background: linear-gradient(180deg, rgba(139, 26, 26, 0.22), rgba(139, 26, 26, 0.08));
  border-color: rgba(218, 165, 32, 0.22);
  box-shadow: 0 12px 20px rgba(0, 0, 0, 0.14);
  transform: translateY(-2px);
}

.loading-runes {
  position: relative;
  height: 56px;
  margin: 0 auto 8px;
  max-width: 500px;
  overflow: hidden;
  pointer-events: none;
}

.loading-rune {
  position: absolute;
  bottom: -8px;
  left: var(--rune-x, 10%);
  font-family: 'Noto Serif SC', serif;
  font-size: var(--rune-size, 1.1rem);
  color: rgba(255, 239, 217, 0.2);
  transform: translateX(-50%);
  animation: loadingRuneRise 3.6s ease-in infinite;
  animation-delay: var(--rune-delay, 0s);
}

.loading-text {
  font-family: 'Playfair Display', serif;
  font-size: 1.74rem;
  margin-bottom: 8px;
  line-height: 1.35;
  color: rgba(255, 248, 240, 0.96);
  text-shadow: 0 12px 24px rgba(0, 0, 0, 0.16);
  transition: opacity 0.32s ease, transform 0.32s ease, filter 0.32s ease;
}

.loading-subtext {
  color: rgba(255, 248, 240, 0.58);
  font-weight: 300;
  max-width: 470px;
  margin: 0 auto;
  line-height: 1.85;
  transition: opacity 0.32s ease, transform 0.32s ease, filter 0.32s ease;
}

.loading-mantra {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
  padding: 10px 18px;
  border-radius: 999px;
  background: rgba(255, 248, 240, 0.06);
  border: 1px solid rgba(255, 248, 240, 0.08);
  box-shadow: 0 14px 26px rgba(0, 0, 0, 0.16);
}

.loading-mantra-char {
  font-family: 'Noto Serif SC', serif;
  font-size: 1rem;
  letter-spacing: 0.12em;
  color: rgba(255, 239, 217, 0.84);
}

.loading-mantra-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(218, 165, 32, 0.76);
  box-shadow: 0 0 14px rgba(218, 165, 32, 0.34);
}

.loading-phase.is-transitioning,
.loading-text.is-transitioning,
.loading-subtext.is-transitioning {
  opacity: 0;
  transform: translateY(8px);
  filter: blur(5px);
}

.loading-phase.is-transitioned,
.loading-text.is-transitioned,
.loading-subtext.is-transitioned {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

@keyframes loadingHaloPulse {
  0%, 100% { transform: scale(0.92); opacity: 0.65; }
  50% { transform: scale(1.06); opacity: 1; }
}

@keyframes loadingMoonGlow {
  0%, 100% { transform: scale(0.985); opacity: 0.92; }
  50% { transform: scale(1.015); opacity: 1; }
}

@keyframes loadingOrbitOuter {
  from { transform: rotate(-10deg); }
  to { transform: rotate(350deg); }
}

@keyframes loadingOrbitInner {
  from { transform: rotate(18deg); }
  to { transform: rotate(378deg); }
}

@keyframes loadingScrollFloat {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-10px); }
}

@keyframes loadingPlateFloat {
  0%, 100% { transform: translateX(-50%) rotate(-8deg) translateY(2px); }
  50% { transform: translateX(-50%) rotate(-4deg) translateY(-8px); }
}

@keyframes loadingSheen {
  0%, 100% { transform: translateX(0) rotate(9deg); opacity: 0.35; }
  50% { transform: translateX(28px) rotate(9deg); opacity: 0.82; }
}

@keyframes loadingInkWrite {
  0%, 14% { transform: scaleX(0.08); opacity: 0; }
  18%, 54% { transform: scaleX(1); opacity: 0.7; }
  72%, 100% { transform: scaleX(0.92); opacity: 0; }
}

@keyframes loadingBrushWrite {
  0%, 12% { transform: translate(0, 0) rotate(-11deg); opacity: 0; }
  18% { opacity: 0.92; }
  32% { transform: translate(62px, 10px) rotate(-4deg); opacity: 0.94; }
  48% { transform: translate(24px, 48px) rotate(8deg); opacity: 0.94; }
  66% { transform: translate(76px, 88px) rotate(-2deg); opacity: 0.92; }
  84% { transform: translate(42px, 122px) rotate(10deg); opacity: 0.7; }
  100% { transform: translate(52px, 122px) rotate(14deg); opacity: 0; }
}

@keyframes loadingInkBloom {
  0%, 18%, 100% { transform: scale(0.6); opacity: 0; }
  44% { transform: scale(0.92); opacity: 0.52; }
  64% { transform: scale(1.12); opacity: 0.18; }
}

@keyframes loadingCloudDrift {
  0%, 100% { transform: translateX(0) translateY(0); opacity: 0.55; }
  50% { transform: translateX(10px) translateY(-8px); opacity: 0.82; }
}

@keyframes loadingTassel {
  0%, 100% { transform: rotate(6deg); }
  50% { transform: rotate(-5deg); }
}

@keyframes loadingSealBob {
  0%, 100% { transform: rotate(-12deg) translateY(0); }
  50% { transform: rotate(-7deg) translateY(-6px); }
}

@keyframes loadingMoteDrift {
  0%, 100% { transform: translateY(0) scale(1); opacity: 0.48; }
  50% { transform: translateY(-18px) scale(1.18); opacity: 1; }
}

@keyframes loadingProgressGlow {
  0% { transform: translateX(-100%); opacity: 0; }
  20% { opacity: 0.85; }
  100% { transform: translateX(100%); opacity: 0; }
}

@keyframes loadingRuneRise {
  0% { transform: translate(-50%, 14px) scale(0.88); opacity: 0; }
  18% { opacity: 0.62; }
  55% { opacity: 0.34; }
  100% { transform: translate(-50%, -42px) scale(1.08); opacity: 0; }
}

/* ===== Results Section ===== */
.results-section {
  background: var(--cream-dark);
}

.shared-report-banner {
  margin-bottom: 20px;
  padding: 18px 20px;
  border-radius: 18px;
  background:
    radial-gradient(circle at top right, rgba(218, 165, 32, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(255, 248, 240, 0.94) 100%);
  border: 1px solid rgba(184, 134, 11, 0.18);
  box-shadow: var(--shadow);
}

.shared-report-pill {
  display: inline-block;
  margin-bottom: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(139, 26, 26, 0.08);
  color: var(--red);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.shared-report-banner p {
  margin: 0;
  color: var(--text);
}

.blur-container {
  position: relative;
  overflow: hidden;
  padding: 2px 0;
}

.blur-container.has-lock-badge {
  min-height: 76px;
  padding: 16px 0;
}

.blur-overlay {
  filter: blur(6px);
  user-select: none;
  pointer-events: none;
  opacity: 0.64;
}

.lock-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-7deg);
  max-width: calc(100% - 16px);
  padding: 7px 10px 7px 7px;
  border-radius: 16px;
  background:
    linear-gradient(145deg, rgba(139, 26, 26, 0.96) 0%, rgba(87, 19, 19, 0.96) 100%);
  border: 1px solid rgba(218, 165, 32, 0.28);
  box-shadow:
    0 14px 28px rgba(44, 24, 16, 0.2),
    inset 0 1px 0 rgba(255, 248, 240, 0.12);
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff4e3;
  z-index: 10;
}

.lock-icon-seal {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(180deg, rgba(196, 30, 58, 0.92) 0%, rgba(139, 26, 26, 0.88) 100%);
  border: 1px solid rgba(255, 248, 240, 0.18);
  box-shadow:
    inset 0 1px 0 rgba(255, 248, 240, 0.14),
    0 8px 14px rgba(0, 0, 0, 0.16);
  font-family: 'Noto Serif SC', serif;
  font-size: 1.12rem;
  line-height: 1;
}

.lock-icon-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  text-align: left;
  min-width: 0;
}

.lock-icon-copy strong {
  font-family: 'Noto Serif SC', serif;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #fff0d5;
  line-height: 1.1;
}

.lock-icon-copy span {
  font-family: 'Noto Serif SC', serif;
  font-size: 0.58rem;
  letter-spacing: 0.06em;
  line-height: 1.05;
  color: rgba(255, 232, 198, 0.72);
}

.StripeElement {
  padding: 12px;
  border: 1px solid #ccc;
  border-radius: 4px;
  background: white;
  margin-bottom: 15px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.StripeElement--focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 1px var(--gold);
}

.result-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  margin-bottom: 32px;
}

.name-display {
  text-align: center;
  padding: 48px 32px 32px;
  background: linear-gradient(160deg, var(--dark) 0%, var(--dark-soft) 100%);
  color: var(--cream);
}

.chinese-name {
  font-family: 'Noto Serif SC', serif;
  font-size: 6rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--gold-light);
  margin-bottom: 8px;
}

.pinyin {
  font-size: 1.2rem;
  font-weight: 300;
  color: rgba(255, 248, 240, 0.7);
  margin-bottom: 12px;
}

.english-for {
  font-size: 0.95rem;
  color: rgba(255, 248, 240, 0.5);
}

.profile-code-panel {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 16px;
  padding: 10px 14px;
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 250, 244, 0.96) 0%, rgba(247, 236, 219, 0.94) 100%);
  border: 1px solid rgba(218, 165, 32, 0.28);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    0 10px 22px rgba(0, 0, 0, 0.14);
}

.profile-code-label {
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(139, 26, 26, 0.78);
}

#profile-code-value {
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  letter-spacing: 0.16em;
  color: #7a1b1b;
}

.divider {
  height: 3px;
  background: linear-gradient(90deg, var(--red), var(--gold-light), var(--red));
}

.result-block {
  padding: 24px 32px;
  border-bottom: 1px solid #F0E8DE;
}
.result-block:last-child {
  border-bottom: none;
}

.result-block h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  color: var(--red);
  margin-bottom: 12px;
}

.result-block p {
  color: var(--text);
  line-height: 1.7;
  max-width: 70ch;
}

.result-block-feature {
  background:
    radial-gradient(circle at 88% 14%, rgba(218, 165, 32, 0.12), transparent 32%),
    linear-gradient(180deg, #fffbf7 0%, #fff6ee 100%);
}

.feature-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 18px;
}

.feature-kicker {
  color: var(--text-light);
  font-size: 0.92rem;
  margin-top: 2px;
}

.five-elements-layout {
  display: grid;
  grid-template-columns: minmax(240px, 320px) 1fr;
  gap: 18px;
  align-items: center;
}

.five-elements-chart-card {
  position: relative;
  padding: 18px;
  border-radius: 18px;
  background:
    radial-gradient(circle at 50% 35%, rgba(218, 165, 32, 0.16), transparent 40%),
    linear-gradient(180deg, #fffdf9 0%, #fff8ef 100%);
  border: 1px solid rgba(184, 134, 11, 0.16);
  min-height: 310px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.five-elements-chart-card[data-locked="true"] svg {
  filter: blur(7px);
  opacity: 0.78;
}

.five-elements-chart-card[data-locked="true"]::after {
  content: "符印未启\A 五行待观";
  position: absolute;
  inset: auto 16px 16px 16px;
  padding: 12px 14px;
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(139, 26, 26, 0.96) 0%, rgba(87, 19, 19, 0.94) 100%);
  border: 1px solid rgba(218, 165, 32, 0.26);
  color: #fff0d5;
  font-family: 'Noto Serif SC', serif;
  font-size: 0.88rem;
  line-height: 1.7;
  letter-spacing: 0.14em;
  white-space: pre-line;
  text-align: center;
  box-shadow: 0 12px 24px rgba(44, 24, 16, 0.18);
}

#five-elements-chart {
  width: 100%;
  height: auto;
  overflow: visible;
}

.chart-ring {
  fill: none;
  stroke: #e7d7c3;
  stroke-width: 1;
}

.chart-axis {
  stroke: #d6c5af;
  stroke-width: 1;
}

.chart-area {
  fill: url(#chartAreaGradient);
  stroke: #8b1a1a;
  stroke-width: 2.5;
}

.chart-label,
.chart-score {
  text-anchor: middle;
}

.chart-label {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  fill: var(--dark-soft);
  font-weight: 600;
}

.chart-score {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  fill: var(--text-light);
}

.five-elements-insights {
  display: grid;
  gap: 14px;
}

.element-pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.element-pill {
  min-width: 92px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(184, 134, 11, 0.16);
  background: rgba(255, 255, 255, 0.9);
  color: var(--dark-soft);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 0.92rem;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.55);
}

.element-pill span {
  font-weight: 600;
}

.element-pill strong {
  color: var(--pill-color);
  font-size: 0.9rem;
}

.insight-card {
  padding: 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(184, 134, 11, 0.14);
  box-shadow: 0 10px 26px rgba(44, 24, 16, 0.05);
}

.insight-label {
  display: inline-block;
  margin-bottom: 8px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold);
  font-weight: 700;
}

.insight-card p {
  margin: 0;
}

.historical-figures-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.historical-figure-card {
  padding: 18px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, #fffdf9 0%, #fff7ee 100%);
  border: 1px solid rgba(184, 134, 11, 0.16);
  box-shadow: 0 12px 28px rgba(44, 24, 16, 0.06);
}

.historical-figure-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.historical-figure-head h4 {
  margin: 0;
  color: var(--dark-soft);
  font-size: 1rem;
  font-family: 'Playfair Display', serif;
}

.historical-figure-year {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(184, 134, 11, 0.12);
  color: var(--red);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.historical-figure-card p {
  margin: 0;
  color: var(--text);
  line-height: 1.68;
}

.poetry {
  font-style: italic;
  color: var(--dark-soft) !important;
  border-left: 3px solid var(--gold);
  padding-left: 16px;
}

.characters-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
}

.char-card {
  background: var(--cream);
  border-radius: 8px;
  padding: 20px;
  text-align: center;
}

.char-card .char {
  font-family: 'Noto Serif SC', serif;
  font-size: 2.2rem;
  color: var(--red);
  margin-bottom: 4px;
}

.char-card .char-pinyin {
  font-size: 0.95rem;
  color: var(--gold);
  margin-bottom: 8px;
}

.char-card .char-meaning {
  font-size: 0.85rem;
  color: var(--text-light);
  line-height: 1.5;
}

/* ===== Actions ===== */
.actions-panel {
  margin-top: 26px;
  padding: 20px;
  border-radius: 16px;
  background:
    radial-gradient(circle at 85% 12%, rgba(218, 165, 32, 0.14), transparent 45%),
    linear-gradient(135deg, #fff9f2 0%, #fff4e9 100%);
  border: 1px solid rgba(184, 134, 11, 0.2);
  box-shadow: 0 14px 30px rgba(34, 24, 16, 0.08);
}

.actions-title {
  font-family: 'Playfair Display', serif;
  color: var(--dark-soft);
  font-size: 1.05rem;
  margin-bottom: 14px;
}

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

.actions .action-btn {
  width: 100%;
  min-height: 58px;
  padding: 14px 16px;
  border-radius: 12px;
  border-width: 1.5px;
  font-weight: 600;
  letter-spacing: 0.01em;
  box-shadow: 0 7px 18px rgba(44, 24, 16, 0.08);
}

.actions .action-btn:hover {
  transform: translateY(-2px);
}

.action-btn-primary {
  border: 1px solid #6f1414;
  background: linear-gradient(145deg, #8b1a1a 0%, #6f1414 100%);
  color: var(--cream);
}

.action-btn-primary:hover {
  background: linear-gradient(145deg, #9f1e1e 0%, #7f1717 100%);
  box-shadow: 0 10px 24px rgba(139, 26, 26, 0.32);
}

.action-btn-outline {
  border: 1px solid #dfc6a7;
  background: #fffdfb;
  color: var(--dark-soft);
}

.action-btn-outline:hover {
  border-color: #caa168;
  background: #fff7ec;
  box-shadow: 0 10px 22px rgba(184, 134, 11, 0.18);
}

.action-btn-ghost {
  border: 1px dashed rgba(122, 110, 101, 0.55);
  background: rgba(255, 255, 255, 0.6);
  color: var(--text);
}

.action-btn-ghost:hover {
  border-color: rgba(139, 26, 26, 0.45);
  background: rgba(255, 246, 236, 0.95);
  color: var(--dark-soft);
}

.action-btn-outline .spinner,
.action-btn-ghost .spinner {
  border-color: rgba(139, 26, 26, 0.2);
  border-top-color: var(--red);
}

.actions .action-btn:disabled {
  transform: none !important;
  box-shadow: none;
}

/* ===== Footer ===== */
.footer {
  text-align: center;
  padding: 32px 0;
  color: var(--text-light);
  font-size: 0.85rem;
  background: var(--dark);
  color: rgba(255,248,240,0.4);
}

.app-version-badge {
  position: fixed;
  right: 18px;
  bottom: 16px;
  z-index: 1200;
  min-width: 82px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(139, 26, 26, 0.2);
  background: linear-gradient(180deg, rgba(255, 250, 244, 0.94) 0%, rgba(249, 239, 226, 0.9) 100%);
  box-shadow: 0 12px 28px rgba(44, 24, 16, 0.14);
  color: var(--red);
  font-family: 'Playfair Display', serif;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-align: center;
  backdrop-filter: blur(10px);
  pointer-events: none;
}

.app-version-badge::before {
  content: "";
  position: absolute;
  inset: 3px;
  border: 1px solid rgba(184, 134, 11, 0.18);
  border-radius: 999px;
  pointer-events: none;
}

/* ===== Error ===== */
.error-message {
  background: #FFF0F0;
  color: #A11;
  padding: 14px 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  border: 1px solid #F5D0D0;
  display: none;
  font-size: 0.95rem;
  line-height: 1.5;
}

.payment-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.55);
}

.payment-modal-card {
  position: relative;
  width: min(540px, 94vw);
  background:
    radial-gradient(circle at top right, rgba(218, 165, 32, 0.14), transparent 36%),
    linear-gradient(180deg, #fffdf8 0%, #fff7ee 100%);
  border-radius: 22px;
  padding: 30px 24px 22px;
  text-align: center;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(184, 134, 11, 0.18);
}

.payment-section,
.payment-completion-section {
  min-height: 100vh;
  background:
    radial-gradient(circle at 18% 18%, rgba(218, 165, 32, 0.12), transparent 34%),
    radial-gradient(circle at 82% 10%, rgba(139, 26, 26, 0.09), transparent 30%),
    linear-gradient(180deg, #fffaf4 0%, #f9efe2 100%);
}

.payment-page-shell,
.payment-completion-shell {
  width: min(760px, 100%);
  margin: 0 auto;
}

.payment-page-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.payment-page-kicker {
  color: var(--text-light);
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.payment-page-back {
  min-width: 160px;
}

.payment-page-card {
  width: min(640px, 100%);
  margin: 0 auto;
}

.payment-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(139, 26, 26, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--dark-soft);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.payment-modal-close:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.95);
}

.payment-modal-head {
  margin-bottom: 18px;
}

.payment-modal-kicker {
  display: inline-block;
  margin-bottom: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(139, 26, 26, 0.08);
  color: var(--red);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.payment-modal-head h3 {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  color: var(--dark-soft);
}

.payment-provider-stack {
  display: grid;
  gap: 14px;
}

.payment-link-note {
  margin: 10px 0 0;
  color: var(--text-light);
  font-size: 0.92rem;
}

.payment-provider {
  text-align: left;
  border-radius: 18px;
  padding: 18px 16px;
  border: 1px solid rgba(122, 110, 101, 0.16);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 30px rgba(70, 45, 24, 0.06);
}

.payment-provider-copy {
  margin-bottom: 14px;
}

.payment-provider-copy h4 {
  font-family: 'Playfair Display', serif;
  font-size: 1.35rem;
  color: var(--dark-soft);
  margin-bottom: 4px;
}

.payment-provider-copy p {
  color: var(--text-light);
  font-size: 0.94rem;
}

.payment-provider-pill {
  display: inline-block;
  margin-bottom: 10px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(46, 125, 50, 0.1);
  color: #1f5f2a;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.payment-provider-stripe {
  background:
    radial-gradient(circle at top right, rgba(139, 26, 26, 0.07), transparent 42%),
    linear-gradient(180deg, #fffdfb 0%, #fff8f1 100%);
  border-color: rgba(184, 134, 11, 0.2);
}

.payment-provider-paypal {
  background:
    radial-gradient(circle at top left, rgba(40, 87, 166, 0.07), transparent 38%),
    linear-gradient(180deg, #ffffff 0%, #fcf7f0 100%);
}

.payment-provider-divider {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--text-light);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.payment-provider-divider::before {
  content: "";
  position: absolute;
  inset: 50% 0 auto;
  border-top: 1px solid rgba(122, 110, 101, 0.2);
}

.payment-provider-divider span {
  position: relative;
  padding: 0 12px;
  background: #fff9f2;
}

.stripe-followup {
  margin-top: 12px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(139, 26, 26, 0.05);
  border: 1px solid rgba(139, 26, 26, 0.12);
}

.stripe-followup.error {
  background: rgba(139, 26, 26, 0.07);
  border-color: rgba(139, 26, 26, 0.2);
}

.stripe-followup.success {
  background: rgba(46, 125, 50, 0.09);
  border-color: rgba(46, 125, 50, 0.22);
}

.stripe-followup-text {
  color: var(--text);
  font-size: 0.9rem;
  margin-bottom: 10px;
}

.stripe-followup-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.stripe-followup-actions .btn {
  flex: 1 1 180px;
}

.promo-code-wrap {
  margin-bottom: 2px;
  text-align: left;
  padding: 14px 12px;
  border-radius: 10px;
  border: 1px solid rgba(122, 110, 101, 0.2);
  background: rgba(255, 248, 240, 0.7);
}

.promo-code-label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.86rem;
  color: var(--text-light);
}

.promo-code-row {
  display: flex;
  gap: 8px;
}

.promo-code-input {
  flex: 1;
  min-width: 0;
  border: 1px solid rgba(122, 110, 101, 0.32);
  border-radius: 8px;
  padding: 10px 11px;
  font-size: 0.95rem;
  background: #fff;
}

.promo-code-input:focus {
  outline: none;
  border-color: rgba(139, 26, 26, 0.45);
  box-shadow: 0 0 0 2px rgba(139, 26, 26, 0.12);
}

#promo-code-btn {
  min-width: 106px;
}

.promo-code-feedback {
  min-height: 18px;
  margin: 8px 0 0;
  font-size: 0.84rem;
  color: var(--text-light);
}

.promo-code-feedback.success {
  color: #1f5f2a;
}

.promo-code-feedback.error {
  color: #8b1a1a;
}

.paypal-buttons-host {
  min-height: 52px;
  margin-bottom: 0;
}

.paypal-placeholder {
  color: var(--text-light);
  font-size: 0.9rem;
  margin: 8px 0;
}

.payment-completion-shell {
  display: flex;
  justify-content: center;
}

.payment-status-page {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background:
    radial-gradient(circle at 20% 20%, rgba(218, 165, 32, 0.22), transparent 45%),
    radial-gradient(circle at 80% 15%, rgba(196, 30, 58, 0.18), transparent 40%),
    linear-gradient(135deg, #1a1110 0%, #2d1713 50%, #402018 100%);
}

.payment-status-card {
  width: min(680px, 92vw);
  background: rgba(255, 248, 240, 0.97);
  border-radius: 18px;
  padding: 42px 34px;
  text-align: center;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(184, 134, 11, 0.35);
}

.payment-completion-section .payment-status-card {
  width: min(680px, 100%);
  margin: 0 auto;
}

.payment-status-icon {
  width: 62px;
  height: 62px;
  margin: 0 auto 14px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 1.8rem;
  font-weight: 700;
  color: #7a1f1f;
  background: rgba(218, 165, 32, 0.2);
  border: 1px solid rgba(184, 134, 11, 0.45);
}

.payment-status-badge {
  display: inline-block;
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 14px;
  color: #7a1f1f;
  background: rgba(218, 165, 32, 0.18);
}

#payment-status-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4vw, 2.8rem);
  color: #4a1612;
  margin-bottom: 10px;
}

#payment-status-subtitle {
  color: #5f4139;
  font-size: 1.08rem;
  margin-bottom: 12px;
}

.payment-status-detail {
  color: #6f554d;
  font-size: 0.95rem;
  margin-bottom: 26px;
}

.payment-status-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.payment-status-card.success {
  border-color: rgba(46, 125, 50, 0.35);
}

.payment-status-card.success .payment-status-icon {
  color: #1f5f2a;
  background: rgba(46, 125, 50, 0.18);
  border-color: rgba(46, 125, 50, 0.35);
}

.payment-status-card.success .payment-status-badge {
  color: #1f5f2a;
  background: rgba(46, 125, 50, 0.16);
}

.payment-status-card.failed {
  border-color: rgba(139, 26, 26, 0.4);
}

.payment-status-card.failed .payment-status-icon {
  color: #8b1a1a;
  background: rgba(139, 26, 26, 0.14);
  border-color: rgba(139, 26, 26, 0.35);
}

.payment-status-card.failed .payment-status-badge {
  color: #8b1a1a;
  background: rgba(139, 26, 26, 0.14);
}

/* ===== Responsive ===== */
@media (max-width: 600px) {
  .section { padding: 56px 0; }
  .container { padding: 0 18px; }
  .hero { min-height: 88vh; padding: 36px 0 58px; }
  .hero-title { font-size: clamp(2.4rem, 13vw, 3.8rem); line-height: 1.05; }
  .hero-subtitle { font-size: 1rem; max-width: 320px; margin-bottom: 28px; }
  .form-row { grid-template-columns: 1fr; }
  .name-form { padding: 22px 18px; border-radius: 18px; }
  .birth-details-grid { grid-template-columns: 1fr; }
  .dob-select-grid { grid-template-columns: 1fr 1fr 1fr; }
  .loading-phase { font-size: 0.78rem; padding: 7px 14px; margin-bottom: 18px; }
  .loading-tableau { width: 280px; height: 286px; margin-bottom: 26px; }
  .loading-halo { inset: 46px 46px 44px; }
  .loading-moon-gate { inset: 16px 26px 36px; }
  .loading-orbit-outer { inset: 4px 18px 22px; }
  .loading-orbit-inner { inset: 34px 52px 64px; }
  .loading-cloud-a { width: 88px; top: 70px; left: 4px; }
  .loading-cloud-b { width: 104px; right: 0; bottom: 66px; }
  .loading-scroll { width: 146px; height: 196px; top: 44px; }
  .loading-scroll-paper { left: 12px; right: 12px; top: 12px; bottom: 16px; }
  .loading-tassel-left { left: 28px; }
  .loading-tassel-right { right: 28px; }
  .loading-plate { width: 124px; height: 134px; top: 106px; }
  .loading-seal { width: 34px; height: 34px; font-size: 1rem; border-radius: 12px; }
  .loading-seal-a { left: 36px; top: 72px; }
  .loading-seal-b { right: 36px; bottom: 58px; }
  .loading-card-glyph-main { font-size: 3.8rem; }
  .loading-plate .loading-card-glyph-main { font-size: 3.45rem; }
  .loading-progress-wrap { max-width: 320px; margin-bottom: 18px; }
  .loading-progress-meta { gap: 10px; margin-top: 8px; }
  .loading-progress-label { font-size: 0.78rem; }
  .loading-progress-percent { font-size: 0.92rem; min-width: 40px; }
  .loading-stage-strip { gap: 8px; }
  .loading-stage-dot { padding: 8px 6px; font-size: 0.9rem; border-radius: 12px; }
  .loading-runes { height: 46px; max-width: 320px; margin-bottom: 6px; }
  .loading-text { font-size: 1.28rem; }
  .loading-subtext { font-size: 0.92rem; max-width: 320px; }
  .loading-mantra { gap: 10px; padding: 8px 14px; margin-top: 16px; }
  .app-version-badge { right: 12px; bottom: 12px; min-width: 72px; padding: 7px 10px; font-size: 0.72rem; }
  .blur-container.has-lock-badge { min-height: 68px; padding: 14px 0; }
  .lock-icon { max-width: calc(100% - 12px); padding: 6px 8px 6px 6px; gap: 6px; border-radius: 14px; }
  .lock-icon-seal { width: 28px; height: 28px; border-radius: 10px; font-size: 1rem; }
  .lock-icon-copy strong { font-size: 0.72rem; letter-spacing: 0.06em; }
  .lock-icon-copy span { font-size: 0.54rem; letter-spacing: 0.04em; }
  .shared-report-banner { padding: 16px; border-radius: 16px; }
  .result-card { border-radius: 18px; }
  .name-display { padding: 34px 20px 24px; }
  .chinese-name { font-size: 3rem; letter-spacing: 0.08em; }
  .profile-code-panel { width: 100%; }
  .result-block { padding: 20px 18px; }
  .characters-grid { grid-template-columns: 1fr; }
  .feature-head { margin-bottom: 14px; }
  .five-elements-layout { grid-template-columns: 1fr; }
  .five-elements-chart-card { min-height: 280px; padding: 12px; }
  .element-pill-row { gap: 8px; }
  .element-pill { flex: 1 1 calc(50% - 8px); min-width: 0; }
  .historical-figures-grid { grid-template-columns: 1fr; }
  .actions-panel { padding: 16px; }
  .actions { grid-template-columns: 1fr; }
  .actions .action-btn { min-height: 54px; }
  .payment-modal-card { padding: 24px 18px 18px; border-radius: 18px; }
  .payment-page-topbar { flex-direction: column; align-items: stretch; }
  .payment-page-back { width: 100%; }
  .payment-modal-head h3 { font-size: 1.75rem; }
  .payment-provider { padding: 16px 14px; border-radius: 16px; }
  .stripe-followup-actions { flex-direction: column; }
  .stripe-followup-actions .btn { width: 100%; }
  .promo-code-row { flex-direction: column; }
  #promo-code-btn { width: 100%; }
  .payment-status-card { padding: 30px 22px; }
  .payment-status-actions { flex-direction: column; }
  .payment-status-actions .btn { width: 100%; }
}

/* ===== Social Share Panel ===== */
.share-panel {
  margin-top: 20px;
  padding: 20px;
  background: linear-gradient(135deg, #fffdf9 0%, #fff5e8 100%);
  border: 1px solid rgba(184, 134, 11, 0.18);
  border-radius: var(--radius);
  text-align: center;
}

.share-title {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  font-weight: 600;
  color: var(--dark-soft);
  margin-bottom: 12px;
}

.share-buttons {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border: 1px solid rgba(0,0,0,0.12);
  border-radius: 8px;
  background: var(--white);
  color: var(--text);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: 'Inter', sans-serif;
}

.share-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.share-btn-x {
  border-color: #000;
  color: #000;
}
.share-btn-x:hover {
  background: #000;
  color: #fff;
}

.share-btn-facebook {
  border-color: #1877F2;
  color: #1877F2;
}
.share-btn-facebook:hover {
  background: #1877F2;
  color: #fff;
}

.share-btn-whatsapp {
  border-color: #25D366;
  color: #128C7E;
}
.share-btn-whatsapp:hover {
  background: #25D366;
  color: #fff;
}

.share-btn-copy {
  border-color: var(--gold);
  color: var(--gold);
}
.share-btn-copy:hover {
  background: var(--gold);
  color: #fff;
}

@media (max-width: 480px) {
  .share-buttons {
    flex-direction: column;
    align-items: stretch;
  }
  .share-btn {
    justify-content: center;
  }
}
