:root {
  --bg:#f5f7f9;
  --surface:#fff;
  --ink:#182b36;
  --muted:#65717e;
  --border:#e4e9ed;
  --teal:#087f75;
  --teal-soft:#e9f5f2;
  --violet:#7b68b0;
  --navy:#152b34;
  --danger:#b12f32;
  --radius:12px;
  font-family:Inter,-apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif;
  color:var(--ink);
  font-size:14px;
  font-synthesis:none
}

* {
  box-sizing:border-box
}
body {
  margin:0;
  background:var(--bg)
}
button,input,select {
  font:inherit
}
button,a,input,select {
  -webkit-tap-highlight-color:transparent
}
button {
  cursor:pointer
}
button:disabled {
  cursor:not-allowed;
  opacity:.5
}
button,a,input,select {
  transition:background .15s,border-color .15s,color .15s
}
a {
  color:var(--teal);
  text-decoration:none
}
a:hover {
  text-decoration:underline
}
button:focus-visible,a:focus-visible {
  outline:3px solid #60adbd;
  outline-offset:3px
}
input:focus,select:focus {
  outline:2px solid #73b6ad;
  outline-offset:1px
}
input,select {
  min-height:44px;
  border:1px solid #cdd6dc;
  border-radius:7px;
  padding:10px 12px;
  color:var(--ink);
  background:white;
  max-width:100%
}
button {
  min-height:44px;
  border:0;
  border-radius:7px
}
svg {
  width:19px;
  height:19px;
  fill:none;
  stroke:currentColor;
  stroke-width:1.7;
  stroke-linecap:round;
  stroke-linejoin:round;
  flex-shrink:0
}
[hidden] {
  display:none!important
}
.boot {
  padding:15vh 24px;
  text-align:center;
  color:var(--muted)
}
.eyebrow {
  font-size:12px;
  letter-spacing:2px;
  color:var(--teal);
  font-weight:600
}
.brand {
  display:flex;
  align-items:center;
  gap:12px;
  color:#fff;
  font-size:19px;
  font-weight:650;
  letter-spacing:1px
}
.brand:hover {
  text-decoration:none
}
.brand-symbol {
  display:grid;
  place-items:center;
  width:39px;
  height:39px;
  background:#b7e6c7;
  border-radius:10px;
  color:var(--navy);
  font-size:20px;
  box-shadow:inset -4px -4px 0 #9ad2b1
}
.brand small {
  display:block;
  color:#aabac0;
  font-size:12px;
  letter-spacing:3px;
  margin-top:5px;
  font-weight:400
}
.workspace {
  display:flex;
  min-height:100vh
}
.sidebar {
  width:230px;
  flex-shrink:0;
  background:var(--navy);
  color:white;
  position:fixed;
  inset:0 auto 0 0;
  padding:32px 20px 0;
  display:flex;
  flex-direction:column
}
.sidebar .brand {
  margin:0 6px 50px
}
.nav-caption {
  font-size:12px;
  letter-spacing:2px;
  color:#91a7b0;
  margin:0 16px 13px
}
.nav-item {
  display:flex;
  align-items:center;
  gap:12px;
  padding:13px 16px;
  color:#b9c7cd;
  margin-bottom:7px;
  border-radius:8px;
  min-height:48px
}
.nav-item:hover {
  background:#213d47;
  text-decoration:none
}
.nav-item.active {
  background:#2a4b53;
  color:#d7f7e6
}
.nav-item.active:after {
  content:"";
  margin-left:auto;
  width:5px;
  height:5px;
  background:#b7e6c7;
  border-radius:50%
}
.sidebar-bottom {
  margin-top:auto;
  padding-top:45px
}
.source-status {
  font-size:12px;
  color:#cfdbdf;
  margin:0 13px
}
.dot {
  display:inline-block;
  width:6px;
  height:6px;
  border-radius:50%;
  background:#70b99a;
  margin-right:5px
}
.sidebar-bottom>p {
  font-size:12px;
  color:#94aab3;
  margin:10px 13px 26px
}
.account {
  display:flex;
  align-items:center;
  gap:10px;
  border-top:1px solid #30444e;
  padding:22px 0
}
.avatar {
  background:#314a55;
  color:#deebe9;
  font-size:13px;
  border-radius:50%;
  height:34px;
  width:34px;
  display:grid;
  place-items:center
}
.account b {
  font-size:12px;
  font-weight:500
}
.account small {
  display:block;
  font-size:12px;
  color:#9aafb8;
  margin-top:5px
}
.account button {
  margin-left:auto;
  background:transparent;
  color:#adbdc5;
  width:44px
}
.account button:hover {
  background:#29434d
}
.main-shell {
  margin-left:230px;
  width:calc(100% - 230px)
}
.topbar {
  height:72px;
  background:var(--surface);
  border-bottom:1px solid var(--border);
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:0 38px;
  font-size:12px;
  color:var(--muted)
}
.topbar strong {
  font-weight:500;
  color:var(--ink)
}
.slash {
  margin:0 13px;
  color:#bdc5cc
}
.topbar-right {
  display:flex;
  align-items:center;
  gap:5px
}
.timezone {
  border-left:1px solid var(--border);
  padding-left:16px;
  margin-left:13px;
  font-size:12px
}
main {
  max-width:1510px;
  margin:auto;
  padding:35px 38px 20px
}
.page-heading {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  margin-bottom:27px
}
h1,h2,p {
  margin:0
}
h1 {
  font-size:30px;
  letter-spacing:-1px;
  line-height:1.5;
  margin:5px 0 8px;
  font-weight:650
}
.title-dot {
  color:var(--teal);
  margin-left:2px
}
.page-heading p {
  color:var(--muted);
  font-size:13px;
  line-height:1.8
}
.primary,.secondary {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  white-space:nowrap;
  padding:10px 17px;
  font-size:12px;
  font-weight:550
}
.primary {
  background:var(--teal);
  color:white
}
.primary:hover {
  background:#066b63
}
.secondary {
  background:white;
  color:#435460;
  border:1px solid #d7dfe5
}
.secondary:hover {
  background:#f0f6f5;
  border-color:#b9cbc8
}
.filter-panel,.panel,.metric {
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius)
}
.filter-panel {
  padding:18px 22px
}
.filter-top {
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:17px;
  gap:16px
}
.filter-title {
  display:flex;
  align-items:center;
  gap:9px;
  font-size:13px;
  font-weight:600
}
.filter-mark {
  height:12px;
  width:3px;
  background:var(--teal);
  border-radius:2px
}
.presets {
  display:flex;
  background:#f0f3f6;
  border-radius:7px;
  padding:3px;
  gap:2px
}
.presets button {
  min-height:44px;
  background:transparent;
  color:#65717e;
  font-size:12px;
  padding:6px 13px;
  border-radius:5px
}
.presets button:hover {
  color:var(--teal)
}
.presets button.selected {
  background:white;
  color:var(--teal);
  box-shadow:0 1px 3px #132b3410
}
.filter-fields {
  display:flex;
  align-items:end;
  gap:16px
}
.filter-fields label {
  display:flex;
  flex-direction:column;
  gap:8px;
  font-size:12px;
  color:#536370;
  flex:1
}
.filter-fields select {
  width:100%;
  font-size:12px
}
.filter-fields>label {
  min-width:120px
}
.date-range {
  display:flex;
  align-items:end;
  gap:10px;
  flex:2
}
.date-range>span {
  padding-bottom:14px;
  color:#a3adb6
}
.date-range input {
  width:100%;
  min-width:140px;
  font-size:12px
}
.filter-fields>.primary {
  min-width:120px
}
.filter-foot {
  display:flex;
  justify-content:space-between;
  gap:10px;
  margin-top:18px;
  font-size:12px;
  color:var(--muted)
}
.filter-foot>span:first-child {
  color:var(--teal)
}
.result-meta {
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin:23px 0 12px;
  font-size:12px;
  color:var(--muted)
}
.scope-badge {
  color:var(--teal);
  background:var(--teal-soft);
  border:1px solid #d7e9e3;
  border-radius:5px;
  padding:5px 9px
}
.metrics {
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:17px;
  margin-bottom:24px
}
.metric {
  position:relative;
  padding:21px 21px 24px;
  overflow:hidden
}
.metric-label {
  display:flex;
  align-items:center;
  justify-content:space-between;
  color:#5b6976;
  font-size:12px
}
.metric-token {
  font-size:12px;
  border:1px solid var(--border);
  border-radius:5px;
  padding:3px 5px;
  color:#657582
}
.metric strong {
  display:block;
  font-size:35px;
  font-weight:600;
  font-variant-numeric:tabular-nums;
  letter-spacing:-1px;
  margin:13px 0 8px;
  line-height:1.2
}
.metric small {
  font-size:12px;
  color:var(--muted);
  line-height:1.7
}
.metric-line {
  height:3px;
  position:absolute;
  bottom:0;
  left:22px;
  width:30px
}
.teal {
  background:var(--teal)
}
.violet {
  background:var(--violet)
}
.amber {
  background:#c39143
}
.slate {
  background:#7392a3
}
.panel {
  margin-bottom:24px
}
.panel-heading {
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:15px;
  padding:23px 23px 15px
}
.panel-heading h2 {
  font-size:15px;
  font-weight:600
}
.panel-heading p {
  font-size:12px;
  color:var(--muted);
  line-height:1.7;
  margin-top:7px
}
.legend {
  display:flex;
  gap:18px;
  color:#5b6976;
  font-size:12px
}
.legend span {
  display:flex;
  align-items:center;
  gap:7px;
  white-space:nowrap
}
.legend i {
  width:8px;
  height:8px;
  border-radius:2px
}
.teal-bg {
  background:var(--teal)
}
.violet-bg {
  background:var(--violet)
}
.chart {
  padding:5px 23px 17px;
  min-height:225px
}
.chart svg {
  display:block;
  width:100%;
  height:auto;
  max-height:290px;
  stroke:none;
  overflow:visible
}
.chart text {
  fill:var(--muted);
  font-size:12px;
  font-family:inherit
}
.chart .grid-line {
  stroke:#e8edf1;
  stroke-width:1;
  stroke-dasharray:3 4
}
.chart .bar-played {
  fill:var(--teal)
}
.chart .bar-completed {
  fill:var(--violet)
}
.chart .value {
  fill:var(--ink);
  font-size:12px
}
.chart-description {
  color:var(--muted);
  font-size:12px;
  text-align:center;
  margin-top:6px
}
.count-tag {
  background:#f0f3f6;
  color:#667480;
  font-size:12px;
  font-weight:500;
  padding:3px 7px;
  border-radius:5px;
  margin-left:7px;
  vertical-align:middle
}
.level-search {
  display:flex;
  align-items:center;
  gap:10px;
  font-size:12px;
  color:var(--muted)
}
.level-search input {
  width:124px;
  font-size:12px;
  min-height:44px
}
.table-scroll {
  overflow-x:auto
}
table {
  border-collapse:collapse;
  width:100%;
  font-size:12px;
  font-variant-numeric:tabular-nums;
  white-space:nowrap
}
th {
  text-align:left;
  background:#f7f9fb;
  color:#5a6b77;
  font-size:12px;
  font-weight:500;
  padding:0 23px;
  height:45px;
  border-block:1px solid #eaf0f3
}
th button {
  background:none;
  padding:0;
  min-height:44px;
  font-size:12px;
  color:inherit;
  display:inline-flex;
  align-items:center;
  gap:8px
}
th button span {
  color:#87959f
}
.num {
  text-align:right
}
td {
  padding:17px 23px;
  border-bottom:1px solid #edf0f3;
  color:#536370
}
td strong {
  color:var(--ink);
  font-weight:550
}
td .complete-num {
  color:var(--violet);
  font-weight:600
}
tbody tr:hover {
  background:#f9fbfb
}
.level-badge {
  font-size:12px;
  padding:4px 9px;
  border-radius:5px;
  background:#edf5f3;
  color:#296f66
}
.pagination {
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:15px 23px;
  color:var(--muted);
  font-size:12px
}
.pagination>div {
  display:flex;
  align-items:center;
  gap:16px
}
.pagination button {
  padding:0;
  width:34px;
  min-height:44px
}
.empty {
  text-align:center;
  padding:75px 18px!important;
  color:var(--muted);
  font-size:12px;
  line-height:1.9
}
.table-scroll .empty {
  padding:45px 18px!important
}
.page-footer {
  display:flex;
  justify-content:space-between;
  gap:15px;
  line-height:1.8;
  font-size:12px;
  color:var(--muted);
  margin:5px 0 10px
}
.page-footer a {
  white-space:nowrap
}
.error {
  color:var(--danger);
  font-size:12px;
  line-height:1.7;
  background:#fff0ef;
  border:1px solid #efd1ce;
  padding:12px;
  border-radius:7px
}
.query-error {
  margin-top:16px
}
.data-note {
  font-size:12px;
  color:#8c6226;
  line-height:1.8;
  margin:-8px 0 20px
}
.definitions {
  padding:8px 28px 30px;
  max-width:900px
}
.definitions h2 {
  font-size:16px;
  margin:28px 0 10px
}
.definitions p {
  font-size:14px;
  color:#586975;
  line-height:2
}
.login-screen {
  display:grid;
  grid-template-columns:45% 55%;
  min-height:100vh
}
.login-story {
  padding:50px 10%;
  background:var(--navy);
  color:white;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  min-height:100vh;
  overflow:hidden;
  position:relative
}
.login-story .eyebrow {
  color:#abd3bd
}
.login-story h1 {
  font-size:40px;
  line-height:1.55;
  letter-spacing:0;
  margin:20px 0
}
.login-story p {
  color:#b1c5cc;
  line-height:2;
  font-size:14px
}
.story-footer {
  font-size:12px;
  color:#90a9b3
}
.maze-art {
  display:grid;
  grid-template-columns:repeat(6,32px);
  gap:9px;
  margin:48px 0
}
.maze-art i {
  height:32px;
  background:#2b4b55;
  border-radius:5px
}
.maze-art i:nth-child(3n) {
  background:#4b7d7a
}
.maze-art i:nth-child(7) {
  background:#b7e6c7;
  box-shadow:0 0 22px #b7e6c72b
}
.login-area {
  display:grid;
  place-items:center;
  padding:40px 24px
}
.login-card {
  width:100%;
  max-width:350px
}
.login-card h2 {
  font-size:28px;
  font-weight:600;
  margin:15px 0 12px
}
.login-card>p {
  color:var(--muted);
  font-size:13px;
  margin-bottom:35px
}
.login-card>label {
  display:block;
  font-size:12px;
  color:#435562;
  margin-bottom:9px
}
.login-card>input,.password-field {
  width:100%;
  margin-bottom:22px
}
.login-card input {
  min-height:48px;
  font-size:13px
}
.password-field {
  display:flex;
  position:relative
}
.password-field input {
  width:100%;
  padding-right:60px
}
.password-field button {
  position:absolute;
  right:4px;
  top:2px;
  background:transparent;
  color:var(--muted);
  font-size:12px
}
.login-submit {
  width:100%;
  margin-top:8px;
  min-height:48px;
  justify-content:space-between;
  font-size:13px
}
.login-card #login-error {
  margin:0 0 12px
}
.login-footnote {
  display:block;
  text-align:center;
  font-size:12px;
  color:var(--muted);
  margin:23px 0
}

@media(min-width:1500px) {
  main {
  padding-top:42px
}
.chart {
  min-height:260px
}

}

@media(max-width:1180px) {
  .sidebar {
  width:200px;
  padding-inline:14px
}
.main-shell {
  margin-left:200px;
  width:calc(100% - 200px)
}
main {
  padding:28px 24px
}
.topbar {
  padding:0 24px
}
.filter-fields {
  flex-wrap:wrap
}
.filter-fields>label {
  flex:1
}
.date-range {
  flex:2.4
}
.filter-fields>.primary {
  width:100%
}
.metrics {
  gap:12px
}
.metric {
  padding:17px 16px 23px
}
.metric strong {
  font-size:30px
}
.metric small {
  font-size:12px
}
th,td {
  padding-inline:16px
}

}

@media(max-width:900px) {
  .sidebar {
  position:static;
  width:100%;
  padding:16px 20px;
  display:block
}
.sidebar .brand {
  margin:0;
  font-size:16px
}
.brand small {
  font-size:12px
}
.brand-symbol {
  width:32px;
  height:32px;
  font-size:17px
}
.sidebar nav {
  display:flex;
  margin-top:18px;
  gap:8px
}
.nav-item {
  margin:0;
  padding:8px 14px;
  font-size:12px;
  min-height:40px
}
.nav-caption,.source-status,.sidebar-bottom>p {
  display:none
}
.sidebar-bottom {
  position:absolute;
  top:15px;
  right:15px;
  padding:0
}
.account {
  border:0;
  padding:0
}
.account>.avatar,.account>span:not(.avatar) {
  display:none
}
.workspace {
  display:block
}
.main-shell {
  margin:0;
  width:100%
}
.topbar {
  height:52px;
  padding:0 22px
}
.timezone {
  display:none
}
main {
  padding:25px 20px
}
.page-heading {
  align-items:start
}
h1 {
  font-size:26px
}
.page-heading .secondary {
  margin-top:25px
}
.filter-panel {
  padding:16px
}
.filter-fields>label {
  min-width:calc(50% - 8px)
}
.date-range {
  min-width:100%
}
.date-range input {
  min-width:0
}
.filter-fields {
  gap:14px
}
.filter-top {
  flex-wrap:wrap
}
.presets button {
  padding-inline:12px;
  min-height:44px
}
.metrics {
  grid-template-columns:repeat(2,minmax(0,1fr))
}
.metric strong {
  font-size:31px
}
.panel-heading {
  padding:20px 16px 12px;
  align-items:start;
  flex-wrap:wrap
}
.chart {
  padding:8px 10px 15px;
  min-height:180px
}
.legend {
  gap:12px
}
.panel-heading p {
  font-size:12px
}
.table-panel .panel-heading {
  gap:14px
}
.table-scroll table {
  min-width:620px
}
.pagination {
  padding:14px 16px
}
.page-footer {
  display:block
}
.page-footer a {
  display:block;
  margin-top:8px
}
.login-screen {
  grid-template-columns:1fr
}
.login-story {
  min-height:0;
  padding:24px
}
.login-story>div,.story-footer {
  display:none
}
.login-area {
  padding:50px 26px
}
.login-card {
  max-width:380px
}
.definitions {
  padding:4px 20px 25px
}
.result-meta {
  gap:10px;
  align-items:start
}
#updated {
  line-height:1.8;
  font-size:12px;
  text-align:right
}
.level-search input {
  min-height:44px
}
.pagination button {
  min-height:44px;
  width:44px
}

}

@media(prefers-reduced-motion:reduce) {
  * {
  transition:none!important
}

}


.sidebar { overflow-y: auto; }

/* 关卡分析主视图：紧凑汇总 + 不分页的逐关对比。 */
.summary-line {
 display: flex;
 align-items: baseline;
 flex-wrap: wrap;
 gap: 12px 28px;
 margin: 16px 0 22px;
 color: var(--muted);
 font-size: 14px;
}
.summary-line strong { font-size: 24px; color: var(--teal); margin: 0 7px; font-variant-numeric: tabular-nums; }
.summary-line .complete-num { color: var(--violet); }
.summary-line small { font-size: 12px; }
.chart-controls { display: flex; align-items: center; flex-wrap: wrap; gap: 16px; }
.chart-key { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding: 0 23px 18px; }
#chart-scale { color: var(--muted); font-size: 12px; line-height: 1.8; }
.level-chart { padding: 0 23px 16px; }
.level-chart-header, .level-progress {
 display: grid;
 grid-template-columns: 80px minmax(0, 1fr) 88px 88px;
 align-items: center;
 gap: 16px;
}
.level-chart-header { min-height: 38px; color: var(--muted); font-size: 12px; border-block: 1px solid var(--border); }
.level-progress { min-height: 42px; border-bottom: 1px solid #edf0f3; font-variant-numeric: tabular-nums; }
.level-progress:last-child { border-bottom: 0; }
.level-progress:hover { background: #f7faf9; }
.level-progress svg { display: block; width: 100%; height: 22px; stroke: none; }
.level-progress .bar-track { fill: #f0f3f6; }
.level-progress .bar-played { fill: var(--teal); }
.level-progress .bar-completed { fill: var(--violet); }
.level-progress .entry-baseline { stroke: #536370; stroke-width: 1.5; stroke-dasharray: 3 2; }
.progress-label { font-size: 12px; color: var(--ink); }
.entry-count, .complete-count { text-align: right; font-size: 14px; font-weight: 550; }
.entry-count { color: var(--teal); }
.complete-count { color: var(--violet); }
.level-chart-header>span:nth-last-child(-n+2) { text-align: right; }
.daily-details { margin: 0 0 22px; }
.daily-details>summary { cursor: pointer; color: var(--muted); font-size: 13px; padding: 12px 0; min-height: 44px; }
.daily-details>summary:focus-visible { outline: 2px solid var(--teal); outline-offset: 3px; }
.daily-details[open]>summary { margin-bottom: 8px; }
@media(max-width:900px) {
 .chart-key { padding-inline: 16px; }
 .level-chart { padding-inline: 16px; }
 .level-chart-header, .level-progress { grid-template-columns: 62px minmax(0,1fr) 62px 62px; gap: 10px; }
 .summary-line { gap: 10px 22px; }
 .summary-line small { flex-basis: 100%; }
 .chart-controls { gap: 12px; }
}
@media(max-width:480px) {
 .level-chart-header, .level-progress { grid-template-columns: 55px minmax(0,1fr) 48px 48px; gap: 8px; }
 .level-chart-header { font-size: 11px; }
 .level-chart-header>span:nth-child(2) { font-size: 0; }
 .level-chart-header>span:nth-child(2)::after { content: '对比'; font-size: 11px; }
 .level-progress { min-height: 44px; }
 .progress-label { font-size: 11px; }
 .chart-controls { width: 100%; justify-content: space-between; }
}

.conversion-funnel { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin:20px 0; }
.conversion-stage { display:flex; flex-direction:column; gap:12px; padding:20px; background:var(--surface); border:1px solid var(--border); border-radius:12px; }
.conversion-stage strong { font-size:26px; color:var(--teal); }
.conversion-stage small { color:var(--muted); }
.conversion-table { margin:20px 0; }
.conversion-table th { white-space:nowrap; }
.conversion-table td:first-child { white-space:nowrap; font-weight:600; }
.conversion-rates { font-size:16px; flex-wrap:wrap; }
@media(max-width:700px) { .conversion-funnel { grid-template-columns:repeat(2,minmax(0,1fr)); } .conversion-stage { padding:14px; } }

.conversion-trend-row { display:grid; grid-template-columns:110px 1fr; gap:12px; padding:12px 20px; }
.conversion-trend-row meter { display:block; width:100%; height:12px; accent-color:var(--teal); }
.conversion-trend-row span { font-size:13px; }

/* 共用查询工具栏：桌面一行控件，手机保留44px触点。 */
.filter-title { display:none; }
.filter-panel { display:flex; flex-wrap:wrap; align-items:center; gap:8px 12px; padding:10px 14px; }
.filter-top { order:2; margin:0; flex:none; gap:0; }
.filter-fields { order:1; flex:1 1 640px; flex-wrap:nowrap; align-items:center; gap:8px; }
.filter-fields label { gap:0; font-size:0; }
.filter-fields>label { flex:0 0 125px; min-width:0; }
.filter-fields>label:nth-child(2) { flex-basis:105px; }
.filter-fields select,.filter-fields input { min-height:32px; height:32px; padding:5px 9px; font-size:12px; }
.date-range { flex:0 0 auto; min-width:0; gap:6px; align-items:center; }
.date-range input { width:142px; min-width:0; }
.date-range>span { padding:0; }
.filter-fields>.primary { min-height:32px; height:32px; min-width:88px; width:auto; padding:5px 12px; }
.filter-top .presets { padding:2px; }
.filter-top .presets button { min-height:32px; padding:4px 10px; }
.filter-foot { order:3; flex-basis:100%; margin:0; font-size:11px; gap:6px; }
@media(max-width:900px) {
 .filter-panel { display:block; padding:12px; }
 .filter-top { justify-content:flex-start; margin-bottom:8px; }
 .filter-top .presets { width:100%; }
 .filter-top .presets button { flex:1; min-height:44px; padding:4px 8px; }
 .filter-fields { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:8px; }
 .filter-fields label { font-size:11px; gap:4px; }
 .filter-fields>label { min-width:0; }
 .filter-fields select,.filter-fields input { min-height:44px; height:44px; width:100%; }
 .date-range { grid-column:1/-1; display:grid; grid-template-columns:minmax(0,1fr) auto minmax(0,1fr); min-width:0; }
 .date-range>span { padding-top:17px; }
 .filter-fields>.primary { grid-column:1/-1; width:100%; min-height:44px; height:44px; }
 .filter-foot { margin-top:8px; flex-wrap:wrap; }
}
@media(min-width:901px) and (pointer:coarse) {
 .filter-fields select,.filter-fields input,.filter-fields>.primary,.filter-top .presets button { min-height:44px; height:44px; }
}

/* 查询条件放进标题右侧的空白处。 */
.analysis-heading { align-items:center; gap:24px; }
.analysis-heading>div:first-child { flex:0 1 210px; min-width:170px; }
.heading-tools { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:start; gap:8px; flex:1; min-width:0; }
.analysis-heading .filter-panel { border:0; background:transparent; padding:0; border-radius:0; }
.heading-tools>.secondary { margin:0; min-height:32px; height:32px; padding:5px 12px; }
@media(max-width:1200px) {
 .analysis-heading { flex-wrap:wrap; align-items:flex-start; gap:16px; }
 .analysis-heading>div:first-child { flex:1 1 100%; }
 .heading-tools { flex-basis:100%; }
}
@media(max-width:900px) {
 .sidebar nav { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:4px; }
 .sidebar .nav-item { justify-content:center; gap:0; padding:8px 4px; min-height:44px; white-space:nowrap; }
 .sidebar .nav-item svg,.sidebar .nav-item.active:after { display:none; }
 .analysis-heading { position:relative; }
 .analysis-heading>div:first-child { padding-right:120px; }
 .heading-tools { grid-template-columns:minmax(0,1fr); }
 .heading-tools>.secondary { position:absolute; top:25px; right:0; min-height:44px; height:44px; }
}

/* 启动漏斗：阶段名称、基数与转化率始终可见，不只依赖颜色。 */
.startup-panel { margin: 18px 0; overflow: hidden; }
.startup-overall { display: flex; flex-direction: column; gap: 6px; text-align: right; white-space: nowrap; }
.startup-overall span { font-size: 12px; color: var(--muted); }
.startup-overall strong { font-size: 28px; color: var(--teal); }
.startup-funnel { list-style: none; margin: 0; padding: 0 24px 12px; }
.startup-stage { padding: 8px 0 10px; }
.startup-stage-label { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.startup-stage-label strong { font-variant-numeric: tabular-nums; }
.startup-track { height: 14px; border-radius: 7px; margin-top: 12px; background: var(--surface); }
.startup-bar { height: 100%; border-radius: inherit; background: var(--teal); }
.startup-stage:nth-child(2) .startup-bar { opacity: .75; }
.startup-stage:nth-child(3) .startup-bar { opacity: .5; }
.startup-step-rate { margin: 10px 0 0; font-size: 12px; color: var(--muted); }
.startup-coverage { margin: 18px 0; padding: 18px 24px; }
.startup-coverage summary { min-height: 44px; display: flex; align-items: center; cursor: pointer; }
.startup-coverage p { font-size: 13px; line-height: 1.8; color: var(--muted); }
.level-chart-header, .level-progress { grid-template-columns: 80px minmax(0,1fr) 70px 70px 100px; }
.level-chart-header>span:nth-last-child(-n+3) { text-align: right; }
.pass-rate { text-align: right; font-variant-numeric: tabular-nums; font-size: 14px; }
.pass-rate small { display: block; font-size: 11px; color: var(--muted); margin-top: 3px; }
@media(max-width:900px) {
 .sidebar nav { display: flex; overflow-x: auto; gap: 4px; }
 .sidebar .nav-item { flex: 0 0 auto; padding-inline: 10px; }
 .level-chart-header, .level-progress { grid-template-columns: 55px minmax(0,1fr) 48px 48px 78px; gap: 8px; }
}
@media(max-width:480px) {
 .startup-funnel { padding-inline: 16px; }
 .startup-coverage { padding: 12px 16px; }
 .startup-overall strong { font-size: 24px; }
 .startup-panel .panel-heading { align-items: flex-start; }
 .level-chart-header, .level-progress { grid-template-columns: 55px minmax(0,1fr) 44px 44px; }
 .level-progress { padding-block: 7px; }
 .level-chart-header>span:last-child { display: none; }
 .pass-rate { grid-column: 2 / -1; text-align: left; font-size: 12px; }
 .pass-rate::before { content: '玩家通过率 '; color: var(--muted); }
 .pass-rate small { display: inline; margin-left: 8px; }
}
@media(max-width:900px) { .filter-fields>.cohort-field { grid-column:1/-1; } }
/* 玩家分组增加一列后，较窄桌面允许控件换行，避免与导出按钮重叠。 */
.analysis-heading .filter-fields { flex-wrap:wrap; }
.startup-info { color:var(--muted); line-height:1.8; }
