/* ==================================================== 
   ✅ GLOBAL VARIABLES (CSS Custom Properties)
==================================================== */
:root {
  --purple: #4b0082;
  --purple-glass: rgba(75, 0, 130, 0.4);
  --purple-deep: rgba(75, 0, 130, 0.9);
  --white: #ffffff;
  --hover-glow: rgba(255, 255, 255, 0.2);
  --modal-backdrop: rgba(0, 0, 0, 0.6);
  --yellow: #ffcc00;
  --yellow-600: #ffaa00;
  --green: #22c55e;
  --green-700: #16a34a;
}


/* General Styles */
body {
  background-image: url('https://wallpaperaccess.com/full/322494.jpg');
  background-size: cover;
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  color: #fff;
  font-family: Arial, sans-serif;
  line-height: 1.6;
  margin: 0;
  padding: 0;
}

/* Prevent horizontal scrolling */
html, body {
  overflow-x: hidden;
  width: 100%;
}

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 3000;
  background: rgba(75, 0, 130, 0.3);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 10px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  transition: top 0.5s ease-in-out;
}

header::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.1) 0%,
    rgba(255, 255, 255, 0.05) 20%,
    rgba(255, 255, 255, 0) 100%
  );
  pointer-events: none;
  z-index: 0;
}

/* Hide header when scrolling */
header.hidden {
  top: -80px;
  transition: top 0.6s ease-in-out; /* Smooth slide-up */
}

header h1 {
  font-size: 2.5rem;
  font-weight: bold;
  color: white;
  margin: 0;
}

/* Header title as a link */
.header-inner .site-title { margin: .32em 0; line-height: 1; }
.header-inner .site-title .home-link {
  display: inline-block;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* Optional: subtle hover/focus affordances */
.header-inner .site-title .home-link:hover { opacity: 0.9; }
.header-inner .site-title .home-link:focus-visible {
  outline: 2px dashed currentColor;
  outline-offset: 4px;
  border-radius: .375rem;
}

/* Group wrappers for logged-in / logged-out states */
#loggedInHeaderGroup,
#loggedOutHeaderGroup {
  display: flex;
  align-items: center;
  gap: 2px;
}

/* Header Login / Register buttons (logged-out state) */
.header-auth-btn {
  text-decoration: none;   /* important when "What is this site?" is an <a> */
  display: inline-flex;    /* normalises <a> and <button> */
  align-items: center;
  justify-content: center;

  font-size: 14px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: rgba(0, 0, 0, 0.4);
  color: #ffffff;
  cursor: pointer;
  white-space: nowrap;

  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

/* ✅ Make logged-out header buttons equal width */
#loggedOutHeaderGroup .header-auth-btn {
  text-align: center;
  justify-content: center;
}


/* Register button – blue primary with soft glow (BASE LOOK) */
.header-auth-btn--primary {
  background: linear-gradient(135deg, #1f7aff, #3ac8ff);
  border-color: rgba(80, 180, 255, 0.95);
  color: #ffffff;
  box-shadow:
    0 0 6px rgba(80, 180, 255, 0.7),
    0 0 14px rgba(58, 200, 255, 0.4);
  position: relative;
  overflow: hidden;
}

/* optional inner rim highlight (looks nice) */
.header-auth-btn--primary::before {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.26);
  pointer-events: none;
}

/* Login only hover/press (NOT Register) */
.header-auth-btn:not(.header-auth-btn--primary):hover,
.header-auth-btn:not(.header-auth-btn--primary):active {
  background: rgba(255, 255, 255, 0.18);
  border-color: #ffffff;
  color: #ffcc00;
}

/* Register: keep blue background ALWAYS — only text changes */
.header-auth-btn--primary:hover,
.header-auth-btn--primary:focus-visible {
  color: #ffcc00;
}
.header-auth-btn--primary:active {
  /* keep it blue even while clicking */
  color: #ffffff;
}

.header-auth-btn:visited {
  color: #ffffff;
}
/* ===== Deposit widget (mirrors homepage) ===== */
.deposit-btn {
  font-size: 14px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 6px;
  border: 1px solid rgba(255, 230, 180, 0.9);
  background: linear-gradient(135deg, #b8860b, #ffd700);
  color: #141814;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;

  box-shadow:
    0 0 6px rgba(255, 215, 0, 0.7),
    0 0 14px rgba(184, 134, 11, 0.5);

  position: relative;
  overflow: hidden;
  z-index: 20; /* keep clickable above header layers */

  transition:
    background 0.2s ease,
    color 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease,
    transform 0.1s ease;
}

/* Inner rim like the Register button */
.deposit-btn::before {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.25);
  pointer-events: none;
}

/* Hover/press – brighter gold + green text */
.deposit-btn:hover,
.deposit-btn:active {
  background: linear-gradient(135deg, #ffd700, #ffe87c);
  color: #209e4a; /* ✅ green text highlight */
  border-color: #fff3c2;
  box-shadow:
    0 0 10px rgba(255, 215, 0, 0.9),
    0 0 20px rgba(255, 248, 184, 0.7);
  transform: translateY(-1px);
}
.deposit-options {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;

  display: none;
  flex-direction: column;
  gap: 8px;

  min-width: 180px;
  padding: 10px;
  border-radius: 10px;

  background: rgba(75, 0, 130, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.55);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.deposit-options.show {
  display: flex;
}

/* 🔒 Deposit popup security strip (matches homepage style) */
.payment-security-note {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.4);
width: 100%;
  margin-left: auto;
  margin-right: auto;

  max-width: min(260px, 100%);
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;

  font-size: 11px;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.85);
  text-align: center;
}



.payment-security-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  text-align: center;
}

.payment-security-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: #3ad169;
  filter: drop-shadow(0 0 3px rgba(58, 209, 105, 0.7));
}

.payment-security-text {
  white-space: normal;
  display: block;
  max-width: 100%;
  overflow-wrap: anywhere;

  /* ✅ this is the centering fix */
  text-align: center;

  /* ✅ make the text block take real width so centering is meaningful */
  flex: 1;
  min-width: 0;
}

/* your strip uses home-security-brands in the HTML */
.home-security-brands {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}

.payment-brand-block {
  display: flex;
  align-items: center;
  gap: 4px;
}

.brand-logo-icon {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.brand-name {
  font-size: 10px;
}

/* lucide renders SVGs inside the spans */
.payment-security-icon svg,
.brand-logo-icon svg {
  width: 18px;
  height: 18px;
}

/* “Custom Deposit with PayPal” pill */
.custom-label {
  background: #222;
  border: 1px solid white;
  color: white;
  font-weight: bold;
  padding: 8px 14px;           /* tighter */
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  font-size: 14px;
  text-transform: uppercase;
  pointer-events: auto;

  display: inline-block;       /* shrink to content */
  width: auto;
  max-width: 100%;
  text-align: center;
  margin: 0 auto 8px auto;     /* centered */
}
.custom-label:hover { background: #00bfff; color: black; }

/* PayPal mount */
#paypal-btn-container {
  display: none;
  width: 100%;
}

/* Preset amounts: like homepage (4 per row) */
.deposit-buttons {
  display: grid;
  grid-template-columns: repeat(4, 1fr);  /* 4-up like homepage */
  gap: 10px;
  justify-items: center;                  /* center buttons in cells */
}
.deposit-buttons button {
  background: #222;
  border: 1px solid white;
  color: white;
  font-weight: bold;
  padding: 8px 12px;                      /* tighter */
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease-in-out;

  /* allow two-line bonus labels without forcing panel wider */
  white-space: normal;
  line-height: 1.2;
  min-height: 40px;
}
.deposit-buttons button:hover { background: #00bfff; color: black; }

/* Mobile tweaks */
@media (max-width: 768px) {
  .deposit-options {
    min-width: 260px;
    max-width: 92vw;
    left: 50%;
    transform: translateX(-50%);
    top: calc(100% + 8px);
  }
  .deposit-buttons {
    grid-template-columns: repeat(2, 1fr);  /* 2-up on mobile */
  }
}

.deposit-options.hidden { display: none !important; }


/* 🔷 Custom Deposit Label Styled Like a Button */
.custom-label {
  background: #222;
  border: 1px solid white;
  color: white;
  font-weight: bold;
  padding: 8px 12px;
  border-radius: 6px;
  transition: all 0.2s ease-in-out;
  font-size: 14px;
  text-transform: uppercase;
  opacity: 1;
  pointer-events: auto; /* ✅ Allow hover, block clicks */
}

/* Match other button hover effects */
.custom-label:hover {
  background: #00bfff;
  color: black;
}

/* DROPDOWN under the cart icon */
.header-icon-group { position: relative; }
.icon-btn { background: transparent; border: 0; cursor: pointer; display: grid; place-items: center; padding: .99rem; }
.dropdown-panel { position: absolute; right: 0; top: 110%; min-width: 220px;
  backdrop-filter: blur(10px); background: rgba(30, 30, 50, .6);
  border: 1px solid rgba(255,255,255,.08); border-radius: 12px; box-shadow: 0 8px 30px rgba(0,0,0,.25); padding: .35rem; z-index: 50;
}
.dropdown-panel.hidden { display: none; }
.dropdown-item { width: 100%; text-align: left; padding: .6rem .8rem; border-radius: 10px; background: transparent; color: #fff; border: 0; cursor: pointer; display: block; text-decoration: none; }
.dropdown-item:hover { background: rgba(255,255,255,.08); }


/* Credit pill */
.credit-pill {
  position: relative; /* keep this for the +$ delta animation */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  white-space: nowrap;

  background: radial-gradient(
    circle at top left,
    rgba(72, 225, 146, 0.32),
    rgba(24, 120, 72, 0.32)
  );
  border: 1px solid rgba(72, 225, 146, 0.95);
  color: #eafff5;

  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.65),
    0 0 14px rgba(72, 225, 146, 0.75);
}

.credit-pill.show-delta::after {
  content: attr(data-delta);
  position: absolute;
  left: 50%;
  top: calc(100% + 4px);
  transform: translate(-50%, 4px);
  font-size: 12px;
  font-weight: 700;
  color: var(--delta-color, #7ef29a);  /* soft green by default */
  opacity: 0;
  pointer-events: none;
  animation: credit-delta-pop 1.6s ease-out forwards;
}

@keyframes credit-delta-pop {
  0%   { opacity: 0; transform: translate(-50%, 6px); }
  12%  { opacity: 1; transform: translate(-50%, 0);   }
  82%  { opacity: 1; transform: translate(-50%, -2px);}
  100% { opacity: 0; transform: translate(-50%, -6px);}
}

/* Burger Button */
.menu-btn {
  font-size: 20px;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid white;
  border-radius: 3px;
  background-color: transparent;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: background-color 0.2s ease;
}

.menu-btn:hover {
  background-color: rgba(255, 255, 255, 0.2);
}


/* Side Menu */
.menu {
  position: fixed;
  top: 0;
  right: -270px;
  width: 270px;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding-top: 70px;
  background-color: rgba(75, 0, 130, 0.4);   /* semi-transparent purple */
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: -6px 0 30px rgba(0, 0, 0, 0.4);
  transition: right 0.3s ease;
  z-index: 5000;
  overflow-y: auto;
}

/* Side Menu Open State */
.menu.open {
  right: 0;
}

/* Close Button */
.menu .close-btn {
  font-size: 30px;
  color: white;
  background: none;
  border: none;
  cursor: pointer;
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
}

/* Side Menu Links */
.menu a {
  color: white;
  padding: 20px;
  text-decoration: none;
  text-align: center;
  font-size: 1.2rem;
  display: block;
}

/* Improve hit area + visuals for menu items (edge-to-edge highlight) */
.menu a,
.menu [role="menuitem"] {
  position: relative;
  display: block;
  border-radius: 0;          /* no rounded pill */
  margin: 0;                 /* remove side gaps so background fills width */
  padding: 14px 22px;        /* comfortable text padding */
  left: 0;                   /* override any earlier offset */
  transition: background-color .2s, transform .08s ease;
}

/* Visible highlight on hover + keyboard focus (full width, no box outline) */
.menu a:hover,
.menu a:focus-visible,
.menu a.is-hover,
.menu [role="menuitem"]:hover,
.menu [role="menuitem"]:focus-visible,
.menu [role="menuitem"].is-hover {
  background-color: rgba(255, 255, 255, 0.18);
  box-shadow: none;
  outline: none;
}

/* Active (current page) state — also full width */
.menu a.is-active {
  background: rgba(255, 255, 255, 0.24);
  box-shadow: none;
}

/* Subtle press feedback */
.menu a:active,
.menu [role="menuitem"]:active {
  transform: translateY(1px);
}

/* ✅ Prevent page scroll when menu is open (script toggles this) */
body.no-scroll {
  overflow: hidden;
}

/* ✅ Mobile menu: keep desktop purple glass + half-screen + bottom fade */
@media (max-width: 900px) {
  .menu {
    width: 55vw;
    max-width: 340px;
    right: 0;
    transform: translateX(100%);
    transition: transform 0.3s ease;

    /* ✅ keep the desktop colour on mobile */
    background-color: rgba(75, 0, 130, 0.4);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
  }

  .menu.open {
    transform: translateX(0);
  }

  /* subtle bottom fade (purple, not black) */
  .menu::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 90px;
    pointer-events: none;
    background: linear-gradient(
      to bottom,
      rgba(75, 0, 130, 0) 0%,
      rgba(75, 0, 130, 0.55) 100%
    );
  }
}
 
/* Main Content */
main {
  padding-top: 100px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 100vh;
}

/* Clipped Wheel Container - Keeps half-wheel effect */
.half-wheel-container {
  position: absolute;
  top: 100px; /* Keeps alignment with the black background */
  left: 50%;
  transform: translateX(-50%);
  width: 1100px;
  height: 500px; /* Slightly reduced height to hide extra segments */
  overflow: hidden;
  z-index: 1;
  clip-path: inset(-20px 0px 46% 0px);
 /* Hides more of the wheel */
}

/* Keep the top ticker visible within the clipped half-wheel container */
.half-wheel-container .pointer {
  top: 2px;            /* bring it inside the visible area */
  z-index: 4;          /* above the canvas (canvas uses z-index: 2) */
  border-bottom-color: #fff; /* ensure good contrast */
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.35));
  transform-origin: 50% 0%;
  pointer-events: none; /* so it never blocks clicks */
}

@keyframes pointerBump {
  0%   { transform: translateX(-50%) rotate(0deg); }
  24%  { transform: translateX(-50%) translateY(-3px) rotate(-24deg); } /* lean back + lift */
  60%  { transform: translateX(-50%) translateY(-1px) rotate(8deg); }   /* spring forward */
  100% { transform: translateX(-50%) rotate(0deg); }
}

.half-wheel-container .pointer.bump {
  animation: pointerBump 140ms ease-out; /* was 110ms */
}

.half-wheel-container .pointer.pointer-up {
  border-bottom: 0;
  border-top: 30px solid #fff; /* flips triangle to point upward */
}

/* ===========================================================
   Metallic Red Pointer Skin (+ inner facet) — ADDITIONS
   =========================================================== */

/* Hide the border-triangle; draw a richer skin with pseudos */
.half-wheel-container .pointer {
  border-left-color: transparent !important;
  border-right-color: transparent !important;
  border-bottom-color: transparent !important;
  border-top-color: transparent !important; /* covers .pointer-up */
  will-change: transform; /* smoother bump */
}

/* Metallic red face (triangle, points DOWN toward wheel) */
.half-wheel-container .pointer::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;                         /* sits inside the container */
  transform: translateX(-50%);
  width: 40px;                    /* overall size of the ticker */
  height: 36px;

  /* cast shadow matching the triangle shape */
  filter: drop-shadow(0 8px 8px rgba(0,0,0,0.45));

  /* DOWN triangle shape */
  clip-path: polygon(0% 0%, 100% 0%, 50% 100%);

  /* deep metallic red gradient */
  background: linear-gradient(
    170deg,
    #5a000a 0%,
    #9a0016 30%,
    #d2122e 50%,
    #7b0010 70%,
    #3e0006 100%
  );

  /* subtle outer glow + inner depth */
  box-shadow:
    0 0 10px rgba(210, 18, 46, 0.35),            /* glow */
    inset 0 -6px 10px rgba(0, 0, 0, 0.45),       /* bottom shading */
    inset 0  6px 10px rgba(255, 120, 140, 0.08); /* top sheen */

  border-radius: 3px;  /* tiny rounding to “metal” the edges */
  pointer-events: none;
}



/* Inner facet / single “diamond” angle */
.half-wheel-container .pointer::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 9px;                      /* depth of the facet from the tip */
  transform: translateX(-50%);
  width: 26px;
  height: 14px;
  /* small inverted triangle to suggest a single inner angle */
  clip-path: polygon(50% 100%, 42% 0%, 58% 0%);
  background: linear-gradient(180deg, rgba(255,255,255,0.65), rgba(255,255,255,0));
  opacity: 0.55;
  mix-blend-mode: screen;        /* metallic highlight feel */
  pointer-events: none;
  top: auto; bottom: 9px;
}

/* If you remove .pointer-up and want a DOWN arrow, flip the skin */
.half-wheel-container .pointer.pointer-up::before {
  clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
}
.half-wheel-container .pointer.pointer-up::after {
  top: 9px; bottom: auto;
  clip-path: polygon(50% 0%, 42% 100%, 58% 100%);
}

.header-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0 20px; /* consistent padding on both sides */
}

.header-buttons {
  position: absolute;
  right: 50px;  /* keep a safe distance from the edge */
  display: flex;
  align-items: center;
  gap: 13px;
}

/* 🖥 Desktop resize behaviour: keep title centred at normal widths,
   but as the window narrows, nudge the title left so it doesn't collide
   with the right-side header buttons (PC only; mobile has its own rules). */
@media (min-width: 769px) and (max-width: 1200px) {
  .header-inner .site-title {
    transform: translateX(clamp(-240px, calc((100vw - 1200px) / 2), 0px));
  }
}

.icon-btn,
.cart-btn {
  font-size: 20px;
  width: 40px;
  height: 40px;
  border: 1px solid var(--white);
  border-radius: 3px;
  background-color: transparent;
  color: var(--white);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease;
}

.icon-btn:hover,
.cart-btn:hover {
  background-color: var(--hover-glow);
}

.icon-btn i,
.cart-btn i {
  width: 22px;
  height: 22px;
}

.icon-btn img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  filter: brightness(0) invert(1);
  pointer-events: none;
}

.icon-btn svg.header-icon {
  width: 20px;
  height: 20px;
  display: block;
}

/* The Wheel */
#giveawayWheel {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
}

/* Center all content below the wheel */
.wheel-section {
  margin-top: 300px; /* Pushes content below the wheel */
  text-align: center;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  align-items: center; /* Centers everything */
}

/* The Pointer */
.pointer {
  width: 0;
  height: 0;
  border-left: 15px solid transparent;
  border-right: 15px solid transparent;
  border-bottom: 30px solid #fff;
  position: absolute;
  top: -30px;
  left: 50%;
  transform: translateX(-50%);
}

/* centre the fairness text */
.wheel-content { position: relative; }

/* Fairness badge (icon = green shield + subtle glow) */
.fairness-badge__icon {
  color: #39d97b; /* green */
  filter: drop-shadow(0 0 6px rgba(57, 217, 123, 0.45));
  animation: fairnessGlow 2.8s ease-in-out infinite;
}

/* Fairness badge container */
.fairness-badge{
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid rgba(57, 217, 123, 0.25);
  background: rgba(10, 20, 15, 0.35);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-weight: 700;
  font-size: 13px;
}

.fairness-badge__text{
  white-space: nowrap;
  line-height: 1;
}

/* Make badge feel clickable + keyboard focus */
.fairness-badge{
  cursor: pointer;
  user-select: none;
}

.fairness-badge:focus-visible{
  outline: 2px solid rgba(57, 217, 123, 0.65);
  outline-offset: 3px;
}

/* Pop-up message under the badge */
.fairness-popover{
  position: absolute;
  top: 44px;          /* sits just below the badge */
  left: 50%;
  width: min(340px, 92vw);
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(57, 217, 123, 0.22);
  background: rgba(8, 14, 12, 0.70);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: rgba(255,255,255,0.92);
  font-size: 13px;
  line-height: 1.25;
  box-shadow: 0 12px 28px rgba(0,0,0,0.35);
  transform: translate(-50%, -6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease;
  z-index: 5;
}

.fairness-popover::before{
  content: "";
  position: absolute;
  top: -6px;
  left: 50%;
  width: 10px;
  height: 10px;
  background: rgba(8, 14, 12, 0.70);
  border-left: 1px solid rgba(57, 217, 123, 0.18);
  border-top: 1px solid rgba(57, 217, 123, 0.18);
  transform: translateX(-50%) rotate(45deg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* visible state */
.fairness-popover.is-open{
  opacity: 1;
  transform: translate(-50%, 0);
  pointer-events: auto;
}

/* give the badge room so it doesn't overlap the h2 */
@media (min-width: 901px){
  .wheel-content{
    padding-top: 44px;
  }
}


@keyframes fairnessGlow {
  0%, 100% {
    filter: drop-shadow(0 0 4px rgba(57, 217, 123, 0.30));
  }
  50% {
    filter: drop-shadow(0 0 10px rgba(57, 217, 123, 0.70));
  }
}

@media (prefers-reduced-motion: reduce) {
  .fairness-badge__icon {
    animation: none;
  }
}

/* Center "Spin to Win" Text */
.wheel-content h2 {
  text-align: center;
  font-size: 2rem; /* Adjust font size if needed */
  margin-bottom: 20px; /* Adds space between text and button */
}

/* Resize & Center Spin Button */
/* 70s-style rhomboid Spin button with SOFT corners + subtle glowing border + 3D feel */
#spin-btn {
  /* keep your existing basics */
  margin-top: 10px;              /* Space above the button */
  padding: 12px 24px;            /* Button size */
  font-size: 1.5rem;             /* Text size */
  font-weight: bold;
  width: auto;                   /* Prevents full-width stretching */
  display: block;                /* Ensures it behaves as a block for centering */
  margin-left: auto;
  margin-right: auto;
  color: #333;
  cursor: pointer;

  /* new: build shape with layered pseudo-elements */
  position: relative;
  background: none;              /* we paint fills on pseudos */
  border: none;                  /* border drawn by pseudos */
  isolation: isolate;            /* keep shadows/glow contained */

  /* tunables */
  --accent: var(--yellow, #ffd400);
  --accent-dark: var(--yellow-600, #e0b700);
  --skew: -14deg;                /* parallelogram angle */
  --radius: 16px;                /* SOFT corner radius */
  --border: 3px;                 /* border thickness */
}

/* OUTER BORDER + GLOW (skewed rounded parallelogram) */
#spin-btn::before {
  content: "";
  position: absolute;
  inset: 0;                      /* full size */
  transform: skewX(var(--skew));
  border-radius: var(--radius);
  pointer-events: none;
  z-index: -1;

  /* border as a gradient surface */
  background: linear-gradient(180deg, var(--accent), var(--accent-dark));

  /* subtle outer glow that follows the rounded shape */
  filter:
    drop-shadow(0 10px 16px rgba(0,0,0,.22))      /* depth */
    drop-shadow(0 0 10px color-mix(in srgb, var(--accent) 45%, transparent)); /* halo */
}

/* INNER FILL (inset to reveal border) + 3D bevel */
#spin-btn::after {
  content: "";
  position: absolute;
  inset: var(--border);          /* reveal the border from ::before */
  transform: skewX(var(--skew));
  border-radius: calc(var(--radius) - var(--border));
  pointer-events: none;
  z-index: -1;

  /* glossy vertical fill */
  background:
    linear-gradient(180deg,
      rgba(255,255,255,.35) 0%,
      rgba(255,255,255,.10) 35%,
      rgba(0,0,0,.10) 100%
    ),
    linear-gradient(180deg, var(--accent), var(--accent-dark));

  /* inner highlights for 3D */
  box-shadow:
    inset 0 1.5px 0 rgba(255,255,255,.55), /* top inner highlight */
    inset 0 -2px 0 rgba(0,0,0,.22);        /* bottom inner shade */
}

/* HOVER: brighten halo slightly */
#spin-btn:hover::before {
  filter:
    drop-shadow(0 12px 18px rgba(0,0,0,.24))
    drop-shadow(0 0 14px color-mix(in srgb, var(--accent) 60%, transparent));
}

/* ACTIVE: press-down feel */
#spin-btn:active { transform: translateY(1px); }

/* ACCESSIBILITY FOCUS */
#spin-btn:focus-visible {
  outline: 2px dashed color-mix(in srgb, var(--accent) 85%, #000);
  outline-offset: 6px;
}

/* ===== Prize catalogue cards: rarity skins + badge ===== */
.prize-box { position: relative; }

/* Badge chip */
.prize-box .rarity-badge {
  position: absolute;
  top: 10px; left: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .4px;
  background: rgba(0,0,0,.45);
  border: 1px solid rgba(255,255,255,.25);
  text-transform: uppercase;
}

/* Value line */
.prize-box .value {
  opacity: 0.95;
  font-weight: 800;
  margin-top: 6px;
}

/* Metallic looks (kept readable on glass background) */
.prize-box.rarity-bronze {
  background: linear-gradient(145deg, rgba(205,127,50,.18), rgba(90,45,20,.18));
  border-color: rgba(205,127,50,.55);
  box-shadow: 0 0 0 1px rgba(205,127,50,.25) inset, 0 10px 20px rgba(0,0,0,.25);
}
.prize-box.rarity-bronze .rarity-badge { color: #ffcf9e; border-color: rgba(205,127,50,.6); }

.prize-box.rarity-silver {
  background: linear-gradient(145deg, rgba(180,180,200,.18), rgba(80,80,95,.18));
  border-color: rgba(200,200,220,.6);
  box-shadow: 0 0 0 1px rgba(200,200,220,.25) inset, 0 10px 20px rgba(0,0,0,.25);
}
.prize-box.rarity-silver .rarity-badge { color: #e6e9ff; border-color: rgba(200,200,220,.6); }

.prize-box.rarity-gold {
  background: linear-gradient(145deg, rgba(255,215,0,.20), rgba(150,110,0,.18));
  border-color: rgba(255,215,0,.7);
  box-shadow: 0 0 0 1px rgba(255,215,0,.35) inset, 0 10px 24px rgba(0,0,0,.28);
}
.prize-box.rarity-gold .rarity-badge { color: #ffeaa7; border-color: rgba(255,215,0,.7); }

/* Slightly larger image for catalogue boxes */
.prize-box img {
  max-width: 120px;
  max-height: 120px;
}

/* === Grid and cards === */
.prize-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
  margin-top: 40px;
  padding: 0 0 60px;
  width: 100%;
  max-width: none;              /* FIX: allow full-width layout (was 1200px) */
  align-items: stretch;         /* ensure cards fill their grid cells */
}

.prize-box {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  padding: 15px;
  text-align: center;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: white;
  transition: transform 0.3s ease;
  display: grid;
  grid-template-rows: 220px auto auto; /* FIX: match media slot height */
  overflow: hidden; 
}

.prize-box .media{
  height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 8px 0; 
}

/* Centered, consistent sizing; overrides earlier .prize-box img rules */
.prize-box .media img{
  display: block;                           /* remove baseline gap */
  max-height: 100% !important;
  max-width: 100%  !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain;
  margin: 0 !important;                     /* no vertical drift */
}

.prize-box:hover {
  transform: scale(1.05);
}

/* Keep single, consistent image sizing (avoid conflicting 100px override) */
.prize-box img {
  max-width: 120px;            /* FIX: match the earlier "slightly larger" size */
  max-height: 120px;           /* FIX: match for consistency */
  object-fit: contain;
  margin-bottom: 10px;
}

.prize-box h3 {
  margin: 8px 0 0;
  line-height: 1.2;
  min-height: calc(1.2em * 2);
  display: -webkit-box;
  -webkit-line-clamp: 2;                /* clamp long names */
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
}

.prize-box > img {
  display: none;                         /* hide raw img to prevent overlap */
}

/* Dark Grey Background Behind Spin Text & Button */
.wheel-content {
  background-color: rgba(50, 50, 50, 0.4); /* slightly more transparent */
  backdrop-filter: blur(15px);            /* glass blur */
  -webkit-backdrop-filter: blur(15px);
  color: white;
  padding: 40px 20px;
  width: 100%;
  max-width: 100%;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: -30px;
  position: relative;
  min-height: calc(100vh - 320px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  box-sizing: border-box;
}

@media (max-width: 768px) {
  .menu {
    width: 50vw;
    max-width: 320px;
    min-width: 240px;

    right: -100%;
    overflow: hidden;
  }

  .menu.open {
    right: 0;
  }

 /* stronger bottom fade */
.menu::before{
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;

  /* was 70px */
  height: 150px;

  pointer-events: none;

  background: linear-gradient(
    to bottom,
    rgba(0,0,0,0) 0%,
    rgba(20, 10, 45, 0.35) 35%,
    rgba(15, 10, 35, 0.98) 100%
  );
}
}


/* Ensure the footer has no extra margins pushing it up */
footer {
  margin: 0;
  padding: 10px;
  background: #333;
  color: white;
  text-align: center;
  width: 100%;
}

/* 🎁 Signup offer modal (wheel page) */
.modal-offer{
  max-width: 420px;
  text-align: center;
}
.modal-offer .offer-text{
  margin: 8px 0 14px;
  font-size: 0.98rem;
  opacity: 0.92;
}
.modal-offer .offer-text strong{
  color: var(--green);
  text-shadow: 0 0 10px rgba(34, 197, 94, 0.35);
}
@media (max-width: 600px){
  .modal-offer{ max-width: 340px; }
}


/* ====================================================
   🔐 MODALS — Login / Register / Forgot Password
   (Appended for parity with homepage)
==================================================== */

/* Modal Backdrop */
.modal {
  display: none;
  position: fixed;
  z-index: 7000; /* ↑ above side menu (5000) */
  inset: 0;
  background-color: var(--modal-backdrop); /* Dark overlay */
  backdrop-filter: blur(5px);               /* Glass effect */
  -webkit-backdrop-filter: blur(5px);
}

/* Modal Content */
.modal-content {
  background: var(--purple-deep);
  color: #fff;
  margin: 10% auto;
  padding: 30px;
  border: 1px solid #ccc;
  border-radius: 10px;
  width: 90%;
  max-width: 400px;
  text-align: center;
  position: relative;
  box-shadow: 0 0 20px rgba(0,0,0,0.5);
  animation: fadeIn 0.3s ease-in-out;
}

/* Close (X) */
.close {
  position: absolute;
  top: 10px;
  right: 10px;
  color: white;
  font-size: 26px;
  font-weight: bold;
  cursor: pointer;
  z-index: 10;
  padding: 0;
  line-height: 1;
}
.close:hover {
  color: var(--yellow);
}

/* Inputs inside modals */
.modal-content input {
  width: 100%;
  max-width: 300px;
  padding: 10px 12px;
  margin: 10px auto;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  background-color: rgba(255, 255, 255, 0.12);
  color: #fff;
  display: block;
  box-sizing: border-box;
}
.modal-content input::placeholder { color: #ccc; }

/* Primary buttons inside modals */
.modal-content button {
  width: 100%;
  max-width: 300px;
  padding: 10px;
  margin: 10px auto;
  background-color: #111;
  color: #f5f5f5;
  font-weight: bold;
  font-size: 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  display: block;
  transition: color 0.3s ease, text-shadow 0.3s ease, background-color 0.3s ease;
}
.modal-content button:hover {
  color: #00bfff;
  text-shadow: 0 0 6px #00bfff;
  background-color: #222;
}

/* Secondary action buttons row */
.modal-action-buttons {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 10px auto;
  max-width: 300px;
}
.modal-sub-btn {
  flex: 1;
  padding: 8px;
  background-color: transparent;
  color: #f5f5f5;
  border: 1px solid #444;
  border-radius: 6px;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.3s ease, text-shadow 0.3s ease, border-color 0.3s ease;
}
.modal-sub-btn:hover {
  color: #00bfff;
  text-shadow: 0 0 5px #00bfff;
  border-color: #00bfff;
}

/* 🏆 Win Modal tweaks (uses existing modal base styles) */
#prizeWinModal .modal-content {
  max-width: 520px;
  text-align: left;
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 16px 18px;
  align-items: center;
}

#prizeWinModal .win-media {
  grid-column: 1 / 2;
}
#prizeWinModal #winItemImage {
  width: 140px;
  height: 140px;
  object-fit: contain;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 10px;
  display: block;
}

#prizeWinModal .win-meta {
  grid-column: 2 / 3;
  line-height: 1.35;
}
#prizeWinModal #winItemTitle {
  font-size: 1.15rem;
  margin: 0 0 6px 0;
}
#prizeWinModal #winItemValue {
  font-weight: 700;
  opacity: 0.95;
}

#prizeWinModal .win-actions {
  grid-column: 1 / -1;
  display: flex;
  gap: 10px;
  margin-top: 8px;
}

/* Action buttons inside win modal */
#winAddToCartBtn,
#winCashBackBtn {
  flex: 1;
  padding: 12px 14px;
  border-radius: 8px;
  font-weight: 800;
  font-size: 15px;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(17, 17, 17, 0.9);
  color: #f5f5f5;
  cursor: pointer;
  transition: transform 0.08s ease, background-color 0.25s ease, border-color 0.25s ease;
}
#winAddToCartBtn:hover,
#winCashBackBtn:hover {
  transform: translateY(-1px);
  border-color: rgba(255,255,255,0.45);
  background: rgba(34, 34, 34, 0.95);
}

/* Distinguish actions (optional accents) */
#winAddToCartBtn {
  box-shadow: inset 0 0 0 1px rgba(255, 204, 0, 0.25);
}
#winAddToCartBtn:hover {
  box-shadow: inset 0 0 0 1px rgba(255, 204, 0, 0.6);
}
#winCashBackBtn {
  box-shadow: inset 0 0 0 1px rgba(34, 197, 94, 0.25);
}
#winCashBackBtn:hover {
  box-shadow: inset 0 0 0 1px rgba(34, 197, 94, 0.6);
}

/* Link-style switch between modals */
.modal-switch-btn {
  background: none;
  border: none;
  color: var(--yellow);
  font-weight: bold;
  cursor: pointer;
  padding: 0;
  text-decoration: none;
}
.modal-switch-btn:hover { color: var(--yellow-600); }

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-20px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeOut {
  from { opacity: 1; transform: translateY(0); }
  to   { opacity: 0; transform: translateY(-20px); }
}

/* Tooltip anchor to avoid intercepting clicks on icon buttons */
.tooltip-anchor {
  position: absolute;
  inset: 0;
  pointer-events: none; /* prevent capturing the click */
}

/* Logged-in glow on login icon btn */
#loginBtn.logged-in {
  box-shadow:
    0 0 25px rgba(0, 123, 255, 1),
    0 0 50px rgba(0, 123, 255, 0.9),
    0 0 80px rgba(0, 123, 255, 0.7);
  transition: box-shadow 0.3s ease;
}

/* Autofill tweaks so text stays readable on purple */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px var(--purple-deep) inset !important;
  box-shadow: 0 0 0 1000px var(--purple-deep) inset !important;
  -webkit-text-fill-color: #fff !important;
}
input:-moz-autofill {
  box-shadow: 0 0 0 1000px var(--purple-deep) inset !important;
  -moz-box-shadow: 0 0 0 1000px var(--purple-deep) inset !important;
  -moz-text-fill-color: #fff !important;
}
input { background-color: var(--purple-deep); color: #fff; caret-color: #fff; }


/* Optional scrollbar theming for visual parity */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-track {
  background: rgba(75, 0, 130, 0.3);
  border-radius: 5px;
}
::-webkit-scrollbar-thumb {
  background-color: rgba(75, 0, 130, 0.8);
  border-radius: 5px;
  border: 2px solid rgba(255, 255, 255, 0.3);
}
::-webkit-scrollbar-thumb:hover {
  background-color: rgba(75, 0, 130, 1);
}
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(75, 0, 130, 0.8) rgba(75, 0, 130, 0.3);
}

/* Generic utility used by your JS to toggle visibility */
.hidden { display: none !important; }

/* Mobile adjustments for modals (these help your existing modals incl. #prizeWinModal) */
@media (max-width: 768px) {
  main { padding-top: 68px !important; } 
  .modal-content {
    padding: 20px;
    max-width: 95%;
  }
}

@media (max-width: 768px) {
  #prizeWinModal .modal-content {
    grid-template-columns: 1fr; /* stack image above text on mobile */
    text-align: center;
  }
  #prizeWinModal .win-media { justify-self: center; }
  #prizeWinModal .win-actions { flex-direction: column; }
  .modal-content input,
  .modal-content button {
    font-size: 1rem;
    padding: 8px;
  }
  .modal-action-buttons { flex-direction: column; }
  .modal-sub-btn { font-size: 1rem; padding: 10px; }
}


/* === Header icon row: keep cart/login/menu side-by-side === */
.header-icon-group {
  position: relative;           /* you already had this */
  display: flex;                /* make children line up horizontally */
  align-items: center;
  gap: 6px;                     /* space between icons */
}

@media (min-width: 901px) {
  .header-icon-group { gap: 8px; }
}

/* Ensure icon buttons are uniform size and don't stretch */
.icon-btn,
.login-btn,
.menu-btn {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  padding: 0 !important;
  border-radius: 5px;
  display: inline-grid;
  place-items: center;
  line-height: 0;
}


/* Lucide SVG icons */
.header-icon-group i[data-lucide] {
  width: 22px;
  height: 22px;
}

/* The login icon is an <img> — match sizes to Lucide */
.header-icon-group .login-btn img {
  width: 22px;
  height: 22px;
  display: block;               /* remove baseline gap */
}

/* Keep the dropdown anchored to the right of the group */
.header-icon-group .dropdown-panel {
  right: 0;
  left: auto;
}

/* ✅ Login toast (homepage 1:1) */
.login-toast {
  position: fixed;
  top: 90px;
  right: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 12px;
  background: rgba(20, 255, 140, 0.15);
  border: 1px solid rgba(20, 255, 140, 0.35);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  transform: translateY(-10px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 9999;
}

.login-toast.show {
  opacity: 1;
  transform: translateY(0);
}

.login-toast-icon {
  font-size: 16px;
  line-height: 1;
}

.login-toast-text {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.2px;
}

@media (max-width: 600px) {
  .login-toast {
    left: 12px;
    right: 12px;
    top: 80px;
    justify-content: center;
  }
}

/* 🔓 Logout confirm modal (homepage 1:1) */
.modal-confirm {
  max-width: 360px;
  text-align: center;
}

.modal-confirm h2 {
  margin-top: 0;
  margin-bottom: 8px;
}

.modal-confirm p {
  margin: 0 0 16px;
  font-size: 0.95rem;
  opacity: 0.9;
}

.modal-confirm-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
}

/* Secondary button (cancel) */
.modal-alt-btn {
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(0, 0, 0, 0.3);
  color: #ffffff;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.1s ease;
}

.modal-alt-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.8);
  transform: translateY(-1px);
}

/* Destructive / confirm logout button */
.modal-danger-btn {
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid rgba(255, 120, 120, 0.9);
  background: linear-gradient(135deg, #8b0000, #ff4c4c);
  color: #fff;
  cursor: pointer;
  font-weight: 600;
  box-shadow:
    0 0 6px rgba(255, 120, 120, 0.7),
    0 0 14px rgba(139, 0, 0, 0.5);
  transition:
    background 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.1s ease,
    border-color 0.2s ease;
}

.modal-danger-btn:hover {
  background: linear-gradient(135deg, #ff5f5f, #ff8585);
  border-color: #ffd2d2;
  box-shadow:
    0 0 10px rgba(255, 150, 150, 0.9),
    0 0 20px rgba(255, 200, 200, 0.7);
  transform: translateY(-1px);
}

/* ✅ Fairness badge tick colour */
.fairness-badge__icon {
  color: var(--green);
}

/* =========================
   Side Menu overlay + mobile sizing (wheel page)
   ========================= */
.menu-overlay{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 4990; /* just under .menu (z-index:5000) */
}

.menu.open + .menu-overlay {
  opacity: 1;
  pointer-events: auto;
}

body.no-scroll{
  overflow: hidden;
}

/* ✅ Logged-out header buttons — match homepage sizing (no forced widths) */
#loggedOutHeaderGroup{
  display: flex;
  align-items: center;
  gap: 4px;
}

#loggedOutHeaderGroup .header-auth-btn{
  /* normalise <a> and <button> so they size the same */
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;

  /* match your base button styling */
  font-size: 14px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 6px;

  /* 🔥 kill the “big button” behaviour from earlier rules */
  width: auto !important;
  min-width: 0 !important;
  flex: 0 0 auto !important;

  white-space: nowrap;
  line-height: 1;
}

/* Extra safety in case --info has any weird overrides elsewhere */
#loggedOutHeaderGroup .header-auth-btn--info {
  width: 160px !important;
  min-width: 120px !important;
  max-width: 120px !important;
  flex: 0 0 160px !important;
  padding: 6px 12px !important;
}



@media (max-width: 900px){
  .menu{
    width: 55vw;
    max-width: 340px;
    right: 0;
    transform: translateX(100%);
    transition: transform 0.3s ease;

    /* ✅ purple glass that fades off at the bottom */
    background: linear-gradient(
      180deg,
      rgba(75, 0, 130, 0.42) 0%,
      rgba(75, 0, 130, 0.26) 65%,
      rgba(75, 0, 130, 0.00) 100%
    );

    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
  }

  .menu.open{
    transform: translateX(0);
  }

  .menu.closing{
    transform: translateX(100%);
  }

  /* Optional: you can remove this now since the menu itself fades */
  .menu::before{
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 70px;
    pointer-events: none;
  }
}


/* =========================
   MOBILE — Wheel + Header (merged clean)
   ========================= */
@media (max-width: 900px) {
  /* ---------- Wheel ---------- */
  .wheel-section { margin-top: 0 !important; }

  :root {
    --wheel-w-phone: 100vw;
    --wheel-maxw-phone: none;
    --pointer-size-phone: 32px;
    --pointer-top-phone: -8px;
    --wheel-canvas-offset: 95px;
  }

  .half-wheel-container {
    position: relative !important;
    width: var(--wheel-w-phone) !important;
    max-width: var(--wheel-maxw-phone) !important;
    aspect-ratio: 1.30 / 1 !important;
    height: auto !important;
    overflow: hidden;
    clip-path: inset(-56px 0 18.5% 0) !important;
    -webkit-clip-path: inset(-56px 0 18.5% 0) !important;
    margin: -24px auto -40px !important;
    left: auto !important;
    transform: none !important;
    top: auto !important;
  }

  #giveawayWheel,
  #giveawayWheelReflection {
    position: absolute !important;
    inset: auto auto auto 50% !important; /* clear shorthand */
    top: 80px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: 112% !important;
    height: auto !important;
    display: block !important;
  }

   .half-wheel-container .pointer {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);           /* center over wheel */
    top: calc(var(--wheel-canvas-offset) - (var(--pointer-size-phone) * 0.55));
    /* 0.55 overlaps the rim slightly; tweak 0.45–0.65 if needed */
    z-index: 3;                             /* above canvases */
  }

    .half-wheel-container .pointer::before {
    width: var(--pointer-size-phone);
    height: calc(var(--pointer-size-phone) * 0.9);
  }

  .wheel-content {
    border-top: 0 !important;
    margin-top: -16px !important;
    padding-top: 12px !important;
    min-height: auto !important;
  }

  .prize-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 14px !important;
    padding-bottom: 80px !important;
  }

   #loggedOutHeaderGroup .header-auth-btn {
    font-size: 12px !important;
    padding: 5px 10px !important;
    line-height: 1 !important;
  }

  /* Let the long info button truncate instead of forcing a wide fixed width */
  #loggedOutHeaderGroup .header-auth-btn--info {
    width: auto !important;
    min-width: 0 !important;
    max-width: 150px !important;
    flex: 0 1 150px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }
  /* ---------- Header (title left, actions right) ---------- */
  header { padding-right: 0 !important; }
  .header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    padding: 10px 2px 10px 0 !important;
    padding-left: max(0px, env(safe-area-inset-left)) !important;
    padding-right: 15px !important;
    flex-wrap: nowrap; /* allow clean 2nd row when tight */
    /* ▼ ensure the green "+$XXX" can escape on mobile */
    position: relative;
    overflow: visible;
    z-index: 10;
  }

  .site-title, .header-title, .logo-title {
    position: static !important;
    left: auto !important;
    transform: none !important;
    margin: 0 !important;
    text-align: left !important;
    order: -1;
    max-width: 7ch;               /* PRIZE | UNBOX stack */
    word-break: normal;
    line-height: 0.95;
    font-size: clamp(14px, 4.2vw, 18px);
    letter-spacing: 0.3px;
    white-space: normal !important;
    overflow: visible;
    text-overflow: clip;
    margin-inline-start: 0 !important;
  }

  /* ensure PRIZE | UNBOX wraps cleanly on the space */
.site-title .home-link {
  display: block;          /* anchor respects the 7ch max-width */
  white-space: normal;     /* allow wrapping */
  word-break: keep-all;    /* don’t split words */
  padding-left: 0;
}

  .header-actions,
  .header-right,
  .header-buttons {
    margin-left: auto !important;
    display: flex;
    align-items: center;
    gap: 6px;
    order: 2;
    min-height: 40px;
    padding: 8px 10px;
    position: static !important;
    inset: auto !important;
    right: auto !important;
    left: auto !important;
    transform: none !important;
    margin-right: 0 !important;
    flex: 1 1 auto;
    justify-content: flex-end;
    min-width: 0;
    /* keep dropdowns and delta above canvas */
    z-index: 10;
  }

  /* Compact buttons */
  .deposit-btn { font-size: 12px; padding: 5px 9px; line-height: 1; }

  .credit-pill {
    font-size: 12px;
    padding: 5px 9px;
    line-height: 1;
    border-radius: 14px;
    white-space: nowrap;
    max-width: 32vw;                 /* don’t let it dominate */
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 0 1 auto;                  /* allow slight shrink */
    /* ▼ anchor +$XXX and ensure it appears above */
    position: relative;
    z-index: 10;
  }

  .header-actions svg,
  .header-buttons svg { width: 22px; height: 22px; }

  .icon-btn, .login-btn, .menu-btn {
    width: 34px; height: 34px; padding: 0; line-height: 0; border-radius: 8px;
    display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto;
  }

  /* Ensure the immediate wrapper is a positioning context for the dropdown */
  .header-buttons > div { position: relative; }

  .deposit-buttons {
    display: grid;
    grid-template-columns: repeat(2, minmax(120px, 1fr)); /* 2-up on phones */
    gap: 10px;
  }

  body {
    background-attachment: scroll;
    background-position: center top;
    background-size: cover;
  }
}

/* ===========================================================
   MOBILE BACKGROUND FIX (REMOVE THIS WHOLE BLOCK TO ROLLBACK)
   Stabilises the background image on phones (prevents “stretch/jank”)
   PC unchanged.
   =========================================================== */
@media (max-width: 900px) {
  /* stop using the normal body background on mobile */
  body {
    background-image: none !important;
  }

  /* draw the background as a fixed layer instead */
  body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;

    background-image: url('https://wallpaperaccess.com/full/322494.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    /* tiny scale helps hide edge “gaps” during scroll/viewport resize */
    transform: scale(1.03);
    transform-origin: center;

    /* stops shimmer on some devices */
    will-change: transform;
  }

  /* optional: ensures any uncovered area is black */
  html {
    background: #000;
  }
}

/* Very small phones */
@media (max-width: 390px) {
  .deposit-btn { font-size: 12.5px; padding: 6px 9px; }
  .credit-pill {
    max-width: 48vw; font-size: 12.5px; padding: 6px 9px;
  }
  /* nudge the delta slightly closer & smaller on tiny screens */
  .credit-pill.show-delta::after {
    font-size: 11px;
    top: calc(100% + 2px);
    transform: translate(-50%, 2px);
  }
  .icon-btn, .login-btn, .menu-btn { width: 38px; height: 38px; }
}