/* ============================================================
 * bb333.homes stylesheet
 * Mobile-first 320-430px canvas. All custom classes use the
 * dynamic prefix `w9583-`. CSS variables follow the same prefix.
 * Palette: #8B008B brand / #0C0C0C bg / #DDA0DD light
 *          #6C757D muted / #FFFACD highlight
 * ============================================================ */

:root {
  --w9583-brand: #8B008B;
  --w9583-brand-deep: #5C005C;
  --w9583-bg: #0C0C0C;
  --w9583-bg-soft: #161016;
  --w9583-card: #1B1320;
  --w9583-text: #FFFACD;
  --w9583-text-soft: #DDA0DD;
  --w9583-muted: #6C757D;
  --w9583-line: rgba(221, 160, 221, 0.18);
  --w9583-shadow: 0 6px 22px rgba(0, 0, 0, 0.45);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--w9583-bg);
  color: var(--w9583-text);
  font-family: "Hind Siliguri", "Noto Sans Bengali", "SolaimanLipi",
               system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.55;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a {
  color: var(--w9583-text-soft);
  text-decoration: none;
}
a:focus-visible {
  outline: 2px solid var(--w9583-text-soft);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Page shell — keep mobile canvas centered on wider screens */
.w9583-shell {
  max-width: 430px;
  margin: 0 auto;
  min-height: 100vh;
  position: relative;
  background:
    radial-gradient(120% 60% at 50% -10%, rgba(139, 0, 139, 0.30), transparent 60%),
    var(--w9583-bg);
  box-shadow: 0 0 40px rgba(0,0,0,0.5);
}

/* ===================== Header ===================== */
.w9583-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: linear-gradient(180deg, #14060F 0%, #0C0C0C 100%);
  border-bottom: 1px solid var(--w9583-line);
}

.w9583-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}
.w9583-brand img {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid rgba(221, 160, 221, 0.35);
  flex-shrink: 0;
}
.w9583-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
  min-width: 0;
}
.w9583-brand-name {
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.4px;
  color: #FFFFFF;
}
.w9583-brand-tag {
  font-size: 10px;
  color: var(--w9583-text-soft);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.w9583-header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}
.w9583-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 7px 12px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 12.5px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, background .2s ease, color .2s ease;
}
.w9583-btn:active { transform: scale(0.96); }
.w9583-btn-ghost {
  background: transparent;
  border-color: rgba(221, 160, 221, 0.5);
  color: var(--w9583-text);
}
.w9583-btn-solid {
  background: linear-gradient(135deg, var(--w9583-brand) 0%, var(--w9583-brand-deep) 100%);
  color: #FFFFFF;
  box-shadow: 0 4px 14px rgba(139, 0, 139, 0.45);
}

.w9583-icon-btn {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid rgba(221, 160, 221, 0.4);
  border-radius: 10px;
  color: var(--w9583-text);
  cursor: pointer;
}
.w9583-icon-btn svg { width: 18px; height: 18px; }

/* Expandable drawer (partition menu) */
.w9583-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 78%;
  max-width: 320px;
  height: 100vh;
  background: #100810;
  border-left: 1px solid var(--w9583-line);
  transform: translateX(105%);
  transition: transform .26s ease;
  z-index: 60;
  padding: 16px 14px 24px;
  overflow-y: auto;
  box-shadow: -12px 0 30px rgba(0,0,0,0.55);
}
.w9583-drawer-open { transform: translateX(0); }
.w9583-drawer-mask {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
  z-index: 55;
}
.w9583-drawer-open + .w9583-drawer-mask,
.w9583-drawer-mask.w9583-show {
  opacity: 1;
  pointer-events: auto;
}
.w9583-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.w9583-drawer-head h3 {
  margin: 0;
  font-size: 14px;
  color: var(--w9583-text-soft);
  letter-spacing: 0.4px;
  text-transform: uppercase;
}
.w9583-drawer-close {
  background: transparent;
  border: none;
  color: var(--w9583-text);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
}
.w9583-drawer-link {
  display: block;
  padding: 12px 10px;
  border-radius: 10px;
  color: var(--w9583-text);
  font-size: 14px;
  border: 1px solid transparent;
  margin-bottom: 4px;
}
.w9583-drawer-link:active { background: rgba(139, 0, 139, 0.18); }
.w9583-drawer-section {
  font-size: 11px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--w9583-muted);
  margin: 14px 6px 6px;
}
.w9583-drawer-cta {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ===================== Hero carousel ===================== */
.w9583-hero {
  position: relative;
  margin: 12px 12px 6px;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--w9583-shadow);
  border: 1px solid var(--w9583-line);
}
.w9583-hero-track {
  display: flex;
  transition: transform .42s ease;
}
.w9583-hero-slide {
  flex: 0 0 100%;
  position: relative;
}
.w9583-hero-slide img {
  width: 100%;
  height: 168px;
  object-fit: cover;
}
.w9583-hero-overlay {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 28px 14px 12px;
  background: linear-gradient(0deg, rgba(12,12,12,0.92) 0%, rgba(12,12,12,0) 100%);
}
.w9583-hero-title {
  font-size: 16px;
  font-weight: 700;
  color: #FFFFFF;
  margin: 0 0 2px;
  line-height: 1.25;
}
.w9583-hero-sub {
  font-size: 12px;
  color: var(--w9583-text);
  margin: 0 0 8px;
}
.w9583-hero-dots {
  position: absolute;
  bottom: 8px;
  right: 12px;
  display: flex;
  gap: 5px;
}
.w9583-hero-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 250, 205, 0.45);
  cursor: pointer;
  border: none;
  padding: 0;
}
.w9583-hero-dot-on { background: #FFFACD; transform: scale(1.15); }

/* ===================== Category chips ===================== */
.w9583-chips {
  display: flex;
  gap: 6px;
  padding: 8px 12px 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.w9583-chips::-webkit-scrollbar { display: none; }
.w9583-chip {
  flex: 0 0 auto;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--w9583-text);
  background: rgba(221, 160, 221, 0.08);
  border: 1px solid var(--w9583-line);
  cursor: pointer;
}

/* ===================== Section ===================== */
.w9583-section {
  margin: 14px 0 6px;
  padding: 0 12px;
}
.w9583-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.w9583-section-title {
  font-size: 15px;
  font-weight: 700;
  color: #FFFFFF;
  margin: 0;
  position: relative;
  padding-left: 10px;
}
.w9583-section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 16px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--w9583-brand) 0%, var(--w9583-text-soft) 100%);
}
.w9583-section-link {
  font-size: 11px;
  color: var(--w9583-text-soft);
}

/* ===================== Game grid ===================== */
.w9583-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
@media (min-width: 360px) {
  .w9583-grid { gap: 9px; }
}
@media (min-width: 400px) {
  .w9583-grid { grid-template-columns: repeat(5, 1fr); }
}
.w9583-game {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  text-align: center;
}
.w9583-game-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid var(--w9583-line);
  background: #1B1320;
  transition: transform .18s ease, box-shadow .2s ease;
}
.w9583-game:active .w9583-game-img,
.w9583-game:focus-visible .w9583-game-img {
  transform: scale(0.96);
  box-shadow: 0 6px 18px rgba(139, 0, 139, 0.45);
}
.w9583-game-name {
  margin-top: 4px;
  font-size: 11px;
  color: var(--w9583-text);
  line-height: 1.25;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  min-height: 28px;
}

/* ===================== Info / promo cards ===================== */
.w9583-promo-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  padding: 0 12px;
  margin: 10px 0;
}
.w9583-promo-card {
  background: linear-gradient(140deg, rgba(139, 0, 139, 0.25) 0%, rgba(12, 12, 12, 0.6) 100%);
  border: 1px solid var(--w9583-line);
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
}
.w9583-promo-card:active { transform: scale(0.98); }
.w9583-promo-card .w9583-promo-eyebrow {
  font-size: 10px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--w9583-text-soft);
}
.w9583-promo-card h4 {
  margin: 4px 0 6px;
  font-size: 14px;
  color: #FFFFFF;
}
.w9583-promo-card p {
  margin: 0;
  font-size: 12px;
  color: var(--w9583-text);
}

/* ===================== Article prose ===================== */
.w9583-prose {
  padding: 6px 14px 4px;
  font-size: 14px;
  color: var(--w9583-text);
}
.w9583-prose h2 {
  font-size: 16px;
  color: #FFFFFF;
  margin: 14px 0 6px;
  line-height: 1.35;
}
.w9583-prose h3 {
  font-size: 14px;
  color: var(--w9583-text-soft);
  margin: 10px 0 4px;
}
.w9583-prose p {
  margin: 0 0 8px;
  color: var(--w9583-text);
}
.w9583-prose a {
  color: var(--w9583-text-soft);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.w9583-prose ul {
  margin: 4px 0 8px;
  padding-left: 18px;
}
.w9583-prose li { margin-bottom: 3px; }

/* ===================== Testimonials ===================== */
.w9583-reviews {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 78%;
  gap: 10px;
  padding: 4px 12px 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.w9583-reviews::-webkit-scrollbar { display: none; }
.w9583-review {
  background: var(--w9583-card);
  border: 1px solid var(--w9583-line);
  border-radius: 12px;
  padding: 12px;
}
.w9583-review-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.w9583-review-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--w9583-brand), var(--w9583-text-soft));
  display: flex; align-items: center; justify-content: center;
  color: #FFFFFF; font-weight: 700; font-size: 13px;
}
.w9583-review-name { font-size: 12.5px; color: #FFFFFF; font-weight: 600; }
.w9583-review-meta { font-size: 10.5px; color: var(--w9583-muted); }
.w9583-review-text { font-size: 12.5px; color: var(--w9583-text); margin: 0; }
.w9583-stars { color: #FFFACD; font-size: 11px; letter-spacing: 1px; }

/* ===================== How to play / steps ===================== */
.w9583-steps {
  display: grid;
  gap: 8px;
  padding: 4px 12px 6px;
}
.w9583-step {
  display: flex;
  gap: 10px;
  background: var(--w9583-card);
  border: 1px solid var(--w9583-line);
  border-radius: 12px;
  padding: 10px 12px;
}
.w9583-step-num {
  flex: 0 0 28px;
  width: 28px; height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--w9583-brand), var(--w9583-brand-deep));
  color: #FFFFFF;
  font-weight: 700;
  font-size: 13px;
  display: flex; align-items: center; justify-content: center;
}
.w9583-step-body h4 {
  margin: 0 0 2px;
  font-size: 13.5px;
  color: #FFFFFF;
}
.w9583-step-body p {
  margin: 0;
  font-size: 12.5px;
  color: var(--w9583-text);
}

/* ===================== Extended footer (homepage only) ===================== */
.w9583-extfoot {
  margin: 14px 12px 6px;
  background: var(--w9583-bg-soft);
  border: 1px solid var(--w9583-line);
  border-radius: 14px;
  overflow: hidden;
}
.w9583-extfoot-block { padding: 12px 14px; border-bottom: 1px solid var(--w9583-line); }
.w9583-extfoot-block:last-child { border-bottom: none; }
.w9583-extfoot-title {
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--w9583-text-soft);
  margin: 0 0 8px;
}
.w9583-extfoot-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
}
.w9583-extfoot-list li a {
  display: block;
  font-size: 12.5px;
  color: var(--w9583-text);
  padding: 6px 8px;
  border-radius: 8px;
  background: rgba(221, 160, 221, 0.06);
  border: 1px solid transparent;
}
.w9583-extfoot-list li a:active { background: rgba(139, 0, 139, 0.18); }
.w9583-extfoot-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.w9583-extfoot-actions .w9583-btn { width: 100%; }
.w9583-extfoot-disclaimer {
  font-size: 11.5px;
  color: var(--w9583-muted);
  line-height: 1.5;
  margin: 0;
}

/* ===================== Generic footer ===================== */
.w9583-footer {
  padding: 16px 14px 86px;
  border-top: 1px solid var(--w9583-line);
  background: #080508;
  color: var(--w9583-text-soft);
  font-size: 12px;
  text-align: center;
}
.w9583-footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 10px;
  margin-bottom: 10px;
}
.w9583-footer-nav a {
  font-size: 12px;
  color: var(--w9583-text-soft);
}
.w9583-footer-copy { font-size: 11px; color: var(--w9583-muted); }

/* ===================== Bottom nav ===================== */
.w9583-bottomnav {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: 100%;
  max-width: 430px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: linear-gradient(180deg, #140810 0%, #050205 100%);
  border-top: 1px solid var(--w9583-line);
  z-index: 40;
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}
.w9583-navbtn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: transparent;
  border: none;
  color: var(--w9583-text-soft);
  font-size: 10px;
  padding: 4px 2px;
  cursor: pointer;
  position: relative;
  min-height: 48px;
  transition: color .18s ease;
}
.w9583-navbtn svg { width: 20px; height: 20px; }
.w9583-navbtn .w9583-nav-label { font-size: 10px; line-height: 1; }
.w9583-navbtn.w9583-active { color: #FFFACD; }
.w9583-navbtn.w9583-active::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 26px;
  height: 3px;
  border-radius: 0 0 4px 4px;
  background: linear-gradient(90deg, var(--w9583-brand), var(--w9583-text-soft));
}
.w9583-navbtn-promo {
  color: #FFFFFF;
}
.w9583-navbtn-promo .w9583-nav-ico {
  background: linear-gradient(135deg, var(--w9583-brand) 0%, var(--w9583-brand-deep) 100%);
  width: 30px; height: 30px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px rgba(139, 0, 139, 0.55);
  margin-top: -10px;
}
.w9583-navbtn-promo .w9583-nav-ico svg { width: 16px; height: 16px; color: #FFFFFF; }

/* ===================== Helpers ===================== */
.w9583-hide { display: none !important; }
.w9583-clearfix::after { content: ""; display: table; clear: both; }

/* Touch target safety */
button, .w9583-btn, .w9583-navbtn, .w9583-game, .w9583-chip, .w9583-promo-card {
  -webkit-tap-highlight-color: transparent;
}

/* Long-name guard for grid cells */
.w9583-game span { word-break: break-word; }
