/* ==========================================================================
   JILI77 MOBILE APP SHELL & DESIGN SYSTEM
   Reverse-Engineered from jl-bet.ph + jili77 Brand Tokens
   ========================================================================== */

:root {
  /* Extended utility tokens */
  --border-light: rgba(255, 255, 255, 0.06);
  --text-muted: #abb8c3;
  --surface-hover: #252b3b;
  --success: #6ee7b7;
  --danger: #ef4444;
  --warning: #f59e0b;
  --radius-full: 50px;

  /* Brand Tokens extracted from jili-77.com.ph */
  --primary: #2f656b;
  --primary-dark: #1d4449;
  --secondary: #d26e4b;
  --accent: #f9ac38;
  --accent-hover: #dd9933;
  --gold: #f9ac38;
  --gold2: #dd9933;
  --glow: rgba(249, 172, 56, 0.16);

  /* Surfaces & Backgrounds */
  --bg: #14161e;
  --bg-shell: #14161e;
  --surface: #1d212d;
  --surface2: #252b3b;
  --border: rgba(255, 255, 255, 0.08);
  --border-focus: rgba(249, 172, 56, 0.4);

  /* Typography Colors */
  --text: #ffffff;
  --muted: #abb8c3;
  --text-dim: #8d9ba8;

  /* Geometry & Radii */
  --radius: 14px;
  --radius-sm: 8px;
  --radius-pill: 50px;

  /* Typography: Rank 1 authoritative domain font (Roboto) + modern system fallbacks */
  --font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Global Reset */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  background: #1a1a1a; /* Desktop outer backdrop */
  display: flex;
  justify-content: center;
  font-family: var(--font-family);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

a {
  color: var(--accent);
  text-decoration: none;
}

/* ==========================================================================
   1. Mobile App Shell Container
   ========================================================================== */
.app-shell {
  width: 100%;
  max-width: 430px; /* Centered viewport container on desktop */
  background: var(--bg-shell);
  min-height: 100vh;
  padding-bottom: 84px; /* Space for fixed bottom bar */
  position: relative;
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.85);
  display: flex;
  flex-direction: column;
}

@media (max-width: 430px) {
  .app-shell {
    max-width: 100%; /* Native mobile full viewport width */
    box-shadow: none;
  }
}

/* ==========================================================================
   2. Sticky Header (.hdr)
   ========================================================================== */
.hdr {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: rgba(15, 6, 26, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
}

.hdr .brand-logo {
  display: flex;
  align-items: center;
}

.hdr img {
  height: 32px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
  display: block;
}

.hdr-btns {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Buttons */
.btn {
  background: linear-gradient(135deg, var(--gold), var(--gold2));
  color: #000;
  padding: 8px 18px;
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: 0.84rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  text-decoration: none;
  line-height: 1.2;
}

.btn:hover {
  transform: translateY(-1.5px);
  box-shadow: 0 4px 16px var(--glow);
  color: #000;
}

.btn-login {
  background: transparent !important;
  border: 1px solid var(--gold) !important;
  color: var(--gold) !important;
}

.btn-login:hover {
  background: rgba(249, 172, 56, 0.12) !important;
  color: #fff !important;
}

.btn-lg {
  padding: 13px 32px;
  font-size: 0.98rem;
  box-shadow: 0 4px 20px var(--glow);
  width: 100%;
}

/* ==========================================================================
   3. Notification & Disclaimers (Pill Badges - ZERO HEADING TAGS)
   ========================================================================== */
.pill-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 500;
}

.pill-badge.pill-warning {
  background: rgba(255, 152, 0, 0.12);
  border-color: rgba(255, 152, 0, 0.3);
  color: #ffb74d;
}

.pill-badge.pill-success {
  background: rgba(14, 159, 110, 0.12);
  border-color: rgba(14, 159, 110, 0.3);
  color: #6ee7b7;
}

.disclaimer-bar {
  padding: 8px 16px;
  background: rgba(0, 0, 0, 0.3);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.disclaimer-bar p {
  font-size: 0.72rem;
  color: var(--text-dim);
  line-height: 1.3;
  margin: 0;
}

/* ==========================================================================
   4. Hero & Main Layout
   ========================================================================== */
.hero {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: #000;
}

.hero img {
  width: 100%;
  height: auto;
  aspect-ratio: 430/220;
  object-fit: cover;
  display: block;
}

.hero-grad {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, var(--bg-shell) 0%, rgba(20, 22, 30, 0.5) 45%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  text-align: center;
  padding: 18px 16px;
}

.hero h1 {
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9);
  line-height: 1.25;
  margin-bottom: 6px;
}

.hero .hero-tagline {
  font-size: 0.78rem;
  color: var(--muted);
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
}

.main-content {
  padding: 0 16px;
  flex: 1;
}

.tldr {
  background: var(--glow);
  border: 1px solid rgba(249, 172, 56, 0.25);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin: 16px 0;
  font-size: 0.88rem;
  line-height: 1.5;
}

.tldr b {
  color: var(--accent);
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 24px 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.section-head h2 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
}

.section-head a {
  font-size: 0.78rem;
  color: var(--accent);
  font-weight: 600;
}

/* ==========================================================================
   5. Interactive 3x2 Game Grids with Dual-Button Overlays
   ========================================================================== */
.game-grid-3x2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* 2 columns x 3 rows = 6 items on mobile */
  gap: 12px;
  margin: 14px 0 22px;
}

.game-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.game-card:hover {
  transform: translateY(-2px);
  border-color: rgba(249, 172, 56, 0.4);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.game-thumb-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16/10;
  overflow: hidden;
  background: #0d0f14;
}

.game-thumb-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.game-card:hover .game-thumb-wrapper img {
  transform: scale(1.04);
}

.game-category-tag {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(15, 6, 26, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 3px 7px;
  border-radius: 4px;
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.game-info {
  padding: 10px 10px 6px;
  display: flex;
  flex-direction: column;
}

.game-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.game-meta {
  font-size: 0.72rem;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

/* Dual-Button Overlay Actions */
.game-actions-dual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 0 10px 10px;
}

.btn-game-play {
  background: linear-gradient(135deg, var(--gold), var(--gold2));
  color: #000;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 6px 0;
  border-radius: var(--radius-pill);
  text-align: center;
  text-decoration: none;
  transition: opacity 0.2s ease, transform 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.btn-game-play:hover {
  opacity: 0.95;
  transform: translateY(-1px);
  color: #000;
}

.btn-game-guide {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 6px 0;
  border-radius: var(--radius-pill);
  text-align: center;
  text-decoration: none;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.btn-game-guide:hover {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(249, 172, 56, 0.08);
}

/* ==========================================================================
   6. 21+ Compliance & Responsible Gaming Footer Block
   ========================================================================= */
.rg-footer {
  background: #0d0f14;
  padding: 24px 16px 20px;
  text-align: center;
  border-top: 1px solid var(--border);
  margin-top: 24px;
}

.rg-badge-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
}

.rg-pill-21 {
  background: rgba(255, 152, 0, 0.16);
  border: 1px solid rgba(255, 152, 0, 0.4);
  color: #ffb74d;
  font-size: 0.76rem;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
}

.rg-desc {
  font-size: 0.72rem;
  color: var(--text-dim);
  line-height: 1.45;
  margin-bottom: 12px;
}

.rg-links {
  display: flex;
  justify-content: center;
  gap: 12px;
  font-size: 0.72rem;
}

.rg-links a {
  color: var(--muted);
}

.rg-links a:hover {
  color: var(--gold);
}

/* ==========================================================================
   7. Fixed Bottom Bar (.bottom-nav)
   ========================================================================== */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px;
  background: rgba(15, 6, 26, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  display: flex;
  justify-content: space-around;
  padding: 8px 0 12px;
  z-index: 100;
  border-top: 1px solid var(--border);
}

@media (max-width: 430px) {
  .bottom-nav {
    max-width: 100%;
  }
}

.bottom-nav .ni {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.68rem;
  font-weight: 500;
  transition: color 0.2s ease;
  gap: 3px;
  min-width: 54px;
}

.bottom-nav .ni.on,
.bottom-nav .ni:hover {
  color: var(--gold);
}

.bottom-nav .ni em {
  font-size: 1.25rem;
  font-style: normal;
  line-height: 1;
}


/* ==========================================================================
   8. Spoke Page & Component Extensions
   ========================================================================== */

/* Button Variants */
.btn-primary {
  background: linear-gradient(135deg, var(--gold), var(--gold2)) !important;
  color: #000 !important;
  font-weight: 700;
  border-radius: var(--radius-pill);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 10px var(--glow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary:hover {
  transform: translateY(-1.5px);
  box-shadow: 0 4px 18px rgba(249, 172, 56, 0.35);
  color: #000 !important;
}

.btn-secondary {
  background: var(--surface2) !important;
  color: #fff !important;
  font-weight: 600;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border) !important;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12) !important;
  color: #fff !important;
}

.btn-outline {
  background: transparent !important;
  color: var(--accent) !important;
  border: 1px solid var(--accent) !important;
  font-weight: 600;
  border-radius: var(--radius-pill);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-outline:hover {
  background: rgba(249, 172, 56, 0.12) !important;
  color: #fff !important;
}

.btn-sm {
  padding: 6px 14px !important;
  font-size: 0.78rem !important;
}

/* Header helpers */
.hdr-left {
  display: flex;
  align-items: center;
}

.hdr-logo {
  display: flex;
  align-items: center;
}

.hdr-logo img, .brand-logo img {
  height: 32px;
  width: auto;
  max-width: 124px;
  object-fit: contain;
  display: block;
}

/* Notification & Disclaimer Bars */
.notice-bar {
  padding: 8px 16px;
  background: rgba(0, 0, 0, 0.35);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}

.notice-icon {
  font-size: 0.95rem;
  line-height: 1;
}

.notice-content {
  font-size: 0.74rem;
  color: var(--muted);
  line-height: 1.35;
}

/* Badges & Indicators */
.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 6px var(--success);
  flex-shrink: 0;
  display: inline-block;
}

.warning-badge {
  background: rgba(255, 152, 0, 0.14) !important;
  border-color: rgba(255, 152, 0, 0.35) !important;
  color: #ffb74d !important;
}

.disclaimer-text {
  font-size: 0.72rem;
  color: var(--text-dim);
  line-height: 1.4;
  margin-top: 4px;
}

/* Sections & Typography */
.section {
  margin: 22px 0 16px;
}

.section-hdr {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 8px;
}

.section-hdr h2 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  padding: 8px 10px;
  font-size: 0.78rem;
  line-height: 1.4;
}

/* FAQs */
.faq-wrap {
  margin: 16px 0;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  overflow: hidden;
}

.faq-question {
  padding: 12px 14px;
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-icon {
  color: var(--accent);
  font-weight: 800;
  font-size: 1rem;
  transition: transform 0.2s ease;
}

details[open] .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  padding: 0 14px 12px;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.5;
}

/* Bottom Nav nav-tab variant */
.nav-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.68rem;
  font-weight: 500;
  gap: 3px;
  flex: 1;
  padding: 4px 0;
  transition: color 0.15s ease;
  min-height: 44px;
}

.nav-tab .tab-icon {
  font-size: 1.25rem;
  line-height: 1;
}

.nav-tab.active,
.nav-tab:hover {
  color: var(--gold);
}

.nav-tab.tab-cta {
  color: #000;
}

.nav-tab.tab-cta .tab-pill {
  background: linear-gradient(135deg, var(--gold), var(--gold2));
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: 800;
  box-shadow: 0 2px 10px var(--glow);
  color: #000;
}

/* Footer-shell variant */
.footer-shell {
  background: #0d0f14;
  padding: 24px 16px 20px;
  text-align: center;
  border-top: 1px solid var(--border);
  margin-top: 24px;
}

.footer-rg-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
}

.footer-disclaimer {
  font-size: 0.72rem;
  color: var(--text-dim);
  line-height: 1.45;
  margin-bottom: 12px;
}

.footer-links, .footer-trust-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  font-size: 0.72rem;
}

.footer-links a, .footer-trust-links a {
  color: var(--muted);
  text-decoration: none;
}

.footer-links a:hover, .footer-trust-links a:hover {
  color: var(--gold);
}

/* Strict Safeguard: Age Gate Modal MUST NEVER leak unstyled */
.age-gate-overlay, #age-gate-modal {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}
