/* ============================================================
   tong-its.homes - theme.css
   All custom classes use the "pg97-" prefix.
   Color palette: #273746 / #880E4F / #36454F / #BDC3C7
   Mobile-first; root font 62.5% (1rem = 10px).
   ============================================================ */

:root {
  --pg97-primary: #880E4F;       /* brand magenta */
  --pg97-bg: #273746;            /* deep slate background */
  --pg97-bg-alt: #36454F;        /* secondary surface */
  --pg97-text: #BDC3C7;          /* light grey text */
  --pg97-text-strong: #ffffff;
  --pg97-accent: #d4af37;        /* warm gold accent */
  --pg97-accent-soft: #f3d27a;
  --pg97-line: rgba(189, 195, 199, 0.18);
  --pg97-card: #314350;
  --pg97-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
  --pg97-radius: 12px;
}

/* ---------- Reset ---------- */
* { box-sizing: border-box; margin: 0; padding: 0; }
html {
  font-size: 62.5%; /* 1rem = 10px */
  -webkit-text-size-adjust: 100%;
}
body {
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  background: var(--pg97-bg);
  color: var(--pg97-text);
  font-size: 1.5rem;
  line-height: 1.5rem;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--pg97-accent-soft); text-decoration: none; }
a:hover { color: var(--pg97-text-strong); }

/* ---------- Layout primitives ---------- */
.pg97-wrapper {
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
  position: relative;
  background: var(--pg97-bg);
  min-height: 100vh;
}
.pg97-container {
  width: 100%;
  padding: 0 1.4rem;
}
.pg97-section {
  padding: 2.4rem 1.4rem;
  border-bottom: 1px solid var(--pg97-line);
}
.pg97-section-title {
  font-size: 2rem;
  font-weight: 800;
  color: var(--pg97-text-strong);
  margin-bottom: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}
.pg97-section-title i,
.pg97-section-title span.material-symbols-outlined {
  color: var(--pg97-accent);
  font-size: 2.2rem;
}
.pg97-section-sub {
  font-size: 1.35rem;
  color: var(--pg97-text);
  margin-bottom: 1.6rem;
  line-height: 2.2rem;
}
.pg97-lead {
  font-size: 1.55rem;
  color: var(--pg97-text);
  line-height: 2.4rem;
}
.pg97-strong { color: var(--pg97-text-strong); font-weight: 700; }
.pg97-magenta { color: var(--pg97-primary); }

/* ---------- Header ---------- */
.pg97-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: linear-gradient(180deg, #1d2932 0%, #273746 100%);
  border-bottom: 1px solid var(--pg97-line);
  transition: box-shadow 0.3s ease;
}
.pg97-header-scrolled { box-shadow: 0 6px 20px rgba(0,0,0,0.45); }
.pg97-header-inner {
  max-width: 430px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.7rem 1rem;
  min-height: 56px;
}
.pg97-brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--pg97-text-strong);
  font-weight: 800;
  font-size: 1.8rem;
}
.pg97-brand img { width: 30px; height: 30px; border-radius: 6px; }
.pg97-brand .pg97-brand-dot { color: var(--pg97-accent); }
.pg97-header-actions { display: flex; align-items: center; gap: 0.5rem; }
.pg97-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: none;
  cursor: pointer;
  font-weight: 700;
  border-radius: 999px;
  padding: 0.85rem 1.4rem;
  font-size: 1.35rem;
  transition: transform 0.15s ease, filter 0.2s ease;
  text-decoration: none;
  line-height: 1;
}
.pg97-btn:active { transform: scale(0.96); }
.pg97-btn-primary {
  background: linear-gradient(135deg, #a8115d 0%, #880E4F 100%);
  color: #fff;
  box-shadow: 0 4px 12px rgba(136, 14, 79, 0.4);
}
.pg97-btn-ghost {
  background: transparent;
  color: var(--pg97-text-strong);
  border: 1px solid var(--pg97-accent);
}
.pg97-btn-gold {
  background: linear-gradient(135deg, #f3d27a 0%, #d4af37 100%);
  color: #2a1d05;
}
.pg97-menu-btn {
  background: transparent;
  border: none;
  color: var(--pg97-text-strong);
  font-size: 2rem;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 8px;
}

/* ---------- Mobile slide-down menu ---------- */
.pg97-mobile-menu {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 9999;
  background: #1f2c35;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.32s ease;
  box-shadow: 0 12px 30px rgba(0,0,0,0.5);
}
.pg97-mobile-menu.pg97-menu-open { max-height: 80vh; overflow-y: auto; }
.pg97-menu-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 1.2rem 1.4rem;
  border-bottom: 1px solid var(--pg97-line);
}
.pg97-menu-head h3 { color: var(--pg97-text-strong); font-size: 1.6rem; }
.pg97-menu-close {
  background: transparent; border: none; color: var(--pg97-text-strong);
  font-size: 2rem; cursor: pointer;
}
.pg97-menu-list { padding: 0.6rem 0; list-style: none; }
.pg97-menu-list a {
  display: flex; align-items: center; gap: 1rem;
  padding: 1.2rem 1.6rem;
  color: var(--pg97-text);
  font-size: 1.5rem;
  border-left: 3px solid transparent;
  transition: background 0.15s ease, color 0.15s ease;
}
.pg97-menu-list a:hover, .pg97-menu-list a:focus {
  background: rgba(212, 175, 55, 0.08);
  color: var(--pg97-text-strong);
  border-left-color: var(--pg97-accent);
}
.pg97-menu-list a i,
.pg97-menu-list a span.material-symbols-outlined {
  color: var(--pg97-accent); font-size: 1.9rem;
}

/* ---------- Hero / Carousel ---------- */
.pg97-hero {
  margin-top: 56px;
  position: relative;
  overflow: hidden;
}
.pg97-carousel {
  position: relative;
  width: 100%;
  height: 220px;
  overflow: hidden;
}
.pg97-slide {
  position: absolute; inset: 0;
  opacity: 0;
  transition: opacity 0.6s ease;
  cursor: pointer;
}
.pg97-slide img { width: 100%; height: 220px; object-fit: cover; }
.pg97-slide.pg97-slide-active { opacity: 1; }
.pg97-slide-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(39,55,70,0.1) 0%, rgba(39,55,70,0.85) 100%);
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 1.6rem;
}
.pg97-slide-title {
  color: var(--pg97-text-strong);
  font-size: 2rem; font-weight: 800;
  margin-bottom: 0.4rem;
}
.pg97-slide-desc { color: var(--pg97-text); font-size: 1.3rem; }
.pg97-carousel-dots {
  position: absolute; bottom: 10px; left: 0; right: 0;
  display: flex; justify-content: center; gap: 6px;
  z-index: 5;
}
.pg97-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(189, 195, 199, 0.5);
  cursor: pointer; border: none;
}
.pg97-dot.pg97-dot-active { background: var(--pg97-accent); width: 22px; border-radius: 4px; }
.pg97-hero-cta {
  position: absolute; bottom: 1.6rem; right: 1.6rem; z-index: 6;
}

/* ---------- Headline ---------- */
.pg97-headline-block { padding: 2rem 1.4rem 0.6rem; text-align: center; }
.pg97-h1 {
  font-size: 2.6rem; font-weight: 900;
  color: var(--pg97-text-strong);
  line-height: 3rem;
  margin-bottom: 0.8rem;
}
.pg97-h1 span { color: var(--pg97-accent); }
.pg97-tagline { color: var(--pg97-text); font-size: 1.45rem; line-height: 2.2rem; }

/* ---------- Game grids ---------- */
.pg97-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.9rem;
}
.pg97-grid-4 { grid-template-columns: repeat(4, 1fr); }
.pg97-card {
  background: var(--pg97-card);
  border-radius: var(--pg97-radius);
  overflow: hidden;
  position: relative;
  cursor: pointer;
  border: 1px solid var(--pg97-line);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}
.pg97-card:hover, .pg97-card:active {
  transform: translateY(-2px);
  box-shadow: var(--pg97-shadow);
}
.pg97-card img {
  width: 100%; height: 92px; object-fit: cover;
}
.pg97-card-name {
  font-size: 1.15rem;
  color: var(--pg97-text);
  text-align: center;
  padding: 0.5rem 0.3rem 0.6rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pg97-card-badge {
  position: absolute; top: 4px; left: 4px;
  background: var(--pg97-primary);
  color: #fff;
  font-size: 0.95rem; font-weight: 700;
  padding: 2px 6px; border-radius: 4px;
}
.pg97-card-badge.hot { background: #c0392b; }
.pg97-card-badge.new { background: #27ae60; }

/* ---------- Filter tabs ---------- */
.pg97-filter-row {
  display: flex; gap: 0.6rem; flex-wrap: wrap;
  margin-bottom: 1.4rem;
}
.pg97-filter-tab {
  padding: 0.7rem 1.2rem;
  border-radius: 999px;
  background: var(--pg97-bg-alt);
  color: var(--pg97-text);
  font-size: 1.25rem;
  border: 1px solid var(--pg97-line);
  cursor: pointer;
}
.pg97-filter-tab.pg97-filter-active {
  background: var(--pg97-primary);
  color: #fff;
  border-color: var(--pg97-primary);
}

/* ---------- Feature / step / info blocks ---------- */
.pg97-feature-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}
.pg97-feature {
  background: var(--pg97-card);
  border-radius: var(--pg97-radius);
  padding: 1.4rem 1.2rem;
  border-left: 3px solid var(--pg97-accent);
}
.pg97-feature i, .pg97-feature .material-symbols-outlined {
  color: var(--pg97-accent); font-size: 2.4rem; margin-bottom: 0.6rem;
}
.pg97-feature h3 { color: var(--pg97-text-strong); font-size: 1.45rem; margin-bottom: 0.4rem; }
.pg97-feature p { color: var(--pg97-text); font-size: 1.25rem; line-height: 1.9rem; }

.pg97-steps { list-style: none; counter-reset: step; }
.pg97-steps li {
  position: relative;
  padding: 1rem 1rem 1rem 3.6rem;
  margin-bottom: 0.8rem;
  background: var(--pg97-card);
  border-radius: 10px;
  counter-increment: step;
  font-size: 1.3rem; color: var(--pg97-text);
  line-height: 2rem;
}
.pg97-steps li::before {
  content: counter(step);
  position: absolute; left: 1rem; top: 1rem;
  width: 2rem; height: 2rem;
  background: var(--pg97-primary);
  color: #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 1.2rem;
}

/* ---------- RTP table ---------- */
.pg97-rtp-table {
  width: 100%; border-collapse: collapse;
  background: var(--pg97-card); border-radius: 10px; overflow: hidden;
  font-size: 1.25rem;
}
.pg97-rtp-table th, .pg97-rtp-table td {
  padding: 0.9rem 0.8rem; text-align: left;
  border-bottom: 1px solid var(--pg97-line);
}
.pg97-rtp-table th { background: var(--pg97-bg-alt); color: var(--pg97-text-strong); }
.pg97-rtp-bar {
  height: 6px; background: rgba(189,195,199,0.15); border-radius: 4px; overflow: hidden;
  margin-top: 4px;
}
.pg97-rtp-bar i { display: block; height: 100%; background: var(--pg97-accent); }

/* ---------- Testimonials ---------- */
.pg97-testimonial-grid { display: grid; grid-template-columns: 1fr; gap: 1rem; }
.pg97-testimonial {
  background: var(--pg97-card); border-radius: 12px; padding: 1.4rem;
  border-top: 3px solid var(--pg97-primary);
}
.pg97-testimonial-stars { color: var(--pg97-accent); margin-bottom: 0.5rem; font-size: 1.3rem; }
.pg97-testimonial p { color: var(--pg97-text); font-size: 1.3rem; line-height: 2rem; font-style: italic; }
.pg97-testimonial-author { margin-top: 0.6rem; color: var(--pg97-text-strong); font-size: 1.2rem; font-weight: 700; }

/* ---------- Payment / winners ---------- */
.pg97-pay-row { display: flex; flex-wrap: wrap; gap: 0.8rem; }
.pg97-pay-chip {
  background: var(--pg97-card);
  border-radius: 10px;
  padding: 0.8rem 1rem;
  display: flex; align-items: center; gap: 0.6rem;
  color: var(--pg97-text); font-size: 1.25rem;
  border: 1px solid var(--pg97-line);
}
.pg97-pay-chip i, .pg97-pay-chip .material-symbols-outlined { color: var(--pg97-accent); }

.pg97-winner-list { list-style: none; }
.pg97-winner-list li {
  display: flex; align-items: center; gap: 0.8rem;
  padding: 0.8rem; border-bottom: 1px solid var(--pg97-line);
  font-size: 1.25rem;
}
.pg97-winner-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--pg97-primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 1.1rem;
}
.pg97-winner-amount { margin-left: auto; color: var(--pg97-accent); font-weight: 800; }

/* ---------- FAQ ---------- */
.pg97-faq-item {
  background: var(--pg97-card);
  border-radius: 10px;
  margin-bottom: 0.8rem;
  overflow: hidden;
  border: 1px solid var(--pg97-line);
}
.pg97-faq-q {
  width: 100%;
  background: transparent; border: none;
  text-align: left; cursor: pointer;
  padding: 1.2rem 1.4rem;
  color: var(--pg97-text-strong);
  font-size: 1.4rem; font-weight: 700;
  display: flex; justify-content: space-between; align-items: center;
}
.pg97-faq-q .pg97-faq-icon { color: var(--pg97-accent); transition: transform 0.2s ease; }
.pg97-faq-open .pg97-faq-icon { transform: rotate(45deg); }
.pg97-faq-a {
  max-height: 0; overflow: hidden;
  transition: max-height 0.3s ease;
  padding: 0 1.4rem;
  color: var(--pg97-text); font-size: 1.3rem; line-height: 2rem;
}
.pg97-faq-open .pg97-faq-a { max-height: 400px; padding: 0 1.4rem 1.2rem; }

/* ---------- Promo CTA banner ---------- */
.pg97-cta {
  background: linear-gradient(135deg, #880E4F 0%, #5e0a37 100%);
  border-radius: 14px;
  padding: 2rem 1.6rem;
  text-align: center;
  color: #fff;
}
.pg97-cta h3 { font-size: 1.9rem; margin-bottom: 0.6rem; }
.pg97-cta p { font-size: 1.3rem; margin-bottom: 1.2rem; color: rgba(255,255,255,0.9); }

/* ---------- Achievements ---------- */
.pg97-stat-row { display: flex; gap: 1rem; flex-wrap: wrap; }
.pg97-stat {
  flex: 1 1 45%;
  background: var(--pg97-card);
  border-radius: 10px; padding: 1.2rem;
  text-align: center;
}
.pg97-stat .pg97-stat-num { color: var(--pg97-accent); font-size: 2rem; font-weight: 900; }
.pg97-stat .pg97-stat-label { color: var(--pg97-text); font-size: 1.2rem; }

/* ---------- Footer ---------- */
.pg97-footer {
  background: #1c2730;
  border-top: 3px solid var(--pg97-primary);
  padding: 2.4rem 1.4rem 8rem; /* bottom space for fixed nav */
  color: var(--pg97-text);
}
.pg97-footer-brand { font-size: 1.4rem; line-height: 2.1rem; margin-bottom: 1.2rem; }
.pg97-footer-promos {
  display: flex; flex-wrap: wrap; gap: 0.6rem; margin-bottom: 1.4rem;
}
.pg97-footer-link {
  display: inline-block;
  padding: 0.5rem 0.9rem;
  background: var(--pg97-card);
  border-radius: 8px;
  font-size: 1.2rem;
  color: var(--pg97-text);
  border: 1px solid var(--pg97-line);
}
.pg97-footer-cols {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem;
  margin-bottom: 1.4rem;
}
.pg97-footer-col h4 {
  color: var(--pg97-text-strong); font-size: 1.35rem; margin-bottom: 0.7rem;
}
.pg97-footer-col a {
  display: block; padding: 0.35rem 0;
  font-size: 1.2rem; color: var(--pg97-text);
}
.pg97-footer-bottom {
  border-top: 1px solid var(--pg97-line);
  padding-top: 1.2rem;
  font-size: 1.15rem; color: var(--pg97-text); text-align: center;
}

/* ---------- Mobile bottom navigation ---------- */
.pg97-bottom-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 1000;
  background: linear-gradient(180deg, #1f2c35 0%, #162028 100%);
  border-top: 1px solid var(--pg97-line);
  display: flex;
  justify-content: space-around;
  align-items: stretch;
  height: 62px;
  box-shadow: 0 -4px 18px rgba(0,0,0,0.4);
}
.pg97-bottom-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--pg97-text);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 2px;
  cursor: pointer;
  font-size: 1rem;
  padding: 4px 2px;
  position: relative;
  transition: color 0.18s ease, transform 0.18s ease;
  min-width: 60px;
  min-height: 60px;
}
.pg97-bottom-btn i,
.pg97-bottom-btn .material-symbols-outlined,
.pg97-bottom-btn ion-icon {
  font-size: 24px;
}
.pg97-bottom-btn ion-icon { font-size: 26px; }
.pg97-bottom-btn:hover { color: var(--pg97-accent); transform: translateY(-1px); }
.pg97-bottom-btn:active { transform: scale(0.92); }
.pg97-bottom-btn.pg97-bottom-active { color: var(--pg97-accent); }
.pg97-bottom-btn.pg97-bottom-active::before {
  content: ""; position: absolute; top: 0;
  width: 28px; height: 3px; border-radius: 0 0 4px 4px;
  background: var(--pg97-accent);
}
.pg97-bottom-badge {
  position: absolute; top: 6px; right: 18px;
  background: var(--pg97-primary); color: #fff;
  font-size: 0.9rem; font-weight: 700;
  border-radius: 999px; padding: 0 5px; min-width: 16px; text-align: center;
}

/* ---------- Mobile spacing helpers ---------- */
main { padding-bottom: 80px; }
.pg97-spacer { height: 1.4rem; }
.pg97-hide-mobile { display: none; }

/* ---------- Desktop adjustments ---------- */
@media (min-width: 769px) {
  .pg97-bottom-nav { display: none; }
  main { padding-bottom: 0; }
  .pg97-wrapper { max-width: 430px; }
}
