/* ==========================================================
   players.css  –  Player list, seat circle, and related UI
   ========================================================== */

      .player-list {
        display: grid;
        gap: 8px;
        max-height: 480px;
        overflow: auto;
      }

      /* Scrollbar for player-list */
      .player-list::-webkit-scrollbar { width: 5px; }
      .player-list::-webkit-scrollbar-track { background: transparent; }
      .player-list::-webkit-scrollbar-thumb { background: var(--brass-dim); border-radius: 3px; }

      .player-card {
        border: 1px solid var(--line);
        border-radius: 12px;
        padding: 8px 10px;
        background: var(--bg-card);
        display: flex;
        justify-content: space-between;
        gap: 10px;
        align-items: center;
        font-size: 13px;
        transition: border-color 0.2s ease, background 0.2s ease;
      }

      .player-card:hover {
        border-color: var(--brass-dim);
      }

      .player-card.self-player {
        border-color: var(--brass);
        box-shadow: var(--glow-brass);
      }

      .player-card.speaking {
        border-color: var(--blood-bright);
        box-shadow: 0 0 12px rgba(196, 30, 58, 0.2);
        animation: pulse-glow 2s ease-in-out infinite;
      }

      .player-card.nominated {
        border-color: var(--blood-bright);
        animation: flash-border 0.8s ease-in-out infinite;
      }

      .player-card.dead {
        opacity: 0.4;
        text-decoration: line-through;
      }

      @keyframes pulse-glow {
        0%, 100% { box-shadow: 0 0 8px rgba(196, 30, 58, 0.15); }
        50% { box-shadow: 0 0 18px rgba(196, 30, 58, 0.35); }
      }

      @keyframes flash-border {
        0%, 100% { border-color: var(--blood-bright); }
        50% { border-color: transparent; }
      }

      .player-model {
        margin-top: 4px;
        font-size: 12px;
        max-width: 180px;
      }

      /* Seat Circle */
      .seat-circle-wrapper {
        position: relative;
        width: 100%;
        max-width: 440px;
        aspect-ratio: 1;
        margin: 0 auto 12px;
      }

      body.phase-day .seat-circle-wrapper {
        max-width: 360px;
      }

      body.phase-dusk .seat-circle-wrapper {
        max-width: 420px;
      }

      body.phase-night .seat-circle-wrapper {
        max-width: 480px;
      }

      @media (max-width: 1000px) {
        .seat-circle-wrapper {
          max-width: 380px;
        }
      }

      .seat-circle-wrapper::before {
        content: "";
        position: absolute;
        inset: 8%;
        border-radius: 50%;
        border: 1px solid rgba(184, 134, 11, 0.25);
        box-shadow:
          inset 0 0 30px rgba(0, 0, 0, 0.6),
          0 0 18px rgba(184, 134, 11, 0.15);
      }

      .seat-circle-center {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        text-align: center;
        z-index: 2;
        pointer-events: none;
        padding: 10px 18px;
        border-radius: 999px;
        border: 1px solid rgba(184, 134, 11, 0.2);
        background: rgba(13, 13, 15, 0.55);
        box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.4);
      }

      .seat-circle-center .phase-icon {
        font-size: 32px;
        display: block;
        margin-bottom: 4px;
      }

      .seat-circle-center .phase-text {
        font-family: "Cinzel", serif;
        font-size: 13px;
        color: var(--muted);
        letter-spacing: 1px;
      }

      .seat-node {
        position: absolute;
        width: 56px;
        height: 56px;
        border-radius: 50%;
        background: radial-gradient(circle at top, rgba(255, 255, 255, 0.08), rgba(13, 13, 15, 0.4)), var(--bg-card);
        border: 2px solid var(--line);
        display: flex;
        align-items: center;
        justify-content: center;
        flex-direction: column;
        cursor: default;
        transition: border-color 0.3s, box-shadow 0.3s, opacity 0.3s;
        transform: translate(-50%, -50%);
        z-index: 3;
      }

      .seat-node {
        cursor: pointer;
      }
      .seat-node .seat-num {
        position: absolute;
        top: 2px;
        left: 6px;
        font-family: "Cinzel", serif;
        font-size: 10px;
        font-weight: 600;
        line-height: 1;
        color: var(--muted);
        z-index: 1;
      }
      .seat-node .seat-note-role {
        font-size: 11px;
        font-weight: 600;
        line-height: 1.1;
        color: var(--ink-bright);
        text-align: center;
        max-width: 48px;
        overflow: hidden;
        text-overflow: ellipsis;
        word-break: break-all;
      }

      .seat-node .seat-label {
        position: absolute;
        bottom: -18px;
        left: 50%;
        transform: translateX(-50%);
        font-size: 11px;
        white-space: nowrap;
        color: var(--muted);
        pointer-events: none;
      }

      /* Plus button for status tags */
      .seat-plus-btn {
        position: absolute;
        width: 18px;
        height: 18px;
        border-radius: 50%;
        background: rgba(100, 60, 140, 0.75);
        border: 1px solid rgba(160, 120, 200, 0.5);
        color: #e0d0f0;
        font-size: 14px;
        line-height: 16px;
        text-align: center;
        cursor: pointer;
        z-index: 5;
        pointer-events: all;
        transition: transform 0.15s, background 0.15s;
      }
      .seat-plus-btn:hover {
        transform: scale(1.2);
        background: rgba(130, 80, 180, 0.9);
      }

      /* Status tags near seat node */
      .seat-tags {
        position: absolute;
        display: flex;
        flex-wrap: wrap;
        gap: 2px;
        z-index: 5;
        pointer-events: all;
        max-width: 80px;
      }
      .seat-tag {
        padding: 1px 4px;
        border-radius: 6px;
        font-size: 9px;
        white-space: nowrap;
        background: rgba(100, 60, 140, 0.7);
        border: 1px solid rgba(160, 120, 200, 0.4);
        color: #e0d0f0;
        cursor: pointer;
        transition: background 0.15s;
      }
      .seat-tag:hover {
        background: rgba(180, 50, 50, 0.7);
      }

      /* Note picker popup */
      .note-picker {
        display: none;
        position: fixed;
        z-index: 100;
        background: rgba(22, 22, 40, 0.97);
        border: 1px solid var(--brass-dim);
        border-radius: 10px;
        padding: 8px;
        box-shadow: 0 12px 40px rgba(0,0,0,0.6);
        backdrop-filter: blur(12px);
        max-width: 260px;
        max-height: 320px;
        overflow-y: auto;
        display: none;
        flex-wrap: wrap;
        gap: 5px;
      }
      .note-picker.open {
        display: flex;
      }
      .note-picker-item {
        padding: 4px 8px;
        border-radius: 8px;
        font-size: 12px;
        cursor: pointer;
        border: 1px solid rgba(42, 111, 143, 0.3);
        background: rgba(28, 61, 90, 0.3);
        color: var(--ink);
        transition: background 0.15s, border-color 0.15s;
        white-space: nowrap;
      }
      .note-picker-item:hover {
        background: rgba(184, 134, 11, 0.3);
        border-color: var(--brass);
        color: var(--ink-bright);
      }
      .note-picker-item.clear-item {
        border-color: rgba(139, 0, 0, 0.4);
        background: rgba(139, 0, 0, 0.15);
        color: #c08080;
      }
      .note-picker-item.clear-item:hover {
        background: rgba(180, 50, 50, 0.4);
        color: #fff;
      }

      .seat-node.alive {
        box-shadow: 0 0 8px rgba(40, 140, 80, 0.15);
      }

      .seat-node.dead {
        opacity: 0.35;
        border-color: rgba(139, 0, 0, 0.3);
      }

      .seat-node.dead .seat-num {
        text-decoration: line-through;
        color: var(--muted);
      }

      .seat-node.self {
        border-color: var(--brass);
        box-shadow: var(--glow-brass);
      }

      .seat-node:hover {
        border-color: rgba(184, 134, 11, 0.6);
        box-shadow: 0 0 16px rgba(184, 134, 11, 0.2);
      }


      .seat-node.nominated-node {
        border-color: var(--blood-bright);
        animation: flash-border 0.8s ease-in-out infinite;
      }
      .seat-node.nominator-node {
        border-color: var(--brass);
        box-shadow: 0 0 12px rgba(184, 134, 11, 0.4);
      }

      /* Nomination pointers SVG overlay */
      .nomination-pointer-svg {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        z-index: 2;
        pointer-events: none;
        overflow: visible;
      }

      .seat-node .seat-status-icon {
        position: absolute;
        top: -4px;
        right: -4px;
        font-size: 14px;
        z-index: 4;
      }

      /* Tooltip on hover */
      .seat-node:hover .seat-tooltip {
        display: block;
      }

      .seat-tooltip {
        display: none;
        position: absolute;
        bottom: calc(100% + 8px);
        left: 50%;
        transform: translateX(-50%);
        background: rgba(18, 18, 32, 0.95);
        border: 1px solid var(--brass-dim);
        border-radius: 8px;
        padding: 6px 10px;
        font-size: 12px;
        white-space: nowrap;
        z-index: 10;
        color: var(--ink);
        pointer-events: none;
      }

      /* Player model config list */
      .player-model-list {
        display: grid;
        gap: 6px;
        max-height: 260px;
        overflow: auto;
        margin-bottom: 10px;
        padding: 8px;
        border-radius: 10px;
        background: rgba(13, 13, 15, 0.4);
        border: 1px solid var(--line);
        animation: fade-in 0.2s ease;
      }

      .player-model-list::-webkit-scrollbar { width: 5px; }
      .player-model-list::-webkit-scrollbar-track { background: transparent; }
      .player-model-list::-webkit-scrollbar-thumb { background: var(--brass-dim); border-radius: 3px; }

      .player-model-row {
        display: flex;
        align-items: center;
        gap: 8px;
        font-size: 13px;
      }

      .player-model-row .pm-name {
        min-width: 60px;
        color: var(--ink);
      }

      .player-model-row .pm-name.pm-human {
        color: var(--brass);
      }

      .player-model-row select {
        flex: 1;
        font-size: 12px;
        padding: 4px 6px;
      }
