/* phplay88 core CSS - Prefix: w8bdf- */
/* Color Palette: #212F3D bg, #FF7F50 accent1, #CCCCCC text, #DDA0DD accent2, #FFA500 accent3, #FFD700 gold */

:root {
  --bg-dark: #212F3D;
  --bg-card: #1a2530;
  --bg-light: #2a3b4a;
  --accent-coral: #FF7F50;
  --accent-plum: #DDA0DD;
  --accent-orange: #FFA500;
  --accent-gold: #FFD700;
  --text-light: #CCCCCC;
  --text-muted: #8a9baa;
  --text-white: #f0f0f0;
  --border-color: #3a4f60;
  --radius: 10px;
  --radius-sm: 6px;
  --shadow: 0 4px 15px rgba(0,0,0,0.3);
  --header-h: 60px;
  --bottom-nav-h: 62px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg-dark);
  color: var(--text-light);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

a { color: var(--accent-coral); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent-gold); }

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

/* ====== HEADER ====== */
.w8bdf-header {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--header-h);
  background: linear-gradient(135deg, var(--bg-dark) 0%, #182634 100%);
  border-bottom: 2px solid var(--accent-coral);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 12px;
  z-index: 1000;
}
.w8bdf-logo-area { display: flex; align-items: center; gap: 8px; }
.w8bdf-logo-area img { width: 36px; height: 36px; border-radius: 8px; }
.w8bdf-logo-area span { font-size: 18px; font-weight: 700; color: var(--accent-gold); letter-spacing: 0.5px; }
.w8bdf-header-btns { display: flex; gap: 8px; align-items: center; }
.w8bdf-btn-register, .w8bdf-btn-login {
  padding: 7px 16px; border-radius: 20px; border: none;
  font-size: 13px; font-weight: 600; cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}
.w8bdf-btn-register {
  background: linear-gradient(135deg, var(--accent-coral), var(--accent-orange));
  color: #fff;
}
.w8bdf-btn-login {
  background: transparent; color: var(--accent-gold);
  border: 1.5px solid var(--accent-gold);
}
.w8bdf-btn-register:hover, .w8bdf-btn-login:hover {
  transform: scale(1.05);
  box-shadow: 0 2px 10px rgba(255,127,80,0.3);
}
.w8bdf-hamburger {
  background: none; border: none; color: var(--text-light);
  font-size: 22px; cursor: pointer; padding: 4px;
  display: flex; align-items: center;
}

/* ====== MOBILE MENU ====== */
.w8bdf-menu-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 9998;
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s;
}
.w8bdf-overlay-show { opacity: 1; pointer-events: auto; }
.w8bdf-mobile-menu {
  position: fixed; top: 0; right: -280px;
  width: 280px; height: 100vh;
  background: var(--bg-dark);
  border-left: 1px solid var(--border-color);
  z-index: 9999;
  transition: right 0.3s ease;
  overflow-y: auto;
  padding: 20px 0;
}
.w8bdf-menu-open { right: 0; }
.w8bdf-menu-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 0 20px 16px;
  border-bottom: 1px solid var(--border-color);
}
.w8bdf-menu-title { font-size: 18px; font-weight: 700; color: var(--accent-gold); }
.w8bdf-menu-close { background: none; border: none; color: var(--text-light); font-size: 20px; cursor: pointer; }
.w8bdf-menu-links { list-style: none; padding: 10px 0; }
.w8bdf-menu-links li a {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 20px; color: var(--text-light);
  font-size: 14px; transition: background 0.2s, color 0.2s;
}
.w8bdf-menu-links li a:hover { background: var(--bg-light); color: var(--accent-coral); }
.w8bdf-menu-links li a i { font-size: 18px; width: 22px; text-align: center; color: var(--accent-orange); }

/* ====== MAIN CONTENT ====== */
main {
  margin-top: var(--header-h);
  padding-bottom: 20px;
}
@media (max-width: 768px) {
  main { padding-bottom: calc(var(--bottom-nav-h) + 20px); }
}

/* ====== CAROUSEL ====== */
.w8bdf-carousel {
  position: relative; width: 100%;
  max-width: 480px; margin: 0 auto;
  overflow: hidden; border-radius: 0 0 var(--radius) var(--radius);
}
.w8bdf-slide { display: none; cursor: pointer; }
.w8bdf-slide img { width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.w8bdf-dots {
  position: absolute; bottom: 10px; left: 50%;
  transform: translateX(-50%);
  display: flex; gap: 8px;
}
.w8bdf-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: rgba(255,255,255,0.4); cursor: pointer;
  transition: background 0.3s;
}
.w8bdf-dot-active { background: var(--accent-coral); }

/* ====== GAME SECTION ====== */
.w8bdf-section { padding: 20px 14px; }
.w8bdf-section-title {
  font-size: 20px; font-weight: 700; margin-bottom: 14px;
  color: var(--accent-gold);
  display: flex; align-items: center; gap: 8px;
}
.w8bdf-section-title i { color: var(--accent-coral); }

/* Game Tabs */
.w8bdf-tabs {
  display: flex; gap: 6px; overflow-x: auto;
  padding-bottom: 8px; margin-bottom: 14px;
  -webkit-overflow-scrolling: touch;
}
.w8bdf-game-tab {
  padding: 7px 14px; border-radius: 20px;
  background: var(--bg-light); color: var(--text-light);
  font-size: 12px; font-weight: 600; white-space: nowrap;
  cursor: pointer; border: 1px solid transparent;
  transition: all 0.2s;
}
.w8bdf-tab-active {
  background: var(--accent-coral); color: #fff;
  border-color: var(--accent-orange);
}

/* Game Grid */
.w8bdf-game-panel { display: none; }
.w8bdf-game-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
@media (min-width: 500px) { .w8bdf-game-grid { grid-template-columns: repeat(5, 1fr); } }
@media (min-width: 769px) { .w8bdf-game-grid { grid-template-columns: repeat(6, 1fr); } }

.w8bdf-game-card {
  background: var(--bg-card); border-radius: var(--radius-sm);
  overflow: hidden; cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  border: 1px solid var(--border-color);
}
.w8bdf-game-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(255,127,80,0.2);
}
.w8bdf-game-card img { width: 100%; aspect-ratio: 1/1; object-fit: cover; }
.w8bdf-game-card .w8bdf-game-name {
  padding: 4px 6px; font-size: 11px;
  text-align: center; color: var(--text-light);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* ====== CONTENT BLOCKS ====== */
.w8bdf-content-block {
  background: var(--bg-card); border-radius: var(--radius);
  padding: 18px 16px; margin: 14px;
  border: 1px solid var(--border-color);
}
.w8bdf-content-block h2 {
  font-size: 18px; color: var(--accent-gold);
  margin-bottom: 10px; display: flex; align-items: center; gap: 8px;
}
.w8bdf-content-block h3 {
  font-size: 15px; color: var(--accent-coral);
  margin: 12px 0 6px;
}
.w8bdf-content-block p {
  font-size: 14px; line-height: 1.7; color: var(--text-light);
  margin-bottom: 8px;
}
.w8bdf-content-block ul, .w8bdf-content-block ol {
  padding-left: 20px; margin-bottom: 10px;
}
.w8bdf-content-block li {
  font-size: 14px; line-height: 1.7; color: var(--text-light);
  margin-bottom: 4px;
}

/* ====== CTA BUTTONS ====== */
.w8bdf-cta {
  display: inline-block;
  padding: 12px 28px; border-radius: 25px;
  background: linear-gradient(135deg, var(--accent-coral), var(--accent-orange));
  color: #fff; font-size: 15px; font-weight: 700;
  border: none; cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  text-align: center;
}
.w8bdf-cta:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 20px rgba(255,127,80,0.4);
  color: #fff;
}
.w8bdf-cta-center { display: flex; justify-content: center; margin: 16px 0; }

/* ====== FEATURES GRID ====== */
.w8bdf-features {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
@media (min-width: 769px) { .w8bdf-features { grid-template-columns: repeat(3, 1fr); } }
.w8bdf-feature-item {
  background: var(--bg-light); border-radius: var(--radius-sm);
  padding: 14px 12px; text-align: center;
  border: 1px solid var(--border-color);
}
.w8bdf-feature-item i { font-size: 28px; color: var(--accent-coral); margin-bottom: 8px; }
.w8bdf-feature-item h4 { font-size: 13px; color: var(--accent-gold); margin-bottom: 4px; }
.w8bdf-feature-item p { font-size: 12px; color: var(--text-muted); }

/* ====== BOTTOM NAVIGATION ====== */
.w8bdf-bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0;
  height: var(--bottom-nav-h);
  background: linear-gradient(180deg, #1e2c38 0%, var(--bg-dark) 100%);
  border-top: 1.5px solid var(--accent-coral);
  display: flex; justify-content: space-around; align-items: center;
  z-index: 1000;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.4);
}
.w8bdf-nav-btn {
  display: flex; flex-direction: column; align-items: center;
  justify-content: center;
  min-width: 60px; min-height: 56px;
  background: none; border: none;
  color: var(--text-muted); cursor: pointer;
  transition: color 0.2s, transform 0.15s;
  padding: 4px 0;
}
.w8bdf-nav-btn i, .w8bdf-nav-btn .material-icons {
  font-size: 22px; margin-bottom: 2px;
}
.w8bdf-nav-btn span { font-size: 10px; font-weight: 500; }
.w8bdf-nav-btn:hover, .w8bdf-nav-active {
  color: var(--accent-coral);
  transform: scale(1.08);
}
@media (min-width: 769px) {
  .w8bdf-bottom-nav { display: none; }
}

/* ====== FOOTER ====== */
.w8bdf-footer {
  background: var(--bg-card); border-top: 1px solid var(--border-color);
  padding: 24px 16px 16px;
  margin-top: 20px;
}
.w8bdf-footer-brand { text-align: center; margin-bottom: 16px; }
.w8bdf-footer-brand p { font-size: 13px; color: var(--text-muted); margin-top: 6px; }
.w8bdf-footer-btns { display: flex; justify-content: center; gap: 12px; margin: 14px 0; }
.w8bdf-footer-links {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 6px 14px; margin: 12px 0;
}
.w8bdf-footer-links a { font-size: 12px; color: var(--text-muted); }
.w8bdf-footer-links a:hover { color: var(--accent-coral); }
.w8bdf-footer-copy {
  text-align: center; font-size: 11px;
  color: var(--text-muted); margin-top: 12px;
  padding-top: 12px; border-top: 1px solid var(--border-color);
}
.w8bdf-partners {
  display: flex; justify-content: center; gap: 14px;
  flex-wrap: wrap; margin: 10px 0;
}
.w8bdf-partners img { height: 22px; opacity: 0.5; filter: grayscale(0.5); }

/* ====== FAQ STYLES ====== */
.w8bdf-faq-item {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  margin-bottom: 8px; overflow: hidden;
}
.w8bdf-faq-q {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 14px; cursor: pointer;
  background: var(--bg-light); font-size: 14px;
  font-weight: 600; color: var(--text-white);
  transition: background 0.2s;
}
.w8bdf-faq-q:hover { background: var(--bg-card); }
.w8bdf-faq-icon { transition: transform 0.3s; color: var(--accent-coral); }
.w8bdf-faq-open { transform: rotate(180deg); }
.w8bdf-faq-a {
  max-height: 0; overflow: hidden;
  transition: max-height 0.3s ease;
  padding: 0 14px;
  font-size: 13px; line-height: 1.7;
  color: var(--text-light);
  background: var(--bg-card);
}
.w8bdf-faq-a-inner { padding: 12px 0; }

/* ====== HELP PAGE ====== */
.w8bdf-help-intro {
  background: linear-gradient(135deg, var(--bg-card), var(--bg-light));
  border-radius: var(--radius); padding: 20px 16px;
  margin: 14px; border: 1px solid var(--border-color);
  text-align: center;
}
.w8bdf-help-intro h2 { font-size: 18px; color: var(--accent-gold); margin-bottom: 8px; }
.w8bdf-help-intro p { font-size: 13px; color: var(--text-muted); }

.w8bdf-step-list { list-style: none; counter-reset: step; padding: 0; }
.w8bdf-step-item {
  counter-increment: step;
  display: flex; gap: 12px; align-items: flex-start;
  padding: 12px 0; border-bottom: 1px solid var(--border-color);
}
.w8bdf-step-item::before {
  content: counter(step);
  min-width: 30px; height: 30px;
  background: var(--accent-coral); color: #fff;
  border-radius: 50%; display: flex; align-items: center;
  justify-content: center; font-size: 14px; font-weight: 700;
}
.w8bdf-step-text h4 { font-size: 14px; color: var(--accent-gold); margin-bottom: 4px; }
.w8bdf-step-text p { font-size: 13px; color: var(--text-light); }

/* ====== UTILITY ====== */
.w8bdf-container { max-width: 480px; margin: 0 auto; }
@media (min-width: 769px) { .w8bdf-container { max-width: 960px; } }
.w8bdf-text-center { text-align: center; }
.w8bdf-mt-1 { margin-top: 8px; }
.w8bdf-mb-1 { margin-bottom: 8px; }
.w8bdf-hidden { display: none; }

/* ====== DESKTOP NAV ====== */
.w8bdf-desktop-nav {
  display: none;
}
@media (min-width: 769px) {
  .w8bdf-desktop-nav {
    display: flex; gap: 18px; align-items: center;
  }
  .w8bdf-desktop-nav a {
    font-size: 13px; color: var(--text-light);
    transition: color 0.2s;
  }
  .w8bdf-desktop-nav a:hover { color: var(--accent-coral); }
}
