/* Realms Hero */
.realms-hero {
  background: linear-gradient(180deg, var(--dark-ink) 0%, rgba(30, 73, 59, 0.1) 50%, var(--dark-ink) 100%);
  padding-top: 140px;
}

.realms-intro {
  max-width: 900px;
  margin: 48px auto 60px;
  text-align: center;
}

.realms-intro p {
  color: rgba(245, 237, 224, 0.75);
  line-height: 2;
  font-size: 1.05rem;
}

/* Realms Navigation */
.realms-nav {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 40px;
}

.realm-nav-btn {
  padding: 14px 36px;
  background: transparent;
  border: 2px solid rgba(212, 175, 55, 0.25);
  color: var(--cloud-white);
  border-radius: 30px;
  text-decoration: none;
  font-size: 1rem;
  transition: all 0.3s ease;
  letter-spacing: 2px;
  position: relative;
  overflow: hidden;
}

.realm-nav-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.puer-btn:hover {
  background: rgba(46, 125, 50, 0.3);
  border-color: #66bb6a;
}

.liubao-btn:hover {
  background: rgba(69, 90, 100, 0.3);
  border-color: #90a4ae;
}

.baicha-btn:hover {
  background: rgba(176, 190, 197, 0.3);
  border-color: #b0bec5;
}

.anhua-btn:hover {
  background: rgba(121, 85, 72, 0.3);
  border-color: #bcaaa4;
}

/* Realm Detail Sections */
.realm-detail {
  padding-top: 100px;
  padding-bottom: 120px;
}

.realm-showcase {
  display: grid;
  grid-template-columns: 420px 1fr;
  gap: 60px;
  align-items: start;
}

.realm-showcase.reverse {
  direction: rtl;
}

.realm-showcase.reverse > * {
  direction: ltr;
}

.puer-section {
  background: linear-gradient(135deg, rgba(46, 125, 50, 0.03), var(--dark-ink));
}

.liubao-section {
  background: linear-gradient(135deg, rgba(69, 90, 100, 0.03), var(--dark-ink));
}

.baicha-section {
  background: linear-gradient(135deg, rgba(176, 190, 197, 0.03), var(--dark-ink));
}

.anhua-section {
  background: linear-gradient(135deg, rgba(121, 85, 72, 0.03), var(--dark-ink));
}

/* Realm Visual Panel */
.realm-visual-panel {
  position: sticky;
  top: 100px;
}

.realm-scene {
  height: 420px;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.scene-atmosphere {
  position: absolute;
  width: 100%;
  height: 100%;
  backdrop-filter: blur(1px);
}

.scene-elements {
  position: absolute;
  width: 100%;
  height: 100%;
}

.scene-title {
  position: relative;
  z-index: 10;
  text-align: center;
}

.scene-title h2 {
  font-size: 2.5rem;
  color: var(--cloud-white);
  margin-bottom: 8px;
  font-weight: 700;
  text-shadow: 0 4px 30px rgba(0, 0, 0, 0.7);
}

.scene-title p {
  color: rgba(245, 237, 224, 0.7);
  font-size: 1.1rem;
  letter-spacing: 3px;
}

/* Puer Scene */
.puer-scene {
  background: linear-gradient(to bottom, 
    rgba(27, 94, 32, 0.6),
    rgba(46, 125, 50, 0.4),
    rgba(56, 142, 60, 0.3)
  );
}

.tree-element {
  position: absolute;
  bottom: 0;
  width: 80px;
  background: linear-gradient(to top, #1b5e20, #2e7d32);
  clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
  animation: tree-sway 6s infinite ease-in-out;
}

.tree-1 { left: 15%; height: 180px; animation-delay: 0s; }
.tree-2 { left: 45%; height: 220px; animation-delay: 1s; }
.tree-3 { right: 18%; height: 160px; animation-delay: 2s; }

@keyframes tree-sway {
  0%, 100% { transform: rotate(-2deg); }
  50% { transform: rotate(2deg); }
}

.mist-effect {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40%;
  background: linear-gradient(to top, rgba(255, 255, 255, 0.08), transparent);
  animation: mist-flow 8s infinite ease-in-out;
}

@keyframes mist-flow {
  0%, 100% { opacity: 0.6; transform: translateX(0); }
  50% { opacity: 0.9; transform: translateX(20px); }
}

/* Liubao Scene */
.liubao-scene {
  background: linear-gradient(to bottom,
    rgba(38, 50, 56, 0.8),
    rgba(55, 71, 79, 0.6),
    rgba(69, 90, 100, 0.4)
  );
}

.water-element {
  position: absolute;
  bottom: 15%;
  width: 200px;
  height: 60px;
  background: linear-gradient(to top, rgba(69, 90, 100, 0.5), transparent);
  border-radius: 50%;
  animation: water-wave 4s infinite ease-in-out;
}

.water-1 { left: 25%; }

@keyframes water-wave {
  0%, 100% { transform: scaleX(1); opacity: 0.5; }
  50% { transform: scaleX(1.1); opacity: 0.8; }
}

.boat-element {
  position: absolute;
  bottom: 22%;
  font-size: 2rem;
  animation: boat-float 5s infinite ease-in-out;
}

.boat-1 { left: 35%; }

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

.rain-effect {
  position: absolute;
  width: 100%;
  height: 100%;
  background-image: repeating-linear-gradient(
    to bottom,
    transparent,
    transparent 29px,
    rgba(176, 190, 197, 0.06) 30px
  );
  animation: rain-fall 1s infinite linear;
}

@keyframes rain-fall {
  from { transform: translateY(-30px); }
  to { transform: translateY(0); }
}

.night-glow {
  position: absolute;
  top: 15%;
  right: 20%;
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, rgba(255, 235, 150, 0.15), transparent);
  border-radius: 50%;
  animation: moon-pulse 6s infinite ease-in-out;
}

@keyframes moon-pulse {
  0%, 100% { opacity: 0.5; transform: scale(1); }
  50% { opacity: 0.9; transform: scale(1.1); }
}

/* Baicha Scene */
.baicha-scene {
  background: linear-gradient(to bottom,
    rgba(144, 164, 174, 0.5),
    rgba(176, 190, 197, 0.3),
    rgba(207, 216, 220, 0.2)
  );
}

.cloud-element {
  position: absolute;
  background: radial-gradient(ellipse at center, rgba(255, 255, 255, 0.12), transparent);
  border-radius: 50%;
  filter: blur(20px);
  animation: cloud-drift 15s infinite ease-in-out;
}

.cloud-1 { top: 20%; left: 15%; width: 180px; height: 80px; animation-delay: 0s; }
.cloud-2 { top: 35%; right: 20%; width: 220px; height: 90px; animation-delay: 5s; }

@keyframes cloud-drift {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(30px); }
}

.moonlight-effect {
  position: absolute;
  top: 10%;
  right: 15%;
  width: 120px;
  height: 120px;
  background: radial-gradient(circle, rgba(255, 255, 240, 0.2), transparent);
  border-radius: 50%;
  box-shadow: 0 0 60px rgba(255, 255, 240, 0.1);
  animation: moon-glow 8s infinite ease-in-out;
}

@keyframes moon-glow {
  0%, 100% { opacity: 0.6; box-shadow: 0 0 60px rgba(255, 255, 240, 0.1); }
  50% { opacity: 1; box-shadow: 0 0 100px rgba(255, 255, 240, 0.2); }
}

.bamboo-element {
  position: absolute;
  bottom: 10%;
  width: 12px;
  height: 140px;
  background: linear-gradient(to top, #81c784, #a5d6a7);
  border-radius: 6px;
  animation: bamboo-sway 4s infinite ease-in-out;
}

.bamboo-1 { left: 25%; }

@keyframes bamboo-sway {
  0%, 100% { transform: rotate(-3deg); }
  50% { transform: rotate(3deg); }
}

/* Anhua Scene */
.anhua-scene {
  background: linear-gradient(to bottom,
    rgba(78, 52, 46, 0.7),
    rgba(93, 64, 55, 0.5),
    rgba(121, 85, 72, 0.3)
  );
}

.mountain-element {
  position: absolute;
  bottom: 0;
  width: 0;
  height: 0;
  border-left: 80px solid transparent;
  border-right: 80px solid transparent;
  border-bottom: 160px solid rgba(93, 64, 55, 0.6);
  animation: mountain-steady 10s infinite ease-in-out;
}

.mountain-1 { left: 30%; }

@keyframes mountain-steady {
  0%, 100% { transform: scaleY(1); }
  50% { transform: scaleY(1.02); }
}

.fire-element {
  position: absolute;
  bottom: 20%;
  left: 42%;
  width: 60px;
  height: 70px;
  background: radial-gradient(ellipse at bottom, rgba(255, 152, 0, 0.4), transparent);
  border-radius: 50% 50% 40% 40%;
  animation: fire-burn 2s infinite ease-in-out;
}

@keyframes fire-burn {
  0%, 100% { transform: scaleY(1) scaleX(1); opacity: 0.7; }
  25% { transform: scaleY(1.1) scaleX(0.95); opacity: 0.9; }
  50% { transform: scaleY(0.98) scaleX(1.05); opacity: 0.8; }
  75% { transform: scaleY(1.05) scaleX(0.98); opacity: 0.85; }
}

.craft-element {
  position: absolute;
  bottom: 22%;
  left: 44%;
  font-size: 1.8rem;
  animation: craft-work 3s infinite ease-in-out;
}

.craft-1 {}

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

.rune-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.08), transparent);
  border-radius: 50%;
  animation: rune-pulse 5s infinite ease-in-out;
}

@keyframes rune-pulse {
  0%, 100% { opacity: 0.4; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 0.8; transform: translate(-50%, -50%) scale(1.15); }
}

/* Realm Stats */
.realm-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.stat-item {
  background: rgba(16, 20, 24, 0.6);
  border: 1px solid rgba(212, 175, 55, 0.15);
  border-radius: 14px;
  padding: 18px 12px;
  text-align: center;
  transition: all 0.3s ease;
}

.stat-item:hover {
  border-color: var(--gold);
  transform: translateY(-3px);
}

.stat-number {
  display: block;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 4px;
}

.stat-label {
  font-size: 0.85rem;
  color: rgba(245, 237, 224, 0.6);
}

/* Info Panel */
.realm-info-panel {
  background: rgba(16, 20, 24, 0.6);
  border: 1px solid rgba(212, 175, 55, 0.15);
  border-radius: 20px;
  padding: 40px;
}

.realm-header {
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.15);
}

.realm-header h2 {
  font-size: 2.5rem;
  color: var(--cloud-white);
  margin-bottom: 12px;
  font-weight: 700;
}

.realm-tag {
  display: inline-block;
  padding: 8px 20px;
  border-radius: 20px;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 1px;
}

.forest {
  background: rgba(46, 125, 50, 0.15);
  color: #66bb6a;
  border: 1px solid rgba(46, 125, 50, 0.35);
}

.trade {
  background: rgba(69, 90, 100, 0.15);
  color: #90a4ae;
  border: 1px solid rgba(69, 90, 100, 0.35);
}

.sky {
  background: rgba(176, 190, 197, 0.15);
  color: #b0bec5;
  border: 1px solid rgba(176, 190, 197, 0.35);
}

.craft {
  background: rgba(121, 85, 72, 0.15);
  color: #bcaaa4;
  border: 1px solid rgba(121, 85, 72, 0.35);
}

.info-block {
  margin-bottom: 28px;
}

.info-block h3 {
  font-size: 1.3rem;
  color: var(--gold);
  margin-bottom: 14px;
  font-weight: 600;
}

.info-block > p {
  color: rgba(245, 237, 224, 0.75);
  line-height: 1.9;
  font-size: 1rem;
}

.feature-list {
  list-style: none;
}

.feature-list li {
  padding: 10px 0;
  color: rgba(245, 237, 224, 0.75);
  line-height: 1.7;
  border-bottom: 1px solid rgba(212, 175, 55, 0.08);
  font-size: 0.98rem;
}

.feature-list li strong {
  color: var(--gold);
}

.feature-list li:last-child {
  border-bottom: none;
}

/* Guardian Card */
.guardian-card {
  display: flex;
  gap: 20px;
  align-items: center;
  background: rgba(30, 73, 59, 0.1);
  border: 1px solid rgba(212, 175, 55, 0.15);
  border-radius: 16px;
  padding: 24px;
  transition: all 0.3s ease;
}

.guardian-card:hover {
  border-color: var(--gold);
  transform: translateX(5px);
}

.guardian-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  flex-shrink: 0;
}

.guxuan-avatar {
  background: linear-gradient(135deg, #2e7d32, #1b5e20);
}

.moyin-avatar {
  background: linear-gradient(135deg, #455a64, #263238);
}

.lingxi-avatar {
  background: linear-gradient(135deg, #b0bec5, #78909c);
}

.qianyan-avatar {
  background: linear-gradient(135deg, #795548, #4e342e);
}

.guardian-info h4 {
  font-size: 1.4rem;
  color: var(--cloud-white);
  margin-bottom: 6px;
}

.guardian-title {
  color: var(--gold);
  font-size: 0.92rem;
  margin-bottom: 8px;
}

.guardian-desc {
  color: rgba(245, 237, 224, 0.65);
  font-size: 0.92rem;
  line-height: 1.6;
  margin-bottom: 12px;
}

.btn-sm-secondary {
  display: inline-block;
  padding: 8px 20px;
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
  text-decoration: none;
  border-radius: 20px;
  font-size: 0.88rem;
  transition: all 0.3s ease;
}

.btn-sm-secondary:hover {
  background: var(--gold);
  color: var(--dark-ink);
}

/* Actions */
.realm-actions {
  display: flex;
  gap: 16px;
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid rgba(212, 175, 55, 0.15);
}

/* Comparison Section */
.comparison-section {
  background: var(--dark-ink);
}

.comparison-table-wrapper {
  max-width: 1100px;
  margin: 80px auto 0;
  overflow-x: auto;
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  background: rgba(16, 20, 24, 0.6);
  border: 1px solid rgba(212, 175, 55, 0.15);
  border-radius: 16px;
  overflow: hidden;
}

.comparison-table thead {
  background: rgba(30, 73, 59, 0.3);
}

.comparison-table th {
  padding: 20px 18px;
  text-align: left;
  color: var(--gold);
  font-weight: 600;
  font-size: 1rem;
  border-bottom: 2px solid rgba(212, 175, 55, 0.2);
}

.comparison-table td {
  padding: 18px;
  color: rgba(245, 237, 224, 0.75);
  border-bottom: 1px solid rgba(212, 175, 55, 0.08);
  font-size: 0.96rem;
}

.comparison-table tbody tr:hover {
  background: rgba(30, 73, 59, 0.1);
}

.comparison-table tbody tr:last-child td {
  border-bottom: none;
}

.puer-color { color: #66bb6a !important; }
.liubao-color { color: #90a4ae !important; }
.baicha-color { color: #b0bec5 !important; }
.anhua-color { color: #bcaaa4 !important; }

/* Responsive */
@media (max-width: 1024px) {
  .realm-showcase,
  .realm-showcase.reverse {
    grid-template-columns: 360px 1fr;
    direction: ltr;
    gap: 40px;
  }

  .realm-visual-panel {
    position: relative;
    top: 0;
  }

  .realm-scene {
    height: 350px;
  }
}

@media (max-width: 768px) {
  .realms-hero {
    padding-top: 120px;
  }

  .realms-nav {
    gap: 10px;
  }

  .realm-nav-btn {
    padding: 10px 24px;
    font-size: 0.9rem;
  }

  .realm-showcase,
  .realm-showcase.reverse {
    grid-template-columns: 1fr;
    direction: ltr;
  }

  .realm-scene {
    height: 300px;
  }

  .scene-title h2 {
    font-size: 2rem;
  }

  .realm-info-panel {
    padding: 28px;
  }

  .realm-header h2 {
    font-size: 2rem;
  }

  .realm-stats {
    grid-template-columns: repeat(3, 1fr);
  }

  .guardian-card {
    flex-direction: column;
    text-align: center;
  }

  .realm-actions {
    flex-direction: column;
  }

  .comparison-table {
    font-size: 0.88rem;
  }

  .comparison-table th,
  .comparison-table td {
    padding: 14px 10px;
  }
}
