/* ===== 搜索关键词高亮 ===== */
mark.search-highlight {
  background: #fcb040;
  color: #3a2500;
  padding: 1px 3px;
  border-radius: 3px;
  box-shadow: 0 0 0 2px rgba(252,176,64,0.3);
  animation: highlightPulse 1.5s ease-out;
}
@keyframes highlightPulse {
  0% { background: #ff8c00; box-shadow: 0 0 8px 2px rgba(252,176,64,0.6); }
  100% { background: #fcb040; box-shadow: 0 0 0 2px rgba(252,176,64,0.3); }
}

/* ===== Blur Mask on Cards ===== */
.tarot-blur-mask {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(20, 10, 40, 0.35);
  backdrop-filter: blur(6px) brightness(0.7);
  -webkit-backdrop-filter: blur(6px) brightness(0.7);
  z-index: 5;
  pointer-events: none;
  transition: opacity 0.6s ease;
  border-radius: 12px;
}
.tarot-blur-mask.tarot-blur-mask-hide {
  opacity: 0;
  pointer-events: none;
}

/* ===== Draw Button Overlay ===== */
.tarot-overlay-btn {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  pointer-events: none;
  transition: opacity 0.4s ease;
}
.tarot-overlay-btn.tarot-overlay-hide {
  opacity: 0;
  pointer-events: none;
}

.tarot-draw-btn {
  pointer-events: auto;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 3px;
  line-height: 1.4;
  color: #f0e6d0;
  background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.15) 0%, transparent 50%),
              linear-gradient(160deg, #1a0a2e 0%, #2d1546 40%, #1a0a2e 100%);
  border: 1.5px solid rgba(201, 168, 76, 0.6);
  cursor: pointer;
  box-shadow: 0 0 0 4px rgba(201, 168, 76, 0.08),
              0 0 0 8px rgba(201, 168, 76, 0.04),
              0 8px 32px rgba(0, 0, 0, 0.5),
              inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.tarot-draw-btn::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: conic-gradient(from 0deg, transparent, rgba(201, 168, 76, 0.1), transparent, rgba(201, 168, 76, 0.05), transparent);
  animation: tarot-btn-spin 8s linear infinite;
}

.tarot-draw-btn .stars-wrap {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  pointer-events: none;
}

.tarot-draw-btn .star-icon {
  position: absolute;
  font-size: 9px;
  color: rgba(201, 168, 76, 0.7);
  animation: star-sparkle 2s ease-in-out infinite;
  text-shadow: 0 0 4px rgba(201, 168, 76, 0.3);
}

@keyframes star-sparkle {
  0%, 100% {
    opacity: 0.4;
    transform: scale(0.8);
    text-shadow: 0 0 2px rgba(201, 168, 76, 0.2);
  }
  25% {
    opacity: 1;
    transform: scale(1.2);
    text-shadow: 0 0 8px rgba(201, 168, 76, 0.8),
                 0 0 16px rgba(201, 168, 76, 0.4),
                 0 0 24px rgba(201, 168, 76, 0.2);
  }
  50% {
    opacity: 0.7;
    transform: scale(1);
    text-shadow: 0 0 4px rgba(201, 168, 76, 0.4);
  }
  75% {
    opacity: 1;
    transform: scale(1.3);
    text-shadow: 0 0 12px rgba(255, 215, 100, 0.9),
                 0 0 20px rgba(201, 168, 76, 0.5),
                 0 0 32px rgba(201, 168, 76, 0.3);
  }
}

@keyframes tarot-btn-spin {
  to { transform: rotate(360deg); }
}

.tarot-draw-btn:hover {
  border-color: rgba(201, 168, 76, 0.9);
  box-shadow: 0 0 0 4px rgba(201, 168, 76, 0.12),
              0 0 0 8px rgba(201, 168, 76, 0.06),
              0 0 40px rgba(201, 168, 76, 0.15),
              0 12px 40px rgba(0, 0, 0, 0.5);
  transform: translateY(-3px) scale(1.04);
  color: #fff;
  text-shadow: 0 0 8px rgba(201, 168, 76, 0.4);
}

.tarot-draw-btn:active {
  transform: translateY(1px) scale(0.96);
  box-shadow: 0 0 0 2px rgba(201, 168, 76, 0.15),
              0 4px 16px rgba(0, 0, 0, 0.5);
  transition-duration: 0.1s;
}

/* ===== Intro Button on Overlay ===== */
.tarot-intro-btn {
  position: absolute;
  bottom: 14px;
  right: 14px;
  z-index: 25;
  width: 26px;
  height: 26px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  font-style: normal;
  color: rgba(201, 168, 76, 0.85);
  background: rgba(26, 10, 46, 0.65);
  border: 1px solid rgba(201, 168, 76, 0.35);
  border-radius: 50%;
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: all 0.3s ease;
  line-height: 1;
}
.tarot-intro-btn:hover {
  color: #e8d5a3;
  background: rgba(45, 27, 78, 0.9);
  border-color: rgba(201, 168, 76, 0.8);
  box-shadow: 0 0 14px rgba(201, 168, 76, 0.35);
  transform: scale(1.1);
}

/* ===== Intro Modal ===== */
.tarot-intro-modal {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 9999;
  background: rgba(10, 5, 20, 0.85);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: tarot-modal-in 0.3s ease;
}
.tarot-intro-modal-hide {
  animation: tarot-modal-out 0.3s ease forwards;
}
@keyframes tarot-modal-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes tarot-modal-out { from { opacity: 1; } to { opacity: 0; } }

.tarot-intro-modal-inner {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
}
.tarot-intro-modal-close {
  position: absolute;
  top: -36px;
  right: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(201, 168, 76, 0.2);
  border: 1px solid rgba(201, 168, 76, 0.5);
  color: #c9a84c;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}
.tarot-intro-modal-close:hover {
  background: rgba(201, 168, 76, 0.4);
  transform: scale(1.1);
}
.tarot-intro-modal-img {
  max-width: 90vw;
  max-height: 80vh;
}

/* ===== 3D Flip Card Animation ===== */

/* Flip container: preserves original absolute positioning + adds perspective */
.tarot-flip-container {
  perspective: 1200px;
  -webkit-perspective: 1200px;
}

/* Flipper: the rotating element */
.tarot-flipper {
  position: relative;
  transform-style: preserve-3d;
  -webkit-transform-style: preserve-3d;
  transition: transform 0.8s cubic-bezier(0.4, 0.0, 0.2, 1);
  -webkit-transition: -webkit-transform 0.8s cubic-bezier(0.4, 0.0, 0.2, 1);
}

/* Flipped state: rotate 180 degrees */
.tarot-flipper.flipped {
  transform: rotateY(180deg);
  -webkit-transform: rotateY(180deg);
}

/* Back face (bj.png): visible by default */
.tarot-flip-back {
  position: absolute;
  top: 0;
  left: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  z-index: 2;
}

.tarot-flip-back img {
  display: block;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Front face (card image): hidden initially, revealed on flip */
.tarot-flip-front {
  position: absolute;
  top: 0;
  left: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  transform: rotateY(180deg);
  -webkit-transform: rotateY(180deg);
}

.tarot-flip-front img {
  display: block;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Gold glow after flip completes */
.tarot-glow .tarot-flip-front img {
  animation: tarotGlow 1.5s ease-in-out;
  -webkit-animation: tarotGlow 1.5s ease-in-out;
}

@keyframes tarotGlow {
  0% { box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3); }
  50% { box-shadow: 0 0 20px rgba(201, 168, 76, 0.6), 0 0 40px rgba(201, 168, 76, 0.3); }
  100% { box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3); }
}

/* ===== Lazy Load Fade-in ===== */
.tarot-lazy {
  opacity: 0;
  transition: opacity 0.4s ease-in;
  -webkit-transition: opacity 0.4s ease-in;
}

.tarot-lazy.loaded {
  opacity: 1;
}

/* ===== Mobile Menu (replaces Foundation toggle) ===== */

/* Hide Foundation's toggle-topbar immediately to prevent "Menu" flash */
li.toggle-topbar.menu-icon { display: none !important; }

/* Hamburger button positioning (replaces Foundation toggle-topbar) */
/* Hamburger button: only visible on tablet/mobile */
@media (min-width: 1025px) {
  .top-bar .tarot-hamburger {
    display: none !important;
  }
}
.top-bar .tarot-hamburger {
  position: absolute;
  right: 15px;
  top: 50%;
  margin-top: -22px;
  list-style: none;
}
/* Hamburger icon: 3-line bars via CSS */
.top-bar .tarot-hamburger a {
  padding: 0 16px !important;
  text-indent: 0 !important;
  font-size: 0 !important;
  width: 44px;
  height: 44px;
  display: flex !important;
  align-items: center;
  justify-content: center;
  position: relative;
  cursor: pointer;
  color: #fff;
  line-height: 44px;
}
.top-bar .tarot-hamburger a span {
  text-indent: 0 !important;
  padding: 0 !important;
  font-size: 0 !important;
  display: block;
  width: 22px;
  height: 2px;
  background: #222 !important;
  position: relative;
  transition: background 0.3s;
  box-shadow: none !important;
  border-radius: 1px;
}
.top-bar .tarot-hamburger a span::before,
.top-bar .tarot-hamburger a span::after {
  content: '';
  position: absolute;
  left: 0;
  width: 22px;
  height: 2px;
  background: #222;
  transition: transform 0.3s, top 0.3s, background 0.3s;
  border-radius: 1px;
}
.top-bar .tarot-hamburger a span::before {
  top: -7px;
}
.top-bar .tarot-hamburger a span::after {
  top: 7px;
}

/* Hamburger → X animation when expanded */
.top-bar.tarot-menu-open .tarot-hamburger a span {
  background: transparent !important;
}
.top-bar.tarot-menu-open .tarot-hamburger a span::before {
  top: 0;
  transform: rotate(45deg);
  background: #c9a84c;
}
.top-bar.tarot-menu-open .tarot-hamburger a span::after {
  top: 0;
  transform: rotate(-45deg);
  background: #c9a84c;
}

/* Expanded dropdown panel */
.top-bar.tarot-menu-open {
  overflow: visible;
}
.top-bar .tarot-mobile-dropdown {
  display: none;
  position: absolute;
  top: 78px;
  right: 0;
  min-width: 180px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  z-index: 999;
  padding: 8px 0;
  border-radius: 0 0 8px 8px;
  animation: tarot-menu-slide 0.25s ease;
}
.top-bar.tarot-menu-open .tarot-mobile-dropdown {
  display: block;
}

@keyframes tarot-menu-slide {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.tarot-mobile-dropdown ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.tarot-mobile-dropdown li {
  border-bottom: 1px solid #f0ebe3;
}
.tarot-mobile-dropdown li:last-child {
  border-bottom: none;
}
.tarot-mobile-dropdown li a {
  display: block;
  padding: 12px 20px;
  color: #222 !important;
  font-size: 15px !important;
  line-height: 1.5 !important;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.2s, color 0.2s;
}
.tarot-mobile-dropdown li a:hover {
  background: #faf5ed;
  color: #c9a84c !important;
}
.tarot-mobile-dropdown li a.button {
  background: #c9a84c !important;
  color: #fff !important;
  text-align: center;
  margin: 8px 16px;
  border-radius: 6px;
  padding: 10px 24px !important;
}
.tarot-mobile-dropdown li a.button:hover {
  background: #b8963e !important;
}

/* Desktop: hide mobile dropdown, show normal top-bar-section */
@media (min-width: 1025px) {
  .top-bar .tarot-mobile-dropdown {
    display: none !important;
  }
  .top-bar.tarot-menu-open .tarot-mobile-dropdown {
    display: none !important;
  }
  /* 导航栏居中布局 */
  .top-bar {
    text-align: center;
  }
  .top-bar .title-area {
    float: none !important;
    display: inline-block;
    vertical-align: middle;
    margin-right: 24px;
  }
  .top-bar-section {
    float: none !important;
    display: inline-block;
    vertical-align: middle;
  }
  .top-bar-section ul.right {
    float: none !important;
  }
  .top-bar-section ul li {
    margin-left: 2px;
    margin-right: 2px;
  }
  /* Nav links use site main tone instead of dark background */
  .top-bar-section li a:not(.button) {
    background: transparent !important;
    color: #5a3e1b !important;
    transition: all 0.2s ease;
  }
  .top-bar-section li a:not(.button):hover {
    background: #fcb040 !important;
    color: #fff !important;
  }
  /* "我要占卜" button follows site main tone */
  .top-bar-section li a.button {
    background: #fcb040 !important;
    color: #fff !important;
    border: 1px solid #e09a20 !important;
    border-radius: 4px !important;
    transition: all 0.2s ease;
  }
  .top-bar-section li a.button:hover {
    background: #fb9b0e !important;
    color: #fff !important;
  }
}

/* ===== Quote Carousel (replaces Foundation Orbit) ===== */
.tarot-carousel-bullets {
  text-align: center;
  padding: 10px 0 20px;
}
.tarot-carousel-bullets span {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ccc;
  margin: 0 4px;
  cursor: pointer;
  transition: background 0.3s;
}
.tarot-carousel-bullets span.active {
  background: #fcb040;
}
.tarot-carousel-bullets span:hover {
  background: #e6a03a;
}
/* 修复卡牌区域显示 - header内的卡牌图片不受header img样式影响 */
header div[style*="width:350px"] img,
header div[style*="width: 350px"] img,
header div[style*="position:relative"] img,
header div[style*="position: relative"] img {
    margin-bottom: 0 !important;
    max-height: none !important;
}

/* 卡牌容器定位 - 确保卡牌相对容器定位 */
header div[style*="width:350px"],
header div[style*="width: 350px"] {
    position: relative !important;
}

/* 翻牌容器继承绝对定位 */
.tarot-flip-container {
    perspective: 1200px;
    -webkit-perspective: 1200px;
}

/* 翻牌容器内的图片不受header img规则影响 */
header .tarot-flip-container img,
header .tarot-flip-back img,
header .tarot-flip-front img {
    margin-bottom: 0 !important;
    max-height: none !important;
}

/* Tablet/Mobile: hide Foundation's top-bar-section completely - we use our own dropdown */
@media (max-width: 1024px) {
  .top-bar-section {
    display: none !important;
  }
}

/* ===== Card Interpretation Modal ===== */
.interpret-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
  padding: 16px;
}
.interpret-overlay.interpret-overlay-visible {
  background: rgba(0, 0, 0, 0.65);
}

.interpret-modal {
  background: #fffdf8;
  border-radius: 16px;
  max-width: 480px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  opacity: 0;
  transform: translateY(30px) scale(0.95);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.interpret-modal.interpret-modal-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.interpret-modal::-webkit-scrollbar {
  width: 6px;
}
.interpret-modal::-webkit-scrollbar-track {
  background: transparent;
}
.interpret-modal::-webkit-scrollbar-thumb {
  background: #e0d5c5;
  border-radius: 3px;
}

.interpret-close {
  position: sticky;
  top: 0;
  right: 0;
  text-align: right;
  padding: 12px 16px 0 0;
  font-size: 28px;
  color: #a09888;
  cursor: pointer;
  z-index: 10;
  line-height: 1;
  transition: color 0.2s;
}
.interpret-close:hover {
  color: #fcb040;
}

.interpret-content {
  padding: 0 24px 28px;
}

.interpret-loading {
  text-align: center;
  padding: 40px 0;
  color: #a09888;
}
.interpret-loading p {
  margin-top: 16px;
  font-size: 14px;
}
.interpret-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #e8e0d5;
  border-top-color: #fcb040;
  border-radius: 50%;
  margin: 0 auto;
  animation: interpret-spin 0.8s linear infinite;
}
@keyframes interpret-spin {
  to { transform: rotate(360deg); }
}

.interpret-header {
  text-align: center;
  margin-bottom: 16px;
}
.interpret-card-img-link {
  display: inline-block;
  margin-bottom: 10px;
  transition: transform 0.2s;
}
.interpret-card-img-link:hover {
  transform: scale(1.03);
}
.interpret-card-img {
  width: 120px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 3px 12px rgba(0,0,0,0.15);
  transition: transform 0.6s cubic-bezier(0.4,0,0.2,1);
}
.interpret-card-img.interpret-card-reversed {
  transform: rotate(180deg);
}
.interpret-card-pos-num {
  position: absolute;
  top: calc(50% - 18px);
  right: 8px;
  width: 26px;
  height: 26px;
  line-height: 26px;
  text-align: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #fcb040, #f0a030);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(252,176,64,0.4);
}
.interpret-popup-pos-num {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 22px;
  height: 22px;
  line-height: 18px;
  text-align: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #c9956a, #a87b52);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 1px 4px rgba(169,123,82,0.35);
  border: 2px solid rgba(255,255,255,0.85);
  z-index: 1;
}
.interpret-card-header {
  position: relative;
}
.interpret-header {
  position: relative;
}
.interpret-card-name {
  font-size: 22px;
  font-weight: 700;
  color: #3d2e1e;
  margin-bottom: 4px;
}
.interpret-card-en {
  font-size: 13px;
  color: #b0a090;
  margin-bottom: 6px;
  font-style: italic;
}
.interpret-card-link-text {
  color: inherit;
  text-decoration: none;
  font-size: inherit;
  font-weight: inherit;
  font-style: inherit;
}
.interpret-card-link-text:hover {
  text-decoration: none;
}
.interpret-position {
  display: inline-block;
  background: linear-gradient(135deg, #fcb040, #f0a030);
  color: #fff;
  font-size: 12px;
  padding: 3px 14px;
  border-radius: 12px;
  margin-bottom: 10px;
}
.interpret-keywords {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  margin-top: 8px;
}
.interpret-kw {
  background: #f5efe6;
  color: #8b7355;
  font-size: 12px;
  padding: 2px 10px;
  border-radius: 10px;
  border: 1px solid #e8ddd0;
}

.interpret-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent 5%, #d4c4b0 30%, #c9956a 50%, #d4c4b0 70%, transparent 95%);
  margin: 22px 0;
  position: relative;
}

.interpret-section {
  margin-bottom: 16px;
}
.interpret-section-title {
  font-size: 14px;
  font-weight: 600;
  color: #fcb040;
  margin-bottom: 8px;
  padding-left: 10px;
  border-left: 3px solid #fcb040;
}
.interpret-section-text {
  font-size: 14px;
  line-height: 1.8;
  color: #5a4a3a;
  text-align: justify;
}

.interpret-highlight {
  background: #fef8ee;
  border-left: 3px solid #fcb040;
  padding: 10px 12px;
  border-radius: 0 8px 8px 0;
}

.interpret-muted {
  color: #9a8a7a;
  font-size: 13px;
}

.interpret-error {
  text-align: center;
  padding: 30px 0;
  color: #cc5533;
}

/* Make flipped cards clickable with pointer cursor */
.tarot-flip-front a {
  cursor: pointer;
}
.tarot-flip-front a:hover img {
  box-shadow: 0 0 12px rgba(252,176,64,0.5);
  transition: box-shadow 0.3s ease;
}

/* Mobile adjustments */
@media (max-width: 640px) {
  .interpret-modal {
    max-height: 90vh;
    border-radius: 12px;
  }
  .interpret-content {
    padding: 0 18px 24px;
  }
  .interpret-card-name {
    font-size: 20px;
  }
  .interpret-section-text {
    font-size: 13.5px;
    line-height: 1.75;
  }
}
.nav-active { color: #fcb040 !important; font-weight: 600; }


.top-bar.has-orange-line { border-bottom: 1px solid #fcb040; }

.hb-part-title-link {
  display: block;
  text-decoration: none;
  color: inherit;
}
a.hb-part-title {
  display: block;
  text-decoration: none;
  color: inherit;
  transition: color 0.2s;
}
a.hb-part-title:hover {
  color: #fcb040;
}

.hb-breadcrumb {
  font-size: 14px;
  color: #999;
  padding: 10px 0 5px;
}
.hb-breadcrumb a {
  color: #999;
  text-decoration: none;
  transition: color 0.2s;
}
.hb-breadcrumb a:hover {
  color: #fcb040;
}
.hb-breadcrumb .bc-sep {
  margin: 0 6px;
  color: #ccc;
}
.hb-breadcrumb .bc-current {
  color: #fcb040;
  font-weight: 500;
}

/* Card detail page hero layout */
.card-hero {
  display: flex;
  align-items: flex-start;
  gap: 28px;
  margin-bottom: 28px;
  padding: 24px;
  background: linear-gradient(135deg, #fdf8f0 0%, #f5efe6 50%, #ede4d6 100%);
  border-radius: 16px;
  border: 1px solid #e8dcc8;
}
.card-image-wrap {
  position: relative;
  flex-shrink: 0;
  perspective: 800px;
}
.card-image-wrap::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 14px;
  background: linear-gradient(135deg, #fcb040, #e8a030, #d4933a, #fcb040);
  background-size: 200% 200%;
  animation: cardGlow 3s ease infinite;
  z-index: 0;
}
.card-image-wrap::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 12px;
  background: #fff;
  z-index: 1;
}
.card-image {
  position: relative;
  width: 240px;
  min-width: 240px;
  height: auto;
  border-radius: 10px;
  z-index: 2;
  display: block;
  transition: transform 0.6s cubic-bezier(0.4, 0.0, 0.2, 1);
  transform-style: preserve-3d;
}
.card-image.card-reversed {
  transform: rotate(180deg);
}
.card-orientation-toggle {
  display: flex;
  gap: 0;
  margin-top: 10px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #e8dcc8;
  position: relative;
  z-index: 3;
}
.card-orientation-btn {
  flex: 1;
  padding: 6px 0;
  border: none;
  background: #fff;
  color: #8a7040;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.25s ease;
  font-weight: 500;
  text-align: center;
}
.card-orientation-btn + .card-orientation-btn {
  border-left: 1px solid #e8dcc8;
}
.card-orientation-btn.active {
  background: linear-gradient(135deg, #fcb040, #e8a030);
  color: #fff;
  font-weight: 600;
}
.card-orientation-btn:first-child.active {
  background: linear-gradient(135deg, #fcb040, #e8a030);
}
.card-orientation-btn:last-child.active {
  background: linear-gradient(135deg, #c4786a, #a86050);
}
.card-orientation-btn:hover:not(.active) {
  background: #fef3dc;
}
.card-hero-info {
  flex: 1;
  padding-top: 4px;
}
@keyframes cardGlow {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}
@media (max-width: 480px) {
  .card-hero {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 20px 16px;
  }
  .card-image {
    width: 140px;
    min-width: 140px;
  }
  .card-orientation-toggle {
    width: 140px;
  }
  .card-hero-info {
    padding-top: 0;
  }
}

/* ========== 更多牌阵链接 ========== */
.more-spreads-link {
  text-align: center;
  padding: 12px 18px;
  margin: 0 auto 20px;
  max-width: 280px;
  background: linear-gradient(135deg, #fff8ee 0%, #fef3dc 100%);
  border-radius: 10px;
  border: 1px solid #f5e0b0;
  box-shadow: 0 2px 8px rgba(252,176,64,0.08);
}
.more-spreads-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #fcb040;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
}
.more-spreads-btn:hover {
  color: #e09a30;
  background: rgba(252,176,64,0.1);
  border-radius: 4px;
  text-decoration: none;
}
.more-spreads-btn svg {
  flex-shrink: 0;
}

/* ========== 全站页尾 ========== */
.tarot-footer {
  padding: 24px 20px;
  margin-top: 0;
  border-top: 1px solid #f0dfc0;
  background: linear-gradient(to bottom, #fffaf3, #fef6e8);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.tarot-footer-text {
  font-size: 14px;
  color: #b8935a;
  letter-spacing: 1px;
  text-align: center;
}
.tarot-footer-text span {
  color: #d4a545;
  font-weight: 600;
}
.tarot-footer-search {
  margin-top: 12px;
  display: flex;
  justify-content: center;
}
.tarot-footer-search-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 18px;
  border-radius: 20px;
  border: 1px solid #e8d5b0;
  background: rgba(255,255,255,0.6);
  color: #b8935a;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}
.tarot-footer-search-btn:hover {
  background: rgba(255,255,255,0.9);
  border-color: #d4a545;
  color: #c87f1a;
}

/* 牌面细节样式 */
.interpret-detail {
    color: #7a6040;
    font-style: italic;
    border-left: 2px solid #f0dfc0;
    padding-left: 12px;
}
.interpret-card-section .interpret-detail {
    color: #7a6040;
    font-style: italic;
    border-left: 2px solid #f0dfc0;
    padding-left: 12px;
}

