.wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.bodyContainer {
  flex: 1;
  display: flex;
}
/* ------------------header----------------------------- */

button {
  background-color: #1f1f1f; /* Green background */
  color: white; /* White text */
  padding: 6px 10px; /* Instead of 3px 3px */
  border: none; /* No border */
  border-radius: 5px; /* Rounded corners */
  font-family: "Inter";
  cursor: pointer; /* Change cursor on hover */
  transition: background-color 0.3s ease; /* Smooth hover effect */
}

button:hover {
  background-color: #fcd34d; /* Darker green on hover */
  color: black;
}

/* Balance button — matches the 404 page's bordered-pill treatment,
   set apart from the plain nav-tab look via #toggleBtn's higher
   specificity overriding the generic button rule above. */
#toggleBtn {
  background: #292929;
  color: #f5f5f5;
  border: 1px solid #444;
  border-radius: 6px;
  padding: 6px 12px;
  cursor: pointer;
  font-size: 13px;
}

/* Matches #toggleBtn's button look — see dashboard_login/index.css's
   identical rule for the full reasoning. */
#depositNavItem a {
  background: #292929;
  color: #f5f5f5;
  border: 1px solid #444;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 13px;
}

a.active-tab {
  border-top: 3px solid #fcd34d; /* bright yellow line above */
  padding-top: 7px; /* add some space so text doesn't feel cramped */
  color: #fcd34d; /* optional: match color with the border */
  font-weight: bold; /* optional: emphasize active tab */
}

a:not(.active-tab):hover {
  border-top: 3px solid #444; /* subtle line */
  padding-top: 7px;
}

/* ------------------blurred----------------------------- */

.balance {
  font-size: 15px;
  font-weight: bold;
  letter-spacing: 4px;
  color: #fcd34d;
}
.blurred {
  color: transparent;
  text-shadow: 0 0 100px rgba(0, 0, 0, 0.5);
}

/* WHAT: The class balanceManager.js adds to the balance + Balance-button
   <li>s when the server says this session isn't valid anymore.
   WHY it had to be added here: this rule already existed in
   dashboard_login/index.css, leaderboard/index.css and notFound/index.css
   — but NOT in this file. balanceManager.js was correctly detecting the
   dead session and correctly calling classList.add("nav-auth-gated"), and
   then nothing happened, because on this page there was no rule for that
   class to trigger. Result: log out in another tab and this page kept
   showing a stale balance next to a Hide Balance button that no longer
   had anything behind it. The JS was right the whole time; the CSS hook
   was simply missing.
   WHY !important, same as the other three files: this is a "nothing else
   gets a say" utility class — it should win regardless of what specificity
   gets added to the header rules above it later.
   NOTE: unlike dashboard_login/leaderboard, the <li>s on this page do NOT
   carry this class in the markup by default. That's deliberate — this page
   is login-gated, so the balance SHOULD be visible normally; this class
   only ever gets applied at runtime once a session goes bad. */
.nav-auth-gated {
  display: none !important;
}

/* The mirror image of .nav-auth-gated — for a guests-only element such as
   a Login link. Nothing on this page uses it today (there's no Login item
   in this header), but the two are a matched pair everywhere else in the
   codebase and navVisibility.js expects both to exist wherever it runs —
   defining it here keeps that contract intact if this page's header ever
   grows one. */
.guest-only {
  display: none !important;
}

/* ------------------header----------------------------- */

* {
  margin: 0;
  padding: 0;
  font-size: 15px;
  box-sizing: border-box;
}

h1 {
  font-size: 20px;
}

body {
  margin: 0;
  font-family: "Inter", sans-serif;
  background-color: #121212;
  color: #f5f5f5;
}

/*  */
.header {
  display: flex;
  align-items: center;
}

.headerContainer {
  background-color: #1f1f1f;
  font-family: "Inter";
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 20px;
}

.headerContainer1 {
  font-family: "Inter";
  font-size: 35px;
  font-weight: 900;
  flex-grow: 1;
  margin: 10px 10px 10px 10px;
}

.headerContainer2 {
  display: flex;
  align-items: center;
}

.headerContainer2 ul {
  display: flex;
  align-items: center;
  gap: 20px;
}

.headerContainer2 li {
  justify-content: space-evenly;
  display: flex;
  list-style-type: none;
  margin: 0;
}

a {
  text-decoration: none;
  color: white;
}

/* ------------------body----------------------------- */
.bodyContainer {
  flex: 1; /* this pushes the footer to the bottom */
}

html,
body {
  height: 100%;
  flex-direction: column;
}

/* WHY scrollbar-gutter: stable + overflow-y: auto: see
   dashboard_login/index.css's identical rule — same reasoning, keeps the
   right-aligned nav from shifting sideways between this page and others
   when only one of them scrolls (the overflow-y is required for the
   gutter property to do anything at all — see that file's comment). */
html {
  scrollbar-gutter: stable;
  overflow-y: auto;
}

/* ------------------footer----------------------------- */

footer {
  color: #888;
  background-color: #1f1f1f;
  font-weight: normal;
  font-size: 12px; /* change this one number to resize everything */
  text-align: center;
  padding: 30px 40px;
}

footer * {
  font-size: inherit; /* forces the year span to match */
}

/*--------------------------- Progress Bar ---------------------*/
#progressBar {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 5px;
  background: linear-gradient(to right, #ffd700, #ff5a5f);
  z-index: 9999;
  transition: width 0.2s ease-out;
}
/*------------ Sidebar styling ------------*/
.sidebar {
  width: 200px;
  background: #292929;
  color: white;
  padding: 20px;
  display: flex;
  flex-direction: column;
  min-height: 400px; /* Minimum height instead of fixed height */
}

.sidebar-section {
  margin-bottom: 30px;
  display: none; /* Hide all sections by default */
}

.sidebar h2 {
  margin-top: 0;
  font-size: 1.3rem;
  color: #fcd34d;
  text-align: center;
  flex-shrink: 0; /* Don't let title shrink */
}

.sidebar-nav {
  list-style: none;
  padding: 0;
  flex: 1; /* This takes up available space and pushes logout to bottom */
}

.sidebar-nav li {
  padding: 10px;
  cursor: pointer;
  border-radius: 4px;
  margin-bottom: 5px;
  display: flex; /* Add this */
  align-items: center; /* Add this */
  text-align: center; /* Keep this */
  min-height: 40px; /* Add this for consistent height */
}

.sidebar-nav li:hover {
  background: #555;
}

.sidebar-nav li.active {
  background: #fcd34d;
  color: black;
}

/* New styles for the bottom section */
.sidebar-bottom {
  flex-shrink: 0; /* Don't let this shrink */
  margin-top: auto; /* This pushes it to the bottom */
  padding-top: 20px;
  border-top: 1px solid #444;
}

.logout-btn {
  width: 100%;
  padding: 12px 16px;
  background: #dc2626; /* Red background for logout */
  color: white;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
}

.logout-btn:hover {
  background: #991b1b; /* Darker red on hover */
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.3);
}

.sidebar ul {
  list-style: none;
  padding: 0;
}

.sidebar li:hover {
  background: #555;
}

.sidebar li.active {
  background: #fcd34d;
  color: black;
}

section,
h1,
h2,
h3,
h4,
p {
  margin-bottom: 10px;
}

/* ------------------content----------------------------- */
/* ---- Content container ---- */
.content {
  flex: 1; /* take remaining space */
  display: flex; /* so we can center the card */
  justify-content: center; /* center horizontally */
  align-items: flex-start; /* align to the top */
  padding: 40px 20px; /* breathing room */
  box-sizing: border-box;
  background: #0e0e0e; /* or rgb(14, 14, 14); */
}

.sidebar-section h3 {
  color: white;
  padding-bottom: 10px;
  position: relative;
}

.sidebar-section h3::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  height: 1px; /* thickness of the "border" */
  width: 100%;
  background: linear-gradient(to right, #ffd700, #ff5a5f);
}
.events h4 {
  margin: 0 0 5px 0;
  color: #fcd34d;
}

.events p {
  margin: 0;
  color: #ffffff;
}

.events {
  background-color: #1f1f1f;
  padding: 15px;
  border-radius: 8px;
  margin-bottom: 20px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s ease;
}
.events:hover {
  transform: scale(1.01);
}

.events p {
  display: none;
}
.faq-answer {
  display: none;
}

/* ----account info tab----- */
.account-card {
  background: #1e1e1e;
  border-radius: 12px;
  padding: 30px;
  width: 100%; /* take full available space */
  max-width: 900px; /* limit so it doesn't get too wide on big screens */
  margin: 40px auto; /* center horizontally with more breathing space */
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.account-card h2 {
  margin-bottom: 1rem;
  font-size: 1.4rem;
  color: #fcd34d;
}

.account-field {
  margin-bottom: 20px;
  display: flex;
  justify-content: flex-start; /* align left */
  gap: 30px; /* space between label & value */
}

.account-field label {
  flex: 0 0 200px; /* fixed width for labels */
  font-weight: 600;
  color: #ffffff;
}

.account-field span {
  flex: 1; /* take the rest of the space */
  text-align: left;
}

.account-actions {
  text-align: right;
  margin-top: 30px;
}

#fileTicketBtn {
  display: inline-block;
  text-decoration: none;
  padding: 8px 14px;
  border: none;
  border-radius: 8px;
  background: #fcd34d;
  color: #000;
  font-weight: 600;
  cursor: pointer;
}

/* ---------NICKNAME EDIT---------- */
#editNicknameBtn {
  padding: 4px 10px;
  font-size: 0.8rem;
  border: none;
  border-radius: 6px;
  background: #fcd34d;
  color: #000;
  cursor: pointer;
}

#nicknameInput {
  padding: 4px 6px;
  border-radius: 4px;
  border: 1px solid #555;
  background: #1e1e1e;
  color: white;
}

/* WHAT: generic hide utility for this page.
   WHY !important: same reasoning as .nav-auth-gated elsewhere in the
   codebase — a "this element is not currently applicable" class should win
   regardless of whatever specificity gets added to the rules above it
   later. This one matters: it's what keeps the Edit button hidden for
   users who have already spent their one change. */
.hidden {
  display: none !important;
}

#nicknameEditRow {
  margin-top: 8px;
}

.nickname-edit-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

#saveNicknameBtn,
#cancelNicknameBtn {
  padding: 4px 10px;
  font-size: 0.8rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

#saveNicknameBtn {
  background: #fcd34d;
  color: #000;
  font-weight: 600;
}

#cancelNicknameBtn {
  background: #333;
  color: #ddd;
}

#saveNicknameBtn:disabled,
#cancelNicknameBtn:disabled,
#editNicknameBtn:disabled {
  opacity: 0.6;
  cursor: default;
}

/* Hidden until there's something to say — see account.js. */
#nicknameError {
  display: none;
  color: #ff6b6b;
  font-size: 0.8rem;
  margin-top: 6px;
}

/* The permanence warning inside the confirmation modal. Deliberately
   styled to stand out from the surrounding text — it's the one line that
   has to actually get read. */
.nickname-warning {
  color: #fcd34d;
  font-size: 0.85rem;
  line-height: 1.45;
  margin-top: 10px;
}

/* ---------------info icon toggle---------- */

.nickname-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
}

.info-icon {
  cursor: pointer;
  font-size: 1.2rem;
}

.label-with-icon {
  display: flex;
  align-items: center;
  gap: 6px;
  position: relative; /* <-- this is the anchor! */
}

.info-text {
  display: none;
  position: absolute;
  top: 120%; /* place just below the label */
  left: 0;
  background: #353535;
  color: #fff;
  padding: 6px 10px;
  font-size: 13px;
  border-radius: 6px;
  width: 220px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  z-index: 10; /* keeps it above other stuff */
}

.info-icon:hover + .info-text {
  display: block;
}

.nickname-note {
  display: block;
  font-size: 0.8rem; /* smaller than normal */
  color: #666; /* subtle gray */
  margin-top: 2px;
}
/* -------- Transactions Table -------- */

.txn-table {
  width: 100%;
  max-width: 1200px;
  border-collapse: collapse;
  margin: 20px auto;
  font-family: "Inter", sans-serif;
  background: #1a1a1a;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
  border: 1px solid #333;
  /* WHAT: fixed layout + explicit per-column widths below.
     WHY: without this, column width is driven purely by content — long
     unbounded strings (full UUID references, "Sent on-chain — tx 0x…"
     notes) blow their columns out wide and squeeze everything else
     (Date & Time was wrapping across 3 lines because of this). Fixed
     layout + ellipsis truncation on the long-text columns keeps every
     row the same height and every column a predictable width. */
  table-layout: fixed;
}

/* Column order: Date & Time | Type | Note | Reference | Amount | Balance | Status */
.txn-table th:nth-child(1),
.txn-table td:nth-child(1) {
  width: 13%;
}
.txn-table th:nth-child(2),
.txn-table td:nth-child(2) {
  width: 13%;
}
.txn-table th:nth-child(3),
.txn-table td:nth-child(3) {
  width: 22%;
}
.txn-table th:nth-child(4),
.txn-table td:nth-child(4) {
  width: 18%;
}
.txn-table th:nth-child(5),
.txn-table td:nth-child(5) {
  width: 12%;
}
.txn-table th:nth-child(6),
.txn-table td:nth-child(6) {
  width: 11%;
}
.txn-table th:nth-child(7),
.txn-table td:nth-child(7) {
  width: 11%;
}

/* WHAT: let the two unbounded-length columns (Note, Reference) wrap onto
   extra lines within their fixed-width column instead of being cut off.
   WHY: matches the admin dashboard's identical fix for the same problem
   (long unbroken tx hashes/notes in a table-layout:fixed table) — see
   admin_dashboard/index.css's .bet-details-table td and
   .withdrawal-detail-row .value.mono. Without word-wrap/overflow-wrap,
   a long unbroken string (a full UUID, a tx hash) has no spaces to break
   on and will just overflow its column rather than wrap. */
.txn-table td:nth-child(3),
.txn-table td:nth-child(4) {
  white-space: normal;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.txn-table th {
  background: linear-gradient(135deg, #2a2a2a 0%, #1f1f1f 100%);
  color: #fcd34d;
  font-weight: 700;
  font-size: 14px;
  padding: 16px 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 2px solid #fcd34d;
  text-align: center;
}

.txn-table td {
  padding: 14px 12px;
  text-align: center;
  color: #e0e0e0;
  font-weight: 500;
  border-bottom: 1px solid #2a2a2a;
  transition: all 0.3s ease;
}

.txn-table tbody tr {
  transition: all 0.3s ease;
}

.txn-table tbody tr:hover {
  background: rgba(252, 211, 77, 0.1);
  transform: translateY(-2px);
}

.txn-table tbody tr:hover td {
  color: #ffffff;
}

/* Striped rows for better readability */
.txn-table tbody tr:nth-child(even),
.summary-table tbody tr:nth-child(even) {
  background: rgba(40, 40, 40, 0.3);
}

.txn-table tbody tr:nth-child(odd),
.summary-table tbody tr:nth-child(odd) {
  background: rgba(30, 30, 30, 0.3);
}

/* ----- Amount Colors ----- */

.txn-table td.credit {
  color: #10b981;
  font-weight: 600;
}

.txn-table td.debit {
  color: #ef4444;
  font-weight: 600;
}

.txn-table td.neutral {
  color: #6b7280;
  font-weight: 600;
}

/* ------- Transactions Summary Table -------- */

.summary-table {
  width: 100%;
  max-width: 1200px;
  border-collapse: collapse;
  margin: 20px auto;
  font-family: "Inter", sans-serif;
  background: #1a1a1a;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
  border: 1px solid #333;
}

.summary-table th {
  background: linear-gradient(135deg, #2a2a2a 0%, #1f1f1f 100%);
  color: #fcd34d;
  font-weight: 700;
  font-size: 14px;
  padding: 16px 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 2px solid #fcd34d;
  text-align: center;
}

.summary-table td {
  padding: 20px 12px;
  text-align: center;
  color: #e0e0e0;
  font-weight: 600;
  font-size: 16px;
  border-bottom: 1px solid #2a2a2a;
  transition: all 0.3s ease;
}

.summary-table tbody tr {
  transition: all 0.3s ease;
}

.summary-table tbody tr:hover {
  background: rgba(252, 211, 77, 0.1);
  transform: translateY(-2px);
}

.summary-table tbody tr:hover td {
  color: #ffffff;
}

/* ----------------download transaction history css-------------- */

.download-btn {
  margin: 10px 0 20px 0;
  padding: 12px 24px;
  background: linear-gradient(135deg, #2a2a2a 0%, #333 100%);
  border: 1px solid #444;
  color: #fcd34d;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  font-family: "Inter", sans-serif;
}

.download-btn:hover {
  background: linear-gradient(135deg, #fcd34d 0%, #e5b800 100%);
  color: #000;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(252, 211, 77, 0.3);
  border-color: #fcd34d;
}

/* ----- Mobile Responsive ----- */
/* WHY the extra (max-height: 500px) and (orientation: landscape) clause
   on both mobile media queries in this file, not just max-width alone: a
   phone that's comfortably under 768px wide in portrait is typically
   740-915px wide in LANDSCAPE — over the threshold, so these blocks used
   to get skipped entirely on a real phone turned sideways, silently
   falling back to the desktop layout. Confirmed via My Bets
   (activeBets), where that exact fallback caused a real overflow bug —
   applied here proactively since the same gap exists on this page too,
   even though it hasn't visibly broken here (yet). Landscape phones are
   short, though, even when they're "wide" by this query's own standard —
   matching on a short height in landscape catches them anyway, on top of
   the original portrait width check. */
@media (max-width: 768px), (max-height: 500px) and (orientation: landscape) {
  .summary-table th,
  .summary-table td,
  .txn-table th,
  .txn-table td {
    padding: 10px 6px;
    font-size: 12px;
  }

  .summary-table td {
    font-size: 14px;
    padding: 15px 6px;
  }

  .status {
    padding: 4px 8px;
    font-size: 0.75rem;
    min-width: 70px;
  }

  #transactions h2 {
    font-size: 1.3rem;
    margin: 20px 0 15px;
  }
}

/* ----------------------------Pagination styling ----------------------*/
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.pagination button {
  padding: 8px 12px;
  background: #2a2a2a;
  color: white;
  border: 1px solid #444;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.pagination button:hover:not(:disabled) {
  background: #fcd34d;
  color: black;
}

.pagination button:disabled {
  background: #1a1a1a;
  color: #666;
  cursor: not-allowed;
}

.pagination button.active-page {
  background: #fcd34d;
  color: black;
  font-weight: 600;
}

/* ===== Transaction headings ===== */

#transactions h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #fcd34d;
  margin: 30px 0 20px;
  letter-spacing: 0.5px;
  text-align: left;
  position: relative;
}

/* ==== Transaction Status badges ==== */

.txn-table td.status-cell {
  text-align: center;
}

.status {
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 20px;
  display: inline-block;
  font-size: 0.85rem;
  text-align: center;
  min-width: 90px;
}

.status.completed {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid #10b981;
}

.status.pending {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border: 1px solid #f59e0b;
}

.status.rejected {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid #ef4444;
}

/* ===== SAFETY SECTION ===== */

/* top "Safety" heading */
#safety h2 {
  color: #fcd34d; /* gold */
  text-align: center;
  margin-bottom: 30px;
  font-size: 28px;
}

/* section titles inside the blocks */
.safety-block h3 {
  color: #ffffff; /* green */
  margin-bottom: 10px;
  font-size: 20px;
}

#safety {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
  font-family: Arial, sans-serif;
}

.safety-block {
  background-color: #1e1e1e;
  padding: 20px;
  margin-bottom: 20px;
  border-radius: 12px;
  color: #f1f1f1;
}

.safety-block h3 {
  margin-bottom: 10px;
  font-size: 20px;
}

/* ===== FORMS ===== */
.safety-block form input {
  display: block;
  width: 100%;
  padding: 10px;
  margin: 8px 0;
  border-radius: 6px;
  border: 1px solid #555;
  background-color: #2a2a2a;
  color: #fff;
}

.safety-block form button {
  padding: 10px 15px;
  margin-bottom: 10px;
  background-color: #fcd34d;
  border: none;
  border-radius: 6px;
  color: #000000;
  cursor: pointer;
  margin-top: 10px;
}

.safety-block form button:hover {
  background-color: #fcd34d;
}

/* Add spacing below the Edit button */
#editPwBtn {
  margin-bottom: 5px; /* or 16px if you want it roomier */
}

/* ===== SELECT + BUTTON ===== */
.safety-block select,
.safety-block button {
  padding: 10px;
  border-radius: 6px;
  border: 1px solid #555;
  background-color: #2a2a2a;
  color: #fff;
  cursor: pointer;
}

.safety-block select:focus,
.safety-block button:focus {
  outline: none;
  border-color: #fcd34d;
}

/* ===== ACTIVE STATUS ===== */
#activeCoolOff {
  margin-top: 10px;
  font-weight: bold;
}

/* ===== MODAL ===== */

.error-msg {
  color: #ff6b6b;
  font-size: 0.9rem;
  margin-top: 5px;
}

.cooloff-note {
  display: block; /* so it stays on its own line */
  margin-top: 8px;
  font-size: 0.85rem;
  color: #ffcc66; /* soft yellow so it stands out */
  line-height: 1.4;
}

.cooloff-info {
  background: #1e293b; /* dark slate */
  color: #f1f5f9; /* light text */
  padding: 12px 16px;
  border-left: 4px solid #fcd34d; /* yellow accent */
  border-radius: 6px;
  font-size: 0.95rem;
  line-height: 1.5;
  margin-bottom: 1rem;
}

.cooloff-msg {
  margin-top: 10px;
  margin-bottom: 10px;
  font-size: 0.85rem;
  color: #ff6666; /* red so user sees the warning */
  display: none;
}

.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-content {
  border: 1px solid #fcd34d;
  background-color: #1e1e1e;
  padding: 30px;
  border-radius: 12px;
  width: 400px;
  text-align: center;
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center; /* center children horizontally */
  justify-content: center; /* center children vertically inside the box */
}

.modal-content input {
  width: 80%;
  padding: 10px;
  margin: 15px auto;
  display: block;
  border-radius: 6px;
  border: 1px solid #555;
  background-color: #2a2a2a;
  color: #fff;
}

.modal-buttons button {
  padding: 10px 15px;
  border: none;
  border-radius: 6px;
  margin: 5px;
  cursor: pointer;
}

#confirmCoolOff {
  background-color: #fcd34d;
  color: #000000;
}

#confirmCoolOff:hover {
  background-color: #da190b;
  color: #ffffff;
}

#cancelCoolOff {
  background-color: #fcd34d;
  color: #000000;
}

#cancelCoolOff:hover {
  background-color: #da190b;
  color: #ffffff;
}

#closePwSuccess {
  margin-top: 15px;
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  background-color: #fcd34d;
  color: #000;
  cursor: pointer;
}

#closePwSuccess:hover {
  background-color: #fbbf24;
}

/* #closeTwoFactorModal's styles lived here. Removed along with the modal
   itself — it existed to dismiss a popup announcing that a checkbox had
   been flipped, which is no longer how 2FA is turned on or off. */

/* ===== TOGGLE SWITCH (already explained in HTML) ===== */

.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 28px;
  margin-right: 10px;
}
.switch input {
  display: none;
}
.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #8d8d8d;
  transition: 0.4s;
  border-radius: 28px;
}
.slider:before {
  position: absolute;
  content: "";
  height: 22px;
  width: 22px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
}
input:checked + .slider {
  background-color: #fcd34d;
}
input:checked + .slider:before {
  transform: translateX(22px);
}

/* ===== Logout Modal Buttons ===== */
#logoutModal .modal-buttons {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.2rem;
}

#logoutModal .modal-buttons button {
  min-width: 90px;
  padding: 0.55rem 1.2rem;
  border: none;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    background 0.25s ease,
    transform 0.1s ease;
}

/* Yes button */
#confirmLogout {
  background: #ef4444; /* red */
  color: #fff;
}

#confirmLogout:hover {
  background: #dc2626;
  transform: scale(1.05);
}

/* No button */
#cancelLogout {
  background: #fcd34d; /* light gray */
  color: #374151;
}

#cancelLogout:hover {
  background: #fbbf24;
  transform: scale(1.05);
}

/* ===== NOTIFICATION CONTAINER ===== */

.notif-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 10px; /* Space between notifications */
}

/* ===== INDIVIDUAL NOTIFICATION STYLES ===== */
.custom-notif {
  background: #5cb85c; /* Default green */
  color: white;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transform: translateX(100%);
  opacity: 0;
  transition: all 0.3s ease;
  max-width: 500px;
  word-wrap: break-word;
}

.custom-notif.success {
  background: #5cb85c; /* green color */
}

.custom-notif.warning {
  background: #d9534f; /* red color */
}

.custom-notif.show {
  transform: translateX(0);
  opacity: 1;
}

/* Optional: Add slide-out animation when removing */
.custom-notif:not(.show) {
  transform: translateX(100%);
  opacity: 0;
}

/* ===== TRANSACTION ACTION BUTTONS ===== */
.transaction-actions {
  background: #1e1e1e;
  padding: 20px;
  border-radius: 12px;
  margin-bottom: 25px;
  border-left: 4px solid #fcd34d;
}

.transaction-actions h2 {
  color: #fcd34d;
  margin-bottom: 15px;
  font-size: 1.3rem;
}

.action-buttons {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.action-btn {
  flex: 1;
  min-width: 120px;
  padding: 12px 20px;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
  text-align: center;
}

.deposit-btn {
  background: #10b981;
  color: white;
}

.deposit-btn:hover {
  background: #059669;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.withdraw-btn {
  background: #ef4444;
  color: white;
}

.withdraw-btn:hover {
  background: #dc2626;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

/* Gold-themed cancel button */
.cancel-btn {
  background: #fcd34d;
  color: #000000;
  border: none;
}

.cancel-btn:hover {
  background: #fbbf24;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(252, 211, 77, 0.3);
}

/* Modal styles for deposit/withdrawal forms */
.action-modal .modal-content {
  max-width: 400px;
}

/* ─── Deposit modal (QR code + address) ──────────────────────────────── */

.deposit-network-notice {
  font-size: 0.85rem;
  color: #ccc;
  line-height: 1.4;
  margin: 4px 0 16px;
  text-align: left;
}

.deposit-network-notice strong {
  color: #fcd34d;
}

.deposit-modal-body {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.deposit-loading,
.deposit-error {
  color: #ccc;
  font-size: 0.9rem;
}

/* ===== VERIFICATION (KYC) TAB =====
   Own classes rather than reusing .safety-block — same card shape on
   purpose (this sits right next to Safety in the sidebar and should feel
   like a sibling), but kept independent so a change to one tab can't
   silently restyle the other. See profile/kyc.js. */
#verification {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
}

.verification-block {
  background-color: #1e1e1e;
  padding: 20px;
  margin-bottom: 20px;
  border-radius: 12px;
  color: #f1f1f1;
}

.verification-block h4 {
  margin: 0 0 10px;
  font-size: 17px;
}

/* Left accent colour is the whole status signal at a glance: green when
   you're done, amber while you wait, red when something needs fixing. */
.verification-approved {
  border-left: 3px solid #10b981;
}

.verification-pending {
  border-left: 3px solid #fcd34d;
}

.verification-rejected {
  border-left: 3px solid #ef4444;
}

.verification-reason {
  background-color: #2a2a2a;
  border-radius: 6px;
  padding: 10px 12px;
  margin: 10px 0;
  color: #ffb4b4;
  white-space: pre-wrap;
}

.verification-intro {
  color: #bbb;
  font-size: 0.92rem;
  line-height: 1.5;
}

.verification-instructions-img {
  display: block;
  width: 100%;
  max-width: 560px;
  height: auto;
  margin: 14px 0 20px;
  border-radius: 8px;
}

/* ─── Two-Factor Authentication (Profile > Safety) ───────────────────
   Everything under #twoFactorBody is rendered by safety.js — see
   renderTwoFactorSection() there for the states these style. */

.twofa-loading {
  color: #888;
  font-size: 14px;
}

.twofa-intro {
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.6;
  margin: 10px 0;
}

.twofa-status-on {
  border-left: 3px solid #10b981;
  padding-left: 12px;
  margin-bottom: 14px;
}

/* The QR gets a white plate on purpose: scanners read dark-on-light, and
   a transparent canvas over this dark page inverts that contrast. */
.twofa-qr {
  display: block;
  background: #ffffff;
  padding: 10px;
  border-radius: 8px;
  margin: 12px 0;
}

.twofa-secret {
  display: inline-block;
  margin-top: 6px;
  padding: 8px 12px;
  background: #0f172a;
  border: 1px solid #334155;
  border-radius: 6px;
  color: #fcd34d;
  font-family: monospace;
  font-size: 15px;
  letter-spacing: 2px;
  word-break: break-all;
}

.twofa-code-input {
  display: block;
  width: 100%;
  max-width: 220px;
  box-sizing: border-box;
  padding: 10px 12px;
  margin: 10px 0;
  background: #0f172a;
  border: 1px solid #475569;
  border-radius: 6px;
  color: #f1f5f9;
  font-family: monospace;
  font-size: 18px;
  letter-spacing: 4px;
  text-align: center;
}

.twofa-code-input:focus {
  outline: none;
  border-color: #fcd34d;
}

.twofa-hint {
  color: #888;
  font-size: 13px;
  margin: 4px 0 8px;
}

/* Reads as a link, but is a real <button> so it's keyboard-reachable and
   never gets treated as a form submit. Sits inline inside the hint line
   under the withdrawal modal's authenticator field — see
   setupCodeModeToggle() in transactionActions.js for what it does. */
.twofa-mode-toggle {
  display: inline;
  width: auto;
  padding: 0;
  background: none;
  border: none;
  color: #fcd34d;
  font-size: inherit;
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
}

/* Backup-code mode on the withdrawal field: nine characters instead of
   six, so the wide tracking meant for a 6-digit code is eased off to stop
   it overflowing on a phone. Uppercase is display-only — the server
   normalises casing before comparing anything. */
#withdrawTwoFactorCode.is-backup-code {
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* Same easing-off for the Safety page's disable / regenerate prompt: nine
   characters against the six the 4px tracking was picked for. Uppercase is
   display-only — the server normalises casing before it compares. */
.twofa-code-input.is-backup-code {
  letter-spacing: 2px;
  text-transform: uppercase;
}

.twofa-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.twofa-cancel-btn {
  padding: 10px 18px;
  border: 1px solid #475569;
  border-radius: 6px;
  background: transparent;
  color: #94a3b8;
  font-size: 14px;
  cursor: pointer;
}

.twofa-cancel-btn:hover {
  color: #cbd5e1;
  border-color: #64748b;
}

.twofa-danger-btn {
  padding: 10px 18px;
  border: none;
  border-radius: 6px;
  background: #ef4444;
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.twofa-danger-btn:hover {
  background: #dc2626;
}

.twofa-backup-count {
  color: #cbd5e1;
  font-size: 14px;
  margin: 12px 0;
}

/* Same amber as the "running low" backup-code nudge — this is the same
   category of message (a real consequence to be aware of), not an error
   and not decoration. Left border rather than a filled background keeps
   it readable without making setup feel like it's going wrong. */
.twofa-warning {
  border-left: 3px solid #fbbf24;
  background: rgba(251, 191, 36, 0.08);
  padding: 12px 14px;
  margin: 16px 0;
  border-radius: 0 6px 6px 0;
}

.twofa-warning p {
  color: #e2c88a;
  font-size: 13px;
  line-height: 1.5;
  margin: 0;
}

.twofa-warning p + p {
  margin-top: 8px;
}

/* The second, shorter reminder right before "Turn on" — deliberately
   quieter than the full warning above it, since this is a repeat for
   someone who may have skipped straight here, not the primary notice. */
.twofa-warning-compact {
  margin-top: 14px;
  padding: 10px 12px;
  font-size: 12px;
}

/* Amber, not red: running low is a "sort this out soon" nudge, not an
   error — nothing is broken yet. */
.twofa-backup-count.twofa-low {
  color: #fbbf24;
}

/* ─── Monthly deposit limit ───────────────────────────────────────────
   Deliberately reuses the existing .deposit-btn / .twofa-danger-btn /
   .deposit-error styles rather than inventing a parallel set — this is
   the same kind of control as the blocks above it and should look like
   a sibling, not a bolt-on. Only the pieces with no existing equivalent
   are defined here. */

.deposit-limit-usage {
  margin-bottom: 14px;
}

.deposit-limit-usage p {
  color: #cbd5e1;
  font-size: 14px;
  margin: 0 0 6px 0;
}

.deposit-limit-usage strong {
  color: #f5f5f5;
}

/* Quieter than the figures above it — this is reference information
   ("when does this refill"), not something to act on. */
.deposit-limit-reset {
  color: #94a3b8 !important;
  font-size: 12px !important;
}

/* Same amber treatment as .twofa-warning: a real consequence to be aware
   of, not an error. Used for both the "waiting on your 24 hours" and
   "your change is unlocked" notices, since both are states the user needs
   to notice before touching the dropdown below them. */
.deposit-limit-notice {
  border-left: 3px solid #fbbf24;
  background: rgba(251, 191, 36, 0.08);
  padding: 12px 14px;
  margin: 0 0 16px 0;
  border-radius: 0 6px 6px 0;
}

.deposit-limit-notice p {
  color: #e2c88a;
  font-size: 13px;
  line-height: 1.5;
  margin: 0;
}

.deposit-limit-notice p + p {
  margin-top: 8px;
}

/* Green rather than amber once the wait is served: amber says "you're
   waiting on something", and at this point they aren't. */
.deposit-limit-unlocked {
  border-left-color: #4ade80;
  background: rgba(74, 222, 128, 0.08);
}

.deposit-limit-unlocked p {
  color: #a7e8bd;
}

/* WHY flex-wrap: the third button ("Never mind") only exists while a
   change request is outstanding, so this row is two items wide most of
   the time and three occasionally — and on a narrow phone all three need
   to be able to drop onto their own lines rather than squeezing. */
.deposit-limit-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

/* WHY "Never mind" is pushed away from Save rather than just sitting next
   to it: those two buttons do opposite things, and the expensive mistake on
   this card is reaching for Save — after waiting a full 24 hours to apply a
   change — and catching the cancel button instead, which throws the whole
   wait away. A confirmation modal catches that (see
   confirmCancelDepositLimitChange in safety.js), but not making the two
   adjacent in the first place is the cheaper half of the fix.
   WHY margin-left rather than a gap change: this only separates THIS pair,
   leaving the dropdown and Save sitting together as one unit, which is how
   they read — pick a value, save it. */
#depositLimitCancelBtn {
  margin-left: 18px;
}

/* On a narrow phone the row wraps and margin-left would just indent the
   cancel button oddly on its own line, so it becomes vertical breathing
   room instead. */
@media (max-width: 480px) {
  #depositLimitCancelBtn {
    margin-left: 0;
    margin-top: 6px;
  }
}

.deposit-limit-controls select {
  padding: 8px 10px;
  border-radius: 6px;
  background-color: #2a2a2a;
  color: #fff;
  border: 1px solid #444;
  font-size: 14px;
}

/* The line under the controls that explains what the button will do.
   Quiet on purpose — it's a running commentary on the current selection,
   not a warning. */
.deposit-limit-hint {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.5;
  margin: 0 0 4px 0;
  min-height: 18px;
}

.deposit-limit-confirm-note {
  color: #94a3b8;
  font-size: 13px;
  line-height: 1.5;
  margin-top: 10px;
}

/* WHY the buttons in this card's confirmations don't wrap: their labels
   are short deliberate phrases ("Yes, discard it", "Start the 24 hours")
   where the whole phrase is the meaning. Breaking one across two lines
   splits the verb from its object and makes a decision button look like a
   paragraph. Scoped to these two ids rather than .modal-buttons generally,
   so nothing else on the page changes.
   WHY nowrap is safe here: the longest label is "Start the 24 hours" at a
   13px-ish button size — it fits the modal comfortably even on a narrow
   phone, so there's no case where this would push content out of view. */
#depositLimitConfirmYes,
#depositLimitConfirmNo {
  white-space: nowrap;
}

/* ─── Deposit modal: limit states ─────────────────────────────────────
   Two different jobs. The "remaining" line sits quietly under a working
   address; the "reached" block replaces the address entirely. */

.deposit-limit-remaining {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
  margin: 12px 0 0 0;
}

/* The offer shown to someone with no limit set. Deliberately the same
   quiet treatment as .deposit-limit-remaining above — it occupies the
   same slot and should read as the same kind of information, not as an
   advert or a warning. Nobody opening a deposit screen wants to be
   lectured; this is a standing offer they can ignore. */
.deposit-limit-offer {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
  margin: 12px 0 0 0;
}

/* WHY a button reset rather than styling an <a>: this is a real <button>
   (it acts on the page rather than navigating), so it arrives with the
   browser's button chrome — background, border, padding, its own font —
   all of which has to be stripped before it can sit inline in a sentence. */
.deposit-limit-offer-link {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  color: #fcd34d;
  text-decoration: underline;
  cursor: pointer;
}

.deposit-limit-offer-link:hover {
  color: #fde68a;
}

.deposit-limit-reached {
  text-align: center;
  padding: 8px 4px;
}

.deposit-limit-reached p {
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.5;
  margin: 0 0 10px 0;
}

/* Amber rather than red: they haven't done anything wrong and nothing has
   failed — a limit they chose is working exactly as they asked it to. */
.deposit-limit-reached-title {
  color: #fbbf24 !important;
  font-weight: 600;
  font-size: 15px !important;
}

/* WHY this keeps a bottom margin now, where it used to be zero: it
   carries a tappable "Change it" link, and the Close button sits directly
   beneath it. Zero margin put a link and a button edge to edge, which on
   a phone is a mis-tap waiting to happen — and the two do very different
   things. */
.deposit-limit-reached-hint {
  color: #94a3b8 !important;
  font-size: 12px !important;
  margin-bottom: 6px !important;
}

.twofa-backup-panel {
  border-left: 3px solid #fbbf24;
  padding-left: 12px;
}

.twofa-codes {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 8px;
  margin: 14px 0;
}

.twofa-codes code {
  padding: 8px 10px;
  background: #0f172a;
  border: 1px solid #334155;
  border-radius: 6px;
  color: #fcd34d;
  font-family: monospace;
  font-size: 15px;
  letter-spacing: 1px;
  text-align: center;
}

.twofa-confirm-box {
  margin-top: 16px;
  padding: 14px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid #334155;
  border-radius: 8px;
}

.twofa-confirm-box p {
  color: #cbd5e1;
  font-size: 14px;
  margin: 0 0 4px;
}

.verification-upload-field {
  margin: 18px 0;
}

.verification-upload-field label {
  display: block;
  font-weight: 600;
  margin-bottom: 4px;
}

.verification-hint {
  color: #888;
  font-size: 0.82rem;
  margin: 0 0 8px;
}

.verification-upload-field input[type="file"] {
  display: block;
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  border: 1px solid #555;
  background-color: #2a2a2a;
  color: #fff;
  cursor: pointer;
}

.verification-loading {
  color: #888;
}

#kycSubmitBtn {
  margin-top: 10px;
  padding: 10px 18px;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
}

#kycSubmitBtn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* The "verify first" screen shown inside the withdrawal modal — see
   renderWithdrawKycGate() in transactionActions.js. */
.withdraw-kyc-gate h4 {
  margin: 0 0 10px;
  font-size: 17px;
  color: #fcd34d;
}

.withdraw-kyc-gate p {
  color: #ccc;
  font-size: 0.92rem;
  line-height: 1.5;
  margin-bottom: 16px;
}

.deposit-qr-wrap {
  background: #fff;
  padding: 10px;
  border-radius: 8px;
  margin-bottom: 16px;
  /* WHY a white background specifically: QR scanners need real contrast
     between the code and its background — most codes are rendered as
     black modules assuming a light background, so dropping this straight
     onto the modal's dark theme would make it unreliable to scan. */
}

.deposit-address-row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  background: #2a2a2a;
  border: 1px solid #555;
  border-radius: 6px;
  padding: 10px 12px;
}

.deposit-address-text {
  flex: 1;
  font-family: monospace;
  font-size: 0.85rem;
  color: #fff;
  word-break: break-all;
  text-align: left;
}

.copy-address-btn {
  flex-shrink: 0;
  padding: 6px 12px;
  border: none;
  border-radius: 6px;
  background: #fcd34d;
  color: #000;
  font-weight: 600;
  cursor: pointer;
  font-size: 0.8rem;
}

.copy-address-btn:hover {
  background: #fbbf24;
}

.copy-address-btn:disabled {
  cursor: default;
  opacity: 0.8;
}

.form-group {
  margin-bottom: 15px;
  text-align: left;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  color: #fcd34d;
  font-weight: 600;
}

.form-group input {
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  border: 1px solid #555;
  background: #2a2a2a;
  color: white;
  font-size: 14px;
}

.form-group input:focus {
  outline: none;
  border-color: #fcd34d;
}

.amount-preview {
  margin-top: 10px;
  padding: 8px;
  background: #2a2a2a;
  border-radius: 4px;
  font-size: 0.9rem;
  color: #ccc;
}

.modal-buttons {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}

.modal-buttons button {
  flex: 1;
  padding: 12px 20px;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
}

/* Mobile responsive — standardized to the same 768px breakpoint and
   header-nav/content-padding treatment used on dashboard_login,
   leaderboard, and activeBets, so the site has one consistent mobile
   behavior instead of each page reflowing at a different width.
   WHY this block lives at the very end of the file: the base
   .sidebar/.sidebar-nav li/.sidebar-bottom/.logout-btn/.content rules
   are declared further down in this file than they were in the other
   three pages' CSS. Since a media-query rule doesn't automatically
   "win" over a later same-specificity rule outside the media query —
   normal source-order cascade still applies — putting this block
   earlier (like the other three pages do) let those later base rules
   silently override the mobile styling on Profile specifically. This
   is now last in the file so it always wins. */
@media (max-width: 768px), (max-height: 500px) and (orientation: landscape) {
  .headerContainer {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .headerContainer2 ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    padding: 0;
    gap: 25px;
  }

  .headerContainer2 ul li {
    list-style: none;
    padding: 8px 12px;
  }

  .bodyContainer {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    border-right: none;
    padding: 10px;
  }

  .sidebar h2 {
    width: 100%;
    text-align: center;
  }

  .sidebar-nav {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
  }

  .sidebar-nav li {
    margin: 8px;
    padding: 10px 16px;
    font-size: 12px;
    text-align: center;
    border: 1px solid #ccc;
    border-radius: 8px;
    background-color: #1f1f1f;
    flex: 1 1 auto;
    min-width: 80px;
  }

  .sidebar-bottom {
    width: 100%;
    margin-left: 0;
    padding-top: 15px;
    border-top: 1px solid #444;
    display: flex;
    justify-content: center;
  }

  .logout-btn {
    width: 100%;
    max-width: 200px;
    display: block;
  }

  .content {
    width: 100%;
    padding: 10px;
  }

  /* Account Info tab — the label was a fixed, non-shrinking 200px
     (flex: 0 0 200px) which ate almost the entire narrow viewport,
     forcing the whole row (and with it, the whole page) to overflow
     horizontally since flex items don't shrink below their content's
     natural width by default. Stacking label above value sidesteps
     the fixed-width fight entirely. */
  .account-card {
    padding: 20px;
    margin: 20px auto;
  }

  .account-field {
    flex-direction: column;
    gap: 4px;
  }

  .account-field label {
    flex: 0 0 auto;
  }

  .account-actions {
    text-align: center;
  }

  /* Transactions tab — table-layout: fixed (the previous fix here)
     stopped the table from dragging the whole page sideways, but on
     a 6-column table like txn-table it did that by squeezing every
     column into the screen width, wrapping headers like "REFERENCE"
     into "REFERE / NCE" and cutting the Status column's text off
     entirely. Trading that for a scoped horizontal scroll instead:
     display: block + overflow-x: auto turns just the table into its
     own scroll container (the overflow is contained there, not on
     the page), so columns can keep their natural, readable width and
     the whole row stays intact — the user scrolls the table
     sideways instead of every column getting crushed. */
  /* WHY min-width: 0 is required for the scroll container below to
     actually contain anything: .content is display: flex, so each
     .sidebar-section is a flex item — and flex items default to
     min-width: auto, meaning they refuse to shrink below their
     content's min-content width. The nowrap table's min-content
     width is wider than the phone, so the section grew to fit it,
     .content grew with it, and the overflow escaped onto the PAGE
     (which is what put the whole layout sideways) before the
     table's own overflow-x ever got a chance to handle it.
     min-width: 0 opts out of that default and lets the section be
     narrower than its content — which is exactly the condition
     overflow-x: auto needs to kick in. */
  .sidebar-section {
    min-width: 0;
  }

  .summary-table,
  .txn-table {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
  }

  .summary-table th,
  .summary-table td,
  .txn-table th,
  .txn-table td {
    white-space: nowrap;
  }
}

/* Nov 16: logo alignment — the global "h1 { margin-bottom: 10px }" rule
   pushed "FairPlay" up, so the scales icon looked too low next to it. */
.websiteName h1 {
  margin: 0;
}

/* ── Referrals tab (Nov 19, profile/referral.js) ─────────────────────── */
.referral-card {
  margin: 20px auto;
}
.referral-note {
  color: #d1d5db;
  line-height: 1.5;
  margin: 0 0 14px;
}
.referral-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.referral-label {
  flex: 0 0 90px;
  font-weight: 600;
}
.referral-code,
.referral-link {
  background: #0f172a;
  color: #fcd34d;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 14px;
  word-break: break-all;
}
.referral-code {
  font-size: 18px;
  letter-spacing: 1px;
}
.referral-row input {
  background: #0f172a;
  color: #fff;
  border: 1px solid #333;
  border-radius: 6px;
  padding: 8px 10px;
  text-transform: uppercase;
}
.referral-copy-btn {
  padding: 6px 14px;
}
.referral-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px;
}
.referral-stat {
  background: #141414;
  border: 1px solid #333;
  border-radius: 10px;
  padding: 14px;
  text-align: center;
}
.referral-stat-value {
  font-size: 22px;
  font-weight: 700;
  color: #fcd34d;
}
.referral-stat-label {
  margin-top: 4px;
  color: #fff;
}
.referral-stat-hint {
  margin-top: 4px;
  font-size: 12px;
  color: #9ca3af;
}
.referral-rules {
  margin: 0;
  padding-left: 20px;
  line-height: 1.6;
  color: #d1d5db;
}
.referral-msg {
  margin: 6px 0 0;
  color: #fcd34d;
}
.referral-loading {
  padding: 30px;
  color: #9ca3af;
}

.referral-toggle { cursor: pointer; }
.referral-toggle input { width: 18px; height: 18px; accent-color: #fcd34d; }
.referral-board-link { color: #fcd34d; text-decoration: underline; }
