/* me88 - Trusted Online Casino Malaysia */
:root {
  --primary: #ff4e00;
  --primary-hover: #e64500;
  --secondary: #f88c00;
  --bg-dark: #0f0f10;
  --bg-card: #1a1a1c;
  --bg-nav: #111113;
  --text-white: #ffffff;
  --text-muted: #9da5b7;
  --text-light: #c8cdd8;
  --border: #2a2a30;
  --gold: #ffd700;
  --radius: 8px;
  --transition: 0.25s ease;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Segoe UI', 'Noto Sans', Arial, sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-white);
  font-size: 15px;
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

img { max-width: 100%; height: auto; display: block; }

ul { list-style: none; }

/* ===== HEADER / NAVBAR ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg-nav);
  border-bottom: 1px solid var(--border);
  padding: 0 20px;
}

.nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  height: 64px;
  gap: 20px;
}

.logo-link img {
  height: 40px;
  width: auto;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
}

.main-nav a {
  padding: 8px 14px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-light);
  transition: color var(--transition), background var(--transition);
  white-space: nowrap;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--primary);
  background: rgba(255, 78, 0, 0.08);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 22px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
}

.btn-outline {
  background: transparent;
  border: 1.5px solid var(--primary);
  color: var(--primary);
}
.btn-outline:hover { background: rgba(255,78,0,0.1); }

.btn-primary {
  background: var(--primary);
  color: #fff;
}
.btn-primary:hover { background: var(--primary-hover); transform: translateY(-1px); }

.btn-lg {
  padding: 13px 32px;
  font-size: 16px;
  border-radius: 10px;
}

.btn-secondary {
  background: var(--secondary);
  color: #fff;
}
.btn-secondary:hover { background: #e07d00; }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-white);
  border-radius: 2px;
  transition: var(--transition);
}

/* ===== MOBILE NAV ===== */
.mobile-nav {
  display: none;
  flex-direction: column;
  background: var(--bg-nav);
  border-top: 1px solid var(--border);
  padding: 12px 20px 20px;
  gap: 4px;
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  padding: 11px 14px;
  border-radius: var(--radius);
  font-size: 15px;
  color: var(--text-light);
  transition: color var(--transition), background var(--transition);
}
.mobile-nav a:hover, .mobile-nav a.active { color: var(--primary); background: rgba(255,78,0,0.08); }
.mobile-nav .btn { margin-top: 6px; width: 100%; }

/* ===== HERO BANNER SLIDER ===== */
.hero-slider {
  position: relative;
  overflow: hidden;
  background: #000;
  max-height: 480px;
}

.slides-wrapper {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.slide {
  min-width: 100%;
  position: relative;
}

.slide img {
  width: 100%;
  height: 480px;
  object-fit: cover;
  object-position: center;
}

.slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,0.55) 0%, transparent 60%);
  display: flex;
  align-items: center;
  padding: 0 60px;
}

.slide-content {
  max-width: 520px;
}
.slide-content h2 {
  font-size: clamp(22px, 3vw, 38px);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 12px;
  text-shadow: 0 2px 10px rgba(0,0,0,0.4);
}
.slide-content p {
  font-size: 16px;
  color: var(--text-light);
  margin-bottom: 24px;
}

.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,78,0,0.7);
  color: #fff;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  z-index: 10;
  transition: background var(--transition);
  display: flex; align-items: center; justify-content: center;
}
.slider-btn:hover { background: var(--primary); }
.slider-btn.prev { left: 16px; }
.slider-btn.next { right: 16px; }

.slider-dots {
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}
.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}
.dot.active {
  background: var(--primary);
  transform: scale(1.3);
}

/* ===== MARQUEE ANNOUNCEMENT ===== */
.marquee-bar {
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 8px 0;
  overflow: hidden;
}
.marquee-inner {
  display: flex;
  gap: 60px;
  animation: marquee 35s linear infinite;
  white-space: nowrap;
}
.marquee-inner span {
  font-size: 13px;
  color: var(--text-muted);
}
.marquee-inner span strong { color: var(--primary); }
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ===== SECTION ===== */
.section {
  padding: 56px 20px;
  max-width: 1280px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 36px;
}

.section-header h2 {
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 800;
  margin-bottom: 8px;
}

.section-header p {
  color: var(--text-muted);
  font-size: 15px;
  max-width: 560px;
  margin: 0 auto;
}

.section-label {
  display: inline-block;
  background: rgba(255,78,0,0.12);
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 10px;
}

/* ===== GAME CATEGORIES ===== */
.categories-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

.category-card {
  flex: 1 1 180px;
  max-width: 240px;
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
  aspect-ratio: 4/3;
}
.category-card:hover { transform: translateY(-4px); box-shadow: 0 12px 32px rgba(255,78,0,0.2); }

.category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.category-card:hover img { transform: scale(1.05); }

.category-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, transparent 60%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding: 16px;
  text-align: center;
}
.category-overlay h3 { font-size: 17px; font-weight: 700; margin-bottom: 4px; }
.category-overlay span { font-size: 12px; color: var(--primary); font-weight: 600; }

/* ===== GAME CARDS GRID ===== */
.games-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}

.game-card {
  flex: 1 1 160px;
  max-width: 220px;
  background: var(--bg-card);
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
  border: 1px solid var(--border);
}
.game-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,0.4); }

.game-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.game-card-info {
  padding: 10px 12px;
}
.game-card-info h4 {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.game-card-info span {
  font-size: 11px;
  color: var(--text-muted);
}

.game-badge {
  position: relative;
}
.game-badge::before {
  content: attr(data-badge);
  position: absolute;
  top: 8px;
  left: 8px;
  background: var(--primary);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
  z-index: 2;
  text-transform: uppercase;
}

/* ===== PROMOTION CARDS ===== */
.promo-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
}

.promo-card {
  flex: 1 1 280px;
  max-width: 380px;
  background: var(--bg-card);
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  transition: transform var(--transition), box-shadow var(--transition);
}
.promo-card:hover { transform: translateY(-3px); box-shadow: 0 10px 28px rgba(255,78,0,0.15); }

.promo-card img {
  width: 100%;
  aspect-ratio: 16/7;
  object-fit: cover;
}

.promo-card-body {
  padding: 18px 20px;
}
.promo-card-body h3 { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.promo-card-body p { font-size: 13px; color: var(--text-muted); margin-bottom: 14px; line-height: 1.55; }
.promo-tag {
  display: inline-block;
  background: rgba(255,78,0,0.12);
  color: var(--primary);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 4px;
  text-transform: uppercase;
  margin-bottom: 10px;
}

/* ===== STATS / TRUST BAR ===== */
.stats-bar {
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.stats-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  divide-x: 1px solid var(--border);
  padding: 28px 20px;
  gap: 20px;
  text-align: center;
}
.stat-item h3 { font-size: clamp(22px, 3vw, 34px); font-weight: 800; color: var(--primary); }
.stat-item p { font-size: 13px; color: var(--text-muted); margin-top: 4px; }

/* ===== WHY CHOOSE ===== */
.features-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
}

.feature-card {
  flex: 1 1 180px;
  max-width: 220px;
  background: var(--bg-card);
  border-radius: 12px;
  padding: 24px 16px;
  border: 1px solid var(--border);
  transition: border-color var(--transition);
  text-align: center;
}
.feature-card:hover { border-color: var(--primary); }

.tab-pane .feature-card { padding: 14px 12px; max-width: none; flex: none; }
.tab-pane .feature-icon { width: 44px; height: 44px; font-size: 22px; margin-bottom: 10px; }
.tab-pane .feature-card h3 { font-size: 14px; margin-bottom: 4px; }
.tab-pane .feature-card p { font-size: 12px; }

.feature-icon {
  width: 56px;
  height: 56px;
  background: rgba(255,78,0,0.12);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin: 0 auto 16px;
}

.feature-card h3 { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.feature-card p { font-size: 13px; color: var(--text-muted); line-height: 1.55; }

/* ===== PAYMENTS ===== */
.payments-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: center;
}
.payment-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 80px;
  height: 44px;
  transition: border-color var(--transition);
}
.payment-item:hover { border-color: var(--primary); }
.payment-item img { height: 26px; width: auto; filter: brightness(0.85); }
.payment-item:hover img { filter: brightness(1); }

/* ===== FAQ ACCORDION ===== */
.faq-list { display: flex; flex-direction: column; gap: 10px; }

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-white);
  font-size: 15px;
  font-weight: 600;
  text-align: left;
  padding: 18px 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  transition: color var(--transition);
}
.faq-question:hover { color: var(--primary); }

.faq-icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  background: rgba(255,78,0,0.12);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--primary);
  transition: transform var(--transition);
}
.faq-item.open .faq-icon { transform: rotate(45deg); }

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.35s ease;
  padding: 0 22px;
}
.faq-item.open .faq-answer {
  max-height: 400px;
  padding: 0 22px 18px;
}
.faq-answer p { font-size: 14px; color: var(--text-muted); line-height: 1.65; }

/* ===== PAGE HERO ===== */
.page-hero {
  background: linear-gradient(135deg, #111113 0%, #1c1c1e 100%);
  border-bottom: 1px solid var(--border);
  padding: 52px 20px;
  text-align: center;
}
.page-hero h1 { font-size: clamp(28px, 5vw, 48px); font-weight: 800; margin-bottom: 12px; }
.page-hero p { font-size: 16px; color: var(--text-muted); max-width: 600px; margin: 0 auto 24px; }

.breadcrumb {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb span { color: var(--text-muted); }

/* ===== TABS ===== */
.tabs {
  display: flex;
  gap: 4px;
  background: var(--bg-card);
  border-radius: 10px;
  padding: 4px;
  flex-wrap: wrap;
}
.tab-btn {
  padding: 8px 20px;
  border: none;
  background: none;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}
.tab-btn.active, .tab-btn:hover {
  background: var(--primary);
  color: #fff;
}

/* ===== LIVE SCORE TICKER ===== */
.live-ticker {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
}
.live-badge {
  background: #e82a2a;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  flex-shrink: 0;
  animation: pulse 1.5s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}
.ticker-scroll { overflow: hidden; flex: 1; }
.ticker-inner { display: flex; gap: 48px; animation: ticker 25s linear infinite; white-space: nowrap; }
.ticker-inner span { font-size: 13px; color: var(--text-muted); }
.ticker-inner strong { color: var(--text-white); }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ===== PROVIDER LOGOS ===== */
.providers-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
}
.provider-badge {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  transition: all var(--transition);
}
.provider-badge:hover { border-color: var(--primary); color: var(--text-white); }

/* ===== CTA SECTION ===== */
.cta-section {
  background: linear-gradient(135deg, rgba(255,78,0,0.12) 0%, rgba(248,140,0,0.06) 100%);
  border-top: 1px solid rgba(255,78,0,0.2);
  border-bottom: 1px solid rgba(255,78,0,0.2);
  text-align: center;
  padding: 64px 20px;
}
.cta-section h2 { font-size: clamp(24px, 3vw, 38px); font-weight: 800; margin-bottom: 12px; }
.cta-section p { color: var(--text-muted); font-size: 16px; max-width: 560px; margin: 0 auto 28px; }
.cta-buttons { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ===== FOOTER ===== */
.site-footer {
  background: #0a0a0b;
  border-top: 1px solid var(--border);
  padding: 52px 20px 24px;
}
.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
}
.footer-top {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 40px;
  margin-bottom: 40px;
}
.footer-brand img { height: 36px; margin-bottom: 14px; }
.footer-brand p { font-size: 13px; color: var(--text-muted); line-height: 1.65; max-width: 280px; }

.footer-col h4 { font-size: 14px; font-weight: 700; margin-bottom: 14px; color: var(--text-white); }
.footer-col ul { display: flex; flex-direction: column; gap: 8px; }
.footer-col ul li a { font-size: 13px; color: var(--text-muted); transition: color var(--transition); }
.footer-col ul li a:hover { color: var(--primary); }

.footer-divider { height: 1px; background: var(--border); margin: 28px 0; }

.footer-payments { margin-bottom: 24px; }
.footer-payments h4 { font-size: 13px; font-weight: 600; color: var(--text-muted); margin-bottom: 12px; text-transform: uppercase; letter-spacing: 1px; }

.certs-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 24px;
}
.cert-badge {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 14px;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-bottom p { font-size: 12px; color: var(--text-muted); }
.footer-bottom .age-badge {
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 6px;
}

.age-disclaimer {
  font-size: 12px;
  color: #666;
  text-align: center;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* ===== 404 PAGE ===== */
.error-page {
  min-height: calc(100vh - 64px);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px;
}
.error-code {
  font-size: clamp(80px, 15vw, 160px);
  font-weight: 900;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 16px;
}
.error-page h2 { font-size: 28px; font-weight: 700; margin-bottom: 12px; }
.error-page p { font-size: 16px; color: var(--text-muted); max-width: 460px; margin: 0 auto 28px; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1023px) {
  .feature-card { flex-basis: calc(50% - 10px); max-width: calc(50% - 10px); padding: 24px 20px; }
}

@media (max-width: 1024px) {
  .footer-top { grid-template-columns: 1fr 1fr; }
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .responsive-2col { grid-template-columns: 1fr !important; }
  .main-nav { display: none; }
  .hamburger { display: flex; }
  .nav-actions .btn-outline { display: none; }

  .slide img { height: 260px; }
  .hero-slider { max-height: 260px; }
  .slide-overlay { padding: 0 24px; }
  .slide-content h2 { font-size: 18px; }
  .slide-content p { display: none; }

  .footer-top { grid-template-columns: 1fr; gap: 28px; }
  .category-card { flex-basis: calc(50% - 8px); max-width: calc(50% - 8px); }
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
  .game-card { flex-basis: 130px; max-width: 180px; }
}

@media (max-width: 639px) {
  .feature-card { flex-basis: 100%; max-width: 100%; }
  .tab-pane .features-grid { grid-template-columns: 1fr !important; }
}

@media (max-width: 480px) {
  .promo-card { flex-basis: 100%; max-width: 100%; }
  .cta-buttons { flex-direction: column; align-items: center; }
  .stats-inner { grid-template-columns: 1fr 1fr; gap: 16px; }
  .game-card { flex-basis: calc(50% - 7px); max-width: calc(50% - 7px); }
}
