/* ============================
   武术套路比赛报名系统 - 样式表
   ============================ */

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

:root {
  --red-primary: #C41E24; --red-dark: #8B0000; --red-light: #E8505A;
  --gold-primary: #F5C842; --gold-light: #FFD866;
  --bg-dark: #0D0D1A; --bg-card: #1A1A2E; --bg-input: #12121F;
  --text-primary: #FFFFFF; --text-secondary: #B0B0B8; --text-muted: #666677;
  --border-color: #2A2A3E; --success: #26A269; --warning: #F37329;
  --font-main: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  --safe-bottom: 83px;
}

html, body { width: 100%; height: 100%; overflow: hidden; font-family: var(--font-main); background: var(--bg-dark); color: var(--text-primary); font-size: 14px; line-height: 1.5; }

/* ====== Page Transition ====== */
.page { position: absolute; top: 0; left: 0; width: 100%; height: 100%; overflow-y: auto; overflow-x: hidden; transform: translateX(100%); transition: transform .35s cubic-bezier(.4,0,.2,1); background: var(--bg-dark); -webkit-overflow-scrolling: touch; }
.page.active { transform: translateX(0); }
.page.slide-out-left { transform: translateX(-30%); opacity: .6; transition: transform .35s, opacity .35s; }

/* ====== Status Bar ====== */
.status-bar { display: none; }
.status-icons { display: flex; align-items: center; gap: 6px; }
.battery-icon { width: 25px; height: 12px; border: 1.5px solid #FFF; border-radius: 3px; position: relative; padding: 1.5px; }
.battery-icon::after { content: ''; position: absolute; right: -4px; top: 50%; transform: translateY(-50%); width: 2px; height: 5px; background: #FFF; border-radius: 0 1px 1px 0; }
.battery-level { width: 75%; height: 100%; background: #FFF; border-radius: 1px; }

/* ====== Fixed Nav ====== */
.fixed-nav { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px 16px; background: linear-gradient(135deg, var(--red-primary) 0%, var(--red-dark) 100%); position: sticky; top: 0; z-index: 100; }
.nav-back, .nav-share { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; cursor: pointer; border-radius: 50%; transition: background .2s; }
.nav-back:active { background: rgba(255,255,255,.15); }
.nav-title { font-size: 17px; font-weight: 600; }
.nav-save-draft { padding: 6px 14px; font-size: 13px; color: #FFF; background: rgba(255,255,255,.15); border: 1px solid rgba(255,255,255,.3); border-radius: 16px; cursor: pointer; transition: background .2s; white-space: nowrap; flex-shrink: 0; }
.nav-save-draft:active { background: rgba(255,255,255,.3); }

/* ====== Header ====== */
.header { padding: 16px 20px 24px; position: relative; overflow: hidden; }
.header-gradient { background: linear-gradient(135deg, var(--red-primary) 0%, var(--red-dark) 100%); }
.header::before { content: ''; position: absolute; top: -40px; right: -40px; width: 160px; height: 160px; background: radial-gradient(circle, rgba(245,200,66,.15) 0%, transparent 70%); pointer-events: none; }
.header::after { content: '武'; position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font-size: 80px; font-weight: 900; color: rgba(255,255,255,.04); pointer-events: none; }
.header-title { font-size: 17px; font-weight: 700; letter-spacing: 1px; position: relative; z-index: 1; }
.header-subtitle { font-size: 13px; color: rgba(245,200,66,.85); margin-top: 4px; letter-spacing: 4px; position: relative; z-index: 1; }

/* ====== Search Bar ====== */
.search-bar { margin: 0 16px; padding: 10px 16px; background: var(--bg-card); border-radius: 12px; display: flex; align-items: center; gap: 8px; border: 1px solid var(--border-color); transform: translateY(-50%); position: relative; z-index: 2; }
.search-icon { flex-shrink: 0; opacity: .5; }
.search-placeholder { color: var(--text-muted); font-size: 13px; }

/* ====== Content ====== */
.content-wrapper { padding: 0 16px 100px; margin-top: 8px; }
.section-label { font-size: 15px; font-weight: 600; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.section-label::before { content: ''; display: inline-block; width: 3px; height: 16px; background: var(--red-primary); border-radius: 2px; }

/* ====== Competition Card ====== */
.competition-card { background: var(--bg-card); border-radius: 16px; padding: 16px; margin-bottom: 12px; border: 1px solid var(--border-color); transition: transform .2s; cursor: pointer; }
.competition-card:active { transform: scale(.98); }
.card-ended { opacity: .55; }
.card-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 8px; }
.card-title-row { flex: 1; }
.card-title { font-size: 15px; font-weight: 600; line-height: 1.4; }
.card-status { font-size: 11px; font-weight: 600; padding: 3px 10px; border-radius: 12px; flex-shrink: 0; margin-left: 8px; }
.status-open { background: rgba(38,162,105,.2); color: var(--success); }
.status-upcoming { background: rgba(245,200,66,.2); color: var(--gold-primary); }
.status-ended { background: rgba(102,102,119,.2); color: var(--text-muted); }
.card-info { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.card-info-item { font-size: 12px; color: var(--text-secondary); }
.card-footer { display: flex; justify-content: space-between; align-items: center; padding-top: 10px; border-top: 1px solid var(--border-color); }
.card-enter-btn { background: var(--red-primary); color: #FFF; font-size: 12px; font-weight: 600; padding: 6px 14px; border-radius: 16px; transition: background .2s; }
.card-enter-btn:active { background: var(--red-dark); }

/* ====== Tab Bar ====== */
.tab-bar { position: fixed; bottom: 0; left: 0; right: 0; height: var(--safe-bottom); padding-bottom: 24px; background: rgba(13,13,26,.97); backdrop-filter: blur(20px); display: flex; justify-content: space-around; align-items: flex-start; padding-top: 10px; border-top: 1px solid var(--border-color); z-index: 200; }
.tab-item { display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--text-muted); font-size: 10px; cursor: pointer; padding: 4px 12px; border-radius: 12px; transition: color .2s; }
.tab-item.tab-active { color: var(--red-primary); }
.tab-item:active svg { transform: scale(.9); }
/* 全局底部导航栏独立于所有 .page，故常驻每一页 */
.tab-bar.hidden { display: none; }
/* 所有页面底部预留导航栏安全区 + 内容区内 footer 空间（登录页除外） */
.page:not(#page-login) { padding-bottom: calc(var(--safe-bottom) + 56px); }
/* 团体总分 */
.team-points-card { background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border-color); padding: 4px 12px; margin-bottom: 16px; }
.team-points-table th, .team-points-table td { padding: 10px 8px; font-size: 12px; text-align: center; border-bottom: 1px solid var(--border-color); }
.team-points-table tbody tr:last-child td { border-bottom: none; }
.tp-rank { font-weight: 700; color: var(--gold-primary); }
.tp-points { font-weight: 700; color: var(--red-primary); }
.tp-team { text-align: left !important; font-weight: 600; }
.tp-medals { white-space: nowrap; }

/* ====== Detail Header ====== */
.detail-header-compact { background: linear-gradient(135deg, var(--red-primary) 0%, var(--red-dark) 100%); padding: 16px 20px 20px; position: relative; overflow: hidden; }
.detail-header-compact::after { content: '术'; position: absolute; right: 16px; top: 50%; transform: translateY(-50%); font-size: 80px; font-weight: 900; color: rgba(255,255,255,.04); pointer-events: none; }
.detail-name { font-size: 19px; font-weight: 700; position: relative; z-index: 1; }
.detail-meta-row { display: flex; align-items: center; gap: 8px; font-size: 13px; color: rgba(255,255,255,.8); margin-top: 6px; position: relative; z-index: 1; }
.dot-sep { opacity: .4; }
.detail-content { padding: 16px; }

/* ====== Module Grid ====== */
.module-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.module-item { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 4px 10px; background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border-color); cursor: pointer; transition: transform .2s, border-color .2s; }
.module-item:active { transform: scale(.95); border-color: var(--red-primary); }
.module-icon { width: 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center; }
.module-label { font-size: 11px; font-weight: 600; text-align: center; }
.module-desc { font-size: 9px; color: var(--text-muted); text-align: center; }

/* ====== Step Indicator ====== */
.step-indicator { display: flex; align-items: center; justify-content: center; padding: 20px 24px 16px; background: var(--bg-card); border-bottom: 1px solid var(--border-color); gap: 0; }
.step { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 11px; color: var(--text-muted); transition: color .3s; }
.step.active { color: var(--red-primary); }
.step.done { color: var(--success); }
.step-num { width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; border: 2px solid var(--border-color); background: var(--bg-dark); transition: all .3s; }
.step.active .step-num { border-color: var(--red-primary); background: var(--red-primary); color: #FFF; }
.step.done .step-num { border-color: var(--success); background: var(--success); color: #FFF; }
.step-line { flex: 1; height: 2px; background: var(--border-color); margin: 0 4px; margin-bottom: 20px; max-width: 40px; transition: background .3s; }
.step.done + .step-line { background: var(--success); }

/* ====== Register Content ====== */
.register-content { padding: 16px 16px 120px; }
.step-panel { display: none; }
.step-panel.active { display: block; animation: fadeIn .3s; }

/* ====== Form Elements ====== */
.form-section { margin-bottom: 24px; }
.form-section-title { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; font-size: 15px; font-weight: 600; }
.section-title-bar { width: 3px; height: 16px; background: var(--red-primary); border-radius: 2px; }
.form-hint { font-size: 12px; color: var(--text-muted); margin-bottom: 12px; }
.form-group { margin-bottom: 14px; }
.form-label { display: block; font-size: 13px; font-weight: 500; color: var(--text-secondary); margin-bottom: 6px; }
.required { color: var(--red-light); }
.form-input { width: 100%; height: 44px; padding: 0 14px; background: var(--bg-input); border: 1.5px solid var(--border-color); border-radius: 10px; color: var(--text-primary); font-size: 14px; font-family: var(--font-main); outline: none; transition: border-color .2s; }
.form-input:focus { border-color: var(--red-primary); }
.form-input::placeholder { color: var(--text-muted); }
.form-row { display: flex; gap: 12px; }
.form-group-half { flex: 1; }

/* ====== ID Preview ====== */
.id-preview { background: var(--bg-card); border-radius: 10px; padding: 12px; margin: 10px 0; flex-wrap: wrap; border: 1px solid var(--border-color); }
.id-info-item { display: flex; flex-direction: column; align-items: center; flex: 1; min-width: 60px; }
.id-label { font-size: 11px; color: var(--text-muted); margin-bottom: 2px; }
.id-info-item span:last-child { font-size: 13px; font-weight: 600; color: var(--success); }

/* ====== Athlete Add Form ====== */
.athlete-add-form { background: var(--bg-card); border-radius: 12px; padding: 16px; border: 1px solid var(--border-color); margin-bottom: 12px; }
.btn-add-athlete { width: 100%; height: 40px; background: var(--red-primary); color: #FFF; font-size: 14px; font-weight: 600; border: none; border-radius: 10px; cursor: pointer; font-family: var(--font-main); display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 6px; transition: background .2s; }
.btn-add-athlete:active { background: var(--red-dark); }
.btn-pick-pool { width: 100%; height: 40px; background: var(--blue-primary, #3584E4); color: #FFF; font-size: 14px; font-weight: 600; border: none; border-radius: 10px; cursor: pointer; font-family: var(--font-main); display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 8px; transition: background .2s; }
.btn-pick-pool:active { background: #1A5FB4; }
.opacity-50 { opacity: 0.5; }

/* ====== Athlete Table ====== */
.athlete-table-wrapper { display: flex; flex-direction: column; gap: 8px; }
.empty-state { text-align: center; padding: 40px 20px; color: var(--text-muted); font-size: 13px; }
.athlete-row { background: var(--bg-card); border-radius: 10px; padding: 12px; border: 1px solid var(--border-color); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.ath-row-info { flex: 1; min-width: 0; }
.ath-row-name { font-size: 14px; font-weight: 600; display: block; }
.ath-row-id { font-size: 11px; color: var(--text-muted); }
.ath-row-meta { display: flex; gap: 6px; flex-wrap: wrap; }
.ath-tag { font-size: 10px; padding: 2px 8px; border-radius: 4px; background: var(--bg-input); color: var(--text-secondary); }
.ath-tag.gender-male { background: rgba(53,132,228,.2); color: #62A0EA; }
.ath-tag.gender-female { background: rgba(229,80,90,.2); color: var(--red-light); }
.ath-tag.tag-group { background: rgba(245,200,66,.15); color: var(--gold-primary); }
.ath-delete-btn { width: 30px; height: 30px; border: none; border-radius: 50%; background: transparent; color: #E8505A; font-size: 16px; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background .2s; }
.ath-delete-btn:active { background: rgba(229,80,90,.15); }

/* ====== Event Selector ====== */
.athlete-event-card { background: var(--bg-card); border-radius: 12px; border: 1px solid var(--border-color); margin-bottom: 12px; overflow: hidden; transition: border-color .2s; }
.athlete-event-card.expanded { border-color: var(--red-primary); }
.ath-event-header { padding: 12px 14px; background: var(--bg-input); display: flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; -webkit-user-select: none; transition: background .2s; }
.ath-event-header:active { background: rgba(26,26,46,.6); }
.ath-event-name { font-weight: 600; font-size: 14px; flex-shrink: 0; }
.ath-event-group { font-size: 11px; color: var(--text-secondary); flex-shrink: 0; }
.ath-event-summary { flex: 1; font-size: 11px; color: var(--text-muted); text-align: right; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ath-event-summary.has-events { color: var(--success); }
.ath-event-summary.no-events { color: var(--red-light); }
.ath-event-badge { font-size: 11px; padding: 2px 8px; border-radius: 10px; background: rgba(196,30,36,.15); color: var(--red-primary); font-weight: 600; flex-shrink: 0; }
.ath-event-arrow { flex-shrink: 0; transition: transform .25s; color: var(--text-muted); font-size: 12px; line-height: 1; }
.athlete-event-card.expanded .ath-event-arrow { transform: rotate(180deg); color: var(--red-primary); }
.ath-event-body { display: none; border-top: 1px solid var(--border-color); }
.athlete-event-card.expanded .ath-event-body { display: block; animation: fadeIn .2s; }
.event-cat-label { padding: 10px 14px 4px; font-size: 13px; font-weight: 700; color: #C41A1A; }
.event-check-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; padding: 6px 14px 10px; }
.event-check-item { display: flex; align-items: center; padding: 8px 10px; background: var(--bg-input); border: 1.5px solid var(--border-color); border-radius: 8px; cursor: pointer; font-size: 12px; color: var(--text-secondary); transition: all .2s; user-select: none; -webkit-user-select: none; }
.event-check-item.checked { border-color: var(--red-primary); background: rgba(196,30,36,.08); color: var(--text-primary); font-weight: 600; }
.event-check-item:active { transform: scale(.97); }
.event-check-item.capped { opacity: .35; pointer-events: none; border-color: var(--border-color); }

/* 「其他」类项目：选中后填写具体名称 */
.other-name-tip { padding: 12px 14px 4px; margin-top: 6px; font-size: 12px; font-weight: 600; color: var(--red-primary); border-top: 1px dashed var(--border-color); }
.other-name-row { display: flex; align-items: center; gap: 8px; padding: 6px 14px; }
/* 内联模式：紧跟所选项下方，横跨整行，视觉上归属该项 */
.other-name-inline { grid-column: 1 / -1; margin: 0 0 4px; padding-left: 22px; padding-right: 14px; border-left: 3px solid var(--red-primary); background: rgba(196,30,36,.04); border-radius: 0 0 8px 8px; }
.other-name-label { flex: 0 0 auto; font-size: 12px; color: var(--text-secondary); min-width: 92px; }
.other-name-input { flex: 1; height: 34px; padding: 0 10px; font-size: 13px; color: var(--text-primary); background: var(--bg-input); border: 1.5px solid var(--border-color); border-radius: 8px; outline: none; font-family: var(--font-main); }
.other-name-input:focus { border-color: var(--red-primary); background: #FFF; }

/* ====== Step Actions ====== */
.step-actions { display: flex; gap: 10px; margin-top: 24px; padding-bottom: 20px; }
.btn-primary { flex: 1; height: 46px; background: linear-gradient(135deg, var(--red-primary), var(--red-light)); color: #FFF; font-size: 15px; font-weight: 600; border: none; border-radius: 10px; cursor: pointer; font-family: var(--font-main); transition: transform .2s, opacity .2s; box-shadow: 0 4px 16px rgba(196,30,36,.3); }
.btn-primary:active { transform: scale(.98); }
.btn-secondary { flex: 1; height: 46px; background: transparent; color: var(--text-secondary); font-size: 15px; font-weight: 500; border: 1.5px solid var(--border-color); border-radius: 10px; cursor: pointer; font-family: var(--font-main); }
.btn-secondary:active { border-color: var(--text-muted); }
.btn-excel { flex: 1; height: 46px; background: linear-gradient(135deg, #1A7140, var(--success)); color: #FFF; font-size: 15px; font-weight: 600; border: none; border-radius: 10px; cursor: pointer; font-family: var(--font-main); display: flex; align-items: center; justify-content: center; gap: 6px; box-shadow: 0 4px 16px rgba(38,162,105,.3); }
.btn-excel:active { transform: scale(.98); }
.btn-draft { flex: 1; height: 44px; background: transparent; color: var(--text-secondary); font-size: 14px; border: 1.5px solid var(--border-color); border-radius: 10px; cursor: pointer; font-family: var(--font-main); }
.btn-draft:active { border-color: var(--text-muted); }
.btn-submit { height: 46px; background: linear-gradient(135deg, var(--gold-primary), #FFD866); color: #1A1A2E; font-size: 16px; font-weight: 700; border: none; border-radius: 10px; cursor: pointer; font-family: var(--font-main); box-shadow: 0 4px 16px rgba(245,200,66,.3); letter-spacing: 1px; transition: transform .2s; }
.btn-submit:active { transform: scale(.98); }

/* ====== Summary ====== */
.summary-section { margin-bottom: 20px; }
.summary-section-title { font-size: 13px; font-weight: 600; color: var(--gold-primary); margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1px solid var(--border-color); }
.summary-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.summary-table td { padding: 6px 0; vertical-align: top; }
.sum-label { color: var(--text-muted); width: 80px; white-space: nowrap; padding-right: 12px; }
.sum-athlete { background: var(--bg-card); border-radius: 8px; padding: 10px 12px; margin-bottom: 8px; border: 1px solid var(--border-color); }
.sum-ath-name { font-weight: 600; font-size: 13px; margin-bottom: 4px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sum-ath-events { font-size: 12px; color: var(--text-secondary); }

/* ====== Picker Modal ====== */
.modal-overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,.7); display: none; align-items: center; justify-content: center; z-index: 999; animation: fadeIn .3s; }
.modal-overlay.show { display: flex; }
.modal-content { background: var(--bg-card); border-radius: 20px; padding: 24px; text-align: center; max-width: 300px; width: 85%; border: 1px solid var(--border-color); animation: slideUp .35s; }
.modal-picker { max-width: 340px; max-height: 70vh; overflow-y: auto; padding: 20px; text-align: left; }
.modal-title { font-size: 16px; font-weight: 700; margin-bottom: 16px; color: var(--text-primary); }
.modal-text { font-size: 13px; color: var(--text-secondary); line-height: 1.6; margin-bottom: 24px; }
.modal-btn { width: 100%; height: 44px; background: var(--red-primary); color: #FFF; font-size: 15px; font-weight: 600; border: none; border-radius: 10px; cursor: pointer; font-family: var(--font-main); }
.modal-btn:active { background: var(--red-dark); }
.modal-btn-cancel { background: transparent; border: 1px solid var(--border-color); color: var(--text-muted); margin-top: 10px; }

.picker-item { padding: 14px 16px; background: var(--bg-input); border-radius: 10px; margin-bottom: 8px; cursor: pointer; border: 1px solid var(--border-color); transition: border-color .2s; }
.picker-item:active { border-color: var(--red-primary); }
.picker-item-name { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.picker-item-meta { font-size: 11px; color: var(--text-muted); }

/* ====== 通用弹窗（通知/详情，id=modal-mask/modal-body） ====== */
.modal-mask { position: fixed; inset: 0; background: rgba(0,0,0,.55); display: none; align-items: center; justify-content: center; z-index: 300; padding: 16px; }
.modal-mask.show { display: flex; }
.modal { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: 14px; width: 100%; max-width: 520px; max-height: 86vh; overflow: auto; padding: 18px; color: var(--text-primary); }
.modal h3 { margin: 0 0 12px; font-size: 16px; color: var(--text-primary); }
.modal .btn { width: 100%; height: 42px; background: var(--red-primary); color: #FFF; border: none; border-radius: 10px; font-size: 14px; font-weight: 600; cursor: pointer; font-family: var(--font-main); margin-top: 14px; }
.modal .btn.ghost { background: transparent; border: 1px solid var(--border-color); color: var(--text-secondary); margin-top: 8px; }
.empty { text-align: center; padding: 30px 20px; color: var(--text-muted); font-size: 13px; }

/* ====== 首页通知横幅 + 通知详情卡片 ====== */
.home-notice { display: flex; align-items: center; gap: 8px; margin: 10px 12px 0; padding: 10px 14px; background: linear-gradient(135deg, rgba(243,115,41,.18), rgba(245,200,66,.14)); border: 1px solid rgba(243,115,41,.4); border-radius: 10px; cursor: pointer; font-size: 13px; }
.home-notice .hn-tag { background: var(--warning); color: #fff; font-size: 11px; padding: 2px 8px; border-radius: 8px; font-weight: 600; flex-shrink: 0; }
.home-notice .hn-text { flex: 1; font-weight: 600; color: var(--gold-primary, #F5C842); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.home-notice .hn-arrow { color: var(--warning); font-weight: 700; flex-shrink: 0; }
.notice-list { display: flex; flex-direction: column; gap: 8px; }
.notice-item { border: 1px solid var(--border-color); border-radius: 10px; overflow: hidden; background: var(--bg-card); }
.notice-row { display: flex; align-items: center; gap: 10px; padding: 12px 14px; cursor: pointer; }
.notice-row:active { background: rgba(255,255,255,.04); }
.notice-row-main { flex: 1; min-width: 0; }
.notice-row-title { font-weight: 700; font-size: 14px; color: var(--text-primary); margin-bottom: 3px; }
.notice-row-preview { font-size: 12px; color: var(--text-secondary); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.notice-row-meta { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.notice-date { font-size: 11px; color: var(--text-muted); }
.notice-chev { color: var(--text-muted); font-size: 16px; transition: transform .2s; line-height: 1; }
.notice-item.open .notice-chev { transform: rotate(180deg); }
.notice-detail { padding: 12px 14px; font-size: 13px; color: var(--text-secondary); line-height: 1.65; white-space: pre-wrap; border-top: 1px solid var(--border-color); }

/* ====== Toast ====== */
#toast { position: fixed; bottom: 100px; left: 50%; transform: translateX(-50%) translateY(20px); background: rgba(26,26,46,.95); color: #FFF; padding: 10px 24px; border-radius: 8px; font-size: 13px; z-index: 9999; opacity: 0; transition: opacity .3s, transform .3s; pointer-events: none; border: 1px solid var(--border-color); white-space: nowrap; }
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ====== Animations ====== */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* ====== Scrollbar ====== */
.page::-webkit-scrollbar { width: 0; display: none; }

/* ====== Responsive (Tablet) ====== */
@media (min-width: 768px) {
  .page { max-width: 420px; left: 50%; transform: translateX(calc(-50% + 100%)); box-shadow: 0 0 40px rgba(0,0,0,.5); }
  .page.active { transform: translateX(-50%); }
  .page.slide-out-left { transform: translateX(calc(-50% - 30%)); }
  body { background: #000; display: flex; justify-content: center; }
  /* 桌面端：备案 footer 约束在 420px 手机列内，与页面浮层对齐 */
  .site-footer { max-width: 420px; }
}

/* ====== Article Page (规程/信息详情) ====== */
.article-page { padding: 16px 20px 80px; }
.rules-title { font-size: 18px; font-weight: 700; text-align: center; margin-bottom: 20px; color: var(--gold-primary); line-height: 1.5; }
.rules-h2 { font-size: 15px; font-weight: 700; margin-top: 18px; margin-bottom: 8px; color: var(--red-light); padding-left: 10px; border-left: 3px solid var(--red-primary); }
.rules-h3 { font-size: 14px; font-weight: 600; margin-top: 12px; margin-bottom: 6px; color: var(--text-primary); }
.article-page p { font-size: 13px; line-height: 1.8; color: var(--text-secondary); margin-bottom: 6px; }
.rules-indent { padding-left: 20px; }
.rules-indent2 { padding-left: 40px; }

/* ====== Info List ====== */
.info-list-page { padding: 12px 16px 80px; }
.info-item { background: var(--bg-card); border-radius: 12px; padding: 14px 16px; margin-bottom: 10px; border: 1px solid var(--border-color); cursor: pointer; transition: transform .2s, border-color .2s; display: flex; gap: 12px; align-items: flex-start; }
.info-item:active { transform: scale(.98); border-color: var(--red-primary); }
.info-tag { font-size: 10px; font-weight: 600; padding: 3px 8px; border-radius: 4px; flex-shrink: 0; color: #FFF; }
.info-body { flex: 1; min-width: 0; }
.info-title { font-size: 14px; font-weight: 600; line-height: 1.4; margin-bottom: 6px; }
.info-date { font-size: 11px; color: var(--text-muted); }

/* ====== Schedule Page ====== */
.schedule-select-bar { padding: 10px 16px; background: var(--bg-card); border-bottom: 1px solid var(--border-color); }
.comp-select { width: 100%; padding: 10px 12px; font-size: 15px; border-radius: 10px; border: 1px solid var(--border-color); background: var(--bg-input); color: var(--text-primary); appearance: none; -webkit-appearance: none; }
.schedule-page { padding: 16px 16px 80px; }
.schedule-day-card { background: var(--bg-card); border-radius: 14px; margin-bottom: 16px; border: 1px solid var(--border-color); overflow: hidden; }
.schedule-day-header { display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: var(--bg-input); }
.schedule-day-date { font-size: 16px; font-weight: 700; }
.schedule-day-weekday { font-size: 12px; color: var(--text-muted); }
.schedule-sessions { padding: 8px; }
.schedule-session { background: var(--bg-input); border-radius: 10px; margin: 6px; padding: 12px 14px; cursor: pointer; transition: all .2s; border: 1px solid transparent; }
.schedule-session:active { border-color: var(--red-primary); }
.schedule-session-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 4px; }
.schedule-session-label { font-size: 14px; font-weight: 600; }
.schedule-session-time { font-size: 12px; color: var(--gold-primary); }
.schedule-session-count { font-size: 11px; color: var(--text-muted); }
.schedule-session-events { font-size: 12px; color: var(--text-secondary); line-height: 1.5; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ====== Schedule Detail ====== */
.schedule-detail-page { padding: 16px 16px 80px; }
.event-item-card { background: var(--bg-card); border-radius: 12px; padding: 14px 16px; margin-bottom: 10px; border: 1px solid var(--border-color); cursor: pointer; transition: transform .2s, border-color .2s; display: flex; align-items: center; gap: 12px; }
.event-item-card:active { transform: scale(.98); border-color: var(--red-primary); }
.event-time { font-size: 12px; font-weight: 600; color: var(--gold-primary); width: 48px; text-align: center; flex-shrink: 0; }
.event-info { flex: 1; min-width: 0; }
.event-name { font-size: 14px; font-weight: 600; margin-bottom: 2px; }
.event-meta { font-size: 11px; color: var(--text-muted); }
.event-type-tag { font-size: 10px; padding: 2px 8px; border-radius: 4px; flex-shrink: 0; }
.event-type-tag.competition { background: rgba(196,30,36,.15); color: var(--red-light); }
.event-type-tag.ceremony { background: rgba(245,200,66,.15); color: var(--gold-primary); }
.event-type-tag.administrative { background: rgba(102,102,119,.2); color: var(--text-muted); }
.event-type-tag.meeting { background: rgba(53,132,228,.15); color: #62A0EA; }
.event-card-right { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex-shrink: 0; }
.event-view-hint { font-size: 11px; color: var(--red-primary); font-weight: 600; white-space: nowrap; }

/* ====== 赛程项目 → 参赛运动员 弹窗（秩序册表格样式） ====== */
.roster-title { font-size: 16px; font-weight: 700; text-align: center; margin-bottom: 14px; color: var(--text-primary); line-height: 1.4; }
.roster-table { width: 100%; border-collapse: collapse; }
.roster-table thead th { font-size: 12px; color: var(--text-muted); font-weight: 600; text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--border-color); background: transparent; }
.roster-table tbody tr { border-bottom: 1px solid rgba(255,255,255,.04); transition: background .15s; }
.roster-table tbody tr:last-child { border-bottom: none; }
.roster-table tbody tr:active { background: rgba(255,255,255,.04); }
.roster-table td { padding: 10px 10px; font-size: 14px; color: var(--text-primary); vertical-align: middle; }
.col-num { width: 42px; text-align: center; color: var(--text-muted); font-weight: 600; font-size: 13px !important; }
.col-name { font-weight: 600; min-width: 60px; }
.col-team { color: var(--text-muted); font-size: 13px !important; }
.col-event { color: #E0A458; font-size: 13px !important; white-space: nowrap; }

/* 集体项目名册表格：序号 | 代表队 | 人员名单 */
.roster-collective .col-team { font-weight: 600; color: var(--text-primary); font-size: 14px !important; min-width: 140px; }
.col-members { font-size: 13px !important; color: var(--text-secondary); line-height: 1.6; word-break: break-all; }

.modal-close-btn { width: 100%; height: 42px; background: var(--red-primary); color: #FFF; border: none; border-radius: 10px; font-size: 14px; font-weight: 600; cursor: pointer; font-family: var(--font-main); margin-top: 16px; }
.modal-close-btn:active { background: var(--red-dark); }
.event-arrow { color: var(--text-muted); font-size: 16px; flex-shrink: 0; }

/* ====== Order Athletes ====== */
.order-athletes-page { padding: 16px 16px 80px; }
.order-athletes-header { background: var(--bg-card); border-radius: 12px; padding: 16px; margin-bottom: 12px; border: 1px solid var(--border-color); }
.order-athletes-header h3 { font-size: 15px; font-weight: 700; margin-bottom: 8px; }
.order-athletes-header p { font-size: 12px; color: var(--text-muted); margin-bottom: 2px; }
.athlete-order-row { display: flex; align-items: center; gap: 12px; background: var(--bg-card); border-radius: 10px; padding: 12px 16px; margin-bottom: 8px; border: 1px solid var(--border-color); transition: border-color .2s; }
.athlete-order-row:active { border-color: var(--red-primary); }
.order-num { width: 32px; height: 32px; border-radius: 50%; background: linear-gradient(135deg, var(--red-primary), var(--red-dark)); color: #FFF; font-size: 14px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.order-athlete-info { flex: 1; }
.order-athlete-name { font-size: 14px; font-weight: 600; }
.order-athlete-team { font-size: 12px; color: var(--text-muted); }
.order-athlete-id { font-size: 11px; color: var(--text-muted); background: var(--bg-input); padding: 2px 8px; border-radius: 4px; }

/* ====== Results Page ====== */
.results-page { padding: 16px 16px 80px; }
.results-upload-btn { width: 100%; height: 48px; background: linear-gradient(135deg, var(--gold-primary), var(--gold-light)); color: #1A1A2E; font-size: 15px; font-weight: 700; border: none; border-radius: 12px; cursor: pointer; font-family: var(--font-main); display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 16px; box-shadow: 0 4px 16px rgba(245,200,66,.2); }
.results-upload-btn:active { transform: scale(.98); }
.result-card { background: var(--bg-card); border-radius: 12px; padding: 14px 16px; margin-bottom: 10px; border: 1px solid var(--border-color); display: flex; align-items: center; gap: 12px; }
.result-card-info { flex: 1; }
.result-card-title { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.result-card-meta { font-size: 11px; color: var(--text-muted); }
.result-status { font-size: 11px; padding: 4px 10px; border-radius: 8px; font-weight: 600; }
.result-status.pending { background: rgba(102,102,119,.2); color: var(--text-muted); }
.result-status.uploaded { background: rgba(38,162,105,.2); color: var(--success); }
.result-view-btn { font-size: 12px; color: var(--gold-primary); padding: 6px 14px; border: 1px solid var(--gold-primary); border-radius: 8px; cursor: pointer; }

/* ====== My Page ====== */
.my-page { padding-bottom: 0; }
.my-header { background: linear-gradient(135deg, var(--red-primary) 0%, var(--red-dark) 100%); padding: 24px 20px 28px; position: relative; overflow: hidden; }
.my-header::after { content: '武'; position: absolute; right: 16px; top: 50%; transform: translateY(-50%); font-size: 80px; font-weight: 900; color: rgba(255,255,255,.04); pointer-events: none; }
.my-avatar-row { display: flex; align-items: center; gap: 14px; position: relative; z-index: 1; }
.my-avatar { width: 60px; height: 60px; border-radius: 50%; background: var(--bg-card); border: 2px solid rgba(255,255,255,.3); display: flex; align-items: center; justify-content: center; font-size: 24px; }
.my-name-row { flex: 1; }
.my-nickname { font-size: 18px; font-weight: 700; color: #FFF; }
.my-role { font-size: 12px; color: rgba(255,255,255,.7); margin-top: 2px; }
.my-login-btn { background: rgba(255,255,255,.15); color: #FFF; font-size: 13px; padding: 8px 18px; border-radius: 20px; border: 1px solid rgba(255,255,255,.3); cursor: pointer; font-family: var(--font-main); }
.my-login-btn:active { background: rgba(255,255,255,.25); }
.my-stats { display: flex; gap: 0; margin-top: 18px; position: relative; z-index: 1; }
.my-stat-item { flex: 1; text-align: center; }
.my-stat-clickable { cursor: pointer; transition: transform .15s; }
.my-stat-clickable:active { transform: scale(0.92); opacity: .8; }
.my-stat-num { font-size: 20px; font-weight: 700; color: var(--gold-primary); }
.my-stat-label { font-size: 11px; color: rgba(255,255,255,.6); margin-top: 2px; }
.my-section { padding: 16px; }
.my-section-title { font-size: 13px; font-weight: 600; color: var(--text-muted); margin-bottom: 10px; padding-left: 4px; }
.my-menu-group { background: var(--bg-card); border-radius: 12px; overflow: hidden; border: 1px solid var(--border-color); }
.my-menu-item { display: flex; align-items: center; gap: 12px; padding: 14px 16px; cursor: pointer; border-bottom: 1px solid var(--border-color); transition: background .2s; }
.my-menu-item:last-child { border-bottom: none; }
.my-menu-item:active { background: var(--bg-input); }
.my-menu-icon { width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; }
.my-menu-text { flex: 1; font-size: 14px; font-weight: 500; }
.my-menu-arrow { color: var(--text-muted); font-size: 14px; }
.my-menu-badge { font-size: 11px; color: #FFF; background: var(--red-primary); padding: 2px 8px; border-radius: 10px; margin-right: 8px; }

/* ====== Login Prompt ====== */
.my-login-prompt { text-align: center; padding: 48px 24px 24px; }
.my-login-icon { font-size: 40px; opacity: .4; margin-bottom: 16px; }
.my-login-text { font-size: 14px; font-weight: 600; color: var(--text-secondary); margin-bottom: 8px; }
.my-login-sub { font-size: 12px; color: var(--text-muted); line-height: 1.6; }

/* ====== Role Picker ====== */
.role-picker-subtitle { font-size: 12px; color: var(--text-muted); margin-bottom: 16px; line-height: 1.5; }
.role-item { display: flex; align-items: center; gap: 14px; padding: 16px; background: var(--bg-input); border-radius: 12px; margin-bottom: 10px; cursor: pointer; border: 1.5px solid var(--border-color); transition: border-color .2s, transform .2s; }
.role-item:active { transform: scale(.98); border-color: var(--red-primary); }
.role-item.role-current { border-color: var(--success); background: rgba(38,162,105,.06); }
.role-icon { width: 44px; height: 44px; border-radius: 12px; background: var(--bg-card); display: flex; align-items: center; justify-content: center; font-size: 22px; flex-shrink: 0; border: 1px solid var(--border-color); }
.role-info { flex: 1; min-width: 0; }
.role-label { font-size: 15px; font-weight: 600; margin-bottom: 2px; }
.role-desc { font-size: 11px; color: var(--text-muted); }
.role-arrow { color: var(--text-muted); font-size: 16px; flex-shrink: 0; }
.role-current-tag { font-size: 11px; color: var(--success); background: rgba(38,162,105,.15); padding: 3px 10px; border-radius: 8px; font-weight: 600; flex-shrink: 0; }

/* ====== Score Results Page (Structured) ====== */
.results-summary-bar { text-align: center; font-size: 12px; color: var(--text-muted); padding: 8px 0 16px; }
.comp-banner { background: linear-gradient(135deg, rgba(196,30,36,.08), rgba(245,200,66,.08)); border-left: 3px solid var(--red-primary); padding: 10px 14px; border-radius: 8px; font-size: 13px; font-weight: 600; color: var(--text-primary); margin-bottom: 12px; }
.score-date-group { margin-bottom: 20px; }
.score-date-header { font-size: 14px; font-weight: 700; color: var(--gold-primary); padding: 8px 4px 12px; border-bottom: 1px solid var(--border-color); margin-bottom: 12px; }
.score-session-label { font-size: 12px; color: var(--text-muted); padding: 4px 4px 8px; font-weight: 600; }
.score-result-card { background: var(--bg-card); border-radius: 12px; padding: 14px 16px; margin-bottom: 10px; border: 1px solid var(--border-color); cursor: pointer; transition: border-color .2s, transform .2s; }
.score-result-card:active { transform: scale(.98); border-color: var(--red-primary); }
.score-card-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 12px; }
.score-card-event { font-size: 14px; font-weight: 600; flex: 1; }
.score-card-meta { font-size: 11px; color: var(--text-muted); flex-shrink: 0; margin-left: 8px; }
.score-card-top3 { display: flex; gap: 8px; margin-bottom: 10px; }
.score-podium { flex: 1; text-align: center; background: var(--bg-input); border-radius: 10px; padding: 12px 8px; position: relative; }
.score-podium.rank-1 { background: linear-gradient(180deg, rgba(245,200,66,.12) 0%, transparent 100%); border: 1px solid rgba(245,200,66,.3); }
.score-podium.rank-2 { background: linear-gradient(180deg, rgba(192,192,192,.08) 0%, transparent 100%); border: 1px solid rgba(192,192,192,.2); }
.score-podium.rank-3 { background: linear-gradient(180deg, rgba(205,127,50,.08) 0%, transparent 100%); border: 1px solid rgba(205,127,50,.2); }
.podium-rank { font-size: 18px; font-weight: 900; margin-bottom: 6px; }
.podium-name { font-size: 13px; font-weight: 600; margin-bottom: 2px; }
.podium-team { font-size: 10px; color: var(--text-muted); margin-bottom: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.podium-score { font-size: 15px; font-weight: 700; color: var(--gold-primary); }
.score-card-footer { text-align: center; padding-top: 8px; border-top: 1px solid var(--border-color); }
.score-view-detail { font-size: 12px; color: var(--text-muted); }

/* ====== Score Detail Page ====== */
.score-detail-page { padding: 16px 16px 80px; }
.score-detail-header { background: var(--bg-card); border-radius: 12px; padding: 16px; margin-bottom: 16px; border: 1px solid var(--border-color); }
.score-detail-header h3 { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.score-detail-meta { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.dot-sep { color: var(--border-color); }
.score-table-wrapper { background: var(--bg-card); border-radius: 12px; overflow: hidden; border: 1px solid var(--border-color); }
.score-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.score-table thead { background: var(--bg-input); }
.score-table th { padding: 12px 8px; font-size: 12px; font-weight: 600; color: var(--text-muted); text-align: center; border-bottom: 1px solid var(--border-color); }
.score-table th.col-rank { width: 60px; }
.score-table th.col-name { text-align: left; }
.score-table th.col-team { text-align: left; }
.score-table th.col-score { width: 70px; }
.score-table td { padding: 12px 8px; text-align: center; border-bottom: 1px solid var(--border-color); }
.score-table td.col-name { text-align: left; font-weight: 600; }
.score-table td.col-team { text-align: left; font-size: 12px; color: var(--text-secondary); }
.score-table td.col-score { font-weight: 700; color: var(--gold-primary); }
.score-table tbody tr:last-child td { border-bottom: none; }
.score-table tbody tr.gold { background: rgba(245,200,66,.06); }
.score-table tbody tr.silver { background: rgba(192,192,192,.04); }
.score-table tbody tr.bronze { background: rgba(205,127,50,.04); }
.rank-badge { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; font-size: 13px; font-weight: 700; background: var(--bg-input); }
.rank-badge.gold { background: linear-gradient(135deg, #F5C842, #FFD866); color: #1A1A2E; }
.rank-badge.silver { background: linear-gradient(135deg, #C0C0C0, #E0E0E0); color: #1A1A2E; }
.rank-badge.bronze { background: linear-gradient(135deg, #CD7F32, #E89B5A); color: #FFF; }
.score-detail-profile-link { display: flex; justify-content: space-between; align-items: center; background: var(--bg-card); border-radius: 12px; padding: 14px 16px; margin-top: 12px; border: 1px solid var(--red-primary); cursor: pointer; font-size: 14px; font-weight: 600; color: var(--gold-primary); }

/* ====== Athlete Verify Page ====== */
.verify-page { padding: 16px 16px 80px; }
.verify-intro { text-align: center; padding: 24px 16px 20px; }
.verify-icon { font-size: 48px; margin-bottom: 12px; }
.verify-title-text { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.verify-desc { font-size: 13px; color: var(--text-secondary); line-height: 1.6; }
.verify-form { background: var(--bg-card); border-radius: 12px; padding: 20px 16px; margin-bottom: 16px; border: 1px solid var(--border-color); }
.verify-submit-btn { width: 100%; margin-top: 16px; height: 48px; }
.verify-tips { background: var(--bg-card); border-radius: 12px; padding: 16px; border: 1px solid var(--border-color); }
.verify-tip-title { font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 8px; }
.verify-tip-item { font-size: 12px; color: var(--text-muted); line-height: 1.8; }

/* 测试运动员列表 */
.verify-test-section { background: var(--bg-card); border-radius: 12px; padding: 16px; margin-bottom: 16px; border: 1px dashed var(--gold-primary); }
.verify-test-title { font-size: 13px; font-weight: 700; color: var(--gold-primary); margin-bottom: 4px; }
.verify-test-desc { font-size: 11px; color: var(--text-muted); margin-bottom: 14px; line-height: 1.5; }
.verify-group-label { font-size: 11px; font-weight: 700; color: var(--text-secondary); padding: 8px 0 4px 4px; }
.verify-athlete-card { display: flex; align-items: center; gap: 8px; padding: 10px 12px; background: var(--bg-page); border-radius: 8px; margin-bottom: 6px; cursor: pointer; transition: all .2s; border: 1px solid transparent; }
.verify-athlete-card:hover { border-color: var(--gold-primary); background: rgba(245,200,66,.06); }
.verify-athlete-card:active { transform: scale(.98); }
.verify-athlete-info { flex: 1; min-width: 0; }
.verify-athlete-name { font-size: 14px; font-weight: 600; display: block; }
.verify-athlete-meta { font-size: 11px; color: var(--text-muted); }
.verify-athlete-idcard { font-size: 12px; color: var(--text-secondary); font-family: 'Courier New', monospace; white-space: nowrap; }
.verify-athlete-action { font-size: 12px; color: var(--red-primary); font-weight: 600; white-space: nowrap; padding: 4px 10px; border: 1px solid var(--red-primary); border-radius: 6px; transition: all .2s; }
.verify-athlete-card:hover .verify-athlete-action { background: var(--red-primary); color: #FFF; }

/* ====== Parent Child Verification ====== */
.verify-child-section { background: var(--bg-card); border-radius: 12px; padding: 16px; margin-bottom: 16px; border: 1px solid rgba(53,132,228,.3); }
.verify-child-card { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--bg-page); border-radius: 8px; margin-bottom: 6px; }
.verify-child-card:last-child { margin-bottom: 0; }
.verify-child-info { flex: 1; min-width: 0; }
.verify-child-name { font-size: 14px; font-weight: 600; display: block; }
.verify-child-id { font-size: 11px; color: var(--text-muted); }
.verify-child-remove { font-size: 12px; color: var(--red-primary); cursor: pointer; padding: 4px 10px; border: 1px solid var(--border-color); border-radius: 6px; white-space: nowrap; transition: all .15s; }
.verify-child-remove:active { background: var(--red-primary); color: #FFF; border-color: var(--red-primary); }

/* ====== Child List Modal ====== */
.child-card { display: flex; align-items: center; gap: 14px; padding: 16px; background: var(--bg-card); border-radius: 10px; margin-bottom: 8px; cursor: pointer; border: 1px solid var(--border-color); transition: all .15s; }
.child-card:active { background: var(--bg-input); transform: scale(.98); }
.child-card-avatar { width: 44px; height: 44px; border-radius: 50%; background: rgba(53,132,228,.12); display: flex; align-items: center; justify-content: center; font-size: 24px; flex-shrink: 0; }
.child-card-info { flex: 1; }
.child-card-name { font-size: 15px; font-weight: 700; margin-bottom: 2px; }
.child-card-meta { font-size: 12px; color: var(--text-muted); }
.child-card-arrow { font-size: 16px; color: var(--text-muted); }
.child-add-btn { text-align: center; padding: 14px; background: var(--bg-card); border-radius: 10px; border: 1px dashed var(--border-color); color: var(--blue-primary); font-size: 14px; font-weight: 600; cursor: pointer; transition: all .15s; margin-top: 8px; }
.child-add-btn:active { background: var(--bg-input); }

/* ====== Athlete Profile Page ====== */
.profile-page { padding-bottom: 0; }
.profile-header { background: linear-gradient(135deg, var(--red-primary) 0%, var(--red-dark) 100%); padding: 28px 20px 24px; display: flex; align-items: center; gap: 16px; position: relative; overflow: hidden; }
.profile-header::after { content: '武'; position: absolute; right: 16px; top: 50%; transform: translateY(-50%); font-size: 80px; font-weight: 900; color: rgba(255,255,255,.04); pointer-events: none; }
.profile-avatar { width: 64px; height: 64px; border-radius: 50%; background: var(--bg-card); border: 2px solid rgba(255,255,255,.3); display: flex; align-items: center; justify-content: center; font-size: 28px; flex-shrink: 0; position: relative; z-index: 1; }
.profile-name-row { position: relative; z-index: 1; }
.profile-name { font-size: 20px; font-weight: 700; color: #FFF; margin-bottom: 6px; }
.profile-meta { display: flex; gap: 6px; flex-wrap: wrap; }
.profile-tag { font-size: 11px; color: rgba(255,255,255,.8); background: rgba(255,255,255,.15); padding: 2px 8px; border-radius: 6px; }
.profile-medal-bar { display: flex; gap: 0; padding: 16px; background: var(--bg-card); border-bottom: 1px solid var(--border-color); }
.medal-item { flex: 1; text-align: center; position: relative; }
.medal-item:not(:last-child)::after { content: ''; position: absolute; right: 0; top: 20%; height: 60%; width: 1px; background: var(--border-color); }
.medal-icon { font-size: 16px; font-weight: 900; margin-bottom: 4px; }
.medal-item.gold .medal-icon { color: #F5C842; }
.medal-item.silver .medal-icon { color: #C0C0C0; }
.medal-item.bronze .medal-icon { color: #CD7F32; }
.medal-num { font-size: 20px; font-weight: 700; }
.medal-label { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.profile-stats-bar { display: flex; gap: 0; padding: 14px 16px; background: var(--bg-card); border-bottom: 1px solid var(--border-color); }
.profile-stat-item { flex: 1; text-align: center; }
.profile-stat-num { font-size: 20px; font-weight: 700; color: var(--gold-primary); }
.profile-stat-label { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.profile-section-title { font-size: 14px; font-weight: 700; padding: 20px 16px 12px; color: var(--text-secondary); }
.profile-timeline { padding: 0 16px; }
.timeline-item { position: relative; padding-left: 28px; padding-bottom: 20px; }
.timeline-item.last { padding-bottom: 0; }
.timeline-dot { position: absolute; left: 4px; top: 4px; width: 12px; height: 12px; border-radius: 50%; background: var(--red-primary); border: 2px solid var(--bg-dark); z-index: 1; }
.timeline-line { position: absolute; left: 9px; top: 18px; width: 2px; height: calc(100% - 12px); background: var(--border-color); }
.timeline-item.last .timeline-line { display: none; }
.timeline-card { background: var(--bg-card); border-radius: 12px; padding: 14px 16px; border: 1px solid var(--border-color); }
.timeline-card-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 6px; }
.timeline-comp-name { font-size: 13px; font-weight: 600; flex: 1; line-height: 1.4; }
.timeline-comp-date { font-size: 11px; color: var(--text-muted); flex-shrink: 0; margin-left: 8px; }
.timeline-comp-team { font-size: 11px; color: var(--text-muted); margin-bottom: 10px; }
.timeline-scores { display: flex; flex-direction: column; gap: 6px; }
.timeline-score-row { display: flex; justify-content: space-between; align-items: center; background: var(--bg-input); border-radius: 8px; padding: 8px 12px; }
.timeline-score-row.gold { border-left: 3px solid #F5C842; }
.timeline-score-row.silver { border-left: 3px solid #C0C0C0; }
.timeline-score-row.bronze { border-left: 3px solid #CD7F32; }
.tsr-event { font-size: 12px; font-weight: 500; flex: 1; }
.tsr-result { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.tsr-rank { font-size: 12px; font-weight: 700; }
.tsr-rank.gold { color: #F5C842; }
.tsr-rank.silver { color: #C0C0C0; }
.tsr-rank.bronze { color: #CD7F32; }
.tsr-score { font-size: 12px; color: var(--text-muted); }

/* ====== Score All-Rows Table (shows all ranks in card) ====== */
.score-all-rows { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--border-color); }
.score-table-row { display: flex; align-items: center; padding: 7px 10px; border-radius: 6px; gap: 8px; font-size: 12px; }
.score-table-row:nth-child(even) { background: var(--bg-input); }
.score-table-row.gold { background: rgba(245,200,66,.08); }
.score-table-row.silver { background: rgba(192,192,192,.08); }
.score-table-row.bronze { background: rgba(205,127,50,.08); }
.score-row-rank { font-weight: 700; min-width: 28px; text-align: center; color: var(--text-muted); }
.score-row-rank.gold { color: #F5C842; }
.score-row-rank.silver { color: #C0C0C0; }
.score-row-rank.bronze { color: #CD7F32; }
.score-row-name { flex: 1; font-weight: 500; }
.score-row-team { color: var(--text-muted); font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100px; }
.score-row-score { font-weight: 600; min-width: 48px; text-align: right; color: var(--gold-primary); }

/* ====== Filter Toggle Bar (我的/全部切换) ====== */
.filter-toggle-bar { display: flex; margin: 12px 16px; background: var(--bg-card); border-radius: 10px; padding: 3px; border: 1px solid var(--border-color); }
.filter-toggle { flex: 1; text-align: center; padding: 8px 0; font-size: 13px; font-weight: 600; color: var(--text-muted); border-radius: 8px; cursor: pointer; transition: all .2s; }
.filter-toggle.active { background: var(--red-primary); color: #FFF; }
.filter-info { font-size: 11px; color: var(--text-muted); text-align: center; padding: 4px 0 6px; }

/* ====== Registration / Athlete Detail Cards (modal) ====== */
.reg-detail-card { background: var(--bg-page); border-radius: 10px; padding: 14px; margin-bottom: 10px; text-align: left; }
.reg-detail-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.reg-detail-team { font-size: 15px; font-weight: 700; color: var(--text-primary); }
.reg-detail-status { font-size: 11px; color: var(--success); background: rgba(38,162,105,.12); padding: 2px 10px; border-radius: 8px; font-weight: 600; }
.reg-detail-status.reg-status-pending { color: #f5a623; background: rgba(245,166,35,.16); }
.reg-detail-status.reg-status-submitted { color: var(--text-muted); background: rgba(142,142,147,.14); }
.reg-detail-tag { font-size: 11px; color: var(--red-primary); background: rgba(196,30,36,.1); padding: 2px 10px; border-radius: 8px; font-weight: 600; }
.reg-detail-meta { font-size: 12px; color: var(--text-muted); margin-bottom: 8px; }
.reg-detail-row { font-size: 12px; color: var(--text-secondary); margin-bottom: 3px; }
.reg-detail-stats { font-size: 11px; color: var(--text-muted); margin-top: 6px; padding-top: 6px; border-top: 1px dashed var(--border-color); display: flex; gap: 6px; align-items: center; }
.reg-detail-actions { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 8px; }
.btn-edit-reg { background: var(--red-primary); color: #FFF; border: none; padding: 8px 16px; border-radius: 8px; font-size: 13px; font-weight: 600; cursor: pointer; flex: 1; }
.reg-detail-events { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.reg-event-tag { font-size: 10px; background: rgba(245,200,66,.12); color: var(--gold-primary); padding: 2px 8px; border-radius: 4px; }
.medal-tag-gold { background: rgba(245,200,66,.18); color: #B8860B; }
.medal-tag-silver { background: rgba(192,192,192,.18); color: #808080; }
.medal-tag-bronze { background: rgba(205,127,50,.18); color: #8B4513; }

/* ====== Medal Summary Bar (stats detail modal) ====== */
.medal-summary-bar { display: flex; gap: 8px; margin-bottom: 12px; }
.medal-summary-item { flex: 1; text-align: center; padding: 10px 4px; border-radius: 10px; font-size: 15px; font-weight: 700; }
.medal-summary-item.medal-gold { background: rgba(245,200,66,.15); color: #B8860B; }
.medal-summary-item.medal-silver { background: rgba(192,192,192,.15); color: #666; }
.medal-summary-item.medal-bronze { background: rgba(205,127,50,.15); color: #8B4513; }
.medal-summary-item.medal-total { background: rgba(196,30,36,.1); color: var(--red-primary); }
.medal-card-gold { border-left: 3px solid #F5C842; }
.medal-card-silver { border-left: 3px solid #C0C0C0; }
.medal-card-bronze { border-left: 3px solid #CD7F32; }

/* ====== Profile Medal Detail ====== */
.profile-medal-detail { padding: 0 16px 16px; }
.medal-detail-row { display: flex; align-items: center; padding: 10px 12px; background: var(--bg-card); border-radius: 8px; margin-bottom: 6px; gap: 10px; border: 1px solid var(--border-color); font-size: 12px; }
.medal-detail-row.gold { border-left: 3px solid #F5C842; }
.medal-detail-row.silver { border-left: 3px solid #C0C0C0; }
.medal-detail-row.bronze { border-left: 3px solid #CD7F32; }
.medal-detail-label { font-weight: 700; min-width: 60px; flex-shrink: 0; }
.medal-detail-event { flex: 1; font-weight: 500; }
.medal-detail-comp { font-size: 10px; color: var(--text-muted); white-space: nowrap; }
.medal-detail-score { font-weight: 600; color: var(--gold-primary); flex-shrink: 0; }

/* ====== Clickable Profile Stats ====== */
.medal-item { cursor: pointer; transition: transform .15s; }
.medal-item:active { transform: scale(.95); }
.profile-stat-item { cursor: pointer; transition: transform .15s; }
.profile-stat-item:active { transform: scale(.95); }
.profile-stat-item:hover .profile-stat-num { color: var(--red-primary); }

/* ====== 手机验证码登录页 ====== */
.login-page-wrapper {
  display: flex; align-items: center; justify-content: center;
  min-height: 100vh; background: linear-gradient(135deg, #B71C1C 0%, #D32F2F 50%, #E53935 100%);
  padding: 24px;
}
.login-card {
  background: #FFF; border-radius: 16px; padding: 40px 32px 32px;
  width: 100%; max-width: 360px; box-shadow: 0 8px 32px rgba(0,0,0,.2);
  text-align: center;
}
.login-icon { margin-bottom: 16px; }
.login-title { font-size: 22px; font-weight: 700; color: #222; margin-bottom: 8px; }
.login-subtitle { font-size: 13px; color: #999; margin-bottom: 28px; }
.login-input-group { display: flex; gap: 10px; margin-bottom: 16px; }
.login-input {
  flex: 1; height: 46px; border: 1.5px solid #E0E0E0; border-radius: 10px;
  padding: 0 14px; font-size: 16px; outline: none; transition: border .2s;
  box-sizing: border-box;
}
.login-input:focus { border-color: #D32F2F; }
.login-send-btn {
  height: 46px; padding: 0 16px; border: none; border-radius: 10px;
  background: #D32F2F; color: #FFF; font-size: 14px; font-weight: 600;
  white-space: nowrap; cursor: pointer; transition: opacity .2s; flex-shrink: 0;
}
.login-send-btn:active { opacity: .8; }
.login-send-btn:disabled { background: #CCC; cursor: not-allowed; }
.login-submit-btn {
  width: 100%; height: 48px; border: none; border-radius: 10px;
  background: #D32F2F; color: #FFF; font-size: 16px; font-weight: 600;
  margin-top: 8px; cursor: pointer; transition: opacity .2s;
}
.login-submit-btn:active { opacity: .8; }
.login-wechat-btn { background: #07C160; }
.login-wechat-btn:active { opacity: .85; }
.login-wechat-btn:disabled { background: #9ED9B8; cursor: default; }
.login-guest-btn {
  width: 100%; height: 44px; border: 1px solid #D32F2F; border-radius: 10px;
  background: #FFF; color: #D32F2F; font-size: 15px; font-weight: 600;
  margin-top: 12px; cursor: pointer; transition: background .2s;
}
.login-guest-btn:active { background: #FDECEC; }
.login-nav {
  height: 44px; display: flex; align-items: center; padding: 0 16px;
  background: #C41E24;
}
.login-back {
  color: #FFF; font-size: 16px; cursor: pointer; padding: 4px 0;
}
.login-error {
  color: #D32F2F; font-size: 13px; margin-bottom: 12px; text-align: left;
}
.login-footer { font-size: 12px; color: #BBB; margin-top: 20px; }

/* ========== 报名流程指南页面 ========= */
.guide-page {
  padding: 0 0 80px 0;
  background: var(--bg-body, #0d0d1a);
  min-height: calc(100vh - 52px);
}
.guide-intro {
  text-align: center; padding: 28px 20px 20px;
  background: linear-gradient(135deg, rgba(196,30,36,.12), rgba(245,200,66,.08));
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.guide-intro-icon { font-size: 36px; margin-bottom: 8px; }
.guide-intro h2 {
  font-size: 20px; font-weight: 700; color: var(--text-primary,#fff); margin: 0 0 10px;
}
.guide-intro p {
  font-size: 13.5px; color: var(--text-muted,#aaa); line-height: 1.6; margin: 0;
  max-width: 340px; margin-left: auto; margin-right: auto;
}
.guide-steps { padding: 12px 14px; }
.guide-step-card {
  background: var(--bg-card, #151525); border-radius: 14px;
  overflow: hidden; margin-bottom: 16px;
  box-shadow: 0 2px 12px rgba(0,0,0,.25); border: 1px solid rgba(255,255,255,.05);
}
.guide-step-header {
  display: flex; align-items: center; gap: 10px; padding: 14px 16px 0;
}
.guide-step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: 50%;
  background: linear-gradient(135deg, #C41E24, #E8505A);
  color: #fff; font-size: 13px; font-weight: 700; flex-shrink: 0;
}
.guide-step-title {
  font-size: 15.5px; font-weight: 700; color: var(--text-primary,#fff);
}
.guide-step-img {
  display: block; width: 100%; height: auto; margin-top: 12px;
  border-radius: 0; /* 图片自带圆角 */
}
.guide-step-desc {
  padding: 12px 16px 16px; font-size: 13px;
  line-height: 1.65; color: var(--text-muted,#bbb);
  border-top: 1px solid rgba(255,255,255,.04);
}

/* ====== 备案信息 Footer（内联到页面内容底部，随滚动显示） ====== */
/* 不用 fixed：fixed 要么盖内容(relative时)，要么被tab-bar盖(在底部时)。
   改为由 JS 在切换页面时 append 到当前 .page 内容区底部。 */
.site-footer {
  background: var(--bg-card, #12121f);
  border-top: 1px solid rgba(255,255,255,.06);
  padding: 12px 16px 16px;
  text-align: center;
  margin-top: auto;
}
.footer-inner {
  display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: 6px;
  font-size: 11px; line-height: 1.7;
  color: var(--text-muted, #777);
}
.footer-link {
  color: var(--text-muted, #888); text-decoration: none;
  transition: color .2s;
}
.footer-link:hover { color: var(--gold-primary, #F5C842); text-decoration: underline; }
.footer-sep { opacity: .35; }
.footer-text { color: var(--text-muted, #777); }
