/* codex: 2026-09-14 从style.css拆分弹窗样式（模态框/规则说明/胜负结算），保持单文件≤500行规范 */
/* ==================== 弹窗 ==================== */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(10, 5, 2, 0.82);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    padding: 16px;
    /* 不使用 backdrop-filter：部分低端设备/WebView 合成器对模糊层支持不佳 */
}

.modal.show {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background: linear-gradient(180deg, #402617 0%, #241309 100%);
    border: 2px solid var(--gold);
    border-radius: 16px;
    width: 100%;
    max-width: 580px;
    max-height: 85vh;
    overflow-y: auto;
    padding: 24px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9);
    position: relative;
    color: var(--text-light);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--card-border);
    padding-bottom: 12px;
    margin-bottom: 16px;
}

.modal-header h2 {
    color: var(--gold);
    font-size: 20px;
}

.close-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 26px;
    cursor: pointer;
    line-height: 1;
    padding: 4px 8px;
}

.close-btn:hover {
    color: #fff;
}

.rule-section {
    margin-bottom: 16px;
    font-size: 14px;
    line-height: 1.6;
}

.rule-section h3 {
    color: #e8cfa0;
    margin-bottom: 6px;
    font-size: 16px;
}

.rule-section ul {
    padding-left: 20px;
}

.rule-section li {
    margin-bottom: 4px;
}

.highlight-box {
    background: rgba(224, 52, 52, 0.14);
    border-left: 4px solid var(--cube-cross);
    padding: 8px 12px;
    border-radius: 4px;
    margin: 10px 0;
    font-size: 13px;
}

/* 胜负结算弹窗 */
.win-modal-content {
    text-align: center;
    padding: 36px 24px;
    max-width: 420px;
}

.win-icon {
    font-size: 64px;
    margin-bottom: 16px;
}

.win-title {
    font-size: 28px;
    color: var(--gold);
    margin-bottom: 8px;
}

.win-desc {
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 24px;
}
