/*
 * win99 club - core theme stylesheet
 * File: css/theme-d5ea.css
 * All custom classes use the pgd5- prefix.
 * Comments are in English per project convention.
 */

:root {
  --pgd5-bg: #262626;
  --pgd5-bg-alt: #1c1c1c;
  --pgd5-surface: #333333;
  --pgd5-text: #f0f0f0;
  --pgd5-text-muted: #b5b5b5;
  --pgd5-primary: #808080;
  --pgd5-accent: #c9a24b;
  --pgd5-accent-soft: #f0d98a;
  --pgd5-border: #4a4a4a;
  --pgd5-danger: #d23b3b;
  --pgd5-success: #3ba971;
  --pgd5-radius: 10px;
  --pgd5-header-h: 6.4rem;
  --pgd5-nav-h: 6.4rem;
  --pgd5-shadow: 0 4px 18px rgba(0, 0, 0, 0.45);
}

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

html { font-size: 62.5%; scroll-behavior: smooth; }

body {
  font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--pgd5-bg);
  color: var(--pgd5-text);
  line-height: 1.5;
  font-size: 1.5rem;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

.pgd5-wrapper { max-width: 430px; margin: 0 auto; min-height: 100vh; position: relative; background: var(--pgd5-bg); }

.pgd5-container { width: 100%; padding: 0 1.2rem; }

/* ===== Header ===== */
.pgd5-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: linear-gradient(180deg, #2e2e2e 0%, #262626 100%);
  border-bottom: 1px solid var(--pgd5-border);
  box-shadow: var(--pgd5-shadow);
}
.pgd5-header-inner {
  max-width: 430px; margin: 0 auto; height: var(--pgd5-header-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 1.2rem; gap: 0.8rem;
}
.pgd5-logo { display: flex; align-items: center; gap: 0.6rem; color: var(--pgd5-text); font-weight: 700; font-size: 1.6rem; }
.pgd5-logo img { width: 2.8rem; height: 2.8rem; border-radius: 6px; }
.pgd5-logo span { color: var(--pgd5-accent); }

.pgd5-header-actions { display: flex; align-items: center; gap: 0.6rem; }
.pgd5-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
  border: none; border-radius: var(--pgd5-radius); cursor: pointer;
  font-size: 1.3rem; font-weight: 700; padding: 0.7rem 1.1rem; min-height: 3.6rem;
  transition: transform .15s ease, background .2s ease, box-shadow .2s ease;
}
.pgd5-btn:active { transform: scale(0.96); }
.pgd5-btn-register { background: linear-gradient(135deg, var(--pgd5-accent), #b8862f); color: #1a1a1a; box-shadow: 0 3px 10px rgba(201,162,75,.35); }
.pgd5-btn-login { background: transparent; color: var(--pgd5-text); border: 1px solid var(--pgd5-border); }
.pgd5-btn-login:hover { border-color: var(--pgd5-accent); }

.pgd5-menu-btn {
  background: transparent; border: 1px solid var(--pgd5-border); color: var(--pgd5-text);
  width: 3.6rem; height: 3.6rem; border-radius: 8px; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; font-size: 1.8rem;
}

/* Expandable nav menu */
.pgd5-nav-menu {
  max-height: 0; overflow: hidden; transition: max-height .3s ease;
  background: var(--pgd5-bg-alt); border-top: 1px solid var(--pgd5-border);
}
.pgd5-nav-menu.pgd5-open { max-height: 480px; }
.pgd5-nav-list { list-style: none; padding: 0.8rem 1.2rem 1.2rem; display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.pgd5-nav-list a {
  display: flex; align-items: center; gap: 0.5rem; padding: 0.8rem 0.9rem;
  background: var(--pgd5-surface); border: 1px solid var(--pgd5-border); border-radius: 8px;
  color: var(--pgd5-text); font-size: 1.25rem; font-weight: 600;
}
.pgd5-nav-list a:hover { border-color: var(--pgd5-accent); text-decoration: none; }

/* ===== Main ===== */
.pgd5-main { padding-top: calc(var(--pgd5-header-h) + 1rem); }

/* ===== Hero / Carousel ===== */
.pgd5-hero { position: relative; margin: 0 0 1.2rem; border-radius: 0 0 16px 16px; overflow: hidden; }
.pgd5-hero-slides { position: relative; height: 180px; }
.pgd5-hero-slide {
  position: absolute; inset: 0; opacity: 0; transition: opacity .8s ease;
  display: flex; align-items: flex-end; padding: 1.2rem;
}
.pgd5-hero-slide img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.pgd5-hero-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.1), rgba(0,0,0,.75)); z-index: 1; }
.pgd5-hero-caption { position: relative; z-index: 2; color: #fff; }
.pgd5-hero-caption h2 { font-size: 1.8rem; margin-bottom: 0.4rem; }
.pgd5-hero-caption p { font-size: 1.25rem; color: #e6e6e6; }
.pgd5-hero-slide.pgd5-active { opacity: 1; }

.pgd5-hero-cta { margin: 0 1.2rem 1.2rem; }
.pgd5-cta-row { display: flex; gap: 0.6rem; }
.pgd5-cta-row .pgd5-btn { flex: 1; }

/* ===== Section ===== */
.pgd5-section { padding: 1.4rem 0; }
.pgd5-section-title { font-size: 1.7rem; font-weight: 700; margin-bottom: 0.8rem; display: flex; align-items: center; gap: 0.5rem; }
.pgd5-section-title i { color: var(--pgd5-accent); }

/* ===== Filter tabs ===== */
.pgd5-filter { display: flex; gap: 0.5rem; overflow-x: auto; padding: 0.4rem 0 1rem; -webkit-overflow-scrolling: touch; }
.pgd5-filter::-webkit-scrollbar { display: none; }
.pgd5-filter-tab {
  flex: 0 0 auto; padding: 0.55rem 1rem; border-radius: 20px; background: var(--pgd5-surface);
  color: var(--pgd5-text-muted); font-size: 1.2rem; font-weight: 600; border: 1px solid var(--pgd5-border);
  cursor: pointer; white-space: nowrap;
}
.pgd5-filter-tab.pgd5-active { background: var(--pgd5-accent); color: #1a1a1a; border-color: var(--pgd5-accent); }

/* ===== Game grid ===== */
.pgd5-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.7rem; }
.pgd5-game-card {
  background: var(--pgd5-surface); border: 1px solid var(--pgd5-border); border-radius: 10px;
  overflow: hidden; cursor: pointer; transition: transform .15s ease, border-color .2s ease;
  text-align: center;
}
.pgd5-game-card:hover { transform: translateY(-2px); border-color: var(--pgd5-accent); }
.pgd5-game-card img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.pgd5-game-name { font-size: 1.1rem; padding: 0.5rem 0.3rem; color: var(--pgd5-text); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ===== Promo / features ===== */
.pgd5-features { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.7rem; }
.pgd5-feature {
  background: var(--pgd5-surface); border: 1px solid var(--pgd5-border); border-radius: 10px; padding: 1rem;
  display: flex; flex-direction: column; gap: 0.4rem;
}
.pgd5-feature i { font-size: 2.2rem; color: var(--pgd5-accent); }
.pgd5-feature h3 { font-size: 1.3rem; }
.pgd5-feature p { font-size: 1.15rem; color: var(--pgd5-text-muted); }

.pgd5-promo-banner {
  background: linear-gradient(135deg, #3a2e15, #262626); border: 1px solid var(--pgd5-accent);
  border-radius: 12px; padding: 1.2rem; display: flex; flex-direction: column; gap: 0.6rem; margin: 1.2rem 0;
}
.pgd5-promo-banner h3 { color: var(--pgd5-accent-soft); font-size: 1.5rem; }
.pgd5-promo-banner p { color: var(--pgd5-text-muted); font-size: 1.2rem; }

.pgd5-text-block { font-size: 1.3rem; color: var(--pgd5-text-muted); line-height: 1.6; }
.pgd5-text-block h2 { color: var(--pgd5-text); font-size: 1.7rem; margin: 1.4rem 0 0.6rem; }
.pgd5-text-block h3 { color: var(--pgd5-text); font-size: 1.4rem; margin: 1rem 0 0.5rem; }
.pgd5-text-block p { margin-bottom: 0.8rem; }
.pgd5-text-block a { font-weight: 700; }

.pgd5-partners { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.5rem; margin-top: 0.8rem; }
.pgd5-partners img { background: #fff; border-radius: 6px; padding: 0.2rem; }

/* ===== Footer ===== */
.pgd5-footer {
  background: var(--pgd5-bg-alt); border-top: 1px solid var(--pgd5-border); padding: 1.6rem 1.2rem 2rem; margin-top: 1.6rem;
}
.pgd5-footer-brand { font-size: 1.3rem; color: var(--pgd5-text-muted); margin-bottom: 1rem; line-height: 1.6; }
.pgd5-footer-links { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; margin-bottom: 1rem; }
.pgd5-footer-links a { color: var(--pgd5-text-muted); font-size: 1.2rem; padding: 0.3rem 0; }
.pgd5-footer-promo { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.pgd5-footer-promo .pgd5-btn { flex: 1 1 auto; min-width: 45%; }
.pgd5-footer-copy { font-size: 1.1rem; color: #777; text-align: center; padding-top: 0.8rem; border-top: 1px solid var(--pgd5-border); }

/* ===== Mobile bottom nav ===== */
.pgd5-bottomnav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 1000;
  background: linear-gradient(180deg, #2e2e2e, #1c1c1c);
  border-top: 1px solid var(--pgd5-border); box-shadow: 0 -3px 14px rgba(0,0,0,.5);
  display: flex; justify-content: space-around; align-items: stretch; height: var(--pgd5-nav-h);
}
.pgd5-navbtn {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.2rem;
  background: transparent; border: none; color: var(--pgd5-text-muted); cursor: pointer;
  min-width: 60px; min-height: 60px; transition: color .2s ease, transform .15s ease; text-decoration: none;
}
.pgd5-navbtn i, .pgd5-navbtn .material-icons-outlined, .pgd5-navbtn ion-icon { font-size: 24px; }
.pgd5-navbtn .material-icons-outlined { font-size: 26px; }
.pgd5-navbtn ion-icon { font-size: 26px; --ionicon-stroke-width: 32px; }
.pgd5-navbtn span { font-size: 1.05rem; font-weight: 600; }
.pgd5-navbtn:active { transform: scale(0.92); }
.pgd5-navbtn.pgd5-current { color: var(--pgd5-accent); }
.pgd5-navbtn:hover { color: var(--pgd5-accent-soft); text-decoration: none; }

/* Bottom padding for main content so fixed nav does not cover content */
@media (max-width: 768px) {
  .pgd5-main { padding-bottom: calc(var(--pgd5-nav-h) + 1.2rem); }
}

/* Desktop: hide bottom nav, widen wrapper */
@media (min-width: 769px) {
  .pgd5-bottomnav { display: none; }
  .pgd5-wrapper { max-width: 960px; }
  .pgd5-header-inner { max-width: 960px; }
  .pgd5-grid { grid-template-columns: repeat(6, 1fr); }
  .pgd5-features { grid-template-columns: repeat(4, 1fr); }
  .pgd5-hero-slides { height: 320px; }
}
