/*!
 * OK8 Homes - Core Theme Stylesheet
 * Language: Vietnamese (vi-VN)
 * Color palette: #A0522D | #8B4513 | #F5DEB3 | #273746
 * All custom classes use prefix "wd728-" for namespace isolation.
 * Comments in English per project convention.
 */

:root {
  --wd728-primary: #A0522D;
  --wd728-secondary: #8B4513;
  --wd728-accent: #F5DEB3;
  --wd728-bg: #273746;
  --wd728-bg-dark: #1c2833;
  --wd728-bg-light: #2e4053;
  --wd728-text: #F5DEB3;
  --wd728-text-light: #ffffff;
  --wd728-text-muted: #c4b896;
  --wd728-gold: #d4a843;
  --wd728-danger: #c0392b;
  --wd728-success: #27ae60;
  --wd728-header-h: 5.6rem;
  --wd728-bottomnav-h: 6.2rem;
  --wd728-radius: 1.2rem;
  --wd728-shadow: 0 .4rem 1.2rem rgba(0,0,0,.35);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 62.5%;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', 'Helvetica Neue', Arial, 'Noto Sans', sans-serif;
  background: var(--wd728-bg);
  color: var(--wd728-text);
  line-height: 1.5rem;
  font-size: 1.4rem;
  max-width: 430px;
  margin: 0 auto;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

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

.wd728-container { width: 100%; padding: 0 1.2rem; }
.wd728-wrapper { padding-top: var(--wd728-header-h); padding-bottom: calc(var(--wd728-bottomnav-h) + 1rem); }
.wd728-grid { display: grid; gap: 1rem; }

/* ============ HEADER ============ */
.wd728-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  max-width: 430px;
  margin: 0 auto;
  height: var(--wd728-header-h);
  background: linear-gradient(135deg, var(--wd728-secondary), var(--wd728-bg-dark));
  border-bottom: .2rem solid var(--wd728-gold);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.2rem;
  z-index: 1000;
  box-shadow: var(--wd728-shadow);
}

.wd728-header-brand {
  display: flex;
  align-items: center;
  gap: .8rem;
  min-width: 0;
}
.wd728-header-logo {
  width: 3rem; height: 3rem;
  border-radius: .6rem;
  background: var(--wd728-accent);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; color: var(--wd728-secondary);
  font-size: 1.6rem;
  flex-shrink: 0;
}
.wd728-header-title {
  color: var(--wd728-text-light);
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: .05rem;
  white-space: nowrap;
}
.wd728-header-title span { color: var(--wd728-gold); }

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

/* ============ BUTTONS ============ */
.wd728-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .8rem 1.4rem;
  border-radius: 2rem;
  font-weight: 700;
  font-size: 1.3rem;
  border: none;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
  min-height: 4rem;
  text-decoration: none;
}
.wd728-btn:hover { transform: translateY(-.1rem); text-decoration: none; }
.wd728-btn-register {
  background: linear-gradient(135deg, var(--wd728-gold), #e6b855);
  color: var(--wd728-bg-dark);
  box-shadow: 0 .3rem .8rem rgba(212,168,67,.4);
}
.wd728-btn-login {
  background: transparent;
  color: var(--wd728-text-light);
  border: .15rem solid var(--wd728-accent);
}
.wd728-btn-promo {
  background: linear-gradient(135deg, var(--wd728-primary), var(--wd728-secondary));
  color: var(--wd728-text-light);
  box-shadow: 0 .3rem .8rem rgba(160,82,45,.5);
}
.wd728-btn-block { display: flex; width: 100%; }

/* ============ MOBILE MENU ============ */
.wd728-mobile-menu {
  position: fixed;
  top: var(--wd728-header-h);
  left: 0; right: 0;
  max-width: 430px;
  margin: 0 auto;
  background: var(--wd728-bg-dark);
  border-bottom: .2rem solid var(--wd728-gold);
  padding: 1rem 1.2rem;
  z-index: 9999;
  transform: translateY(-130%);
  transition: transform .3s ease;
  max-height: 70vh;
  overflow-y: auto;
}
.wd728-mobile-menu.wd728-menu-open { transform: translateY(0); }
.wd728-mobile-menu a {
  display: block;
  padding: 1rem 1.2rem;
  color: var(--wd728-text);
  border-bottom: .1rem solid rgba(245,222,179,.12);
  font-size: 1.4rem;
}
.wd728-mobile-menu a:hover { background: rgba(160,82,45,.25); color: var(--wd728-gold); text-decoration: none; }
.wd728-mobile-menu a i { margin-right: .8rem; color: var(--wd728-gold); }

/* ============ CAROUSEL ============ */
.wd728-carousel {
  position: relative;
  width: 100%;
  border-radius: var(--wd728-radius);
  overflow: hidden;
  margin: 1.2rem 0;
  box-shadow: var(--wd728-shadow);
}
.wd728-carousel-track { position: relative; width: 100%; height: 18rem; }
.wd728-carousel-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity .6s ease;
  cursor: pointer;
}
.wd728-carousel-slide.wd728-active { opacity: 1; }
.wd728-carousel-slide img { width: 100%; height: 100%; object-fit: cover; }
.wd728-carousel-caption {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,.75));
  padding: 1.2rem;
  color: #fff;
  font-weight: 700;
  font-size: 1.5rem;
}
.wd728-carousel-dots {
  position: absolute;
  bottom: 1rem; left: 50%; transform: translateX(-50%);
  display: flex; gap: .5rem;
}
.wd728-carousel-dot {
  width: .8rem; height: .8rem;
  border-radius: 50%;
  background: rgba(255,255,255,.5);
  cursor: pointer;
}
.wd728-carousel-dot.wd728-active { background: var(--wd728-gold); }

/* ============ SECTIONS ============ */
.wd728-section {
  margin: 1.6rem 0;
  padding: 1.2rem;
  background: var(--wd728-bg-light);
  border-radius: var(--wd728-radius);
  box-shadow: var(--wd728-shadow);
}
.wd728-section-title {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--wd728-gold);
  margin-bottom: 1rem;
  padding-bottom: .6rem;
  border-bottom: .15rem solid var(--wd728-primary);
  display: flex; align-items: center; gap: .6rem;
}
.wd728-section-title i { font-size: 2rem; }
.wd728-section p { margin-bottom: .8rem; color: var(--wd728-text-muted); }
.wd728-section h2 { color: var(--wd728-text-light); font-size: 1.7rem; margin: 1rem 0 .6rem; }
.wd728-section h3 { color: var(--wd728-gold); font-size: 1.5rem; margin: .8rem 0 .4rem; }
.wd728-section ul { padding-left: 1.8rem; color: var(--wd728-text-muted); }
.wd728-section li { margin-bottom: .4rem; }

/* ============ HERO ============ */
.wd728-hero {
  padding: 1.6rem 1.2rem;
  text-align: center;
  background: radial-gradient(circle at top, var(--wd728-bg-light), var(--wd728-bg));
}
.wd728-hero h1 {
  font-size: 2.4rem;
  font-weight: 800;
  color: var(--wd728-gold);
  margin-bottom: .8rem;
  line-height: 1.3;
}
.wd728-hero p { color: var(--wd728-text-muted); margin-bottom: 1.2rem; }
.wd728-hero-cta { display: flex; gap: .8rem; justify-content: center; flex-wrap: wrap; }

/* ============ GAME GRID ============ */
.wd728-game-group { margin-bottom: 1.6rem; }
.wd728-group-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: .6rem .2rem;
  margin-bottom: .8rem;
}
.wd728-group-head h3 {
  font-size: 1.6rem; color: var(--wd728-gold); font-weight: 700;
  display: flex; align-items: center; gap: .5rem;
}
.wd728-group-head h3 i { color: var(--wd728-primary); }
.wd728-group-more { font-size: 1.2rem; color: var(--wd728-text-muted); }

.wd728-game-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: .8rem;
}
.wd728-game-card {
  display: flex; flex-direction: column;
  align-items: center;
  background: var(--wd728-bg-dark);
  border-radius: .8rem;
  padding: .6rem .4rem;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
  text-align: center;
}
.wd728-game-card:hover { transform: translateY(-.2rem); box-shadow: 0 .4rem 1rem rgba(160,82,45,.5); }
.wd728-game-card img {
  width: 100%; aspect-ratio: 1; object-fit: cover;
  border-radius: .6rem; margin-bottom: .4rem;
  border: .1rem solid rgba(245,222,179,.2);
}
.wd728-game-card span {
  font-size: 1rem;
  color: var(--wd728-text);
  line-height: 1.2;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ============ FEATURE CARDS ============ */
.wd728-feature-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}
.wd728-feature-card {
  background: var(--wd728-bg-dark);
  border-radius: 1rem;
  padding: 1.2rem;
  text-align: center;
  border: .1rem solid rgba(160,82,45,.3);
}
.wd728-feature-card .wd728-ic {
  font-size: 2.6rem; color: var(--wd728-gold); margin-bottom: .6rem;
}
.wd728-feature-card h3 { color: var(--wd728-text-light); font-size: 1.4rem; margin-bottom: .4rem; }
.wd728-feature-card p { color: var(--wd728-text-muted); font-size: 1.2rem; }

/* ============ TESTIMONIAL ============ */
.wd728-testimonial {
  background: var(--wd728-bg-dark);
  border-left: .3rem solid var(--wd728-gold);
  padding: 1rem 1.2rem;
  border-radius: .8rem;
  margin-bottom: .8rem;
}
.wd728-testimonial p { font-style: italic; color: var(--wd728-text); margin-bottom: .4rem; }
.wd728-testimonial .who { color: var(--wd728-gold); font-size: 1.2rem; font-weight: 700; }

/* ============ PAYMENT ============ */
.wd728-pay-row { display: flex; flex-wrap: wrap; gap: .8rem; justify-content: center; }
.wd728-pay-item {
  background: var(--wd728-bg-dark);
  border-radius: .8rem;
  padding: .8rem 1rem;
  color: var(--wd728-text-light);
  font-size: 1.2rem;
  font-weight: 600;
  border: .1rem solid rgba(245,222,179,.25);
  display: flex; align-items: center; gap: .5rem;
}

/* ============ WINNERS ============ */
.wd728-winner-row {
  display: flex; justify-content: space-between;
  padding: .6rem .8rem;
  background: var(--wd728-bg-dark);
  border-radius: .6rem;
  margin-bottom: .5rem;
  font-size: 1.2rem;
}
.wd728-winner-row .name { color: var(--wd728-text); }
.wd728-winner-row .amt { color: var(--wd728-gold); font-weight: 700; }

/* ============ CTA STRIP ============ */
.wd728-cta-strip {
  background: linear-gradient(135deg, var(--wd728-primary), var(--wd728-gold));
  padding: 1.4rem 1.2rem;
  border-radius: var(--wd728-radius);
  text-align: center;
  margin: 1.6rem 0;
  color: #fff;
}
.wd728-cta-strip h3 { font-size: 1.8rem; margin-bottom: .6rem; color: #fff; }
.wd728-cta-strip p { margin-bottom: 1rem; color: #fff; opacity: .95; }

/* ============ FOOTER ============ */
.wd728-footer {
  background: var(--wd728-bg-dark);
  padding: 1.6rem 1.2rem calc(var(--wd728-bottomnav-h) + 1.6rem);
  border-top: .2rem solid var(--wd728-primary);
  margin-top: 1.6rem;
}
.wd728-footer-brand { color: var(--wd728-text-muted); font-size: 1.2rem; margin-bottom: 1rem; line-height: 1.6; }
.wd728-footer-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: .6rem;
  margin-bottom: 1rem;
}
.wd728-footer-links a {
  color: var(--wd728-text);
  font-size: 1.2rem;
  padding: .4rem .2rem;
}
.wd728-footer-promo {
  display: flex; flex-wrap: wrap; gap: .6rem;
  margin-bottom: 1rem;
}
.wd728-footer-promo button {
  flex: 1 1 45%;
  min-height: 3.6rem;
}
.wd728-footer-copy {
  text-align: center;
  color: var(--wd728-text-muted);
  font-size: 1.1rem;
  border-top: .1rem solid rgba(245,222,179,.15);
  padding-top: .8rem;
}

/* ============ BOTTOM NAV ============ */
.wd728-bottom-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  max-width: 430px;
  margin: 0 auto;
  height: var(--wd728-bottomnav-h);
  background: linear-gradient(180deg, var(--wd728-bg-light), var(--wd728-bg-dark));
  border-top: .2rem solid var(--wd728-gold);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 1000;
  box-shadow: 0 -.3rem 1rem rgba(0,0,0,.4);
}
.wd728-bottom-nav-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--wd728-text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .2rem;
  min-width: 60px;
  min-height: 60px;
  cursor: pointer;
  padding: .4rem;
  transition: color .2s ease, transform .2s ease;
}
.wd728-bottom-nav-btn i { font-size: 2.2rem; }
.wd728-bottom-nav-btn .lbl { font-size: 1rem; }
.wd728-bottom-nav-btn:active { transform: scale(.92); }
.wd728-bottom-nav-btn:hover { color: var(--wd728-gold); }
.wd728-bottom-nav-btn.wd728-current { color: var(--wd728-gold); }
.wd728-bottom-nav-btn.wd728-current i { text-shadow: 0 0 .8rem rgba(212,168,67,.7); }
.wd728-nav-badge {
  position: absolute;
  top: .3rem; right: 1.4rem;
  background: var(--wd728-danger);
  color: #fff;
  font-size: .9rem;
  font-weight: 700;
  border-radius: 50%;
  min-width: 1.5rem; height: 1.5rem;
  display: flex; align-items: center; justify-content: center;
  padding: 0 .3rem;
}
.wd728-bottom-nav-btn { position: relative; }

/* ============ RESPONSIVE ============ */
@media (min-width: 769px) {
  .wd728-bottom-nav { display: none; }
  .wd728-footer { padding-bottom: 1.6rem; }
  .wd728-wrapper { padding-bottom: 1rem; }
}
@media (max-width: 768px) {
  .wd728-wrapper { padding-bottom: calc(var(--wd728-bottomnav-h) + 1rem); }
  main { padding-bottom: 8rem; }
}
@media (max-width: 360px) {
  .wd728-game-grid { grid-template-columns: repeat(3, 1fr); }
  .wd728-hero h1 { font-size: 2rem; }
}
