/* H 13 layout stylesheet - all custom classes use pg84- prefix */
/* Palette: #ADB5BD (muted grey) | #333333 (dark) | #FFCC02 (gold accent) */
/* Dark background, light text, gold accent for CTA. Mobile-first, max-width 430px. */

:root {
  --pg84-dark: #1a1a1a;
  --pg84-darker: #0e0e0e;
  --pg84-card: #242424;
  --pg84-card-2: #2e2e2e;
  --pg84-text: #f5f5f5;
  --pg84-muted: #ADB5BD;
  --pg84-accent: #FFCC02;
  --pg84-accent-2: #ffd633;
  --pg84-line: #3a3a3a;
  --pg84-shadow: 0 6px 24px rgba(0, 0, 0, 0.45);
  --pg84-radius: 14px;
  --pg84-radius-sm: 10px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: "Segoe UI", "Roboto", "Helvetica Neue", Arial, "Microsoft YaHei", sans-serif;
  background: var(--pg84-dark);
  color: var(--pg84-text);
  line-height: 1.55;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.pg84-no-scroll { overflow: hidden; }

a { color: var(--pg84-accent); text-decoration: none; }
a:hover { color: var(--pg84-accent-2); text-decoration: underline; }

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

h1, h2, h3, h4 { color: #fff; margin: 0 0 0.6em; line-height: 1.3; font-weight: 700; }
h1 { font-size: 1.7rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 0.9em; }

.container { width: 100%; max-width: 430px; margin: 0 auto; padding: 0 14px; }

/* ============ HEADER ============ */
.pg84-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: linear-gradient(180deg, #161616 0%, #0e0e0e 100%);
  border-bottom: 1px solid var(--pg84-line);
  box-shadow: 0 2px 12px rgba(0,0,0,0.5);
}
.pg84-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 14px;
  max-width: 430px;
  margin: 0 auto;
}
.pg84-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  color: #fff;
  font-size: 1.2rem;
  letter-spacing: 0.5px;
}
.pg84-logo .pg84-logo-badge {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--pg84-accent), #ff9900);
  color: #1a1a1a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.95rem;
}
.pg84-logo span.pg84-brand { color: var(--pg84-accent); }

.pg84-header-actions { display: flex; align-items: center; gap: 8px; }

.pg84-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: 30px;
  font-weight: 700;
  font-size: 0.85rem;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s, background 0.2s;
  white-space: nowrap;
  line-height: 1;
}
.pg84-btn:hover { text-decoration: none; transform: translateY(-1px); }
.pg84-btn-login {
  background: transparent;
  color: #fff;
  border: 1.5px solid var(--pg84-accent);
}
.pg84-btn-login:hover { background: rgba(255,204,2,0.12); }
.pg84-btn-register {
  background: linear-gradient(135deg, var(--pg84-accent) 0%, #ff9900 100%);
  color: #1a1a1a;
  box-shadow: 0 4px 14px rgba(255,204,2,0.35);
}
.pg84-btn-register:hover { box-shadow: 0 6px 18px rgba(255,204,2,0.5); }

.pg84-menu-btn {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.4rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
}
.pg84-menu-btn:hover { background: rgba(255,255,255,0.08); }

/* Desktop nav (hidden on mobile) */
.pg84-desktop-nav { display: none; }
.pg84-desktop-nav a {
  color: #fff;
  font-size: 0.9rem;
  padding: 6px 10px;
  border-radius: 8px;
}
.pg84-desktop-nav a:hover { background: rgba(255,255,255,0.08); color: var(--pg84-accent); text-decoration: none; }

/* ============ MOBILE MENU ============ */
.pg84-mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 80%;
  max-width: 320px;
  height: 100vh;
  background: #121212;
  z-index: 9999;
  padding: 70px 18px 24px;
  transform: translateX(100%);
  transition: transform 0.28s ease;
  overflow-y: auto;
  border-left: 1px solid var(--pg84-line);
}
.pg84-mobile-menu.pg84-open { transform: translateX(0); }
.pg84-mobile-menu a {
  display: block;
  padding: 12px 14px;
  color: #fff;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  font-size: 0.95rem;
}
.pg84-mobile-menu a:hover { background: rgba(255,204,2,0.1); color: var(--pg84-accent); text-decoration: none; }
.pg84-menu-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.6rem;
  cursor: pointer;
}
.pg84-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 9998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}
.pg84-mobile-menu.pg84-open ~ .pg84-menu-overlay { opacity: 1; pointer-events: auto; }

/* ============ HERO ============ */
.pg84-hero {
  position: relative;
  overflow: hidden;
  border-radius: 0 0 22px 22px;
  background: #0a0a0a;
}
.pg84-hero-slide {
  display: none;
  position: relative;
  padding: 28px 16px 36px;
  background-size: cover;
  background-position: center;
  min-height: 320px;
}
.pg84-hero-slide.pg84-active { display: block; }
.pg84-hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.4) 0%, rgba(0,0,0,0.85) 100%);
}
.pg84-hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
}
.pg84-hero-tag {
  display: inline-block;
  background: var(--pg84-accent);
  color: #1a1a1a;
  font-weight: 700;
  font-size: 0.72rem;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 10px;
  letter-spacing: 1px;
}
.pg84-hero-title {
  font-size: 2rem;
  line-height: 1.15;
  margin-bottom: 8px;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0,0,0,0.6);
}
.pg84-hero-title span { color: var(--pg84-accent); }
.pg84-hero-desc {
  color: var(--pg84-muted);
  font-size: 0.9rem;
  margin-bottom: 18px;
  max-width: 360px;
  margin-left: auto;
  margin-right: auto;
}
.pg84-hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, var(--pg84-accent), #ff9900);
  color: #1a1a1a;
  padding: 13px 30px;
  border-radius: 30px;
  font-weight: 800;
  font-size: 1rem;
  box-shadow: 0 6px 22px rgba(255,204,2,0.4);
  cursor: pointer;
  border: none;
}
.pg84-hero-cta:hover { transform: translateY(-2px); text-decoration: none; }
.pg84-hero-dots {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: -14px;
  padding-bottom: 14px;
}
.pg84-hero-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  cursor: pointer;
  transition: all 0.2s;
}
.pg84-hero-dot.pg84-active { background: var(--pg84-accent); width: 22px; border-radius: 4px; }

/* ============ MARQUEE ============ */
.pg84-marquee {
  background: var(--pg84-accent);
  color: #1a1a1a;
  padding: 7px 0;
  overflow: hidden;
  white-space: nowrap;
  font-weight: 700;
  font-size: 0.8rem;
}
.pg84-marquee span {
  display: inline-block;
  padding-left: 100%;
  animation: pg84scroll 22s linear infinite;
}
@keyframes pg84scroll {
  to { transform: translateX(-100%); }
}

/* ============ SECTIONS ============ */
.pg84-section { padding: 26px 0; }
.pg84-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.pg84-section-title {
  font-size: 1.25rem;
  color: #fff;
  position: relative;
  padding-left: 14px;
  margin: 0;
}
.pg84-section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 5px;
  height: 22px;
  background: var(--pg84-accent);
  border-radius: 3px;
}
.pg84-section-more { font-size: 0.8rem; color: var(--pg84-accent); }

/* ============ CATEGORY PILLS ============ */
.pg84-cats {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 0 10px;
  -webkit-overflow-scrolling: touch;
}
.pg84-cats::-webkit-scrollbar { display: none; }
.pg84-cat-pill {
  flex-shrink: 0;
  padding: 8px 16px;
  background: var(--pg84-card);
  color: #fff;
  border-radius: 20px;
  font-size: 0.82rem;
  cursor: pointer;
  border: 1px solid var(--pg84-line);
  white-space: nowrap;
}
.pg84-cat-pill.pg84-active, .pg84-cat-pill:hover {
  background: var(--pg84-accent);
  color: #1a1a1a;
  border-color: var(--pg84-accent);
}

/* ============ GAME GRID ============ */
.pg84-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.pg84-game-card {
  background: var(--pg84-card);
  border-radius: var(--pg84-radius-sm);
  overflow: hidden;
  cursor: pointer;
  position: relative;
  border: 1px solid var(--pg84-line);
  transition: transform 0.18s, box-shadow 0.18s;
}
.pg84-game-card:hover { transform: translateY(-3px); box-shadow: var(--pg84-shadow); border-color: var(--pg84-accent); }
.pg84-game-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: #000;
}
.pg84-game-name {
  padding: 6px 8px;
  font-size: 0.7rem;
  text-align: center;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 600;
}
.pg84-game-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s;
}
.pg84-game-card:hover .pg84-game-overlay { opacity: 1; }
.pg84-play-btn {
  background: var(--pg84-accent);
  color: #1a1a1a;
  font-weight: 800;
  font-size: 0.75rem;
  padding: 7px 16px;
  border-radius: 20px;
  border: none;
  cursor: pointer;
}
.pg84-hot-badge {
  position: absolute;
  top: 6px;
  left: 6px;
  background: #ff3344;
  color: #fff;
  font-size: 0.6rem;
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 700;
  z-index: 2;
}

/* ============ FEATURED BIG CARD ============ */
.pg84-featured {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
.pg84-feature-card {
  position: relative;
  border-radius: var(--pg84-radius);
  overflow: hidden;
  min-height: 150px;
  display: flex;
  align-items: flex-end;
  background: var(--pg84-card);
  border: 1px solid var(--pg84-line);
}
.pg84-feature-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pg84-feature-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0,0,0,0.9) 10%, transparent 70%);
}
.pg84-feature-body {
  position: relative;
  z-index: 2;
  padding: 12px;
}
.pg84-feature-title { color: #fff; font-size: 1rem; margin: 0 0 4px; }
.pg84-feature-sub { color: var(--pg84-muted); font-size: 0.75rem; margin-bottom: 8px; }
.pg84-feature-link {
  display: inline-block;
  background: var(--pg84-accent);
  color: #1a1a1a;
  padding: 6px 14px;
  border-radius: 16px;
  font-size: 0.75rem;
  font-weight: 700;
}

/* ============ INFO / WHY ============ */
.pg84-features-box {
  background: var(--pg84-card);
  border-radius: var(--pg84-radius);
  padding: 18px;
  border: 1px solid var(--pg84-line);
}
.pg84-feature-row {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.pg84-feature-row:last-child { border-bottom: none; }
.pg84-feature-icon {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  border-radius: 10px;
  background: rgba(255,204,2,0.15);
  color: var(--pg84-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}
.pg84-feature-text h4 { margin: 0 0 4px; color: #fff; font-size: 0.95rem; }
.pg84-feature-text p { margin: 0; color: var(--pg84-muted); font-size: 0.8rem; }

/* ============ STEPS ============ */
.pg84-steps { display: grid; gap: 10px; }
.pg84-step {
  display: flex;
  gap: 12px;
  align-items: center;
  background: var(--pg84-card);
  padding: 12px;
  border-radius: var(--pg84-radius-sm);
  border: 1px solid var(--pg84-line);
}
.pg84-step-num {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  background: var(--pg84-accent);
  color: #1a1a1a;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.95rem;
}
.pg84-step-text h4 { margin: 0 0 3px; font-size: 0.9rem; color: #fff; }
.pg84-step-text p { margin: 0; font-size: 0.78rem; color: var(--pg84-muted); }

/* ============ SEO CONTENT ============ */
.pg84-seo {
  background: var(--pg84-card);
  border-radius: var(--pg84-radius);
  padding: 20px 18px;
  border: 1px solid var(--pg84-line);
  color: var(--pg84-muted);
  font-size: 0.88rem;
  line-height: 1.7;
}
.pg84-seo h2 { color: #fff; font-size: 1.2rem; margin-top: 18px; }
.pg84-seo h2:first-child { margin-top: 0; }
.pg84-seo h3 { color: var(--pg84-accent); font-size: 1rem; margin-top: 14px; }
.pg84-seo p { margin-bottom: 0.8em; }
.pg84-seo strong { color: #fff; }

/* ============ FAQ ============ */
.pg84-faq-item {
  background: var(--pg84-card);
  border: 1px solid var(--pg84-line);
  border-radius: var(--pg84-radius-sm);
  margin-bottom: 8px;
  overflow: hidden;
}
.pg84-faq-q {
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  padding: 14px 16px;
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.pg84-faq-q .pg84-icon { color: var(--pg84-accent); transition: transform 0.2s; }
.pg84-faq-item.pg84-open .pg84-faq-q .pg84-icon { transform: rotate(45deg); }
.pg84-faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 16px;
  color: var(--pg84-muted);
  font-size: 0.84rem;
}
.pg84-faq-item.pg84-open .pg84-faq-a {
  max-height: 500px;
  padding-bottom: 14px;
}

/* ============ CTA BANNER ============ */
.pg84-cta {
  background: linear-gradient(135deg, #2a2000 0%, #1a1a1a 100%);
  border: 1px solid var(--pg84-accent);
  border-radius: var(--pg84-radius);
  padding: 22px 18px;
  text-align: center;
  margin: 22px 0;
}
.pg84-cta h3 { color: var(--pg84-accent); margin-bottom: 8px; }
.pg84-cta p { color: var(--pg84-muted); font-size: 0.85rem; margin-bottom: 14px; }

/* ============ FOOTER ============ */
.pg84-footer {
  background: #0a0a0a;
  border-top: 1px solid var(--pg84-line);
  padding: 26px 0 30px;
  margin-top: 20px;
}
.pg84-footer-cols { display: grid; gap: 18px; }
.pg84-footer-col h4 {
  color: var(--pg84-accent);
  font-size: 0.9rem;
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.pg84-footer-col a {
  display: block;
  color: var(--pg84-muted);
  font-size: 0.82rem;
  padding: 4px 0;
}
.pg84-footer-col a:hover { color: var(--pg84-accent); }
.pg84-footer-bottom {
  border-top: 1px solid var(--pg84-line);
  margin-top: 18px;
  padding-top: 14px;
  text-align: center;
  color: #777;
  font-size: 0.75rem;
}

/* ============ BOTTOM NAV ============ */
.pg84-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, #1a1a1a 0%, #050505 100%);
  border-top: 1px solid var(--pg84-line);
  display: flex;
  justify-content: space-around;
  align-items: center;
  height: 62px;
  z-index: 1000;
  box-shadow: 0 -3px 14px rgba(0,0,0,0.5);
}
.pg84-bottom-nav a, .pg84-bottom-nav button {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--pg84-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 0.66rem;
  text-decoration: none;
  padding: 6px 2px;
  min-height: 60px;
  min-width: 60px;
  position: relative;
  cursor: pointer;
  transition: color 0.18s;
}
.pg84-bottom-nav a:hover, .pg84-bottom-nav button:hover { text-decoration: none; }
.pg84-bottom-nav .pg84-bn-icon {
  font-size: 1.35rem;
  line-height: 1;
  transition: transform 0.18s;
}
.pg84-bottom-nav a:hover .pg84-bn-icon,
.pg84-bottom-nav button:hover .pg84-bn-icon { transform: translateY(-2px); }
.pg84-bottom-nav .pg84-active-nav { color: var(--pg84-accent); }
.pg84-bottom-nav .pg84-bn-promo {
  background: linear-gradient(135deg, var(--pg84-accent), #ff9900);
  color: #1a1a1a;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  margin-top: -22px;
  box-shadow: 0 4px 14px rgba(255,204,2,0.45);
  font-weight: 800;
  border: 3px solid #1a1a1a;
  flex: 0 0 auto;
}
.pg84-bottom-nav .pg84-bn-promo .pg84-bn-icon { font-size: 1.4rem; }

/* ============ BACK TO TOP ============ */
.pg84-back-top {
  position: fixed;
  bottom: 76px;
  right: 14px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--pg84-accent);
  color: #1a1a1a;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  z-index: 999;
  transition: opacity 0.25s, transform 0.25s;
  box-shadow: var(--pg84-shadow);
}
.pg84-back-top.pg84-show { opacity: 1; pointer-events: auto; }

main { padding-bottom: 80px; }

/* ============ SUBPAGE MINI HERO ============ */
.pg84-page-hero {
  background: linear-gradient(135deg, #241c00 0%, #0e0e0e 70%);
  border-bottom: 1px solid var(--pg84-line);
  padding: 26px 16px 24px;
  text-align: center;
}
.pg84-page-hero h1 { font-size: 1.5rem; margin-bottom: 8px; }
.pg84-page-hero p { color: var(--pg84-muted); font-size: 0.88rem; max-width: 380px; margin: 0 auto 14px; }

/* Footer brand description */
.pg84-footer-desc { color: var(--pg84-muted); font-size: 0.78rem; line-height: 1.6; margin: 0 0 8px; }

/* Bold promo text link (triggered by web4ccopenLink JS handler) */
.pg84-promo-link {
  display: inline-block;
  margin-top: 12px;
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--pg84-accent);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.pg84-promo-link:hover { color: var(--pg84-accent-2); }
.pg84-center { text-align: center; }

/* Compact tip / checklist used on help pages */
.pg84-tips { margin: 0 0 0.9em; padding-left: 1.2em; color: var(--pg84-muted); font-size: 0.85rem; line-height: 1.6; }
.pg84-tips li { margin-bottom: 6px; }
.pg84-tips strong { color: #fff; }
.pg84-lead { color: var(--pg84-text); font-size: 0.95rem; }

/* ============ DESKTOP ============ */
@media (min-width: 769px) {
  body { background: #111; }
  .container { max-width: 960px; }
  .pg84-header-inner { max-width: 960px; }
  .pg84-menu-btn { display: none; }
  .pg84-desktop-nav { display: flex; gap: 6px; }
  .pg84-bottom-nav { display: none; }
  main { padding-bottom: 30px; }
  .pg84-grid { grid-template-columns: repeat(6, 1fr); }
  .pg84-featured { grid-template-columns: repeat(3, 1fr); }
  .pg84-footer-cols { grid-template-columns: repeat(4, 1fr); }
  .pg84-features-box { padding: 26px; }
}
