﻿:root {
  --bg: #050609;
  --wcl-bg: #000;
  --wcl-panel: #101010;
  --wcl-panel-2: #191919;
  --wcl-head: #1f1f1f;
  --wcl-border: #313131;
  --wcl-blue: #8fc7ff;
  --panel: #10141a;
  --panel-2: #151a22;
  --line: #2b3442;
  --line-soft: #1d2530;
  --text: #edf3f8;
  --muted: #8fa0b2;
  --gold: #d9a441;
  --blue: #69b8d7;
  --green: #7dcb74;
  --shadow: 0 18px 60px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--wcl-bg);
  color: var(--text);
  font-family: Verdana, "Segoe UI", sans-serif;
  font-size: 12px;
}

body.loading {
  cursor: progress;
}

.loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: grid;
  place-items: center;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  background: rgba(0, 0, 0, 0.42);
  transition: opacity 140ms ease, visibility 140ms ease;
}

.loading-overlay.active {
  opacity: 1;
  visibility: visible;
}

.loading-box {
  width: min(420px, calc(100vw - 34px));
  border: 1px solid rgba(143, 199, 255, 0.32);
  background: rgba(5, 8, 12, 0.94);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.58);
  padding: 16px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px 14px;
  align-items: center;
}

.loading-box span {
  color: var(--wcl-blue);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.loading-box strong {
  color: var(--text);
  font-size: 1rem;
}

.loading-track {
  grid-column: 1 / -1;
  height: 16px;
  border: 1px solid rgba(143, 199, 255, 0.24);
  background: #05080c;
  overflow: hidden;
}

.loading-track i {
  display: block;
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--wcl-blue));
  transition: width 160ms ease;
}

button,
input,
select {
  font: inherit;
}

button,
a.icon-button {
  cursor: pointer;
}

.app-shell {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  border-right: 1px solid var(--line);
  background: rgba(11, 14, 19, 0.96);
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 0;
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 13px;
}

.guild-mark {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(217, 164, 65, 0.75);
  background: linear-gradient(145deg, rgba(217, 164, 65, 0.22), rgba(105, 184, 215, 0.08));
  color: var(--gold);
  font-weight: 900;
  letter-spacing: 0.06em;
}

.brand-block h1,
.brand-block p,
.topbar h2,
.topbar p,
.panel-head h3,
.panel-head span,
.status-card p {
  margin: 0;
}

.brand-block h1 {
  font-size: 1.08rem;
}

.brand-block p,
.eyebrow,
.panel-kicker {
  color: var(--muted);
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.status-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  background: var(--panel);
}

.status-card p {
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.35;
}

.status-dot {
  width: 10px;
  height: 10px;
  background: #e28b42;
  box-shadow: 0 0 18px #e28b42;
}

.status-card.ready .status-dot {
  background: var(--green);
  box-shadow: 0 0 18px var(--green);
}

.sidebar-tools {
  display: grid;
  gap: 12px;
}

.calendar-card {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--wcl-border);
  background: #090b0f;
}

.calendar-head {
  display: grid;
  grid-template-columns: 30px 1fr 30px;
  align-items: center;
  gap: 8px;
}

.calendar-head strong {
  text-align: center;
  color: #fff;
  font-size: 0.82rem;
}

.calendar-nav {
  min-height: 28px;
  border: 1px solid #354553;
  background: #101722;
  color: #d7e8f5;
  font-weight: 900;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}

.calendar-weekdays span {
  color: #7d8d9b;
  text-align: center;
  font-size: 0.64rem;
  text-transform: uppercase;
}

.calendar-day {
  min-height: 28px;
  border: 1px solid #222a34;
  background: #05070a;
  color: #637283;
  font-size: 0.72rem;
}

.calendar-day.in-month {
  color: #d7e8f5;
}

.calendar-day.has-logs {
  color: #06120a;
  background: linear-gradient(180deg, #7dcb74, #3f8d49);
  border-color: #a0ed93;
  box-shadow: 0 0 12px rgba(125, 203, 116, 0.22);
  font-weight: 900;
}

.calendar-day.selected {
  outline: 2px solid var(--gold);
  outline-offset: -2px;
}

.calendar-day.today:not(.selected) {
  outline: 1px solid var(--wcl-blue);
  outline-offset: -1px;
}

.clear-date {
  min-height: 30px;
}

.primary-action,
.text-button,
.icon-button {
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  min-height: 38px;
}

.primary-action {
  background: linear-gradient(180deg, #2a3340, #171d25);
  border-color: #3f4a57;
}

.text-button {
  padding: 0 13px;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  min-width: 54px;
  height: 38px;
  font-weight: 800;
  padding: 0 11px;
  text-decoration: none;
}

.search-field,
.filter-field {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.78rem;
}

.search-field input,
.filter-field input,
select {
  width: 100%;
  color: var(--text);
  background: #080a0e;
  border: 1px solid var(--line);
  padding: 10px;
  outline: none;
}

select:focus,
input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 2px rgba(105, 184, 215, 0.12);
}

.report-list {
  display: grid;
  gap: 8px;
  overflow: auto;
  padding-right: 4px;
}

.report-item {
  display: grid;
  gap: 7px;
  width: 100%;
  padding: 12px;
  text-align: left;
  border: 1px solid var(--line-soft);
  background: #0b0f15;
  color: var(--text);
}

.report-item.active {
  border-color: var(--gold);
  background: linear-gradient(90deg, rgba(217, 164, 65, 0.17), rgba(16, 20, 26, 0.96));
}

.report-item strong,
.report-item span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.report-item span {
  color: var(--muted);
  font-size: 0.78rem;
}

.workspace {
  min-width: 0;
  padding: 0 16px 16px;
  display: grid;
  gap: 14px;
  align-content: start;
}

.topbar,
.panel-head,
.summary-strip,
.metric-tabs,
.table-tools,
.topbar-actions,
.chart-tools {
  display: flex;
  align-items: center;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  justify-content: space-between;
  gap: 16px;
  min-height: 58px;
  padding: 10px 0;
  border-bottom: 1px solid var(--wcl-border);
  background: rgba(0, 0, 0, 0.96);
}

.topbar h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.65rem;
  color: #fff;
}

.report-title-group {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
}

.report-title-group h2 {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.report-title-group span {
  color: #93a4b4;
  font-size: 0.76rem;
  white-space: nowrap;
}

.topbar-actions,
.table-tools,
.chart-tools {
  gap: 8px;
}

.chart-tools {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.summary-strip {
  display: grid;
  grid-template-columns: minmax(420px, 1.7fr) repeat(3, minmax(120px, 0.55fr));
  border: 1px solid var(--wcl-border);
  background: var(--wcl-panel);
}

.summary-strip article {
  padding: 13px 15px;
  border-right: 1px solid var(--line-soft);
  min-width: 0;
}

.summary-strip article:last-child {
  border-right: 0;
}

.summary-strip span {
  display: block;
  color: var(--muted);
  font-size: 0.73rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.summary-strip strong {
  display: block;
  margin-top: 7px;
  font-size: 1.06rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.selected-fight-card {
  display: grid;
  gap: 8px;
}

.fight-picker-grid {
  display: grid;
  grid-template-columns: minmax(280px, 2fr) minmax(150px, 0.85fr);
  gap: 10px;
  align-items: end;
}

.fight-picker-grid label {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.fight-picker-grid small {
  color: var(--muted);
  font-size: 0.68rem;
  text-transform: uppercase;
}

.fight-picker-grid select {
  padding: 8px 10px;
  font-weight: 800;
  min-width: 0;
}

.fight-select-wide select {
  font-weight: 900;
  min-width: 320px;
}

.boss-tile-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
  max-height: 156px;
  overflow-y: auto;
  padding-right: 2px;
}

.boss-tile {
  position: relative;
  min-height: 72px;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  grid-template-rows: 1fr auto;
  column-gap: 10px;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid rgba(143, 199, 255, 0.18);
  background: #070a0e;
  color: #f4f8ff;
  text-align: left;
  overflow: hidden;
  isolation: isolate;
}

.boss-tile::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--boss-bg-image);
  background-size: cover;
  background-position: center;
  opacity: 0.56;
  z-index: -2;
}

.boss-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(2, 5, 9, 0.25), rgba(2, 5, 9, 0.93) 46%, rgba(2, 5, 9, 0.98));
  z-index: -1;
}

.boss-tile:hover,
.boss-tile.active {
  border-color: var(--boss-accent);
  box-shadow: inset 3px 0 0 var(--boss-accent), 0 0 18px rgba(143, 199, 255, 0.12);
}

.boss-art {
  grid-row: 1 / span 2;
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--boss-accent) 72%, #ffffff 10%);
  background: rgba(0, 0, 0, 0.35);
}

.boss-art em {
  color: #fff;
  font-style: normal;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-shadow: 0 2px 8px #000;
}

.boss-tile strong,
.boss-tile small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.boss-tile strong {
  font-size: 0.82rem;
}

.boss-tile small {
  color: #b6c4d1;
  font-size: 0.68rem;
}

.pull-strip {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 2px 0 1px;
}

.pull-chip {
  flex: 0 0 auto;
  min-width: 128px;
  max-width: 210px;
  display: grid;
  gap: 3px;
  padding: 7px 9px;
  border: 1px solid #2f3945;
  background: #070a0e;
  color: #d7e8f5;
  text-align: left;
}

.pull-chip strong,
.pull-chip span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pull-chip strong {
  color: #fff;
  font-size: 0.78rem;
}

.pull-chip span {
  color: #98a9b8;
  font-size: 0.68rem;
}

.pull-chip.kill {
  border-color: rgba(125, 203, 116, 0.72);
  background: linear-gradient(180deg, rgba(125, 203, 116, 0.18), #070a0e);
}

.pull-chip.wipe {
  border-color: rgba(217, 164, 65, 0.56);
  background: linear-gradient(180deg, rgba(217, 164, 65, 0.14), #070a0e);
}

.pull-chip.active {
  outline: 2px solid var(--wcl-blue);
  outline-offset: -2px;
  box-shadow: 0 0 18px rgba(143, 199, 255, 0.18);
}

.fight-multi-select {
  position: relative;
  min-width: 0;
}

.fight-select-button {
  width: 100%;
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 1px solid #354553;
  background: #c9dde5;
  color: #001018;
  padding: 6px 10px;
  text-align: left;
  font-weight: 800;
}

.fight-select-button::after {
  content: "v";
  color: #243746;
}

.fight-select-button.multi {
  box-shadow: inset 3px 0 0 var(--gold);
}

.fight-select-button span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fight-select-menu {
  position: absolute;
  z-index: 30;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  max-height: 360px;
  overflow-y: auto;
  border: 1px solid rgba(143, 199, 255, 0.36);
  background: #05080d;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.58);
}

.fight-select-all,
.fight-select-option {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  width: 100%;
  border: 0;
  border-bottom: 1px solid #1f2b37;
  background: transparent;
  color: #d7e8f5;
  text-align: left;
}

.fight-select-all {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 8px 10px;
  background: #111820;
}

.fight-select-all em {
  color: var(--muted);
  font-style: normal;
  font-size: 0.72rem;
}

.fight-check,
.fight-jump {
  border: 0;
  background: transparent;
  color: inherit;
}

.fight-check {
  width: 34px;
  height: 100%;
  min-height: 42px;
  display: grid;
  place-items: center;
}

.fight-jump {
  min-width: 0;
  padding: 7px 10px 7px 0;
  text-align: left;
}

.fight-jump strong,
.fight-jump span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fight-jump strong {
  color: #fff;
  font-size: 0.78rem;
}

.fight-jump span {
  color: #98a9b8;
  font-size: 0.68rem;
}

.fight-select-option:hover,
.fight-select-option.active {
  background: rgba(105, 184, 215, 0.08);
}

.fake-checkbox {
  width: 16px;
  height: 16px;
  display: inline-grid;
  place-items: center;
  border: 1px solid #5c6b78;
  background: #05080d;
}

.fake-checkbox.checked {
  border-color: var(--gold);
  background: rgba(217, 164, 65, 0.22);
}

.fake-checkbox.checked::after {
  content: "✓";
  color: var(--gold);
  font-size: 0.82rem;
  font-weight: 900;
  line-height: 1;
}

.fight-select-empty {
  padding: 14px;
  color: var(--muted);
}

.metric-tabs {
  gap: 0;
  overflow-x: auto;
  border-bottom: 1px solid var(--wcl-border);
}

.metric-tab {
  min-width: max-content;
  color: var(--muted);
  background: transparent;
  border: 0;
  border-bottom: 3px solid transparent;
  padding: 12px 16px;
}

.metric-tab.active {
  color: var(--text);
  border-bottom-color: var(--gold);
  background: rgba(217, 164, 65, 0.08);
}

.topbar-tab.active {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(217, 164, 65, 0.12);
}

.chart-panel,
.table-panel,
.pairdown-panel,
.wcl-panel,
.attendance-panel,
.mythicplus-panel {
  border: 1px solid var(--wcl-border);
  background: var(--wcl-panel);
  box-shadow: var(--shadow);
  min-width: 0;
}

.replay-panel,
.pairdown-panel,
.wcl-panel,
.attendance-panel,
.mythicplus-panel {
  display: none;
}

.workspace.view-replay .chart-panel,
.workspace.view-replay .table-panel {
  display: none;
}

.workspace.view-replay .replay-panel {
  display: block;
}

.workspace.view-pairdown .chart-panel,
.workspace.view-pairdown .table-panel,
.workspace.view-pairdown .replay-panel {
  display: none;
}

.workspace.view-pairdown .pairdown-panel {
  display: block;
}

.workspace.view-wcl .chart-panel,
.workspace.view-wcl .table-panel,
.workspace.view-wcl .replay-panel,
.workspace.view-wcl .pairdown-panel,
.workspace.view-wcl .attendance-panel,
.workspace.view-wcl .mythicplus-panel,
.workspace.view-attendance .chart-panel,
.workspace.view-attendance .table-panel,
.workspace.view-attendance .replay-panel,
.workspace.view-attendance .pairdown-panel,
.workspace.view-attendance .wcl-panel,
.workspace.view-attendance .mythicplus-panel,
.workspace.view-attendance .summary-strip,
.workspace.view-attendance .metric-tabs,
.workspace.view-mythicplus .chart-panel,
.workspace.view-mythicplus .table-panel,
.workspace.view-mythicplus .replay-panel,
.workspace.view-mythicplus .pairdown-panel,
.workspace.view-mythicplus .wcl-panel,
.workspace.view-mythicplus .attendance-panel,
.workspace.view-mythicplus .summary-strip,
.workspace.view-mythicplus .metric-tabs {
  display: none;
}

.workspace.view-wcl .wcl-panel,
.workspace.view-attendance .attendance-panel,
.workspace.view-mythicplus .mythicplus-panel {
  display: block;
}

.panel-head {
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--wcl-border);
  background: #050505;
}

.panel-head h3 {
  margin-top: 3px;
  font-size: 1rem;
}

.chart-head {
  align-items: flex-end;
}

.wcl-toolbar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 8px;
  align-items: end;
  padding: 7px 10px;
  background: #080b10;
  border-bottom: 1px solid #1c2732;
}

.wcl-toolbar label {
  min-width: 0;
  display: grid;
  gap: 3px;
  color: #d7e8f5;
}

.wcl-toolbar label span,
.filter-field span {
  font-size: 0.68rem;
  color: #fff;
  text-shadow: 0 1px #000;
}

.wcl-toolbar input,
.wcl-toolbar select,
.table-tools select {
  min-height: 30px;
  border-color: #354553;
  background: #c9dde5;
  color: #001018;
  padding: 6px 8px;
}

.toggle-field {
  grid-column: span 2;
  grid-template-columns: auto 1fr;
  gap: 8px;
  align-items: center;
  min-height: 30px;
  color: #fff;
  font-weight: 800;
}

.toggle-field input {
  width: 30px;
  min-height: 20px;
  accent-color: #cfe3eb;
}

.death-ignore-control {
  grid-template-columns: minmax(0, 1fr) 70px;
  align-items: center;
}

.death-ignore-control input {
  width: 70px;
  text-align: right;
  font-weight: 800;
}

.filter-expression {
  grid-column: span 2;
  grid-template-columns: 1fr;
  align-items: center;
}

.target-filter,
.ability-filter,
.player-filter {
  grid-template-columns: 1fr;
}

.selected-player-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 6px 10px;
  border-bottom: 1px solid #202020;
  background: #080b10;
}

.pin-empty {
  color: #8192a3;
  font-size: 0.74rem;
}

.pin-chip,
.pin-clear {
  min-height: 24px;
  border: 1px solid #2f3945;
  background: #05080d;
  color: #d7e8f5;
  font-weight: 800;
}

.pin-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-color: color-mix(in srgb, var(--pin-color), #2f3945 42%);
}

.pin-chip .spec-icon {
  width: 20px;
  height: 20px;
  border-color: color-mix(in srgb, var(--pin-color), #404040 55%);
}

.pin-chip em {
  color: #9fb0c0;
  font-style: normal;
}

.pin-chip:hover,
.pin-clear:hover {
  color: #fff;
  border-color: var(--wcl-blue);
}

.pin-clear {
  padding: 0 9px;
  color: var(--gold);
}

.data-source-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-bottom: 1px solid #202020;
  background: #050505;
  color: #9fb0c0;
  font-size: 0.72rem;
}

.data-source-strip span {
  padding: 2px 7px;
  border: 1px solid #222b34;
  background: #080b10;
}

.data-source-strip em {
  color: #43505c;
  font-style: normal;
}

.data-source-strip strong {
  color: var(--gold);
}

.chart-legend {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
  min-height: 30px;
  padding: 6px 10px 4px;
  background: #111;
  border-bottom: 1px solid #202020;
  color: #aab2ba;
  font-size: 0.75rem;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.legend-item.player {
  cursor: pointer;
  padding: 3px 6px;
  border: 1px solid transparent;
}

.legend-item.player:hover,
.legend-item.player:focus,
.legend-item.player.active {
  color: #fff;
  border-color: rgba(143, 199, 255, 0.42);
  background: rgba(143, 199, 255, 0.08);
  outline: none;
}

.legend-item.total {
  color: #d7e8f5;
  font-weight: 800;
}

.legend-item .spec-icon {
  width: 20px;
  height: 20px;
}

.legend-swatch {
  width: 18px;
  height: 2px;
  box-shadow: 0 0 0 1px rgba(255,255,255,0.12);
}

.timeline-wrap {
  position: relative;
  background: #0d0d0d;
}

canvas {
  width: 100%;
  height: 360px;
  display: block;
}

.chart-tooltip {
  position: absolute;
  pointer-events: none;
  z-index: 5;
  min-width: 210px;
  max-width: 320px;
  padding: 8px 10px;
  border: 1px solid #617184;
  background: rgba(0, 0, 0, 0.88);
  color: #fff;
  box-shadow: 0 8px 24px rgba(0,0,0,0.55);
  font-size: 0.76rem;
  line-height: 1.45;
}

.chart-tooltip-player,
.replay-readout-player {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.chart-tooltip-player .spec-icon,
.replay-readout-player .spec-icon {
  width: 18px;
  height: 18px;
}

.event-rail {
  position: relative;
  min-height: 34px;
  border-top: 1px solid #202020;
  border-bottom: 1px solid #202020;
  background: repeating-linear-gradient(90deg, #06080b 0, #06080b 39px, #0b1016 40px);
  overflow: hidden;
}

.event-marker {
  position: absolute;
  top: 6px;
  width: 7px;
  height: 22px;
  border: 1px solid rgba(255,255,255,0.22);
  transform: translateX(-50%);
  box-shadow: 0 0 9px rgba(255,255,255,0.16);
}

.event-marker.death {
  background: #d6473d;
  box-shadow: 0 0 10px rgba(214,71,61,0.45);
}

.event-marker.filtered {
  background: #8fc7ff;
  box-shadow: 0 0 10px rgba(143,199,255,0.42);
}

.event-rail-empty {
  display: block;
  padding: 9px 13px;
  color: #7f91a5;
  font-size: 0.72rem;
}

.timeline-footer {
  border-top: 1px solid var(--line-soft);
  color: #b9dfff;
  padding: 8px 15px;
  font-size: 0.82rem;
  background: #090d13;
}

.timeline-analysis {
  padding: 10px 13px;
  min-height: 46px;
  border-top: 1px solid #27303a;
  color: #d6e8f7;
  background: #080a0d;
  line-height: 1.65;
}

.bucket-card {
  display: grid;
  gap: 5px;
  margin-bottom: 8px;
  padding: 8px 10px;
  border: 1px solid #242c34;
  background: #05080d;
}

.bucket-card.pinned {
  border-color: rgba(217, 164, 65, 0.7);
  background: linear-gradient(90deg, rgba(217, 164, 65, 0.12), #05080d);
}

.bucket-card span {
  color: #b9dfff;
}

.bucket-actions {
  display: flex;
  gap: 7px;
}

.bucket-focus {
  width: max-content;
  min-height: 25px;
  border: 1px solid rgba(217, 164, 65, 0.65);
  background: #080b10;
  color: var(--gold);
  font-weight: 900;
  padding: 3px 9px;
}

.bucket-focus:hover {
  border-color: var(--wcl-blue);
  color: #fff;
}

.bucket-leaders {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.bucket-leader {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--leader-color);
  white-space: nowrap;
}

.bucket-leader .spec-icon {
  width: 18px;
  height: 18px;
}

.bucket-leader em {
  color: #9fb0c0;
  font-style: normal;
}

.bucket-leader.empty {
  color: #9fb0c0;
}

.timeline-analysis strong {
  color: #fff;
}

.death-event-list {
  display: grid;
  gap: 5px;
}

.death-event-row {
  position: relative;
  display: grid;
  grid-template-columns: 45px minmax(90px, 0.35fr) minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-height: 28px;
  padding: 4px 7px;
  border: 1px solid #222b34;
  background: #070a0e;
}

.death-time {
  color: #ffb0a8;
  font-weight: 900;
}

.death-player {
  color: #fff;
  outline: none;
}

.death-event-row em {
  min-width: 0;
  color: #c7d7e5;
  font-style: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.death-ability-button {
  border: 0;
  padding: 0;
  background: transparent;
  color: #8fc7ff;
  font-weight: 900;
  text-align: left;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.death-timeline-popover {
  position: absolute;
  left: 45px;
  top: calc(100% + 6px);
  z-index: 18;
  width: min(620px, calc(100vw - 390px));
  max-width: 620px;
  display: none;
  gap: 7px;
  padding: 10px;
  border: 1px solid rgba(143, 199, 255, 0.48);
  background: #020407;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.58);
}

.death-event-row:hover .death-timeline-popover,
.death-player:focus + em + .death-timeline-popover,
.death-timeline-popover:hover {
  display: grid;
}

.death-timeline-head,
.death-health-readout,
.death-timeline-hit {
  display: grid;
  grid-template-columns: 82px minmax(160px, 1fr) 90px minmax(130px, 0.8fr);
  gap: 8px;
  align-items: center;
}

.death-timeline-head {
  grid-template-columns: 1fr auto;
  color: #fff;
}

.death-timeline-head span,
.death-health-readout span {
  color: #9fb0c0;
}

.death-health-readout {
  grid-template-columns: 1fr auto;
  padding: 6px 7px;
  border: 1px solid #1d2934;
  background: #080d13;
}

.death-health-readout em {
  color: #d9a441;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.death-timeline-list {
  display: grid;
  gap: 4px;
}

.death-timeline-hit {
  min-height: 28px;
}

.death-hit-time {
  color: #ffb0a8;
}

.timeline-ability {
  max-width: 230px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.death-health-track {
  position: relative;
  height: 10px;
  border: 1px solid #34404c;
  background: #2c0707;
  overflow: hidden;
}

.death-health-track i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #d6473d, #d9a441, #7dcb74);
}

.death-health-track em {
  position: absolute;
  inset: -2px 4px 0 auto;
  color: #fff;
  font-size: 0.58rem;
  font-style: normal;
  font-weight: 900;
  line-height: 12px;
  text-shadow: 0 1px 2px #000;
  white-space: nowrap;
}

.death-timeline-empty {
  color: #9fb0c0;
}

.ability-popup {
  position: fixed;
  z-index: 80;
  padding: 11px;
  border: 1px solid rgba(143, 199, 255, 0.55);
  background: #030507;
  color: #d7e8f5;
  box-shadow: 0 18px 55px rgba(0,0,0,0.65);
}

.ability-popup-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: #fff;
}

.ability-popup-head span {
  color: #93a4b4;
}

.ability-popup p {
  margin: 8px 0;
  line-height: 1.45;
}

.ability-popup-grid {
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 5px 9px;
}

.ability-popup-grid span {
  color: #8fa0b2;
}

.replay-panel {
  border: 1px solid var(--wcl-border);
  background: var(--wcl-panel);
  box-shadow: var(--shadow);
  min-width: 0;
}

.replay-head {
  align-items: center;
}

.replay-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.replay-controls label {
  display: grid;
  gap: 3px;
  color: #d7e8f5;
  font-size: 0.68rem;
}

.replay-controls select {
  min-height: 30px;
  border-color: #354553;
  background: #c9dde5;
  color: #001018;
  padding: 6px 8px;
}

#replayClock {
  display: inline-grid;
  place-items: center;
  min-width: 58px;
  min-height: 30px;
  border: 1px solid #354553;
  color: #fff;
  background: #05080d;
}

.replay-stage-wrap {
  position: relative;
  min-height: 360px;
  background:
    radial-gradient(circle at 50% 44%, rgba(104, 152, 118, 0.18), transparent 28%),
    radial-gradient(circle at 26% 66%, rgba(105, 184, 215, 0.12), transparent 22%),
    linear-gradient(145deg, #080b0d, #11120f 48%, #08090a);
  background-position: center;
  background-size: cover;
  overflow: hidden;
}

.replay-stage-wrap.has-map {
  background-image:
    linear-gradient(180deg, rgba(0, 0, 0, 0.28), rgba(0, 0, 0, 0.38)),
    var(--replay-map-image);
  background-size: cover, contain;
  background-repeat: no-repeat;
  background-color: #05080d;
}

.replay-stage-wrap::before {
  content: "";
  position: absolute;
  inset: 22px;
  border: 1px solid rgba(217, 164, 65, 0.32);
  box-shadow: inset 0 0 80px rgba(0,0,0,0.35), 0 0 26px rgba(217,164,65,0.12);
  pointer-events: none;
}

#replayStage {
  width: 100%;
  height: 420px;
  display: block;
}

.replay-readout {
  position: absolute;
  left: 12px;
  bottom: 10px;
  max-width: min(520px, calc(100% - 24px));
  padding: 8px 10px;
  border: 1px solid rgba(143, 199, 255, 0.35);
  background: rgba(0,0,0,0.72);
  color: #d7e8f5;
  line-height: 1.45;
}

.replay-readout-summary,
.replay-readout-leaders {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.replay-readout-summary span {
  color: #9fb0c0;
}

.replay-readout-summary em {
  color: #53606c;
  font-style: normal;
}

.replay-readout-leaders {
  margin-top: 5px;
  gap: 10px;
}

.replay-readout-label {
  color: #8fa0b2;
  font-size: 0.66rem;
  text-transform: uppercase;
}

.replay-readout-empty {
  color: #9fb0c0;
}

.replay-scrub {
  width: 100%;
  display: block;
  accent-color: var(--wcl-blue);
  background: #050505;
  border-top: 1px solid #252525;
}

.data-table {
  overflow: visible;
  overflow-x: hidden;
  background: #000;
}

.row {
  display: grid;
  grid-template-columns: 54px minmax(120px, var(--name-col, 18ch)) minmax(360px, 1fr) 52px 60px 66px 80px 34px;
  align-items: center;
  gap: 8px;
  min-height: 31px;
  padding: 0 10px;
  border: 0;
  border-bottom: 1px solid #252525;
  background: transparent;
  color: var(--text);
  text-align: left;
  width: 100%;
}

.row.aura-table {
  grid-template-columns: 50px minmax(180px, 1.35fr) minmax(210px, 1.55fr) 66px 74px minmax(100px, 0.8fr) 70px 34px;
}

.row.interrupt-table {
  grid-template-columns: 50px minmax(150px, 1fr) minmax(170px, 1.25fr) 50px minmax(120px, 0.95fr) minmax(115px, 0.9fr) minmax(100px, 0.8fr) 34px;
}

.row.death-table-view {
  grid-template-columns: 50px minmax(150px, 1fr) minmax(180px, 1.25fr) 58px minmax(140px, 1fr) minmax(100px, 0.8fr) 80px 34px;
}

.row.target-table {
  grid-template-columns: 50px minmax(160px, 1fr) minmax(220px, 1.5fr) 72px minmax(130px, 0.95fr) 86px 82px 34px;
}

.row.ability-table {
  grid-template-columns: 50px minmax(180px, 1.2fr) minmax(220px, 1.45fr) 80px 72px 86px 82px 34px;
}

.row > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.row.header {
  min-height: 32px;
  color: #fff;
  font-size: 0.76rem;
  text-transform: none;
  background: #222;
  font-weight: 800;
  position: sticky;
  top: 0;
  z-index: 2;
}

.table-sort {
  all: unset;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #fff;
}

.table-sort:hover,
.table-sort:focus {
  color: var(--wcl-blue);
  outline: none;
}

.table-sort.active {
  color: var(--gold);
}

.table-sort em {
  color: #9fb0c0;
  font-size: 0.62rem;
  font-style: normal;
  text-transform: uppercase;
}

.data-row:hover,
.data-row.selected {
  background: rgba(105, 184, 215, 0.08);
}

.data-row {
  cursor: pointer;
}

.data-row.selected {
  outline: 1px solid rgba(105, 184, 215, 0.45);
  outline-offset: -1px;
}

.expand-player {
  width: 28px;
  height: 24px;
  border: 1px solid #3b4652;
  background: #05080d;
  color: #fff;
  font-weight: 900;
}

.player-detail-row {
  padding: 12px 14px 13px 94px;
  border-bottom: 1px solid #252525;
  border-left: 3px solid var(--detail-color);
  background: linear-gradient(90deg, rgba(255,255,255,0.03), rgba(0,0,0,0.1));
}

.detail-title {
  margin-bottom: 9px;
  color: var(--detail-color);
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 10px;
}

.detail-grid div {
  padding: 8px;
  border: 1px solid #242c34;
  background: #05080d;
}

.detail-grid span {
  display: block;
  color: #8192a3;
  font-size: 0.68rem;
  text-transform: uppercase;
}

.detail-grid strong {
  display: block;
  margin-top: 4px;
  color: #fff;
}

.detail-buckets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.breakdown-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.breakdown-section {
  min-width: 0;
  border: 1px solid #242c34;
  background: #05080d;
}

.breakdown-section h4 {
  margin: 0;
  padding: 8px 10px;
  border-bottom: 1px solid #202832;
  color: #d7e8f5;
  font-size: 0.78rem;
  letter-spacing: 0;
  text-transform: uppercase;
}

.breakdown-list {
  display: grid;
  gap: 1px;
}

.breakdown-row {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(90px, 0.65fr) 82px 54px;
  align-items: center;
  gap: 9px;
  min-height: 28px;
  padding: 6px 9px;
  background: rgba(255,255,255,0.018);
}

.breakdown-name {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  overflow: hidden;
  color: #f0f6fb;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.breakdown-name .spec-icon {
  width: 18px;
  height: 18px;
}

.breakdown-bar {
  height: 8px;
  overflow: hidden;
  border: 1px solid #242c34;
  background: #090d13;
}

.breakdown-bar i {
  display: block;
  height: 100%;
  background: var(--detail-color);
}

.breakdown-row strong {
  color: #fff;
  text-align: right;
}

.breakdown-row em {
  color: #8fa0b2;
  font-style: normal;
  text-align: right;
}

.death-detail-hit .breakdown-bar i {
  background: #d6473d;
}

.death-detail-hit .breakdown-name em {
  color: #8fa0b2;
  font-size: 0.68rem;
  margin-left: 4px;
}

.detail-chip {
  display: grid;
  grid-template-columns: 46px 110px auto;
  gap: 7px;
  align-items: center;
  padding: 6px 8px;
  border: 1px solid #242c34;
  background: #000;
}

.detail-chip strong {
  color: #fff;
}

.detail-chip em {
  color: #d7e8f5;
  font-style: normal;
}

.mini-bar {
  height: 8px;
  background: #101010;
  border: 1px solid #242c34;
  overflow: hidden;
}

.mini-bar i {
  display: block;
  height: 100%;
}

.empty-detail {
  padding: 8px 10px;
  color: #8fa0b2;
}

.parse {
  font-weight: 900;
}

.player-name {
  display: flex;
  align-items: center;
  gap: 7px;
  font-weight: 850;
  min-width: 0;
}

.player-name strong,
.player-name small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.player-name small {
  color: var(--muted);
  font-weight: 500;
}

.spec-icon {
  width: 24px;
  height: 24px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid #404040;
  background: #10151b;
  color: #d7e8f5;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.spec-icon img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.spec-icon em {
  display: none;
  font-size: 0.62rem;
  font-style: normal;
  font-weight: 900;
}

.spec-icon.fallback em {
  display: block;
}

.inline-ability-icon {
  width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  margin-right: 6px;
  vertical-align: -4px;
  border: 1px solid #404040;
  background: #10151b;
  overflow: hidden;
}

.inline-ability-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.amount-cell {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) minmax(92px, max-content);
  align-items: center;
  gap: 6px;
}

.bar-track {
  height: 16px;
  background: #05070a;
  border: 1px solid #1f1f1f;
  position: relative;
  overflow: hidden;
}

.bar-fill {
  position: absolute;
  inset: 0 auto 0 0;
  opacity: 0.88;
}

.amount-value {
  color: #fff;
  font-style: normal;
  font-size: 0.78rem;
  text-align: right;
  text-shadow: 0 1px 2px #000;
  font-weight: 800;
}

.table-panel {
  min-height: 510px;
}

.pairdown-panel {
  min-height: 510px;
  background: #05080d;
}

.pairdown-head {
  align-items: center;
}

.pairdown-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.pairdown-tab {
  border: 1px solid #314354;
  background: rgba(105, 184, 215, 0.08);
  color: #d7e8f5;
  min-height: 30px;
  padding: 5px 10px;
  font-weight: 800;
}

.pairdown-tab.active {
  border-color: var(--gold);
  background: rgba(217, 164, 65, 0.16);
  color: #fff;
}

.pairdown-content {
  padding: 12px;
}

.pairdown-summary-grid,
.pairdown-watch-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.pairdown-card {
  border: 1px solid #263747;
  background: linear-gradient(180deg, rgba(13, 24, 35, 0.95), rgba(3, 5, 8, 0.95));
  padding: 12px;
  min-width: 0;
}

.pairdown-wide {
  grid-column: 1 / -1;
}

.pairdown-card > span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.pairdown-card > strong {
  display: block;
  color: #fff;
  font-size: 1rem;
}

.pairdown-card p {
  margin: 6px 0 0;
  color: var(--text-soft);
}

.pairdown-weights {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 9px;
}

.pairdown-weights span {
  border: 1px solid #314354;
  background: rgba(0, 0, 0, 0.28);
  padding: 5px 8px;
  color: #d7e8f5;
}

.pairdown-callout-list {
  display: grid;
  gap: 6px;
  margin-top: 8px;
}

.pairdown-callout-row {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) minmax(108px, 0.7fr) minmax(92px, 0.62fr) 86px minmax(110px, 0.8fr);
  align-items: center;
  gap: 8px;
  min-width: 0;
  border: 1px solid rgba(217, 164, 65, 0.22);
  background: rgba(0, 0, 0, 0.24);
  padding: 6px 8px;
}

.pairdown-callout-row strong,
.pairdown-callout-row em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pairdown-metric {
  display: grid;
  gap: 1px;
  min-width: 0;
}

.pairdown-metric b,
.pairdown-metric em {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pairdown-metric b {
  color: #fff;
  font-size: 0.78rem;
}

.pairdown-metric em {
  color: var(--muted);
  font-size: 0.62rem;
  font-style: normal;
}

.pairdown-callout-row em {
  color: var(--text-soft);
  font-style: normal;
}

.pairdown-full-score-list {
  display: grid;
  gap: 5px;
  margin-top: 8px;
}

.pairdown-score-row {
  display: grid;
  grid-template-columns: 38px minmax(170px, 260px) minmax(440px, 1fr) 124px 86px;
  align-items: center;
  gap: 8px;
  min-width: 0;
  border: 1px solid #263747;
  background: rgba(0, 0, 0, 0.2);
  padding: 6px 8px;
}

.pairdown-score-row > span {
  color: var(--muted);
  font-weight: 900;
}

.pairdown-score-head {
  min-height: 30px;
  background: #1c242e;
  color: #fff;
  font-size: 0.72rem;
  text-transform: uppercase;
}

.pairdown-score-head strong,
.pairdown-score-head em,
.pairdown-score-head span {
  color: #fff;
  font-style: normal;
  font-weight: 900;
}

.pairdown-score-row strong,
.pairdown-score-row em,
.pairdown-score-row small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pairdown-score-row em {
  color: var(--text-soft);
  font-style: normal;
}

.pairdown-score-row small {
  color: var(--muted);
}

.pairdown-bar-cell {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  min-width: 0;
}

.pairdown-bar-cell > small {
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 800;
  text-transform: uppercase;
}

.pairdown-bar-cell .bar-track {
  min-width: 0;
}

.pairdown-rate-value {
  color: #fff;
  font-weight: 900;
  padding-right: 12px;
  text-align: right;
}

.pairdown-score {
  display: inline-flex;
  justify-content: center;
  min-width: 62px;
  border: 1px solid #38506a;
  background: rgba(105, 184, 215, 0.11);
  color: #d7e8f5;
  padding: 4px 7px;
  font-weight: 900;
}

.pairdown-score.critical {
  border-color: rgba(214, 71, 61, 0.62);
  background: rgba(214, 71, 61, 0.14);
  color: #ffb7b2;
}

.pairdown-score.warning {
  border-color: rgba(217, 164, 65, 0.62);
  background: rgba(217, 164, 65, 0.14);
  color: #ffdca2;
}

.pairdown-score.ok {
  border-color: rgba(64, 191, 136, 0.55);
  background: rgba(64, 191, 136, 0.12);
  color: #b7ffd9;
}

.pairdown-table {
  overflow-x: auto;
  border: 1px solid #253442;
  background: #000;
}

.pairdown-row {
  display: grid;
  grid-template-columns: 54px minmax(190px, 1fr) 86px minmax(118px, 0.8fr) 76px minmax(108px, 0.8fr) 82px 78px 58px 68px;
  gap: 8px;
  align-items: center;
  min-width: 1030px;
  min-height: 34px;
  padding: 0 10px;
  border-bottom: 1px solid #252525;
}

.pairdown-table.healing .pairdown-row {
  grid-template-columns: 54px minmax(190px, 1fr) 86px minmax(118px, 0.8fr) 76px minmax(108px, 0.8fr) 82px 78px 58px 68px minmax(95px, 0.7fr);
  min-width: 1130px;
}

.pairdown-row > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pairdown-row-head {
  position: sticky;
  top: 0;
  z-index: 1;
  min-height: 32px;
  background: #222;
  color: #fff;
  font-size: 0.76rem;
  font-weight: 800;
}

.pairdown-name {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.pairdown-scope {
  color: var(--muted);
  font-size: 0.66rem;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}

.pairdown-watch-table {
  display: grid;
  gap: 7px;
  margin-top: 8px;
}

.pairdown-watch-table div {
  border: 1px solid #263747;
  background: rgba(0, 0, 0, 0.24);
  padding: 8px;
}

.pairdown-watch-table strong {
  color: #fff;
}

.player-name-token {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 0 10px 4px 0;
  min-width: 0;
  vertical-align: middle;
}

.player-name-token .spec-icon {
  width: 18px;
  height: 18px;
}

.player-name-token strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pairdown-empty {
  padding: 24px 14px;
  border: 1px solid #263747;
  background: rgba(0, 0, 0, 0.22);
  color: var(--muted);
}

.empty-state {
  padding: 24px 14px;
  color: var(--muted);
}

.wcl-home,
.attendance-content {
  display: grid;
  gap: 14px;
  padding: 14px;
}

.wcl-home-grid,
.attendance-summary-grid,
.attendance-role-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 10px;
}

.wcl-home-card,
.attendance-summary-grid article,
.attendance-role-grid article,
.attendance-card {
  border: 1px solid var(--wcl-border);
  background: rgba(6, 10, 15, 0.84);
  padding: 12px;
}

.wcl-home-card span,
.attendance-summary-grid span,
.attendance-role-grid span,
.attendance-card-head span {
  display: block;
  color: var(--wcl-blue);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.wcl-home-card strong,
.attendance-summary-grid strong,
.attendance-role-grid strong {
  display: block;
  margin-top: 5px;
  color: var(--text);
  font-size: 1.25rem;
}

.wcl-home-card p,
.attendance-summary-grid p,
.attendance-role-grid p {
  margin: 6px 0 0;
  color: var(--muted);
}

.wcl-report-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 9px;
}

.wcl-home-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(420px, 1.35fr);
  gap: 14px;
  align-items: start;
}

.wcl-section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 10px;
  margin-bottom: 9px;
  border-bottom: 1px solid var(--wcl-border);
  padding-bottom: 7px;
}

.wcl-section-head strong {
  color: var(--text);
}

.wcl-section-head span {
  color: var(--muted);
  font-size: 0.76rem;
}

.wcl-report-card {
  min-height: 88px;
  text-align: left;
  border: 1px solid var(--wcl-border);
  background: #06090e;
  color: var(--text);
  padding: 10px;
}

.wcl-report-card.active {
  border-color: var(--gold);
  box-shadow: inset 0 0 0 1px rgba(217, 164, 65, 0.28);
}

.wcl-report-card strong,
.wcl-report-card span,
.wcl-report-card em {
  display: block;
}

.wcl-report-card span {
  margin-top: 7px;
  color: var(--muted);
}

.wcl-report-card em {
  margin-top: 5px;
  color: var(--wcl-blue);
  font-style: normal;
}

.wcl-boss-list {
  display: grid;
  gap: 12px;
}

.wcl-boss-group {
  border: 1px solid var(--wcl-border);
  background: rgba(0, 0, 0, 0.22);
}

.wcl-boss-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 10px;
  border-bottom: 1px solid var(--wcl-border);
  background: rgba(143, 199, 255, 0.04);
}

.wcl-boss-head strong {
  color: var(--text);
}

.wcl-boss-head span {
  color: var(--muted);
  font-size: 0.78rem;
}

.wcl-pull-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(125px, 1fr));
  gap: 6px;
  padding: 8px;
}

.wcl-pull-card {
  min-height: 68px;
  text-align: left;
  border: 1px solid rgba(143, 199, 255, 0.16);
  background: #05080d;
  color: var(--text);
  padding: 8px;
}

.wcl-pull-card span,
.wcl-pull-card strong,
.wcl-pull-card em {
  display: block;
}

.wcl-pull-card span {
  color: var(--wcl-blue);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.wcl-pull-card strong {
  margin-top: 5px;
}

.wcl-pull-card em {
  margin-top: 4px;
  color: var(--muted);
  font-style: normal;
}

.wcl-pull-card.kill {
  border-color: rgba(67, 181, 129, 0.42);
}

.wcl-pull-card.wipe {
  border-color: rgba(214, 71, 61, 0.34);
}

.wcl-pull-card.active {
  border-color: var(--gold);
  box-shadow: inset 0 0 0 1px rgba(217, 164, 65, 0.28);
}

.attendance-head {
  align-items: center;
}

.attendance-tools {
  display: flex;
  align-items: end;
  gap: 8px;
  flex-wrap: wrap;
}

.attendance-tools label {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.attendance-tools select {
  min-width: 230px;
}

.attendance-card {
  display: grid;
  gap: 12px;
}

.attendance-card-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 10px;
}

.attendance-card-head strong {
  color: var(--text);
  font-size: 1rem;
}

.attendance-night-graph {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(22px, 1fr));
  align-items: end;
  gap: 5px;
  min-height: 180px;
  padding: 10px 8px 4px;
  border: 1px solid rgba(143, 199, 255, 0.16);
  background: linear-gradient(180deg, rgba(143, 199, 255, 0.05), rgba(0, 0, 0, 0.12));
}

.attendance-night {
  display: grid;
  grid-template-rows: 1fr auto;
  gap: 5px;
  height: 170px;
}

.attendance-night span {
  align-self: end;
  min-height: 4px;
  background: linear-gradient(180deg, var(--wcl-blue), #1d6fb1);
  border: 1px solid rgba(255,255,255,0.16);
}

.attendance-night em {
  color: var(--muted);
  font-size: 0.62rem;
  font-style: normal;
  text-align: center;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}

.attendance-player-table {
  display: grid;
  gap: 4px;
}

.attendance-player-head,
.attendance-player-row {
  display: grid;
  grid-template-columns: minmax(130px, 1.2fr) 90px minmax(260px, 2fr) 70px 80px;
  gap: 8px;
  align-items: center;
}

.attendance-player-head {
  color: var(--wcl-blue);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
  padding: 0 8px 4px;
}

.attendance-player-row {
  min-height: 36px;
  border: 1px solid rgba(143, 199, 255, 0.12);
  background: rgba(0,0,0,0.22);
  padding: 6px 8px;
}

.attendance-player-row strong {
  color: var(--text);
}

.attendance-player-row em {
  color: var(--muted);
  font-style: normal;
}

.attendance-bar-cell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 58px;
  align-items: center;
  gap: 8px;
}

.attendance-bar {
  position: relative;
  height: 18px;
  border: 1px solid rgba(143, 199, 255, 0.22);
  background: #05080c;
  overflow: hidden;
}

.attendance-bar i {
  position: absolute;
  inset: 0 auto 0 0;
  background: linear-gradient(90deg, var(--gold), #62d28f);
}

.attendance-bar-cell b {
  color: #fff;
  font-size: 0.72rem;
  text-align: right;
  font-weight: 900;
}

.attendance-empty {
  padding: 18px;
  color: var(--muted);
  border: 1px dashed var(--line);
  background: rgba(255,255,255,0.02);
}

.mythicplus-head {
  align-items: center;
}

.mythicplus-tools {
  display: flex;
  align-items: end;
  gap: 8px;
  flex-wrap: wrap;
}

.mythicplus-tools label {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.mythicplus-tools select {
  min-width: 190px;
}

.mythicplus-content {
  display: grid;
  gap: 14px;
  padding: 14px;
}

.mythicplus-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 10px;
}

.mythicplus-summary-grid article,
.mythicplus-card {
  border: 1px solid var(--wcl-border);
  background: rgba(6, 10, 15, 0.84);
  padding: 12px;
}

.mythicplus-summary-grid span {
  display: block;
  color: var(--wcl-blue);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.mythicplus-summary-grid strong {
  display: block;
  margin-top: 5px;
  color: var(--text);
  font-size: 1.25rem;
}

.mythicplus-summary-grid p,
.mythicplus-card p {
  margin: 6px 0 0;
  color: var(--muted);
}

.mythicplus-card {
  display: grid;
  gap: 12px;
}

.mythicplus-week-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(72px, 1fr));
  gap: 8px;
}

.mythicplus-week-grid div {
  position: relative;
  min-height: 56px;
  border: 1px solid rgba(143, 199, 255, 0.16);
  background: #05080c;
  padding: 8px;
  overflow: hidden;
}

.mythicplus-week-grid i {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 4px;
  background: var(--gold);
}

.mythicplus-week-grid span,
.mythicplus-week-grid b {
  position: relative;
  z-index: 1;
  display: block;
}

.mythicplus-week-grid span {
  color: var(--wcl-blue);
  font-weight: 900;
}

.mythicplus-week-grid b {
  margin-top: 7px;
  color: #fff;
  font-size: 1.1rem;
}

.mythicplus-day-graph {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(34px, 1fr));
  align-items: end;
  gap: 6px;
  min-height: 190px;
  padding: 10px 8px 4px;
  border: 1px solid rgba(143, 199, 255, 0.16);
  background: linear-gradient(180deg, rgba(143, 199, 255, 0.05), rgba(0, 0, 0, 0.12));
}

.mythicplus-day {
  display: grid;
  grid-template-rows: 1fr auto auto;
  gap: 4px;
  height: 180px;
  min-width: 0;
}

.mythicplus-day span {
  align-self: end;
  min-height: 4px;
  background: linear-gradient(180deg, #69b8d7, #6846b8);
  border: 1px solid rgba(255,255,255,0.16);
}

.mythicplus-day strong,
.mythicplus-day em {
  color: var(--muted);
  font-size: 0.62rem;
  font-style: normal;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mythicplus-day strong {
  color: var(--text);
}

.mythicplus-player-table {
  display: grid;
  gap: 4px;
}

.mythicplus-player-head,
.mythicplus-player-row {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) 76px minmax(220px, 1.3fr) 54px 62px minmax(130px, 1fr) minmax(180px, 1.4fr);
  gap: 9px;
  align-items: center;
}

.mythicplus-player-head {
  color: var(--wcl-blue);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
  padding: 0 8px 4px;
}

.mythicplus-player-row {
  min-height: 38px;
  border: 1px solid rgba(143, 199, 255, 0.12);
  background: rgba(0,0,0,0.22);
  padding: 6px 8px;
}

.mythicplus-player-row strong,
.mythicplus-player-row span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mythicplus-player-row em {
  display: block;
  color: var(--muted);
  font-size: 0.7rem;
  font-style: normal;
}

.mythicplus-bar-cell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 44px;
  align-items: center;
  gap: 8px;
}

.mythicplus-bar-cell b {
  color: #fff;
  text-align: right;
}

.mythicplus-bar {
  position: relative;
  display: block;
  height: 18px;
  border: 1px solid rgba(143, 199, 255, 0.22);
  background: #05080c;
  overflow: hidden;
}

.mythicplus-bar i {
  position: absolute;
  inset: 0 auto 0 0;
  background: linear-gradient(90deg, var(--wcl-blue), var(--gold));
}

.mythicplus-dungeon-grid,
.mythicplus-run-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 9px;
}

.mythicplus-dungeon-card,
.mythicplus-run-card {
  border: 1px solid rgba(143, 199, 255, 0.16);
  background: #05080c;
  color: var(--text);
  padding: 10px;
}

.mythicplus-dungeon-card div {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mythicplus-dungeon-card img {
  width: 28px;
  height: 28px;
  object-fit: cover;
  border: 1px solid rgba(255,255,255,0.18);
}

.mythicplus-dungeon-card .mythicplus-bar {
  margin-top: 9px;
}

.mythicplus-run-card {
  display: grid;
  gap: 5px;
  min-height: 126px;
  background-size: cover;
  background-position: center;
  text-decoration: none;
}

.mythicplus-run-card span {
  color: var(--wcl-blue);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.mythicplus-run-card strong {
  color: var(--text);
  font-size: 1rem;
}

.mythicplus-run-card em,
.mythicplus-run-card small {
  color: var(--muted);
  font-style: normal;
}

.mythicplus-run-card p {
  margin: 0;
  color: #d8e6f5;
}

@media (max-width: 1180px) {
  .app-shell {
    grid-template-columns: 280px minmax(0, 1fr);
  }

  .wcl-home-layout {
    grid-template-columns: 1fr;
  }

  .summary-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .selected-fight-card {
    grid-column: 1 / -1;
  }

  .wcl-toolbar {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .toggle-field,
  .death-ignore-control,
  .filter-expression,
  .player-filter {
    grid-column: 1 / -1;
  }
}

@media (max-width: 860px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    max-height: 55vh;
  }

  .workspace {
    padding: 16px;
  }

  .summary-strip {
    grid-template-columns: 1fr;
  }

  .fight-picker-grid {
    grid-template-columns: 1fr;
  }

  .chart-head {
    align-items: stretch;
    flex-direction: column;
  }

  .chart-tools {
    justify-content: stretch;
  }

  .pairdown-summary-grid,
  .pairdown-watch-grid {
    grid-template-columns: 1fr;
  }

  .pairdown-head {
    align-items: stretch;
    flex-direction: column;
  }

  .pairdown-tabs {
    justify-content: flex-start;
  }

  .filter-field {
    width: 100%;
  }

  .row {
    grid-template-columns: 48px minmax(130px, 1fr) minmax(180px, 1.2fr) 78px;
  }

  .row span:nth-child(4),
  .row span:nth-child(5),
  .row span:nth-child(6),
  .row span:nth-child(8) {
    display: none;
  }
}

.empty-table-row {
  color: var(--muted);
  background: rgba(143, 199, 255, 0.035);
}

.empty-table-row span:nth-child(3) {
  grid-column: span 1;
  color: var(--text-soft);
}

.bucket-card.deaths {
  border-color: rgba(214, 71, 61, 0.62);
  background: linear-gradient(90deg, rgba(214, 71, 61, 0.12), #05080d 58%);
}

.death-event-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 6px;
}

.death-event-row {
  display: grid;
  grid-template-columns: 52px minmax(72px, 0.8fr) minmax(120px, 1.2fr);
  gap: 8px;
  align-items: center;
  padding: 5px 7px;
  border: 1px solid rgba(214, 71, 61, 0.28);
  background: rgba(0, 0, 0, 0.24);
  min-width: 0;
}

.death-event-row strong,
.death-event-row em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.death-time {
  color: #ff8a80;
  font-weight: 900;
}

.death-event-row strong {
  color: #fff;
}

.death-event-row em {
  color: #b7c2ce;
  font-style: normal;
}
