/* =====================================================================
   BLACK BOOK – REFRESH 2026
   "Svart läderbok med guldpressning"
   Läggs ovanpå style.css. Allt visuellt – ingen logik ändras här.
   ===================================================================== */

:root {
  /* Läder */
  --bg: #110e0b;
  --bg-2: #1c1813;
  --bg-3: #27211a;
  --leather-hi: #241e17;
  --leather-lo: #17130f;

  /* Guldfolie */
  --gold: #d4af37;
  --gold-light: #f0d57a;
  --gold-pale: #fff1c2;
  --gold-deep: #8a6d1f;
  --gold-dim: rgba(212, 175, 55, 0.14);
  --gold-line: rgba(212, 175, 55, 0.16);
  --stitch: rgba(212, 175, 55, 0.28);

  /* Text & bläck */
  --text: #f3ece0;
  --text-muted: #8f8676;
  --text-dim: #6b6356;
  --text-primary: #f3ece0;

  /* Plus / minus – mjukare toner */
  --success: #86d1a3;
  --positive: #86d1a3;
  --danger: #ef8a7e;

  --radius: 18px;
  --radius-sm: 14px;
  --nav-height: 84px;

  --font-body: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --foil: linear-gradient(110deg, #a8841f 0%, #d4af37 22%, #f6e39a 38%, #fff6d6 44%, #e7c65a 52%, #c9a227 72%, #9c7a1c 100%);
  --panel: linear-gradient(170deg, var(--leather-hi) 0%, var(--leather-lo) 100%);
  --panel-shadow: 0 1px 0 rgba(255, 236, 190, 0.04) inset, 0 10px 28px -16px rgba(0, 0, 0, 0.9);
}

/* ===== Bas: läderyta med mjuk vinjett ===== */
html, body {
  font-family: var(--font-body);
  font-feature-settings: 'tnum' 1, 'lnum' 1;
  background: var(--bg);
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(120% 60% at 50% -10%, rgba(212, 175, 55, 0.09) 0%, transparent 60%),
    radial-gradient(90% 70% at 50% 120%, rgba(90, 50, 20, 0.22) 0%, transparent 65%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.85 0 0 0 0 0.72 0 0 0 0 0.45 0 0 0 0.06 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

#app { z-index: 1; }

input, select, textarea, button { font-family: inherit; }

::selection { background: rgba(212, 175, 55, 0.35); color: #fff; }

:focus-visible {
  outline: 2px solid var(--gold-light);
  outline-offset: 2px;
  border-radius: 8px;
}

/* ===== Header: läderremsa med guldsöm ===== */
.app-header {
  position: relative;
  background: linear-gradient(180deg, rgba(30, 25, 19, 0.94) 0%, rgba(20, 16, 12, 0.9) 100%);
  border-bottom: 1px solid rgba(0, 0, 0, 0.6);
  box-shadow: 0 12px 24px -18px rgba(0, 0, 0, 0.9);
}

.app-header::after {
  content: '';
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 5px;
  border-bottom: 1px dashed var(--stitch);
  pointer-events: none;
}

.header-title,
.header-title.header-title-group {
  background: var(--foil) !important;
  background-size: 250% auto !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  font-style: italic;
  letter-spacing: 1.5px;
  filter: drop-shadow(0 1px 0 rgba(0, 0, 0, 0.6)) drop-shadow(0 0 14px rgba(212, 175, 55, 0.18));
  animation: foilSweep 6s ease-in-out infinite !important;
}

.btn-icon {
  color: var(--text-muted);
  border-radius: 14px;
}
.btn-icon svg,
.btn-tx-history svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.btn-icon:hover,
.btn-icon:focus-visible {
  color: var(--gold-light);
  background: rgba(212, 175, 55, 0.06);
}

@keyframes foilSweep {
  0%, 100% { background-position: 0% center; }
  50%      { background-position: 100% center; }
}

/* ===== Sektionsrubriker: liggarens avdelare ===== */
.section-title,
.stats-section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-weight: 400;
  font-size: 15px;
  text-transform: none;
  letter-spacing: 0.4px;
  color: #cdb77a;
}
.section-title::before,
.stats-section-title::before {
  content: '';
  width: 5px;
  height: 5px;
  flex-shrink: 0;
  transform: rotate(45deg);
  background: var(--gold);
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.6);
}
.section-title::after,
.stats-section-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--gold-line), transparent);
}
.section-title-row .section-title { flex: 1; }
.section-title-row { gap: 12px; }
.stats-section-header .stats-section-title { flex: 1; }
.stats-section-header { gap: 12px; }

.section { margin-bottom: 28px; }

/* ===== Läderpaneler ===== */
.card,
.balance-item,
.closed-session-item,
.history-item,
.stat-card,
.stats-player-card,
.settlement-toggle,
.active-session-preview,
.saved-group-btn,
.group-player-item,
.group-code-display {
  background: var(--panel);
  border: 1px solid var(--gold-line);
  box-shadow: var(--panel-shadow);
}

.card {
  position: relative;
  border-radius: 22px;
  padding: 22px;
}
/* Sydd söm runt lobbykortet */
.card::before {
  content: '';
  position: absolute;
  inset: 6px;
  border: 1px dashed rgba(212, 175, 55, 0.18);
  border-radius: 17px;
  pointer-events: none;
}
.card h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 0.3px;
  color: var(--gold-light);
}

/* ===== Formulär ===== */
.form-group label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  color: var(--text-muted);
}

input[type="text"],
input[type="number"],
.input-select,
.amount-input,
.delete-confirm-input {
  background: rgba(8, 6, 4, 0.55);
  border: 1px solid rgba(212, 175, 55, 0.14);
  border-radius: 12px;
  color: var(--text);
  box-shadow: 0 1px 0 rgba(255, 236, 190, 0.03), inset 0 2px 6px rgba(0, 0, 0, 0.5);
}
input[type="text"]:focus,
input[type="number"]:focus,
.input-select:focus,
.amount-input:focus {
  border-color: rgba(240, 213, 122, 0.7);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.5), 0 0 0 4px rgba(212, 175, 55, 0.12), 0 0 22px -6px rgba(212, 175, 55, 0.5);
}
input::placeholder { color: #5e5648; }

/* ===== Knappar ===== */
.btn {
  border-radius: 14px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.btn-primary {
  background: var(--foil);
  background-size: 250% 100%;
  color: #221906;
  text-shadow: 0 1px 0 rgba(255, 246, 214, 0.45);
  box-shadow:
    0 1px 0 rgba(255, 250, 225, 0.7) inset,
    0 -2px 0 rgba(120, 90, 20, 0.35) inset,
    0 10px 26px -10px rgba(212, 175, 55, 0.65);
  animation: foilSweep 5s ease-in-out infinite;
}
.btn-primary:hover {
  background: var(--foil);
  background-size: 250% 100%;
  box-shadow:
    0 1px 0 rgba(255, 250, 225, 0.7) inset,
    0 -2px 0 rgba(120, 90, 20, 0.35) inset,
    0 14px 32px -10px rgba(212, 175, 55, 0.8);
}
.btn-primary:disabled { filter: grayscale(0.6) brightness(0.7); animation: none; }

.btn-secondary {
  background: linear-gradient(180deg, #2a231b 0%, #1d1812 100%);
  color: var(--text);
  border: 1px solid rgba(212, 175, 55, 0.22);
  box-shadow: 0 1px 0 rgba(255, 236, 190, 0.05) inset;
}
.btn-secondary:hover { border-color: rgba(212, 175, 55, 0.45); }

.btn-danger {
  color: var(--danger);
  border-color: rgba(239, 138, 126, 0.55);
  background: rgba(239, 138, 126, 0.04);
}

.btn-ghost { border-radius: 14px; }

.btn-text { color: var(--gold-light); font-weight: 600; }

.divider { color: var(--text-dim); font-family: 'Playfair Display', serif; font-style: italic; }
.divider::before,
.divider::after { background: linear-gradient(90deg, transparent, var(--gold-line)); }
.divider::after { background: linear-gradient(90deg, var(--gold-line), transparent); }

/* ===== Lobby ===== */
#screen-lobby {
  overflow-x: hidden;
  background:
    radial-gradient(70% 40% at 50% 12%, rgba(212, 175, 55, 0.16) 0%, transparent 70%),
    transparent;
}

.lobby-book-wrap::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 320px;
  height: 320px;
  transform: translate(-50%, -50%);
  background: conic-gradient(from 0deg, transparent 0 20%, rgba(240, 213, 122, 0.12) 25%, transparent 32% 58%, rgba(240, 213, 122, 0.09) 64%, transparent 72%);
  border-radius: 50%;
  filter: blur(18px);
  animation: raysSpin 26s linear infinite;
  pointer-events: none;
}
@keyframes raysSpin { to { transform: translate(-50%, -50%) rotate(360deg); } }

.lobby-book-img {
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.75)) drop-shadow(0 0 30px rgba(212, 175, 55, 0.22));
  animation: lobbyBookEnter 0.8s var(--spring) 0.05s forwards, bookFloat 6s ease-in-out 1s infinite;
}
@keyframes bookFloat {
  0%, 100% { translate: 0 0; }
  50%      { translate: 0 -6px; }
}

.logo-sub {
  font-size: 14px;
  letter-spacing: 7px;
  background: var(--foil);
  background-size: 250% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: fade-in 0.8s ease 0.6s forwards, foilSweep 7s ease-in-out 1.4s infinite;
}

/* Guldstoft */
.gold-dust {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}
.gold-dust span {
  position: absolute;
  bottom: -10px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--gold-pale);
  box-shadow: 0 0 6px 1px rgba(240, 213, 122, 0.8);
  opacity: 0;
  animation: dustRise var(--d, 14s) linear var(--delay, 0s) infinite;
}
.gold-dust span:nth-child(1)  { left: 8%;  --d: 16s; --delay: 0s;   }
.gold-dust span:nth-child(2)  { left: 18%; --d: 12s; --delay: 3s;   width: 2px; height: 2px; }
.gold-dust span:nth-child(3)  { left: 29%; --d: 18s; --delay: 6s;   }
.gold-dust span:nth-child(4)  { left: 41%; --d: 14s; --delay: 1.5s; width: 2px; height: 2px; }
.gold-dust span:nth-child(5)  { left: 52%; --d: 20s; --delay: 8s;   }
.gold-dust span:nth-child(6)  { left: 63%; --d: 13s; --delay: 4.5s; width: 4px; height: 4px; }
.gold-dust span:nth-child(7)  { left: 72%; --d: 17s; --delay: 2s;   width: 2px; height: 2px; }
.gold-dust span:nth-child(8)  { left: 81%; --d: 15s; --delay: 7s;   }
.gold-dust span:nth-child(9)  { left: 90%; --d: 19s; --delay: 5s;   width: 2px; height: 2px; }
.gold-dust span:nth-child(10) { left: 35%; --d: 22s; --delay: 10s;  width: 2px; height: 2px; }
.gold-dust span:nth-child(11) { left: 58%; --d: 16s; --delay: 12s;  }
.gold-dust span:nth-child(12) { left: 12%; --d: 21s; --delay: 9s;   width: 4px; height: 4px; }

@keyframes dustRise {
  0%   { transform: translate(0, 0) scale(0.6); opacity: 0; }
  10%  { opacity: 0.9; }
  50%  { transform: translate(14px, -45vh) scale(1); opacity: 0.55; }
  80%  { opacity: 0.8; }
  100% { transform: translate(-10px, -95vh) scale(0.5); opacity: 0; }
}

#screen-lobby .lobby-container,
#screen-lobby .app-signature { position: relative; z-index: 1; }

.saved-groups-label {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  text-transform: none;
  letter-spacing: 0.3px;
  font-size: 14px;
  color: #cdb77a;
}
.saved-group-btn { border-radius: 16px; padding: 14px 16px; }
.saved-group-btn:hover { border-color: rgba(212, 175, 55, 0.45); }
.saved-group-code {
  font-family: 'Manrope', monospace;
  font-weight: 800;
  letter-spacing: 2px;
  color: var(--gold-light);
}
.saved-group-label {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 16px;
  color: var(--text);
}
.saved-group-arrow { color: var(--gold); }

.app-signature {
  color: #4d463c;
  font-size: 11px;
  letter-spacing: 1px;
}

/* ===== Saldo ===== */
.balances-list { gap: 10px; }

.balance-item {
  position: relative;
  border-radius: 16px;
  padding: 14px 16px;
  overflow: hidden;
}
.balance-item.positive { border-color: rgba(134, 209, 163, 0.22); }
.balance-item.negative { border-color: rgba(239, 138, 126, 0.2); }

/* Mjuk färgkant på vänstersidan som visar plus/minus */
.balance-item.positive::before,
.balance-item.negative::before {
  content: '';
  position: absolute;
  left: 0;
  top: 18%;
  bottom: 18%;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: var(--success);
  box-shadow: 0 0 12px var(--success);
}
.balance-item.negative::before { background: var(--danger); box-shadow: 0 0 12px var(--danger); }

/* Ledaren får guldfolie + krona */
.balances-list .balance-item.positive:first-child {
  border-color: rgba(240, 213, 122, 0.55);
  background:
    radial-gradient(120% 140% at 0% 0%, rgba(212, 175, 55, 0.16) 0%, transparent 55%),
    var(--panel);
  box-shadow: var(--panel-shadow), 0 0 0 1px rgba(212, 175, 55, 0.12), 0 12px 30px -14px rgba(212, 175, 55, 0.55);
}
.balances-list .balance-item.positive:first-child::before {
  background: var(--foil);
  box-shadow: 0 0 14px rgba(240, 213, 122, 0.8);
}
.balances-list .balance-item.positive:first-child::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 241, 194, 0.13) 48%, transparent 60%);
  transform: translateX(-100%);
  animation: rowSheen 5.5s ease-in-out 1.2s infinite;
  pointer-events: none;
}
.balances-list .balance-item.positive:first-child .player-avatar::after {
  content: '';
  position: absolute;
  top: -11px;
  left: 50%;
  width: 18px;
  height: 12px;
  transform: translateX(-50%) rotate(-8deg);
  background: var(--foil);
  background-size: 200% 100%;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 16'%3E%3Cpath d='M1 4l5.5 5L12 1l5.5 8L23 4l-2.5 11h-17z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 16'%3E%3Cpath d='M1 4l5.5 5L12 1l5.5 8L23 4l-2.5 11h-17z'/%3E%3C/svg%3E") center / contain no-repeat;
  filter: drop-shadow(0 0 4px rgba(240, 213, 122, 0.9));
  animation: crownBob 3s ease-in-out infinite;
}
@keyframes crownBob {
  0%, 100% { translate: 0 0; }
  50%      { translate: 0 -2px; }
}
@keyframes rowSheen {
  0%   { transform: translateX(-100%); }
  45%, 100% { transform: translateX(100%); }
}

.balance-name { font-weight: 700; font-size: 15px; letter-spacing: 0.1px; }
.balance-you {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #221906;
  background: var(--foil);
  background-size: 200% 100%;
  padding: 2px 7px;
  border-radius: 999px;
  vertical-align: 2px;
  margin-left: 8px;
}

.balance-amount,
.totals-amount,
.settlement-amount,
.history-total-val,
.total-value,
.sum-value {
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.2px;
}
.balance-amount { font-size: 18px; font-weight: 800; }
.balance-amount.positive { color: var(--success); text-shadow: 0 0 18px rgba(134, 209, 163, 0.35); }
.balance-amount.negative { color: var(--danger);  text-shadow: 0 0 18px rgba(239, 138, 126, 0.3); }
.balance-amount.zero     { color: var(--text-dim); }

/* ===== Avatarer: präglade mynt ===== */
.player-avatar,
.sd-player-avatar {
  position: relative;
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  box-shadow:
    inset 0 0 0 1.5px color-mix(in srgb, currentColor 50%, transparent),
    inset 0 2px 4px rgba(255, 255, 255, 0.08),
    0 0 14px -4px color-mix(in srgb, currentColor 70%, transparent),
    0 3px 8px rgba(0, 0, 0, 0.5);
}

/* ===== Uppgörelse & totaler ===== */
.settlement-toggle {
  border-radius: 16px;
  padding: 14px 16px;
}
.settlement-toggle-label {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-weight: 400;
  font-size: 15px;
  text-transform: none;
  letter-spacing: 0.3px;
  color: var(--text);
}
.settlement-toggle-icon { color: var(--gold); opacity: 1; }
.settlement-toggle[aria-expanded="true"] {
  border-color: rgba(240, 213, 122, 0.5);
  border-radius: 16px 16px 0 0;
}
.settlement-toggle-badge {
  background: var(--foil);
  background-size: 200% 100%;
  color: #221906;
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.55);
  animation: badgeGlow 2.4s ease-in-out infinite;
}
@keyframes badgeGlow {
  0%, 100% { box-shadow: 0 0 6px rgba(212, 175, 55, 0.4); }
  50%      { box-shadow: 0 0 16px rgba(240, 213, 122, 0.85); }
}
.settlements-panel {
  background: linear-gradient(180deg, var(--leather-lo), #130f0c);
  border-color: rgba(240, 213, 122, 0.5);
  border-radius: 0 0 16px 16px;
}
.settlement-item {
  background: rgba(255, 236, 190, 0.03);
  border: 1px solid rgba(212, 175, 55, 0.1);
  border-radius: 12px;
}
.settlement-arrow { color: var(--gold); opacity: 0.7; }
.settlement-amount { color: var(--gold-light); font-weight: 800; }
.btn-confirm-tx { border-color: rgba(134, 209, 163, 0.6); color: var(--success); }

.totals-item {
  padding: 8px 4px;
  border-bottom: 1px dashed rgba(212, 175, 55, 0.1);
}
.totals-item:last-child { border-bottom: none; }

/* ===== Aktiv session-kort ===== */
.active-session-preview {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
}
.active-session-preview[data-session-id] {
  border-color: rgba(134, 209, 163, 0.35);
}
.active-session-preview[data-session-id]::before {
  content: '';
  position: absolute;
  top: 10px;
  right: 10px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 0 rgba(134, 209, 163, 0.6);
  animation: livePulse 1.8s ease-out infinite;
}
@keyframes livePulse {
  0%   { box-shadow: 0 0 0 0 rgba(134, 209, 163, 0.6); }
  100% { box-shadow: 0 0 0 10px rgba(134, 209, 163, 0); }
}
.active-session-preview .muted { font-family: 'Playfair Display', serif; font-style: italic; }

/* ===== Avslutade sessioner / historik ===== */
.closed-session-item,
.history-item {
  border-radius: 16px;
  padding: 14px 16px;
}
.closed-session-item:hover,
.history-item:hover { border-color: rgba(212, 175, 55, 0.35); }

.history-item-name {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 17px;
  color: var(--text);
}
.history-item-date {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.8px;
  color: var(--text-dim);
}
.history-item-header {
  padding-bottom: 8px;
  margin-bottom: 10px;
  border-bottom: 1px dashed rgba(212, 175, 55, 0.14);
}
.history-total-chip {
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 236, 190, 0.05);
  padding: 4px 10px 4px 7px;
  font-size: 12.5px;
}
.history-total-chip.positive { border-color: rgba(134, 209, 163, 0.18); }
.history-total-chip.negative { border-color: rgba(239, 138, 126, 0.16); }
.history-total-chip.positive .history-total-val { color: var(--success); }
.history-total-chip.negative .history-total-val { color: var(--danger); }
.history-total-dot { box-shadow: 0 0 6px currentColor; }

.history-item-actions .btn-sm { border-radius: 10px; }

.btn-tx-history {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
}

/* ===== FAB: guldmynt med roterande glans ===== */
.fab {
  width: 60px;
  height: 60px;
  background: var(--foil);
  background-size: 250% 100%;
  color: #221906;
  font-size: 0;
  box-shadow:
    0 1px 0 rgba(255, 250, 225, 0.8) inset,
    0 -3px 0 rgba(120, 90, 20, 0.4) inset,
    0 12px 30px -8px rgba(212, 175, 55, 0.7),
    0 0 0 6px rgba(212, 175, 55, 0.08);
  animation: foilSweep 5s ease-in-out infinite;
  isolation: isolate;
}
.fab::before {
  content: '';
  position: absolute;
  inset: -7px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0 70%, rgba(255, 241, 194, 0.85) 82%, transparent 92%);
  -webkit-mask: radial-gradient(circle, transparent 62%, #000 64%, #000 70%, transparent 72%);
          mask: radial-gradient(circle, transparent 62%, #000 64%, #000 70%, transparent 72%);
  animation: fabOrbit 4s linear infinite;
  z-index: -1;
}
.fab svg {
  width: 26px;
  height: 26px;
  stroke: #221906;
  stroke-width: 2.4;
  stroke-linecap: round;
  fill: none;
  filter: drop-shadow(0 1px 0 rgba(255, 246, 214, 0.6));
  transition: transform 0.35s var(--spring);
}
.fab:hover svg { transform: rotate(90deg); }
.fab:active { animation: none; }
@keyframes fabOrbit { to { transform: rotate(360deg); } }

/* ===== Bottenmeny: flytande läderpiller ===== */
.bottom-nav {
  left: 12px;
  right: 12px;
  bottom: calc(10px + env(safe-area-inset-bottom));
  height: 64px;
  padding: 0 6px;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(38, 31, 24, 0.9) 0%, rgba(22, 18, 14, 0.94) 100%);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border: 1px solid rgba(212, 175, 55, 0.2);
  box-shadow:
    0 1px 0 rgba(255, 236, 190, 0.06) inset,
    0 18px 40px -12px rgba(0, 0, 0, 0.95),
    0 0 0 1px rgba(0, 0, 0, 0.6);
  max-width: 520px;
  margin: 0 auto;
}
.bottom-nav::after {
  content: '';
  position: absolute;
  inset: 4px;
  border-radius: 20px;
  border: 1px dashed rgba(212, 175, 55, 0.14);
  pointer-events: none;
}

.nav-btn { gap: 4px; color: var(--text-dim); z-index: 1; }
.nav-btn.active::before {
  top: 50%;
  left: 50%;
  width: 58px;
  height: 46px;
  transform: translate(-50%, -50%);
  border-radius: 16px;
  background:
    radial-gradient(80% 90% at 50% 20%, rgba(240, 213, 122, 0.2) 0%, rgba(212, 175, 55, 0.05) 60%, transparent 100%);
  border: 1px solid rgba(212, 175, 55, 0.25);
  animation: navGlowIn 0.4s var(--spring) both;
}
@keyframes navGlowIn {
  from { opacity: 0; transform: translate(-50%, -50%) scale(0.6); }
  to   { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}
.nav-btn.active { color: var(--gold-light); }
.nav-icon {
  display: flex;
  font-size: 0;
}
.nav-icon svg {
  width: 23px;
  height: 23px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.nav-btn.active .nav-icon svg { filter: drop-shadow(0 0 6px rgba(240, 213, 122, 0.7)); }
.nav-btn.active .nav-icon { transform: translateY(-1px); }
.nav-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.4px;
}

/* ===== Session-skärmen ===== */
.session-sticky-top {
  background: linear-gradient(180deg, var(--bg) 70%, rgba(17, 14, 11, 0));
}
.quick-players-list { gap: 6px; }
.quick-player-row {
  background: var(--panel);
  border: 1px solid var(--gold-line);
  border-radius: 14px;
  padding: 6px 10px;
  min-height: 50px;
  box-shadow: var(--panel-shadow);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.quick-player-row:focus-within {
  border-color: rgba(240, 213, 122, 0.5);
  box-shadow: var(--panel-shadow), 0 0 22px -8px rgba(212, 175, 55, 0.6);
}
.quick-player-name { font-weight: 700; font-size: 15px; }
.amount-input {
  height: 38px;
  font-size: 16px;
  font-weight: 800;
  border-radius: 10px;
}
.btn-sign-toggle {
  width: 30px;
  height: 30px;
  background: rgba(212, 175, 55, 0.08);
  border-color: rgba(212, 175, 55, 0.3);
}
.btn-sign-toggle.is-negative {
  color: var(--danger);
  border-color: rgba(239, 138, 126, 0.6);
  background: rgba(239, 138, 126, 0.12);
}

.sum-row {
  border-top: 1px dashed rgba(212, 175, 55, 0.18);
  padding: 10px 4px;
}
.sum-label { font-family: 'Playfair Display', serif; font-style: italic; }
.sum-value.zero { color: var(--success); }
.sum-value.nonzero { color: var(--danger); }

.btn-register { height: 52px; font-size: 16px; letter-spacing: 0.6px; }

/* Anteckningsblocket blir en pergamentsida ur boken */
.session-rounds-list {
  background:
    radial-gradient(120% 80% at 50% 0%, rgba(255, 255, 255, 0.35) 0%, transparent 60%),
    radial-gradient(140% 100% at 100% 100%, rgba(150, 110, 50, 0.22) 0%, transparent 60%),
    #efe2c2;
  border-radius: 6px 6px 10px 10px;
  box-shadow:
    0 2px 0 #d9c89f,
    0 4px 0 #c6b184,
    0 6px 0 #a8916a,
    0 16px 30px -8px rgba(0, 0, 0, 0.8),
    inset 0 0 40px rgba(140, 100, 40, 0.18);
}
.session-rounds-list::before {
  height: 12px;
  background: linear-gradient(180deg, rgba(90, 60, 25, 0.28), transparent);
  opacity: 1;
}
.session-rounds-list::after { background: rgba(176, 56, 44, 0.45); }
.round-row { border-bottom-color: rgba(120, 95, 60, 0.18); }
.round-latest { background: rgba(212, 175, 55, 0.14); }
.round-entry { color: #2a1d10; font-size: 17px; }
.round-old { text-decoration-color: rgba(42, 29, 16, 0.4); }

.session-sticky-total {
  bottom: calc(var(--nav-height) + env(safe-area-inset-bottom));
  left: 12px;
  right: 12px;
  max-width: 520px;
  margin: 0 auto;
  padding: 10px 14px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(38, 31, 24, 0.94), rgba(22, 18, 14, 0.96));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(212, 175, 55, 0.2);
  box-shadow: 0 12px 30px -12px rgba(0, 0, 0, 0.9);
}
.session-sticky-total:empty { display: none; }
.total-entry.positive .total-value { color: var(--success); }
.total-entry.negative .total-value { color: var(--danger); }

/* ===== Statistik ===== */
.stat-card { border-radius: 16px; }
.stat-value {
  background: var(--foil);
  background-size: 250% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: 24px;
}
.stat-card--positive { border-color: rgba(134, 209, 163, 0.3); }
.stat-card--negative { border-color: rgba(239, 138, 126, 0.3); }
.stat-card--positive .stat-value,
.stat-card--negative .stat-value {
  background: none;
  -webkit-text-fill-color: currentColor;
}
.stat-card--positive .stat-value { color: var(--success); }
.stat-card--negative .stat-value { color: var(--danger); }
.stat-label { font-size: 11.5px; color: var(--text-muted); }

.stats-player-card { border-radius: 20px; padding: 16px; }
.stats-player-header {
  padding-bottom: 10px;
  border-bottom: 1px dashed rgba(212, 175, 55, 0.15);
}
.stats-player-name {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-size: 18px;
}

/* ===== Modaler: bottenark i läder ===== */
.modal-overlay {
  background: radial-gradient(120% 80% at 50% 100%, rgba(40, 28, 10, 0.55), rgba(0, 0, 0, 0.8));
  backdrop-filter: blur(8px) saturate(120%);
  -webkit-backdrop-filter: blur(8px) saturate(120%);
}
.modal {
  background:
    radial-gradient(100% 50% at 50% 0%, rgba(212, 175, 55, 0.08) 0%, transparent 70%),
    linear-gradient(180deg, #211b15 0%, #15110d 100%);
  border-top: 1px solid rgba(240, 213, 122, 0.35);
  border-radius: 26px 26px 0 0;
  box-shadow: 0 -20px 60px rgba(0, 0, 0, 0.7), 0 -1px 0 rgba(255, 241, 194, 0.08) inset;
}
.modal::before {
  width: 44px;
  background: linear-gradient(90deg, rgba(212, 175, 55, 0.2), rgba(240, 213, 122, 0.7), rgba(212, 175, 55, 0.2));
}
.modal h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-size: 23px;
  color: var(--gold-light);
}
.modal-close-btn {
  width: 34px;
  height: 34px;
  top: 14px;
  right: 14px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  background: rgba(255, 236, 190, 0.05);
  border: 1px solid rgba(212, 175, 55, 0.15);
}
.modal-close-btn:hover { color: var(--gold-light); border-color: rgba(212, 175, 55, 0.4); }

.modal-overlay--center .modal {
  border-radius: 24px;
  border: 1px solid rgba(240, 213, 122, 0.3);
}

.player-checkbox-btn {
  background: rgba(0, 0, 0, 0.3);
  border-color: rgba(212, 175, 55, 0.15);
  border-radius: 999px;
  padding: 8px 16px;
  font-weight: 600;
}
.player-checkbox-btn.selected {
  background: linear-gradient(180deg, rgba(212, 175, 55, 0.22), rgba(212, 175, 55, 0.08));
  border-color: rgba(240, 213, 122, 0.7);
  color: var(--gold-pale);
  box-shadow: 0 0 16px -4px rgba(212, 175, 55, 0.6);
}

.group-code-display { border-radius: 14px; flex-wrap: wrap; }
.group-code-value {
  font-family: 'Manrope', monospace;
  background: var(--foil);
  background-size: 250% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: foilSweep 6s ease-in-out infinite;
}
.group-player-item { border-radius: 12px; }

.close-book-title {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 24px;
  color: var(--gold-light);
}

/* ===== Toast ===== */
.toast {
  background: linear-gradient(180deg, rgba(40, 32, 24, 0.96), rgba(24, 19, 14, 0.96));
  border: 1px solid rgba(240, 213, 122, 0.35);
  color: var(--text);
  font-weight: 600;
  box-shadow: 0 16px 40px -8px rgba(0, 0, 0, 0.85), 0 0 24px -8px rgba(212, 175, 55, 0.5);
}

.empty-state p { font-family: 'Playfair Display', serif; font-style: italic; font-size: 16px; }

/* ===== Splash ===== */
#splash-screen {
  background:
    radial-gradient(60% 40% at 50% 45%, rgba(212, 175, 55, 0.14) 0%, transparent 70%),
    var(--bg);
}
.splash-title {
  background: var(--foil);
  background-size: 250% auto;
  -webkit-background-clip: text;
  background-clip: text;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar-thumb { background: rgba(212, 175, 55, 0.25); border-radius: 8px; }

/* ===== Mindre rörelse ===== */
@media (prefers-reduced-motion: reduce) {
  .gold-dust,
  .lobby-book-wrap::before,
  .fab::before,
  .balances-list .balance-item.positive:first-child::after { display: none; }
  .btn-primary,
  .fab,
  .header-title,
  .logo-sub,
  .settlement-toggle-badge,
  .group-code-value,
  .lobby-book-img,
  .balances-list .balance-item.positive:first-child .player-avatar::after,
  .active-session-preview[data-session-id]::before { animation: none !important; }
  .lobby-book-img { opacity: 1; }
}

/* ===== Diagramknappar (SVG) ===== */
.stats-chart-inline-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  color: var(--gold-light);
  background: rgba(212, 175, 55, 0.07);
  border: 1px solid rgba(212, 175, 55, 0.2);
  opacity: 1;
}
.stats-chart-inline-btn svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.btn-icon--chart { color: var(--gold-light); }

/* ===== Session-header: kompakt "Avsluta"-pill ===== */
#screen-session .app-header { gap: 6px; }
#screen-session .header-title {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 0 4px;
}
#screen-session .header-actions { gap: 0; flex-shrink: 0; }
#btn-close-session {
  white-space: nowrap;
  font-size: 12px;
  font-weight: 700;
  padding: 7px 11px;
  margin-left: 4px;
  border-radius: 999px;
  border: 1px solid rgba(239, 138, 126, 0.5);
  background: rgba(239, 138, 126, 0.08);
  color: var(--danger);
}
#screen-session .app-header { padding-left: 6px; padding-right: 10px; }
#screen-session .header-title { font-size: 19px; letter-spacing: 0.5px; }
#screen-session .header-actions .btn-icon { min-width: 38px; padding: 8px; }

/* ===== Gruppkod: kod överst, knappar under ===== */
.group-code-display {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 8px;
  padding: 14px;
  text-align: center;
}
.group-code-display .label,
.group-code-display .group-code-value { grid-column: 1 / -1; }
.group-code-display .label { font-size: 10.5px; letter-spacing: 1.6px; font-weight: 700; }
.group-code-display .group-code-value { font-size: 30px; letter-spacing: 8px; padding: 2px 0 8px; }
.group-code-display .btn-text {
  font-size: 13px;
  padding: 9px 8px;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.25);
  background: rgba(212, 175, 55, 0.06);
}

/* =====================================================================
   NYA FUNKTIONER
   ===================================================================== */

/* ===== Guldig bekräftelseruta ===== */
.gold-confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 20px;
  background: radial-gradient(90% 60% at 50% 50%, rgba(40, 28, 10, 0.5), rgba(0, 0, 0, 0.82));
  backdrop-filter: blur(8px) saturate(120%);
  -webkit-backdrop-filter: blur(8px) saturate(120%);
  animation: overlayFadeIn 0.2s ease both;
}
.gold-confirm-overlay.hidden { display: none; }
.gold-confirm-overlay.closing { animation: overlayFadeOut 0.18s ease both; }
.gold-confirm-overlay.closing .gold-confirm { animation: confirmOut 0.18s ease both; }

.gold-confirm {
  position: relative;
  width: 100%;
  max-width: 340px;
  padding: 34px 22px 20px;
  text-align: center;
  border-radius: 24px;
  background:
    radial-gradient(100% 60% at 50% 0%, rgba(212, 175, 55, 0.13) 0%, transparent 70%),
    linear-gradient(180deg, #231c15 0%, #15110d 100%);
  border: 1px solid rgba(240, 213, 122, 0.35);
  box-shadow: 0 30px 70px -10px rgba(0, 0, 0, 0.9), 0 0 40px -12px rgba(212, 175, 55, 0.45), inset 0 1px 0 rgba(255, 241, 194, 0.08);
  animation: confirmIn 0.34s var(--spring) both;
}
.gold-confirm::before {
  content: '';
  position: absolute;
  inset: 6px;
  border: 1px dashed rgba(212, 175, 55, 0.18);
  border-radius: 19px;
  pointer-events: none;
}
/* Sigill: guldmynt med ett präglat ? eller ! */
.gold-confirm-seal {
  position: absolute;
  top: -26px;
  left: 50%;
  width: 52px;
  height: 52px;
  margin-left: -26px;
  border-radius: 50%;
  background: var(--foil);
  background-size: 250% 100%;
  box-shadow: 0 0 0 4px #1a1510, 0 8px 22px -4px rgba(212, 175, 55, 0.7), inset 0 1px 0 rgba(255, 250, 225, 0.8), inset 0 -2px 0 rgba(120, 90, 20, 0.4);
  animation: foilSweep 4s ease-in-out infinite;
}
.gold-confirm-seal::after {
  content: '?';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-weight: 700;
  font-size: 26px;
  color: #3a2a08;
  text-shadow: 0 1px 0 rgba(255, 246, 214, 0.6);
}
.gold-confirm.is-danger .gold-confirm-seal::after { content: '!'; color: #6e1f16; }
.gold-confirm.is-danger { border-color: rgba(239, 138, 126, 0.4); }

.gold-confirm-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 22px;
  line-height: 1.25;
  color: var(--gold-light);
  margin: 4px 0 8px;
  overflow-wrap: anywhere;
}
.gold-confirm-msg {
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0 0 22px;
}
.gold-confirm-actions { display: flex; gap: 10px; }
.gold-confirm-actions .btn { flex: 1; min-height: 48px; }
.gold-confirm.is-danger .btn-primary {
  background: linear-gradient(180deg, #e98a7f 0%, #c85a4e 100%);
  color: #2a0c08;
  text-shadow: none;
  animation: none;
  box-shadow: inset 0 1px 0 rgba(255, 220, 210, 0.5), 0 10px 26px -10px rgba(239, 138, 126, 0.7);
}

@keyframes confirmIn {
  from { opacity: 0; transform: translateY(14px) scale(0.92); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes confirmOut {
  to { opacity: 0; transform: scale(0.95); }
}

/* ===== Rullande siffror: kort glöd i riktningen ===== */
.num-rise { animation: numRise 0.9s ease-out; }
.num-fall { animation: numFall 0.9s ease-out; }
@keyframes numRise {
  0%   { text-shadow: 0 0 0 rgba(134, 209, 163, 0); }
  30%  { text-shadow: 0 0 16px rgba(134, 209, 163, 0.9); }
  100% { text-shadow: 0 0 18px rgba(134, 209, 163, 0.25); }
}
@keyframes numFall {
  0%   { text-shadow: 0 0 0 rgba(239, 138, 126, 0); }
  30%  { text-shadow: 0 0 16px rgba(239, 138, 126, 0.9); }
  100% { text-shadow: 0 0 18px rgba(239, 138, 126, 0.2); }
}

/* ===== Duell ===== */
.duel {
  position: relative;
  padding: 16px;
  border-radius: 20px;
  background:
    radial-gradient(80% 60% at 50% 0%, rgba(212, 175, 55, 0.1) 0%, transparent 70%),
    var(--panel);
  border: 1px solid rgba(212, 175, 55, 0.22);
  box-shadow: var(--panel-shadow);
}
.duel-pickers {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
}
.duel-select {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 10px 30px 10px 12px;
  border-radius: 12px;
  font: 700 14px var(--font-body);
  color: var(--text);
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23d4af37' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") right 10px center / 16px no-repeat,
    rgba(8, 6, 4, 0.55);
  border: 1px solid rgba(212, 175, 55, 0.22);
  text-overflow: ellipsis;
}
.duel-select:focus { outline: none; border-color: rgba(240, 213, 122, 0.7); }
.duel-select option { background: #1c1813; color: var(--text); }
.duel-vs {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-weight: 700;
  font-size: 18px;
  color: var(--gold);
  text-shadow: 0 0 12px rgba(212, 175, 55, 0.6);
}

.duel-score {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  margin: 22px 0 12px;
}
.duel-side { display: flex; justify-content: center; }
.duel-avatar {
  width: 54px;
  height: 54px;
  font-size: 22px;
  transition: transform 0.3s var(--spring);
}
.duel-side.is-lead .duel-avatar {
  transform: scale(1.08);
  box-shadow:
    inset 0 0 0 1.5px color-mix(in srgb, currentColor 60%, transparent),
    0 0 0 3px rgba(212, 175, 55, 0.55),
    0 0 24px -2px rgba(240, 213, 122, 0.7);
}
.duel-side.is-lead .duel-avatar::after {
  content: '';
  position: absolute;
  top: -15px;
  left: 50%;
  width: 22px;
  height: 14px;
  transform: translateX(-50%) rotate(-8deg);
  background: var(--foil);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 16'%3E%3Cpath d='M1 4l5.5 5L12 1l5.5 8L23 4l-2.5 11h-17z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 16'%3E%3Cpath d='M1 4l5.5 5L12 1l5.5 8L23 4l-2.5 11h-17z'/%3E%3C/svg%3E") center / contain no-repeat;
  filter: drop-shadow(0 0 4px rgba(240, 213, 122, 0.9));
}
.duel-tally {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: center;
  gap: 0 8px;
  text-align: center;
}
.duel-num,
.duel-dash {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  font-size: 38px;
  line-height: 1;
  background: var(--foil);
  background-size: 250% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: foilSweep 6s ease-in-out infinite;
}
.duel-dash { font-size: 28px; opacity: 0.6; }
.duel-sub {
  flex-basis: 100%;
  margin-top: 6px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-muted);
}

.duel-bar {
  display: flex;
  height: 8px;
  gap: 3px;
  margin-bottom: 14px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.4);
}
.duel-bar span {
  display: block;
  height: 100%;
  border-radius: 999px;
  transition: width 0.6s var(--ease-out-expo);
}
.duel-bar span[style*="width:0%"] { display: none; }

.duel-rows { display: flex; flex-direction: column; }
.duel-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
  padding: 9px 2px;
  border-top: 1px dashed rgba(212, 175, 55, 0.12);
}
.duel-label {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 13px;
  color: #cdb77a;
  text-align: center;
  white-space: nowrap;
}
.duel-val {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}
.duel-row .duel-val:first-child { text-align: left; }
.duel-row .duel-val:last-child { text-align: right; }
.duel-val.is-better { color: var(--gold-light); text-shadow: 0 0 12px rgba(212, 175, 55, 0.45); }
.duel-empty {
  margin: 16px 0 4px;
  text-align: center;
  font-family: 'Playfair Display', serif;
  font-style: italic;
  color: var(--text-muted);
}

/* ===== Diagram ===== */
.btn-open-chart-from-stats {
  width: 32px;
  height: 32px;
  justify-content: center;
  padding: 0;
  opacity: 1;
  color: var(--gold-light);
  border-radius: 10px;
  background: rgba(212, 175, 55, 0.07);
  border: 1px solid rgba(212, 175, 55, 0.2);
}
.btn-open-chart-from-stats svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.chart-container,
.stats-chart-container {
  border-radius: 16px;
  padding: 8px 4px 4px;
  background:
    radial-gradient(90% 60% at 50% 0%, rgba(212, 175, 55, 0.06) 0%, transparent 70%),
    rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(212, 175, 55, 0.12);
}

@media (prefers-reduced-motion: reduce) {
  .gold-confirm,
  .gold-confirm-seal,
  .duel-num,
  .duel-dash,
  .num-rise,
  .num-fall { animation: none !important; }
}
