/*!
 * ph777 login app - layout stylesheet
 * Palette: #E9ECEF / #F8F8FF / #95A5A6 / #273746 / #808080
 * All custom classes use the "w8621-" prefix to isolate styles.
 * Mobile first: base rules target <=430px; @media (min-width) upgrades layout.
 */

:root {
  --w8621-bg: #273746;
  --w8621-bg-alt: #1f2c38;
  --w8621-bg-card: #2c3e50;
  --w8621-text: #F8F8FF;
  --w8621-text-muted: #E9ECEF;
  --w8621-line: #95A5A6;
  --w8621-line-soft: rgba(149, 165, 166, .25);
  --w8621-gray: #808080;
  --w8621-primary: #c0842b;
  --w8621-primary-2: #e0a84a;
  --w8621-accent: #d9534f;
  --w8621-success: #5fb775;
  --w8621-radius: 14px;
  --w8621-radius-sm: 10px;
  --w8621-shadow: 0 6px 18px rgba(0, 0, 0, .35);
  --w8621-header-h: 56px;
  --w8621-bottom-h: 62px;
  --w8621-container: 430px;
  font-size: 62.5%;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--w8621-bg);
  color: var(--w8621-text);
  font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.6rem;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

img { max-width: 100%; display: block; }
a { color: var(--w8621-primary-2); text-decoration: none; }
a:hover, a:focus { color: var(--w8621-primary); text-decoration: underline; }

.w8621-sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.w8621-container {
  width: 100%;
  max-width: var(--w8621-container);
  margin: 0 auto;
  padding: 0 14px;
}

.w8621-wrapper { padding-top: var(--w8621-header-h); padding-bottom: 20px; }

/* ===== Header ===== */
.w8621-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--w8621-header-h);
  background: linear-gradient(180deg, #2b3e50 0%, #1f2c38 100%);
  border-bottom: 1px solid var(--w8621-line-soft);
  box-shadow: 0 2px 10px rgba(0, 0, 0, .35);
}
.w8621-header-inner {
  height: 100%; max-width: var(--w8621-container);
  margin: 0 auto; padding: 0 12px;
  display: flex; align-items: center; gap: 10px;
}
.w8621-logo {
  display: flex; align-items: center; gap: 8px;
  color: var(--w8621-text); font-weight: 700; font-size: 1.5rem;
  text-decoration: none; flex-shrink: 0;
}
.w8621-logo img { width: 26px; height: 26px; border-radius: 6px; }
.w8621-logo:hover { text-decoration: none; color: var(--w8621-primary-2); }

.w8621-burger {
  width: 38px; height: 38px;
  background: transparent; border: 0; color: var(--w8621-text);
  font-size: 2rem; cursor: pointer; padding: 0;
  display: inline-flex; align-items: center; justify-content: center;
}
.w8621-burger.w8621-is-active { color: var(--w8621-primary-2); }

.w8621-spacer { flex: 1 1 auto; }

.w8621-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 36px; padding: 0 14px; border-radius: var(--w8621-radius-sm);
  font-weight: 700; font-size: 1.3rem; border: 0; cursor: pointer;
  text-decoration: none; transition: transform .15s ease, filter .15s ease;
}
.w8621-btn:hover { text-decoration: none; transform: translateY(-1px); filter: brightness(1.05); }
.w8621-btn-primary { background: linear-gradient(135deg, #e0a84a, #c0842b); color: #1f2c38; }
.w8621-btn-ghost { background: transparent; color: var(--w8621-text); border: 1px solid var(--w8621-line-soft); }
.w8621-btn-block { display: flex; width: 100%; padding: 12px 14px; font-size: 1.4rem; }
.w8621-btn-lg { min-height: 48px; padding: 0 22px; font-size: 1.5rem; }

/* ===== Mobile drawer ===== */
.w8621-menu-backdrop {
  position: fixed; inset: 0; background: rgba(0, 0, 0, .55);
  opacity: 0; pointer-events: none; transition: opacity .25s ease; z-index: 9998;
}
.w8621-menu-backdrop.w8621-is-visible { opacity: 1; pointer-events: auto; }
.w8621-mobile-menu {
  position: fixed; top: 0; right: -85%; width: 80%; max-width: 320px;
  height: 100%; background: var(--w8621-bg-alt);
  z-index: 9999; padding: 70px 18px 30px;
  transform: translateX(0); transition: transform .28s ease;
  overflow-y: auto; box-shadow: var(--w8621-shadow);
}
.w8621-mobile-menu.w8621-is-open { transform: translateX(-85%); }
.w8621-mobile-menu h4 {
  color: var(--w8621-line); font-size: 1.2rem; text-transform: uppercase;
  letter-spacing: .08em; margin: 18px 0 8px;
}
.w8621-mobile-menu a {
  display: block; padding: 11px 12px; color: var(--w8621-text);
  border-bottom: 1px solid var(--w8621-line-soft); font-size: 1.4rem;
}
.w8621-mobile-menu a:hover { background: rgba(192, 132, 43, .12); text-decoration: none; }
.w8621-menu-close {
  position: absolute; top: 14px; right: 14px; width: 36px; height: 36px;
  background: transparent; border: 0; color: var(--w8621-text); font-size: 1.8rem;
  cursor: pointer;
}

/* ===== Hero carousel ===== */
.w8621-hero {
  position: relative; overflow: hidden; border-radius: var(--w8621-radius);
  box-shadow: var(--w8621-shadow); margin: 12px 0 18px;
}
.w8621-hero-track { position: relative; height: 190px; }
.w8621-hero-slide {
  position: absolute; inset: 0; opacity: 0; transition: opacity .55s ease;
  background-size: cover; background-position: center;
}
.w8621-hero-slide.w8621-is-active { opacity: 1; }
.w8621-hero-slide a { display: block; width: 100%; height: 100%; }
.w8621-hero-cta {
  position: absolute; left: 12px; bottom: 12px; right: 12px;
  display: flex; gap: 8px; align-items: center;
}
.w8621-hero-dots {
  position: absolute; bottom: 8px; left: 0; right: 0;
  display: flex; justify-content: center; gap: 6px;
}
.w8621-hero-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(248, 248, 255, .45); border: 0; padding: 0; cursor: pointer;
}
.w8621-hero-dot.w8621-is-active { background: var(--w8621-primary-2); }

/* ===== Sections ===== */
.w8621-section { margin: 18px 0; padding: 0; }
.w8621-section-head {
  display: flex; align-items: center; gap: 10px; margin-bottom: 10px;
}
.w8621-section-head h2 {
  font-size: 1.6rem; margin: 0; color: var(--w8621-text); font-weight: 700;
}
.w8621-section-head .w8621-ico { color: var(--w8621-primary-2); font-size: 1.8rem; }
.w8621-section-intro { color: var(--w8621-text-muted); font-size: 1.35rem; margin: 0 0 12px; }

/* ===== Game grid ===== */
.w8621-filter-bar {
  display: flex; gap: 6px; overflow-x: auto; padding: 6px 0 10px;
  -webkit-overflow-scrolling: touch;
}
.w8621-filter-btn {
  flex: 0 0 auto; padding: 8px 14px; border-radius: 20px;
  background: var(--w8621-bg-card); color: var(--w8621-text-muted);
  border: 1px solid var(--w8621-line-soft); cursor: pointer;
  font-size: 1.25rem; white-space: nowrap;
}
.w8621-filter-btn.w8621-is-active {
  background: linear-gradient(135deg, #e0a84a, #c0842b); color: #1f2c38; border-color: transparent;
}
.w8621-game-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
}
.w8621-game-card {
  background: var(--w8621-bg-card); border-radius: var(--w8621-radius-sm);
  overflow: hidden; text-align: center; cursor: pointer;
  border: 1px solid var(--w8621-line-soft); transition: transform .15s ease;
}
.w8621-game-card:hover { transform: translateY(-2px); border-color: var(--w8621-primary-2); }
.w8621-game-card img {
  width: 100%; aspect-ratio: 1 / 1; object-fit: cover; background: #0f1620;
}
.w8621-game-card .w8621-game-name {
  display: block; padding: 6px 4px 8px; font-size: 1.15rem;
  color: var(--w8621-text); line-height: 1.25;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

/* ===== Cards & misc ===== */
.w8621-card {
  background: var(--w8621-bg-card); border-radius: var(--w8621-radius);
  padding: 14px 16px; border: 1px solid var(--w8621-line-soft);
  margin-bottom: 12px;
}
.w8621-card h3 { margin: 0 0 6px; font-size: 1.45rem; color: var(--w8621-text); }
.w8621-card p { margin: 0; color: var(--w8621-text-muted); font-size: 1.3rem; }

.w8621-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.w8621-stat-row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--w8621-line-soft); font-size: 1.3rem; }
.w8621-stat-row:last-child { border-bottom: 0; }
.w8621-stat-row strong { color: var(--w8621-primary-2); }

.w8621-pill {
  display: inline-block; padding: 2px 10px; border-radius: 12px;
  background: rgba(95, 183, 117, .15); color: var(--w8621-success);
  font-size: 1.15rem; margin-right: 4px;
}

/* ===== FAQ ===== */
.w8621-faq-item {
  background: var(--w8621-bg-card); border-radius: var(--w8621-radius-sm);
  margin-bottom: 8px; overflow: hidden; border: 1px solid var(--w8621-line-soft);
}
.w8621-faq-q {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 14px; cursor: pointer; font-weight: 700; font-size: 1.35rem;
  color: var(--w8621-text);
}
.w8621-faq-a { max-height: 0; overflow: hidden; transition: max-height .3s ease; padding: 0 14px; color: var(--w8621-text-muted); }
.w8621-faq-item.w8621-is-open .w8621-faq-a { max-height: 320px; padding: 0 14px 12px; }

/* ===== Testimonials ===== */
.w8621-testimonial {
  background: var(--w8621-bg-card); border-left: 3px solid var(--w8621-primary-2);
  padding: 12px 14px; border-radius: var(--w8621-radius-sm); margin-bottom: 10px;
}
.w8621-testimonial p { margin: 0 0 6px; font-size: 1.3rem; }
.w8621-testimonial cite { color: var(--w8621-line); font-style: normal; font-size: 1.2rem; }

/* ===== Footer ===== */
.w8621-footer {
  background: var(--w8621-bg-alt); color: var(--w8621-text-muted);
  padding: 22px 14px calc(var(--w8621-bottom-h) + 22px);
  margin-top: 22px; border-top: 1px solid var(--w8621-line-soft);
}
.w8621-footer h4 { color: var(--w8621-text); font-size: 1.3rem; margin: 12px 0 8px; text-transform: uppercase; letter-spacing: .05em; }
.w8621-footer a { color: var(--w8621-text-muted); display: block; padding: 4px 0; font-size: 1.25rem; }
.w8621-footer-promos { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 10px 0; }
.w8621-footer-copy { font-size: 1.15rem; color: var(--w8621-gray); margin-top: 14px; text-align: center; }

/* ===== Bottom nav ===== */
.w8621-bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 1000;
  height: var(--w8621-bottom-h);
  background: linear-gradient(180deg, #2b3e50 0%, #1a2530 100%);
  border-top: 1px solid var(--w8621-line-soft);
  display: flex; justify-content: space-around; align-items: stretch;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, .35);
}
.w8621-bottom-nav-btn {
  flex: 1 1 0; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; color: var(--w8621-text-muted); text-decoration: none;
  font-size: 1.05rem; padding: 4px 2px; min-width: 60px; min-height: 60px;
  transition: color .15s ease, transform .15s ease;
  background: transparent; border: 0; cursor: pointer;
}
.w8621-bottom-nav-btn .material-icons,
.w8621-bottom-nav-btn .ion,
.w8621-bottom-nav-btn i { font-size: 22px; }
.w8621-bottom-nav-btn:hover { color: var(--w8621-primary-2); transform: translateY(-1px); text-decoration: none; }
.w8621-bottom-nav-btn.w8621-is-current { color: var(--w8621-primary-2); }
.w8621-bottom-nav-btn.w8621-is-current::before {
  content: ''; position: absolute; top: 0; width: 30px; height: 3px;
  background: var(--w8621-primary-2); border-radius: 0 0 4px 4px;
}
.w8621-bottom-nav-btn { position: relative; }

/* ===== Back to top ===== */
.w8621-to-top {
  position: fixed; right: 14px; bottom: calc(var(--w8621-bottom-h) + 14px);
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--w8621-primary); color: #1f2c38; border: 0;
  font-size: 1.8rem; cursor: pointer; opacity: 0; pointer-events: none;
  transition: opacity .25s ease, transform .25s ease; z-index: 999;
  box-shadow: var(--w8621-shadow);
}
.w8621-to-top.w8621-is-visible { opacity: 1; pointer-events: auto; }

/* ===== Mobile bottom padding for content not covered by footer ===== */
@media (max-width: 768px) {
  main { padding-bottom: 80px; }
  .w8621-wrapper { padding-bottom: calc(var(--w8621-bottom-h) + 24px); }
}

/* ===== Desktop: hide bottom nav, widen container ===== */
@media (min-width: 769px) {
  :root { --w8621-container: 960px; }
  .w8621-bottom-nav { display: none; }
  .w8621-footer { padding-bottom: 22px; }
  .w8621-hero-track { height: 320px; }
  .w8621-game-grid { grid-template-columns: repeat(6, 1fr); }
  .w8621-grid-2 { grid-template-columns: repeat(3, 1fr); }
  .w8621-footer-promos { grid-template-columns: repeat(4, 1fr); }
  .w8621-wrapper { padding-bottom: 30px; }
}
@media (min-width: 992px) {
  :root { --w8621-container: 1140px; }
  .w8621-game-grid { grid-template-columns: repeat(8, 1fr); }
}

/* ===== Utilities ===== */
.w8621-text-center { text-align: center; }
.w8621-mt-0 { margin-top: 0; }
.w8621-mb-0 { margin-bottom: 0; }
.w8621-mt-12 { margin-top: 12px; }
.w8621-mb-12 { margin-bottom: 12px; }
.w8621-hidden { display: none !important; }
.w8621-lead { font-size: 1.4rem; color: var(--w8621-text-muted); }
.w8621-divider { height: 1px; background: var(--w8621-line-soft); margin: 16px 0; border: 0; }
.w8621-link-inline { color: var(--w8621-primary-2); font-weight: 700; }
.w8621-link-inline:hover { color: var(--w8621-primary); text-decoration: underline; }
.w8621-badges { display: flex; flex-wrap: wrap; gap: 6px; }
.w8621-badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 10px; border-radius: 12px; background: rgba(224, 168, 74, .15);
  color: var(--w8621-primary-2); font-size: 1.15rem;
}
