/* ============================================================
   kk333 Design System — Emerald Trust Gaming UI
   Visual Style: Premium, Trust-focused, Bangladesh-optimized
   ============================================================ */

:root {
  --color-primary: #1a6b4a;
  --color-primary-dark: #0f4d35;
  --color-primary-soft: #e8f5ef;
  --color-secondary: #c8a33e;
  --color-accent: #e8a020;
  --color-bg: #f7f8fa;
  --color-bg-soft: #eef1f5;
  --color-surface: #ffffff;
  --color-surface-strong: #f0f2f6;
  --color-card: #ffffff;
  --color-card-alt: #f8fafb;
  --color-border: #dce1e8;
  --color-border-strong: #b8c0cc;
  --color-text: #1a1e2a;
  --color-text-soft: #4a5068;
  --color-text-muted: #7a8098;
  --color-success: #22a85a;
  --color-warning: #e8a020;
  --color-danger: #d9434e;
  --color-footer-bg: #111827;
  --color-footer-text: #c8cdd8;
  --gradient-hero: linear-gradient(135deg, #0f2b1e 0%, #1a4a35 40%, #0d3828 100%);
  --gradient-hero-soft: linear-gradient(180deg, rgba(26,107,74,.08) 0%, transparent 100%);
  --gradient-button: linear-gradient(135deg, #1a6b4a 0%, #22885e 100%);
  --gradient-button-hover: linear-gradient(135deg, #22885e 0%, #2aa06c 100%);
  --gradient-cta: linear-gradient(135deg, #c8a33e 0%, #e8b84a 100%);
  --gradient-footer: linear-gradient(180deg, #111827 0%, #0a0f18 100%);
  --shadow-header: 0 2px 12px rgba(0,0,0,.08);
  --shadow-card: 0 2px 8px rgba(0,0,0,.06);
  --shadow-card-hover: 0 8px 24px rgba(0,0,0,.12);
  --shadow-button: 0 2px 6px rgba(26,107,74,.2);
  --shadow-soft: 0 1px 4px rgba(0,0,0,.04);
  --radius-xs: 4px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-pill: 50px;
  --radius-card: 12px;
  --font-base: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, "Noto Sans Bengali", sans-serif;
  --fs-h1: clamp(28px, 4vw, 48px);
  --fs-h2: clamp(22px, 3vw, 36px);
  --fs-h3: clamp(18px, 2vw, 24px);
  --fs-body: 17px;
  --fs-small: 14px;
  --fs-nav: clamp(13px, .84vw, 15px);
  --lh-heading: 1.25;
  --lh-body: 1.85;
  --container-max: 1200px;
  --container-narrow: 820px;
  --section-y: clamp(48px, 6vw, 80px);
  --section-y-sm: clamp(32px, 4vw, 56px);
  --gap-sm: 12px;
  --gap-md: 20px;
  --gap-lg: 32px;
  --header-h: 72px;
  --mobile-header-h: 64px;
  --motion-fast: .15s;
  --motion-normal: .25s;
  --motion-slow: .4s;
  --ease-out: cubic-bezier(.22,1,.36,1);
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { font-family: var(--font-base); font-size: var(--fs-body); line-height: var(--lh-body); color: var(--color-text); background: var(--color-bg); overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--color-primary); text-decoration: none; transition: color var(--motion-fast); }
a:hover { color: var(--color-primary-dark); }
ul, ol { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 2px; border-radius: var(--radius-xs); }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; } }

/* ---- Container ---- */
.container { width: 100%; max-width: var(--container-max); margin: 0 auto; padding: 0 clamp(16px, 3vw, 32px); }

/* ---- Section ---- */
.section { padding: var(--section-y) 0; }
.alt-bg { background: var(--color-bg-soft); }

/* ============================================================
   HEADER — Single-row, no "More" button, all 11 nav items visible
   ============================================================ */
.site-header { position: sticky; top: 0; z-index: 1000; background: rgba(255,255,255,.97); backdrop-filter: blur(8px); border-bottom: 1px solid var(--color-border); box-shadow: var(--shadow-header); }
.header-inner { width: 100%; max-width: none; padding-left: clamp(10px, 1.2vw, 20px); padding-right: clamp(10px, 1.2vw, 20px); min-height: var(--header-h); display: flex; align-items: center; gap: clamp(8px, 1vw, 16px); }
.brand-wrap { flex: 0 0 auto; margin-right: clamp(4px, .6vw, 10px); }
.site-logo { display: block; width: auto; height: clamp(32px, 3vw, 42px); max-width: clamp(100px, 10vw, 160px); object-fit: contain; }
.primary-nav { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; justify-content: center; flex-wrap: nowrap; gap: clamp(4px, .6vw, 12px); white-space: nowrap; overflow: visible; }
.primary-nav .nav-link { flex: 0 1 auto; min-width: 0; padding: 8px clamp(4px, .5vw, 10px); font-size: var(--fs-nav); font-weight: 500; line-height: 1; white-space: nowrap; color: var(--color-text-soft); border-radius: var(--radius-sm); transition: all var(--motion-fast); }
.primary-nav .nav-link:hover { color: var(--color-primary); background: var(--color-primary-soft); }
.primary-nav .nav-link.active { color: var(--color-primary); font-weight: 600; background: var(--color-primary-soft); }
.header-actions { flex: 0 0 auto; margin-left: auto; display: flex; align-items: center; justify-content: flex-end; gap: clamp(6px, .6vw, 10px); white-space: nowrap; }
.nav-toggle { display: none; flex: 0 0 42px; width: 42px; height: 42px; align-items: center; justify-content: center; flex-direction: column; gap: 5px; padding: 8px; border-radius: var(--radius-sm); transition: background var(--motion-fast); }
.nav-toggle:hover { background: var(--color-bg-soft); }
.hamburger-line { width: 22px; height: 2px; background: var(--color-text); border-radius: 2px; transition: all var(--motion-normal); }

/* ---- Mobile Menu ---- */
.mobile-menu { display: none; position: fixed; top: var(--header-h); left: 0; right: 0; bottom: 0; z-index: 999; background: rgba(0,0,0,.4); opacity: 0; pointer-events: none; transition: opacity var(--motion-normal); }
.mobile-menu.is-open { display: block; opacity: 1; pointer-events: auto; }
.mobile-menu-inner { background: var(--color-surface); padding: 16px; max-height: calc(100vh - var(--header-h) - 20px); overflow-y: auto; border-bottom: 1px solid var(--color-border); box-shadow: 0 8px 24px rgba(0,0,0,.12); }
.mobile-nav-link { display: block; padding: 14px 16px; font-size: 16px; font-weight: 500; color: var(--color-text); border-radius: var(--radius-sm); transition: background var(--motion-fast); }
.mobile-nav-link:hover { background: var(--color-primary-soft); color: var(--color-primary); }

@media (max-width: 1180px) {
  .primary-nav { display: none; }
  .nav-toggle { display: inline-flex; }
  .header-inner { min-height: var(--mobile-header-h); padding-left: clamp(8px, 2.4vw, 14px); padding-right: clamp(8px, 2.4vw, 14px); justify-content: flex-start; gap: clamp(6px, 1.8vw, 10px); }
  .brand-wrap { flex: 0 1 auto; margin-right: 0; }
  .site-logo { height: clamp(30px, 8vw, 40px); max-width: clamp(90px, 25vw, 130px); }
  .header-actions { margin-left: auto; }
  .nav-toggle { flex: 0 0 42px; margin-left: 2px; }
}
@media (max-width: 375px) {
  .header-inner { padding-left: 8px; padding-right: 8px; gap: 6px; }
  .site-logo { max-width: 100px; }
  .nav-toggle { flex-basis: 38px; width: 38px; height: 38px; }
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn { display: inline-flex; align-items: center; justify-content: center; padding: 12px 24px; font-size: 15px; font-weight: 600; line-height: 1; border-radius: var(--radius-pill); text-decoration: none; white-space: nowrap; transition: all var(--motion-normal) var(--ease-out); min-height: 44px; }
.btn-primary { background: var(--gradient-button); color: #fff; box-shadow: var(--shadow-button); }
.btn-primary:hover { background: var(--gradient-button-hover); color: #fff; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(26,107,74,.3); }
.btn-outline { background: transparent; color: var(--color-primary); border: 2px solid var(--color-primary); }
.btn-outline:hover { background: var(--color-primary); color: #fff; }
.btn-lg { padding: 16px 32px; font-size: 17px; }

/* ============================================================
   HOME HERO
   ============================================================ */
.home-hero { background: var(--gradient-hero); color: #fff; padding: clamp(48px, 8vw, 96px) 0; }
.home-hero .container { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.home-hero h1 { font-size: var(--fs-h1); line-height: var(--lh-heading); margin-bottom: 20px; }
.hero-lead { font-size: 18px; line-height: 1.7; color: rgba(255,255,255,.85); margin-bottom: 28px; }
.hero-cta-group { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 32px; }
.hero-cta-group .btn-outline { border-color: rgba(255,255,255,.5); color: #fff; }
.hero-cta-group .btn-outline:hover { background: rgba(255,255,255,.15); border-color: #fff; }
.hero-trust-strip { display: flex; gap: 24px; flex-wrap: wrap; }
.trust-item { text-align: center; }
.trust-item strong { display: block; font-size: 24px; color: var(--color-secondary); }
.trust-item span { font-size: 13px; color: rgba(255,255,255,.7); }
.home-hero-visual img { border-radius: var(--radius-lg); box-shadow: 0 12px 40px rgba(0,0,0,.3); }
@media (max-width: 900px) {
  .home-hero .container { grid-template-columns: 1fr; text-align: center; }
  .hero-cta-group { justify-content: center; }
  .hero-trust-strip { justify-content: center; }
  .home-hero-visual { order: -1; }
  .home-hero-visual img { max-height: 260px; width: auto; margin: 0 auto; }
}

/* ============================================================
   CARD GRIDS
   ============================================================ */
.card-grid { display: grid; gap: var(--gap-lg); }
.card-grid-2 { grid-template-columns: repeat(2, 1fr); }
.card-grid-3 { grid-template-columns: repeat(3, 1fr); }
.card-grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .card-grid-3, .card-grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .card-grid-2, .card-grid-3, .card-grid-4 { grid-template-columns: 1fr; } }

/* ---- Feature Card ---- */
.feature-card { background: var(--color-card); border-radius: var(--radius-card); box-shadow: var(--shadow-card); overflow: hidden; transition: transform var(--motion-normal) var(--ease-out), box-shadow var(--motion-normal); }
.feature-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-card-hover); }
.feature-card img { width: 100%; height: 200px; object-fit: cover; }
.feature-card h3 { padding: 18px 20px 0; font-size: var(--fs-h3); color: var(--color-text); }
.feature-card p { padding: 10px 20px 20px; color: var(--color-text-soft); font-size: 15px; line-height: 1.7; }

/* ---- Game Card ---- */
.game-card { display: block; background: var(--color-card); border-radius: var(--radius-card); padding: 24px 20px; box-shadow: var(--shadow-card); border: 1px solid var(--color-border); text-decoration: none; transition: all var(--motion-normal) var(--ease-out); }
.game-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-card-hover); border-color: var(--color-primary); }
.game-card h3 { font-size: 17px; color: var(--color-primary); margin-bottom: 6px; }
.game-card p { font-size: 14px; color: var(--color-text-muted); margin: 0; }

/* ---- Review Card ---- */
.review-card { background: var(--color-card); border-radius: var(--radius-card); padding: 28px 24px; border-left: 4px solid var(--color-primary); box-shadow: var(--shadow-card); }
.review-card h3 { font-size: 16px; color: var(--color-primary); margin-bottom: 10px; }
.review-card p { color: var(--color-text-soft); font-size: 15px; }

/* ---- Step Card ---- */
.step-flow { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap-lg); }
.step-card { background: var(--color-card); border-radius: var(--radius-card); padding: 32px 24px; text-align: center; box-shadow: var(--shadow-card); position: relative; }
.step-number { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 50%; background: var(--gradient-button); color: #fff; font-size: 20px; font-weight: 700; margin-bottom: 16px; }
.step-card h3 { font-size: 18px; margin-bottom: 10px; }
.step-card p { color: var(--color-text-soft); font-size: 15px; }
@media (max-width: 768px) { .step-flow { grid-template-columns: 1fr; } }

/* ---- Stat Card ---- */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap-md); }
.stat-card { background: var(--color-card); border-radius: var(--radius-card); padding: 28px 20px; text-align: center; box-shadow: var(--shadow-card); border-top: 3px solid var(--color-primary); }
.stat-card strong { display: block; font-size: 28px; color: var(--color-primary); margin-bottom: 6px; }
.stat-card span { color: var(--color-text-muted); font-size: 14px; }
@media (max-width: 768px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }

/* ============================================================
   GUIDE PANEL (text + image side-by-side)
   ============================================================ */
.guide-content { display: grid; grid-template-columns: 1.1fr .9fr; gap: 36px; align-items: start; }
.guide-content img { border-radius: var(--radius-lg); box-shadow: var(--shadow-card); }
@media (max-width: 900px) { .guide-content { grid-template-columns: 1fr; } }

/* ============================================================
   SPLIT LAYOUT (category intro)
   ============================================================ */
.split-layout { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.split-layout img { border-radius: var(--radius-lg); box-shadow: var(--shadow-card); }
@media (max-width: 900px) { .split-layout { grid-template-columns: 1fr; } .split-layout img { order: -1; } }

/* ============================================================
   PAGE HERO SIMPLE (inner pages)
   ============================================================ */
.page-hero-simple { background: var(--gradient-hero-soft); padding: var(--section-y-sm) 0; border-bottom: 1px solid var(--color-border); }
.page-hero-simple h1 { font-size: var(--fs-h1); line-height: var(--lh-heading); margin-bottom: 16px; color: var(--color-text); }
.page-hero-simple p { font-size: 17px; color: var(--color-text-soft); max-width: var(--container-narrow); }
.hero-img { margin-top: 24px; border-radius: var(--radius-lg); box-shadow: var(--shadow-card); }

/* ============================================================
   CONTENT STYLING
   ============================================================ */
.section h2 { font-size: var(--fs-h2); line-height: var(--lh-heading); margin-bottom: 16px; color: var(--color-text); }
.section h3 { font-size: var(--fs-h3); line-height: 1.35; margin: 24px 0 10px; color: var(--color-text); }
.section p { margin-bottom: 14px; color: var(--color-text-soft); }
.content-img { margin: 24px 0; border-radius: var(--radius-lg); box-shadow: var(--shadow-card); }
.content-list { margin: 16px 0; padding-left: 0; }
.content-list li { padding: 8px 0 8px 24px; position: relative; color: var(--color-text-soft); }
.content-list li::before { content: "✓"; position: absolute; left: 0; color: var(--color-primary); font-weight: 700; }
.related-links { margin: 16px 0; }
.related-links li { padding: 10px 0; border-bottom: 1px solid var(--color-border); }
.related-links li a { font-weight: 600; }
.warning-box { background: #fef3cd; border: 1px solid #ffc107; border-radius: var(--radius-md); padding: 20px 24px; margin: 20px 0; }
.warning-box h3 { color: #856404; margin-top: 0; }
.warning-box li { color: #856404; }

/* ============================================================
   FAQ
   ============================================================ */
.faq-list { max-width: var(--container-narrow); }
.faq-item { border: 1px solid var(--color-border); border-radius: var(--radius-md); margin-bottom: 10px; overflow: hidden; background: var(--color-card); }
.faq-question { width: 100%; display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; font-size: 16px; font-weight: 600; color: var(--color-text); text-align: left; background: transparent; transition: background var(--motion-fast); }
.faq-question:hover { background: var(--color-bg-soft); }
.faq-icon { font-size: 20px; color: var(--color-primary); transition: transform var(--motion-normal); flex-shrink: 0; margin-left: 12px; }
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-answer { display: none; padding: 0 20px 16px; }
.faq-item.open .faq-answer { display: block; }
.faq-answer p { color: var(--color-text-soft); font-size: 15px; margin: 0; }

/* ============================================================
   CTA SECTION
   ============================================================ */
.cta-section { background: var(--gradient-hero); color: #fff; text-align: center; }
.cta-section h2 { color: #fff; }
.cta-section p { color: rgba(255,255,255,.85); max-width: var(--container-narrow); margin: 0 auto 24px; }
.cta-section a { color: rgba(255,255,255,.9); }
.cta-buttons { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.home-final-cta { background: var(--gradient-hero); color: #fff; text-align: center; }
.home-final-cta h2 { color: #fff; }
.home-final-cta p { color: rgba(255,255,255,.85); max-width: var(--container-narrow); margin: 0 auto 24px; }

/* ============================================================
   BREADCRUMB
   ============================================================ */
.breadcrumb { padding: 14px 0; border-bottom: 1px solid var(--color-border); background: var(--color-surface); }
.breadcrumb-list { display: flex; align-items: center; gap: 8px; max-width: var(--container-max); margin: 0 auto; padding: 0 clamp(16px, 3vw, 32px); font-size: 14px; }
.breadcrumb-list li::before { content: "/"; margin-right: 8px; color: var(--color-text-muted); }
.breadcrumb-list li:first-child::before { display: none; }
.breadcrumb-list li a { color: var(--color-primary); }
.breadcrumb-list li[aria-current] { color: var(--color-text-muted); }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { background: var(--gradient-footer); color: var(--color-footer-text); padding: 56px 0 0; }
.footer-inner { max-width: var(--container-max); margin: 0 auto; padding: 0 clamp(16px, 3vw, 32px); }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 32px; padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,.1); }
.footer-logo { height: 36px; width: auto; margin-bottom: 14px; filter: brightness(1.2); }
.footer-desc { font-size: 14px; line-height: 1.7; color: rgba(255,255,255,.6); }
.footer-heading { font-size: 16px; font-weight: 600; color: #fff; margin-bottom: 14px; }
.footer-links li { padding: 5px 0; }
.footer-links a { color: var(--color-footer-text); font-size: 14px; transition: color var(--motion-fast); }
.footer-links a:hover { color: var(--color-secondary); }
.footer-bottom { padding: 20px 0; text-align: center; }
.footer-bottom p { font-size: 13px; color: rgba(255,255,255,.5); margin-bottom: 4px; }
.footer-safety a { color: var(--color-secondary); }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .footer-grid { grid-template-columns: 1fr; } }

/* ============================================================
   CATEGORY INTRO
   ============================================================ */
.category-intro { background: var(--gradient-hero-soft); padding: var(--section-y) 0; border-bottom: 1px solid var(--color-border); }
.category-intro h1 { font-size: var(--fs-h1); margin-bottom: 16px; }

/* ============================================================
   404
   ============================================================ */
.error-section h1 { font-size: clamp(36px, 5vw, 56px); color: var(--color-primary); margin-bottom: 16px; }

/* ============================================================
   MOBILE OPTIMIZATIONS
   ============================================================ */
@media (max-width: 414px) {
  .section { padding: clamp(32px, 6vw, 48px) 0; }
  .btn { padding: 11px 20px; font-size: 14px; min-height: 42px; }
  .btn-lg { padding: 14px 24px; font-size: 15px; }
  .feature-card img { height: 160px; }
}
@media (max-width: 375px) {
  body { font-size: 16px; }
  .section h2 { font-size: 20px; }
  .home-hero h1 { font-size: 24px; }
}

/* ---- AOS fallback ---- */
[data-aos] { opacity: 1 !important; transform: none !important; }
.swiper:not(.swiper-initialized) .swiper-slide { display: inline-block; }

/* ---- Print ---- */
@media print { .site-header, .site-footer, .mobile-menu, .nav-toggle { display: none !important; } }
