/* ==========================================================================
   Tab Panel SPA Dedicated Page Routing
   ========================================================================== */

.main-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 20px 50px 20px;
  min-height: calc(100vh - 120px);
}

.tab-panel {
  display: none !important;
}

.tab-panel.active {
  display: block !important;
  animation: panelFadeIn 0.28s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes panelFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.panel-top-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px dashed rgba(212, 175, 55, 0.25);
}

.btn-back-home {
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid var(--border-gold);
  color: var(--accent-gold-bright);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.2s ease;
  font-weight: 500;
}

.btn-back-home:hover {
  background: rgba(212, 175, 55, 0.25);
  transform: translateX(-2px);
}

.panel-breadcrumb {
  font-size: 13px;
  color: var(--text-muted);
}

.panel-breadcrumb strong {
  color: var(--accent-gold-bright);
}

/* ==========================================================================
   Chinese Modern Dark-Gold Luxury Aesthetic Design System (国学暗金风)
   ========================================================================== */

:root {
  --bg-primary: #0d0a12;
  --bg-secondary: #171320;
  --bg-card: rgba(30, 24, 42, 0.75);
  --bg-card-hover: rgba(45, 36, 64, 0.85);

  --accent-gold: #D4AF37;
  --accent-gold-light: #F3E5AB;
  --accent-gold-bright: #FFD700;
  --accent-red: #8B0000;
  --accent-red-bright: #E63946;
  --accent-green: #2A9D8F;
  --accent-purple: #6B2D5C;

  --text-main: #F4E8C1;
  --text-muted: #A89F91;
  --text-dark: #121212;

  --border-gold: rgba(212, 175, 55, 0.35);
  --border-gold-glow: rgba(212, 175, 55, 0.75);
  --shadow-gold: 0 4px 20px rgba(212, 175, 55, 0.15);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.5);

  --font-serif: "Songti SC", "STSong", "Noto Serif SC", "Source Han Serif SC", "SimSun", serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", sans-serif;

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-main);
  font-family: var(--font-sans);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  background-image: 
    radial-gradient(circle at 50% 0%, rgba(139, 0, 0, 0.25), transparent 70%),
    radial-gradient(circle at 80% 80%, rgba(212, 175, 55, 0.08), transparent 50%);
  background-attachment: fixed;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */

/* ==========================================================================
   App Header & Navigation Bars
   ========================================================================== */

.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13, 10, 18, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-gold);
  padding: 10px 16px 8px 16px;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
  gap: 12px;
}

.logo-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.logo-badge {
  width: 38px;
  height: 38px;
  background: linear-gradient(135deg, var(--accent-red), #4A0000);
  border: 1.5px solid var(--accent-gold);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  font-size: 20px;
  color: var(--accent-gold-bright);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.35);
  flex-shrink: 0;
}

.title-text {
  font-family: var(--font-serif);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 1px;
  background: linear-gradient(135deg, #FFF, var(--accent-gold-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  white-space: nowrap;
  margin: 0;
}

.subtitle-text {
  font-size: 10.5px;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  white-space: nowrap;
  margin: 0;
}

/* User & Action Buttons Widget */
#userAuthWidget {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.header-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 12.5px;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.lang-btn {
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid var(--border-gold);
  color: var(--accent-gold-bright);
}

.lang-btn:hover {
  background: rgba(212, 175, 55, 0.25);
}

.user-btn {
  background: linear-gradient(135deg, #8B0000, #4A0000);
  border: 1px solid var(--border-gold);
  color: var(--accent-gold-bright);
}

.user-btn:hover {
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

.header-quota-badge {
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid var(--border-gold);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 12px;
  color: var(--accent-gold-bright);
  white-space: nowrap;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.header-quota-badge strong {
  color: #FFD700;
  font-size: 13px;
}

/* Navigation Scroll Row (Second Row) */
.nav-scroll {
  width: 100%;
  max-width: 1200px;
  margin: 8px auto 0 auto;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 2px 0;
}
.nav-scroll::-webkit-scrollbar { display: none; }

.nav-tabs {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
  padding: 4px 6px;
  background: rgba(23, 19, 32, 0.85);
  border-radius: var(--radius-full);
  border: 1px solid var(--border-gold);
  width: max-content;
  margin: 0 auto;
}

.nav-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.nav-btn:hover {
  color: #FFF;
  background: rgba(255, 255, 255, 0.06);
}

.nav-btn.active {
  background: linear-gradient(135deg, #8B0000, #4A0000);
  border: 1px solid var(--accent-gold-bright);
  color: var(--accent-gold-bright);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

.tutorial-btn {
  background: linear-gradient(135deg, #78350F, #8B0000) !important;
  border: 1px solid var(--accent-gold-bright) !important;
  color: var(--accent-gold-bright) !important;
}

.almanac-banner {
  background: linear-gradient(135deg, rgba(40, 20, 25, 0.9), rgba(20, 15, 30, 0.9));
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.almanac-banner::before {
  content: "福";
  position: absolute;
  right: -20px;
  bottom: -30px;
  font-family: var(--font-serif);
  font-size: 160px;
  color: rgba(212, 175, 55, 0.04);
  pointer-events: none;
}

.date-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 16px;
}

.solar-lunar-title {
  font-family: var(--font-serif);
  font-size: 24px;
  color: var(--accent-gold-bright);
  font-weight: 700;
}

.ganzhi-info {
  font-size: 15px;
  color: var(--text-main);
  margin-top: 4px;
}

.calendar-btn {
  background: linear-gradient(135deg, var(--accent-gold), #997A15);
  color: #121212;
  border: none;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(212, 175, 55, 0.3);
  transition: transform 0.2s, box-shadow 0.2s;
}

.calendar-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.5);
}

.yi-ji-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  background: rgba(10, 8, 14, 0.6);
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.badge-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.badge-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 12px;
  border-radius: 20px;
  font-weight: bold;
  font-size: 13px;
  line-height: 1.4;
  white-space: nowrap;
  flex-shrink: 0;
  width: auto;
  height: auto;
}

.badge-tag.badge-circle {
  width: 28px;
  height: 28px;
  padding: 0;
  border-radius: 50%;
  font-size: 14px;
}

/* Card Metaphysics Panel & Header */
.card-metaphysics {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  padding: 24px;
  border-radius: var(--radius-lg);
  max-width: 860px;
  margin: 0 auto;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.card-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
  padding-bottom: 16px;
  margin-bottom: 20px;
}

.title-with-icon {
  display: flex;
  align-items: center;
  gap: 10px;
}

.title-with-icon .icon {
  font-size: 26px;
}

.panel-title {
  font-family: var(--font-serif);
  color: var(--accent-gold-bright);
  font-size: 22px;
  margin: 0;
  letter-spacing: 1px;
}

.badge-yi { background: var(--accent-green); color: #FFF; }
.badge-ji { background: var(--accent-red-bright); color: #FFF; }

.badge-list {
  font-size: 14px;
  color: var(--text-main);
  line-height: 1.8;
}

/* Feature Grid Cards */
.portal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 24px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 170px;
  position: relative;
  overflow: hidden;
}

.feature-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-gold-bright);
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.6), 0 0 15px rgba(212, 175, 55, 0.2);
}

.card-icon {
  width: 50px;
  height: 50px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-family: var(--font-serif);
  font-weight: bold;
  margin-bottom: 12px;
  border: 1px solid var(--border-gold);
}

.bg-red { background: linear-gradient(135deg, #8B0000, #400000); color: var(--accent-gold-bright); }
.bg-gold { background: linear-gradient(135deg, #B8860B, #5C4305); color: #FFF; }
.bg-blue { background: linear-gradient(135deg, #1E3A8A, #0F1D45); color: #93C5FD; }
.bg-purple { background: linear-gradient(135deg, #4C1D95, #260E4A); color: #DDD6FE; }
.bg-green { background: linear-gradient(135deg, #065F46, #033023); color: #A7F3D0; }
.bg-pink { background: linear-gradient(135deg, #9D174D, #4F0B27); color: #FBCFE8; }

.card-title {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--text-main);
}

.card-desc {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ==========================================================================
   Module 1: Yijing Dayan Divination (高岛易断)
   ========================================================================== */

.divine-box {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 30px;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.divine-title {
  font-family: var(--font-serif);
  font-size: 26px;
  color: var(--accent-gold-bright);
  margin-bottom: 8px;
}

.divine-subtitle {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.sticks-stage {
  height: 180px;
  background: rgba(10, 8, 14, 0.8);
  border-radius: var(--radius-md);
  border: 1px dashed var(--border-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  margin-bottom: 24px;
}

.stick-anim {
  width: 4px;
  height: 100px;
  background: linear-gradient(to bottom, #D4AF37, #8B5A2B);
  margin: 0 4px;
  border-radius: 2px;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-red), #5A0000);
  color: var(--accent-gold-bright);
  border: 1px solid var(--accent-gold);
  padding: 12px 36px;
  font-size: 16px;
  font-weight: 700;
  border-radius: var(--radius-full);
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(139, 0, 0, 0.5);
  transition: all 0.3s;
}

.btn-primary:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 25px rgba(212, 175, 55, 0.4);
}

/* Hexagram Result Display */
.hexagram-container {
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 30px;
}

.hexagram-card {
  flex: 1;
  min-width: 280px;
  background: rgba(15, 12, 22, 0.8);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-md);
  padding: 20px;
}

.hex-title {
  font-family: var(--font-serif);
  font-size: 20px;
  color: var(--accent-gold-bright);
  margin-bottom: 16px;
}

.lines-stack {
  display: flex;
  flex-direction: column-reverse; /* Bottom line is line 1 */
  gap: 8px;
  margin-bottom: 16px;
}

.yao-line {
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.yang-bar {
  width: 140px;
  height: 14px;
  background: linear-gradient(to right, #D4AF37, #FFD700);
  border-radius: 3px;
}

.yin-bars {
  width: 140px;
  height: 14px;
  display: flex;
  justify-content: space-between;
}

.yin-part {
  width: 62px;
  height: 14px;
  background: linear-gradient(to right, #D4AF37, #E5C158);
  border-radius: 3px;
}

.yao-line.changing .yang-bar,
.yao-line.changing .yin-part {
  background: linear-gradient(to right, var(--accent-red-bright), #FF6B6B) !important;
  box-shadow: 0 0 10px rgba(255, 107, 107, 0.8);
}

/* ==========================================================================
   Module 2: Fengshui Compass (风水罗盘) Cockpit & Stage
   ========================================================================== */

.compass-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: 100%;
}

/* Live Cockpit Dashboard */
.compass-live-cockpit {
  width: 100%;
  max-width: 680px;
  background: linear-gradient(135deg, rgba(26, 18, 12, 0.95), rgba(15, 10, 8, 0.95));
  border: 1.5px solid var(--accent-gold-bright);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), inset 0 0 20px rgba(212, 175, 55, 0.1);
  text-align: left;
}

.cockpit-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.25);
  padding-bottom: 10px;
  margin-bottom: 10px;
}

.cockpit-degree-block {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.cockpit-deg {
  font-family: var(--font-serif);
  font-size: 30px;
  font-weight: bold;
  color: var(--accent-gold-bright);
  line-height: 1;
}

.cockpit-mountain {
  font-size: 16px;
  font-weight: bold;
  color: #FFF;
}

.cockpit-badge-block {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.cockpit-star-badge {
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: bold;
  white-space: nowrap;
}

.badge-green { background: #065F46; color: #34D399; border: 1px solid #10B981; }
.badge-yellow { background: #78350F; color: #FBBF24; border: 1px solid #D97706; }
.badge-red { background: #7F1D1D; color: #F87171; border: 1px solid #EF4444; }

.cockpit-elem-badge {
  background: rgba(212, 175, 55, 0.15);
  color: var(--accent-gold-light);
  border: 1px solid rgba(212, 175, 55, 0.3);
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 12px;
}

.cockpit-summary-box {
  background: rgba(10, 6, 4, 0.6);
  border: 1px dashed rgba(212, 175, 55, 0.3);
  border-radius: var(--radius-md);
  padding: 10px 14px;
}

.cockpit-target-label {
  font-weight: bold;
  color: var(--accent-gold-bright);
  font-size: 13px;
  margin-bottom: 4px;
}

.cockpit-target-desc {
  font-size: 13px;
  color: #ded7ca;
  line-height: 1.6;
  margin: 0;
}

/* Stage & Dial Canvas */
.compass-stage {
  position: relative;
  padding: 8px;
  background: radial-gradient(circle, rgba(35, 22, 16, 0.9), rgba(12, 6, 4, 0.98));
  border: 2px solid var(--accent-gold);
  border-radius: 50%;
  box-shadow: 0 0 35px rgba(212, 175, 55, 0.25);
  display: flex;
  justify-content: center;
  align-items: center;
  max-width: 320px;
  max-height: 320px;
  width: 90vw;
  height: 90vw;
  margin: 0 auto;
}

.compass-stage canvas {
  width: 100% !important;
  height: 100% !important;
  max-width: 300px;
  max-height: 300px;
  display: block;
}

.compass-actions-bar {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  width: 100%;
  max-width: 680px;
}

.btn-action-gold {
  background: linear-gradient(135deg, #78350F, #451A03);
  color: var(--accent-gold-bright);
  border: 1px solid var(--border-gold);
  padding: 10px 18px;
  border-radius: var(--radius-md);
  font-weight: bold;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-action-gold:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.2);
}

.btn-action-ghost {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 10px 18px;
  border-radius: var(--radius-md);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-action-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* ==========================================================================
   Module 3: Bazi Four Pillars (八字排盘) & Marriage Matching
   ========================================================================== */

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

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 13px;
  color: var(--text-muted);
}

.form-control {
  background: rgba(10, 8, 15, 0.8);
  border: 1px solid var(--border-gold);
  color: var(--text-main);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  outline: none;
}

.form-control:focus {
  border-color: var(--accent-gold-bright);
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.4);
}

.bazi-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  background: rgba(15, 12, 22, 0.8);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.bazi-table th, .bazi-table td {
  padding: 12px;
  text-align: center;
  border: 1px solid rgba(212, 175, 55, 0.15);
}

.bazi-table th {
  background: rgba(139, 0, 0, 0.4);
  color: var(--accent-gold-bright);
  font-family: var(--font-serif);
  font-size: 15px;
}

.stem-char, .branch-char {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: bold;
}

.wuxing-meter {
  display: flex;
  gap: 12px;
  margin: 20px 0;
}

.wuxing-item {
  flex: 1;
  background: rgba(15, 12, 22, 0.6);
  border-radius: var(--radius-sm);
  padding: 10px;
  text-align: center;
  border: 1px solid var(--border-gold);
}

.wuxing-bar-bg {
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
  margin-top: 6px;
}

.wuxing-bar-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.6s ease;
}

/* ==========================================================================
   Modals & Popups
   ========================================================================== */

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-overlay.active {
  display: flex;
}

.modal-content {
  background: var(--bg-card);
  border: 1px solid var(--accent-gold);
  border-radius: var(--radius-lg);
  max-width: 640px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 24px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.8);
  position: relative;
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 24px;
  cursor: pointer;
}

.modal-close:hover { color: #FFF; }

/* Mobile Bottom Navigation Bar Base */
.mobile-bottom-nav {
  display: none !important;
}

@media (max-width: 768px) {
  body {
    padding-bottom: 20px;
  }

  .app-header {
    padding: 8px 10px 6px 10px;
  }

  .header-container {
    gap: 6px;
  }

  .logo-badge {
    width: 32px;
    height: 32px;
    font-size: 17px;
  }

  .title-text {
    font-size: 15px;
    letter-spacing: 0.5px;
  }

  .subtitle-text {
    display: none; /* Hide subtitle on small screens to save space */
  }

  #userAuthWidget {
    gap: 4px;
  }

  .header-action-btn {
    padding: 3px 8px;
    font-size: 11px;
  }

  .header-quota-badge {
    padding: 3px 6px;
    font-size: 11px;
  }

  .header-quota-badge .quota-label {
    display: none; /* Show just 🧙 9/9次 on mobile */
  }

  .nav-scroll {
    margin: 6px 0 0 0;
    padding: 2px 0;
    display: block !important;
  }

  .nav-tabs {
    margin: 0 !important;
    padding: 3px 4px;
    gap: 4px;
  }

  .nav-btn {
    padding: 5px 10px !important;
    font-size: 12.5px !important;
  }

  .almanac-banner { padding: 16px; }
  .solar-lunar-title { font-size: 18px; }



  .mobile-nav-btn .icon {
    font-size: 20px;
    margin-bottom: 2px;
    transition: transform 0.2s ease;
  }

  .mobile-nav-btn.active {
    color: var(--accent-gold-bright);
  }

  .mobile-nav-btn.active .icon {
    transform: translateY(-2px) scale(1.1);
  }

  .portal-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .main-content {
    padding: 12px;
  }
}

/* ==========================================================================
   Teacher Scenario Guide & Quad-Analysis Component Styles (师者向导与四维讲堂)
   ========================================================================== */

.scenario-guide-box {
  background: linear-gradient(135deg, rgba(26, 18, 38, 0.95), rgba(15, 12, 22, 0.95));
  border: 1.5px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), inset 0 0 20px rgba(212, 175, 55, 0.08);
  position: relative;
  overflow: hidden;
}

.scenario-guide-box::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.12), transparent 70%);
  pointer-events: none;
}

.scenario-header {
  margin-bottom: 20px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
  padding-bottom: 14px;
}

.scenario-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.scenario-icon {
  font-size: 32px;
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid var(--border-gold);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.3);
}

.scenario-title {
  font-family: var(--font-serif);
  color: var(--accent-gold-bright);
  font-size: 20px;
  letter-spacing: 0.5px;
}

.scenario-subtitle {
  font-size: 13.5px;
  color: var(--text-muted);
  margin-top: 4px;
}

.scenario-category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.15);
  padding-bottom: 12px;
}

.scenario-cat-tab {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(212, 175, 55, 0.2);
  color: var(--text-muted);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.scenario-cat-tab:hover {
  background: rgba(212, 175, 55, 0.15);
  color: var(--text-main);
  border-color: var(--accent-gold);
}

.scenario-cat-tab.active {
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.3), rgba(139, 0, 0, 0.4));
  color: var(--accent-gold-bright);
  border-color: var(--accent-gold-bright);
  font-weight: 600;
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.25);
}

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

.scenario-card {
  background: rgba(18, 14, 26, 0.8);
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

.scenario-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-gold-bright);
  background: rgba(35, 27, 50, 0.95);
  box-shadow: 0 8px 24px rgba(212, 175, 55, 0.25);
}

.scenario-card-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: bold;
  color: var(--accent-gold-light);
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid var(--border-gold);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  margin-bottom: 8px;
  align-self: flex-start;
}

.scenario-card-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 6px;
  line-height: 1.4;
}

.scenario-card-desc {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 12px;
}

.scenario-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px dashed rgba(212, 175, 55, 0.15);
  padding-top: 10px;
  margin-top: auto;
}

.scenario-tool-tag {
  font-size: 12px;
  color: var(--accent-gold);
  font-weight: 500;
}

.scenario-btn-go {
  font-size: 12px;
  color: var(--accent-gold-bright);
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 2px;
  transition: transform 0.2s ease;
}

.scenario-card:hover .scenario-btn-go {
  transform: translateX(4px);
  color: #fff;
}

/* Tool Header Teacher Guide Box */
.teacher-intro-banner {
  background: rgba(212, 175, 55, 0.08);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin-bottom: 20px;
  text-align: left;
  position: relative;
}

.teacher-intro-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.15);
  padding-bottom: 8px;
}

.teacher-tag-badge {
  font-size: 12px;
  color: var(--accent-gold-bright);
  background: rgba(139, 0, 0, 0.6);
  border: 1px solid var(--border-gold);
  padding: 3px 10px;
  border-radius: var(--radius-full);
}

.teacher-intro-body {
  font-size: 13px;
  color: var(--text-main);
  line-height: 1.7;
}

/* Goal Selector Chips */
.goal-selector-box {
  margin: 14px 0 20px 0;
  text-align: left;
}

.goal-selector-label {
  font-size: 13.5px;
  color: var(--accent-gold);
  font-weight: 600;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.goal-chips-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.goal-chip {
  background: rgba(15, 12, 22, 0.8);
  border: 1px solid var(--border-gold);
  color: var(--text-muted);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.goal-chip:hover {
  color: var(--accent-gold-light);
  border-color: var(--accent-gold-bright);
}

.goal-chip.active {
  background: linear-gradient(135deg, #78350F, #8B0000);
  border-color: var(--accent-gold-bright);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.4);
}

/* Quad-Analysis Master Teacher Result Component (四维师者讲堂) */
.teacher-quad-container {
  margin-top: 24px;
  padding: 22px;
  background: var(--bg-card);
  border: 1.5px solid var(--accent-gold);
  border-radius: var(--radius-lg);
  text-align: left;
  box-shadow: var(--shadow-gold);
}

.teacher-quad-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-gold);
  padding-bottom: 12px;
  margin-bottom: 16px;
}

.teacher-quad-title-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.teacher-quad-title {
  color: var(--accent-gold-bright);
  font-family: var(--font-serif);
  font-size: 19px;
  margin: 0;
}

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

.teacher-quad-card {
  background: rgba(10, 8, 14, 0.75);
  border-radius: var(--radius-md);
  padding: 16px;
  border-left: 4px solid var(--border-gold);
  border-top: 1px solid rgba(212, 175, 55, 0.15);
  border-right: 1px solid rgba(212, 175, 55, 0.15);
  border-bottom: 1px solid rgba(212, 175, 55, 0.15);
}

.teacher-quad-card.good {
  border-left-color: #2A9D8F;
}

.teacher-quad-card.warn {
  border-left-color: #E63946;
}

.teacher-quad-card.why {
  border-left-color: #D4AF37;
}

.teacher-quad-card.action {
  border-left-color: #3A86FF;
  grid-column: 1 / -1;
}

.teacher-quad-card-title {
  font-size: 14.5px;
  font-weight: 600;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.teacher-quad-card.good .teacher-quad-card-title { color: #2A9D8F; }
.teacher-quad-card.warn .teacher-quad-card-title { color: #E63946; }
.teacher-quad-card.why .teacher-quad-card-title { color: var(--accent-gold-bright); }
.teacher-quad-card.action .teacher-quad-card-title { color: #60A5FA; }

.teacher-quad-card-text {
  font-size: 13px;
  color: var(--text-main);
  line-height: 1.75;
}



/* --- Home Navigation & Breadcrumbs --- */
.logo-group {
  cursor: pointer;
  user-select: none;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.logo-group:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.panel-top-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding: 8px 14px;
  background: rgba(212, 175, 55, 0.08);
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: var(--radius-md);
}

.btn-back-home {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, rgba(139, 0, 0, 0.85), rgba(74, 0, 0, 0.85));
  border: 1px solid var(--border-gold);
  color: var(--accent-gold-bright);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-back-home:hover {
  background: linear-gradient(135deg, #A00000, #5C0000);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.4);
  transform: translateY(-1px);
}

.panel-breadcrumb {
  font-size: 13px;
  color: var(--text-muted);
}

.panel-breadcrumb strong {
  color: var(--accent-gold-bright);
}

.float-home-btn {
  position: fixed;
  bottom: 80px;
  right: 20px;
  z-index: 999;
  background: linear-gradient(135deg, #8B0000, #3B0000);
  border: 1.5px solid var(--accent-gold);
  color: var(--accent-gold-bright);
  padding: 10px 18px;
  border-radius: 30px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.5), 0 0 12px rgba(212,175,55,0.3);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(8px);
}

.float-home-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(0,0,0,0.6), 0 0 18px rgba(212,175,55,0.5);
  background: linear-gradient(135deg, #A30000, #520000);
}

@media (max-width: 768px) {
  .float-home-btn {
    bottom: 75px;
    right: 14px;
    padding: 8px 14px;
    font-size: 12px;
  }
}

/* ==========================================================================
   Master Metaphysics Treatise 3.0 (大师万言命书长卷)
   ========================================================================== */

.master-treatise-container {
  margin-top: 24px;
  background: linear-gradient(145deg, rgba(25, 20, 32, 0.95), rgba(12, 9, 18, 0.98));
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), inset 0 0 20px rgba(212, 175, 55, 0.05);
  animation: fadeIn 0.3s ease;
}

.master-treatise-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px dashed rgba(212, 175, 55, 0.3);
  padding-bottom: 16px;
  margin-bottom: 20px;
}

.master-treatise-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.master-treatise-title {
  font-family: var(--font-serif);
  font-size: 20px;
  color: var(--accent-gold-bright);
  margin: 0;
  letter-spacing: 1px;
}

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

.treatise-card {
  background: rgba(10, 8, 14, 0.85);
  border-radius: var(--radius-md);
  padding: 18px;
  border-left: 4px solid var(--border-gold);
  border-top: 1px solid rgba(212, 175, 55, 0.12);
  border-right: 1px solid rgba(212, 175, 55, 0.12);
  border-bottom: 1px solid rgba(212, 175, 55, 0.12);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.treatise-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.5);
}

.treatise-card.full-width {
  grid-column: 1 / -1;
}

.treatise-card-title {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: 0.5px;
}

.treatise-card.overview { border-left-color: #D4AF37; }
.treatise-card.overview .treatise-card-title { color: #F59E0B; }

.treatise-card.years { border-left-color: #06B6D4; }
.treatise-card.years .treatise-card-title { color: #22D3EE; }

.treatise-card.wealth { border-left-color: #EAB308; }
.treatise-card.wealth .treatise-card-title { color: #FACC15; }

.treatise-card.career { border-left-color: #3B82F6; }
.treatise-card.career .treatise-card-title { color: #60A5FA; }

.treatise-card.marriage { border-left-color: #EC4899; }
.treatise-card.marriage .treatise-card-title { color: #F472B6; }

.treatise-card.academic { border-left-color: #10B981; }
.treatise-card.academic .treatise-card-title { color: #34D399; }

.treatise-card.health { border-left-color: #84CC16; }
.treatise-card.health .treatise-card-title { color: #A3E635; }

.treatise-card.tips { border-left-color: #A855F7; }
.treatise-card.tips .treatise-card-title { color: #C084FC; }

.treatise-card-text {
  font-size: 13.5px;
  color: #EDE8DF;
  line-height: 1.85;
}

.treatise-card-text b,
.treatise-card-text strong {
  color: var(--accent-gold-bright);
}


/* Traditional Chinese Typography Enhancement */
body.lang-trad {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang TC", "Songti TC", "Noto Serif TC", "Microsoft JhengHei", "MingLiU", sans-serif;
}

body.lang-trad .title-text,
body.lang-trad .panel-title,
body.lang-trad h1, 
body.lang-trad h2, 
body.lang-trad h3, 
body.lang-trad h4,
body.lang-trad .treatise-card-title,
body.lang-trad .master-treatise-header h3 {
  font-family: "Songti TC", "Noto Serif TC", "PMingLiU", "MingLiU", "Cinzel Decorative", Georgia, serif !important;
  letter-spacing: 1.5px;
}

/* ==========================================================================
   Interactive Chinese Lunar Calendar & Almanac Styles
   ========================================================================== */

.calendar-metaphysics-card {
  margin-bottom: 20px;
  background: linear-gradient(180deg, rgba(23, 19, 32, 0.95), rgba(15, 12, 22, 0.98));
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

.calendar-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.calendar-month-selector {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cal-nav-btn {
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid var(--border-gold);
  color: var(--accent-gold-bright);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  transition: all 0.2s ease;
}

.cal-nav-btn:hover {
  background: rgba(212, 175, 55, 0.3);
  transform: scale(1.08);
}

.cal-month-title {
  display: flex;
  flex-direction: column;
}

.cal-ym-text {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--accent-gold-bright);
  letter-spacing: 1px;
}

.cal-lunar-m-text {
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

.calendar-quick-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cal-today-btn, .cal-toggle-btn {
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid var(--border-gold);
  color: var(--accent-gold-bright);
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.cal-today-btn:hover, .cal-toggle-btn:hover {
  background: rgba(212, 175, 55, 0.25);
}

.calendar-grid-wrapper {
  margin: 12px 0 16px 0;
  transition: all 0.3s ease;
}

.calendar-week-header {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 6px;
}

.cal-week-day {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}

.cal-week-day.weekend {
  color: #E57373;
}

.calendar-days-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.cal-day-cell {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  padding: 8px 4px;
  min-height: 58px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  user-select: none;
}

.cal-day-cell:hover {
  background: rgba(212, 175, 55, 0.12);
  border-color: var(--border-gold);
  transform: translateY(-2px);
}

.cal-day-cell.other-month {
  opacity: 0.35;
}

.cal-day-cell.today {
  border: 1.5px solid var(--accent-gold-bright);
  background: rgba(212, 175, 55, 0.15);
  box-shadow: inset 0 0 8px rgba(212, 175, 55, 0.2);
}

.cal-day-cell.active {
  background: linear-gradient(135deg, rgba(139, 0, 0, 0.85), rgba(74, 0, 0, 0.95)) !important;
  border: 1.5px solid var(--accent-gold-bright) !important;
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.4) !important;
  transform: scale(1.03);
}

.cal-day-num {
  font-size: 16px;
  font-weight: 700;
  color: #FFF;
  line-height: 1.2;
}

.cal-day-cell.today .cal-day-num,
.cal-day-cell.active .cal-day-num {
  color: var(--accent-gold-bright);
}

.cal-lunar-text {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  text-align: center;
}

.cal-lunar-text.festival,
.cal-lunar-text.jieqi {
  color: #FFD700;
  font-weight: 600;
}

.cal-day-cell.active .cal-lunar-text {
  color: #FFF;
}

/* Selected Day Detailed Cockpit */
.selected-day-cockpit {
  margin-top: 12px;
  background: rgba(10, 8, 14, 0.7);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: var(--radius-md);
  padding: 16px 20px;
}

.date-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.almanac-week-badge {
  background: rgba(212, 175, 55, 0.2);
  border: 1px solid var(--border-gold);
  color: var(--accent-gold-bright);
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 600;
}

.almanac-jieqi-badge {
  background: linear-gradient(135deg, #10B981, #059669);
  color: #FFF;
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 600;
}

.almanac-extra-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 10px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed rgba(212, 175, 55, 0.2);
}

.almanac-extra-item {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 6px;
  padding: 8px 12px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.extra-label {
  font-size: 11.5px;
  color: var(--accent-gold-bright);
  font-weight: 600;
}

.extra-val {
  font-size: 12.5px;
  color: var(--text-main);
  line-height: 1.5;
}

/* Hourly Fortunes Slider */
.hourly-fortune-container {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed rgba(212, 175, 55, 0.2);
}

.hourly-title-row {
  margin-bottom: 8px;
}

.hourly-title {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--accent-gold-bright);
}

.hourly-scroll-bar {
  display: flex;
  overflow-x: auto;
  gap: 8px;
  padding: 4px 2px 8px 2px;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

.hourly-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 8px 10px;
  min-width: 105px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: all 0.2s ease;
}

.hourly-card:hover {
  border-color: var(--border-gold);
  background: rgba(212, 175, 55, 0.08);
}

.hourly-card.lucky {
  border-color: rgba(16, 185, 129, 0.4);
  background: rgba(16, 185, 129, 0.05);
}

.hourly-card.unlucky {
  border-color: rgba(239, 68, 68, 0.3);
  background: rgba(239, 68, 68, 0.04);
}

.hourly-gz {
  font-size: 13.5px;
  font-weight: 700;
  color: #FFF;
}

.hourly-tag {
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 3px;
  margin: 3px 0;
  font-weight: 600;
}

.hourly-tag.lucky {
  background: #10B981;
  color: #FFF;
}

.hourly-tag.unlucky {
  background: #6B7280;
  color: #FFF;
}

.hourly-ts {
  font-size: 11px;
  color: var(--accent-gold-bright);
}

.hourly-yi-ji {
  font-size: 10.5px;
  color: var(--text-muted);
  margin-top: 3px;
  line-height: 1.3;
}

@media (max-width: 768px) {
  .calendar-metaphysics-card {
    padding: 12px 10px;
  }
  .cal-day-cell {
    min-height: 48px;
    padding: 4px 2px;
  }
  .cal-day-num {
    font-size: 14px;
  }
  .cal-lunar-text {
    font-size: 9.5px;
  }
  .selected-day-cockpit {
    padding: 12px 10px;
  }
  .almanac-extra-grid {
    grid-template-columns: 1fr;
  }
}

/* 测字神数分类字库样式 */
.cezi-category-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.cezi-cat-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 12px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.cezi-cat-btn:hover {
  background: rgba(212, 175, 55, 0.15);
  color: var(--text-main);
}

.cezi-cat-btn.active {
  background: linear-gradient(135deg, #8B0000, #4A0000);
  border-color: var(--accent-gold-bright);
  color: var(--accent-gold-bright);
  font-weight: 600;
}

.cezi-chars-matrix {
  scrollbar-width: thin;
}

.cezi-char-pill {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(212, 175, 55, 0.08);
  border: 1px solid rgba(212, 175, 55, 0.3);
  color: var(--text-main);
  border-radius: 50%;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.cezi-char-pill:hover {
  background: rgba(212, 175, 55, 0.3);
  border-color: var(--accent-gold-bright);
  color: var(--accent-gold-bright);
  transform: scale(1.12);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.4);
}

.cezi-char-pill.active {
  background: linear-gradient(135deg, #FFD700, #D4AF37) !important;
  color: #121212 !important;
  font-weight: bold;
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.6);
}
/* Hide removed elements */
.mobile-bottom-nav,
.float-home-btn,
#btnFloatingHome {
  display: none !important;
}



/* ==========================================================================
   1. Portal 4 Flagship Hero Cards (少即是多 · 焦点四门)
   ========================================================================== */
.portal-flagship-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px;
  margin-top: 8px;
}

.flagship-card {
  position: relative;
  background: linear-gradient(145deg, rgba(28, 22, 38, 0.9) 0%, rgba(16, 12, 22, 0.95) 100%);
  border: 1.5px solid rgba(212, 175, 55, 0.35);
  border-radius: var(--radius-lg);
  padding: 24px 20px 20px 20px;
  text-align: left;
  cursor: pointer;
  transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.flagship-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-gold-bright);
  box-shadow: 0 12px 30px rgba(212, 175, 55, 0.25);
}

.flagship-card-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid var(--border-gold);
  color: var(--accent-gold-bright);
  font-size: 11px;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-weight: 600;
}

.flagship-card-icon {
  font-size: 36px;
  margin-bottom: 12px;
}

.flagship-card-title {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: #faeed7;
  margin-bottom: 6px;
}

.flagship-card-desc {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 16px;
  flex-grow: 1;
}

.flagship-card-action {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-gold-bright);
  display: flex;
  align-items: center;
  gap: 4px;
  transition: transform 0.2s ease;
}

.flagship-card:hover .flagship-card-action {
  transform: translateX(4px);
}

/* Card Themes */
.card-yijing { border-top: 3px solid #E63946; }
.card-dream { border-top: 3px solid #9D4EDD; }
.card-bazi { border-top: 3px solid #E056FD; }
.card-lucky { border-top: 3px solid #2A9D8F; }

/* Secondary Tools Accordion */
.secondary-tools-accordion {
  background: rgba(18, 14, 24, 0.6);
  border: 1px dashed rgba(212, 175, 55, 0.3);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  transition: all 0.3s ease;
}

.secondary-tools-accordion[open] {
  background: rgba(18, 14, 24, 0.85);
  border-style: solid;
  border-color: rgba(212, 175, 55, 0.4);
}

.secondary-tools-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--accent-gold-bright);
  font-size: 14.5px;
  cursor: pointer;
  user-select: none;
  list-style: none;
}

.secondary-tools-summary::-webkit-details-marker {
  display: none;
}

/* ==========================================================================
   2. Progressive Disclosure (关键词先导 + 30秒速读 + 渐进式折叠)
   ========================================================================== */
.result-highlight-cockpit {
  background: linear-gradient(145deg, rgba(26, 20, 36, 0.95) 0%, rgba(14, 10, 18, 0.98) 100%);
  border: 1.5px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
  text-align: left;
}

.result-cockpit-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
  margin-bottom: 14px;
}

.result-cockpit-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.result-cockpit-title {
  font-family: var(--font-serif);
  font-size: 19px;
  color: var(--accent-gold-bright);
  margin: 0;
}

.result-keywords-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.result-keyword-pill {
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.2), rgba(212, 175, 55, 0.05));
  border: 1px solid var(--border-gold);
  color: #FFD700;
  font-size: 12.5px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.2);
}

.result-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 12px;
}

.summary-box {
  padding: 12px 14px;
  border-radius: var(--radius-md);
  font-size: 13px;
  line-height: 1.6;
}

.summary-box.good {
  background: rgba(42, 157, 143, 0.12);
  border-left: 3.5px solid #2A9D8F;
}

.summary-box.warn {
  background: rgba(230, 57, 70, 0.12);
  border-left: 3.5px solid #E63946;
}

.summary-box.taboo {
  background: rgba(157, 78, 221, 0.12);
  border-left: 3.5px solid #9D4EDD;
}

.summary-box.action {
  background: rgba(212, 175, 55, 0.12);
  border-left: 3.5px solid var(--accent-gold-bright);
}

.summary-title {
  font-weight: bold;
  font-size: 13px;
  margin-bottom: 4px;
}

.summary-box.good .summary-title { color: #52B788; }
.summary-box.warn .summary-title { color: #FF758F; }
.summary-box.taboo .summary-title { color: #C77DFF; }
.summary-box.action .summary-title { color: #FFD700; }

.summary-text {
  color: var(--text-main);
  font-size: 12.5px;
}

/* Master Treatise Accordion */
.master-treatise-accordion {
  background: rgba(14, 10, 18, 0.7);
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  transition: all 0.3s ease;
}

.master-treatise-accordion[open] {
  background: rgba(14, 10, 18, 0.95);
  border-color: var(--border-gold);
}

.treatise-accordion-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--accent-gold-bright);
  font-size: 14px;
  cursor: pointer;
  user-select: none;
  list-style: none;
}

.treatise-accordion-summary::-webkit-details-marker {
  display: none;
}

.accordion-arrow {
  font-size: 12px;
  color: var(--text-muted);
  transition: transform 0.2s ease;
}

details[open] .accordion-arrow {
  transform: rotate(180deg);
}

/* ==========================================================================
   3. AI Dream Interactive Dialogue (周公解梦多轮 AI 对话追问)
   ========================================================================== */
.ai-chat-card {
  background: linear-gradient(145deg, rgba(24, 18, 32, 0.95) 0%, rgba(12, 10, 16, 0.98) 100%);
  border: 1.5px solid rgba(157, 78, 221, 0.4);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
  text-align: left;
}

.ai-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(157, 78, 221, 0.25);
  margin-bottom: 14px;
}

.ai-prompt-chips-wrap {
  margin-bottom: 14px;
}

.ai-prompt-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ai-prompt-chip {
  background: rgba(157, 78, 221, 0.12);
  border: 1px solid rgba(157, 78, 221, 0.3);
  color: #D8B4E2;
  font-size: 12px;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.2s ease;
}

.ai-prompt-chip:hover {
  background: rgba(157, 78, 221, 0.28);
  border-color: #C77DFF;
  color: #fff;
  transform: translateY(-1px);
}

.ai-chat-messages {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 380px;
  overflow-y: auto;
  padding: 10px;
  background: rgba(10, 8, 14, 0.6);
  border-radius: var(--radius-md);
  border: 1px solid rgba(212, 175, 55, 0.15);
  margin-bottom: 14px;
}

.ai-msg-bubble {
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.7;
  max-width: 88%;
  white-space: pre-line;
}

.ai-msg-bubble.user {
  align-self: flex-end;
  background: linear-gradient(135deg, #8B0000, #5B0000);
  border: 1px solid rgba(212, 175, 55, 0.4);
  color: #faeed7;
  border-bottom-right-radius: 2px;
}

.ai-msg-bubble.master {
  align-self: flex-start;
  background: rgba(28, 22, 38, 0.85);
  border: 1px solid rgba(157, 78, 221, 0.35);
  color: #ded7ca;
  border-bottom-left-radius: 2px;
}

.ai-chat-input-bar {
  display: flex;
  gap: 8px;
}

.ai-chat-input {
  flex: 1;
  background: rgba(10, 8, 14, 0.8);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: var(--radius-full);
  color: var(--text-main);
  padding: 10px 18px;
  font-size: 13.5px;
  outline: none;
}

.ai-chat-input:focus {
  border-color: var(--accent-gold-bright);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

.ai-chat-send-btn {
  background: linear-gradient(135deg, #9D4EDD, #7B2CBF);
  border: 1px solid #C77DFF;
  color: #fff;
  font-weight: 600;
  font-size: 13px;
  padding: 0 20px;
  border-radius: var(--radius-full);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.ai-chat-send-btn:hover {
  background: linear-gradient(135deg, #C77DFF, #9D4EDD);
  transform: translateY(-1px);
}

/* ==========================================================================
   4. Visual Auspicious Month Calendar Matrix (红圈吉日热力图)
   ========================================================================== */
.lucky-cal-card {
  background: linear-gradient(145deg, rgba(24, 20, 32, 0.95) 0%, rgba(12, 10, 16, 0.98) 100%);
  border: 1.5px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-top: 20px;
  text-align: left;
}

.lucky-cal-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.lucky-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  margin-bottom: 16px;
}

.lucky-cal-week-header {
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-gold);
  padding: 6px 0;
}

.lucky-cal-day-cell {
  background: rgba(14, 10, 18, 0.7);
  border: 1px solid rgba(212, 175, 55, 0.18);
  border-radius: 8px;
  padding: 8px 4px;
  min-height: 64px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.lucky-cal-day-cell:hover {
  border-color: var(--accent-gold-bright);
  transform: scale(1.04);
  z-index: 2;
}

.lucky-cal-day-cell.active {
  border-color: #FFD700 !important;
  box-shadow: 0 0 14px rgba(212, 175, 55, 0.5) !important;
  background: rgba(212, 175, 55, 0.15) !important;
}

/* Auspicious Status Tags */
.lucky-cal-day-cell.great-auspicious {
  border: 1.8px solid #E63946;
  background: rgba(230, 57, 70, 0.12);
}

.lucky-red-circle {
  width: 24px;
  height: 24px;
  margin: 0 auto;
  border: 2px solid #E63946;
  border-radius: 50%;
  color: #FF758F;
  font-weight: bold;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(230, 57, 70, 0.2);
  box-shadow: 0 0 8px rgba(230, 57, 70, 0.5);
}

.lucky-badge-good {
  font-size: 10px;
  color: #52B788;
  background: rgba(82, 183, 136, 0.15);
  border-radius: 3px;
  padding: 1px 4px;
  display: inline-block;
  margin-top: 2px;
}

.lucky-badge-caution {
  font-size: 10px;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
  padding: 1px 4px;
  display: inline-block;
  margin-top: 2px;
}

.lucky-day-cockpit {
  background: rgba(10, 8, 14, 0.85);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-top: 14px;
  animation: fadeIn 0.25s ease;
}



/* ==========================================================================
   Comprehensive Mobile & Desktop Dual-Platform Layout Optimization
   ========================================================================== */

/* Universal Mobile Inputs: prevent iOS zoom */
@media (max-width: 768px) {
  input[type="text"],
  input[type="date"],
  input[type="number"],
  select,
  textarea {
    font-size: 16px !important;
  }

  .main-content {
    padding: 10px 12px 30px 12px !important;
  }

  /* 4 Flagship Cards on Mobile */
  .portal-flagship-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
  }

  .flagship-card {
    padding: 16px 12px 14px 12px !important;
    border-radius: 12px !important;
  }

  .flagship-card-icon {
    font-size: 28px !important;
    margin-bottom: 8px !important;
  }

  .flagship-card-badge {
    font-size: 9.5px !important;
    padding: 1px 6px !important;
    top: 10px !important;
    right: 10px !important;
  }

  .flagship-card-title {
    font-size: 15px !important;
    margin-bottom: 4px !important;
  }

  .flagship-card-desc {
    font-size: 11.5px !important;
    margin-bottom: 10px !important;
    line-height: 1.4 !important;
  }

  .flagship-card-action {
    font-size: 11.5px !important;
  }

  /* Secondary Tools Grid on Mobile */
  .secondary-tools-accordion {
    padding: 12px 14px !important;
    border-radius: 12px !important;
  }

  .secondary-tools-summary {
    font-size: 13.5px !important;
  }

  /* Progressive Disclosure Cockpit on Mobile */
  .result-highlight-cockpit {
    padding: 14px 12px !important;
    border-radius: 12px !important;
  }

  .result-cockpit-title {
    font-size: 16px !important;
  }

  .result-keywords-row {
    gap: 6px !important;
    margin-bottom: 12px !important;
  }

  .result-keyword-pill {
    font-size: 11px !important;
    padding: 3px 9px !important;
  }

  .result-summary-grid {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }

  .summary-box {
    padding: 10px 12px !important;
  }

  .summary-title {
    font-size: 12.5px !important;
  }

  .summary-text {
    font-size: 12px !important;
  }

  /* Master Treatise Grid on Mobile */
  .master-treatise-grid {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }

  .treatise-card {
    padding: 14px 12px !important;
  }

  /* AI Dream Chat on Mobile */
  .ai-chat-card {
    padding: 14px 12px !important;
  }

  .ai-prompt-chip {
    font-size: 11.5px !important;
    padding: 4px 10px !important;
  }

  .ai-msg-bubble {
    max-width: 92% !important;
    font-size: 12.5px !important;
    padding: 8px 12px !important;
  }

  .ai-chat-input {
    font-size: 14px !important;
    padding: 8px 14px !important;
  }

  .ai-chat-send-btn {
    padding: 0 14px !important;
    font-size: 12px !important;
  }

  /* Lucky Days Calendar Matrix on Mobile */
  .lucky-cal-card {
    padding: 14px 10px !important;
    border-radius: 12px !important;
  }

  .lucky-cal-top-bar {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 10px;
  }

  .lucky-cal-top-bar strong {
    font-size: 15px !important;
  }

  .lucky-cal-grid {
    gap: 3px !important;
  }

  .lucky-cal-day-cell {
    min-height: 48px !important;
    padding: 4px 1px !important;
    border-radius: 6px !important;
  }

  .lucky-cal-day-cell > div:first-child {
    font-size: 13px !important;
  }

  .lucky-cal-day-cell > div:nth-child(2) {
    font-size: 9px !important;
  }

  .lucky-red-circle {
    width: 18px !important;
    height: 18px !important;
    font-size: 9.5px !important;
    border-width: 1.5px !important;
  }

  .lucky-badge-good, .lucky-badge-caution {
    font-size: 8.5px !important;
    padding: 0 2px !important;
  }

  .lucky-day-cockpit {
    padding: 12px 10px !important;
  }

  /* Bazi Table Mobile Horizontal Scrolling */
  .bazi-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    margin: 10px 0;
  }

  .bazi-table {
    min-width: 480px;
  }

  /* Cezi Matrix on Mobile */
  .cezi-char-pill {
    width: 36px !important;
    height: 36px !important;
    font-size: 14.5px !important;
  }
}

/* Desktop Optimization (min-width: 769px) */
@media (min-width: 769px) {
  .portal-flagship-grid {
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 18px;
  }

  .result-summary-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }

  .master-treatise-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .master-treatise-grid .full-width {
    grid-column: 1 / -1;
  }

  .lucky-cal-grid {
    gap: 8px;
  }

  .lucky-cal-day-cell {
    min-height: 72px;
    padding: 10px 6px;
  }
}



/* ==========================================================================
   Daily Fortune & Metaphysics Dressing Guide Styles (今日专属运势与五行穿衣)
   ========================================================================== */
.daily-fortune-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: left;
  animation: fadeIn 0.3s ease;
}

.daily-score-card {
  background: linear-gradient(145deg, rgba(28, 22, 38, 0.95) 0%, rgba(14, 10, 18, 0.98) 100%);
  border: 1.5px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.daily-score-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.daily-score-dial {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.25) 0%, rgba(10, 8, 14, 0.9) 80%);
  border: 2.5px solid var(--accent-gold-bright);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 16px rgba(212, 175, 55, 0.4);
}

.daily-score-num {
  font-size: 22px;
  font-weight: 800;
  color: #FFD700;
  line-height: 1;
}

.daily-score-label {
  font-size: 9.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.daily-score-meta h4 {
  font-family: var(--font-serif);
  font-size: 20px;
  color: var(--accent-gold-bright);
  margin: 0 0 4px 0;
}

.daily-score-meta p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}

.daily-radar-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.daily-radar-item {
  background: rgba(10, 8, 14, 0.8);
  border: 1px solid rgba(212, 175, 55, 0.25);
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
}

/* 防小人专属预警卡片 */
.daily-villain-card {
  background: linear-gradient(135deg, rgba(230, 57, 70, 0.12) 0%, rgba(10, 8, 14, 0.85) 100%);
  border: 1.5px solid #E63946;
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: 0 4px 20px rgba(230, 57, 70, 0.15);
}

.daily-villain-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14.5px;
  font-weight: bold;
  color: #FF758F;
  margin-bottom: 8px;
}

/* 五行穿衣指南卡片群 */
.daily-dressing-section {
  background: linear-gradient(145deg, rgba(22, 18, 30, 0.95) 0%, rgba(12, 10, 16, 0.98) 100%);
  border: 1.5px solid rgba(212, 175, 55, 0.35);
  border-radius: var(--radius-lg);
  padding: 20px;
}

.daily-dressing-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
  margin-bottom: 14px;
}

.daily-dressing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.dressing-tier-card {
  background: rgba(10, 8, 14, 0.7);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  border-left: 4px solid var(--border-gold);
}

.dressing-tier-card.best { border-left-color: #2A9D8F; background: rgba(42, 157, 143, 0.08); }
.dressing-tier-card.good { border-left-color: #D4AF37; background: rgba(212, 175, 55, 0.08); }
.dressing-tier-card.fair { border-left-color: #B7791F; background: rgba(183, 121, 31, 0.08); }
.dressing-tier-card.drain { border-left-color: #718096; background: rgba(113, 128, 150, 0.08); }
.dressing-tier-card.taboo { border-left-color: #E63946; background: rgba(230, 57, 70, 0.08); }

.dressing-tier-title {
  font-size: 13.5px;
  font-weight: bold;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.dressing-tier-card.best .dressing-tier-title { color: #52B788; }
.dressing-tier-card.good .dressing-tier-title { color: #FFD700; }
.dressing-tier-card.fair .dressing-tier-title { color: #F6AD55; }
.dressing-tier-card.drain .dressing-tier-title { color: #CBD5E0; }
.dressing-tier-card.taboo .dressing-tier-title { color: #FF758F; }

.dressing-color-names {
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 4px;
}

.dressing-desc {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* 附图传统大宗黄历明细卡片 */
.daily-almanac-details-card {
  background: rgba(12, 10, 16, 0.95);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 20px;
}

.daily-yi-ji-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 16px;
}

@media (max-width: 768px) {
  .daily-yi-ji-row {
    grid-template-columns: 1fr !important;
  }
  .daily-dressing-grid {
    grid-template-columns: 1fr !important;
  }
}



/* Interactive Hourly Fortune Styles */
.hourly-card {
  cursor: pointer !important;
  user-select: none;
  position: relative;
}

.hourly-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent-gold-bright) !important;
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.25);
}

.hourly-card.active {
  border-color: #FFD700 !important;
  background: rgba(212, 175, 55, 0.18) !important;
  box-shadow: 0 0 14px rgba(212, 175, 55, 0.45) !important;
  transform: scale(1.03);
}

.hourly-now-badge {
  position: absolute;
  top: -6px;
  right: -4px;
  background: linear-gradient(135deg, #E63946, #8B0000);
  color: #FFF;
  font-size: 9px;
  font-weight: bold;
  padding: 1px 5px;
  border-radius: 6px;
  border: 1px solid #FFAAA6;
  box-shadow: 0 0 6px rgba(230, 57, 70, 0.6);
}

.hourly-detail-cockpit {
  background: linear-gradient(145deg, rgba(26, 20, 36, 0.95) 0%, rgba(12, 10, 16, 0.98) 100%);
  border: 1.5px solid var(--border-gold);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  text-align: left;
  margin-top: 10px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  animation: fadeIn 0.25s ease;
}
