/* ═══════════════════════════════════════════════════════════
   pool.css — Pool tab styles (extracted from pool.js)
   ══════════════════════════════════��════════════════════════ */

/* ── Pool players content — flex column to fill tab height ── */
#pool-players-content {
  display: flex;
  flex-direction: column;
  flex: 1 1 0;
  min-height: 0;
}

/* ── Pool toolbar redesign ── */
#pool-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  background: linear-gradient(180deg, rgba(10,15,26,0.95) 0%, rgba(6,9,15,0.98) 100%);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(56,130,246,0.08);
  flex-wrap: wrap;
  position: relative;
}
#pool-toolbar::after {
  content: '';
  position: absolute;
  bottom: 0; left: 20px; right: 20px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(56,130,246,0.15), transparent);
}

#pool-search {
  height: 32px;
  padding: 0 12px 0 34px;
  width: 220px;
  background: rgba(15,23,42,0.6);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 12px;
  font-family: var(--font);
  transition: all var(--transition-normal);
  position: relative;
}
#pool-search:focus {
  outline: none;
  border-color: rgba(56,130,246,0.35);
  background: rgba(15,23,42,0.8);
  box-shadow: 0 0 0 3px rgba(56,130,246,0.08);
}
#pool-search::placeholder { color: var(--text-placeholder); }

#pool-arch-filter {
  height: 32px;
  padding: 0 10px;
  background: rgba(15,23,42,0.6);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 6px;
  color: var(--text-muted);
  font-size: 11px;
  font-family: var(--font);
  cursor: pointer;
  transition: all var(--transition-normal);
}
#pool-arch-filter:hover { border-color: rgba(255,255,255,0.1); }
#pool-arch-filter:focus { outline: none; border-color: rgba(56,130,246,0.35); }

.slider-group {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 10px;
  color: var(--text-dim);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 600;
}

#pool-min-hands {
  -webkit-appearance: none;
  width: 110px;
  height: 4px;
  border-radius: 2px;
  background: rgba(30,41,59,0.6);
  outline: none;
}
#pool-min-hands::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--accent-blue);
  cursor: pointer;
  box-shadow: 0 0 8px rgba(59,130,246,0.3);
  transition: transform var(--transition-fast);
}
#pool-min-hands::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

#pool-min-hands-label {
  min-width: 30px;
  text-align: right;
  color: var(--text-dim);
  font-weight: 600;
  font-size: 11px;
}

#pool-count {
  margin-left: auto;
  font-size: 10px;
  color: var(--text-dim);
  letter-spacing: 0.06em;
  font-weight: 600;
}

/* ── Virtual table container ── */
#vtable-container {
  overflow-y: scroll;
  position: relative;
  background: var(--bg-deep);
}

/* ── Header styling ── */
.vtable-header-v3 {
  display: grid;
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--bg-gradient);
  border-bottom: 1px solid rgba(56,130,246,0.1);
  user-select: none;
}
.vtable-header-v3::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 5%, rgba(56,130,246,0.12) 50%, transparent 95%);
}

.vtable-hcell {
  padding: 0 10px;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-placeholder);
  transition: color var(--transition-normal);
  display: flex;
  align-items: center;
  gap: 4px;
}
.vtable-hcell:hover { color: var(--text-dim); }
.vtable-hcell.sorted { color: var(--accent-blue); }
.vtable-hcell .sort-arrow {
  font-size: 8px;
  opacity: 0;
  transition: opacity var(--transition-fast);
}
.vtable-hcell.sorted .sort-arrow { opacity: 1; }

/* ── Row styling ���─ */
.pool-row-v3 {
  display: grid;
  position: absolute;
  left: 0; right: 0;
  cursor: pointer;
  transition: all var(--transition-fast);
  border-bottom: 1px solid rgba(255,255,255,0.02);
}
.pool-row-v3:hover {
  background: rgba(56,130,246,0.04) !important;
  border-bottom-color: rgba(56,130,246,0.06);
}
.pool-row-v3:hover .pool-name { color: var(--text-bright); }
.pool-row-v3:active { transform: scale(0.998); }

.pool-cell {
  padding: 0 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: flex;
  align-items: center;
  font-size: 12px;
}

.pool-name {
  font-weight: 600;
  color: var(--text-body);
  letter-spacing: 0.01em;
  transition: color var(--transition-fast);
}

.pool-hands {
  color: var(--text-dim);
  font-variant-numeric: tabular-nums;
  font-size: 11px;
}

.pool-stat {
  color: var(--text-dim);
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  font-weight: 500;
}

/* ��─ Archetype badge (pill style) ── */
.arch-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
  line-height: 1;
  white-space: nowrap;
}
.arch-pill .arch-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* ── Sub-archetype tag ── */
.subarch-tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 3px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.03em;
}

/* ── Confidence bar ── */
.conf-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}
.conf-track {
  flex: 1;
  height: 5px;
  border-radius: 999px;
  background: rgba(30,41,59,0.5);
  overflow: hidden;
  position: relative;
}
.conf-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.3s ease;
  position: relative;
}
.conf-fill::after {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 12px; height: 100%;
  background: inherit;
  filter: blur(4px);
  opacity: 0.6;
}
.conf-text {
  font-size: 10px;
  font-weight: 600;
  min-width: 38px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ── bb/100 styling ─��� */
.bb100-pos { color: #22c55e; font-weight: 700; }
.bb100-neg { color: #ef4444; font-weight: 700; }
.bb100-zero { color: #475569; }

/* ── Stat value coloring by intensity ── */
.stat-high { color: #94a3b8; }
.stat-mid  { color: #64748b; }
.stat-low  { color: #475569; }

/* ── Explanation card (floating panel) ── */
.explain-backdrop {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  z-index: 900;
}
.explain-card {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  z-index: 901;
  width: min(580px, 90vw);
  max-height: 80vh;
  overflow-y: auto;
  background: linear-gradient(180deg, #0d1424 0%, #080d18 100%);
  border: 1px solid rgba(56,130,246,0.15);
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.6), 0 0 40px rgba(56,130,246,0.05);
  color: #cbd5e1;
  font-family: 'JetBrains Mono', monospace;
}
.explain-card::-webkit-scrollbar { width: 6px; }
.explain-card::-webkit-scrollbar-track { background: transparent; }
.explain-card::-webkit-scrollbar-thumb { background: rgba(56,130,246,0.15); border-radius: 3px; }
.explain-close {
  position: absolute; top: 12px; right: 16px;
  background: none; border: none; color: #475569;
  font-size: 18px; cursor: pointer; line-height: 1;
  transition: color 0.15s;
}
.explain-close:hover { color: #94a3b8; }
.explain-header {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 16px; padding-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.explain-name {
  font-size: 16px; font-weight: 700; color: #f1f5f9;
}
.explain-section {
  margin-bottom: 14px;
}
.explain-section-title {
  font-size: 9px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.12em; color: #3b82f6; margin-bottom: 6px;
}
.explain-summary {
  font-size: 12px; line-height: 1.6; color: #94a3b8;
}
.explain-tendency {
  font-size: 11px; line-height: 1.5; color: #8899ab;
  padding: 4px 0 4px 12px;
  border-left: 2px solid rgba(56,130,246,0.15);
  margin-bottom: 4px;
}
.explain-stat-row {
  display: grid;
  grid-template-columns: 90px 60px 1fr 50px;
  gap: 8px;
  align-items: center;
  font-size: 11px;
  padding: 3px 0;
  border-bottom: 1px solid rgba(255,255,255,0.02);
}
.explain-stat-label { color: #475569; font-weight: 600; text-transform: uppercase; font-size: 9px; }
.explain-stat-value { color: #cbd5e1; font-weight: 600; text-align: right; }
.explain-stat-bar-wrap {
  height: 4px; border-radius: 2px; background: rgba(30,41,59,0.5); overflow: hidden;
}
.explain-stat-bar {
  height: 100%; border-radius: 2px;
  transition: width 0.3s ease;
}
.explain-stat-pct { color: #475569; font-size: 10px; text-align: right; }
.explain-info-btn {
  background: none; border: none; color: #334155;
  font-size: 14px; cursor: pointer; padding: 0 4px;
  transition: color 0.15s; line-height: 1;
}
.explain-info-btn:hover { color: #3b82f6; }

/* ── Leak indicator button ── */
.leak-info-btn {
  background: none; border: none; cursor: pointer;
  padding: 0 4px; font-size: 11px; font-weight: 700;
  line-height: 1; transition: opacity 0.15s; letter-spacing: 0.03em;
  font-family: 'JetBrains Mono', monospace;
}
.leak-info-btn:hover { opacity: 1; }

/* ���─ Leak card (shares explain-card base) ── */
.leak-item {
  padding: 10px 12px;
  margin-bottom: 6px;
  border-radius: 6px;
  background: rgba(15,23,42,0.5);
  border-left: 3px solid;
}
.leak-item-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 4px;
}
.leak-item-name {
  font-size: 12px; font-weight: 700; color: #e2e8f0;
}
.leak-item-sev {
  font-size: 9px; font-weight: 700; padding: 2px 6px;
  border-radius: 3px; text-transform: uppercase; letter-spacing: 0.08em;
}
.leak-item-text {
  font-size: 11px; line-height: 1.5; color: #8899ab;
}
.leak-item-meta {
  display: flex; gap: 12px; margin-top: 6px;
  font-size: 10px; color: #475569;
}
.leak-health-bar {
  width: 100%; height: 8px; border-radius: 4px;
  background: rgba(30,41,59,0.5); overflow: hidden;
  margin-top: 4px;
}
.leak-health-fill {
  height: 100%; border-radius: 4px; transition: width 0.4s ease;
}
