/* ==========================================
   Eight Destiny - Main Styles
   ========================================== */

:root {
    --primary: #8B4513;
    --primary-light: #D4A574;
    --primary-dark: #5D2E0C;
    --gold: #DAA520;
    --gold-light: #F4D03F;
    --red: #C41E3A;
    --blue: #1E3A5F;
    --bg-light: #FDF8F3;
    --bg-dark: #2C1810;
    --text-dark: #1A1A1A;
    --text-light: #F5F5F5;
    --text-muted: #666;
    --border: #E5D4C0;
    --shadow: rgba(139, 69, 19, 0.15);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Serif TC', 'Inter', serif;
    background: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.7;
    min-height: 100vh;
}

/* ==========================================
   Header
   ========================================== */
header {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 20px var(--shadow);
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--gold);
}

.logo-icon {
    font-size: 2.5rem;
    animation: spin 20s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.logo span {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-light);
}

/* ==========================================
   Main Navigation
   ========================================== */
.main-nav {
    display: flex;
    gap: 0.5rem;
}

.nav-link {
    padding: 0.5rem 1rem;
    color: var(--primary-light);
    text-decoration: none;
    border-radius: 20px;
    transition: all 0.3s;
    font-size: 0.9rem;
    white-space: nowrap;
}

.nav-link:hover {
    background: var(--gold);
    color: var(--primary-dark);
}

/* ==========================================
   Language Switcher Buttons
   ========================================== */
.lang-switcher {
    display: flex;
    gap: 0.25rem;
}

.lang-btn {
    padding: 0.4rem 0.8rem;
    background: transparent;
    color: var(--primary-light);
    border: 1px solid var(--primary-light);
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 0.85rem;
    font-family: inherit;
}

.lang-btn:hover {
    background: var(--gold);
    color: var(--primary-dark);
    border-color: var(--gold);
}

.lang-btn.active {
    background: var(--gold);
    color: var(--primary-dark);
    border-color: var(--gold);
}

/* ==========================================
   Language Dropdown
   ========================================== */
.lang-dropdown {
    position: relative;
}

.lang-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: transparent;
    color: var(--primary-light);
    border: 1px solid var(--primary-light);
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9rem;
    font-family: inherit;
    transition: all 0.3s;
}

.lang-dropdown-btn:hover {
    background: var(--gold);
    color: var(--primary-dark);
    border-color: var(--gold);
}

.lang-dropdown-btn::after {
    content: '▼';
    font-size: 0.6rem;
    margin-left: 0.25rem;
}

.lang-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 120px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s;
    z-index: 1000;
    margin-top: 0.5rem;
    overflow: hidden;
}

.lang-dropdown:hover .lang-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-dropdown-item {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--text-dark);
    text-decoration: none;
    transition: background 0.2s;
    font-size: 0.9rem;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
}

.lang-dropdown-item:hover {
    background: var(--bg-light);
    color: var(--primary);
}

.lang-dropdown-item.active {
    background: var(--gold);
    color: var(--primary-dark);
    font-weight: 600;
}

@media (max-width: 1024px) {
    .main-nav {
        display: none;
    }
}

/* ==========================================
   Mobile Navigation
   ========================================== */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 5px;
    z-index: 1001;
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 3px;
    background: var(--primary-light);
    border-radius: 2px;
    transition: all 0.3s;
}

.mobile-menu-btn:hover span {
    background: var(--gold);
}

.mobile-nav-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1002;
    opacity: 0;
    transition: opacity 0.3s;
}

.mobile-nav-overlay.active {
    display: block;
    opacity: 1;
}

.mobile-nav {
    position: fixed;
    top: 0;
    right: -300px;
    width: 280px;
    height: 100vh;
    background: white;
    z-index: 1003;
    transition: right 0.3s ease;
    overflow-y: auto;
    box-shadow: -5px 0 20px rgba(0, 0, 0, 0.2);
}

.mobile-nav.active {
    right: 0;
}

.mobile-nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
    color: white;
}

.mobile-nav-title {
    font-size: 1.25rem;
    font-weight: 600;
}

.mobile-nav-close {
    font-size: 2rem;
    color: white;
    background: none;
    border: none;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s;
}

.mobile-nav-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.mobile-nav-link {
    display: block;
    padding: 1rem 1.25rem;
    color: var(--text-dark);
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    border-bottom: 1px solid var(--border);
    transition: all 0.3s;
}

.mobile-nav-link:hover {
    background: var(--bg-light);
    color: var(--primary);
    padding-left: 1.5rem;
}

@media (max-width: 1024px) {
    .mobile-menu-btn {
        display: flex;
    }
    
    .header-content {
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .mobile-nav {
        width: 85%;
        max-width: 300px;
    }
    
    .header-content {
        padding: 0 1rem;
    }
    
    .logo span {
        font-size: 1.25rem;
    }
    
    .logo-icon {
        font-size: 2rem;
    }
}

/* ==========================================
   Main Content
   ========================================== */
main {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* ==========================================
   Hero Section
   ========================================== */
.hero-section {
    position: relative;
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 6rem 2rem;
    background: linear-gradient(180deg, var(--bg-light) 0%, #F5EBE0 100%);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%238B4513' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-section h1 {
    font-size: 4rem;
    color: var(--primary-dark);
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-muted);
    margin-bottom: 3rem;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 4rem;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--gold);
}

.stat-label {
    font-size: 1rem;
    color: var(--text-muted);
}

/* ==========================================
   Section Title
   ========================================== */
.section-title {
    text-align: center;
    font-size: 2.5rem;
    color: var(--primary-dark);
    margin: 4rem 0 3rem;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--gold);
    margin: 1rem auto 0;
    border-radius: 2px;
}

/* ==========================================
   Features Grid
   ========================================== */
.features-section {
    padding: 2rem 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.feature-card {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 10px 40px var(--shadow);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 60px var(--shadow);
}

.feature-card.featured {
    background: linear-gradient(135deg, var(--red) 0%, #8B0000 100%);
    color: white;
}

.feature-card.featured .feature-btn {
    background: white;
    color: var(--red);
}

.feature-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--gold);
    color: var(--primary-dark);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.feature-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}

.feature-card h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
    color: inherit;
}

.feature-card p {
    font-size: 1rem;
    margin-bottom: 1.5rem;
    opacity: 0.9;
}

.feature-list {
    list-style: none;
    margin-bottom: 1.5rem;
}

.feature-list li {
    padding: 0.5rem 0;
    font-size: 0.95rem;
    opacity: 0.9;
}

.feature-btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--gold);
    color: var(--primary-dark);
    border-radius: 25px;
    font-weight: 600;
    transition: all 0.3s;
}

.feature-card:hover .feature-btn {
    transform: scale(1.05);
}

/* ==========================================
   Info Section
   ========================================== */
.info-section {
    padding: 4rem 0;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.info-card {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    border-left: 5px solid var(--gold);
    box-shadow: 0 5px 20px var(--shadow);
}

.info-card h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.info-card p {
    color: var(--text-muted);
    line-height: 1.8;
}

/* ==========================================
   CTA Section
   ========================================== */
.cta-section {
    text-align: center;
    padding: 5rem 2rem;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
    border-radius: 30px;
    margin: 4rem 0;
}

.cta-section h2 {
    color: var(--gold);
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-section p {
    color: var(--text-light);
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.btn {
    padding: 1rem 2.5rem;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s;
    display: inline-block;
}

.btn-primary {
    background: var(--gold);
    color: var(--primary-dark);
}

.btn-primary:hover {
    background: var(--gold-light);
    transform: scale(1.05);
}

.btn-secondary {
    background: transparent;
    color: var(--text-light);
    border: 2px solid var(--gold);
}

.btn-secondary:hover {
    background: var(--gold);
    color: var(--primary-dark);
}

/* ==========================================
   Footer
   ========================================== */
footer {
    background: var(--bg-dark);
    color: var(--text-light);
    padding: 2rem;
    text-align: center;
    margin-top: 4rem;
}

.footer-content p {
    opacity: 0.8;
}

/* ==========================================
   Form Styles (for BaZi & Match pages)
   ========================================== */
.card {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 10px 40px var(--shadow);
    margin-bottom: 2rem;
}

.card-title {
    font-size: 1.75rem;
    color: var(--primary-dark);
    margin-bottom: 2rem;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.form-group select, .form-group input {
    padding: 1rem;
    border: 2px solid var(--border);
    border-radius: 12px;
    font-size: 1rem;
    font-family: inherit;
    background: white;
    transition: all 0.3s;
    cursor: pointer;
}

.form-group select:focus, .form-group input:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 4px rgba(218, 165, 32, 0.2);
}

.form-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.btn-gold {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    color: var(--primary-dark);
    border: none;
    padding: 1rem 3rem;
    border-radius: 30px;
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 20px rgba(218, 165, 32, 0.4);
}

.btn-gold:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(218, 165, 32, 0.5);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
    padding: 1rem 2rem;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

/* ==========================================
   Tabs
   ========================================== */
.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    background: white;
    padding: 0.5rem;
    border-radius: 15px;
    margin-bottom: 2rem;
    box-shadow: 0 5px 20px var(--shadow);
}

.tab-btn {
    flex: 1;
    min-width: 120px;
    padding: 1rem;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    border-radius: 10px;
    transition: all 0.3s;
}

.tab-btn:hover {
    background: var(--bg-light);
}

.tab-btn.active {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==========================================
   BaZi Chart Display
   ========================================== */
.chart-grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.pillar-card {
    background: linear-gradient(135deg, #FFF8F0 0%, #FFF5E6 100%);
    border: 2px solid var(--border);
    border-radius: 15px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s;
}

.pillar-card:hover {
    transform: scale(1.02);
    border-color: var(--gold);
}

.pillar-card.highlight {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    border-color: var(--gold);
}

.pillar-header {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
    font-weight: 600;
}

.pillar-body {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.pillar-gan, .pillar-zhi {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.pillar-footer {
    display: flex;
    justify-content: center;
    gap: 1rem;
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.pillar-shishen {
    font-size: 0.85rem;
    color: var(--gold);
    font-weight: 600;
    padding-top: 0.5rem;
    border-top: 1px dashed var(--border);
}

/* ==========================================
   Section Titles within cards
   ========================================== */
.section-title-small {
    font-size: 1.25rem;
    color: var(--primary);
    margin: 2rem 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--gold);
}

/* ==========================================
   Hidden Stems Grid
   ========================================== */
.canggan-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1rem 0;
}

.canggan-item {
    background: #F9F5F0;
    padding: 1rem;
    border-radius: 10px;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0.75rem;
    min-width: 0;
}

.canggan-zhi {
    min-width: 60px;
    flex-shrink: 0;
}

.canggan-item strong {
    color: var(--primary);
    font-size: 1.1rem;
    display: block;
}

.canggan-gans {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    flex: 1;
    min-width: 0;
}

.canggan-gan {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    padding: 0.4rem 0.6rem;
    background: white;
    border-radius: 6px;
    flex-shrink: 0;
    min-width: 50px;
}

.canggan-gan .gan-text {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-dark);
    line-height: 1.2;
}

.canggan-gan .strength-text {
    font-size: 0.65rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    display: block;
}

/* ==========================================
   Shen Sha Grid
   ========================================== */
.shensha-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1rem 0;
}

.shensha-item {
    background: linear-gradient(135deg, #FFF8F0 0%, #FFF5E6 100%);
    padding: 1rem;
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.shensha-name {
    font-weight: 600;
    color: var(--primary);
}

.shensha-values {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* ==========================================
   DaYun Table
   ========================================== */
.dayun-table {
    overflow-x: auto;
    margin: 1rem 0;
}

.dayun-table-inner {
    width: 100%;
    border-collapse: collapse;
}

.dayun-table-inner th, .dayun-table-inner td {
    padding: 1rem;
    text-align: center;
    border: 1px solid var(--border);
}

.dayun-table-inner th {
    background: var(--primary);
    color: white;
    font-weight: 600;
}

.dayun-table-inner tr:nth-child(even) {
    background: #F9F5F0;
}

/* ==========================================
   Five Elements Chart
   ========================================== */
.wuxing-chart {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 1rem 0;
}

.wuxing-bar-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.wuxing-bar-label {
    min-width: 150px;
    display: flex;
    justify-content: space-between;
    font-weight: 600;
}

.wuxing-bar-track {
    flex: 1;
    height: 30px;
    background: #EEE;
    border-radius: 15px;
    overflow: hidden;
}

.wuxing-bar-fill {
    height: 100%;
    border-radius: 15px;
    transition: width 1s ease;
}

.xiyong-card, .strength-card {
    background: linear-gradient(135deg, #FFF8F0 0%, #FFF5E6 100%);
    padding: 1.5rem;
    border-radius: 15px;
    margin-top: 1.5rem;
}

.xiyong-card h3, .strength-card h3 {
    color: var(--primary);
    margin-bottom: 1rem;
}

.strength-meter {
    height: 20px;
    background: #EEE;
    border-radius: 10px;
    overflow: hidden;
    margin: 1rem 0;
}

.strength-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--gold) 0%, var(--gold-light) 100%);
    border-radius: 10px;
    transition: width 1s ease;
}

/* ==========================================
   Lucky Info Grid
   ========================================== */
.liuNian-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    padding: 2rem;
    border-radius: 15px;
    margin-bottom: 2rem;
}

.liuNian-main {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.liuNian-ganzhi {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.liuNian-wuxing {
    font-size: 1.5rem;
    color: var(--primary);
}

.liuNian-relation {
    font-size: 1.25rem;
    color: var(--primary-dark);
    font-weight: 600;
}

.lucky-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.lucky-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 20px var(--shadow);
    transition: transform 0.3s;
}

.lucky-item:hover {
    transform: translateY(-5px);
}

.lucky-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.lucky-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.lucky-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
}

/* ==========================================
   Keywords
   ========================================== */
.keywords-list, .keyword-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1rem 0;
}

.keyword-tag {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    color: var(--primary-dark);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.95rem;
}

/* ==========================================
   Monthly Grid
   ========================================== */
.monthly-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 1rem 0;
}

.month-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
    border-left: 4px solid var(--gold);
}

.month-header {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.month-summary {
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.month-tips {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* ==========================================
   Personality
   ========================================== */
.personality-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 1.5rem;
    border-radius: 15px;
    margin-bottom: 2rem;
}

.daymaster-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.daymaster-label {
    color: var(--primary-light);
}

.daymaster-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gold);
}

.strength-badge {
    background: var(--gold);
    color: var(--primary-dark);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
}

.description-box {
    background: #F9F5F0;
    padding: 2rem;
    border-radius: 15px;
    margin-bottom: 2rem;
    font-size: 1.1rem;
    line-height: 2;
}

.traits-grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.trait-card {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
}

.trait-card h3 {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.trait-card ul {
    list-style: none;
}

.trait-card li {
    padding: 0.5rem 0;
    border-bottom: 1px dashed var(--border);
}

.trait-card li:last-child {
    border-bottom: none;
}

/* ==========================================
   Marriage
   ========================================== */
.match-score-card {
    display: flex;
    align-items: center;
    gap: 2rem;
    background: linear-gradient(135deg, var(--red) 0%, #8B0000 100%);
    padding: 2rem;
    border-radius: 20px;
    margin-bottom: 2rem;
}

.score-circle {
    width: 120px;
    height: 120px;
    background: white;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.score-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--red);
    line-height: 1;
}

.score-label {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.score-info {
    color: white;
}

.score-info span {
    font-size: 1.5rem;
    font-weight: 700;
}

.score-info p {
    margin-top: 0.5rem;
    opacity: 0.9;
}

.marriage-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.marriage-item {
    background: #F9F5F0;
    padding: 1.5rem;
    border-radius: 15px;
}

.marriage-item h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.gan-tags {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.gan-tag {
    background: var(--gold);
    color: var(--primary-dark);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
}

.marriage-notes {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
}

.marriage-notes h3 {
    color: var(--primary);
    margin-bottom: 1rem;
}

.marriage-notes ul {
    list-style: none;
}

.marriage-notes li {
    padding: 0.75rem 0;
    border-bottom: 1px dashed var(--border);
    padding-left: 1.5rem;
    position: relative;
}

.marriage-notes li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--gold);
}

/* ==========================================
   Career
   ========================================== */
.career-section {
    margin-bottom: 2rem;
}

.career-section h3 {
    color: var(--primary);
    margin-bottom: 1rem;
}

.career-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.career-item {
    background: #F9F5F0;
    padding: 1.5rem;
    border-radius: 15px;
}

.career-item h4 {
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.career-analysis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.analysis-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
}

.analysis-item h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.wealth-tips {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    padding: 1.5rem;
    border-radius: 15px;
}

.wealth-tips h3 {
    color: var(--primary-dark);
    margin-bottom: 0.75rem;
}

/* ==========================================
   Modal
   ========================================== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.7);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-muted);
    transition: color 0.3s;
}

.modal-close:hover {
    color: var(--red);
}

.modal-content h2 {
    color: var(--primary);
    margin-bottom: 1rem;
}

.modal-content p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.match-result {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid var(--border);
}

.match-score-large {
    text-align: center;
    margin-bottom: 1.5rem;
}

.match-score-large span:first-child {
    font-size: 4rem;
    font-weight: 700;
    color: var(--gold);
}

.match-level {
    display: block;
    font-size: 1.5rem;
    color: var(--primary);
    margin-top: 0.5rem;
}

.match-result h4 {
    color: var(--primary);
    margin: 1rem 0;
}

.match-result ul {
    list-style: none;
}

.match-result li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
}

.match-result li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--gold);
}

/* ==========================================
   Result Section
   ========================================== */
.result-section {
    display: none;
    margin-top: 3rem;
    padding-top: 3rem;
    border-top: 2px solid var(--border);
}

.result-section.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

.disclaimer {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 3rem;
    padding: 1rem;
    background: #F9F5F0;
    border-radius: 10px;
}

/* ==========================================
   Zodiac Page Specific
   ========================================== */
.year-input-section {
    text-align: center;
    padding: 1rem 0;
}

.year-input-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.year-input-wrapper label {
    font-weight: 600;
    color: var(--primary);
    font-size: 1rem;
}

.year-input {
    padding: 0.75rem 1.5rem;
    border: 2px solid var(--border);
    border-radius: 25px;
    font-size: 1rem;
    width: 150px;
    text-align: center;
    font-family: inherit;
    transition: all 0.3s;
}

.year-input:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 4px rgba(218, 165, 32, 0.2);
}

.year-hint {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 0.75rem;
}

.zodiac-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.zodiac-btn {
    background: white;
    border: 2px solid var(--border);
    border-radius: 15px;
    padding: 1.25rem 1rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary);
    font-family: inherit;
    box-shadow: 0 5px 15px var(--shadow);
}

.zodiac-btn:hover {
    transform: translateY(-5px);
    border-color: var(--gold);
    box-shadow: 0 10px 25px rgba(218, 165, 32, 0.3);
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    color: var(--primary-dark);
}

.zodiac-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 20px var(--shadow);
}

.zodiac-item:hover {
    transform: translateY(-5px);
    border-color: var(--gold);
}

.zodiac-item.selected {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    border-color: var(--gold);
}

.zodiac-item .zodiac-icon {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.zodiac-item .zodiac-name {
    font-weight: 600;
    color: var(--primary);
}

.zodiac-result {
    display: none;
    margin-top: 2rem;
}

.zodiac-result.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

/* ==========================================
   Birthday Page Specific
   ========================================== */
.birthday-display {
    text-align: center;
    padding: 2rem;
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    border-radius: 20px;
    margin-bottom: 2rem;
}

.life-path-number {
    font-size: 5rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.life-path-label {
    font-size: 1.5rem;
    color: var(--primary);
    margin-top: 0.5rem;
}

/* ==========================================
   History Section
   ========================================== */
.history-section {
    padding: 4rem 0;
    background: linear-gradient(180deg, var(--bg-light) 0%, #F5EBE0 100%);
    margin: 2rem 0;
    border-radius: 30px;
}

.history-intro {
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.timeline {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 2rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, var(--gold) 0%, var(--primary) 100%);
    border-radius: 2px;
}

.timeline-item {
    display: flex;
    justify-content: flex-start;
    padding-left: calc(50% + 3rem);
    position: relative;
    margin-bottom: 2.5rem;
}

.timeline-item:nth-child(even) {
    justify-content: flex-end;
    padding-left: 0;
    padding-right: calc(50% + 3rem);
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 20px;
    background: var(--gold);
    border: 4px solid white;
    border-radius: 50%;
    box-shadow: 0 0 0 4px var(--gold);
    z-index: 1;
    top: 0;
}

.timeline-date {
    display: inline-block;
    background: var(--gold);
    color: var(--primary-dark);
    padding: 0.3rem 0.8rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    box-shadow: 0 2px 8px var(--shadow);
}

.timeline-content {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
    max-width: 400px;
    position: relative;
}

.timeline-content::before {
    content: '';
    position: absolute;
    top: 0;
    width: 0;
    height: 0;
}

.timeline-item:not(:nth-child(even)) .timeline-content::before {
    left: -0.5rem;
    top: 1rem;
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    border-right: 10px solid white;
}

.timeline-item:nth-child(even) .timeline-content::before {
    right: -0.5rem;
    top: 1rem;
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    border-left: 10px solid white;
}

.timeline-content h3 {
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.timeline-content p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

.classics-grid {
    margin-top: 3rem;
    padding: 0 2rem;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.classics-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.classic-item {
    display: flex;
    gap: 1rem;
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
    border-left: 4px solid var(--gold);
}

.classic-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.classic-info h4 {
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.classic-info p {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* ==========================================
   Philosophy Section
   ========================================== */
.philosophy-section {
    padding: 4rem 0;
}

.philosophy-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.philosophy-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 2rem;
    border-radius: 20px;
    color: white;
    text-align: center;
    transition: transform 0.3s;
}

.philosophy-card:hover {
    transform: translateY(-5px);
}

.philosophy-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.philosophy-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--gold);
}

.philosophy-card p {
    font-size: 0.95rem;
    line-height: 1.8;
    opacity: 0.9;
}

@media (max-width: 768px) {
    .timeline::before {
        left: 1.5rem;
    }
    
    .timeline-item,
    .timeline-item:nth-child(even) {
        padding-left: 4rem;
        padding-right: 0;
        justify-content: flex-start;
    }
    
    .timeline-item::before,
    .timeline-item:nth-child(even)::before {
        left: 1.5rem;
        transform: translateX(-50%);
    }
    
    .timeline-date {
        font-size: 0.8rem;
        padding: 0.25rem 0.6rem;
    }
    
    .timeline-content,
    .timeline-item:nth-child(even) .timeline-content {
        max-width: 100%;
    }
    
    .timeline-item:not(:nth-child(even)) .timeline-content::before,
    .timeline-item:nth-child(even) .timeline-content::before {
        left: -0.5rem;
        right: auto;
        border-right: 10px solid white;
        border-left: none;
    }
}

/* ==========================================
   Responsive Design
   ========================================== */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    /* Chart page mobile optimization */
    .page-header {
        padding: 2rem 1rem;
        border-radius: 0 0 20px 20px;
    }
    
    .page-header h1 {
        font-size: 1.75rem;
    }
    
    .page-header p {
        font-size: 0.95rem;
    }
    
    .page-nav {
        gap: 0.5rem;
    }
    
    .page-nav-btn {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
    }
    
    /* Card mobile optimization */
    .card {
        padding: 1.25rem;
        border-radius: 15px;
    }
    
    .card-title {
        font-size: 1.25rem;
        margin-bottom: 1.25rem;
    }
    
    /* Four pillars grid mobile */
    .chart-grid-4 {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    
    .pillar-card {
        padding: 1rem;
        border-radius: 12px;
    }
    
    .pillar-header {
        font-size: 0.75rem;
        margin-bottom: 0.5rem;
    }
    
    .pillar-gan, .pillar-zhi {
        font-size: 1.75rem;
    }
    
    .pillar-footer {
        font-size: 0.75rem;
        gap: 0.5rem;
    }
    
    .pillar-shishen {
        font-size: 0.7rem;
    }
    
    /* Hidden stems mobile */
    .canggan-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .canggan-item {
        padding: 0.75rem;
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }
    
    .canggan-zhi {
        min-width: auto;
    }
    
    .canggan-item strong {
        font-size: 1rem;
    }
    
    .canggan-gans {
        justify-content: flex-start;
        gap: 0.4rem;
    }
    
    .canggan-gan {
        flex-direction: row;
        justify-content: center;
        gap: 0.4rem;
        padding: 0.3rem 0.5rem;
        min-width: 55px;
    }
    
    .canggan-gan .gan-text {
        font-size: 0.85rem;
    }
    
    .canggan-gan .strength-text {
        font-size: 0.6rem;
    }
    
    /* Shen Sha mobile */
    .shensha-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .shensha-item {
        padding: 0.75rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
    
    .shensha-name {
        font-size: 0.9rem;
    }
    
    .shensha-values {
        font-size: 0.8rem;
    }
    
    /* DaYun table mobile */
    .dayun-table {
        overflow-x: auto;
        margin: 1rem -0.5rem;
        padding: 0 0.5rem;
    }
    
    .dayun-table-inner {
        font-size: 0.75rem;
        min-width: 600px;
    }
    
    .dayun-table-inner th, 
    .dayun-table-inner td {
        padding: 0.6rem 0.4rem;
    }
    
    /* Section titles mobile */
    .section-title-small {
        font-size: 1rem;
        margin: 1.25rem 0 0.75rem;
    }
    
    /* Form mobile optimization */
    .form-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .form-group label {
        font-size: 0.85rem;
    }
    
    .form-group select {
        padding: 0.85rem;
        font-size: 0.9rem;
    }
    
    .form-actions {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .btn-gold {
        padding: 0.85rem 2rem;
        font-size: 1rem;
    }
    
    .btn-outline {
        padding: 0.85rem 1.5rem;
        font-size: 0.9rem;
    }
    
    /* Tabs mobile */
    .tabs {
        gap: 0.25rem;
        padding: 0.4rem;
    }
    
    .tab-btn {
        min-width: auto;
        padding: 0.75rem 0.5rem;
        font-size: 0.8rem;
    }
    
    /* Lucky info mobile */
    .liuNian-header {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
        padding: 1.25rem;
    }
    
    .liuNian-ganzhi {
        font-size: 2rem;
    }
    
    .liuNian-wuxing {
        font-size: 1.1rem;
    }
    
    .liuNian-relation {
        font-size: 1rem;
    }
    
    .lucky-info-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .lucky-item {
        padding: 1rem;
    }
    
    .lucky-icon {
        font-size: 1.75rem;
    }
    
    .lucky-label {
        font-size: 0.75rem;
    }
    
    .lucky-value {
        font-size: 1rem;
    }
    
    /* Five elements mobile */
    .wuxing-bar-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .wuxing-bar-label {
        min-width: auto;
        width: 100%;
        justify-content: space-between;
        font-size: 0.85rem;
    }
    
    .wuxing-bar-track {
        width: 100%;
        height: 20px;
    }
    
    /* Keywords mobile */
    .keywords-list,
    .keyword-tags {
        gap: 0.5rem;
    }
    
    .keyword-tag {
        padding: 0.4rem 0.8rem;
        font-size: 0.8rem;
    }
    
    /* Monthly fortune mobile */
    .monthly-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .month-item {
        padding: 1rem;
    }
    
    .month-header {
        font-size: 1rem;
    }
    
    .month-summary {
        font-size: 0.9rem;
    }
    
    .month-tips {
        font-size: 0.8rem;
    }
    
    /* Marriage mobile */
    .match-score-card {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem;
    }
    
    .score-circle {
        width: 100px;
        height: 100px;
    }
    
    .score-value {
        font-size: 2rem;
    }
    
    .score-info span {
        font-size: 1.25rem;
    }
    
    .marriage-info-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .gan-tags {
        flex-wrap: wrap;
    }
    
    .gan-tag {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
    }
    
    /* Personality mobile */
    .personality-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding: 1.25rem;
    }
    
    .daymaster-value {
        font-size: 1.5rem;
    }
    
    .description-box {
        padding: 1.25rem;
        font-size: 0.95rem;
    }
    
    .traits-grid-2 {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .trait-card {
        padding: 1rem;
    }
    
    .trait-card h3 {
        font-size: 1rem;
    }
    
    .trait-card li {
        font-size: 0.9rem;
        padding: 0.5rem 0;
    }
    
    /* Career mobile */
    .career-grid {
        grid-template-columns: 1fr;
    }
    
    .career-item {
        padding: 1rem;
    }
    
    .career-analysis {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .analysis-item {
        padding: 1rem;
    }
    
    .wealth-tips {
        padding: 1rem;
    }
    
    /* Modal mobile */
    .modal {
        padding: 1rem;
    }
    
    .modal-content {
        padding: 1.5rem;
        border-radius: 15px;
        max-height: 85vh;
    }
    
    .modal-close {
        top: 0.75rem;
        right: 0.75rem;
        font-size: 1.5rem;
    }
    
    .modal-content h2 {
        font-size: 1.25rem;
    }
}

/* ==========================================
   Page Header for sub-pages
   ========================================== */
.page-header {
    text-align: center;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    margin-bottom: 2rem;
    border-radius: 0 0 30px 30px;
}

.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.page-header p {
    opacity: 0.9;
    font-size: 1.1rem;
}

.page-nav {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.page-nav {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.page-nav-btn {
    padding: 0.75rem 1.5rem;
    background: white;
    color: var(--primary);
    border: none;
    border-radius: 25px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 15px var(--shadow);
    font-family: inherit;
}

.page-nav-btn:hover {
    background: var(--gold);
    color: var(--primary-dark);
    transform: translateY(-2px);
}

.page-nav-btn.active {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    color: var(--primary-dark);
    box-shadow: 0 8px 25px rgba(218, 165, 32, 0.4);
}

/* ==========================================
   Enhanced Zodiac Result Styles
   ========================================== */
.zodiac-result-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    padding: 2rem;
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    border-radius: 20px;
    margin-bottom: 2rem;
    box-shadow: 0 10px 40px rgba(218, 165, 32, 0.3);
}

.zodiac-hero-icon {
    font-size: 6rem;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.zodiac-hero-info {
    text-align: left;
}

.zodiac-hero-name {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.zodiac-hero-year {
    font-size: 1.25rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.zodiac-fortune-level {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: var(--primary);
    color: var(--gold);
    border-radius: 25px;
    font-weight: 600;
    font-size: 1rem;
}

/* Enhanced lucky info with icons */
.lucky-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.lucky-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 20px var(--shadow);
    transition: all 0.3s;
    border: 2px solid transparent;
}

.lucky-item:hover {
    transform: translateY(-5px);
    border-color: var(--gold);
    box-shadow: 0 10px 30px rgba(218, 165, 32, 0.2);
}

.lucky-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.lucky-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.lucky-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
}

/* Enhanced monthly grid */
.monthly-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 1rem 0;
}

.month-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
    border-left: 4px solid var(--gold);
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.month-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--gold), var(--gold-light));
    opacity: 0;
    transition: opacity 0.3s;
}

.month-item:hover::before {
    opacity: 1;
}

.month-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(218, 165, 32, 0.15);
}

.month-header {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.month-header::before {
    content: '📅';
    font-size: 1.25rem;
}

.month-summary {
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.month-tips {
    font-size: 0.9rem;
    color: var(--text-muted);
    padding-left: 1rem;
    border-left: 2px solid var(--border);
}

/* Enhanced description box */
.description-box {
    background: linear-gradient(135deg, #FFF8F0 0%, #FFF5E6 100%);
    padding: 2rem;
    border-radius: 15px;
    margin-bottom: 2rem;
    font-size: 1.1rem;
    line-height: 2;
    border-left: 4px solid var(--gold);
}

/* Enhanced keywords */
.keywords-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.keyword-tag {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    color: var(--primary-dark);
    padding: 0.6rem 1.2rem;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s;
    cursor: default;
}

.keyword-tag:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(218, 165, 32, 0.3);
}

/* Enhanced tabs */
.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    background: white;
    padding: 0.5rem;
    border-radius: 15px;
    margin-bottom: 2rem;
    box-shadow: 0 5px 20px var(--shadow);
}

.tab-btn {
    flex: 1;
    min-width: 120px;
    padding: 1rem;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    border-radius: 10px;
    transition: all 0.3s;
    position: relative;
}

.tab-btn:hover {
    background: var(--bg-light);
    color: var(--primary);
}

.tab-btn.active {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(139, 69, 19, 0.3);
}

/* Enhanced traits grid */
.traits-grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.trait-card {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
    transition: all 0.3s;
}

.trait-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(218, 165, 32, 0.15);
}

.trait-card h3 {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary);
}

.trait-card ul {
    list-style: none;
}

.trait-card li {
    padding: 0.75rem 0;
    border-bottom: 1px dashed var(--border);
    padding-left: 1.5rem;
    position: relative;
}

.trait-card li::before {
    content: '✦';
    position: absolute;
    left: 0;
    color: var(--gold);
}

.trait-card li:last-child {
    border-bottom: none;
}

/* ==========================================
   Enhanced Match Page Styles
   ========================================== */
.match-profile-section {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.match-profile-card {
    background: linear-gradient(135deg, #FFF8F0 0%, #FFF5E6 100%);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    min-width: 250px;
    box-shadow: 0 10px 30px var(--shadow);
    transition: all 0.3s;
}

.match-profile-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(218, 165, 32, 0.2);
}

.match-profile-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.match-profile-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.match-profile-gan {
    font-size: 3rem;
    font-weight: 700;
    color: var(--gold);
    margin: 1rem 0;
}

.match-profile-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Enhanced score display */
.match-score-card {
    display: flex;
    align-items: center;
    gap: 2rem;
    background: linear-gradient(135deg, var(--red) 0%, #8B0000 100%);
    padding: 2.5rem;
    border-radius: 20px;
    margin-bottom: 2rem;
    box-shadow: 0 10px 40px rgba(196, 30, 58, 0.3);
    position: relative;
    overflow: hidden;
}

.match-score-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
}

.score-circle {
    width: 140px;
    height: 140px;
    background: white;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    position: relative;
    z-index: 1;
}

.score-value {
    font-size: 3rem;
    font-weight: 700;
    color: var(--red);
    line-height: 1;
}

.score-label {
    font-size: 1rem;
    color: var(--text-muted);
}

.score-info {
    color: white;
    position: relative;
    z-index: 1;
}

.score-info span {
    font-size: 1.75rem;
    font-weight: 700;
}

.score-info p {
    margin-top: 0.75rem;
    opacity: 0.95;
    line-height: 1.6;
}

/* Enhanced marriage items */
.marriage-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.marriage-item {
    background: linear-gradient(135deg, #FFF8F0 0%, #FFF5E6 100%);
    padding: 1.5rem;
    border-radius: 15px;
    border-left: 4px solid var(--gold);
    transition: all 0.3s;
}

.marriage-item:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 20px rgba(218, 165, 32, 0.15);
}

.marriage-item h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Enhanced marriage notes */
.marriage-notes {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
    margin-top: 2rem;
}

.marriage-notes h3 {
    color: var(--primary);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.marriage-notes ul {
    list-style: none;
}

.marriage-notes li {
    padding: 0.75rem 0;
    border-bottom: 1px dashed var(--border);
    padding-left: 2rem;
    position: relative;
    line-height: 1.6;
}

.marriage-notes li:last-child {
    border-bottom: none;
}

.marriage-notes li::before {
    content: '💡';
    position: absolute;
    left: 0;
    font-size: 1.1rem;
}

/* Enhanced analysis items */
.career-analysis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.analysis-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
    transition: all 0.3s;
}

.analysis-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(218, 165, 32, 0.15);
}

.analysis-item h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* ==========================================
   Enhanced Birthday Page Styles
   ========================================== */
.birthday-hero-section {
    text-align: center;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    border-radius: 25px;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.birthday-hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%238B4513' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.birthday-date-display {
    position: relative;
    z-index: 1;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

.birthday-zodiac-info {
    position: relative;
    z-index: 1;
    font-size: 1.25rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.birthday-lifepath-hero {
    position: relative;
    z-index: 1;
    display: inline-block;
}

.life-path-number {
    font-size: 6rem;
    font-weight: 700;
    color: var(--primary-dark);
    line-height: 1;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.life-path-label {
    font-size: 1.5rem;
    color: var(--primary);
    margin-top: 0.5rem;
}

/* Enhanced personality header */
.personality-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 1.5rem 2rem;
    border-radius: 15px;
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px rgba(139, 69, 19, 0.2);
}

.daymaster-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.daymaster-label {
    color: var(--primary-light);
    font-size: 1rem;
}

.daymaster-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gold);
}

.strength-badge {
    background: var(--gold);
    color: var(--primary-dark);
    padding: 0.6rem 1.2rem;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.95rem;
}

/* Enhanced lucky items for birthday */
.birthday-lucky-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.birthday-lucky-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 20px var(--shadow);
    transition: all 0.3s;
    border-top: 4px solid var(--gold);
}

.birthday-lucky-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(218, 165, 32, 0.2);
}

.birthday-lucky-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.birthday-lucky-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.birthday-lucky-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary);
}

/* Enhanced mission section */
.mission-section {
    background: linear-gradient(135deg, #FFF8F0 0%, #FFF5E6 100%);
    padding: 2rem;
    border-radius: 15px;
    margin: 2rem 0;
    border-left: 4px solid var(--gold);
}

.mission-section h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.mission-section p {
    line-height: 1.8;
    color: var(--text-dark);
}

/* Enhanced destiny section */
.destiny-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.destiny-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px var(--shadow);
    transition: all 0.3s;
}

.destiny-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(218, 165, 32, 0.15);
}

.destiny-item h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.destiny-item h3::before {
    content: '🎯';
}

/* Responsive adjustments - merged with main responsive styles above */
@media (max-width: 768px) {
    .zodiac-result-header {
        flex-direction: column;
        text-align: center;
    }
    
    .zodiac-hero-info {
        text-align: center;
    }
    
    .zodiac-hero-name {
        font-size: 2rem;
    }
    
    .match-profile-section {
        flex-direction: column;
        align-items: center;
    }
    
    .birthday-hero-section {
        padding: 2rem 1rem;
    }
    
    .birthday-date-display {
        font-size: 1.75rem;
    }
    
    .life-path-number {
        font-size: 4rem;
    }
}

/* ==========================================
   English Version Additional Styles
   ========================================== */

/* Fortune overview styles */
.fortune-overview {
    background: linear-gradient(135deg, #FFF8F0 0%, #FFF5E6 100%);
    padding: 2rem;
    border-radius: 15px;
    margin-bottom: 2rem;
    display: flex;
    gap: 2rem;
    align-items: center;
}

.fortune-score {
    text-align: center;
    flex-shrink: 0;
}

.fortune-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.fortune-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.fortune-icon {
    font-size: 1.5rem;
    width: 2rem;
    text-align: center;
}

.fortune-label {
    width: 80px;
    font-weight: 600;
    color: var(--text-dark);
}

.fortune-bar {
    flex: 1;
    height: 12px;
    background: white;
    border-radius: 6px;
    overflow: hidden;
}

.fortune-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gold) 0%, var(--gold-light) 100%);
    border-radius: 6px;
    transition: width 0.5s ease;
}

/* Compatibility grid styles */
.compatibility-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.compat-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 20px var(--shadow);
    transition: all 0.3s;
}

.compat-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(218, 165, 32, 0.15);
}

.compat-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}

.compat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.compat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.compat-bar {
    height: 8px;
    background: var(--bg-light);
    border-radius: 4px;
    overflow: hidden;
}

.compat-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gold) 0%, var(--gold-light) 100%);
    border-radius: 4px;
    transition: width 0.5s ease;
}

/* Analysis section styles */
.analysis-section {
    margin-top: 2rem;
}

.analysis-section h3 {
    color: var(--primary);
    margin: 1.5rem 0 1rem;
    font-size: 1.25rem;
}

.analysis-text {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    line-height: 1.8;
    box-shadow: 0 3px 10px var(--shadow);
}

.analysis-text p {
    margin: 0;
}

/* Strengths and challenges styles */
.strengths-list, .challenges-list, .advice-list {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 3px 10px var(--shadow);
}

.strength-item, .challenge-item, .advice-item {
    padding: 0.75rem 0;
    border-bottom: 1px dashed var(--border);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.strength-item:last-child, .challenge-item:last-child, .advice-item:last-child {
    border-bottom: none;
}

.strength-item::before {
    content: '✓';
    color: #4CAF50;
    font-weight: bold;
}

.challenge-item::before {
    content: '⚠';
    color: #FF9800;
}

.advice-item::before {
    content: '•';
    color: var(--gold);
    font-weight: bold;
}

/* Life path display styles */
.life-path-display {
    text-align: center;
    padding: 2rem;
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    border-radius: 20px;
    margin-bottom: 2rem;
}

.birthday-summary {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    line-height: 1.8;
    box-shadow: 0 3px 10px var(--shadow);
}

.traits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.talents-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.talent-item {
    background: linear-gradient(135deg, #FFF8F0 0%, #FFF5E6 100%);
    padding: 1rem;
    border-radius: 10px;
    text-align: center;
    font-weight: 600;
    transition: all 0.3s;
}

.talent-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(218, 165, 32, 0.2);
}

.love-compat, .destiny-text {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    line-height: 1.8;
    box-shadow: 0 3px 10px var(--shadow);
}

/* Match score display styles */
.match-score-display {
    display: flex;
    align-items: center;
    gap: 2rem;
    background: linear-gradient(135deg, var(--red) 0%, #8B0000 100%);
    padding: 2rem;
    border-radius: 15px;
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px rgba(196, 30, 58, 0.3);
}

.match-circle {
    width: 100px;
    height: 100px;
    background: white;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.match-score-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--red);
}

.match-score-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.match-level-badge {
    background: var(--gold);
    color: var(--primary-dark);
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    font-size: 1.1rem;
}

/* Additional English responsive styles */
@media (max-width: 768px) {
    .fortune-overview {
        flex-direction: column;
    }
    
    .fortune-details {
        width: 100%;
    }
    
    .match-score-display {
        flex-direction: column;
        text-align: center;
    }
    
    .compatibility-grid {
        grid-template-columns: 1fr;
    }
}