/* ============================================================
 * kkk ph - theme-0831.css
 * Mobile-first gaming website theme. All classes use g318- prefix.
 * Palette: #0C0C0C bg | #BC8F8F accent | #BDB76B gold | #FAF0E6 text
 * ============================================================ */

:root {
  --g318-bg: #0C0C0C;
  --g318-bg-2: #151515;
  --g318-bg-3: #1f1b18;
  --g318-primary: #BC8F8F;
  --g318-gold: #BDB76B;
  --g318-text: #FAF0E6;
  --g318-text-muted: #c9bfb4;
  --g318-border: rgba(189, 183, 107, 0.25);
  --g318-danger: #d98a6a;
  --g318-success: #9fb876;
  --g318-radius: 14px;
  --g318-header-h: 56px;
  --g318-bottomnav-h: 62px;
}

* { box-sizing: border-box; }

html {
  font-size: 62.5%; /* 1rem = 10px base for rem sizing */
}

body {
  margin: 0;
  background: var(--g318-bg);
  color: var(--g318-text);
  font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.5rem;
  line-height: 1.5rem;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: var(--g318-gold); text-decoration: none; }
a:hover { color: var(--g318-primary); }
img { max-width: 100%; display: block; }

.g318-container {
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
  padding: 0 1.2rem;
}
.g318-wrapper { width: 100%; max-width: 430px; margin: 0 auto; }

/* ---------- Header ---------- */
.g318-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--g318-header-h);
  background: linear-gradient(90deg, #0C0C0C 0%, #1a1414 100%);
  border-bottom: 1px solid var(--g318-border);
  z-index: 1000;
  display: flex;
  align-items: center;
}
.g318-header-inner {
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
}
.g318-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--g318-text);
  font-weight: 800;
  font-size: 1.7rem;
  letter-spacing: 0.5px;
}
.g318-brand img { width: 28px; height: 28px; border-radius: 6px; }
.g318-brand .g318-brand-accent { color: var(--g318-gold); }

.g318-header-actions { display: flex; align-items: center; gap: 0.5rem; }
.g318-menu-btn {
  background: transparent;
  border: 1px solid var(--g318-border);
  color: var(--g318-text);
  width: 38px; height: 38px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  font-size: 1.8rem;
}

.g318-btn {
  border: none;
  border-radius: 10px;
  padding: 0.7rem 1.1rem;
  font-size: 1.3rem;
  font-weight: 700;
  cursor: pointer;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: transform 0.12s ease, opacity 0.12s ease;
}
.g318-btn:active { transform: scale(0.96); }
.g318-btn-primary {
  background: linear-gradient(135deg, var(--g318-gold), #a89f4f);
  color: #1a1414;
}
.g318-btn-outline {
  background: transparent;
  color: var(--g318-text);
  border: 1px solid var(--g318-primary);
}

/* ---------- Mobile menu (expandable) ---------- */
.g318-mobile-menu {
  position: fixed;
  top: var(--g318-header-h);
  left: 0; right: 0;
  background: #120e0e;
  border-bottom: 1px solid var(--g318-border);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.28s ease;
  z-index: 9999;
}
.g318-mobile-menu.g318-menu-open { max-height: 420px; }
.g318-mobile-menu ul {
  list-style: none;
  margin: 0; padding: 0.4rem 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.2rem;
}
.g318-mobile-menu a {
  display: block;
  padding: 1rem 1.2rem;
  color: var(--g318-text);
  font-size: 1.35rem;
  border-bottom: 1px solid rgba(189,183,107,0.08);
}
.g318-mobile-menu a:hover { background: rgba(189,143,143,0.12); color: var(--g318-gold); }

/* ---------- Main / sections ---------- */
main.g318-main {
  padding-top: calc(var(--g318-header-h) + 8px);
  padding-bottom: 1rem;
}
.g318-section { padding: 1.6rem 0; }
.g318-section-title {
  font-size: 1.9rem;
  font-weight: 800;
  margin: 0 0 1rem;
  color: var(--g318-text);
  border-left: 4px solid var(--g318-gold);
  padding-left: 0.8rem;
}
.g318-section-title small {
  display: block;
  font-size: 1.2rem;
  color: var(--g318-text-muted);
  font-weight: 500;
  margin-top: 0.2rem;
}
.g318-lead {
  font-size: 1.45rem;
  color: var(--g318-text-muted);
  line-height: 2.2rem;
  margin: 0 0 1rem;
}
.g318-text-link { color: var(--g318-gold); font-weight: 700; }
.g318-text-link:hover { text-decoration: underline; }

/* ---------- Carousel ---------- */
.g318-carousel {
  position: relative;
  border-radius: var(--g318-radius);
  overflow: hidden;
  aspect-ratio: 16 / 7;
  background: #111;
  margin-bottom: 1.2rem;
}
.g318-slide {
  position: absolute; inset: 0;
  opacity: 0;
  transition: opacity 0.5s ease;
  cursor: pointer;
}
.g318-slide.g318-slide-active { opacity: 1; }
.g318-slide img { width: 100%; height: 100%; object-fit: cover; }
.g318-slide-cap {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 1rem 1.2rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.75));
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--g318-text);
}
.g318-dots {
  position: absolute; bottom: 8px; right: 10px;
  display: flex; gap: 5px;
}
.g318-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: rgba(250,240,230,0.45);
  border: none; cursor: pointer; padding: 0;
}

/* ---------- Filter chips ---------- */
.g318-chips {
  display: flex; flex-wrap: wrap; gap: 0.5rem;
  margin-bottom: 1rem;
}
.g318-chip {
  background: #1a1414;
  border: 1px solid var(--g318-border);
  color: var(--g318-text-muted);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 1.2rem;
  cursor: pointer;
}
.g318-chip.g318-chip-active {
  background: var(--g318-gold);
  color: #1a1414;
  border-color: var(--g318-gold);
  font-weight: 700;
}

/* ---------- Game grid ---------- */
.g318-game-group { margin-bottom: 1.6rem; }
.g318-group-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 0.7rem;
}
.g318-group-head h2 {
  font-size: 1.6rem; margin: 0; color: var(--g318-gold);
  text-transform: capitalize;
}
.g318-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.6rem;
}
.g318-game-card {
  background: var(--g318-bg-2);
  border: 1px solid var(--g318-border);
  border-radius: 10px;
  padding: 0.4rem;
  text-align: center;
  cursor: pointer;
  transition: transform 0.12s ease, border-color 0.12s ease;
}
.g318-game-card:hover { transform: translateY(-2px); border-color: var(--g318-primary); }
.g318-game-card img {
  width: 100%; aspect-ratio: 1; object-fit: cover;
  border-radius: 8px;
}
.g318-game-card .g318-game-name {
  font-size: 1.05rem;
  color: var(--g318-text);
  margin-top: 0.3rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ---------- Cards / info blocks ---------- */
.g318-card {
  background: var(--g318-bg-2);
  border: 1px solid var(--g318-border);
  border-radius: var(--g318-radius);
  padding: 1.2rem;
  margin-bottom: 1rem;
}
.g318-card h3 { margin: 0 0 0.5rem; font-size: 1.5rem; color: var(--g318-primary); }
.g318-card p { margin: 0 0 0.6rem; font-size: 1.35rem; color: var(--g318-text-muted); line-height: 2.1rem; }
.g318-card ul { margin: 0; padding-left: 1.4rem; color: var(--g318-text-muted); font-size: 1.3rem; line-height: 2.1rem; }

.g318-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.6rem;
}
.g318-stat {
  background: #161010;
  border-radius: 10px;
  padding: 0.8rem;
  text-align: center;
}
.g318-stat b { display: block; font-size: 1.6rem; color: var(--g318-gold); }
.g318-stat span { font-size: 1.1rem; color: var(--g318-text-muted); }

/* ---------- Testimonials ---------- */
.g318-testi {
  background: var(--g318-bg-2);
  border-left: 3px solid var(--g318-primary);
  border-radius: 8px;
  padding: 0.9rem 1rem;
  margin-bottom: 0.7rem;
}
.g318-testi p { margin: 0 0 0.3rem; font-size: 1.3rem; color: var(--g318-text); }
.g318-testi small { color: var(--g318-gold); font-size: 1.1rem; }

/* ---------- Payment / winners rows ---------- */
.g318-row {
  display: flex; gap: 0.5rem; overflow-x: auto; padding-bottom: 0.4rem;
}
.g318-pill {
  background: #161010;
  border: 1px solid var(--g318-border);
  border-radius: 20px;
  padding: 0.5rem 0.9rem;
  font-size: 1.2rem;
  white-space: nowrap;
  color: var(--g318-text-muted);
}
.g318-winner {
  background: #161010; border-radius: 10px; padding: 0.6rem 0.8rem;
  min-width: 160px;
}
.g318-winner b { color: var(--g318-gold); font-size: 1.3rem; }
.g318-winner span { display: block; color: var(--g318-text-muted); font-size: 1.1rem; }

/* ---------- CTA banner ---------- */
.g318-cta {
  background: linear-gradient(135deg, #2a1f1f, #1a1414);
  border: 1px solid var(--g318-gold);
  border-radius: var(--g318-radius);
  padding: 1.4rem;
  text-align: center;
  margin: 1.4rem 0;
}
.g318-cta h3 { margin: 0 0 0.5rem; color: var(--g318-gold); font-size: 1.7rem; }
.g318-cta p { margin: 0 0 1rem; color: var(--g318-text-muted); font-size: 1.3rem; }
.g318-cta .g318-btn { font-size: 1.5rem; padding: 0.9rem 1.6rem; }

/* ---------- Footer ---------- */
.g318-footer {
  background: #0a0707;
  border-top: 1px solid var(--g318-border);
  padding: 1.6rem 1.2rem 2rem;
  margin-top: 1.6rem;
}
.g318-footer-inner { max-width: 430px; margin: 0 auto; }
.g318-footer p { color: var(--g318-text-muted); font-size: 1.25rem; line-height: 2rem; margin: 0 0 0.8rem; }
.g318-footer-links {
  display: flex; flex-wrap: wrap; gap: 0.4rem 0.8rem;
  margin-bottom: 0.8rem;
}
.g318-footer-links a {
  font-size: 1.2rem;
  color: var(--g318-text-muted);
  border-bottom: 1px dotted var(--g318-border);
  padding-bottom: 1px;
}
.g318-footer-links a:hover { color: var(--g318-gold); }
.g318-footer-promo {
  display: flex; flex-wrap: wrap; gap: 0.5rem;
  margin: 0.6rem 0 1rem;
}
.g318-footer-promo .g318-btn { font-size: 1.2rem; padding: 0.5rem 0.9rem; }
.g318-copy { font-size: 1.1rem; color: #6b6258; text-align: center; margin-top: 0.8rem; }

/* ---------- Bottom nav ---------- */
.g318-bottomnav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: var(--g318-bottomnav-h);
  background: linear-gradient(180deg, #14100f, #0a0707);
  border-top: 1px solid var(--g318-border);
  display: flex;
  justify-content: space-around;
  align-items: stretch;
  z-index: 1000;
}
.g318-bottomnav-btn {
  flex: 1;
  min-width: 60px;
  min-height: 60px;
  background: transparent;
  border: none;
  color: var(--g318-text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  cursor: pointer;
  font-size: 1.05rem;
  transition: color 0.15s ease, transform 0.15s ease;
}
.g318-bottomnav-btn .material-icons,
.g318-bottomnav-btn ion-icon,
.g318-bottomnav-btn i { font-size: 24px; }
.g318-bottomnav-btn:hover { color: var(--g318-gold); }
.g318-bottomnav-btn:active { transform: scale(0.92); }
.g318-bottomnav-active { color: var(--g318-gold); }
.g318-bottomnav-active::before {
  content: "";
  position: absolute;
  top: 0;
  width: 32px; height: 3px;
  background: var(--g318-gold);
  border-radius: 0 0 6px 6px;
}
.g318-bottomnav-btn { position: relative; }

/* ---------- Responsive ---------- */
@media (min-width: 769px) {
  .g318-bottomnav { display: none; }
  .g318-container, .g318-header-inner, .g318-footer-inner { max-width: 720px; }
  .g318-grid { grid-template-columns: repeat(8, 1fr); }
}
@media (max-width: 768px) {
  main.g318-main { padding-bottom: calc(var(--g318-bottomnav-h) + 12px); }
  .g318-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 360px) {
  .g318-grid { grid-template-columns: repeat(3, 1fr); }
}
