/* =========================================================
   MOTYW: DARK + GOLD (pełny, finalny)
   ========================================================= */

/* ---------- Zmienne ---------- */
:root {
  --bg-main: #0d0f1a;
  --bg-panel: linear-gradient(145deg, #1a1c2e, #11131f);

  --gold-1: #d4af37;          /* głębokie złoto */
  --gold-2: #ffd700;          /* jasne złoto */
  --gold-3: #ffea70;          /* blask przy hover */

  --border-color: rgba(255, 215, 0, 0.22);
  --border-color-soft: rgba(255, 215, 0, 0.28);

  --text-light: #f0f3f8;
  --text-dark: #a79658;       /* przygaszone złoto */

  --font-heading: 'Cinzel', serif;
  --font-body: 'Montserrat', sans-serif;
}

/* ---------- Layout ---------- */
body {
  background-color: var(--bg-main);
  color: var(--text-light);
  font-family: var(--font-body);
}

.dashboard-container {
  max-width: 1600px;
  margin: 2rem auto;
  padding: 0 2rem;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 2rem;
  align-items: start;
}

.dashboard-main { display: flex; flex-direction: column; gap: 2rem; }

.dashboard-sidebar {
  position: sticky;
  top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

/* ---------- Panele ---------- */
.panel,
.card {
  background: var(--bg-panel);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 1.5rem 2rem;
  box-shadow: 0 8px 25px rgba(0,0,0,0.3);
  transition: transform .2s ease, box-shadow .2s ease;
}
.panel:hover,
.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 35px rgba(255, 215, 0, 0.16);
}

.panel-title,
.card-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 1.2rem;
  color: var(--gold-1);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: .6rem;
}
.panel-title i,
.card-title i { margin-right: .75rem; color: var(--gold-1); }

/* ---------- Kafelki doładowań ---------- */
.recharge-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
}
.recharge-tile {
  background-color: rgba(0,0,0,0.25);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  text-align: center;
  padding: 1.3rem 1rem;
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--text-light);
  transition: all .3s ease;
  cursor: pointer;
}
.recharge-tile span {
  display: block;
  font-size: .9rem;
  font-weight: 400;
  color: var(--text-dark);
  margin-top: .3rem;
}
.recharge-tile:hover {
  background-color: var(--gold-2);
  color: #000;
  border-color: var(--gold-2);
}

/* ---------- Historia / zakładki ---------- */
.history-panel .panel-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 1rem;
}
.history-panel .tab-btn {
  padding: .6rem 1.2rem;
  background: none;
  border: none;
  color: var(--text-dark);
  font-weight: 600;
  cursor: pointer;
  transition: color .3s ease;
}
.history-panel .tab-btn:hover { color: var(--gold-3); }
.history-panel .tab-btn.active {
  color: var(--gold-2);
  position: relative;
}
.history-panel .tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0;
  width: 100%; height: 2px;
  background: var(--gold-2);
}

/* ✅ KLUCZOWE: przełączanie treści zakładek */
.history-panel .tab-content { display: none; }
.history-panel .tab-content.active { display: block; }

/* Lista zakupów/płatności */
.purchase-list { display: flex; flex-direction: column; gap: 1rem; }
.purchase-card {
  display: flex; justify-content: space-between; align-items: center;
  background: rgba(0,0,0,0.25);
  border-left: 4px solid var(--gold-2);
  padding: 1rem 1.5rem; border-radius: 10px;
  transition: background-color .3s ease;
}
.purchase-card:hover { background-color: rgba(255,215,0,0.1); }

.purchase-info { display: flex; align-items: center; gap: 1rem; }
.purchase-icon { width: 40px; height: 40px; border-radius: 6px; }
.purchase-name { font-weight: 600; color: var(--text-light); }
.purchase-details { text-align: right; color: var(--text-dark); }
.purchase-price { font-weight: 700; color: var(--gold-2); }
.purchase-date { font-size: .8rem; color: var(--text-dark); }

/* ---------- Statystyki ---------- */
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; text-align: center; }
.stat-label { color: var(--text-dark); font-size: .9rem; }
.stat-value { font-weight: 700; font-size: 1.4rem; color: var(--gold-2); }

/* ---------- System poleceń ---------- */
.referral-code {
  background-color: rgba(0,0,0,0.3);
  border: 1px solid var(--border-color);
  color: var(--gold-2);
  text-align: center;
  font-weight: bold; font-size: 1rem;
  padding: .6rem; border-radius: 8px;
}

/* ---------- Formularze ---------- */
.redeem-code-form { display: flex; gap: .5rem; }
.redeem-code-form input {
  flex-grow: 1;
  background-color: rgba(0,0,0,0.3);
  border: 1px solid var(--border-color);
  color: var(--text-light);
  padding: .7rem 1rem;
  border-radius: 8px;
}
.redeem-code-form input:focus {
  outline: none;
  border-color: var(--gold-2);
  box-shadow: 0 0 10px rgba(255,215,0,0.4);
}

/* ---------- Select „Filtruj według” ---------- */
#currencyFilter,
.history-panel select,
.form-select {
  appearance: none;
  background-color: rgba(0,0,0,0.35);
  color: var(--text-light);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: .4rem .75rem;
  font-weight: 600;
  line-height: 1.2;
}
#currencyFilter:focus,
.history-panel select:focus,
.form-select:focus {
  outline: none;
  border-color: var(--gold-2);
  box-shadow: 0 0 10px rgba(255,215,0,0.4);
}

/* ---------- Twoje przyciski ---------- */
.btn-action, .btn-management {
  width: 100%;
  padding: .8rem 1rem;
  border: 1px solid var(--gold-2);
  background: radial-gradient(circle, rgba(255,215,0,0.1), rgba(0,0,0,0.2));
  color: var(--gold-2);
  border-radius: 8px;
  font-weight: 600; font-size: 1rem;
  cursor: pointer; transition: all .3s ease;
}
.btn-action:hover, .btn-management:hover {
  background-color: var(--gold-2); color: #111;
  box-shadow: 0 0 15px rgba(255,215,0,0.4);
}

/* ---------- Responsywność ---------- */
@media (max-width: 992px) {
  .dashboard-grid { grid-template-columns: 1fr; }
  .dashboard-sidebar { position: static; }
}

/* =========================================================
   BOOTSTRAP 5 – GOLD OVERRIDE
   ========================================================= */

/* Linki */
a, a:hover, a:focus, .link-primary, .text-primary { color: var(--gold-2) !important; }

/* Wypełnione */
.btn-primary, .btn-info, .btn-success {
  --bs-btn-color: #111;
  --bs-btn-bg: var(--gold-2);
  --bs-btn-border-color: var(--gold-2);
  --bs-btn-hover-color: #111;
  --bs-btn-hover-bg: var(--gold-3);
  --bs-btn-hover-border-color: var(--gold-3);
  --bs-btn-focus-shadow-rgb: 255,215,0;
  --bs-btn-active-color: #111;
  --bs-btn-active-bg: var(--gold-2);
  --bs-btn-active-border-color: var(--gold-2);
  --bs-btn-disabled-bg: var(--gold-2);
  --bs-btn-disabled-border-color: var(--gold-2);
}

/* Outline (główny winowajca turkusu) */
.btn-outline-primary,
.btn-outline-info,
.btn-outline-success,
.btn-outline-secondary {
  --bs-btn-color: var(--gold-2);
  --bs-btn-border-color: var(--gold-2);
  --bs-btn-hover-color: #111;
  --bs-btn-hover-bg: var(--gold-2);
  --bs-btn-hover-border-color: var(--gold-2);
  --bs-btn-focus-shadow-rgb: 255,215,0;
  --bs-btn-active-color: #111;
  --bs-btn-active-bg: var(--gold-2);
  --bs-btn-active-border-color: var(--gold-2);
  --bs-btn-disabled-color: var(--gold-2);
  --bs-gradient: none;
}

/* Linkowe */
.btn-link {
  --bs-btn-color: var(--gold-2);
  --bs-btn-hover-color: var(--gold-3);
  color: var(--bs-btn-color) !important;
}

/* Tabs/nawigacje */
.nav-tabs .nav-link {
  --bs-nav-tabs-link-active-color: var(--gold-2);
  --bs-nav-tabs-link-active-border-color: var(--gold-2) var(--gold-2) transparent;
  color: var(--text-dark) !important;
}
.nav-tabs .nav-link.active,
.nav-pills .nav-link.active {
  color: var(--gold-2) !important;
  border-color: var(--gold-2) !important;
}

/* Utility */
.text-info, .text-success { color: var(--gold-2) !important; }
.border-info, .border-success, .border-primary { border-color: var(--border-color-soft) !important; }

/* =========================================================
   MEGA-SPECYFICZNY KILL SWITCH – outline w panelach
   ========================================================= */
.panel .btn.btn-outline-info,
.panel .btn.btn-outline-primary,
.panel .btn.btn-outline-success,
.dashboard-sidebar .panel .btn.btn-outline-info,
.dashboard-sidebar .panel .btn.btn-outline-primary,
.dashboard-sidebar .panel .btn.btn-outline-success,
.panel a.btn.btn-outline-info,
.panel a.btn.btn-outline-primary,
.panel a.btn.btn-outline-success {
  color: var(--gold-2) !important;
  border-color: var(--gold-2) !important;
  background: transparent !important;
  box-shadow: none !important;
}
.panel .btn.btn-outline-info:hover,
.panel .btn.btn-outline-primary:hover,
.panel .btn.btn-outline-success:hover,
.dashboard-sidebar .panel .btn.btn-outline-info:hover,
.dashboard-sidebar .panel .btn.btn-outline-primary:hover,
.dashboard-sidebar .panel .btn.btn-outline-success:hover,
.panel a.btn.btn-outline-info:hover,
.panel a.btn.btn-outline-primary:hover,
.panel a.btn.btn-outline-success:hover {
  color: #111 !important;
  background-color: var(--gold-2) !important;
  border-color: var(--gold-2) !important;
  box-shadow: 0 0 14px rgba(255,215,0,0.45) !important;
}
.panel .btn.btn-outline-info:focus,
.panel .btn.btn-outline-primary:focus,
.panel .btn.btn-outline-success:focus {
  outline: none !important;
  border-color: var(--gold-2) !important;
  box-shadow: 0 0 10px rgba(255,215,0,0.45) !important;
}




.history-panel .pagination,
.history-panel .pagination-wrapper,
.history-panel .pagination-row,
.history-panel .pager {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  flex-wrap: wrap;
  gap: .55rem;
  margin: 1.1rem 0 0 0 !important;
  padding: .5rem .75rem;
  background: rgba(0,0,0,0.25);
  border: 1px solid rgba(255,215,0,0.18);
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(255,215,0,0.10);
}

/* 2) Pojedyncze elementy (anchor/span) — wygląd „złotych kapsli” */
.history-panel .pagination a,
.history-panel .pagination span,
.history-panel .pagination-wrapper a,
.history-panel .pagination-wrapper span,
.history-panel .pagination-row a,
.history-panel .pagination-row span,
.history-panel .pager a,
.history-panel .pager span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 .7rem;
  border-radius: 10px;
  border: 1px solid rgba(255,215,0,0.22);
  background: rgba(0,0,0,0.35);
  color: var(--text-light);
  text-decoration: none;
  font-weight: 700;
  line-height: 1;
  transition: all .18s ease;
}

/* 3) Hover */
.history-panel .pagination a:hover,
.history-panel .pagination-wrapper a:hover,
.history-panel .pagination-row a:hover,
.history-panel .pager a:hover {
  background: var(--gold-2);
  border-color: var(--gold-2);
  color: #111;
  box-shadow: 0 0 12px rgba(255,215,0,0.35);
}

/* 4) Aktywna strona (różne warianty HTML) */
.history-panel .pagination .active,
.history-panel .pagination .active > a,
.history-panel .pagination .active > span,
.history-panel .pagination a.active,
.history-panel .pagination span.active,
.history-panel .pager .active,
.history-panel .pager a.active,
.history-panel .pager span.active {
  background: var(--gold-2) !important;
  border-color: var(--gold-2) !important;
  color: #111 !important;
  box-shadow: 0 0 14px rgba(255,215,0,0.45);
}

/* 5) Disabled/nieklikalne (np. « » na skrajach) */
.history-panel .pagination .disabled,
.history-panel .pagination .disabled > a,
.history-panel .pagination .disabled > span,
.history-panel .pagination a[aria-disabled="true"],
.history-panel .pager .disabled,
.history-panel .pager a[aria-disabled="true"],
.history-panel .pager span[aria-disabled="true"] {
  opacity: .45;
  cursor: not-allowed;
  background: rgba(0,0,0,0.2) !important;
  border-color: rgba(255,215,0,0.18) !important;
  color: var(--text-dark) !important;
  box-shadow: none !important;
  pointer-events: none;
}

/* 6) Etykieta „Strona X z Y” – traktuj jako status, nie przycisk */
.history-panel .pagination-status,
.history-panel .pager .status,
.history-panel .pagination span.status {
  padding: .25rem .65rem;
  border-radius: 999px;
  border: 1px solid rgba(255,215,0,0.22);
  background: rgba(0,0,0,0.25);
  color: var(--text-dark);
  font-weight: 700;
}

/* 7) Strzałki/ikonki wewnątrz — delikatnie mniejsze */
.history-panel .pagination i,
.history-panel .pager i,
.history-panel .pagination a .bi,
.history-panel .pager a .bi {
  font-size: .9rem;
}



/* =========================================================
   HISTORIA — FINALNA PAGINACJA ZŁOTY MOTYW
   ========================================================= */

.history-panel .pagination,
.history-panel .pagination-wrapper,
.history-panel .pagination-row,
.history-panel .pager {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 0.5rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

/* Ogólne przyciski i elementy */
.history-panel .pagination a,
.history-panel .pagination button,
.history-panel .pagination span,
.history-panel .pager a,
.history-panel .pager button,
.history-panel .pager span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 0.75rem;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.9rem;
  line-height: 1;
  border: 1px solid rgba(255, 215, 0, 0.25);
  background: rgba(0, 0, 0, 0.3);
  color: #d4af37;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
}

/* Hover efekt */
.history-panel .pagination a:hover,
.history-panel .pagination button:hover,
.history-panel .pager a:hover,
.history-panel .pager button:hover {
  background: #ffd700;
  border-color: #ffd700;
  color: #111;
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.35);
}

/* Aktywna strona */
.history-panel .pagination .active,
.history-panel .pagination .active > a,
.history-panel .pagination .active > span,
.history-panel .pager .active,
.history-panel .pager a.active,
.history-panel .pager span.active {
  background: #ffd700 !important;
  border-color: #ffd700 !important;
  color: #111 !important;
  box-shadow: 0 0 15px rgba(255, 215, 0, 0.45);
}

/* Nieaktywne/disabled */
.history-panel .pagination .disabled,
.history-panel .pagination .disabled > a,
.history-panel .pagination .disabled > span,
.history-panel .pager .disabled,
.history-panel .pager a[aria-disabled="true"],
.history-panel .pager span[aria-disabled="true"] {
  opacity: 0.4;
  cursor: not-allowed;
  background: rgba(0, 0, 0, 0.25);
  border-color: rgba(255, 215, 0, 0.2);
  color: #a79658;
  box-shadow: none;
}

/* Ikony strzałek — lekkie złote tło */
.history-panel .pagination a i,
.history-panel .pagination button i,
.history-panel .pager a i,
.history-panel .pager button i {
  font-size: 0.85rem;
  color: inherit;
}

/* Labelka "Strona X z Y" */
.history-panel .pagination-status,
.history-panel .pager .status,
.history-panel .pagination span.status {
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 215, 0, 0.25);
  border-radius: 8px;
  color: #ffd700;
  font-weight: 700;
  padding: 0.4rem 0.8rem;
  text-align: center;
}

/* Drobny efekt podświetlenia przy focusie */
.history-panel .pagination a:focus,
.history-panel .pagination button:focus,
.history-panel .pager a:focus,
.history-panel .pager button:focus {
  outline: none;
  border-color: #ffd700;
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.4);
}
/* ===========================================================
   DASHBOARD HEADER (Welcome, username)
   =========================================================== */
.dashboard-header {
    background: linear-gradient(135deg, rgba(20,20,30,0.85), rgba(40,40,55,0.6));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 1.8rem 2rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 0 25px rgba(0,0,0,0.4);
    position: relative;
    overflow: hidden;
}

.dashboard-header::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(600px 250px at 85% 15%, rgba(0,150,255,0.08), transparent 70%);
    pointer-events: none;
}

.dashboard-header h1 {
    font-size: 2.2rem;
    margin: 0;
    color: var(--text-light, #fff);
    font-weight: 800;
    letter-spacing: .5px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.45);
}

.dashboard-header .username {
    color: #ffd966;
}

.dashboard-header p {
    color: var(--text-dark, #ccc);
    font-size: 1rem;
    margin-top: .4rem;
    opacity: 0.85;
}

/* ===========================================================
   ACCOUNT STATUS (Points & Keys)
   =========================================================== */
.stats-grid {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 0.8rem;
}

.stat-item {
    flex: 1 1 220px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 1rem 1.2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: all 0.25s ease;
}

.stat-item:hover {
    background: rgba(255,255,255,0.08);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.stat-label {
    font-size: 0.9rem;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.3rem;
}

.stat-value {
    font-size: 1.4rem;
    font-weight: 700;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    white-space: nowrap;
}

.stat-value i {
    font-size: 1.1rem;
    filter: drop-shadow(0 0 6px rgba(255,215,0,0.3));
}

.stat-value .gold {
    color: #ffd700;

}

.stat-value .accent {
    color: #4db8ff;
}

/* ===========================================================
   DISCORD LINKED ACCOUNT
   =========================================================== */
.discord-linked-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: rgba(0,0,0,0.35);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 0.9rem 1.2rem;
    margin-top: 0.8rem;
    transition: background 0.25s ease;
}

.discord-linked-info:hover {
    background: rgba(0,0,0,0.5);
}

.discord-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: 2px solid rgba(114,137,218,0.6);
    box-shadow: 0 0 12px rgba(114,137,218,0.4);
    object-fit: cover;
    flex-shrink: 0;
}

.discord-linked-info span {
    color: #b8c2ff;
    font-size: 1rem;
    font-weight: 600;
    text-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

.discord-link-btn {
    display: inline-block;
    margin-top: 0.8rem;
    background: linear-gradient(90deg, #7289da, #5865f2);
    color: #fff;
    font-weight: 600;
    padding: 0.6rem 1.2rem;
    border-radius: 10px;
    transition: background 0.25s ease, transform 0.2s ease;
}

.discord-link-btn:hover {
    background: linear-gradient(90deg, #8899ff, #6678f8);
    transform: translateY(-2px);
}
/* ===========================================================
   RECHARGE FOOTER (Stripe info)
   =========================================================== */
.recharge-footer {
    margin-top: 1.2rem;
    padding: 0.9rem 1.2rem;
    background: linear-gradient(90deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
    border-top: 1px solid rgba(255,255,255,0.08);
    border-radius: 0 0 12px 12px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.recharge-footer::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, rgba(255,215,0,0.3), rgba(77,184,255,0.3));
    opacity: 0.4;
}

.recharge-footer p {
    margin: 0;
    font-size: 0.95rem;
    color: #ffd966;
    font-weight: 500;
    letter-spacing: 0.02em;
    text-shadow: 0 1px 2px rgba(0,0,0,0.6);
    transition: color 0.25s ease;
}