/* ============================================================
   ff1686.click - Core stylesheet
   All custom classes use the "pgaf-" prefix for namespace isolation
   Color palette: #34495E | #1B263B | #778899
   Mobile-first; root font-size 62.5% (1rem = 10px)
   ============================================================ */

:root {
  --pgaf-primary: #34495E;
  --pgaf-bg: #1B263B;
  --pgaf-accent: #778899;
  --pgaf-text: #ECEFF1;
  --pgaf-text-muted: #B0BEC5;
  --pgaf-gold: #F4C430;
  --pgaf-card: #2C3E50;
  --pgaf-border: #3A4F66;
}

/* ---------- Reset & base ---------- */
* { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: "Segoe UI", "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  background: var(--pgaf-bg);
  color: var(--pgaf-text);
  font-size: 1.6rem;
  line-height: 1.5rem;
  min-height: 100vh;
  max-width: 100vw;
  overflow-x: hidden;
}

a { color: var(--pgaf-gold); text-decoration: none; }

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

h1, h2, h3, h4 { line-height: 1.5; color: var(--pgaf-text); }

h1 { font-size: 2.4rem; }
h2 { font-size: 2.2rem; }
h3 { font-size: 2.0rem; }

/* ---------- Layout ---------- */
.pgaf-container {
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
  padding: 1.2rem;
}

.pgaf-wrapper { width: 100%; }

/* ---------- Header ---------- */
.pgaf-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: linear-gradient(135deg, var(--pgaf-primary), var(--pgaf-bg));
  border-bottom: 0.2rem solid var(--pgaf-border);
  box-shadow: 0 0.2rem 0.8rem rgba(0,0,0,0.35);
}

.pgaf-header-inner {
  max-width: 430px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 1.2rem;
}

.pgaf-logo {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  color: var(--pgaf-gold);
  font-weight: 700;
  font-size: 2.0rem;
}

.pgaf-logo img {
  width: 3.2rem;
  height: 3.2rem;
  border-radius: 50%;
  border: 0.2rem solid var(--pgaf-gold);
}

.pgaf-header-actions { display: flex; gap: 0.8rem; align-items: center; }

.pgaf-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.8rem 1.6rem;
  border-radius: 2.4rem;
  font-weight: 700;
  font-size: 1.3rem;
  cursor: pointer;
  border: none;
  transition: transform 0.15s ease, opacity 0.15s ease;
  min-height: 4.4rem;
  touch-action: manipulation;
}

.pgaf-btn:active { transform: scale(0.96); opacity: 0.9; }

.pgaf-btn-login {
  background: transparent;
  color: var(--pgaf-text);
  border: 0.2rem solid var(--pgaf-accent);
}

.pgaf-btn-register {
  background: linear-gradient(135deg, var(--pgaf-gold), #E0A800);
  color: #1B263B;
}

.pgaf-menu-toggle {
  background: transparent;
  border: none;
  color: var(--pgaf-text);
  font-size: 2.4rem;
  cursor: pointer;
  min-width: 4.4rem;
  min-height: 4.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ---------- Mobile menu (slide down) ---------- */
.pgaf-menu-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.5);
  z-index: 9998;
}

.pgaf-mobile-menu {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  background: var(--pgaf-bg);
  border-bottom: 0.2rem solid var(--pgaf-gold);
  transform: translateY(-100%);
  transition: transform 0.3s ease;
  z-index: 9999;
  max-height: 80vh;
  overflow-y: auto;
  padding: 6.4rem 1.2rem 1.6rem;
}

.pgaf-mobile-menu-open { transform: translateY(0); }

.pgaf-nav-list { list-style: none; display: flex; flex-direction: column; gap: 0.4rem; }

.pgaf-nav-link {
  display: block;
  padding: 1.2rem 1.6rem;
  color: var(--pgaf-text);
  font-size: 1.5rem;
  border-radius: 0.8rem;
  transition: background 0.15s;
}

.pgaf-nav-link:hover, .pgaf-nav-link:focus {
  background: var(--pgaf-primary);
  color: var(--pgaf-gold);
}

.pgaf-nav-section-title {
  color: var(--pgaf-gold);
  font-size: 1.4rem;
  font-weight: 700;
  margin: 1.2rem 0 0.6rem;
  padding-left: 1.6rem;
}

.pgaf-menu-overlay.pgaf-visible { display: block; }

.pgaf-mobile-menu-open + .pgaf-menu-overlay,
.pgaf-mobile-menu.pgaf-mobile-menu-open ~ .pgaf-menu-overlay {
  display: block;
}

/* ---------- Main ---------- */
.pgaf-main {
  padding-top: 7.2rem;
  padding-bottom: 8rem;
  max-width: 430px;
  margin: 0 auto;
}

/* ---------- Carousel ---------- */
.pgaf-carousel {
  position: relative;
  width: 100%;
  height: 18rem;
  border-radius: 1.2rem;
  overflow: hidden;
  margin-bottom: 1.6rem;
  box-shadow: 0 0.4rem 1.2rem rgba(0,0,0,0.4);
}

.pgaf-carousel-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.6s ease;
  cursor: pointer;
}

.pgaf-carousel-slide img { width: 100%; height: 100%; object-fit: cover; }

.pgaf-slide-active { opacity: 1; }

.pgaf-carousel-caption {
  position: absolute;
  bottom: 1.2rem;
  left: 1.2rem;
  background: rgba(27,38,59,0.78);
  padding: 0.6rem 1.2rem;
  border-radius: 0.8rem;
  color: var(--pgaf-gold);
  font-weight: 700;
  font-size: 1.4rem;
  z-index: 2;
}

.pgaf-carousel-dots {
  position: absolute;
  bottom: 0.6rem;
  right: 1.2rem;
  display: flex;
  gap: 0.4rem;
  z-index: 2;
}

.pgaf-carousel-dot {
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  cursor: pointer;
  border: none;
}

.pgaf-dot-active { background: var(--pgaf-gold); }

/* ---------- Section ---------- */
.pgaf-section {
  margin-bottom: 2.4rem;
  padding: 0 1.2rem;
}

.pgaf-section-title {
  font-size: 2.0rem;
  color: var(--pgaf-gold);
  margin-bottom: 1.2rem;
  padding-left: 0.8rem;
  border-left: 0.4rem solid var(--pgaf-gold);
}

/* ---------- Game category grid ---------- */
.pgaf-cat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.8rem;
  margin-bottom: 1.6rem;
}

.pgaf-cat-card {
  background: var(--pgaf-card);
  border-radius: 1.0rem;
  border: 0.2rem solid var(--pgaf-border);
  overflow: hidden;
  text-align: center;
  padding: 1.2rem;
  transition: transform 0.2s;
  cursor: pointer;
}

.pgaf-cat-card:active { transform: scale(0.97); }

.pgaf-cat-card i, .pgaf-cat-card span.material-icons-outlined {
  font-size: 2.8rem;
  color: var(--pgaf-gold);
  margin-bottom: 0.6rem;
  display: block;
}

.pgaf-cat-name {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--pgaf-text);
}

/* ---------- Compact game grid ---------- */
.pgaf-game-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.8rem;
}

.pgaf-game-tile {
  background: var(--pgaf-card);
  border-radius: 0.8rem;
  overflow: hidden;
  border: 0.2rem solid var(--pgaf-border);
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s;
}

.pgaf-game-tile:active {
  transform: scale(0.96);
  border-color: var(--pgaf-gold);
}

.pgaf-game-tile img {
  width: 100%;
  height: 8.5rem;
  object-fit: cover;
}

.pgaf-game-name {
  font-size: 1.1rem;
  color: var(--pgaf-text);
  padding: 0.5rem 0.4rem;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---------- Info / text blocks ---------- */
.pgaf-text-block {
  background: var(--pgaf-card);
  border-radius: 1.0rem;
  padding: 1.6rem;
  margin-bottom: 1.6rem;
  border: 0.2rem solid var(--pgaf-border);
}

.pgaf-text-block h2 { color: var(--pgaf-gold); margin-bottom: 0.8rem; }

.pgaf-text-block p {
  color: var(--pgaf-text-muted);
  margin-bottom: 0.8rem;
  line-height: 1.6;
}

.pgaf-text-block a { color: var(--pgaf-gold); font-weight: 600; }

/* ---------- FAQ ---------- */
.pgaf-faq-item {
  background: var(--pgaf-card);
  border: 0.2rem solid var(--pgaf-border);
  border-radius: 0.8rem;
  margin-bottom: 0.8rem;
  overflow: hidden;
}

.pgaf-faq-question {
  padding: 1.4rem;
  font-weight: 700;
  color: var(--pgaf-text);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.5rem;
}

.pgaf-faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  padding: 0 1.4rem;
  color: var(--pgaf-text-muted);
}

/* ---------- Promo CTA ---------- */
.pgaf-cta {
  background: linear-gradient(135deg, var(--pgaf-primary), var(--pgaf-card));
  border-radius: 1.0rem;
  padding: 1.6rem;
  text-align: center;
  margin-bottom: 1.6rem;
  border: 0.2rem solid var(--pgaf-gold);
}

.pgaf-cta h3 { color: var(--pgaf-gold); margin-bottom: 0.6rem; }
.pgaf-cta p { color: var(--pgaf-text-muted); margin-bottom: 1.2rem; }

/* ---------- Footer ---------- */
.pgaf-footer {
  background: var(--pgaf-primary);
  padding: 2.4rem 1.2rem 9.6rem;
  border-top: 0.2rem solid var(--pgaf-gold);
  max-width: 430px;
  margin: 0 auto;
}

.pgaf-footer-brand {
  color: var(--pgaf-gold);
  font-size: 2.0rem;
  font-weight: 700;
  margin-bottom: 1.2rem;
}

.pgaf-footer-desc {
  color: var(--pgaf-text-muted);
  font-size: 1.3rem;
  line-height: 1.6;
  margin-bottom: 1.6rem;
}

.pgaf-footer-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.8rem;
  margin-bottom: 2.0rem;
}

.pgaf-footer-links a {
  color: var(--pgaf-text);
  font-size: 1.3rem;
  padding: 0.4rem 0;
}

.pgaf-footer-promo-btns {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.8rem;
  margin: 1.6rem 0;
}

.pgaf-footer-promo-btn {
  background: var(--pgaf-gold);
  color: var(--pgaf-bg);
  padding: 1.0rem;
  text-align: center;
  border-radius: 0.6rem;
  font-weight: 700;
  font-size: 1.3rem;
  cursor: pointer;
  border: none;
}

.pgaf-footer-copy {
  color: var(--pgaf-accent);
  font-size: 1.2rem;
  text-align: center;
  border-top: 0.1rem solid var(--pgaf-border);
  padding-top: 1.2rem;
}

/* ---------- Bottom nav ---------- */
.pgaf-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 6.0rem;
  background: linear-gradient(180deg, var(--pgaf-primary), #2C3E50);
  border-top: 0.2rem solid var(--pgaf-gold);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 1000;
  box-shadow: 0 -0.4rem 1.2rem rgba(0,0,0,0.4);
}

.pgaf-navbtn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 6.0rem;
  min-height: 6.0rem;
  background: transparent;
  border: none;
  color: var(--pgaf-text-muted);
  cursor: pointer;
  text-decoration: none;
  transition: color 0.2s ease;
  font-size: 1.1rem;
  gap: 0.2rem;
}

.pgaf-navbtn i,
.pgaf-navbtn span.material-icons-outlined,
.pgaf-navbtn span.material-icons {
  font-size: 2.4rem;
}

.pgaf-navbtn span { font-size: 1.1rem; }

.pgaf-navbtn:hover, .pgaf-navbtn:active { color: var(--pgaf-gold); }

.pgaf-navbtn-active { color: var(--pgaf-gold); }

.pgaf-navbtn-active i,
.pgaf-navbtn-active span.material-icons-outlined,
.pgaf-navbtn-active span.material-icons {
  filter: drop-shadow(0 0 0.4rem var(--pgaf-gold));
  transform: scale(1.1);
}

/* ---------- Desktop ---------- */
@media (min-width: 769px) {
  .pgaf-bottom-nav { display: none; }
  .pgaf-menu-toggle { display: none; }
  .pgaf-header-inner,
  .pgaf-main,
  .pgaf-footer {
    max-width: 768px;
  }
  body { font-size: 1.7rem; }
  .pgaf-game-grid { grid-template-columns: repeat(5, 1fr); }
  .pgaf-cat-grid { grid-template-columns: repeat(5, 1fr); }
  .pgaf-footer-promo-btns { grid-template-columns: repeat(4, 1fr); }
  .pgaf-footer { padding-bottom: 2.4rem; }
  .pgaf-main { padding-bottom: 2.4rem; }
}

/* ---------- Mobile bottom padding ---------- */
@media (max-width: 768px) {
  .pgaf-main { padding-bottom: 8rem; }
}