/* ========== 全局基础 ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-primary: #0a0a1a;
    --bg-secondary: #12122a;
    --bg-card: rgba(255, 255, 255, 0.05);
    --bg-card-hover: rgba(255, 255, 255, 0.08);
    --border-color: rgba(255, 255, 255, 0.1);
    --text-primary: #e8e8f0;
    --text-secondary: #a0a0b8;
    --text-muted: #6a6a82;
    --accent-gold: #d4a853;
    --accent-red: #e85d5d;
    --accent-blue: #5b9bd5;
    --accent-green: #5dbe7e;
    --accent-purple: #9b7ed8;
    --accent-cyan: #5dc9be;
    --gradient-hero: linear-gradient(135deg, #1a1a3e 0%, #0d0d2b 50%, #1a1a3e 100%);
    --gradient-card: linear-gradient(135deg, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0.02) 100%);
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.3);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --font-mono: 'SF Mono', 'Cascadia Code', 'Consolas', monospace;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(ellipse at 20% 20%, rgba(212, 168, 83, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 60%, rgba(91, 155, 213, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 80%, rgba(155, 126, 216, 0.04) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* ========== 模态框选择器 ========== */
.modal-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s;
}

.modal-trigger:hover {
    border-color: var(--accent-gold);
    background: rgba(212, 168, 83, 0.06);
}

.modal-trigger-text {
    font-size: 14px;
    color: var(--text-primary);
}

.modal-trigger-text:empty,
.modal-trigger-text[data-placeholder] {
    color: var(--text-muted);
}

.modal-trigger-arrow {
    font-size: 20px;
    color: var(--text-muted);
}

/* 模态框背景 */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 300;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    animation: modalFadeIn 0.2s ease;
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-container {
    width: 100%;
    max-width: 480px;
    max-height: 80vh;
    background: #1a1a36;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    display: flex;
    flex-direction: column;
    animation: modalSlideUp 0.3s ease;
}

@keyframes modalSlideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px 20px 12px;
    position: relative;
}

.modal-header h3 {
    font-size: 17px;
    font-weight: 600;
    color: var(--text-primary);
}

.modal-close {
    position: absolute;
    right: 16px;
    top: 16px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-secondary);
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.modal-search {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 16px 12px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
}

.modal-search-icon {
    font-size: 16px;
    flex-shrink: 0;
}

.modal-search-input {
    flex: 1;
    background: none;
    border: none;
    outline: none;
    color: var(--text-primary);
    font-size: 15px;
    font-family: inherit;
}

.modal-search-input::placeholder {
    color: var(--text-muted);
}

.modal-list {
    flex: 1;
    overflow-y: auto;
    padding: 0 16px 20px;
    -webkit-overflow-scrolling: touch;
}

.modal-list::-webkit-scrollbar {
    width: 3px;
}

.modal-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

.modal-section-title {
    font-size: 12px;
    color: var(--accent-gold);
    font-weight: 600;
    padding: 10px 4px 6px;
    letter-spacing: 1px;
}

.modal-item {
    padding: 12px 14px;
    margin-bottom: 2px;
    border-radius: var(--radius-sm);
    font-size: 15px;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.15s;
}

.modal-item:hover {
    background: rgba(212, 168, 83, 0.1);
    color: var(--accent-gold);
}

.modal-item:active {
    background: rgba(212, 168, 83, 0.15);
}

.modal-empty {
    padding: 30px 14px;
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
}

/* ========== Header ========== */
.app-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(10, 10, 26, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
}

.header-inner {
    max-width: 480px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
}

.header-title {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 2px;
    background: linear-gradient(135deg, var(--accent-gold), #f0d78c);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-icon {
    font-size: 18px;
    opacity: 0.4;
    cursor: pointer;
    transition: opacity 0.2s;
}

.header-icon:hover {
    opacity: 0.8;
}

/* ========== Main ========== */
.app-main {
    max-width: 480px;
    margin: 0 auto;
    padding: 20px 16px 80px;
    position: relative;
    z-index: 1;
}

/* ========== Toast ========== */
.toast {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border-radius: var(--radius-md);
    margin-bottom: 20px;
    font-size: 14px;
}

.toast-error {
    background: rgba(232, 93, 93, 0.15);
    border: 1px solid rgba(232, 93, 93, 0.3);
    color: #f5a0a0;
}

.toast-icon {
    font-size: 18px;
    flex-shrink: 0;
}

/* ========== Form Page ========== */
.form-hero {
    text-align: center;
    padding: 30px 0 20px;
}

.hero-icon {
    font-size: 48px;
    margin-bottom: 12px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.form-hero h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
    background: linear-gradient(135deg, var(--accent-gold), #f0d78c);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.form-hero p {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* ========== Form Sections ========== */
.form-section {
    margin-bottom: 20px;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
    padding-left: 2px;
}

.section-title.collapsible {
    cursor: pointer;
    user-select: none;
}

.section-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-gold);
    flex-shrink: 0;
}

.collapse-arrow {
    margin-left: auto;
    font-size: 12px;
    color: var(--text-muted);
    transition: transform 0.3s;
}

.collapse-arrow.open {
    transform: rotate(180deg);
}

.form-group {
    margin-bottom: 12px;
}

.form-label {
    display: block;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.form-input {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 15px;
    outline: none;
    transition: all 0.2s;
    font-family: inherit;
}

.form-input:focus {
    border-color: var(--accent-gold);
    background: rgba(212, 168, 83, 0.06);
    box-shadow: 0 0 0 3px rgba(212, 168, 83, 0.1);
}

.form-input::placeholder {
    color: var(--text-muted);
}

select.form-input {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%236a6a82' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

/* Radio Group */
.radio-group {
    display: flex;
    gap: 8px;
}

.radio-item {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s;
    font-size: 14px;
}

.radio-item:hover {
    background: var(--bg-card-hover);
}

.radio-item.active {
    border-color: var(--accent-gold);
    background: rgba(212, 168, 83, 0.1);
}

.radio-item input[type="radio"] {
    display: none;
}

.radio-label {
    color: var(--text-secondary);
}

.radio-item.active .radio-label {
    color: var(--accent-gold);
}

/* Form Row */
.form-row {
    display: flex;
    gap: 10px;
}

.form-row .form-group {
    flex: 1;
}

.form-row-2 .form-group {
    flex: 1;
}

.form-row-3 .form-group {
    flex: 1;
}

/* Advanced Settings */
.advanced-settings {
    padding-top: 8px;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Submit Button */
.btn-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 16px;
    margin-top: 24px;
    background: linear-gradient(135deg, var(--accent-gold), #c49740);
    border: none;
    border-radius: var(--radius-lg);
    color: #1a1a2e;
    font-size: 17px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 20px rgba(212, 168, 83, 0.3);
    letter-spacing: 2px;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 28px rgba(212, 168, 83, 0.4);
}

.btn-submit:active {
    transform: translateY(0);
}

.btn-submit.loading {
    pointer-events: none;
    opacity: 0.7;
}

.btn-icon {
    font-size: 20px;
}

/* ========== Result Cards ========== */
.result-card {
    background: var(--gradient-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 16px;
    backdrop-filter: blur(10px);
}

.card-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ========== Profile Card ========== */
.profile-card {
    padding: 0;
    overflow: hidden;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 20px;
    background: linear-gradient(135deg, rgba(212, 168, 83, 0.1), rgba(212, 168, 83, 0.03));
}

.profile-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-gold), #c49740);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #1a1a2e;
    flex-shrink: 0;
}

.profile-info h2 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 2px;
}

.profile-sub {
    font-size: 13px;
    color: var(--text-secondary);
}

.profile-badge {
    margin-left: auto;
    padding: 4px 12px;
    background: rgba(212, 168, 83, 0.15);
    border: 1px solid rgba(212, 168, 83, 0.3);
    border-radius: 20px;
    font-size: 12px;
    color: var(--accent-gold);
    white-space: nowrap;
}

.profile-detail {
    padding: 16px 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.detail-row {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.detail-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-value {
    font-size: 13px;
    color: var(--text-primary);
    font-family: var(--font-mono);
}

.profile-tags {
    padding: 0 20px 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
}

.tag-primary {
    background: rgba(91, 155, 213, 0.1);
    border: 1px solid rgba(91, 155, 213, 0.25);
    color: var(--accent-blue);
}

.tag-gold {
    background: rgba(212, 168, 83, 0.1);
    border: 1px solid rgba(212, 168, 83, 0.25);
    color: var(--accent-gold);
}

/* ========== Tab Navigation ========== */
.tab-nav {
    display: flex;
    gap: 4px;
    margin-bottom: 16px;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.tab-nav::-webkit-scrollbar {
    display: none;
}

.tab-btn {
    flex: 1;
    min-width: fit-content;
    padding: 10px 12px;
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    font-family: inherit;
}

.tab-btn.active {
    background: rgba(212, 168, 83, 0.15);
    color: var(--accent-gold);
    font-weight: 600;
}

.tab-btn:hover:not(.active) {
    background: var(--bg-card-hover);
    color: var(--text-primary);
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== 四柱八字 ========== */
.sizhu-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.sizhu-item {
    text-align: center;
    padding: 14px 8px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.sizhu-label {
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.sizhu-tg {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.tg-god {
    font-size: 10px;
    font-weight: 400;
    color: var(--accent-gold);
}

.sizhu-dz {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 4px 0;
}

.sizhu-cg {
    font-size: 10px;
    color: var(--accent-blue);
    margin-top: 4px;
}

.sizhu-cg-god {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 2px;
}

.sizhu-cs {
    font-size: 10px;
    color: var(--text-secondary);
    margin-top: 6px;
}

.sizhu-nayin,
.sizhu-wx,
.sizhu-kw {
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 2px;
}

.sizhu-shensha {
    font-size: 10px;
    color: var(--accent-purple);
    margin-top: 4px;
    line-height: 1.4;
}

/* Info Grid */
.info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.info-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-label {
    font-size: 11px;
    color: var(--text-muted);
}

.info-value {
    font-size: 13px;
    color: var(--text-primary);
}

/* ========== 五行分析 ========== */
.xiyong-banner {
    background: rgba(212, 168, 83, 0.06);
    border: 1px solid rgba(212, 168, 83, 0.15);
    border-radius: var(--radius-sm);
    padding: 16px;
}

.xiyong-main {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin-bottom: 12px;
}

.xiyong-qiangruo {
    padding: 2px 10px;
    background: rgba(232, 93, 93, 0.15);
    border-radius: 12px;
    font-size: 13px;
    color: var(--accent-red);
    font-weight: 600;
}

.xiyong-shen {
    font-size: 14px;
    color: var(--text-primary);
}

.xiyong-shen strong {
    color: var(--accent-green);
}

.xiyong-ji {
    font-size: 14px;
    color: var(--text-primary);
}

.xiyong-ji strong {
    color: var(--accent-red);
}

.xiyong-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 10px;
}

.xiyong-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    font-size: 12px;
    color: var(--text-muted);
}

/* 五行能量条 */
.wuxing-bars {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
}

.wx-bar-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.wx-name {
    width: 20px;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    flex-shrink: 0;
}

.wx-bar-track {
    flex: 1;
    height: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    overflow: hidden;
}

.wx-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.6s ease;
    min-width: 2px;
}

.wx-value {
    font-size: 11px;
    color: var(--text-secondary);
    white-space: nowrap;
    min-width: 70px;
    text-align: right;
}

.wx-percent {
    font-size: 11px;
    color: var(--text-muted);
    min-width: 45px;
}

.wuxing-extra {
    border-top: 1px solid var(--border-color);
    padding-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.wx-info-row {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
}

.wx-info-row span:first-child {
    color: var(--text-muted);
}

.wx-info-row span:last-child {
    color: var(--text-primary);
}

.wuxing-desc-block {
    text-align: center;
}

.wx-desc-tag {
    display: inline-block;
    padding: 4px 16px;
    background: rgba(212, 168, 83, 0.1);
    border: 1px solid rgba(212, 168, 83, 0.25);
    border-radius: 20px;
    font-size: 14px;
    color: var(--accent-gold);
    margin-bottom: 12px;
}

.wx-desc-text {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* ========== 大运流年 ========== */
.dayun-timeline {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dayun-item {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.2s;
}

.dayun-item:hover {
    border-color: rgba(212, 168, 83, 0.3);
}

.dayun-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    cursor: pointer;
    user-select: none;
}

.dayun-age {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 48px;
}

.dayun-age-num {
    font-size: 16px;
    font-weight: 700;
    color: var(--accent-gold);
}

.dayun-age-label {
    font-size: 10px;
    color: var(--text-muted);
}

.dayun-core {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.dayun-ganzhi {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
}

.dayun-shishen {
    font-size: 11px;
    color: var(--accent-gold);
}

.dayun-meta {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 11px;
    color: var(--text-muted);
}

.dayun-arrow {
    font-size: 12px;
    color: var(--text-muted);
    transition: transform 0.3s;
    flex-shrink: 0;
}

.dayun-arrow.open {
    transform: rotate(90deg);
}

.dayun-detail {
    border-top: 1px solid var(--border-color);
    padding: 16px;
    animation: slideDown 0.3s ease;
}

.dy-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 12px;
}

.dy-info-grid div {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    padding: 6px 10px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 6px;
}

.dy-info-grid div span:first-child {
    color: var(--text-muted);
}

.dy-info-grid div span:last-child {
    color: var(--text-primary);
}

.dy-shensha {
    font-size: 12px;
    color: var(--accent-purple);
    margin-bottom: 8px;
    padding: 8px 10px;
    background: rgba(155, 126, 216, 0.08);
    border-radius: 6px;
}

.dy-tg-liuyi,
.dy-dz-liuyi {
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 4px;
    padding: 4px 10px;
}

/* 大运批示 */
.dy-indication {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 12px;
}

.dy-ind-item {
    padding: 12px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.dy-ind-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--text-primary);
}

.dy-ind-item p {
    font-size: 11px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* 流年列表 */
.liunian-section {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.liunian-section h4 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.liunian-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.liunian-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.ln-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    cursor: pointer;
    font-size: 13px;
    transition: background 0.2s;
}

.ln-header:hover {
    background: rgba(255, 255, 255, 0.03);
}

.ln-year {
    font-weight: 700;
    color: var(--accent-blue);
    min-width: 48px;
}

.ln-age {
    font-size: 11px;
    color: var(--text-muted);
}

.ln-ganzhi {
    font-weight: 600;
    color: var(--text-primary);
}

.ln-shishen {
    font-size: 11px;
    color: var(--accent-gold);
    margin-left: auto;
}

.ln-detail {
    padding: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    animation: slideDown 0.2s ease;
}

.ln-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-bottom: 10px;
}

.ln-info-grid div {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 4px;
}

.ln-info-grid div span:first-child {
    color: var(--text-muted);
}

.ln-shensha {
    font-size: 11px;
    color: var(--accent-purple);
    margin-bottom: 8px;
    padding: 6px 8px;
    background: rgba(155, 126, 216, 0.08);
    border-radius: 4px;
}

.ln-indication {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
}

.ln-indication > div {
    padding: 8px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 4px;
}

.ln-indication > div span {
    font-size: 12px;
    display: block;
    margin-bottom: 4px;
}

.ln-indication > div p {
    font-size: 10px;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ========== 命理批示 ========== */
.chenggu-display {
    text-align: center;
}

.cg-weights {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
}

.cg-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 12px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.cg-label {
    font-size: 10px;
    color: var(--text-muted);
}

.cg-val {
    font-size: 14px;
    font-weight: 700;
    color: var(--accent-gold);
}

.cg-total .cg-val {
    font-size: 18px;
    color: var(--accent-red);
}

.cg-plus, .cg-eq {
    font-size: 16px;
    color: var(--text-muted);
}

.cg-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.8;
    padding: 12px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-sm);
}

.indication-text {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.8;
}

.indication-text.poem {
    text-align: center;
    font-size: 16px;
    color: var(--accent-gold);
    padding: 16px;
    background: rgba(212, 168, 83, 0.06);
    border-radius: var(--radius-sm);
    border: 1px solid rgba(212, 168, 83, 0.15);
    font-style: italic;
}

/* ========== Result Actions ========== */
.result-actions {
    text-align: center;
    margin-top: 24px;
}

.btn-reset {
    display: inline-block;
    padding: 12px 32px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    color: var(--text-secondary);
    font-size: 14px;
    text-decoration: none;
    transition: all 0.2s;
}

.btn-reset:hover {
    border-color: var(--accent-gold);
    color: var(--accent-gold);
    background: rgba(212, 168, 83, 0.06);
}

/* ========== Footer ========== */
.app-footer {
    max-width: 480px;
    margin: 0 auto;
    padding: 20px 16px 40px;
    text-align: center;
    font-size: 11px;
    color: var(--text-muted);
    position: relative;
    z-index: 1;
}

/* ========== Loading Spinner ========== */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 10, 26, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 200;
    gap: 20px;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 3px solid rgba(212, 168, 83, 0.2);
    border-top-color: var(--accent-gold);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-text {
    color: var(--text-secondary);
    font-size: 14px;
}

/* ========== Responsive ========== */
@media (max-width: 480px) {
    .sizhu-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .dy-indication {
        grid-template-columns: 1fr;
    }
    
    .ln-indication {
        grid-template-columns: 1fr;
    }

    .info-grid {
        grid-template-columns: 1fr;
    }

    .profile-detail {
        grid-template-columns: 1fr;
    }
}

/* 滚动条美化 */
::-webkit-scrollbar {
    width: 4px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}
