/* ============================================================
   dialogs.css - 业务弹窗样式（买房/股票/实业/借贷/破产）
   ============================================================ */

.biz-dialog {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 150;
    animation: fadeIn 0.3s ease-out;
    padding: 20px;
}

.biz-dialog-panel {
    width: 100%;
    max-width: 500px;
    max-height: 85vh;
    background: linear-gradient(135deg, #1a1a1a 0%, #2a1a1a 100%);
    border: 2px solid var(--secondary-yellow);
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: slideUp 0.4s ease-out;
}

.biz-dialog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 20px;
    background: rgba(139,26,26,0.5);
    border-bottom: 2px solid var(--secondary-yellow);
}
.biz-dialog-title {
    font-size: 17px;
    font-weight: bold;
    color: var(--secondary-yellow);
}
.biz-dialog-close {
    font-size: 22px;
    cursor: pointer;
    color: var(--text-primary);
    opacity: 0.8;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}
.biz-dialog-close:hover {
    background: rgba(255,255,255,0.1);
    opacity: 1;
}

.biz-dialog-info {
    padding: 10px 20px;
    background: rgba(0,0,0,0.3);
    font-size: 12px;
    color: var(--text-secondary);
}

.biz-dialog-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px;
}

.biz-dialog-footer {
    padding: 12px 20px;
    background: rgba(0,0,0,0.4);
    border-top: 1px solid var(--border);
    display: flex;
    gap: 8px;
}

.biz-section-title {
    font-size: 15px;
    color: #FFE082;  /* V3.6.2.2: 提亮到 #FFE082，深色背景下对比度从 5:1 升到 ~9:1 */
    margin-bottom: 10px;
    font-weight: bold;
    text-shadow: 0 1px 2px rgba(0,0,0,0.6);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.empty-tip {
    padding: 20px;
    text-align: center;
    color: var(--text-tertiary);
    font-size: 13px;
    background: rgba(255,255,255,0.03);
    border-radius: 8px;
    border: 1px dashed var(--border);
}

/* --- 通用业务按钮 --- */
.biz-btn {
    padding: 8px 14px;
    background: rgba(255,255,255,0.1);
    border: 1px solid var(--border);
    color: var(--text-primary);
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}
.biz-btn:hover { background: rgba(255,255,255,0.15); }
.biz-btn.primary {
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--primary-red-light) 100%);
    border-color: var(--primary-red-light);
    color: #fff;
}
.biz-btn.primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(139,26,26,0.3);
}
/* V3.3.10: 自购"抵押"按钮专用 - 绿色（普通可执行操作，区别于 primary 红色）*/
.biz-btn.action {
    background: linear-gradient(135deg, #2e7d32 0%, #1b5e20 100%);
    border-color: #1b5e20;
    color: #fff;
}
.biz-btn.action:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(46,125,50,0.3);
}
.biz-btn.secondary {
    background: transparent;
    border-color: var(--secondary-yellow);
    color: var(--secondary-yellow);
}
.biz-btn.small {
    padding: 6px 10px;
    font-size: 11px;
}
.biz-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;   /* V3.3.5: iOS Safari 双保险，彻底禁掉点击 */
}
.biz-btn.no-action {
    pointer-events: none;   /* V3.3.5: no-action 类也彻底禁掉点击 */
    opacity: 0.4;
    cursor: not-allowed;
}

/* --- 房产项 --- */
.property-item, .property-buy-item {
    background: rgba(255,255,255,0.05);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}
.property-info { flex: 1; }
.property-title {
    font-size: 14px;
    font-weight: bold;
    color: var(--text-primary);
    margin-bottom: 4px;
}
.property-meta {
    font-size: 11px;
    color: var(--text-secondary);
    line-height: 1.5;
}
.property-actions {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

/* --- 股票项 --- */
.stock-item, .stock-buy-item {
    background: rgba(255,255,255,0.05);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    cursor: pointer;  /* V3.0: 整行可点击 */
    transition: background 0.2s;
}
.stock-item:hover, .stock-buy-item:hover {
    background: rgba(255,255,255,0.1);
}
.stock-info { flex: 1; }
.stock-code {
    font-size: 14px;
    font-weight: bold;
    color: var(--secondary-yellow);
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}
/* V3.0: 股票档位标签 */
.stock-tier {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 3px;
    font-size: 10px;
    font-weight: normal;
    color: #fff;
}
.stock-tier.tier-stable { background: #3498db; }  /* 蓝：稳健 */
.stock-tier.tier-growth { background: #16a085; }  /* 绿：成长 */
.stock-tier.tier-tech   { background: #9b59b6; }  /* 紫：科技 */
.stock-tier.tier-wild   { background: #e74c3c; }  /* 红：妖股 */
.stock-tier.tier-legacy { background: #7f8c8d; }  /* 灰：传统 */
.stock-meta {
    font-size: 11px;
    color: var(--text-secondary);
}
.stock-vol {
    color: #888;
    font-size: 10px;
    margin-left: 4px;
}
/* V3.0: A 股配色（涨红跌绿）—— 覆写全局 .positive/.negative */
.stock-profit { font-size: 12px; font-weight: bold; margin-top: 4px; }
.a-up   { color: #E74C3C !important; }   /* 涨：红 */
.a-down { color: #2ECC71 !important; }   /* 跌：绿 */
/* V3.0: 本月预估涨跌幅 */
.stock-monthly-change {
    font-size: 11px;
    margin-top: 2px;
    font-weight: bold;
}
.stock-buy-input {
    display: flex;
    align-items: center;
    gap: 4px;
}
.stock-buy-input input {
    width: 80px;
    padding: 4px 6px;
    background: rgba(255,255,255,0.1);
    border: 1px solid var(--border);
    border-radius: 4px;
    color: var(--text-primary);
    font-size: 12px;
    outline: none;
}

/* --- 实业项 --- */
.business-item, .business-type-item {
    background: rgba(255,255,255,0.05);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}
.business-info { flex: 1; }
.business-title {
    font-size: 14px;
    font-weight: bold;
    color: var(--text-primary);
    margin-bottom: 4px;
}
.business-meta {
    font-size: 11px;
    color: var(--text-secondary);
    line-height: 1.5;
}
.positive { color: var(--success); }
.negative { color: var(--error); }
.business-actions {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

/* --- 贷款项 --- */
.loan-item {
    background: rgba(255,255,255,0.05);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}
.loan-info { flex: 1; }
.loan-title {
    font-size: 14px;
    font-weight: bold;
    color: var(--text-primary);
    margin-bottom: 4px;
}
.loan-meta {
    font-size: 11px;
    color: var(--text-secondary);
    line-height: 1.5;
}
.loan-actions {
    display: flex;
    gap: 4px;
}

/* --- 破产挽救 --- */
.bankrupt-warning {
    padding: 16px;
    background: rgba(231,76,60,0.2);
    border: 1px solid var(--error);
    border-radius: 8px;
    text-align: center;
    margin-bottom: 20px;
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.6;
}
.recharge-tiers {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 16px;
}
.recharge-btn {
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}
.recharge-btn:hover {
    background: rgba(212,165,116,0.2);
    border-color: var(--secondary-yellow);
    transform: translateY(-2px);
}
.recharge-tier {
    font-size: 14px;
    font-weight: bold;
    color: var(--secondary-yellow);
    margin-bottom: 4px;
}
.recharge-price {
    font-size: 12px;
    color: var(--text-secondary);
}
.bankrupt-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

/* ============================================================
   \u6708\u5ea6\u7ed3\u7b97\u5f39\u7a97 \u2014\u2014 V3.0 \u7edf\u4e00\u4e3a\u5b8b\u4f53 14px\uff08\u4e0e BottomSheet \u4e00\u81f4\uff09
   ============================================================ */
.settlement-title {
    font-size: 14px !important;
    font-weight: 800;
    color: #8b1a1a;
    margin-bottom: 12px;
    text-align: center;
    font-family: "SimSun", "\u5b8b\u4f53", "Songti SC", "STSong", serif;
}
.settlement-total {
    font-size: 14px !important;
    font-weight: 700;
    padding: 14px;
    text-align: center;
    background: #fff8e7;
    border: 1px solid #e8dcb8;
    border-radius: 8px;
    margin-bottom: 14px;
    font-family: "SimSun", "\u5b8b\u4f53", "Songti SC", "STSong", serif;
}
.settlement-total.positive {
    color: #2e7d32;
    background: #e8f5e9;
    border-color: #c8e6c9;
}
.settlement-total.negative {
    color: #c62828;
    background: #ffebee;
    border-color: #ef9a9a;
}
.settlement-events {
    font-size: 14px !important;
    line-height: 1.7;
    max-height: 320px;
    overflow-y: auto;
    padding: 4px 8px;
    font-family: "SimSun", "\u5b8b\u4f53", "Songti SC", "STSong", serif;
}
.settlement-event {
    padding: 10px 8px;
    border-bottom: 1px dashed #e8dcb8;
    font-size: 14px !important;
    color: #2a2418;
    line-height: 1.7;
}
.settlement-event strong {
    color: #8b1a1a;
    font-weight: 800;
}
.settlement-warning {
    color: #c62828;
    margin-top: 12px;
    padding: 12px;
    background: #ffebee;
    border: 1px solid #ef9a9a;
    border-radius: 6px;
    font-size: 14px !important;
    font-weight: 600;
    font-family: "SimSun", "\u5b8b\u4f53", "Songti SC", "STSong", serif;
    line-height: 1.7;
}
.settlement-actions {
    margin-top: 16px;
    text-align: center;
}
.settlement-actions .biz-btn {
    min-width: 140px;
    padding: 10px 28px;
    height: 44px;
}

/* ============================================================
   V3.0 升级：月度结算新样式（BottomSheet + 分类汇总）
   ============================================================ */
.settlement-total-label {
    font-size: 12px;
    opacity: 0.8;
    margin-bottom: 4px;
    font-weight: 600;
}
.settlement-total-amount {
    font-size: 28px;
    font-weight: 800;
    font-family: "SimSun", "宋体", "Songti SC", "STSong", serif;
    margin-bottom: 4px;
}
.settlement-total-balance {
    font-size: 12px;
    opacity: 0.7;
    font-weight: 600;
}
.settlement-summary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 14px;
}
.settlement-summary-item {
    padding: 10px 12px;
    border-radius: 8px;
    text-align: center;
    border: 1px solid;
}
.settlement-summary-item.income {
    background: #e8f5e9;
    border-color: #c8e6c9;
    color: #2e7d32;
}
.settlement-summary-item.expense {
    background: #ffebee;
    border-color: #ef9a9a;
    color: #c62828;
}
.settlement-summary-label {
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 4px;
}
.settlement-summary-value {
    font-size: 18px;
    font-weight: 800;
    font-family: "SimSun", "宋体", serif;
    margin-bottom: 2px;
}
.settlement-summary-count {
    font-size: 10px;
    opacity: 0.7;
}
.settlement-events-title {
    font-size: 13px;
    font-weight: 700;
    color: #5d4037;
    margin-bottom: 8px;
    padding: 0 4px;
    font-family: "SimSun", "宋体", serif;
}
.settlement-event-amount {
    float: right;
    color: #5d4037;
    font-weight: 600;
    font-family: "SimSun", "宋体", serif;
}
.settlement-warning-title {
    font-size: 13px;
    font-weight: 800;
    margin-bottom: 6px;
    color: #c62828;
}
.settlement-warning-item {
    font-size: 13px;
    line-height: 1.7;
    color: #c62828;
}

/* V3.0: 股票本月利好/利空消息 */
#stock-monthly-news {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    padding: 8px 10px;
    margin-bottom: 12px;
    border-left: 3px solid #f39c12;
}
.stock-news-item {
    font-size: 12px;
    line-height: 1.6;
    padding: 4px 0;
    font-family: "SimSun", "宋体", serif;
}
.stock-news-item.news-bull { color: #E74C3C; }  /* 利好：红 */
.stock-news-item.news-bear { color: #2ECC71; }  /* 利空：绿 */

/* ============================================================
   V3.0 整合：实名认证中的用户协议 + 免责声明样式
   （原 disclaimer.css 内容，类名改为 realname-agree-*）
   ============================================================ */

.realname-agree-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    user-select: none;
}
.realname-agree-toggle:hover {
    color: #ffd700;
}
.realname-agree-toggle-icon {
    font-size: 11px;
    color: #888;
    transition: transform 0.2s;
}

.realname-agree-wrap {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    margin-top: 8px;
    overflow: hidden;
}

.realname-agree-tip {
    background: rgba(255, 193, 7, 0.15);
    color: #ffd54f;
    padding: 8px 12px;
    font-size: 12px;
    line-height: 1.6;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-family: "SimSun", "宋体", serif;
}

.realname-agree-body {
    max-height: 280px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 10px 12px;
}
.biz-dialog-body::-webkit-scrollbar { width: 8px; }
.realname-agree-body::-webkit-scrollbar { width: 6px; }
.realname-agree-body::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
}
/* V3.0 防御性：若 JS 误用 realname-agree-body 作为 item 正文，也要有样式 */
.realname-item .realname-agree-body,
.realname-agree-item .realname-agree-body {
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-size: 12px;
    line-height: 1.7;
    color: #d6dde8;
    text-align: justify;
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    max-height: none;
    overflow: visible;
}

/* ============================================================
   V3.1 完整合同书样式
   ============================================================ */

/* V3.1 修复：法规说明 / 登录方式 / section 通用样式（之前完全没定义 → 看不见） */
.realname-section {
    margin-bottom: 12px;
    padding: 10px 12px;
    background: rgba(255, 248, 231, 0.95);   /* 米黄底色（高对比） */
    border: 1px solid rgba(139, 26, 26, 0.15);
    border-left: 4px solid var(--primary-red);
    border-radius: 8px;
}
.realname-section-title {
    font-size: 14px;
    font-weight: 800;
    color: #4a3a1f;                          /* 深棕字（强制高对比） */
    margin-bottom: 8px;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    letter-spacing: 0.5px;
    line-height: 1.4;
}
.realname-section-text {
    font-size: 13px;
    line-height: 1.8;
    color: #2a2418;                          /* 深色字（强制高对比） */
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    text-align: justify;
    font-weight: bold;
}
.realname-section-text br + br {
    display: block;
    content: "";
    margin-top: 4px;
}

/* 登录方式（微信/游客） */
.realname-method {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    background: rgba(46, 204, 113, 0.1);    /* 浅绿底 */
    border: 1px solid rgba(46, 204, 113, 0.3);
    border-radius: 8px;
}
.realname-method.wechat {
    background: rgba(52, 152, 219, 0.1);    /* 浅蓝底（微信） */
    border-color: rgba(52, 152, 219, 0.3);
}
.realname-method.guest {
    background: rgba(243, 156, 18, 0.1);    /* 浅橙底（游客） */
    border-color: rgba(243, 156, 18, 0.3);
}
.realname-method-icon {
    font-size: 24px;
    line-height: 1;
    flex-shrink: 0;
}
.realname-method-text {
    font-size: 13px;
    line-height: 1.7;
    color: #2a2418;                          /* 深色字 */
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: bold;
    flex: 1;
}
.realname-method-text small {
    font-size: 11px;
    color: #6a5a3c;
    font-weight: normal;
}

/* 用户协议 toggle 行（"📑 用户协议与免责声明"） */
.realname-section-title.realname-agree-toggle {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    cursor: pointer;
    user-select: none;
    color: #4a3a1f;
    background: rgba(255, 215, 0, 0.15);
    padding: 8px 10px;
    border-radius: 6px;
    margin-bottom: 6px;
}
.realname-section-title.realname-agree-toggle:hover {
    background: rgba(255, 215, 0, 0.25);
}
.realname-agree-toggle-icon {
    margin-left: auto;
    font-size: 12px;
    color: #8b1a1a;
    transition: transform 0.2s;
}
.realname-agree-meta {
    font-size: 11px;
    color: #8b1a1a;
    background: rgba(255, 255, 255, 0.6);
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 700;
    margin-left: 4px;
}

/* 年龄确认 checkbox 区域 */
.realname-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid #c4b48a;
    border-radius: 8px;
    cursor: pointer;
}
.realname-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex-shrink: 0;
    accent-color: #8b1a1a;
}
.realname-checkbox-text {
    font-size: 12.5px;
    line-height: 1.7;
    color: #2a2418;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: bold;
}

/* 警告提示 */
.realname-warning {
    background: rgba(231, 76, 60, 0.1) !important;
    border: 1px solid rgba(231, 76, 60, 0.4) !important;
    border-left: 4px solid #e74c3c !important;
}
.realname-warning-text {
    font-size: 12px;
    line-height: 1.7;
    color: #c62828;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 700;
}


/* 合同 meta 提示（如"约 1.1 万字"） */
.realname-agree-meta {
    font-size: 11px;
    color: #888;
    background: rgba(255,255,255,0.05);
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: 8px;
    font-weight: normal;
}

/* 合同节（通用） */
.contract-section {
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px dashed rgba(74,58,31,0.3);
}
.contract-section:last-child {
    border-bottom: none;
}
.contract-section-title {
    font-size: 13px;
    font-weight: 800;
    color: #4a3a1f;
    margin-bottom: 6px;
    letter-spacing: 0.5px;
}
.contract-section-content {
    font-size: 11.5px;
    line-height: 1.7;
    color: #2a2418;
    text-align: justify;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 500;
}

/* 前言特殊样式：加粗金边 */
.contract-preamble {
    background: rgba(255, 248, 231, 0.95);
    padding: 10px 12px;
    border-radius: 6px;
    border-left: 3px solid var(--secondary-yellow);
    border-bottom: 1px solid rgba(74,58,31,0.15);
}
.contract-preamble .contract-section-title { color: #8b1a1a; }
.contract-preamble .contract-section-content { color: #2a2418; font-weight: 600; }

/* 释义 */
.contract-def-list {
    margin: 6px 0 0 0;
    padding-left: 18px;
}
.contract-def-item {
    font-size: 11.5px;
    line-height: 1.7;
    color: #2a2418;
    margin-bottom: 4px;
    text-align: justify;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 500;
}

/* 主合同 */
.contract-article-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
    padding-bottom: 5px;
    border-bottom: 1px solid rgba(139,26,26,0.3);
}
.contract-article-icon { font-size: 15px; }
.contract-article-number {
    font-size: 13px;
    font-weight: 800;
    color: #8b1a1a;
}
.contract-article-title {
    font-size: 12.5px;
    font-weight: 700;
    color: #2a2418;
}
.contract-article-content {
    font-size: 11.5px;
    line-height: 1.7;
    color: #2a2418;
    text-align: justify;
    margin-bottom: 6px;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 500;
}
.contract-article-subs {
    background: rgba(255,255,255,0.5);
    border-left: 3px solid var(--secondary-yellow);
    padding: 6px 10px;
    border-radius: 0 4px 4px 0;
    margin-left: 4px;
}
.contract-sub {
    font-size: 11px;
    line-height: 1.7;
    color: #2a2418;
    margin-bottom: 5px;
    text-align: justify;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 500;
}
.contract-sub:last-child { margin-bottom: 0; }

/* 附件 */
.contract-attachment {
    background: rgba(52, 152, 219, 0.08);
    border: 1px solid rgba(52, 152, 219, 0.4);
    border-radius: 6px;
    padding: 10px 12px;
}
.contract-attachment-label {
    display: inline-block;
    background: linear-gradient(135deg, #1e3a5f 0%, #2c5282 100%);
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    padding: 3px 10px;
    border-radius: 12px;
    margin-bottom: 6px;
    letter-spacing: 1px;
}
.contract-attachment-title-main {
    font-size: 13px;
    font-weight: 800;
    color: #1e3a5f;
    margin-bottom: 6px;
}
.contract-attachment-intro {
    font-size: 11px;
    line-height: 1.7;
    color: #1a2b3c;
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 1px dashed rgba(30,58,95,0.3);
    text-align: justify;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 500;
}
.contract-attachment-article {
    background: rgba(255,255,255,0.5);
    border-radius: 4px;
    padding: 6px 8px;
    margin-bottom: 6px;
    border-left: 2px solid rgba(52,152,219,0.5);
}
.contract-attachment-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}
.contract-attachment-number {
    font-size: 11px;
    font-weight: 800;
    color: #1e3a5f;
    background: rgba(30,58,95,0.15);
    padding: 1px 6px;
    border-radius: 3px;
}
.contract-attachment-title {
    font-size: 11.5px;
    font-weight: 700;
    color: #1a2b3c;
}
.contract-attachment-content {
    font-size: 10.5px;
    line-height: 1.7;
    color: #1a2b3c;
    text-align: justify;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 500;
}

/* 签字栏 */
.contract-signature {
    background: linear-gradient(135deg, rgba(46,204,113,0.12) 0%, rgba(212,165,116,0.08) 100%);
    border: 1px solid rgba(46,204,113,0.4);
    border-radius: 6px;
    padding: 10px 12px;
}
.contract-signature .contract-section-title { color: #1b5e20; }
.contract-signature .contract-section-content { color: #1a2b1a; font-weight: 500; }
.contract-signature-line {
    background: rgba(255,255,255,0.6);
    border-radius: 4px;
    padding: 8px 10px;
    margin-top: 8px;
    border: 1px dashed rgba(46,204,113,0.4);
}
.contract-signature-row {
    display: flex;
    font-size: 11px;
    line-height: 1.8;
    color: #1a2b1a;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 500;
}
.contract-signature-label {
    color: #1b5e20;
    font-weight: 800;
    min-width: 70px;
}
.contract-signature-value {
    color: #000;
    flex: 1;
    font-weight: 600;
}

/* 合同尾 */
.contract-footer {
    text-align: center;
    color: #4a3a1f;
    font-size: 11px;
    padding: 10px 0 4px 0;
    border-top: 1px dashed rgba(74,58,31,0.3);
    margin-top: 10px;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 600;
}
.contract-footer-meta {
    font-size: 10px;
    color: #6a5a3c;
    margin-top: 4px;
    display: inline-block;
    font-weight: 500;
}

/* 合同头 */
.contract-header {
    background: linear-gradient(135deg, rgba(255,248,231,0.95) 0%, rgba(255,238,200,0.95) 100%);
    border: 2px solid var(--secondary-yellow);
    border-radius: 8px;
    padding: 12px 14px;
    margin-bottom: 14px;
}
.contract-header-title {
    font-size: 14px;
    font-weight: 800;
    color: #8b1a1a;
    text-align: center;
    margin-bottom: 8px;
    letter-spacing: 1px;
}
.contract-header-meta {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #4a3a1f;
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 1px dashed rgba(74,58,31,0.3);
    font-weight: 600;
}
.contract-parties {
    font-size: 11px;
    line-height: 1.6;
    color: #2a2418;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-weight: 500;
}

/* ============================================================
   V3.1 完整合同书：滚动容器高度（PC 端拉高，mobile 紧凑）
   ============================================================ */
.bs-panel-contract .realname-agree-body {
    max-height: 800px;  /* PC 端：800px，能看到更多内容 */
    padding: 8px 10px;
}
@media (max-width: 480px) {
    .bs-panel-contract .realname-agree-body {
        max-height: 400px;  /* mobile：400px 紧凑 */
    }
}

.realname-agree-item {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 10px 12px;
    margin-bottom: 8px;
}
.realname-agree-item:last-child { margin-bottom: 0; }

.realname-agree-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}
.realname-agree-icon {
    font-size: 16px;
    line-height: 1;
}
.realname-agree-title {
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-size: 13px;
    font-weight: bold;
    color: #ffd700;
}
.realname-agree-text {
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-size: 12px;
    line-height: 1.7;
    color: #d6dde8;
    text-align: justify;
}

/* V3.0 PC 端：业务弹窗已经 max-width: 500px，足够窄；加个微妙居中 */
@media (min-width: 481px) {
    .biz-dialog {
        padding: 30px;
    }
}

/* 移动端适配（手机 480px 以下） */
@media (max-width: 480px) {
    .realname-agree-body { max-height: 220px; }
    .realname-agree-title { font-size: 12px; }
    .realname-agree-text { font-size: 11px; line-height: 1.6; }
}

/* ============================================================
   V3.2 系统空间 + 商城 新增样式
   ============================================================ */

/* 解锁按钮（金色高亮） */
.skill-btn.unlock {
    background: linear-gradient(135deg, #d4a017 0%, #b8860b 100%);
    color: #fff;
    font-weight: 600;
    border: 1px solid #b8860b;
    box-shadow: 0 2px 4px rgba(212, 160, 23, 0.3);
}
.skill-btn.unlock:hover:not([disabled]) {
    background: linear-gradient(135deg, #e0b028 0%, #c89510 100%);
    transform: translateY(-1px);
}
.skill-btn.unlock[disabled] {
    background: #d4d4d4;
    color: #888;
    box-shadow: none;
    cursor: not-allowed;
}

/* 已购技能卡（绿色边框 + 浅绿底） */
.skill-card.owned {
    border-color: #4caf50;
    background: linear-gradient(135deg, #f1f8e9 0%, #ffffff 100%);
}
.skill-btn.owned {
    background: #4caf50;
    color: #fff;
}
.skill-btn.owned[disabled] {
    background: #bdbdbd;
    color: #fff;
}

/* 商城 section 卡片 */
.mall-section {
    background: #faf6e8;
    border: 1px solid #e0d4b0;
    border-radius: 8px;
    padding: 14px;
    margin-bottom: 14px;
}
.mall-section-title {
    font-size: 14px;
    font-weight: bold;
    color: #5a4a3a;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px dashed #d4c490;
}
.mall-points-display {
    text-align: center;
    padding: 14px 0;
    background: linear-gradient(135deg, #fff8e7 0%, #faf6e8 100%);
    border-radius: 6px;
    margin-bottom: 10px;
}
.mall-points-num {
    font-size: 32px;
    font-weight: bold;
    color: #d4a017;
    line-height: 1.2;
}
.mall-points-label {
    font-size: 12px;
    color: #8a7a6a;
    margin-top: 4px;
}
.mall-points-meta {
    font-size: 11px;
    color: #8a7a6a;
    text-align: center;
    margin-bottom: 10px;
}
.mall-recharge-btn {
    display: block;
    width: 100%;
    padding: 10px;
    background: linear-gradient(135deg, #d4a017 0%, #b8860b 100%);
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.mall-recharge-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(212, 160, 23, 0.3);
}

/* 商城技能卡 */
.mall-skill-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    border: 1px solid #e0d4b0;
    border-radius: 6px;
    padding: 10px 12px;
    margin-bottom: 8px;
    transition: all 0.2s;
}
.mall-skill-card.owned {
    background: #f1f8e9;
    border-color: #4caf50;
}
.mall-skill-info {
    flex: 1;
    min-width: 0;
}
.mall-skill-name {
    font-size: 13px;
    font-weight: 600;
    color: #2a2418;
    margin-bottom: 3px;
}
.mall-skill-desc {
    font-size: 11px;
    color: #8a7a6a;
    line-height: 1.4;
}
.mall-skill-price {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    margin-left: 10px;
}
.price-tag {
    background: #fff8e7;
    color: #d4a017;
    font-size: 12px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 10px;
    border: 1px solid #d4a017;
}
.owned-tag {
    color: #4caf50;
    font-size: 11px;
    font-weight: 600;
}
.mall-buy-btn {
    background: #d4a017;
    color: #fff;
    border: none;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.mall-buy-btn:hover:not([disabled]) {
    background: #b8860b;
}
.mall-buy-btn[disabled] {
    background: #d4d4d4;
    color: #888;
    cursor: not-allowed;
}

/* 兑换历史 */
.mall-history-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 12px;
    border-bottom: 1px dashed #e0d4b0;
}
.mall-history-item:last-child {
    border-bottom: none;
}
.mall-history-name {
    color: #2a2418;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.mall-history-points {
    color: #d32f2f;
    font-weight: 600;
    margin-right: 10px;
}
.mall-history-time {
    color: #aaa;
    font-size: 10px;
    flex-shrink: 0;
}

/* ============================================================
   V3.2.3 排行榜样式
   ============================================================ */
.lb-tabs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: rgba(0,0,0,0.3);
    border-bottom: 1px solid var(--border);
}
.lb-tab {
    padding: 10px 6px;
    text-align: center;
    color: var(--text-secondary);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}
.lb-tab-emoji { font-size: 18px; line-height: 1; }
.lb-tab-text { font-size: 11px; line-height: 1.2; }
.lb-tab:hover { background: rgba(212, 165, 116, 0.05); }
.lb-tab.active {
    color: var(--secondary-yellow);
    border-bottom-color: var(--secondary-yellow);
    background: rgba(212, 165, 116, 0.1);
}
.lb-board {
    padding: 16px;
}
.lb-board-title {
    font-size: 18px;
    font-weight: bold;
    color: var(--secondary-yellow);
    margin-bottom: 4px;
}
.lb-board-desc {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 12px;
}
.lb-board-player-rank {
    background: linear-gradient(135deg, rgba(212, 160, 23, 0.2), rgba(212, 160, 23, 0.05));
    border: 1px solid var(--secondary-yellow);
    border-radius: 6px;
    padding: 10px 14px;
    margin-bottom: 14px;
    font-size: 14px;
    color: var(--text-primary);
    text-align: center;
}
.lb-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.lb-item {
    display: grid;
    grid-template-columns: 40px 36px 1fr auto;
    align-items: center;
    padding: 10px 12px;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border);
    border-radius: 6px;
    transition: all 0.2s;
}
.lb-item.top3 {
    background: linear-gradient(135deg, rgba(212, 160, 23, 0.15), rgba(212, 160, 23, 0.05));
    border-color: var(--secondary-yellow);
}
.lb-item.is-player {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.2), rgba(76, 175, 80, 0.05));
    border-color: #4caf50;
    border-width: 2px;
    box-shadow: 0 2px 6px rgba(76, 175, 80, 0.2);
}
.lb-rank {
    font-size: 18px;
    text-align: center;
}
.lb-rank-num {
    display: inline-block;
    width: 24px;
    height: 24px;
    line-height: 24px;
    background: var(--border);
    color: var(--text-secondary);
    border-radius: 50%;
    font-size: 12px;
    font-weight: bold;
}
.lb-avatar {
    font-size: 22px;
    text-align: center;
}
.lb-name {
    font-size: 14px;
    color: var(--text-primary);
    font-weight: 500;
}
.lb-value {
    font-size: 14px;
    color: var(--secondary-yellow);
    font-weight: 600;
}

/* ============================================================
   V3.2.4 AI 破产高亮（排行榜里已退出玩家用）
   ============================================================ */
.lb-item.is-bankrupt {
    opacity: 0.4;
    background: linear-gradient(135deg, rgba(198, 40, 40, 0.15), rgba(198, 40, 40, 0.05)) !important;
    border-color: #c62828 !important;
    text-decoration: line-through;
}
.lb-item.is-bankrupt .lb-avatar {
    filter: grayscale(1);
}
