/* 八字合婚专用样式 */

/* 人员信息块 */
.person-block {
    margin-bottom: 18px;
    padding: 14px;
    border-radius: 12px;
    background: rgba(255, 252, 245, 0.6);
    border: 1px solid var(--line);
}
.person-block:last-of-type {
    margin-bottom: 0;
}
.person-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--line);
}
.person-header.male { color: #1e6091; }
.person-header.female { color: #8d2824; }
.person-icon {
    font-size: 20px;
    font-weight: 700;
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.05);
}
.person-header.male .person-icon { background: rgba(30, 96, 145, 0.1); }
.person-header.female .person-icon { background: rgba(141, 40, 36, 0.1); }
.person-label { font-size: 16px; font-weight: 700; }

/* 表单 */
.form-row {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(120px, 1fr);
    gap: 10px;
}
.form-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.form-item label {
    font-size: 12px;
    color: var(--muted);
    font-weight: 600;
}
.form-item input, .form-item select {
    height: 40px;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 252, 245, 0.9);
    color: var(--ink);
    font-size: 14px;
    font-family: inherit;
}
.form-item input:focus, .form-item select:focus {
    outline: none;
    border-color: var(--red);
    box-shadow: 0 0 0 3px rgba(141, 40, 36, 0.08);
}

/* 合婚评分卡片 */
.match-score-card {
    display: flex;
    align-items: center;
    gap: 20px;
    background: linear-gradient(135deg, rgba(255,252,245,.95), rgba(245,239,226,.95));
}
.match-score-circle {
    flex: 0 0 auto;
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: linear-gradient(135deg, #c9a227, #8b6914);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: 0 8px 24px rgba(139,105,20,.35);
    position: relative;
}
.match-score-circle::before {
    content: '';
    position: absolute;
    inset: 5px;
    border-radius: 50%;
    border: 2px solid rgba(255,248,235,.35);
}
.match-score-number {
    font-size: 38px;
    font-weight: 800;
    color: #fff8eb;
    line-height: 1;
    font-family: Arial, sans-serif;
}
.match-score-label {
    font-size: 11px;
    color: rgba(255,248,235,.9);
    letter-spacing: .15em;
    margin-top: 4px;
}
.match-score-info { flex: 1; }
.match-score-level {
    font-size: 22px;
    font-weight: 700;
    color: var(--red);
    margin-bottom: 8px;
    letter-spacing: .08em;
}
.match-score-desc {
    font-size: 13px;
    line-height: 1.8;
    color: var(--ink);
}

/* 八字总览 */
.bazi-compare {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 12px;
    align-items: center;
}
.bazi-person {
    text-align: center;
    padding: 12px;
    border-radius: 10px;
    background: rgba(255,252,245,.7);
    border: 1px solid var(--line);
}
.bazi-person.male { border-color: rgba(30,96,145,.3); }
.bazi-person.female { border-color: rgba(141,40,36,.3); }
.bazi-person-title {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 8px;
}
.bazi-person.male .bazi-person-title { color: #1e6091; }
.bazi-person.female .bazi-person-title { color: #8d2824; }
.bazi-pillars {
    display: flex;
    justify-content: center;
    gap: 6px;
}
.bazi-pillar {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 6px 8px;
    border-radius: 6px;
    background: rgba(0,0,0,.03);
}
.bazi-pillar-label {
    font-size: 10px;
    color: var(--muted);
    margin-bottom: 2px;
}
.bazi-pillar-gan {
    font-size: 16px;
    font-weight: 700;
    color: var(--ink);
}
.bazi-pillar-zhi {
    font-size: 16px;
    font-weight: 700;
    color: var(--red);
}
.bazi-vs {
    font-size: 20px;
    font-weight: 800;
    color: var(--gold);
}
.bazi-person-meta {
    font-size: 11px;
    color: var(--muted);
    margin-top: 8px;
    line-height: 1.6;
}

/* 五维评分 */
.dimension-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.dimension-item {
    display: flex;
    align-items: center;
    gap: 12px;
}
.dimension-name {
    flex: 0 0 80px;
    font-size: 14px;
    font-weight: 700;
    color: var(--ink);
}
.dimension-bar-wrap {
    flex: 1;
    height: 22px;
    background: rgba(0,0,0,.05);
    border-radius: 11px;
    overflow: hidden;
}
.dimension-bar {
    height: 100%;
    border-radius: 11px;
    transition: width .8s ease;
}
.dimension-score {
    flex: 0 0 40px;
    text-align: right;
    font-size: 16px;
    font-weight: 800;
    font-family: Arial, sans-serif;
}

/* 配对详情 */
.match-detail {
    padding: 14px;
    border-radius: 10px;
    background: rgba(255,252,245,.6);
    border: 1px solid var(--line);
    margin-bottom: 12px;
}
.match-detail:last-child { margin-bottom: 0; }
.match-detail-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.match-detail-tag {
    padding: 2px 10px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 600;
}
.match-detail-tag.good { background: rgba(45,106,79,.1); color: var(--green); }
.match-detail-tag.bad { background: rgba(141,40,36,.08); color: var(--red); }
.match-detail-tag.normal { background: rgba(184,134,11,.1); color: var(--gold); }
.match-detail-text {
    font-size: 13px;
    line-height: 1.8;
    color: var(--ink);
}

/* 五行对比 */
.element-compare {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 14px;
}
.element-row {
    display: grid;
    grid-template-columns: 40px 1fr 40px 1fr 40px;
    align-items: center;
    gap: 8px;
}
.element-name {
    font-size: 14px;
    font-weight: 700;
    text-align: center;
}
.element-bar {
    height: 16px;
    border-radius: 8px;
    transition: width .5s;
}
.element-count {
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    color: var(--ink);
}
.element-complement {
    padding: 12px;
    border-radius: 8px;
    background: rgba(45,106,79,.06);
    border: 1px solid rgba(45,106,79,.15);
    font-size: 13px;
    line-height: 1.8;
    color: var(--ink);
    margin-bottom: 10px;
}
.element-yong {
    padding: 12px;
    border-radius: 8px;
    background: rgba(184,134,11,.06);
    border: 1px solid rgba(184,134,11,.15);
    font-size: 13px;
    line-height: 1.8;
    color: var(--ink);
}

/* 生肖配对 */
.zodiac-display {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 14px;
    padding: 16px;
    border-radius: 12px;
    background: rgba(255,252,245,.6);
}
.zodiac-item { text-align: center; }
.zodiac-emoji {
    font-size: 40px;
    margin-bottom: 4px;
}
.zodiac-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--ink);
}
.zodiac-branch {
    font-size: 12px;
    color: var(--muted);
}
.zodiac-relation-icon {
    font-size: 24px;
    color: var(--gold);
}

/* 配偶星宫 */
.spouse-section { margin-bottom: 14px; }
.spouse-section:last-child { margin-bottom: 0; }
.spouse-section-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--line);
}
.spouse-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}
.spouse-tag {
    padding: 4px 12px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
    background: rgba(141,40,36,.08);
    color: var(--red);
}
.spouse-tag.bad { background: rgba(141,40,36,.1); color: var(--red); }
.spouse-tag.good { background: rgba(45,106,79,.1); color: var(--green); }
.spouse-desc {
    font-size: 12px;
    line-height: 1.7;
    color: var(--muted);
}

/* 响应式 */
@media (max-width: 480px) {
    .form-row { grid-template-columns: minmax(0, 3fr) minmax(112px, 2fr); }
    .bazi-compare { grid-template-columns: 1fr; }
    .bazi-vs { text-align: center; }
    .element-row { grid-template-columns: 30px 1fr 30px 1fr 30px; gap: 4px; }
}
