/**
 * phjion.sbs - Main Stylesheet
 * All classes use s599- prefix for namespace isolation
 * Color palette: #8A2BE2 | #212F3D | #4B0082 | #EEE8AA | #DDA0DD
 * Mobile-first responsive design
 */

/* CSS Variables */
:root {
  --s599-primary: #8A2BE2;
  --s599-bg-dark: #212F3D;
  --s599-accent: #4B0082;
  --s599-text-light: #EEE8AA;
  --s599-soft: #DDA0DD;
  --s599-white: #FFFFFF;
  --s599-black: #000000;
  --s599-gray: #B0B0B0;
  --s599-card-bg: #1A252F;
  --s599-border: rgba(138, 43, 226, 0.3);
  --s599-gradient: linear-gradient(135deg, #8A2BE2 0%, #4B0082 100%);
  --s599-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  --s599-radius: 8px;
  --s599-font: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Base Reset */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 62.5%;
  scroll-behavior: smooth;
}

body {
  font-family: var(--s599-font);
  background-color: var(--s599-bg-dark);
  color: var(--s599-white);
  line-height: 1.5rem;
  font-size: 1.4rem;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--s599-primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--s599-soft);
}

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

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

.s599-wrapper {
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
}

/* Header */
.s599-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 56px;
  background: var(--s599-bg-dark);
  border-bottom: 1px solid var(--s599-border);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem;
}

.s599-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
}

.s599-logo img {
  width: 28px;
  height: 28px;
  border-radius: 6px;
}

.s599-logo span {
  font-size: 1.8rem;
  font-weight: 700;
  background: var(--s599-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.s599-header-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.s599-btn {
  padding: 0.6rem 1.4rem;
  border: none;
  border-radius: var(--s599-radius);
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

.s599-btn-register {
  background: var(--s599-primary);
  color: var(--s599-white);
}

.s599-btn-register:hover {
  background: #9B3FE2;
  transform: scale(1.03);
}

.s599-btn-login {
  background: transparent;
  color: var(--s599-text-light);
  border: 1px solid var(--s599-primary);
}

.s599-btn-login:hover {
  background: rgba(138, 43, 226, 0.15);
}

.s599-btn-promo {
  background: var(--s599-gradient);
  color: var(--s599-white);
  padding: 1rem 2rem;
  font-size: 1.4rem;
  border-radius: 2rem;
  width: 100%;
  max-width: 280px;
  margin: 1rem auto;
  display: block;
  text-align: center;
}

.s599-btn-promo:hover {
  opacity: 0.9;
  transform: scale(1.02);
}

/* Menu Toggle */
.s599-menu-toggle {
  background: none;
  border: none;
  color: var(--s599-white);
  font-size: 2rem;
  cursor: pointer;
  padding: 0.4rem;
  line-height: 1;
}

/* Mobile Menu */
.s599-mobile-menu {
  position: fixed;
  top: 0;
  right: -280px;
  width: 280px;
  height: 100vh;
  background: var(--s599-bg-dark);
  z-index: 9999;
  transition: right 0.3s ease;
  padding: 2rem 1.5rem;
  border-left: 1px solid var(--s599-border);
  overflow-y: auto;
}

.s599-menu-active {
  right: 0 !important;
}

.s599-mobile-menu .s599-menu-close {
  background: none;
  border: none;
  color: var(--s599-white);
  font-size: 2.4rem;
  cursor: pointer;
  position: absolute;
  top: 1rem;
  right: 1.2rem;
}

.s599-mobile-menu ul {
  list-style: none;
  margin-top: 3rem;
}

.s599-mobile-menu li {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.s599-mobile-menu a {
  display: block;
  padding: 1.2rem 0;
  color: var(--s599-white);
  font-size: 1.5rem;
  transition: color 0.3s ease;
}

.s599-mobile-menu a:hover {
  color: var(--s599-primary);
}

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

.s599-overlay-active {
  display: block !important;
}

/* Carousel */
.s599-carousel {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: var(--s599-radius);
  margin-top: 1rem;
}

.s599-slide {
  display: none;
  width: 100%;
  cursor: pointer;
}

.s599-slide img {
  width: 100%;
  height: auto;
  aspect-ratio: 16/9;
  object-fit: cover;
}

.s599-slide-active {
  display: block !important;
}

.s599-carousel-dots {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
}

.s599-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: background 0.3s;
}

.s599-dot-active {
  background: var(--s599-primary) !important;
}

/* Main Content */
.s599-main {
  padding-top: 56px;
  min-height: 100vh;
}

/* Section */
.s599-section {
  padding: 2rem 0;
}

.s599-section-title {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 1.2rem;
  color: var(--s599-text-light);
  position: relative;
  padding-left: 1rem;
}

.s599-section-title::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.2rem;
  width: 4px;
  height: 80%;
  background: var(--s599-primary);
  border-radius: 2px;
}

/* Game Grid */
.s599-game-category {
  margin-bottom: 2rem;
}

.s599-game-category h2 {
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--s599-text-light);
  margin-bottom: 1rem;
  padding-left: 0.4rem;
}

.s599-game-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.8rem;
}

.s599-game-item {
  text-align: center;
  cursor: pointer;
  transition: transform 0.2s ease;
  padding: 0.4rem;
  border-radius: var(--s599-radius);
}

.s599-game-item:hover {
  transform: scale(1.05);
  background: rgba(138, 43, 226, 0.1);
}

.s599-game-item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--s599-radius);
  border: 1px solid var(--s599-border);
}

.s599-game-item span {
  display: block;
  font-size: 1.1rem;
  color: var(--s599-gray);
  margin-top: 0.3rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Cards */
.s599-card {
  background: var(--s599-card-bg);
  border-radius: var(--s599-radius);
  padding: 1.5rem;
  margin-bottom: 1rem;
  border: 1px solid var(--s599-border);
}

.s599-card h3 {
  font-size: 1.5rem;
  color: var(--s599-text-light);
  margin-bottom: 0.8rem;
}

.s599-card p {
  font-size: 1.3rem;
  color: var(--s599-gray);
  line-height: 1.8rem;
}

/* Features Grid */
.s599-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.8rem;
}

.s599-feature-item {
  background: var(--s599-card-bg);
  padding: 1.2rem;
  border-radius: var(--s599-radius);
  text-align: center;
  border: 1px solid var(--s599-border);
}

.s599-feature-item i,
.s599-feature-item .material-symbols-outlined {
  font-size: 2.4rem;
  color: var(--s599-primary);
  margin-bottom: 0.4rem;
}

.s599-feature-item h4 {
  font-size: 1.2rem;
  color: var(--s599-text-light);
  margin-bottom: 0.3rem;
}

.s599-feature-item p {
  font-size: 1.1rem;
  color: var(--s599-gray);
}

/* Testimonial */
.s599-testimonial {
  background: var(--s599-card-bg);
  border-radius: var(--s599-radius);
  padding: 1.2rem;
  margin-bottom: 0.8rem;
  border-left: 3px solid var(--s599-primary);
}

.s599-testimonial p {
  font-size: 1.2rem;
  color: var(--s599-gray);
  font-style: italic;
  margin-bottom: 0.6rem;
}

.s599-testimonial cite {
  font-size: 1.1rem;
  color: var(--s599-primary);
  font-style: normal;
  font-weight: 600;
}

/* Winners */
.s599-winner-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.s599-winner-name {
  font-size: 1.2rem;
  color: var(--s599-soft);
  font-weight: 600;
}

.s599-winner-game {
  font-size: 1.1rem;
  color: var(--s599-gray);
}

.s599-winner-amount {
  font-size: 1.3rem;
  color: var(--s599-text-light);
  font-weight: 700;
}

/* Payment */
.s599-payment-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: center;
}

.s599-payment-item {
  background: var(--s599-card-bg);
  border: 1px solid var(--s599-border);
  border-radius: var(--s599-radius);
  padding: 0.6rem 1rem;
  font-size: 1.1rem;
  color: var(--s599-gray);
}

/* RTP Table */
.s599-rtp-table {
  width: 100%;
  border-collapse: collapse;
}

.s599-rtp-table th,
.s599-rtp-table td {
  padding: 0.6rem 0.8rem;
  text-align: left;
  font-size: 1.2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.s599-rtp-table th {
  color: var(--s599-primary);
  font-weight: 600;
}

.s599-rtp-table td {
  color: var(--s599-gray);
}

/* App Download CTA */
.s599-app-cta {
  background: var(--s599-gradient);
  border-radius: var(--s599-radius);
  padding: 2rem 1.5rem;
  text-align: center;
}

.s599-app-cta h3 {
  font-size: 1.8rem;
  color: var(--s599-white);
  margin-bottom: 0.6rem;
}

.s599-app-cta p {
  font-size: 1.3rem;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 1.2rem;
}

/* Footer */
.s599-footer {
  background: #0D1520;
  padding: 2.5rem 1.2rem 1.5rem;
  border-top: 1px solid var(--s599-border);
}

.s599-footer-brand {
  font-size: 1.3rem;
  color: var(--s599-gray);
  line-height: 1.8rem;
  margin-bottom: 1.5rem;
}

.s599-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}

.s599-footer-links a {
  background: var(--s599-card-bg);
  color: var(--s599-gray);
  padding: 0.5rem 1rem;
  border-radius: 1.5rem;
  font-size: 1.1rem;
  border: 1px solid var(--s599-border);
  transition: all 0.3s ease;
}

.s599-footer-links a:hover {
  color: var(--s599-primary);
  border-color: var(--s599-primary);
}

.s599-footer-copy {
  text-align: center;
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

/* Bottom Navigation */
.s599-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 60px;
  background: #0D1520;
  border-top: 1px solid var(--s599-border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 1000;
  padding: 0 0.4rem;
}

.s599-bottom-nav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 58px;
  min-height: 54px;
  color: var(--s599-gray);
  text-decoration: none;
  transition: all 0.25s ease;
  border-radius: 8px;
  padding: 0.3rem;
}

.s599-bottom-nav a:hover,
.s599-bottom-nav a:active {
  color: var(--s599-primary);
  transform: scale(1.08);
}

.s599-bottom-nav .s599-nav-icon {
  font-size: 22px;
  margin-bottom: 2px;
}

.s599-bottom-nav .s599-nav-label {
  font-size: 1rem;
  line-height: 1.2;
}

.s599-bottom-nav .s599-nav-active {
  color: var(--s599-primary);
}

/* Promo text links */
.s599-promo-text {
  color: var(--s599-primary);
  font-weight: 600;
  cursor: pointer;
  transition: color 0.3s;
}

.s599-promo-text:hover {
  color: var(--s599-soft);
  text-decoration: underline;
}

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

/* Mobile bottom padding */
@media (max-width: 768px) {
  .s599-main {
    padding-bottom: 80px;
  }
}

/* Utility */
.s599-text-center {
  text-align: center;
}

.s599-mt-1 {
  margin-top: 1rem;
}

.s599-mb-1 {
  margin-bottom: 1rem;
}

.s599-hidden {
  display: none;
}
