.analysis-shell { --analysis-ink: oklch(28% .028 20); --analysis-muted: oklch(49% .024 20); max-width: 1180px; margin: 32px auto 72px; padding: 0 28px; color: var(--analysis-ink); text-align: left; }
.analysis-shell *, .analysis-shell *::before, .analysis-shell *::after { box-sizing: border-box; }
.analysis-shell a { color: oklch(40% .10 15); text-underline-offset: 3px; }
.analysis-shell h1, .analysis-shell h2, .analysis-shell h3 { text-align: left; margin: 0; }
.analysis-shell h1 { font-size: clamp(28px, 4vw, 44px); letter-spacing: -.035em; }
.analysis-shell h2 { font-size: 25px; }
.analysis-shell h3 { font-size: 19px; letter-spacing: -.015em; }
.analysis-kicker { color: var(--analysis-muted); font-size: 12px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase; margin: 0 0 8px; }
.analysis-intro { max-width: 650px; color: var(--analysis-muted); line-height: 1.6; }
.analysis-controls { display: flex; gap: 20px; align-items: end; flex-wrap: wrap; padding: 22px 0; }
.analysis-controls label { flex: 1 1 200px; font-size: 12px; font-weight: 700; color: var(--analysis-muted); }
.analysis-controls label:last-child { flex: 0 1 280px; }
.analysis-controls select { display: block; width: 100%; min-width: 0; min-height: 46px; margin: 7px 0 0; padding: 10px 36px 10px 12px; border: 1px solid oklch(82% .019 30); border-radius: 7px; background: oklch(99% .006 60); color: var(--analysis-ink); font-size: 15px; }
.analysis-tabs { display: flex; gap: 24px; border-bottom: 1px solid oklch(85% .014 20); margin-bottom: 28px; }
.analysis-tabs button { background: transparent; color: var(--analysis-muted); border: 0; border-bottom: 3px solid transparent; border-radius: 0; padding: 15px 1px 12px; margin: 0; font-size: 14px; font-weight: 700; min-height: 46px; white-space: nowrap; }
.analysis-tabs button[aria-selected=true] { color: oklch(39% .105 15); border-bottom-color: currentColor; }
.analysis-shell :focus-visible { outline: 3px solid oklch(56% .12 225); outline-offset: 4px; }
.analysis-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 24px 0; gap: 24px 16px; }
.analysis-metrics > div { padding: 0 16px 0 0; min-width: 0; }
.analysis-metrics dt { font-size: 12px; color: var(--analysis-muted); margin-bottom: 7px; }
.analysis-metrics dd { font-size: clamp(23px, 3vw, 34px); line-height: 1.15; font-weight: 700; font-variant-numeric: tabular-nums; margin: 0; letter-spacing: -.035em; overflow-wrap: anywhere; }
.analysis-metrics small { display: block; margin-top: 7px; font-size: 11px; color: var(--analysis-muted); }
.analysis-chart { background: oklch(99% .005 50); border: 1px solid oklch(88% .014 35); border-radius: 10px; margin: 24px 0; padding: 24px; min-width: 0; }
.analysis-chart__heading p { color: var(--analysis-muted); font-size: 13px; line-height: 1.6; max-width: 720px; margin: 8px 0; }
.analysis-chart__canvas { height: 360px; position: relative; min-width: 0; margin-top: 22px; }
.analysis-chart__canvas canvas { max-width: 100%; }
.analysis-chart__legend { display: flex; flex-wrap: wrap; gap: 10px 24px; font-size: 12px; margin-top: 14px; }
.analysis-chart__legend span::before { content: ''; display: inline-block; width: 24px; border-top: 3px solid #792b36; vertical-align: middle; margin-right: 8px; }
.analysis-chart__legend .series-1::before { border-color: #286e83; border-top-style: dashed; }
.analysis-chart__legend .advantage-negative::before { border-top-style: solid; }
.analysis-chart__detail { display: block; min-height: 45px; border: 1px solid oklch(86% .03 65); border-radius: 6px; padding: 10px 14px; color: var(--analysis-ink); font-size: 13px; background: oklch(96% .015 65); }
.analysis-hint { color: var(--analysis-muted); font-size: 12px; line-height: 1.6; }
.analysis-empty { padding: 48px 16px; text-align: center; color: var(--analysis-muted); }
.analysis-data { margin-top: 16px; font-size: 13px; }
.analysis-data summary { cursor: pointer; padding: 10px 0; font-weight: 700; }
.analysis-table-wrap { overflow-x: auto; }
.analysis-shell table { width: 100%; border-collapse: collapse; font-size: 13px; margin: 12px 0; border: 0; }
.analysis-shell th, .analysis-shell td { padding: 14px 10px; text-align: right; border: 0; border-bottom: 1px solid oklch(89% .012 30); background: transparent; color: inherit; }
.analysis-shell th:first-child, .analysis-shell td:first-child { text-align: left; }
.analysis-shell thead { background: oklch(96% .012 35); color: var(--analysis-muted); }
.analysis-shell th { font-weight: 600; }
.analysis-data th button { font: inherit; text-align: left; padding: 5px; margin: 0; border: 0; background: transparent; color: oklch(40% .09 15); text-decoration: underline; text-underline-offset: 3px; }
.analysis-data td, .analysis-data th { text-align: left; }
.analysis-history { margin-top: 36px; }
.analysis-history h3 { margin-bottom: 20px; }
.analysis-history__head, .analysis-event > summary { display: grid; grid-template-columns: minmax(0, 2.3fr) repeat(4, minmax(0, 1fr)); gap: 16px; align-items: center; text-align: right; }
.analysis-history__head { padding: 10px 12px; font-size: 11px; color: var(--analysis-muted); }
.analysis-history__head > :first-child, .analysis-event > summary > :first-child { text-align: left; }
.analysis-event { border-bottom: 1px solid oklch(87% .013 30); }
.analysis-event > summary { cursor: pointer; list-style: none; padding: 18px 12px; font-size: 14px; min-height: 66px; }
.analysis-event > summary::-webkit-details-marker { display: none; }
.analysis-event > summary small { display: block; margin-top: 4px; color: var(--analysis-muted); font-size: 11px; }
.analysis-event[open] { background: oklch(97% .012 50); }
.analysis-event__body { padding: 0 20px 20px; }
.analysis-event__body .analysis-metrics dd { font-size: 21px; }
.analysis-event > summary:hover { background: oklch(95% .02 40); }
.value-positive { color: oklch(40% .08 158); }
.value-negative { color: oklch(43% .13 20); }
.analysis-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; }
.analysis-pair > section + section { border-left: 1px solid oklch(86% .015 30); padding-left: 36px; }
.analysis-pair h2 { font-size: 23px; overflow-wrap: anywhere; }
.analysis-pair .analysis-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.analysis-shell .comparison-scorecard { table-layout: fixed; margin: 28px 0 16px; }
.comparison-scorecard th:first-child { width: 36%; }
.analysis-shell .comparison-scorecard th, .analysis-shell .comparison-scorecard td { padding: 20px 16px; text-align: left; vertical-align: middle; }
.comparison-scorecard thead th { border-bottom: 2px solid oklch(82% .025 35); font-size: 17px; overflow-wrap: anywhere; }
.comparison-scorecard small { display: block; font-size: 11px; font-weight: 400; color: var(--analysis-muted); line-height: 1.5; margin-top: 6px; }
.comparison-scorecard strong { font-size: 25px; font-variant-numeric: tabular-nums; }
.comparison-player.series-0 { color: #792b36; }
.comparison-player.series-1 { color: #286e83; }
.comparison-meter { display: block; height: 5px; max-width: 220px; background: oklch(89% .012 30); margin-top: 10px; border-radius: 3px; overflow: hidden; }
.comparison-meter > span { display: block; height: 100%; background: #792b36; }
.comparison-meter.series-1 > span { background: #286e83; }
.comparison-form { display: flex; gap: 5px; flex-wrap: wrap; }
.comparison-form span { display: grid; place-items: center; width: 28px; height: 30px; border-radius: 3px; background: oklch(94% .02 55); font-size: 12px; font-weight: 600; }
.comparison-form span[data-win=true] { background: oklch(85% .105 78); }
.analysis-form { display: flex; gap: 7px; flex-wrap: wrap; margin: 12px 0 22px; }
.analysis-form a { display: grid; place-items: center; min-width: 42px; min-height: 42px; border: 1px solid oklch(82% .03 45); border-radius: 50%; font-size: 13px; font-weight: 700; text-decoration: none; background: oklch(97% .02 70); color: oklch(37% .07 20); }
.analysis-form a[data-win=true] { background: oklch(85% .105 78); }
.analysis-profile { display: grid; grid-template-columns: 120px 1fr; gap: 28px; align-items: center; padding-bottom: 28px; border-bottom: 1px solid oklch(85% .015 30); }
.analysis-profile__avatar { position: relative; width: 104px; height: 104px; }
.analysis-profile__photo { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; background: oklch(94% .025 45); }
.analysis-profile__border { position: absolute; width: 100%; height: 100%; top: 0; left: 0; pointer-events: none; }
.analysis-profile__badge { position: absolute; width: 52px; height: 52px; right: -14px; bottom: -8px; object-fit: contain; }
.analysis-profile p { margin: 8px 0; }
.analysis-profile__title { color: oklch(43% .10 20); font-size: 13px; font-weight: 700; }
.analysis-mode { display: flex; gap: 8px; flex-wrap: wrap; margin: 20px 0; }
.analysis-mode button { min-height: 42px; margin: 0; border: 1px solid oklch(82% .02 35); border-radius: 6px; padding: 9px 16px; background: transparent; color: var(--analysis-ink); }
.analysis-mode button[aria-pressed=true] { background: oklch(37% .09 15); color: oklch(98% .005 50); }
.analysis-error { border-left: 3px solid oklch(48% .13 20); padding: 18px; background: oklch(96% .02 30); }
.analysis-badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 20px; margin: 20px 0; }
.analysis-badges figure { text-align: center; margin: 0; }
.analysis-badges img { width: 120px; max-width: 100%; height: 120px; object-fit: contain; }
.analysis-badges figcaption { font-size: 12px; font-weight: 700; }
.analysis-leaderboard th button { background: transparent; color: inherit; border: 0; padding: 6px 0; margin: 0; font: inherit; cursor: pointer; text-align: inherit; }
.analysis-leaderboard .leaderboard-expand { display: block; font-size: 11px; font-weight: 400; color: var(--analysis-muted); min-height: 32px; }
.analysis-leaderboard tbody th { min-width: 105px; }
.analysis-leaderboard td { font-variant-numeric: tabular-nums; }
.analysis-leaderboard .leaderboard-detail { padding: 10px 22px 24px; text-align: left; background: oklch(95% .015 50); }
.leaderboard-detail .analysis-metrics dd { font-size: 22px; }
.analysis-controls .direction-control { flex: 0 0 auto; min-height: 46px; border: 1px solid oklch(80% .02 35); background: transparent; color: inherit; padding: 10px 14px; border-radius: 6px; margin: 0; }
@media (max-width: 500px) { .analysis-leaderboard th:last-child, .analysis-leaderboard tr:not([hidden]) > td:last-child:not([colspan]) { display: none; } .analysis-shell .analysis-leaderboard th, .analysis-shell .analysis-leaderboard td { padding: 12px 6px; font-size: 12px; } .analysis-leaderboard td[colspan] { display: table-cell; } }
@media (max-width: 700px) {
  .analysis-shell .comparison-scorecard th, .analysis-shell .comparison-scorecard td { padding: 16px 7px; }
  .comparison-scorecard th:first-child { width: 35%; }
  .comparison-scorecard thead th { font-size: 14px; }
  .comparison-scorecard strong { font-size: 22px; }
  .comparison-scorecard small { font-size: 10px; }
  .comparison-form { gap: 3px; }
  .comparison-form span { width: 22px; height: 26px; }
  .analysis-shell { margin-top: 24px; padding: 0 18px; }
  .analysis-controls { gap: 14px; }
  .analysis-controls label { flex-basis: calc(50% - 8px); }
  .analysis-controls label:last-child { flex-basis: 100%; }
  .analysis-tabs { gap: 0; justify-content: space-between; margin-bottom: 24px; }
  .analysis-tabs button { font-size: 13px; }
  .analysis-chart { padding: 18px 12px; margin: 22px 0; }
  .analysis-chart__canvas { height: 300px; }
  .analysis-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 12px; }
  .analysis-pair { gap: 16px; }
  .analysis-pair > section + section { padding-left: 16px; }
  .analysis-pair h2 { font-size: 19px; }
  .analysis-pair .analysis-metrics { grid-template-columns: 1fr; gap: 24px; }
  .analysis-pair .analysis-metrics dd { font-size: 27px; }
  .analysis-history__head, .analysis-event > summary { grid-template-columns: minmax(0, 2fr) minmax(40px, .65fr) minmax(65px, 1fr); gap: 10px; }
  .analysis-history__head > :nth-child(3), .analysis-history__head > :nth-child(4), .event-finance { display: none; }
  .analysis-profile { grid-template-columns: 80px 1fr; gap: 20px; }
  .analysis-profile__avatar { width: 74px; height: 74px; }
  .analysis-profile__badge { width: 40px; height: 40px; }
  .analysis-profile h1 { font-size: 27px; }
  .analysis-form { gap: 5px; }
  .analysis-form a { min-width: 32px; min-height: 36px; border-radius: 5px; }
}
@media (prefers-reduced-motion: reduce) { .analysis-shell *, .analysis-shell *::before, .analysis-shell *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
/* Event records retain a readable width across long histories. */
.analysis-chart__scroll { max-width: 100%; overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; touch-action: pan-x pan-y; padding: 0 2px 12px; -webkit-overflow-scrolling: touch; }
.analysis-chart__scroll:focus-visible { outline: 3px solid oklch(56% .12 225); outline-offset: 2px; }
.analysis-chart__legend .financial-profit::before { border-color: #287650; }
.analysis-chart__legend .financial-loss::before { border-color: #b14446; }
.analysis-chart__legend .financial-even::before { border-color: #82776f; }
.recent-results { list-style: none; margin: 18px 0 26px; padding: 0; }
.recent-results li { display: grid; grid-template-columns: minmax(0, 1fr) auto 80px; align-items: center; gap: 24px; padding: 16px 12px; border-bottom: 1px solid oklch(86% .02 45); font-variant-numeric: tabular-nums; }
.recent-results li[data-win=true] { background: oklch(95% .055 80); }
.recent-results time { font-size: 12px; color: var(--analysis-muted); }
.recent-results li > div > span { display: block; font-size: 14px; font-weight: 600; margin-top: 4px; }
.recent-results strong { font-size: 19px; }
.recent-results small { font-size: 11px; font-weight: 400; color: var(--analysis-muted); }
.recent-results li > span { text-align: right; font-weight: 600; }
.recent-results li > span small { display: block; margin-top: 4px; }
/* Tour identity surrounds the standings; controls and statistics stay familiar. */
.leaderboard-masthead { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 36px; border-radius: 12px; background: oklch(29% .06 17); color: oklch(97% .018 65); }
.leaderboard-masthead h1 { color: inherit; }
.leaderboard-masthead .analysis-kicker { color: oklch(81% .09 78); }
.leaderboard-masthead .analysis-intro { color: oklch(87% .022 65); margin-bottom: 0; }
.leaderboard-masthead img { flex: 0 0 auto; width: 112px; opacity: .9; }
.analysis-shell[data-game=poker] #leaderboard-summary { padding: 4px 24px; background: oklch(94% .032 67); border: 1px solid oklch(86% .033 67); border-radius: 10px; }
.analysis-shell[data-game=poker] #leaderboard-summary .analysis-metrics { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.analysis-shell[data-game=poker] #leaderboard-summary dd { font-size: 25px; }
.analysis-shell[data-game=poker] .analysis-leaderboard { border-collapse: separate; border-spacing: 0; border: 1px solid oklch(85% .023 45); border-radius: 10px; overflow: hidden; background: oklch(99% .008 65); }
.analysis-shell[data-game=poker] .analysis-leaderboard thead { background: oklch(91% .028 55); }
.analysis-shell[data-game=poker] .analysis-leaderboard thead th { padding-top: 18px; padding-bottom: 18px; font-size: 12px; }
.analysis-shell[data-game=poker] .leaderboard-player-row:hover { background: oklch(96% .024 60); }
.analysis-shell[data-game=poker] .leaderboard-player-row[data-standing='1'] { background: oklch(95% .051 80); }
.leaderboard-identity { display: flex; align-items: center; gap: 12px; }
.leaderboard-place { display: grid; place-items: center; flex: 0 0 30px; height: 30px; font-size: 15px; font-weight: 700; color: var(--analysis-muted); font-variant-numeric: tabular-nums; }
[data-standing='1'] .leaderboard-place { border-radius: 50%; background: oklch(79% .11 78); color: oklch(31% .065 45); }
[data-standing='2'] .leaderboard-place, [data-standing='3'] .leaderboard-place { border-radius: 50%; background: oklch(88% .028 55); color: oklch(35% .04 35); }
.leaderboard-avatar { position: relative; flex: 0 0 42px; height: 42px; border-radius: 50%; overflow: hidden; background: oklch(91% .027 40); display: grid; place-items: center; font-weight: 700; font-size: 12px; color: oklch(40% .07 20); }
.leaderboard-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.analysis-shell .leaderboard-name { font-size: 15px; font-weight: 700; text-decoration: none; }
.analysis-shell .leaderboard-name:hover { text-decoration: underline; }
.analysis-shell[data-game=poker] .analysis-leaderboard .leaderboard-score { font-size: 20px; font-weight: 700; color: oklch(37% .09 20); background: oklch(89% .035 65 / .18); }
.analysis-shell .analysis-leaderboard .value-positive { color: oklch(40% .08 158); }
.analysis-shell .analysis-leaderboard .value-negative { color: oklch(43% .13 20); }
@media (max-width: 700px) {
  .leaderboard-masthead { padding: 26px 22px; }
  .leaderboard-masthead img { display: none; }
  .analysis-shell[data-game=poker] #leaderboard-summary .analysis-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .leaderboard-identity { gap: 7px; }
  .leaderboard-avatar { display: none; }
  .leaderboard-place { flex-basis: 24px; height: 24px; font-size: 12px; }
  .analysis-shell .leaderboard-name { font-size: 13px; }
  .analysis-shell[data-game=poker] .analysis-leaderboard .leaderboard-score { font-size: 16px; }
  .recent-results li { gap: 12px; grid-template-columns: minmax(0, 1fr) auto 64px; padding: 14px 8px; }
  .recent-results strong { font-size: 16px; }
}
