:root {
  --bg-body: #23262e;
  --bg-panel: #2c2f38;
  --bg-panel-alt: #2c2f38;
  --bg-accent: #363a45;
  --border-subtle: #454b56;
  --text-main: #e8eaef;
  --text-muted: #9ca3af;
  --accent: #22c55e;
  --accent-soft: rgba(34, 197, 94, 0.14);
  --danger: #f97373;
  --danger-soft: rgba(248, 113, 113, 0.12);
  --radius-lg: 18px;
  --radius-md: 10px;
  --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.3);
  --transition-fast: 0.18s ease-out;
  --gap-lg: 24px;
  --gap-md: 16px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: radial-gradient(ellipse at top, #2d313a 0, #272a32 45%, #23262e 100%);
  color: var(--text-main);
}

.app {
  max-width: 1120px;
  margin: 0 auto;
  padding: 32px 16px 32px;
  display: flex;
  flex-direction: column;
  gap: var(--gap-lg);
}

.app__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.app__header h1 {
  margin: 0 0 4px;
  font-size: 28px;
  letter-spacing: 0.02em;
}

.app__subtitle {
  margin: 0;
  color: var(--text-muted);
  font-size: 14px;
}

.header__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.auth-block {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.header-balance {
  font-size: 14px;
  color: var(--text-muted);
}

.header-balance strong {
  color: var(--accent);
}

.notifications-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.notifications-bell {
  position: relative;
  padding: 6px 10px;
  font-size: 18px;
  line-height: 1;
}

.notifications-bell__badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  font-size: 11px;
  font-weight: 600;
  line-height: 18px;
  text-align: center;
  color: #fff;
  background: var(--danger);
  border-radius: 9px;
}

.notifications-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 6px;
  width: 320px;
  max-height: 400px;
  background: var(--bg-panel);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  z-index: 50;
  display: flex;
  flex-direction: column;
}

.notifications-dropdown.hidden {
  display: none;
}

.notifications-dropdown__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-subtle);
}

.notifications-dropdown__header h4 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
}

.notifications-list {
  overflow-y: auto;
  padding: 8px;
  max-height: 320px;
}

.notifications-list__empty {
  margin: 0;
  padding: 16px;
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
}

.notification-item {
  padding: 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  margin-bottom: 8px;
  background: var(--bg-accent);
}

.notification-item:last-child {
  margin-bottom: 0;
}

.notification-item--read .notification-item__title {
  font-weight: 500;
  color: var(--text-muted);
}

.notification-item__title {
  display: block;
  font-size: 13px;
  margin: 0 0 4px;
  color: var(--text-main);
}

.notification-item__body {
  margin: 0 0 8px;
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.4;
}

.notification-item__date {
  font-size: 11px;
  color: var(--text-muted);
}

.notification-item__actions {
  margin-top: 8px;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.auth-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 14px;
}

.auth-tab {
  padding: 6px 12px;
  font-size: 13px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast), border-color var(--transition-fast);
}

.auth-tab:hover {
  background: var(--bg-accent);
  color: var(--text-main);
}

.auth-tab.active {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-form label {
  font-size: 13px;
  color: var(--text-muted);
}

.auth-form input {
  background: var(--bg-accent);
  border-radius: 999px;
  border: 1px solid var(--border-subtle);
  padding: 10px 14px;
  color: var(--text-main);
  font-size: 14px;
  outline: none;
}

.auth-form-error {
  font-size: 13px;
  color: var(--danger);
}

/* Блок «Игрок» на главной (только отображение) */
.launcher-player-section {
  min-height: 2.5em;
}
.launcher-player-display {
  margin: 0;
  font-size: 14px;
  color: var(--text-muted);
}
.launcher-player-display--guest {
  font-style: italic;
}

/* Личный кабинет — табы и карточный layout */
.cabinet-modal {
  max-width: 520px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.5);
}

.cabinet-modal__header {
  position: relative;
  padding: 20px 24px 16px;
  background: linear-gradient(160deg, rgba(34, 197, 94, 0.12) 0%, rgba(44, 48, 58, 0.98) 55%);
  border-bottom: 1px solid var(--border-subtle);
}

.cabinet-modal__avatar {
  width: 48px;
  height: 48px;
  margin-bottom: 10px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent) 0%, #16a34a 100%);
  opacity: 0.95;
}

.cabinet-modal__title {
  margin: 0 0 2px;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.cabinet-modal__email {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.cabinet-modal__header .modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
}

.cabinet-tabs {
  display: flex;
  gap: 2px;
  padding: 0 16px;
  background: var(--bg-accent);
  border-bottom: 1px solid var(--border-subtle);
  overflow-x: auto;
}

.cabinet-tab {
  padding: 12px 14px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s;
}

.cabinet-tab:hover {
  color: var(--text-main);
}

.cabinet-tab.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.cabinet-modal__body {
  padding: 20px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-height: 65vh;
  overflow-y: auto;
}

/* Вариант кабинета как отдельной страницы */
.cabinet-page-body .cabinet-modal {
  max-width: 960px;
  width: 100%;
  margin: 16px auto 32px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.cabinet-page-body .cabinet-modal__body {
  max-height: none;
  overflow-y: visible;
}

.cabinet-page-main {
  display: flex;
  justify-content: center;
}

@media (max-width: 900px) {
  .cabinet-page-body .cabinet-modal {
    margin: 8px auto 24px;
    border-radius: 0;
    border-left: none;
    border-right: none;
  }

  .cabinet-modal__body {
    padding: 16px 12px 20px;
  }
}

.cabinet-panel {
  display: none;
  flex-direction: column;
  gap: 18px;
  animation: cabinet-panel-in 0.2s ease;
}

.cabinet-panel.active {
  display: flex;
}

@keyframes cabinet-panel-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.cabinet-card {
  background: rgba(40, 44, 52, 0.85);
  border-radius: 12px;
  padding: 18px;
  border: 1px solid var(--border-subtle);
}

.cabinet-card--compact {
  padding: 16px 18px;
}

.cabinet-card--compact .cabinet-balance-value {
  margin: 0 0 4px;
  font-size: 24px;
}

.cabinet-balance-sub {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}

.cabinet-card--recent .cabinet-card__title {
  margin-bottom: 10px;
}

.cabinet-card__link-wrap {
  margin: 10px 0 0;
  padding-top: 10px;
  border-top: 1px solid var(--border-subtle);
}

.cabinet-card__link {
  font-size: 13px;
  color: var(--accent);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  text-decoration: none;
}

.cabinet-card__link:hover {
  text-decoration: underline;
}

.cabinet-card__header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.cabinet-card__icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 16px;
  font-weight: 700;
}

.cabinet-card__title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-main);
}

.cabinet-card--balance .cabinet-balance-value {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.02em;
}

.cabinet-balance-breakdown {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
}

.cabinet-balance-line {
  margin: 0 0 6px;
  font-size: 13px;
  color: var(--text-muted);
}

.cabinet-balance-line:last-of-type {
  margin-bottom: 0;
}

.cabinet-balance-label {
  margin-right: 6px;
}

.cabinet-balance-withdraw-hint {
  margin-top: 8px;
}

.cabinet-promo-row {
  display: flex;
  gap: 10px;
  margin-bottom: 8px;
}

.cabinet-promo-row input {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-accent);
  color: var(--text-main);
  font-size: 14px;
}

.cabinet-promo-message {
  margin: 0;
  font-size: 13px;
}

.cabinet-promo-message--error {
  color: var(--danger, #f97373);
}

.cabinet-withdraw-summary {
  margin: 8px 0 12px;
  font-size: 13px;
  color: var(--text-muted);
}

.cabinet-withdraw-agree {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 13px;
  cursor: pointer;
}

.cabinet-withdraw-agree input { width: auto; margin: 0; }

.cabinet-card__subtitle {
  margin: 20px 0 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
}

.cabinet-withdraw-list {
  margin-top: 8px;
}

.cabinet-withdraw-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-subtle);
  font-size: 13px;
}

.cabinet-withdraw-row:last-child { border-bottom: none; }

.cabinet-withdraw-row__amount { font-weight: 600; }
.cabinet-withdraw-row__fee { color: var(--text-muted); }
.cabinet-withdraw-row__address { font-family: monospace; font-size: 12px; }
.cabinet-withdraw-row__status--pending { color: var(--warning, #eab308); }
.cabinet-withdraw-row__status--approved { color: var(--success, #22c55e); }
.cabinet-withdraw-row__status--rejected { color: var(--danger, #f97373); }
.cabinet-withdraw-row__date { color: var(--text-muted); margin-left: auto; }
.cabinet-withdraw-row__note { width: 100%; font-size: 12px; color: var(--text-muted); }

.cabinet-field {
  margin-bottom: 14px;
}
.cabinet-field:last-of-type {
  margin-bottom: 0;
}

.cabinet-field label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  color: var(--text-muted);
}

.cabinet-field input {
  width: 100%;
  margin-bottom: 8px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-accent);
  color: var(--text-main);
  font-size: 14px;
}

.cabinet-deposit-row {
  display: flex;
  gap: 10px;
  margin-bottom: 8px;
}

.cabinet-deposit-row input {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-accent);
  color: var(--text-main);
  font-size: 14px;
}

.cabinet-native-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
  margin-top: 10px;
}

.cabinet-native-item label {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.cabinet-native-item input {
  width: 100%;
  padding: 8px 10px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-accent);
  color: var(--text-main);
  font-size: 13px;
  margin-bottom: 4px;
}

.cabinet-native-rate {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.cabinet-hint {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.cabinet-history-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}

.cabinet-history-filters__label {
  font-size: 12px;
  color: var(--text-muted);
  margin-right: 4px;
}

.cabinet-history-filter {
  padding: 6px 12px;
  font-size: 12px;
  color: var(--text-muted);
  background: var(--bg-accent);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}

.cabinet-history-filter:hover {
  color: var(--text-main);
  border-color: var(--text-muted);
}

.cabinet-history-filter.active {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-soft, rgba(34, 197, 94, 0.12));
}

.cabinet-card--history .cabinet-history {
  max-height: 240px;
  overflow-y: auto;
  padding: 0;
  font-size: 13px;
}

.cabinet-history--short {
  max-height: 160px;
}

.cabinet-history-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px 14px;
  align-items: baseline;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 13px;
}

.cabinet-history-row:last-child {
  border-bottom: none;
}

.cabinet-history-row__type {
  color: var(--text-main);
  font-weight: 500;
}

.cabinet-history-row__amount {
  color: var(--text-main);
  font-variant-numeric: tabular-nums;
}

.cabinet-history-row__amount {
  color: var(--accent);
}

.cabinet-history-row__amount--minus {
  color: var(--danger, #f97373);
}

.cabinet-history-row__balance {
  font-size: 12px;
  color: var(--text-muted);
}

.cabinet-history-row .cabinet-history-row__date {
  grid-column: 1 / -1;
  font-size: 11px;
  color: var(--text-muted);
  opacity: 0.9;
}

@media (min-width: 420px) {
  .cabinet-history-row {
    grid-template-columns: 100px 1fr auto auto;
  }
  .cabinet-history-row .cabinet-history-row__date {
    grid-column: auto;
  }
}

.app__main {
  display: grid;
  grid-template-columns: minmax(0, 320px) minmax(0, 1fr);
  gap: var(--gap-lg);
}

.panel {
  background: radial-gradient(circle at top left, var(--bg-body) 0, var(--bg-body) 40%, var(--bg-body) 100%);
  border-radius: var(--radius-lg);
  padding: 20px 20px 18px;
  border: 1px solid rgba(45, 49, 58, 0.9);
  box-shadow: var(--shadow-soft);
}

.panel--left {
  display: flex;
  flex-direction: column;
  gap: var(--gap-md);
}

.panel--right {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.panel__nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.panel__title {
  margin: 0;
  font-size: 18px;
}

.panel__section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

label {
  font-size: 13px;
  color: var(--text-muted);
}

input[type="text"] {
  background: var(--bg-accent);
  border-radius: 999px;
  border: 1px solid var(--border-subtle);
  padding: 10px 14px;
  color: var(--text-main);
  font-size: 14px;
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast),
    background var(--transition-fast), transform var(--transition-fast);
}

input[type="text"]::placeholder {
  color: #6b7280;
}

input[type="text"]:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.5);
  transform: translateY(-0.5px);
}

/* Выпадающие списки в стиле площадки (ЛК, лаунчер) */
select {
  display: block;
  width: 100%;
  max-width: 100%;
  padding: 10px 36px 10px 14px;
  font-size: 14px;
  font-family: inherit;
  color: var(--text-main);
  background-color: var(--bg-accent);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  outline: none;
  cursor: pointer;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%239ca3af' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 14px;
}

select:hover {
  border-color: rgba(148, 163, 184, 0.6);
}

select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.5);
}

select option {
  background: var(--bg-panel);
  color: var(--text-main);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 999px;
  border: 1px solid transparent;
  padding: 9px 16px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast),
    box-shadow var(--transition-fast), transform var(--transition-fast), border-color var(--transition-fast);
  white-space: nowrap;
}

.btn--primary {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: #022c22;
  box-shadow: 0 14px 30px rgba(22, 163, 74, 0.5);
}

.btn--primary:hover {
  background: linear-gradient(135deg, #4ade80, #22c55e);
  transform: translateY(-1px);
  box-shadow: 0 18px 40px rgba(34, 197, 94, 0.55);
}

.btn--primary:active {
  transform: translateY(0);
  box-shadow: 0 10px 24px rgba(22, 163, 74, 0.45);
}

.btn--ghost {
  background: transparent;
  color: var(--text-muted);
  border-color: rgba(148, 163, 184, 0.4);
}

.btn--ghost:hover {
  background: rgba(45, 49, 58, 0.85);
  color: var(--text-main);
}

.btn--small {
  padding: 6px 10px;
  font-size: 12px;
}

.btn:disabled,
.btn.btn--disabled {
  opacity: 0.6;
  cursor: default;
  box-shadow: none;
  transform: none;
}

.message {
  min-height: 18px;
  font-size: 13px;
  color: var(--text-muted);
}

.message--error {
  color: var(--danger);
}

.message--success {
  color: var(--accent);
}

/* Промо-блок ставок на спорт на главной */
.sports-promo-card {
  margin-bottom: var(--gap-lg);
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  background: radial-gradient(circle at top left, rgba(34, 197, 94, 0.2), transparent 55%),
    radial-gradient(circle at bottom right, rgba(56, 189, 248, 0.16), transparent 60%),
    var(--bg-panel);
  border: 1px solid rgba(148, 163, 184, 0.4);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  gap: 14px;
  box-shadow: var(--shadow-soft);
}

.sports-promo-card__left {
  flex: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.sports-promo-card__right {
  flex: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid rgba(75, 85, 99, 0.7);
  margin-top: 4px;
}

.sports-promo-card__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.16);
  color: var(--accent);
}

.sports-promo-card__title {
  margin: 2px 0 0;
  font-size: 20px;
}

.sports-promo-card__text {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}

.sports-promo-card__cta {
  margin-top: 10px;
  width: 100%;
}

.sports-promo-card__odds-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
}

.sports-promo-card__odds-label {
  color: var(--text-muted);
}

.sports-promo-card__odds-values {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.sports-promo-card__hint {
  margin-top: 4px;
  font-size: 11px;
  color: var(--text-muted);
  opacity: 0.85;
}

@media (max-width: 800px) {
  .sports-promo-card__cta {
    text-align: center;
  }
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}

.game-card {
  background: radial-gradient(circle at top left, rgba(34, 197, 94, 0.18), rgba(44, 48, 58, 0.96));
  border-radius: var(--radius-md);
  border: 1px solid rgba(55, 65, 81, 0.9);
  padding: 14px 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
  overflow: hidden;
}

.game-card::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: radial-gradient(circle at top, rgba(34, 197, 94, 0.12), transparent 55%);
  opacity: 0;
  transition: opacity var(--transition-fast);
  pointer-events: none;
}

.game-card:hover::before {
  opacity: 1;
}

.game-card__title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.game-card__title {
  margin: 0;
  font-size: 15px;
}

.game-card__badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid rgba(52, 211, 153, 0.4);
  background: rgba(6, 95, 70, 0.4);
  color: #a7f3d0;
}

.game-card__badge--online {
  border-color: rgba(52, 211, 153, 0.6);
  background: rgba(6, 95, 70, 0.6);
  color: #bbf7d0;
}

.game-card__badge--offline {
  border-color: rgba(248, 113, 113, 0.6);
  background: rgba(127, 29, 29, 0.7);
  color: #fee2e2;
}

.game-card__badge--unknown {
  border-color: rgba(148, 163, 184, 0.6);
  background: rgba(69, 75, 86, 0.8);
  color: #e5e7eb;
}

.game-card__desc {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}

.game-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 4px;
}

.game-card__meta {
  font-size: 11px;
  color: #6b7280;
}

.empty-state {
  margin-top: 8px;
  font-size: 13px;
  color: var(--text-muted);
}

.hidden {
  display: none !important;
}

.admin {
  background: radial-gradient(circle at top left, rgba(248, 113, 113, 0.12), var(--bg-body) 55%, var(--bg-body) 100%);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(55, 65, 81, 0.9);
  padding: 18px 18px 14px;
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.admin__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin__header-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.admin__header h2 {
  margin: 0;
  font-size: 18px;
}

.admin__hint {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}

.admin-table-wrapper {
  border-radius: var(--radius-md);
  border: 1px solid rgba(69, 75, 86, 0.9);
  background: radial-gradient(circle at top left, var(--bg-body) 0, var(--bg-body) 40%, var(--bg-body) 100%);
  overflow: hidden;
}

.admin-add-game {
  margin-top: 14px;
  padding: 12px 12px 10px;
  border-radius: var(--radius-md);
  border: 1px dashed rgba(55, 65, 81, 0.9);
  background: rgba(45, 49, 58, 0.85);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.admin-add-game__title {
  margin: 0;
  font-size: 14px;
}

.admin-add-game__hint {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.admin-add-game__form {
  margin-top: 6px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 8px;
}

.admin-add-game__form input,
.admin-add-game__form textarea {
  background: var(--bg-accent);
  border-radius: 999px;
  border: 1px solid var(--border-subtle);
  padding: 7px 11px;
  color: var(--text-main);
  font-size: 12px;
  outline: none;
  resize: vertical;
}

.admin-add-game__form textarea {
  border-radius: 10px;
  min-height: 40px;
}

.admin-add-game__form input::placeholder,
.admin-add-game__form textarea::placeholder {
  color: #6b7280;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.admin-table th,
.admin-table td {
  padding: 9px 10px;
  border-bottom: 1px solid rgba(69, 75, 86, 0.9);
}

.admin-table th {
  text-align: left;
  font-weight: 500;
  color: var(--text-muted);
  background: rgba(45, 49, 58, 0.9);
}

.admin-table tr:last-child td {
  border-bottom: none;
}

.admin-table__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  font-size: 12px;
  color: var(--text-muted);
}

.switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.switch__track {
  width: 32px;
  height: 18px;
  border-radius: 999px;
  background: rgba(69, 75, 86, 0.9);
  position: relative;
  transition: background var(--transition-fast);
}

.switch__thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #f9fafb;
  position: absolute;
  top: 2px;
  left: 2px;
  transition: transform var(--transition-fast), background var(--transition-fast);
  box-shadow: 0 2px 6px rgba(45, 49, 58, 0.9);
}

.switch input:checked + .switch__track {
  background: rgba(34, 197, 94, 0.85);
}

.switch input:checked + .switch__track .switch__thumb {
  transform: translateX(14px);
  background: #ecfdf5;
}

.badge-disabled {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  background: var(--danger-soft);
  color: #fecaca;
  border: 1px solid rgba(248, 113, 113, 0.4);
}

.badge-server {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
}

.badge-server--online {
  background: var(--accent-soft);
  color: #bbf7d0;
  border: 1px solid rgba(34, 197, 94, 0.5);
}

.badge-server--offline {
  background: var(--danger-soft);
  color: #fecaca;
  border: 1px solid rgba(248, 113, 113, 0.6);
}

.badge-server--unknown {
  background: rgba(69, 75, 86, 0.9);
  color: var(--text-muted);
  border: 1px solid rgba(55, 65, 81, 0.9);
}

.app__footer {
  font-size: 12px;
  color: #6b7280;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(45, 49, 58, 0.9);
  backdrop-filter: blur(4px);
}

.modal__content {
  position: relative;
  max-width: 820px;
  width: min(100% - 32px, 820px);
  background: radial-gradient(circle at top left, rgba(34, 197, 94, 0.08), var(--bg-body));
  border-radius: var(--radius-lg);
  border: 1px solid rgba(69, 75, 86, 0.9);
  box-shadow: var(--shadow-soft);
  padding: 18px 18px 14px;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.modal__header h3 {
  margin: 0;
  font-size: 16px;
}

.modal__body {
  font-size: 13px;
  color: var(--text-muted);
}

.modal__hint {
  margin: 0;
}

.modal__hint--error {
  color: var(--danger);
}

.summary-totals {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.summary-totals__item {
  flex: 1 1 180px;
  padding: 8px 10px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(69, 75, 86, 0.9);
  background: rgba(45, 49, 58, 0.9);
}

.summary-totals__label {
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 3px;
}

.summary-totals__value {
  font-size: 15px;
  color: var(--text-main);
  font-weight: 500;
}

.summary-table-wrapper {
  max-height: 360px;
  overflow: auto;
  border-radius: var(--radius-md);
  border: 1px solid rgba(69, 75, 86, 0.9);
}

.summary-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.summary-table th,
.summary-table td {
  padding: 8px 9px;
  border-bottom: 1px solid rgba(69, 75, 86, 0.9);
}

.summary-table th {
  text-align: left;
  font-weight: 500;
  color: var(--text-muted);
  background: rgba(45, 49, 58, 0.9);
  position: sticky;
  top: 0;
}

.summary-table tr:last-child td {
  border-bottom: none;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono",
    "Courier New", monospace;
  font-size: 12px;
}

@media (max-width: 900px) {
  .app__main {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 600px) {
  .app {
    padding-top: 20px;
  }

  .app__header {
    flex-direction: column;
    align-items: flex-start;
  }
}

