/* ========================================
   紫微斗数增强样式 - 环形十二宫布局
   ======================================== */

.ziwei-circle-chart {
    position: relative;
    width: 600px;
    height: 600px;
    margin: 40px auto;
    background: radial-gradient(circle, rgba(255,248,240,0.3) 0%, rgba(255,248,240,0.8) 100%);
    border-radius: 50%;
    box-shadow: 0 10px 40px rgba(139, 69, 19, 0.15);
}

.center-info {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    background: linear-gradient(135deg, #fff8f0 0%, #ffe4d0 100%);
    padding: 30px;
    border-radius: 50%;
    width: 180px;
    height: 180px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    box-shadow: 0 5px 20px rgba(139, 69, 19, 0.2);
    border: 3px solid #d4af37;
}

.center-info h4 {
    font-size: 20px;
    color: #8b4513;
    margin: 0 0 10px 0;
    font-weight: 600;
}

.center-info p {
    font-size: 14px;
    color: #666;
    margin: 5px 0;
}

.palaces-ring {
    position: relative;
    width: 100%;
    height: 100%;
}

.palace-item {
    position: absolute;
    width: 140px;
    height: 100px;
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid #d4af37;
    border-radius: 8px;
    padding: 8px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.palace-item:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 20px rgba(212, 175, 55, 0.3);
    z-index: 10;
}

.palace-item.ming-gong {
    background: linear-gradient(135deg, #fff8dc 0%, #ffd700 100%);
    border-color: #ff6b6b;
    border-width: 3px;
}

.palace-item.shen-gong {
    background: linear-gradient(135deg, #e6f3ff 0%, #b3d9ff 100%);
    border-color: #4a90e2;
    border-width: 3px;
}

/* 十二宫位置（环形排列） */
.palace-item[data-position="4"] { top: 10px; left: 230px; } /* 巳 */
.palace-item[data-position="5"] { top: 10px; right: 230px; } /* 午 */
.palace-item[data-position="6"] { top: 60px; right: 100px; } /* 未 */
.palace-item[data-position="7"] { top: 150px; right: 20px; } /* 申 */
.palace-item[data-position="8"] { top: 280px; right: 20px; } /* 酉 */
.palace-item[data-position="9"] { bottom: 60px; right: 100px; } /* 戌 */
.palace-item[data-position="10"] { bottom: 10px; right: 230px; } /* 亥 */
.palace-item[data-position="11"] { bottom: 10px; left: 230px; } /* 子 */
.palace-item[data-position="0"] { bottom: 60px; left: 100px; } /* 丑 */
.palace-item[data-position="1"] { top: 280px; left: 20px; } /* 寅 */
.palace-item[data-position="2"] { top: 150px; left: 20px; } /* 卯 */
.palace-item[data-position="3"] { top: 60px; left: 100px; } /* 辰 */

.palace-name {
    font-size: 14px;
    font-weight: 600;
    color: #8b4513;
    margin-bottom: 3px;
}

.palace-zhi {
    font-size: 12px;
    color: #999;
    margin-bottom: 5px;
}

.palace-stars {
    font-size: 11px;
    line-height: 1.4;
}

.main-star {
    display: inline-block;
    padding: 2px 5px;
    margin: 2px;
    border-radius: 3px;
    font-weight: 600;
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
    color: white;
}

.main-star.庙 {
    background: linear-gradient(135deg, #ff0000 0%, #cc0000 100%);
}

.main-star.旺 {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
}

.main-star.平 {
    background: linear-gradient(135deg, #ffa500 0%, #ff8c00 100%);
}

.main-star.陷 {
    background: linear-gradient(135deg, #999 0%, #666 100%);
}

.aux-star {
    display: inline-block;
    padding: 1px 4px;
    margin: 1px;
    font-size: 10px;
    color: #4a90e2;
    border: 1px solid #4a90e2;
    border-radius: 2px;
}

.main-star sup, .aux-star sup {
    font-size: 9px;
    font-weight: bold;
    margin-left: 2px;
}

.sihua-legend {
    text-align: center;
    margin-top: 20px;
    padding: 15px;
    background: rgba(255, 248, 240, 0.5);
    border-radius: 8px;
}

.sihua-legend span {
    margin: 0 15px;
    font-size: 14px;
}

.sihua-legend .lu { color: #ff0000; font-weight: 600; }
.sihua-legend .quan { color: #ff6b00; font-weight: 600; }
.sihua-legend .ke { color: #0066cc; font-weight: 600; }
.sihua-legend .ji { color: #666; font-weight: 600; }

/* 命书解读样式 */
.mingshu-section {
    background: linear-gradient(135deg, #fff8f0 0%, #ffe4d0 100%);
    padding: 25px;
    border-radius: 12px;
    margin: 20px 0;
    border-left: 5px solid #d4af37;
}

.classic-quote {
    background: white;
    padding: 20px;
    border-radius: 8px;
    margin-top: 15px;
}

.classic-quote .source {
    font-size: 13px;
    color: #8b4513;
    font-weight: 600;
    margin-bottom: 10px;
}

.classic-quote .original {
    font-size: 16px;
    color: #333;
    font-style: italic;
    line-height: 1.8;
    padding: 15px;
    background: #fafafa;
    border-left: 3px solid #d4af37;
    margin: 10px 0;
}

.classic-quote .interpretation {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}

.modern-section {
    background: white;
    padding: 25px;
    border-radius: 12px;
    margin: 20px 0;
    border-left: 5px solid #4a90e2;
}

.modern-section h4 {
    color: #4a90e2;
    margin-bottom: 15px;
}

.modern-section p {
    line-height: 1.8;
    margin: 12px 0;
}

/* 双盘融合样式 */
.fusion-analysis {
    background: linear-gradient(135deg, #f0f8ff 0%, #e6f3ff 100%);
    padding: 30px;
    border-radius: 15px;
    margin: 20px 0;
}

.ai-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: 600;
    margin-bottom: 20px;
}

.year-section {
    background: white;
    padding: 25px;
    border-radius: 12px;
    margin: 20px 0;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.1);
}

.year-section h3 {
    color: #8b4513;
    border-bottom: 2px solid #d4af37;
    padding-bottom: 10px;
    margin-bottom: 15px;
}

.liunian-minggong {
    color: #666;
    margin-bottom: 20px;
    font-size: 14px;
}

.dimension-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-top: 15px;
}

.dimension-item {
    background: #fafafa;
    padding: 15px;
    border-radius: 8px;
    border-left: 3px solid #4a90e2;
}

.dimension-item h4 {
    color: #4a90e2;
    font-size: 15px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.dimension-item p {
    font-size: 14px;
    line-height: 1.6;
    color: #666;
}

/* 响应式适配 */
@media (max-width: 768px) {
    .ziwei-circle-chart {
        width: 100%;
        max-width: 400px;
        height: 400px;
    }
    
    .palace-item {
        width: 90px;
        height: 70px;
        padding: 5px;
        font-size: 10px;
    }
    
    .center-info {
        width: 120px;
        height: 120px;
        padding: 15px;
    }
    
    .dimension-grid {
        grid-template-columns: 1fr;
    }
}
