/* PH JL56 - Design Stylesheet */
/* All classes use g522- prefix */

:root {
  --g522-primary: #9932CC;
  --g522-secondary: #8B4513;
  --g522-dark: #273746;
  --g522-bg: #1a1a2e;
  --g522-bg-light: #16213e;
  --g522-bg-card: #1f2b47;
  --g522-text: #f0e6d3;
  --g522-text-light: #c4b89a;
  --g522-accent: #d4a017;
  --g522-gold: #FFD700;
  --g522-border: rgba(153, 50, 204, 0.3);
  --g522-radius: 12px;
}

/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 62.5%; scroll-behavior: smooth; }
body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; background: var(--g522-bg); color: var(--g522-text); line-height: 1.6; overflow-x: hidden; }
a { color: var(--g522-accent); text-decoration: none; transition: color 0.3s; }
a:hover { color: var(--g522-gold); }
img { max-width: 100%; height: auto; display: block; }

/* Container */
.g522-container { max-width: 430px; margin: 0 auto; padding: 0 16px; width: 100%; }

/* Header */
.g522-header { position: fixed; top: 0; left: 0; right: 0; z-index: 1000; background: linear-gradient(135deg, var(--g522-dark), var(--g522-bg-light)); border-bottom: 2px solid var(--g522-border); padding: 10px 0; }
.g522-header-inner { display: flex; align-items: center; justify-content: space-between; max-width: 430px; margin: 0 auto; padding: 0 12px; }
.g522-logo { display: flex; align-items: center; gap: 8px; }
.g522-logo img { width: 32px; height: 32px; border-radius: 6px; }
.g522-logo-text { font-size: 1.6rem; font-weight: 800; color: var(--g522-gold); letter-spacing: 1px; }
.g522-header-actions { display: flex; align-items: center; gap: 8px; }
.g522-btn { padding: 8px 16px; border: none; border-radius: 8px; font-size: 1.2rem; font-weight: 700; cursor: pointer; transition: all 0.3s; touch-action: manipulation; min-height: 36px; }
.g522-btn-register { background: linear-gradient(135deg, var(--g522-accent), #b8860b); color: var(--g522-dark); }
.g522-btn-register:hover { background: linear-gradient(135deg, var(--g522-gold), var(--g522-accent)); transform: scale(1.05); }
.g522-btn-login { background: transparent; color: var(--g522-accent); border: 2px solid var(--g522-accent); }
.g522-btn-login:hover { background: rgba(212, 160, 23, 0.15); }
.g522-menu-toggle { background: none; border: none; color: var(--g522-text); font-size: 2rem; cursor: pointer; padding: 4px; display: flex; align-items: center; }

/* Mobile Menu */
.g522-mobile-menu { position: fixed; top: 0; right: -280px; width: 280px; height: 100vh; background: var(--g522-bg-light); z-index: 9999; transition: right 0.35s ease; padding: 60px 20px 20px; border-left: 2px solid var(--g522-border); overflow-y: auto; }
.g522-menu-active { right: 0 !important; }
.g522-mobile-menu .g522-menu-close { position: absolute; top: 12px; right: 12px; background: none; border: none; color: var(--g522-text); font-size: 2.4rem; cursor: pointer; }
.g522-mobile-menu a { display: block; padding: 12px 0; font-size: 1.4rem; color: var(--g522-text-light); border-bottom: 1px solid rgba(255,255,255,0.08); transition: color 0.3s; }
.g522-mobile-menu a:hover { color: var(--g522-gold); }

/* Overlay */
.g522-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.6); z-index: 9998; display: none; }
.g522-overlay-active { display: block; }

/* Carousel */
.g522-carousel { position: relative; margin-top: 56px; overflow: hidden; border-radius: 0 0 16px 16px; }
.g522-slide { display: none; width: 100%; cursor: pointer; }
.g522-slide img { width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.g522-slide-active { display: block; }
.g522-dots { position: absolute; bottom: 10px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; }
.g522-dot { width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,0.4); cursor: pointer; border: none; }
.g522-dot-active { background: var(--g522-gold); }

/* Section */
.g522-section { padding: 24px 0; }
.g522-section-title { font-size: 2rem; font-weight: 800; color: var(--g522-gold); margin-bottom: 16px; padding-bottom: 8px; border-bottom: 2px solid var(--g522-border); }
.g522-section-subtitle { font-size: 1.6rem; font-weight: 700; color: var(--g522-accent); margin-bottom: 12px; }

/* Game Grid */
.g522-game-section { margin-bottom: 28px; }
.g522-game-category { font-size: 1.8rem; font-weight: 800; color: var(--g522-primary); margin-bottom: 12px; padding-left: 4px; text-transform: capitalize; }
.g522-game-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.g522-game-item { text-align: center; cursor: pointer; transition: transform 0.3s; }
.g522-game-item:hover { transform: scale(1.08); }
.g522-game-item img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; border: 2px solid var(--g522-border); }
.g522-game-name { font-size: 1.1rem; color: var(--g522-text-light); margin-top: 4px; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Promo CTA */
.g522-cta { background: linear-gradient(135deg, var(--g522-primary), #6a1b9a); border-radius: var(--g522-radius); padding: 20px; text-align: center; margin: 16px 0; }
.g522-cta-title { font-size: 1.8rem; font-weight: 800; color: var(--g522-gold); margin-bottom: 8px; }
.g522-cta-text { font-size: 1.3rem; color: var(--g522-text-light); margin-bottom: 14px; line-height: 1.5; }
.g522-cta-btn { display: inline-block; padding: 12px 28px; background: linear-gradient(135deg, var(--g522-gold), var(--g522-accent)); color: var(--g522-dark); font-size: 1.4rem; font-weight: 800; border-radius: 30px; cursor: pointer; border: none; transition: all 0.3s; }
.g522-cta-btn:hover { transform: scale(1.06); box-shadow: 0 4px 20px rgba(255,215,0,0.4); }

/* Content blocks */
.g522-content-block { background: var(--g522-bg-card); border-radius: var(--g522-radius); padding: 20px; margin-bottom: 16px; border: 1px solid var(--g522-border); }
.g522-content-block h2 { font-size: 1.8rem; color: var(--g522-gold); margin-bottom: 12px; }
.g522-content-block h3 { font-size: 1.5rem; color: var(--g522-primary); margin-bottom: 8px; }
.g522-content-block p { font-size: 1.3rem; line-height: 1.7; color: var(--g522-text-light); margin-bottom: 10px; }
.g522-content-block ul, .g522-content-block ol { padding-left: 20px; margin-bottom: 10px; }
.g522-content-block li { font-size: 1.3rem; line-height: 1.7; color: var(--g522-text-light); margin-bottom: 6px; }

/* Promo text link */
.g522-promo-link { color: var(--g522-gold); font-weight: 700; cursor: pointer; text-decoration: underline; transition: color 0.3s; }
.g522-promo-link:hover { color: #fff; }

/* Testimonials */
.g522-testimonial { background: var(--g522-bg-card); border-radius: var(--g522-radius); padding: 16px; margin-bottom: 12px; border-left: 4px solid var(--g522-primary); }
.g522-testimonial-text { font-size: 1.3rem; color: var(--g522-text-light); font-style: italic; margin-bottom: 8px; }
.g522-testimonial-author { font-size: 1.2rem; color: var(--g522-accent); font-weight: 700; }

/* Winner ticker */
.g522-winner-bar { background: linear-gradient(90deg, var(--g522-secondary), #5d2e0c); padding: 10px 0; overflow: hidden; margin: 16px 0; }
.g522-winner-bar span { display: inline-block; color: var(--g522-gold); font-size: 1.2rem; font-weight: 700; animation: g522scroll 18s linear infinite; white-space: nowrap; }
@keyframes g522scroll { 0% { transform: translateX(100%); } 100% { transform: translateX(-100%); } }

/* Payment icons */
.g522-payment-row { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin: 12px 0; }
.g522-payment-icon { font-size: 2.4rem; color: var(--g522-text-light); transition: color 0.3s; }
.g522-payment-icon:hover { color: var(--g522-gold); }

/* Footer */
.g522-footer { background: var(--g522-bg-light); border-top: 2px solid var(--g522-border); padding: 24px 0 32px; margin-top: 24px; }
.g522-footer-brand { font-size: 1.4rem; color: var(--g522-text-light); line-height: 1.6; margin-bottom: 16px; }
.g522-footer-links { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.g522-footer-link { padding: 6px 14px; background: rgba(153, 50, 204, 0.15); border-radius: 20px; font-size: 1.2rem; color: var(--g522-text-light); cursor: pointer; border: 1px solid var(--g522-border); transition: all 0.3s; }
.g522-footer-link:hover { background: rgba(153, 50, 204, 0.3); color: var(--g522-gold); }
.g522-footer-copy { font-size: 1.1rem; color: rgba(240,230,211,0.4); text-align: center; margin-top: 12px; }

/* Bottom Navigation */
.g522-bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; z-index: 1000; background: linear-gradient(180deg, rgba(39,55,70,0.97), rgba(26,26,46,0.99)); border-top: 2px solid var(--g522-border); padding: 6px 0 env(safe-area-inset-bottom, 6px); display: flex; justify-content: space-around; align-items: center; height: 60px; backdrop-filter: blur(10px); }
.g522-nav-item { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 60px; min-height: 48px; cursor: pointer; color: var(--g522-text-light); transition: all 0.25s; border: none; background: none; padding: 4px 8px; }
.g522-nav-item:hover { color: var(--g522-gold); }
.g522-nav-item:active { transform: scale(0.92); }
.g522-nav-item i, .g522-nav-item .material-icons { font-size: 22px; margin-bottom: 2px; }
.g522-nav-item ion-icon { font-size: 22px; margin-bottom: 2px; }
.g522-nav-label { font-size: 1rem; white-space: nowrap; }
.g522-nav-active { color: var(--g522-gold) !important; }

/* Main content padding for fixed navs */
main { padding-top: 56px; }
@media (max-width: 768px) { main { padding-bottom: 80px; } }

/* Desktop: hide bottom nav */
@media (min-width: 769px) { .g522-bottom-nav { display: none; } }

/* Responsive tweaks */
@media (max-width: 360px) {
  .g522-game-grid { grid-template-columns: repeat(3, 1fr); }
  .g522-btn { padding: 6px 10px; font-size: 1.1rem; }
}
