/* ============================================================
 * Spin Time - style.css
 * Mobile-first casino gaming stylesheet for Philippine players.
 * All custom classes use the w30d4- prefix for isolation.
 * Color palette: #E0FFFF (light/text) | #696969 (muted) | #2C3E50 (dark/bg)
 * ============================================================ */

:root {
  --w30d4-bg: #2C3E50;
  --w30d4-bg-deep: #1f2d3a;
  --w30d4-text: #E0FFFF;
  --w30d4-muted: #696969;
  --w30d4-accent: #FFD166;
  --w30d4-accent-2: #06d6a0;
  --w30d4-accent-3: #ef476f;
  --w30d4-card: #34495e;
  --w30d4-card-soft: #3d566e;
  --w30d4-border: rgba(224, 255, 255, 0.12);
  --w30d4-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  --w30d4-radius: 12px;
  --w30d4-header-h: 56px;
  --w30d4-bottomnav-h: 62px;
  font-size: 62.5%;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  background: var(--w30d4-bg);
  color: var(--w30d4-text);
  line-height: 1.5rem;
  font-size: 1.6rem;
  max-width: 430px;
  margin: 0 auto;
  min-height: 100vh;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--w30d4-accent); text-decoration: none; }
ul { list-style: none; }

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

/* ---------- Header ---------- */
.w30d4-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: linear-gradient(135deg, #1f2d3a 0%, #2C3E50 100%);
  border-bottom: 1px solid var(--w30d4-border);
  box-shadow: var(--w30d4-shadow);
  max-width: 430px; margin: 0 auto;
}
.w30d4-header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--w30d4-header-h); padding: 0 0.8rem 0 1rem;
}
.w30d4-logo {
  display: flex; align-items: center; gap: 0.6rem; cursor: pointer;
  color: var(--w30d4-text); font-weight: 800; font-size: 1.8rem;
}
.w30d4-logo img { width: 30px; height: 30px; border-radius: 6px; }
.w30d4-logo-text {
  background: linear-gradient(90deg, #E0FFFF, #FFD166);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.w30d4-header-actions { display: flex; align-items: center; gap: 0.4rem; }
.w30d4-btn {
  border: none; border-radius: 999px; cursor: pointer;
  font-weight: 700; font-size: 1.3rem; padding: 0.6rem 1.2rem;
  min-height: 36px; transition: transform 0.2s, opacity 0.2s;
  font-family: inherit; white-space: nowrap;
}
.w30d4-btn:active { transform: scale(0.95); }
.w30d4-btn-login {
  background: transparent; color: var(--w30d4-text);
  border: 1px solid rgba(224, 255, 255, 0.4);
}
.w30d4-btn-register {
  background: linear-gradient(135deg, #FFD166, #ef476f);
  color: #1f2d3a; box-shadow: 0 4px 12px rgba(255, 209, 102, 0.3);
}
.w30d4-menu-btn {
  background: transparent; border: none; color: var(--w30d4-text);
  font-size: 2rem; cursor: pointer; padding: 0.4rem 0.6rem;
  min-width: 44px; min-height: 44px;
  display: flex; align-items: center; justify-content: center;
}

/* ---------- Mobile slide-in menu ---------- */
.w30d4-mobile-menu {
  position: fixed; top: 0; right: -82%; bottom: 0; width: 82%; max-width: 354px;
  background: var(--w30d4-bg-deep); z-index: 9999; transition: right 0.3s ease;
  padding: 5rem 1.5rem 2rem; overflow-y: auto; border-left: 1px solid var(--w30d4-border);
}
.w30d4-mobile-menu.w30d4-menu-open { right: 0; }
.w30d4-menu-overlay {
  position: fixed; inset: 0; background: rgba(0, 0, 0, 0.6); z-index: 9998;
  opacity: 0; visibility: hidden; transition: opacity 0.3s;
}
.w30d4-menu-overlay.w30d4-overlay-show { opacity: 1; visibility: visible; }
.w30d4-menu-close {
  position: absolute; top: 0.6rem; right: 0.8rem; background: transparent;
  border: none; color: var(--w30d4-text); font-size: 2.2rem; cursor: pointer;
  min-width: 44px; min-height: 44px;
}
.w30d4-menu-section-title {
  font-size: 1.1rem; color: var(--w30d4-accent); margin: 1.6rem 0 0.4rem;
  text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700;
}
.w30d4-menu-link {
  display: block; padding: 0.9rem 0.4rem; color: var(--w30d4-text); cursor: pointer;
  border-bottom: 1px solid var(--w30d4-border); font-size: 1.4rem;
}
.w30d4-menu-link:active { background: rgba(255, 255, 255, 0.05); }
.w30d4-menu-promo {
  margin-top: 1.4rem; background: linear-gradient(135deg, #FFD166, #ef476f);
  color: #1f2d3a; text-align: center; font-weight: 800; padding: 1rem;
  border-radius: var(--w30d4-radius); cursor: pointer;
}

/* ---------- Main content ---------- */
.w30d4-main { padding-top: calc(var(--w30d4-header-h) + 1rem); padding-bottom: 2rem; }
@media (max-width: 768px) {
  .w30d4-main { padding-bottom: calc(var(--w30d4-bottomnav-h) + 1.5rem); }
}

/* ---------- Hero + Carousel ---------- */
.w30d4-hero { padding: 1rem 1.2rem 0.4rem; text-align: center; }
.w30d4-h1 {
  font-size: 2.3rem; font-weight: 800; line-height: 1.3;
  margin: 0.5rem 0; color: var(--w30d4-text);
}
.w30d4-h1 .w30d4-accent { color: var(--w30d4-accent); }
.w30d4-lead { font-size: 1.45rem; color: rgba(224, 255, 255, 0.85); margin-top: 0.6rem; }
.w30d4-hero-cta {
  display: inline-flex; align-items: center; gap: 0.5rem; margin-top: 1rem;
  background: linear-gradient(135deg, #FFD166, #ef476f); color: #1f2d3a;
  font-weight: 800; padding: 0.9rem 2rem; border-radius: 999px; font-size: 1.5rem;
  border: none; cursor: pointer; box-shadow: 0 6px 16px rgba(239, 71, 111, 0.35);
}

.w30d4-carousel {
  position: relative; width: 100%; border-radius: var(--w30d4-radius);
  overflow: hidden; margin: 1.2rem 0; box-shadow: var(--w30d4-shadow);
}
.w30d4-carousel-track { position: relative; width: 100%; aspect-ratio: 16 / 9; }
.w30d4-carousel-slide {
  position: absolute; inset: 0; opacity: 0;
  transition: opacity 0.6s ease; cursor: pointer;
}
.w30d4-carousel-slide.w30d4-slide-active { opacity: 1; }
.w30d4-carousel-slide img { width: 100%; height: 100%; object-fit: cover; }
.w30d4-carousel-caption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 1.6rem 1rem 0.8rem;
  color: #fff; background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
}
.w30d4-carousel-title { font-size: 1.7rem; font-weight: 800; }
.w30d4-carousel-sub { font-size: 1.25rem; opacity: 0.9; margin-top: 2px; }
.w30d4-carousel-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); background: rgba(0, 0, 0, 0.45);
  color: #fff; border: none; width: 34px; height: 34px; border-radius: 50%; cursor: pointer;
  font-size: 1.4rem; display: flex; align-items: center; justify-content: center;
}
.w30d4-carousel-prev { left: 8px; }
.w30d4-carousel-next { right: 8px; }
.w30d4-carousel-dots {
  position: absolute; bottom: 8px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px;
}
.w30d4-carousel-dot {
  width: 8px; height: 8px; border-radius: 50%; background: rgba(255, 255, 255, 0.5);
  cursor: pointer; border: none; padding: 0;
}
.w30d4-carousel-dot.w30d4-dot-active { background: var(--w30d4-accent); width: 22px; border-radius: 4px; }

/* ---------- Section ---------- */
.w30d4-section { padding: 1.6rem 1.2rem; }
.w30d4-section-title {
  font-size: 1.9rem; font-weight: 800; margin-bottom: 0.6rem; color: var(--w30d4-text);
  display: flex; align-items: center; gap: 0.6rem;
}
.w30d4-section-title i,
.w30d4-section-title .material-icons { color: var(--w30d4-accent); font-size: 2.2rem; }
.w30d4-section-intro { color: rgba(224, 255, 255, 0.78); font-size: 1.4rem; margin-bottom: 1rem; }

/* ---------- Filter chips ---------- */
.w30d4-filter-bar {
  display: flex; gap: 0.5rem; overflow-x: auto; padding: 0.4rem 1.2rem 0.8rem;
  -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.w30d4-filter-bar::-webkit-scrollbar { display: none; }
.w30d4-filter-chip {
  background: var(--w30d4-card); color: var(--w30d4-text); padding: 0.5rem 1rem;
  border-radius: 999px; font-size: 1.2rem; border: 1px solid var(--w30d4-border);
  cursor: pointer; white-space: nowrap; min-height: 32px; font-family: inherit;
}
.w30d4-filter-chip.w30d4-chip-active {
  background: var(--w30d4-accent); color: #1f2d3a; border-color: var(--w30d4-accent);
}

/* ---------- Game grid ---------- */
.w30d4-game-section { margin-bottom: 1.4rem; scroll-margin-top: 70px; }
.w30d4-cat-header {
  display: flex; align-items: center; justify-content: space-between;
  margin: 1.6rem 0 0.8rem; padding: 0 1.2rem;
}
.w30d4-cat-title {
  font-size: 1.7rem; font-weight: 800; color: var(--w30d4-accent);
  display: flex; align-items: center; gap: 0.5rem;
}
.w30d4-cat-title i, .w30d4-cat-title .material-icons { font-size: 1.9rem; }
.w30d4-cat-tag {
  background: rgba(255, 209, 102, 0.15); color: var(--w30d4-accent);
  padding: 0.2rem 0.7rem; border-radius: 999px; font-size: 1.05rem; font-weight: 700;
}
.w30d4-game-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.7rem; padding: 0 1.2rem; }
.w30d4-game-card {
  background: var(--w30d4-card); border-radius: 10px; overflow: hidden; cursor: pointer;
  position: relative; border: 1px solid var(--w30d4-border);
  transition: transform 0.18s, box-shadow 0.18s;
}
.w30d4-game-card:active { transform: scale(0.96); box-shadow: 0 6px 14px rgba(0, 0, 0, 0.4); }
.w30d4-game-img-wrap { position: relative; aspect-ratio: 1 / 1; overflow: hidden; }
.w30d4-game-img-wrap img { width: 100%; height: 100%; object-fit: cover; }
.w30d4-game-overlay {
  position: absolute; inset: 0; background: rgba(31, 45, 58, 0.6); opacity: 0;
  display: flex; align-items: center; justify-content: center; transition: opacity 0.2s;
}
.w30d4-game-card:active .w30d4-game-overlay,
.w30d4-game-card:hover .w30d4-game-overlay { opacity: 1; }
.w30d4-game-play-icon { color: #fff; font-size: 2.4rem; }
.w30d4-game-name {
  padding: 0.4rem 0.3rem; font-size: 1.05rem; text-align: center; color: var(--w30d4-text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600;
}

/* ---------- Cards / modules ---------- */
.w30d4-card {
  background: var(--w30d4-card); border-radius: var(--w30d4-radius);
  padding: 1.2rem; margin-bottom: 1rem; border: 1px solid var(--w30d4-border);
  box-shadow: var(--w30d4-shadow);
}
.w30d4-card-title {
  font-size: 1.6rem; font-weight: 700; margin-bottom: 0.6rem;
  color: var(--w30d4-accent); display: flex; align-items: center; gap: 0.4rem;
}
.w30d4-card-text {
  color: rgba(224, 255, 255, 0.86); font-size: 1.4rem; margin-bottom: 0.7rem;
}
.w30d4-card-text strong { color: var(--w30d4-accent); }
.w30d4-card-text a { color: var(--w30d4-accent); font-weight: 700; text-decoration: underline; cursor: pointer; }
.w30d4-card-list { padding-left: 0; }
.w30d4-card-list li {
  padding: 0.5rem 0 0.5rem 2rem; position: relative; font-size: 1.4rem;
  color: rgba(224, 255, 255, 0.85); border-bottom: 1px dashed var(--w30d4-border);
}
.w30d4-card-list li::before {
  content: '\f00c'; font-family: 'Font Awesome 6 Free'; font-weight: 900;
  position: absolute; left: 0; color: var(--w30d4-accent-2);
}
.w30d4-step-list { counter-reset: step; padding-left: 0; }
.w30d4-step-list li {
  position: relative; padding: 0.6rem 0 0.6rem 3rem; font-size: 1.4rem;
  color: rgba(224, 255, 255, 0.88); border-bottom: 1px dashed var(--w30d4-border);
}
.w30d4-step-list li::before {
  counter-increment: step; content: counter(step); position: absolute; left: 0; top: 0.6rem;
  width: 2.2rem; height: 2.2rem; background: var(--w30d4-accent); color: #1f2d3a;
  border-radius: 50%; text-align: center; font-weight: 800; font-size: 1.2rem; line-height: 2.2rem;
}

/* ---------- CTA ---------- */
.w30d4-cta {
  background: linear-gradient(135deg, #FFD166, #ef476f); color: #1f2d3a; padding: 1rem;
  border-radius: var(--w30d4-radius); text-align: center; margin: 1rem 0; cursor: pointer;
  font-weight: 800; font-size: 1.5rem; border: none; width: 100%; font-family: inherit;
  box-shadow: 0 6px 16px rgba(239, 71, 111, 0.3);
}
.w30d4-cta:active { transform: scale(0.98); }
.w30d4-text-link { color: var(--w30d4-accent); font-weight: 700; cursor: pointer; text-decoration: underline; }

/* ---------- Stats / RTP ---------- */
.w30d4-stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.7rem; }
.w30d4-stat {
  background: var(--w30d4-card); border-radius: 10px; padding: 0.9rem; text-align: center;
  border: 1px solid var(--w30d4-border);
}
.w30d4-stat-num { font-size: 1.9rem; font-weight: 800; color: var(--w30d4-accent); }
.w30d4-stat-label { font-size: 1.15rem; color: rgba(224, 255, 255, 0.7); margin-top: 2px; }

/* ---------- Testimonials ---------- */
.w30d4-testimonial {
  background: var(--w30d4-card); border-radius: 10px; padding: 0.9rem 1rem;
  margin-bottom: 0.7rem; border-left: 3px solid var(--w30d4-accent);
}
.w30d4-testimonial-name { font-weight: 700; color: var(--w30d4-accent); font-size: 1.35rem; }
.w30d4-testimonial-stars { color: #FFD166; font-size: 1.1rem; margin: 2px 0; }
.w30d4-testimonial-text { color: rgba(224, 255, 255, 0.85); font-size: 1.3rem; }

/* ---------- Payment ---------- */
.w30d4-payment-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.5rem; }
.w30d4-payment-item {
  background: var(--w30d4-card); border-radius: 8px; padding: 0.7rem 0.3rem; text-align: center;
  border: 1px solid var(--w30d4-border);
}
.w30d4-payment-item i,
.w30d4-payment-item .material-icons { font-size: 2rem; color: var(--w30d4-accent); }
.w30d4-payment-item span { display: block; font-size: 1rem; margin-top: 0.25rem; color: rgba(224, 255, 255, 0.82); }

/* ---------- Latest winners ---------- */
.w30d4-winner {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--w30d4-card); padding: 0.65rem 0.9rem; border-radius: 8px;
  margin-bottom: 0.5rem; border: 1px solid var(--w30d4-border);
}
.w30d4-winner-name { font-size: 1.25rem; font-weight: 600; }
.w30d4-winner-game { font-size: 1.05rem; color: rgba(224, 255, 255, 0.6); }
.w30d4-winner-amount { color: var(--w30d4-accent-2); font-weight: 800; font-size: 1.35rem; }

/* ---------- FAQ accordion ---------- */
.w30d4-faq-item {
  background: var(--w30d4-card); border-radius: 8px; margin-bottom: 0.6rem;
  border: 1px solid var(--w30d4-border); overflow: hidden;
}
.w30d4-faq-q {
  padding: 0.9rem 1rem; font-weight: 700; color: var(--w30d4-text); font-size: 1.35rem;
  display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; cursor: pointer;
}
.w30d4-faq-q::after {
  content: '\f078'; font-family: 'Font Awesome 6 Free'; font-weight: 900;
  color: var(--w30d4-accent); transition: transform 0.2s; font-size: 1.1rem;
}
.w30d4-faq-item.w30d4-faq-open .w30d4-faq-q::after { transform: rotate(180deg); }
.w30d4-faq-a { padding: 0 1rem 1rem; color: rgba(224, 255, 255, 0.82); font-size: 1.3rem; display: none; }
.w30d4-faq-item.w30d4-faq-open .w30d4-faq-a { display: block; }

/* ---------- Footer ---------- */
.w30d4-footer {
  background: var(--w30d4-bg-deep); padding: 2rem 1.2rem 1.4rem;
  border-top: 1px solid var(--w30d4-border); margin-top: 1rem;
}
.w30d4-footer-brand {
  display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.8rem;
}
.w30d4-footer-brand img { width: 32px; height: 32px; border-radius: 6px; }
.w30d4-footer-brand-name { font-size: 1.7rem; font-weight: 800; color: var(--w30d4-text); }
.w30d4-footer-desc { color: rgba(224, 255, 255, 0.7); font-size: 1.3rem; margin-bottom: 1rem; }
.w30d4-footer-promo { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.w30d4-footer-btn {
  background: var(--w30d4-card); color: var(--w30d4-text); padding: 0.5rem 0.9rem;
  border-radius: 999px; font-size: 1.2rem; border: 1px solid var(--w30d4-border);
  cursor: pointer; font-weight: 600; font-family: inherit;
}
.w30d4-footer-btn:active { background: var(--w30d4-card-soft); }
.w30d4-footer-links { display: flex; flex-wrap: wrap; gap: 0.6rem 1rem; margin-bottom: 1rem; }
.w30d4-footer-link { color: rgba(224, 255, 255, 0.7); font-size: 1.2rem; cursor: pointer; }
.w30d4-footer-link:hover { color: var(--w30d4-accent); }
.w30d4-copyright {
  font-size: 1.1rem; color: rgba(224, 255, 255, 0.5); text-align: center;
  border-top: 1px solid var(--w30d4-border); padding-top: 1rem;
}

/* ---------- Mobile bottom navigation ---------- */
.w30d4-bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 1000;
  background: linear-gradient(180deg, #2C3E50 0%, #1f2d3a 100%);
  border-top: 1px solid var(--w30d4-border);
  display: flex; justify-content: space-around; align-items: stretch;
  height: var(--w30d4-bottomnav-h); max-width: 430px; margin: 0 auto;
  box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.3);
}
.w30d4-bottom-btn {
  flex: 1; background: transparent; border: none; color: var(--w30d4-text);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; cursor: pointer; min-width: 60px; min-height: 60px; padding: 0.35rem;
  transition: color 0.2s; position: relative; font-family: inherit;
}
.w30d4-bottom-btn i,
.w30d4-bottom-btn .material-icons,
.w30d4-bottom-btn ion-icon { font-size: 22px; color: rgba(224, 255, 255, 0.7); }
.w30d4-bottom-btn span { font-size: 1rem; color: rgba(224, 255, 255, 0.7); }
.w30d4-bottom-btn.w30d4-active i,
.w30d4-bottom-btn.w30d4-active .material-icons,
.w30d4-bottom-btn.w30d4-active ion-icon,
.w30d4-bottom-btn.w30d4-active span { color: var(--w30d4-accent); }
.w30d4-bottom-btn.w30d4-bottom-promo i,
.w30d4-bottom-btn.w30d4-bottom-promo span,
.w30d4-bottom-btn.w30d4-bottom-promo ion-icon { color: var(--w30d4-accent-2); }
.w30d4-bottom-btn::after {
  content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 0; height: 2px; background: var(--w30d4-accent); transition: width 0.2s;
}
.w30d4-bottom-btn.w30d4-active::after { width: 28px; }
.w30d4-bottom-btn:active { transform: scale(0.94); }
.w30d4-bottom-badge {
  position: absolute; top: 4px; right: 18px; background: var(--w30d4-accent-3);
  color: #fff; font-size: 0.9rem; padding: 1px 5px; border-radius: 999px;
  min-width: 16px; text-align: center; font-weight: 700;
}

/* ---------- Back to top ---------- */
.w30d4-back-to-top {
  position: fixed; right: 1rem; bottom: calc(var(--w30d4-bottomnav-h) + 1rem);
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--w30d4-accent); color: #1f2d3a;
  border: none; cursor: pointer; font-size: 1.7rem;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: opacity 0.3s; z-index: 999;
  box-shadow: var(--w30d4-shadow);
}
.w30d4-back-to-top.w30d4-top-show { opacity: 1; visibility: visible; }

/* ---------- Scroll reveal ---------- */
.w30d4-reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.6s, transform 0.6s; }
.w30d4-reveal.w30d4-reveal-show { opacity: 1; transform: translateY(0); }

/* ---------- Desktop: hide bottom nav ---------- */
@media (min-width: 769px) {
  .w30d4-bottom-nav { display: none; }
  .w30d4-back-to-top { bottom: 2rem; }
}
