/* ── Tables Container (two-team layout) ──────────────────────────────────── */
.tables-container {
  flex: 1; display: flex; overflow: hidden; position: relative;
}

.team-area {
  flex: 1; position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  border-right: 1px solid rgba(8,17,46,0.08);
}
.team-area:last-child { border-right: none; }

.team-label {
  position: absolute; top: 10px; left: 10px; transform: none;
  font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em;
  padding: 4px 14px; border-radius: 20px; border: 1px solid; z-index: 5;
  white-space: nowrap; pointer-events: none;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.15);
}
.dev-label { color: #3448ff; border-color: rgba(52,72,255,0.25); background: rgba(255,255,255,0.55); }
.qa-label  { color: #3448ff; border-color: rgba(52,72,255,0.25); background: rgba(255,255,255,0.55); }

.poker-table { position: absolute; isolation: isolate; }

.table-surface {
  position: relative; z-index: 2;
  width: 100%; height: 100%; border-radius: 999px;
  background: radial-gradient(ellipse at 40% 35%, #2d8a54 0%, #1e6b3e 45%, #145230 100%);
  border: 14px solid #0d3d22;
  box-shadow:
    0 24px 70px rgba(0,0,0,0.7),
    inset 0 2px 10px rgba(255,255,255,0.08);
  display: flex; align-items: center; justify-content: center;
}

.table-center-content {
  text-align: center; color: white;
  font-size: 13px; padding: 10px; max-width: 200px;
  display: flex; align-items: center; justify-content: center;
}

/* Glass pill — current ticket */
.table-issue-pill {
  display: flex; flex-direction: column; gap: 5px;
  background: rgba(255,255,255,0.13);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.22), 0 4px 20px rgba(0,0,0,0.35);
  border-radius: 14px; padding: 10px 14px; text-align: center;
}
.table-issue-label {
  font-size: 9px; text-transform: uppercase; letter-spacing: .08em;
  color: rgba(255,255,255,0.5); font-weight: 700;
}
.table-issue-title {
  font-size: 11px; line-height: 1.4; color: white; font-weight: 500;
  max-width: 160px; overflow: hidden; display: -webkit-box;
  -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.table-issue-status {
  font-size: 10px; color: rgba(255,255,255,0.6); font-weight: 600;
  letter-spacing: .02em;
}

/* Waiting state pill */
.table-waiting {
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.15);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.15);
  border-radius: 999px; padding: 6px 16px;
  font-size: 12px; color: rgba(255,255,255,0.7); font-weight: 500;
}

/* Lonely prompt */
.table-lonely {
  display: flex; flex-direction: column; align-items: center; gap: 7px;
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.14);
  border-radius: 16px; padding: 14px 20px;
}
.table-lonely-icon { color: rgba(255,255,255,0.45); display: flex; }
.table-lonely-text  { font-size: 13px; color: rgba(255,255,255,0.7); font-weight: 500; }
.table-lonely-hint  { font-size: 11px; color: rgba(255,255,255,0.35); }

.players-layer {
  position: absolute; inset: 0; pointer-events: none;
}

/* ── Dealer toggle ───────────────────────────────────────────────────────── */
.dealer-toggle {
  position: absolute; bottom: 12px; right: 12px;
  display: flex; align-items: center; gap: 6px;
  cursor: pointer; user-select: none; z-index: 5;
}
.dealer-toggle input { display: none; }
.dealer-toggle-track {
  width: 34px; height: 20px; border-radius: 10px;
  background: rgba(8,17,46,0.15); border: 1px solid rgba(8,17,46,0.12);
  position: relative; transition: background 0.2s;
  flex-shrink: 0;
}
.dealer-toggle input:checked ~ .dealer-toggle-track { background: var(--primary); }
.dealer-toggle-thumb {
  position: absolute; top: 2px; left: 2px;
  width: 14px; height: 14px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,0.2);
  transition: transform 0.2s;
}
.dealer-toggle input:checked ~ .dealer-toggle-track .dealer-toggle-thumb { transform: translateX(14px); }
.dealer-toggle-label { font-size: 11px; color: var(--text-muted); font-weight: 500; }

/* ── Countdown ───────────────────────────────────────────────────────────── */
.countdown-overlay {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  z-index: 10; pointer-events: none;
}
.countdown-overlay.hidden { display: none; }
#countdown-number {
  font-size: 120px; font-weight: 900; color: white;
  text-shadow: 0 0 40px rgba(255,255,255,0.4), 0 4px 20px rgba(0,0,0,0.8);
  animation: countPulse 0.8s ease-out; display: block;
}
@keyframes countPulse {
  from { transform: scale(1.6); opacity: 0.3; }
  to   { transform: scale(1);   opacity: 1; }
}

/* ── Issues Sidebar ──────────────────────────────────────────────────────── */
.issues-sidebar {
  width: 0; overflow: hidden;
  background: var(--glass, rgba(255,255,255,0.6));
  backdrop-filter: blur(40px) saturate(180%);
  -webkit-backdrop-filter: blur(40px) saturate(180%);
  border-left: 1px solid var(--glass-border, rgba(8,17,46,0.08));
  box-shadow: inset 1px 0 0 var(--glass-hi, rgba(255,255,255,0.8)), -4px 0 32px rgba(52,72,255,0.07);
  display: flex; flex-direction: column;
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  flex-shrink: 0;
}
.issues-sidebar.open { width: 280px; }

.sidebar-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px 10px;
  border-bottom: 1px solid rgba(8,17,46,0.08);
  flex-shrink: 0;
}
.sidebar-title { font-size: 14px; font-weight: 600; color: var(--primary); }
.sidebar-jira-btn { font-size: 11px; padding: 4px 8px; }

.btn-icon {
  background: transparent; border: none; color: var(--muted);
  cursor: pointer; font-size: 16px; padding: 2px 6px;
  border-radius: 4px; transition: color 0.2s; line-height: 1;
}
.btn-icon:hover { color: var(--text); }

.issue-list {
  flex: 1; overflow-y: auto; list-style: none; padding: 8px 0;
}
.issue-list::-webkit-scrollbar { width: 4px; }
.issue-list::-webkit-scrollbar-thumb { background: rgba(8,17,46,0.18); border-radius: 2px; }

.issue-item {
  display: flex; align-items: flex-start; gap: 8px;
  padding: 8px 16px; cursor: pointer;
  transition: background 0.15s;
  border-left: 3px solid transparent;
}
.issue-item:hover { background: rgba(8,17,46,0.04); }
.issue-item.active {
  background: rgba(52,72,255,0.08);
  border-left-color: var(--primary);
}
.issue-item.estimated {
  border-left-color: var(--success);
}
.issue-item.estimated .issue-title { color: var(--muted); }
.issue-saved-badge {
  color: var(--success); flex-shrink: 0;
  display: flex; align-items: center; margin-top: 2px;
}

.issue-title {
  flex: 1; font-size: 13px; color: var(--text);
  line-height: 1.4; word-break: break-word;
}
.issue-estimate {
  font-size: 11px; font-weight: 700;
  border-radius: 4px; padding: 1px 6px;
  white-space: nowrap; flex-shrink: 0; align-self: flex-start; margin-top: 1px;
}
.issue-estimate.dev-est { background: rgba(52,72,255,0.12); color: var(--primary); }
.issue-estimate.qa-est  { background: rgba(161,137,227,0.18); color: #7b5cc9; }
.issue-estimates { display: flex; gap: 3px; flex-wrap: wrap; flex-shrink: 0; align-self: flex-start; margin-top: 1px; }
.issue-delete {
  background: transparent; border: none; color: var(--muted);
  cursor: pointer; font-size: 14px; padding: 0 2px;
  opacity: 0; transition: opacity 0.15s, color 0.15s;
  flex-shrink: 0; line-height: 1.4;
}
.issue-item:hover .issue-delete { opacity: 1; }
.issue-delete:hover { color: var(--error); }

.add-issue-row {
  display: flex; gap: 6px; padding: 10px 12px;
  border-top: 1px solid rgba(8,17,46,0.08); flex-shrink: 0;
}
.issue-input {
  flex: 1; padding: 7px 10px;
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(8,17,46,0.12);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.9);
  border-radius: 8px; color: var(--text); font-size: 13px;
  outline: none; font-family: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.issue-input:focus {
  border-color: rgba(52,72,255,0.5);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.9), 0 0 0 3px rgba(52,72,255,0.15);
}
.btn-add-issue {
  background: #3448ff;
  border: 1px solid rgba(52,72,255,0.5);
  box-shadow: 0 2px 8px rgba(52,72,255,0.25);
  color: white; border-radius: 8px;
  width: 32px; height: 32px;
  cursor: pointer; display: flex;
  align-items: center; justify-content: center;
  flex-shrink: 0; transition: background 0.2s;
}
.btn-add-issue:hover { background: rgba(255,255,255,0.25); }

/* ── Dealer ──────────────────────────────────────────────────────────────── */
.dealer {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translate(-50%, -68%);
  transform-origin: top center;
  z-index: 1;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  filter: drop-shadow(0 6px 20px rgba(0,0,0,0.7));
  height: 160px;
  overflow: visible;
}
.dealer-hands {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translate(-50%, -68%);
  transform-origin: top center;
  z-index: 3;
  pointer-events: none;
  filter: drop-shadow(0 6px 20px rgba(0,0,0,0.7));
}

.dlr-label {
  font-size: 9px;
  color: rgba(255,255,255,0.7);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
  margin-top: 4px;
  background: rgba(8,17,46,0.32);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.1);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.1);
  padding: 2px 8px;
  border-radius: 20px;
}

/* ── Player Seat ─────────────────────────────────────────────────────────── */
.player-seat {
  position: absolute;
  display: flex; flex-direction: column;
  align-items: center; gap: 5px;
  pointer-events: auto; min-width: 72px;
  transform-origin: center center;
}

.player-card-wrap { width: 50px; height: 72px; perspective: 600px; flex-shrink: 0; }
.player-card-inner {
  width: 100%; height: 100%; position: relative;
  transform-style: preserve-3d;
  -webkit-transform-style: preserve-3d;
  transition: transform 0.65s cubic-bezier(0.4, 0, 0.2, 1);
}
.player-card-inner.flipped { transform: rotateY(180deg); }

.card-face {
  position: absolute; inset: 0; border-radius: 7px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 3px 10px rgba(0,0,0,0.45);
}
.card-back {
  background: linear-gradient(145deg, rgba(64,82,255,0.75) 0%, rgba(20,38,120,0.92) 100%);
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.3),
    inset 0 -1px 0 rgba(0,0,0,0.25),
    0 4px 12px rgba(0,0,0,0.3);
}
.card-back::after {
  content: ''; width: 22px; height: 22px; border-radius: 50%;
  border: 1.5px solid rgba(255,255,255,0.3);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), 0 0 10px rgba(168,235,255,0.25);
}
.card-empty {
  background: rgba(255,255,255,0.06);
  border: 1.5px dashed rgba(255,255,255,0.18);
  color: rgba(255,255,255,0.2); font-size: 22px;
}
.card-front {
  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(255,255,255,0.95);
  box-shadow: inset 0 1px 0 rgba(255,255,255,1), 0 2px 8px rgba(8,17,46,0.12);
  transform: rotateY(180deg);
  color: #08112e;
}
.card-front .cv-center { font-size: 18px; font-weight: 800; letter-spacing: -0.03em; }

/* Spectators layer — centered between the two tables */
.spectators-layer {
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  pointer-events: none;
}

.spectator-seat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
}
.spectator-seat .player-avatar {
  width: 44px; height: 44px; font-size: 15px;
}

.player-avatar {
  width: 38px; height: 38px; border-radius: 50%;
  background: linear-gradient(145deg, rgba(72,90,255,0.95), rgba(42,60,220,0.85));
  display: flex; align-items: center;
  justify-content: center; font-size: 13px; font-weight: 700;
  color: white; letter-spacing: -0.01em;
  border: 1.5px solid rgba(255,255,255,0.28);
  flex-shrink: 0; user-select: none;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.35),
    0 4px 14px rgba(0,0,0,0.35);
}
.player-avatar.is-me {
  background: linear-gradient(145deg, #c4eeff, #8dd8f8);
  color: #08112e;
  border-color: rgba(255,255,255,0.55);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.6), 0 4px 14px rgba(168,235,255,0.35);
}
.player-avatar.is-admin {
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.35), 0 0 0 2.5px rgba(255,255,255,0.55), 0 4px 14px rgba(0,0,0,0.35);
}
.player-avatar.is-spectator {
  background: rgba(30, 40, 80, 0.75);
  border-color: rgba(255,255,255,0.3);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.15), 0 4px 14px rgba(0,0,0,0.35);
  color: rgba(255,255,255,0.9);
}
.player-avatar img {
  width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block;
}

/* ── Avatar picker (landing) ─────────────────────────────────────────────── */
.avatar-pick-group { display: flex; flex-direction: column; }
.avatar-pick-row   { display: flex; align-items: center; gap: 12px; }
.avatar-pick-info  { flex: 1; display: flex; flex-direction: column; }

.avatar-preview {
  width: 54px; height: 54px; border-radius: 50%; flex-shrink: 0;
  background: linear-gradient(145deg, rgba(72,90,255,0.9), rgba(42,60,220,0.8));
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; position: relative; overflow: hidden;
  border: 2px dashed rgba(52,72,255,0.3);
  transition: border-color 0.2s, box-shadow 0.2s;
  user-select: none;
}
.avatar-preview:hover { border-color: rgba(52,72,255,0.7); box-shadow: 0 0 0 3px rgba(52,72,255,0.12); }
.avatar-preview.has-image { border-style: solid; border-color: rgba(52,72,255,0.4); }

#avatar-preview-initials {
  font-size: 18px; font-weight: 700; color: rgba(255,255,255,0.85); letter-spacing: -0.01em;
}
#avatar-preview-img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 50%;
}
.avatar-pick-overlay {
  position: absolute; inset: 0; border-radius: 50%;
  background: rgba(8,17,46,0.52);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  color: white; opacity: 1; transition: background 0.18s;
}
.avatar-preview:hover .avatar-pick-overlay { background: rgba(8,17,46,0.68); }
.avatar-pick-label { font-size: 8px; font-weight: 600; letter-spacing: 0; white-space: nowrap; }
/* Once image is set: show dimmed overlay only on hover */
.avatar-preview.has-image .avatar-pick-overlay { opacity: 0; transition: opacity 0.18s; }
.avatar-preview.has-image:hover .avatar-pick-overlay { opacity: 1; background: rgba(8,17,46,0.55); }

.player-name {
  font-size: 12px; font-weight: 600; color: rgba(255,255,255,0.95);
  white-space: nowrap;
  text-align: center; line-height: 1.3;
  background: rgba(8,17,46,0.38);
  backdrop-filter: blur(12px) saturate(150%);
  -webkit-backdrop-filter: blur(12px) saturate(150%);
  border: 1px solid rgba(255,255,255,0.13);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.12);
  padding: 3px 9px; border-radius: 20px;
}
.player-name.is-me {
  background: rgba(52,72,255,0.4);
  color: white;
  border-color: rgba(100,130,255,0.4);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.2);
}
.player-name.is-spectator { color: rgba(255,255,255,0.55); font-style: italic; }

/* ── Reactions ───────────────────────────────────────────────────────────── */
.picker-top-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 2px; }

.react-wrap { position: relative; }

.react-trigger { display: flex; align-items: center; gap: 5px; }
.react-trigger.active { color: var(--primary); border-color: rgba(52,72,255,0.3); background: rgba(255,255,255,0.88); }

.react-popover {
  position: absolute; bottom: calc(100% + 8px); right: 0;
  display: flex; gap: 4px; padding: 8px 10px;
  background: rgba(248,250,255,0.97);
  backdrop-filter: blur(40px) saturate(200%);
  -webkit-backdrop-filter: blur(40px) saturate(200%);
  border: 1px solid rgba(52,72,255,0.15);
  border-radius: 40px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.95), 0 8px 32px rgba(52,72,255,0.14), 0 2px 8px rgba(8,17,46,0.1);
  animation: dropIn 0.2s cubic-bezier(0.34, 1.56, 0.64, 1) both;
  white-space: nowrap;
}
.react-popover.hidden { display: none !important; }

.react-emoji-btn {
  background: none; border: none; cursor: pointer;
  font-size: 22px; line-height: 1; padding: 2px 3px;
  border-radius: 8px; transition: transform 0.15s;
  user-select: none;
}
.react-emoji-btn:hover { transform: scale(1.35); }
.react-emoji-btn:active { transform: scale(1.1); }
.react-emoji-btn--img { padding: 1px 2px; }
.react-emoji-btn--img img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; display: block; }

/* Floating reaction — spawned by JS over player seat */
.floating-reaction {
  position: absolute; pointer-events: none; z-index: 100;
  font-size: 28px; line-height: 1;
  animation: floatUp 2.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
  transform-origin: center bottom;
}
@keyframes floatUp {
  0%   { opacity: 1;   transform: translateY(0)     scale(1); }
  15%  { opacity: 1;   transform: translateY(-14px) scale(1.3); }
  80%  { opacity: 1;   transform: translateY(-80px) scale(1); }
  100% { opacity: 0;   transform: translateY(-110px) scale(0.8); }
}

/* ── Card Picker ─────────────────────────────────────────────────────────── */
.picker-area {
  flex-shrink: 0; padding: 20px 20px 14px;
  background: var(--glass, rgba(255,255,255,0.65));
  backdrop-filter: blur(32px) saturate(180%);
  -webkit-backdrop-filter: blur(32px) saturate(180%);
  border-top: 1px solid var(--glass-border, rgba(8,17,46,0.08));
  box-shadow: 0 -1px 0 var(--glass-hi, rgba(255,255,255,0.8)), 0 -8px 32px rgba(52,72,255,0.07);
}
#picker-panel { display: flex; flex-direction: column; gap: 8px; }
.picker-label {
  font-size: 11px; color: var(--muted); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
}
.cards-row {
  display: flex; gap: 10px; overflow-x: auto;
  padding-bottom: 6px; padding-top: 20px;
  scrollbar-width: none;
}
.cards-row::-webkit-scrollbar { display: none; }

.pick-card {
  flex-shrink: 0; width: 54px; height: 76px;
  position: relative;
  border-radius: 12px;
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.88);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.95),
    inset 0 -1px 0 rgba(8,17,46,0.04),
    0 2px 8px rgba(8,17,46,0.1),
    0 1px 2px rgba(8,17,46,0.06);
  font-size: 16px; font-weight: 700; letter-spacing: -0.02em;
  cursor: pointer;
  transition:
    transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1),
    box-shadow 0.2s ease,
    background 0.15s ease,
    border-color 0.15s ease;
  display: flex; align-items: center; justify-content: center;
  user-select: none;
}
.pick-card:hover:not(:disabled) {
  transform: translateY(-14px);
  background: rgba(255,255,255,0.92);
  border-color: rgba(52,72,255,0.35);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.95),
    0 16px 32px rgba(52,72,255,0.18),
    0 4px 10px rgba(8,17,46,0.1);
}
.pick-card.selected {
  transform: translateY(-18px);
  background: var(--primary);
  color: white;
  border-color: rgba(52,72,255,0.5);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.28),
    0 20px 36px rgba(52,72,255,0.32),
    0 6px 12px rgba(52,72,255,0.2);
}
.pick-card:disabled { opacity: 0.3; cursor: not-allowed; transform: none !important; box-shadow: none !important; }

/* ── Results panel ───────────────────────────────────────────────────────── */
#results-panel { padding: 2px 0 4px; }
#results-content { display: flex; flex-direction: column; gap: 8px; }

.results-teams { display: flex; gap: 16px; align-items: flex-start; }
.results-team  { flex: 1; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.results-team-header {
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--muted); padding-bottom: 4px; border-bottom: 1px solid rgba(8,17,46,0.1);
}
.results-no-votes { font-size: 12px; color: var(--muted); }

.results-stats {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
}
.results-consensus { font-size: 15px; font-weight: 700; color: var(--success); }
.results-avg       { font-size: 15px; font-weight: 700; color: var(--text); }
.results-range     { font-size: 13px; color: var(--muted); }

.results-votes {
  display: flex; flex-wrap: wrap; gap: 6px; align-items: flex-end;
}
.vote-group {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
}

.vote-bar-wrap {
  width: 40px; height: 52px;
  display: flex; align-items: flex-end; justify-content: center;
}
.vote-bar-bg {
  width: 12px; height: 100%;
  background: rgba(8,17,46,0.07);
  border-radius: 6px; overflow: hidden;
  display: flex; align-items: flex-end;
}
.vote-bar-fill {
  width: 100%; border-radius: 6px;
  background: rgba(8,17,46,0.15);
  transition: height 0.5s cubic-bezier(0.4,0,0.2,1);
}
.vote-bar-fill.winner { background: #3448ff; }

.vote-card-mini {
  width: 40px; height: 56px; border-radius: 10px;
  background: rgba(255,255,255,0.82);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.9);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 800; letter-spacing: -0.02em;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.95),
    0 3px 10px rgba(8,17,46,0.1);
  animation: cardRevealMini 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}
@keyframes cardRevealMini {
  0%   { transform: perspective(400px) rotateY(-90deg) scale(0.88); opacity: 0; }
  65%  { transform: perspective(400px) rotateY(6deg)   scale(1.04); opacity: 1; }
  100% { transform: perspective(400px) rotateY(0deg)   scale(1);    opacity: 1; }
}
.vote-card-mini.highlight {
  background: var(--primary);
  color: white;
  border-color: rgba(52,72,255,0.5);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.25), 0 3px 12px rgba(52,72,255,0.28);
}

.vote-names {
  font-size: 10px; color: var(--muted); text-align: center;
  max-width: 60px; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap;
}

.results-save-row {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.btn-save-estimate {
  padding: 6px 14px;
  background: rgba(52,72,255,0.08);
  color: var(--primary);
  border: 1px solid rgba(52,72,255,0.2);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
  border-radius: 8px; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: background 0.2s;
  font-family: inherit;
}
.btn-save-estimate:hover { background: rgba(52,72,255,0.14); }
.save-confirm { font-size: 12px; color: var(--success); }

/* ── Table center stats ──────────────────────────────────────────────────── */
.stats-wrap {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  background: rgba(255,255,255,0.13);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.22), 0 4px 20px rgba(0,0,0,0.35);
  border-radius: 16px; padding: 12px 18px;
}
.stat-consensus  { font-size: 15px; font-weight: 700; color: #cbf69f; display: flex; align-items: center; gap: 5px; }
.stat-avg        { font-size: 28px; font-weight: 800; color: white; letter-spacing: -0.03em; }
.stat-label      { font-size: 9px; color: rgba(255,255,255,0.45); text-transform: uppercase; letter-spacing: 0.08em; font-weight: 600; }
.stat-range      { font-size: 11px; color: rgba(255,255,255,0.55); font-weight: 500; }

/* ── Transfer Host Modal ─────────────────────────────────────────────────── */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(8,17,46,0.2);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
}
.modal-backdrop.hidden { display: none; }
@keyframes modalIn {
  from { opacity: 0; transform: scale(0.94) translateY(8px); }
  to   { opacity: 1; transform: scale(1)    translateY(0); }
}
@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.modal-box {
  animation: modalIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) both;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(48px) saturate(180%);
  -webkit-backdrop-filter: blur(48px) saturate(180%);
  border: 1px solid rgba(255,255,255,0.95);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,1),
    0 24px 64px rgba(8,17,46,0.18),
    0 0 0 0.5px rgba(8,17,46,0.06);
  border-radius: 20px; padding: 24px; min-width: 280px; max-width: 360px;
  display: flex; flex-direction: column; gap: 14px;
}
.modal-header { display: flex; align-items: center; justify-content: space-between; }
.modal-title  { font-size: 16px; font-weight: 700; letter-spacing: -0.02em; }
.modal-hint   { font-size: 13px; color: var(--muted); margin: 0; }
.transfer-list { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.transfer-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: 12px;
  background: rgba(255,255,255,0.5); border: 1px solid rgba(8,17,46,0.1);
  cursor: pointer; transition: border-color 0.15s, background 0.15s;
  font-size: 14px;
}
.transfer-item:hover { border-color: var(--primary); background: rgba(52,72,255,0.06); }
.transfer-item-avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--primary); color: white;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; flex-shrink: 0;
}

/* ── Toasts ──────────────────────────────────────────────────────────────── */
.toasts {
  position: fixed; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  display: flex; flex-direction: column; gap: 8px;
  z-index: 999; pointer-events: none;
  align-items: center;
}
.toast {
  color: var(--text);
  padding: 10px 20px;
  border-radius: 999px;
  font-size: 13px; font-weight: 600; letter-spacing: -0.01em;
  background: rgba(255,255,255,0.82);
  backdrop-filter: blur(40px) saturate(180%);
  -webkit-backdrop-filter: blur(40px) saturate(180%);
  border: 1px solid rgba(8,17,46,0.1);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.95), 0 8px 32px rgba(8,17,46,0.12);
  opacity: 0; transform: scale(0.85);
  transition: opacity 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
              transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateY(0) scale(1); }
.toast.join  { border-color: rgba(66,148,99,0.35);  box-shadow: inset 0 1px 0 rgba(255,255,255,0.95), 0 8px 32px rgba(66,148,99,0.15), 0 0 0 1px rgba(66,148,99,0.2); color: #2d7a47; }
.toast.leave { border-color: rgba(220,38,38,0.3);   box-shadow: inset 0 1px 0 rgba(255,255,255,0.95), 0 8px 32px rgba(220,38,38,0.12), 0 0 0 1px rgba(220,38,38,0.15); color: #c02020; }
.toast.host  { border-color: rgba(52,72,255,0.25);  box-shadow: inset 0 1px 0 rgba(255,255,255,0.95), 0 8px 32px rgba(52,72,255,0.12), 0 0 0 1px rgba(52,72,255,0.15); color: var(--primary); }
.toast.info  { border-color: rgba(8,17,46,0.1); }

/* ── Jira Import ─────────────────────────────────────────────────────────── */
.jira-modal-box {
  max-width: 640px; width: 100%;
  display: flex; flex-direction: column; gap: 14px;
}
.jira-step { display: flex; flex-direction: column; gap: 8px; width: 100%; }
.jira-step.hidden { display: none; }
.jira-label { font-size: 12px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; }
.jira-select { font-size: 13px; }

/* Scope tab buttons */
.jira-scope-tabs { display: flex; gap: 6px; width: 100%; }
.jira-scope-btn {
  flex: 1; padding: 7px 10px;
  font-size: 12px; font-weight: 600; font-family: inherit;
  border-radius: 8px; cursor: pointer;
  border: 1px solid rgba(8,17,46,0.12);
  background: rgba(255,255,255,0.6);
  color: var(--muted);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.jira-scope-btn.active {
  background: var(--primary); color: white;
  border-color: var(--primary);
}
.jira-scope-btn:not(.active):hover { background: rgba(52,72,255,0.08); color: var(--primary); }

/* Searchable project dropdown */
.search-select-wrap { position: relative; }
.search-select-dropdown {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 200;
  background: white; border: 1px solid rgba(8,17,46,0.12); border-radius: 8px;
  margin-top: 4px; max-height: 200px; overflow-y: auto;
  box-shadow: 0 8px 24px rgba(8,17,46,0.12);
  list-style: none; padding: 4px; margin: 4px 0 0;
}
.search-select-dropdown.hidden { display: none; }
.proj-dd-item {
  padding: 8px 10px; border-radius: 6px; cursor: pointer;
  font-size: 13px; color: var(--text);
}
.proj-dd-item:hover { background: var(--primary); color: white; }
.proj-dd-empty { padding: 8px 10px; font-size: 13px; color: var(--muted); }

/* Filter bar (type, version, label, priority dropdowns) */
.jira-filter-bar {
  display: flex; flex-wrap: wrap; gap: 6px;
}
.jira-filter-csel { min-width: 0; flex: 1; }
.csel-trigger-sm {
  width: 100%; padding: 6px 10px;
  font-size: 12px; border-radius: 8px;
}

/* Issue search inside results */
.jira-issue-search {
  width: 100%; box-sizing: border-box;
  padding: 7px 10px; border-radius: 8px;
  border: 1px solid rgba(8,17,46,0.12);
  background: rgba(255,255,255,0.65);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.9);
  color: var(--text); font-size: 13px; outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.jira-issue-search:focus {
  border-color: rgba(52,72,255,0.5);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.9), 0 0 0 3px rgba(52,72,255,0.15);
}

/* Type badge on issue rows */
.jira-type-badge {
  font-size: 10px; color: var(--muted);
  background: rgba(8,17,46,0.06); border-radius: 4px;
  padding: 1px 5px; flex-shrink: 0; white-space: nowrap;
}

/* Fetching state */
.jira-fetching { font-size: 13px; color: var(--muted); margin: 0; }

/* ── Jira Estimate Panel ─────────────────────────────────────────────────── */
.jira-estimate-panel {
  margin: 0 12px 4px;
  padding: 12px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(8,17,46,0.1);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.8);
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex-shrink: 0;
}
.jira-estimate-panel.hidden { display: none; }

.jira-est-header {
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid rgba(8,17,46,0.08);
  padding-bottom: 8px;
}
.jira-est-key {
  font-size: 11px; font-weight: 700; color: var(--primary);
  background: rgba(52,72,255,0.1); padding: 2px 7px;
  border-radius: 4px; flex-shrink: 0;
}
.jira-est-title {
  font-size: 12px; font-weight: 600; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.05em;
}

.jira-est-fields { display: flex; flex-direction: column; gap: 7px; }
.jira-est-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.jira-est-label { font-size: 12px; color: var(--muted); flex: 1; }
.jira-est-input {
  width: 72px; padding: 5px 8px;
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(8,17,46,0.12);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.9);
  border-radius: 8px; color: var(--text); font-size: 13px;
  font-weight: 600; text-align: right; outline: none;
  font-family: inherit; transition: border-color 0.2s, box-shadow 0.2s;
}
.jira-est-input:focus {
  border-color: rgba(52,72,255,0.5);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.9), 0 0 0 3px rgba(52,72,255,0.15);
}
.jira-est-input:disabled { opacity: 0.45; cursor: not-allowed; }

.btn-save-jira {
  width: 100%; padding: 8px;
  background: #3448ff;
  color: white;
  border: 1px solid rgba(52,72,255,0.5);
  box-shadow: 0 4px 12px rgba(52,72,255,0.25);
  border-radius: 10px;
  font-size: 13px; font-weight: 600; font-family: inherit;
  cursor: pointer; transition: opacity 0.2s;
}
.btn-save-jira:hover:not(:disabled) { opacity: 0.88; }
.btn-save-jira:disabled { opacity: 0.4; cursor: not-allowed; }

.btn-jira-import {
  margin: 0 12px 12px;
  padding: 8px 12px;
  background: rgba(52,72,255,0.08);
  color: var(--primary);
  border: 1px solid rgba(52,72,255,0.2);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
  justify-content: center;
  flex-shrink: 0;
}
.btn-jira-import::before { display: none; }
.btn-jira-import:hover { background: rgba(52,72,255,0.14); }

.jira-results {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}
.jira-results.hidden { display: none; }
.jira-list-wrap {
  display: flex; flex-direction: column; gap: 8px;
  max-height: 340px; overflow-y: auto;
}
.jira-list-wrap::-webkit-scrollbar { width: 4px; }
.jira-list-wrap::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.jira-hint {
  font-size: 12px;
  color: var(--muted);
  margin: 0;
}
.jira-error  { font-size: 13px; color: var(--error); margin: 0; }
.jira-empty  { font-size: 13px; color: var(--muted); margin: 0; }

.jira-issue-list { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.jira-issue-item {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(8,17,46,0.09);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.8);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.jira-issue-item:hover { border-color: rgba(52,72,255,0.4); background: rgba(52,72,255,0.06); }
.jira-key     { font-size: 11px; font-weight: 700; color: var(--primary); flex-shrink: 0; }
.jira-summary { font-size: 13px; color: var(--text); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.jira-status  { font-size: 10px; color: var(--muted); flex-shrink: 0; white-space: nowrap; }
