/**
 * Jackpot 777 Philippines - Production Design System & Compliance UI
 * Built on authentic brand tokens from brand_palette.json
 */

:root {
  /* Brand Core Tokens */
  --brand-primary: #FFC107;
  --brand-primary-hover: #FFA000;
  --brand-primary-gradient: linear-gradient(135deg, #FFD700 0%, #FFA000 100%);
  --brand-secondary: #E53935;
  --brand-secondary-hover: #D32F2F;
  --brand-secondary-gradient: linear-gradient(135deg, #FF5252 0%, #D32F2F 100%);
  --brand-cta: #00E676;
  --brand-cta-hover: #00C853;
  --brand-cta-gradient: linear-gradient(135deg, #00E676 0%, #00B0FF 100%);

  /* Surfaces & Backgrounds */
  --surface-bg: #0B0E14;
  --surface-card: #141923;
  --surface-elevated: #1C2333;
  --surface-subtle: #242D40;
  --surface-glass: rgba(20, 25, 35, 0.85);

  /* Borders & Shadows */
  --border-subtle: rgba(255, 193, 7, 0.2);
  --border-glow: rgba(255, 193, 7, 0.5);
  --border-card: rgba(255, 255, 255, 0.08);
  --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 25px rgba(255, 193, 7, 0.25);
  --shadow-cta: 0 4px 15px rgba(0, 230, 118, 0.35);

  /* Typography */
  --text-primary: #FFFFFF;
  --text-secondary: #B0B8C6;
  --text-muted: #6E7A8A;
  --text-gold: #FFD54F;
  --text-emerald: #00E676;

  /* Fonts */
  --font-family-base: -apple-system, BlinkMacSystemFont, "Plus Jakarta Sans", "Inter", "Segoe UI", Roboto, sans-serif;

  /* Provider Badges Theming */
  --badge-jili-bg: rgba(225, 29, 72, 0.15);
  --badge-jili-color: #E11D48;
  --badge-jili-border: rgba(245, 158, 11, 0.4);

  --badge-fc-bg: rgba(217, 119, 6, 0.15);
  --badge-fc-color: #D97706;
  --badge-fc-border: rgba(5, 150, 105, 0.4);

  --badge-pp-bg: rgba(234, 88, 12, 0.15);
  --badge-pp-color: #EA580C;
  --badge-pp-border: rgba(124, 58, 237, 0.4);

  --badge-pg-bg: rgba(139, 92, 246, 0.15);
  --badge-pg-color: #8B5CF6;
  --badge-pg-border: rgba(251, 146, 60, 0.4);

  --badge-live-bg: rgba(37, 99, 235, 0.15);
  --badge-live-color: #2563EB;
  --badge-live-border: rgba(226, 232, 240, 0.4);

  --badge-arcade-bg: rgba(6, 182, 212, 0.15);
  --badge-arcade-color: #06B6D4;
  --badge-arcade-border: rgba(20, 184, 166, 0.4);

  /* Layout */
  --container-max-width: 1200px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 9999px;
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
}

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

html {
  font-family: var(--font-family-base);
  background-color: var(--surface-bg);
  color: var(--text-primary);
  font-size: 16px;
  line-height: 1.6;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  background-color: var(--surface-bg);
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(255, 193, 7, 0.05) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(229, 57, 53, 0.05) 0%, transparent 40%);
  background-attachment: fixed;
  overflow-x: hidden;
  width: 100%;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Typography Hierarchy */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 0.75rem;
}

h1 { font-size: clamp(1.75rem, 4vw, 2.5rem); }
h2 { font-size: clamp(1.35rem, 3vw, 1.85rem); margin-top: 1.5rem; }
h3 { font-size: clamp(1.15rem, 2.5vw, 1.35rem); margin-top: 1rem; }
p { margin-bottom: 1rem; color: var(--text-secondary); }
a { color: var(--brand-primary); text-decoration: none; transition: var(--transition-fast); }
a:hover { color: var(--brand-primary-hover); }

/* Layout Container */
.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

/* Navigation Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--surface-glass);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
  height: 72px;
  display: flex;
  align-items: center;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-logo-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-logo-img {
  width: 48px;
  height: 48px;
  object-fit: contain;
}

.brand-logo-text {
  display: none !important;
}

.nav-links-desktop {
  display: none;
  align-items: center;
  gap: 24px;
}

@media (min-width: 992px) {
  .nav-links-desktop {
    display: flex;
  }
}

.nav-link {
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  transition: var(--transition-fast);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.header-cta-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Button System */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 10px 22px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: var(--transition-base);
  border: none;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--brand-primary-gradient);
  color: #0B0E14 !important;
  border: 1px solid #FFE082;
  box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 193, 7, 0.45);
}

.btn-cta {
  background: var(--brand-cta-gradient);
  color: #0B0E14 !important;
  box-shadow: var(--shadow-cta);
}

.btn-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 22px rgba(0, 230, 118, 0.5);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary) !important;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.35);
}

/* Mobile Hamburger */
.mobile-menu-btn {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  z-index: 110;
}

@media (min-width: 992px) {
  .mobile-menu-btn { display: none; }
}

.mobile-menu-btn span {
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition-base);
}

/* Mobile Slide-Out Drawer */
.mobile-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 320px;
  height: 100vh;
  background: var(--surface-card);
  border-left: 1px solid var(--border-subtle);
  padding: 80px 24px 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  z-index: 105;
  transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.7);
}

.mobile-drawer.open {
  right: 0;
}

.drawer-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 102;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.drawer-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

/* Hero Section */
.hero-section {
  padding: 40px 0;
  position: relative;
}

.hero-banner-card {
  background: var(--surface-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 32px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: center;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

@media (min-width: 768px) {
  .hero-banner-card {
    grid-template-columns: 1.2fr 0.8fr;
    padding: 48px;
  }
}

.hero-badge-live {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(0, 230, 118, 0.15);
  color: var(--brand-cta);
  border: 1px solid rgba(0, 230, 118, 0.4);
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.hero-badge-live .pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand-cta);
  box-shadow: 0 0 8px var(--brand-cta);
}

.hero-media-wrap img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-card);
  object-fit: cover;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 24px;
}

/* Trust Bar Component */
.trust-bar {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin: 32px 0;
}

@media (min-width: 768px) {
  .trust-bar {
    grid-template-columns: repeat(4, 1fr);
  }
}

.trust-item {
  background: var(--surface-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: var(--transition-fast);
}

.trust-item:hover {
  border-color: var(--border-subtle);
  transform: translateY(-2px);
}

.trust-icon {
  font-size: 1.8rem;
  line-height: 1;
}

.trust-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
}

.trust-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Interactive Filter Chips */
.filter-chips-container {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  padding: 8px 0 16px;
  margin-bottom: 24px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.filter-chips-container::-webkit-scrollbar {
  display: none;
}

.chip-btn {
  background: var(--surface-card);
  color: var(--text-secondary);
  border: 1px solid var(--border-card);
  padding: 8px 18px;
  border-radius: var(--radius-pill);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition-fast);
}

.chip-btn:hover {
  color: var(--text-primary);
  border-color: var(--border-subtle);
}

.chip-btn.active {
  background: var(--brand-primary-gradient);
  color: #0B0E14;
  border-color: #FFE082;
  box-shadow: 0 2px 10px rgba(255, 193, 7, 0.3);
}

/* Game Grid Framework */
.games-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 20px;
  margin-bottom: 32px;
}

@media (min-width: 576px) {
  .games-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .games-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Game Card */
.game-card {
  background: var(--surface-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base);
  position: relative;
}

.game-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-glow);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5), var(--shadow-glow);
}

.game-thumb-wrap,
.game-card-media {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #000;
  overflow: hidden;
}

.game-thumb-wrap img,
.game-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.game-card:hover .game-thumb-wrap img,
.game-card:hover .game-card-media img {
  transform: scale(1.05);
}

/* Studio Badges */
.studio-badge,
.game-badge-provider {
  position: absolute;
  top: 12px;
  left: 12px;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  backdrop-filter: blur(8px);
  z-index: 2;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

.badge-jili { background: var(--badge-jili-bg); color: var(--badge-jili-color); border: 1px solid var(--badge-jili-border); }
.badge-fc { background: var(--badge-fc-bg); color: var(--badge-fc-color); border: 1px solid var(--badge-fc-border); }
.badge-pp { background: var(--badge-pp-bg); color: var(--badge-pp-color); border: 1px solid var(--badge-pp-border); }
.badge-pg { background: var(--badge-pg-bg); color: var(--badge-pg-color); border: 1px solid var(--badge-pg-border); }
.badge-live { background: var(--badge-live-bg); color: var(--badge-live-color); border: 1px solid var(--badge-live-border); }
.badge-arcade { background: var(--badge-arcade-bg); color: var(--badge-arcade-color); border: 1px solid var(--badge-arcade-border); }

/* Game Card Body */
.game-card-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.game-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.game-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
}

.game-meta-tags {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.tag-rtp {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--brand-cta);
  background: rgba(0, 230, 118, 0.12);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
}

.tag-volatility {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--brand-primary);
  background: rgba(255, 193, 7, 0.12);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
}

.game-card-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: auto;
}

.btn-card-play {
  background: var(--brand-primary-gradient);
  color: #0B0E14 !important;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 8px;
  border-radius: var(--radius-pill);
  text-align: center;
}

.btn-card-guide {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary) !important;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px;
  border-radius: var(--radius-pill);
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-card-guide:hover {
  background: rgba(255, 255, 255, 0.15);
}

/* Pagination Component */
.pagination-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 32px 0 48px;
}

.page-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--surface-card);
  color: var(--text-secondary);
  border: 1px solid var(--border-card);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition-fast);
}

.page-btn:hover {
  color: var(--text-primary);
  border-color: var(--border-subtle);
}

.page-btn.active {
  background: var(--brand-primary-gradient);
  color: #0B0E14;
  border-color: #FFE082;
}

/* 5-Column Silo Directory in Footer */
.silo-directory-section {
  background: var(--surface-card);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  padding: 48px 0;
  margin-top: 60px;
}

.directory-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 32px;
}

@media (min-width: 576px) {
  .directory-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .directory-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

.directory-column h4 {
  font-size: 1rem;
  color: var(--brand-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
  border-bottom: 2px solid var(--border-subtle);
  padding-bottom: 8px;
}

.directory-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.directory-links li a {
  color: var(--text-secondary);
  font-size: 0.88rem;
  transition: var(--transition-fast);
}

.directory-links li a:hover {
  color: var(--text-primary);
  padding-left: 4px;
}

/* Compliance Footer */
.compliance-footer {
  background: #07090D;
  padding: 40px 0 80px;
  text-align: center;
}

.payment-badges-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.payment-badge-img {
  height: 36px;
  width: auto;
  border-radius: var(--radius-sm);
  background: #FFFFFF;
  padding: 4px 8px;
}

.age-gate-badge {
  display: inline-block;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--brand-secondary);
  border: 2px solid var(--brand-secondary);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  line-height: 40px;
  margin-bottom: 16px;
}

.regulatory-statement {
  font-size: 0.82rem;
  color: var(--text-muted);
  max-width: 800px;
  margin: 0 auto 16px;
  line-height: 1.6;
}

.compliance-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.compliance-links a {
  color: var(--text-secondary);
  font-size: 0.82rem;
}

.compliance-links a:hover {
  color: var(--brand-primary);
}

/* Verified Analyst E-E-A-T Reviewer Card */
.analyst-review-card {
  background: var(--surface-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  margin: 40px 0;
  display: flex;
  align-items: flex-start;
  gap: 20px;
  box-shadow: var(--shadow-card);
}

.analyst-avatar {
  width: 64px;
  height: 64px;
  min-width: 64px;
  border-radius: 50%;
  background: var(--surface-elevated);
  border: 2px solid var(--brand-cta);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  box-shadow: 0 0 12px rgba(0, 230, 118, 0.25);
}

.analyst-info {
  flex: 1;
}

.analyst-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.analyst-bio {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 14px;
}

.analyst-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.analyst-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--brand-cta);
  background: rgba(0, 230, 118, 0.08);
  border: 1px solid rgba(0, 230, 118, 0.3);
  padding: 4px 12px;
  border-radius: var(--radius-pill);
}

@media (max-width: 640px) {
  .analyst-review-card {
    flex-direction: column;
    padding: 20px;
  }
}

