/* =========================================================
 * CM68 (cm68.homes) core stylesheet
 * All custom classes use the pg95- prefix for isolation
 * Mobile-first: target width <= 430px, scale up to desktop
 * Palette: #4169E1 / #FFFFFF / #0F0F23 / #FFF176 / #FF4500 / #FF5722
 * ========================================================= */

:root {
  --pg95-primary: #4169E1;       /* Royal blue */
  --pg95-primary-dark: #2b4fb5;
  --pg95-bg: #0F0F23;            /* Near-black navy */
  --pg95-bg-alt: #161634;
  --pg95-surface: #1d1d44;
  --pg95-surface-2: #232357;
  --pg95-text: #FFFFFF;
  --pg95-text-muted: #b9bce0;
  --pg95-accent: #FFF176;        /* Warm yellow */
  --pg95-cta: #FF4500;           /* Orange-red */
  --pg95-cta-2: #FF5722;         /* Deep orange */
  --pg95-success: #38d39f;
  --pg95-border: rgba(255,255,255,.08);
  --pg95-radius: 14px;
  --pg95-radius-sm: 10px;
  --pg95-shadow: 0 10px 24px rgba(0,0,0,.35);
  --pg95-header-h: 60px;
  --pg95-bottom-nav-h: 62px;
  font-size: 62.5%;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: "Be Vietnam Pro", "Segoe UI", Roboto, system-ui, sans-serif;
  background: radial-gradient(1200px 600px at 50% -10%, #1b1b4d 0%, var(--pg95-bg) 55%);
  color: var(--pg95-text);
  line-height: 1.5rem;
  font-size: 1.5rem;
  min-height: 100%;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 { margin: 0; line-height: 1.35; font-weight: 700; }
p { margin: 0 0 1rem; }

/* ---------- Layout helpers ---------- */
.pg95-container {
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
  padding: 0 14px;
}
.pg95-wrapper { width: 100%; }
main { padding-bottom: calc(var(--pg95-bottom-nav-h) + 24px); }

/* ---------- Header ---------- */
.pg95-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--pg95-header-h);
  z-index: 1000;
  background: linear-gradient(180deg, rgba(15,15,35,.92), rgba(15,15,35,.78));
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--pg95-border);
}
.pg95-header.pg95-is-scrolled { background: rgba(10,10,28,.96); box-shadow: var(--pg95-shadow); }
.pg95-header-inner {
  height: 100%;
  max-width: 430px;
  margin: 0 auto;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.pg95-brand { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pg95-brand-logo {
  width: 30px; height: 30px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--pg95-cta), var(--pg95-accent));
  display: grid; place-items: center;
  font-weight: 800; color: #0F0F23; font-size: 1.4rem;
  box-shadow: 0 4px 10px rgba(255,69,0,.4);
}
.pg95-brand-name { font-weight: 800; font-size: 1.7rem; letter-spacing: .5px; }
.pg95-brand-name span { color: var(--pg95-accent); }

.pg95-header-actions { display: flex; align-items: center; gap: 6px; }
.pg95-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 1.3rem;
  min-height: 36px;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.pg95-btn:active { transform: scale(.95); }
.pg95-btn-login {
  background: transparent;
  border: 1px solid var(--pg95-primary);
  color: var(--pg95-text);
}
.pg95-btn-register {
  background: linear-gradient(135deg, var(--pg95-cta), var(--pg95-cta-2));
  color: #fff;
  box-shadow: 0 6px 14px rgba(255,69,0,.35);
}
.pg95-menu-btn {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: var(--pg95-surface);
  display: grid; place-items: center;
  color: var(--pg95-text);
  border: 1px solid var(--pg95-border);
}

/* ---------- Mobile menu drawer ---------- */
.pg95-mobile-menu {
  position: fixed;
  top: 0; right: 0;
  width: 82%;
  max-width: 340px;
  height: 100vh;
  background: var(--pg95-bg-alt);
  border-left: 1px solid var(--pg95-border);
  transform: translateX(105%);
  transition: transform .28s ease;
  z-index: 9999;
  padding: 76px 18px 24px;
  overflow-y: auto;
}
.pg95-mobile-menu.pg95-is-open { transform: translateX(0); box-shadow: -16px 0 40px rgba(0,0,0,.5); }
.pg95-mobile-menu h4 { font-size: 1.4rem; color: var(--pg95-text-muted); margin: 14px 0 8px; text-transform: uppercase; letter-spacing: 1px; }
.pg95-mobile-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 12px;
  border-radius: 10px;
  font-size: 1.45rem;
  font-weight: 600;
  border: 1px solid transparent;
}
.pg95-mobile-menu a:active { background: var(--pg95-surface); border-color: var(--pg95-border); }
.pg95-mobile-menu .pg95-menu-cta { margin-top: 16px; justify-content: center; background: linear-gradient(135deg, var(--pg95-cta), var(--pg95-cta-2)); color: #fff; }
.pg95-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.55);
  opacity: 0; visibility: hidden;
  transition: opacity .25s ease;
  z-index: 9998;
}
.pg95-overlay.pg95-is-open { opacity: 1; visibility: visible; }
.pg95-no-scroll { overflow: hidden; }

/* ---------- Carousel ---------- */
.pg95-carousel {
  position: relative;
  margin-top: calc(var(--pg95-header-h) + 14px);
  border-radius: var(--pg95-radius);
  overflow: hidden;
  box-shadow: var(--pg95-shadow);
}
.pg95-carousel-track { position: relative; }
.pg95-carousel-slide {
  position: relative;
  display: none;
  cursor: pointer;
}
.pg95-carousel-slide.pg95-is-active { display: block; }
.pg95-carousel-slide img { width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.pg95-carousel-caption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 16px;
  background: linear-gradient(0deg, rgba(15,15,35,.92), rgba(15,15,35,0));
  display: flex; flex-direction: column; gap: 6px;
}
.pg95-carousel-caption strong { font-size: 1.8rem; color: var(--pg95-accent); }
.pg95-carousel-caption span { font-size: 1.3rem; color: var(--pg95-text-muted); }
.pg95-carousel-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 34px; height: 34px; border-radius: 50%;
  background: rgba(0,0,0,.45);
  color: #fff;
  display: grid; place-items: center;
  z-index: 2;
}
.pg95-carousel-arrow.pg95-prev { left: 8px; }
.pg95-carousel-arrow.pg95-next { right: 8px; }
.pg95-carousel-dots {
  position: absolute; bottom: 8px; left: 0; right: 0;
  display: flex; justify-content: center; gap: 6px; z-index: 3;
}
.pg95-carousel-dot { width: 7px; height: 7px; border-radius: 50%; background: rgba(255,255,255,.45); }
.pg95-carousel-dot.pg95-is-active { background: var(--pg95-accent); width: 18px; border-radius: 999px; }

/* ---------- Sections ---------- */
.pg95-section { padding: 26px 0 8px; }
.pg95-section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; gap: 8px; }
.pg95-section-title { font-size: 2rem; display: flex; align-items: center; gap: 8px; }
.pg95-section-title i { color: var(--pg95-accent); }
.pg95-section-sub { color: var(--pg95-text-muted); font-size: 1.3rem; }
.pg95-pill {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 1.15rem; padding: 4px 10px; border-radius: 999px;
  background: rgba(65,105,225,.18); color: #aab7ff;
}

/* ---------- Game grid ---------- */
.pg95-game-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.pg95-game-card {
  background: var(--pg95-surface);
  border: 1px solid var(--pg95-border);
  border-radius: var(--pg95-radius);
  padding: 8px;
  text-align: center;
  transition: transform .15s ease, border-color .15s ease;
  cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
}
.pg95-game-card:active { transform: scale(.96); border-color: var(--pg95-primary); }
.pg95-game-thumb {
  width: 100%; aspect-ratio: 1/1;
  object-fit: cover;
  border-radius: var(--pg95-radius-sm);
  background: #0b0b1f;
}
.pg95-game-name { font-size: 1.2rem; font-weight: 600; color: var(--pg95-text); min-height: 2.8em; line-height: 1.2; }

/* ---------- Cards / features ---------- */
.pg95-card {
  background: linear-gradient(160deg, var(--pg95-surface), var(--pg95-bg-alt));
  border: 1px solid var(--pg95-border);
  border-radius: var(--pg95-radius);
  padding: 16px;
  box-shadow: var(--pg95-shadow);
}
.pg95-card h3 { font-size: 1.6rem; margin-bottom: 6px; }
.pg95-card p { color: var(--pg95-text-muted); font-size: 1.35rem; margin-bottom: 0; }
.pg95-feature-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.pg95-feature {
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--pg95-surface); border: 1px solid var(--pg95-border);
  border-radius: var(--pg95-radius); padding: 14px;
}
.pg95-feature .pg95-icon-box {
  flex: 0 0 42px; width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center; font-size: 22px;
  background: linear-gradient(135deg, var(--pg95-primary), var(--pg95-cta));
  color: #fff;
}
.pg95-feature h4 { font-size: 1.45rem; margin-bottom: 4px; }
.pg95-feature p { margin: 0; color: var(--pg95-text-muted); font-size: 1.3rem; }

/* ---------- CTA banner ---------- */
.pg95-cta-banner {
  background: linear-gradient(135deg, var(--pg95-cta), var(--pg95-cta-2));
  border-radius: var(--pg95-radius);
  padding: 18px;
  text-align: center;
  color: #fff;
  box-shadow: 0 10px 24px rgba(255,69,0,.3);
}
.pg95-cta-banner h3 { font-size: 1.9rem; margin-bottom: 6px; }
.pg95-cta-banner p { color: rgba(255,255,255,.9); font-size: 1.3rem; margin-bottom: 12px; }
.pg95-cta-banner .pg95-btn { background: #fff; color: var(--pg95-cta); }
.pg95-text-link { color: var(--pg95-accent); font-weight: 700; border-bottom: 1px dashed rgba(255,241,118,.5); }

/* ---------- Stats / RTP ---------- */
.pg95-stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.pg95-stat {
  background: var(--pg95-surface); border: 1px solid var(--pg95-border);
  border-radius: var(--pg95-radius-sm); padding: 12px; text-align: center;
}
.pg95-stat strong { display: block; font-size: 2.2rem; color: var(--pg95-accent); }
.pg95-stat span { font-size: 1.2rem; color: var(--pg95-text-muted); }
.pg95-rtp-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 0; border-bottom: 1px dashed var(--pg95-border); font-size: 1.35rem;
}
.pg95-rtp-row:last-child { border-bottom: 0; }
.pg95-rtp-bar { flex: 0 0 90px; height: 8px; border-radius: 999px; background: rgba(255,255,255,.1); overflow: hidden; margin: 0 10px; }
.pg95-rtp-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--pg95-primary), var(--pg95-accent)); }

/* ---------- Testimonials ---------- */
.pg95-testimonial {
  background: var(--pg95-surface); border: 1px solid var(--pg95-border);
  border-radius: var(--pg95-radius); padding: 14px; margin-bottom: 10px;
}
.pg95-testimonial-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.pg95-avatar { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--pg95-primary), var(--pg95-accent)); color: #0F0F23; display: grid; place-items: center; font-weight: 700; }
.pg95-testimonial-name { font-weight: 700; font-size: 1.35rem; }
.pg95-testimonial-stars { color: var(--pg95-accent); font-size: 1.2rem; }
.pg95-testimonial p { margin: 0; color: var(--pg95-text-muted); font-size: 1.3rem; }

/* ---------- Payment / winners ---------- */
.pg95-chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.pg95-chip { background: var(--pg95-surface); border: 1px solid var(--pg95-border); border-radius: 999px; padding: 8px 12px; font-size: 1.25rem; display: inline-flex; align-items: center; gap: 6px; }
.pg95-winner-row { display: flex; align-items: center; justify-content: space-between; padding: 8px 0; border-bottom: 1px dashed var(--pg95-border); font-size: 1.3rem; }
.pg95-winner-row:last-child { border-bottom: 0; }
.pg95-winner-row b { color: var(--pg95-success); }

/* ---------- FAQ ---------- */
.pg95-faq-item {
  background: var(--pg95-surface); border: 1px solid var(--pg95-border);
  border-radius: var(--pg95-radius-sm); padding: 14px; margin-bottom: 10px; cursor: pointer;
}
.pg95-faq-q { display: flex; justify-content: space-between; gap: 10px; font-weight: 700; font-size: 1.4rem; }
.pg95-faq-q i { color: var(--pg95-accent); transition: transform .2s ease; }
.pg95-faq-a { max-height: 0; overflow: hidden; color: var(--pg95-text-muted); font-size: 1.3rem; transition: max-height .25s ease, margin .25s ease; }
.pg95-faq-item.pg95-is-open .pg95-faq-a { max-height: 320px; margin-top: 8px; }
.pg95-faq-item.pg95-is-open .pg95-faq-q i { transform: rotate(45deg); }

/* ---------- App download ---------- */
.pg95-app-card { display: flex; align-items: center; gap: 14px; background: var(--pg95-surface); border: 1px solid var(--pg95-border); border-radius: var(--pg95-radius); padding: 14px; }
.pg95-app-icon { width: 56px; height: 56px; border-radius: 14px; background: linear-gradient(135deg, var(--pg95-primary), var(--pg95-cta)); display: grid; place-items: center; font-size: 26px; color: #fff; }
.pg95-app-meta { flex: 1; }
.pg95-app-meta h4 { font-size: 1.5rem; }
.pg95-app-meta p { margin: 0; color: var(--pg95-text-muted); font-size: 1.25rem; }

/* ---------- Footer ---------- */
.pg95-footer { background: var(--pg95-bg-alt); border-top: 1px solid var(--pg95-border); padding: 24px 0 calc(var(--pg95-bottom-nav-h) + 30px); margin-top: 28px; }
.pg95-footer-brand { color: var(--pg95-text-muted); font-size: 1.3rem; margin-bottom: 14px; }
.pg95-footer-links { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.pg95-footer-links a { font-size: 1.25rem; color: var(--pg95-text-muted); padding: 4px 8px; border-radius: 6px; }
.pg95-footer-links a:hover { color: var(--pg95-accent); }
.pg95-footer-promos { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.pg95-footer-promos button { font-size: 1.3rem; padding: 8px 14px; border-radius: 999px; background: var(--pg95-surface); border: 1px solid var(--pg95-border); color: var(--pg95-text); }
.pg95-copyright { font-size: 1.2rem; color: var(--pg95-text-muted); border-top: 1px solid var(--pg95-border); padding-top: 12px; text-align: center; }

/* ---------- Mobile bottom navigation ---------- */
.pg95-bottom-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: var(--pg95-bottom-nav-h);
  background: linear-gradient(180deg, var(--pg95-bg-alt), #0a0a1c);
  border-top: 1px solid var(--pg95-border);
  display: flex;
  justify-content: space-around;
  align-items: stretch;
  z-index: 1000;
  padding-bottom: env(safe-area-inset-bottom);
}
.pg95-bottom-nav-btn {
  flex: 1;
  min-width: 60px;
  min-height: 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--pg95-text-muted);
  font-size: 1.05rem;
  position: relative;
  transition: color .15s ease;
}
.pg95-bottom-nav-btn i, .pg95-bottom-nav-btn span.material-icons-outlined, .pg95-bottom-nav-btn ion-icon { font-size: 22px; }
.pg95-bottom-nav-btn:active { transform: scale(.92); }
.pg95-bottom-nav-btn.pg95-is-current { color: var(--pg95-accent); }
.pg95-bottom-nav-btn.pg95-is-current::before {
  content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 28px; height: 3px; border-radius: 999px; background: var(--pg95-accent);
}
.pg95-bottom-nav-btn.pg95-nav-promo { color: var(--pg95-cta); }
.pg95-bottom-nav-btn.pg95-nav-promo i { background: linear-gradient(135deg, var(--pg95-cta), var(--pg95-accent)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

/* ---------- Desktop: hide bottom nav, widen container ---------- */
@media (min-width: 769px) {
  .pg95-bottom-nav { display: none; }
  main { padding-bottom: 40px; }
  .pg95-container { max-width: 960px; }
  .pg95-game-grid { grid-template-columns: repeat(6, 1fr); }
  .pg95-feature-grid { grid-template-columns: repeat(2, 1fr); }
  .pg95-stats-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (min-width: 481px) and (max-width: 768px) {
  .pg95-game-grid { grid-template-columns: repeat(4, 1fr); }
  .pg95-stats-grid { grid-template-columns: repeat(4, 1fr); }
}
