/**
 * PH22 Club - Main Stylesheet
 * Mobile-first responsive design
 * All classes use w5e92- prefix for namespace isolation
 */

/* CSS Variables */
:root {
  --w5e92-primary: #FFBF00;
  --w5e92-dark: #0F0F23;
  --w5e92-light-gray: #CED4DA;
  --w5e92-accent: #0097A7;
  --w5e92-mint: #E8F5E8;
  --w5e92-text-primary: #FFFFFF;
  --w5e92-text-secondary: #CED4DA;
  --w5e92-bg-primary: #0F0F23;
  --w5e92-bg-secondary: #1A1A35;
  --w5e92-bg-card: #252540;
  --w5e92-border: rgba(206, 212, 218, 0.1);
  --w5e92-shadow: rgba(0, 0, 0, 0.3);
  --w5e92-header-height: 64px;
  --w5e92-bottom-nav-height: 64px;
}

/* Base Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 62.5%;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 1.4rem;
  line-height: 1.6;
  color: var(--w5e92-text-primary);
  background-color: var(--w5e92-bg-primary);
  overflow-x: hidden;
}

/* Container & Layout */
.w5e92-container {
  max-width: 430px;
  margin: 0 auto;
  padding: 0 1.6rem;
}

.w5e92-wrapper {
  padding-top: var(--w5e92-header-height);
  padding-bottom: calc(var(--w5e92-bottom-nav-height) + 2rem);
  min-height: 100vh;
}

.w5e92-section {
  padding: 3rem 0;
}

.w5e92-grid {
  display: grid;
  gap: 1.6rem;
}

.w5e92-grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

.w5e92-grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.w5e92-grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

/* Header */
.w5e92-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--w5e92-header-height);
  background: linear-gradient(135deg, var(--w5e92-dark) 0%, var(--w5e92-bg-secondary) 100%);
  border-bottom: 2px solid var(--w5e92-primary);
  z-index: 1000;
  box-shadow: 0 2px 12px var(--w5e92-shadow);
  transition: all 0.3s ease;
}

.w5e92-header-scrolled {
  box-shadow: 0 4px 20px var(--w5e92-shadow);
  background: var(--w5e92-dark);
}

.w5e92-header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: 430px;
  margin: 0 auto;
  padding: 0 1.6rem;
}

.w5e92-logo-wrapper {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
}

.w5e92-logo-img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.w5e92-logo-text {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--w5e92-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.w5e92-header-actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.w5e92-btn {
  padding: 0.8rem 1.6rem;
  border: none;
  border-radius: 8px;
  font-size: 1.3rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
}

.w5e92-btn-primary {
  background: linear-gradient(135deg, var(--w5e92-primary) 0%, #FFD700 100%);
  color: var(--w5e92-dark);
}

.w5e92-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 191, 0, 0.4);
}

.w5e92-btn-secondary {
  background: transparent;
  color: var(--w5e92-primary);
  border: 2px solid var(--w5e92-primary);
}

.w5e92-btn-secondary:hover {
  background: var(--w5e92-primary);
  color: var(--w5e92-dark);
}

.w5e92-hamburger {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  min-height: 44px;
  min-width: 44px;
  align-items: center;
  justify-content: center;
}

.w5e92-hamburger span {
  display: block;
  width: 24px;
  height: 3px;
  background: var(--w5e92-primary);
  border-radius: 2px;
  transition: all 0.3s ease;
}

.w5e92-hamburger-active span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.w5e92-hamburger-active span:nth-child(2) {
  opacity: 0;
}

.w5e92-hamburger-active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* Mobile Menu */
.w5e92-mobile-menu {
  position: fixed;
  top: var(--w5e92-header-height);
  right: -100%;
  width: 280px;
  height: calc(100vh - var(--w5e92-header-height));
  background: var(--w5e92-bg-secondary);
  z-index: 9999;
  transition: right 0.3s ease;
  overflow-y: auto;
  box-shadow: -4px 0 20px var(--w5e92-shadow);
}

.w5e92-menu-active {
  right: 0;
}

.w5e92-menu-overlay {
  position: fixed;
  top: var(--w5e92-header-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.w5e92-overlay-active {
  opacity: 1;
  visibility: visible;
}

.w5e92-nav-list {
  list-style: none;
  padding: 2rem 0;
}

.w5e92-nav-item {
  border-bottom: 1px solid var(--w5e92-border);
}

.w5e92-nav-link {
  display: block;
  padding: 1.6rem 2rem;
  color: var(--w5e92-text-primary);
  text-decoration: none;
  font-size: 1.5rem;
  transition: all 0.3s ease;
}

.w5e92-nav-link:hover,
.w5e92-nav-active {
  background: var(--w5e92-bg-card);
  color: var(--w5e92-primary);
  padding-left: 2.4rem;
}

/* Carousel */
.w5e92-carousel {
  position: relative;
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 4px 20px var(--w5e92-shadow);
}

.w5e92-carousel-track {
  position: relative;
  width: 100%;
  height: 200px;
}

.w5e92-carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.5s ease;
  cursor: pointer;
}

.w5e92-slide-active {
  opacity: 1;
}

.w5e92-carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.w5e92-carousel-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.w5e92-carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.w5e92-dot-active {
  background: var(--w5e92-primary);
  width: 12px;
  height: 12px;
}

/* Typography */
.w5e92-h1 {
  font-size: 2.8rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 2rem;
  color: var(--w5e92-primary);
}

.w5e92-h2 {
  font-size: 2.4rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 1.6rem;
  color: var(--w5e92-text-primary);
}

.w5e92-h3 {
  font-size: 2rem;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 1.2rem;
  color: var(--w5e92-text-primary);
}

.w5e92-text {
  font-size: 1.4rem;
  line-height: 1.6;
  color: var(--w5e92-text-secondary);
  margin-bottom: 1.2rem;
}

/* Game Cards */
.w5e92-game-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
  margin: 2rem 0;
}

.w5e92-game-card {
  background: var(--w5e92-bg-card);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  cursor: pointer;
}

.w5e92-game-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 20px rgba(255, 191, 0, 0.2);
}

.w5e92-game-img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.w5e92-game-name {
  padding: 0.8rem;
  font-size: 1.1rem;
  text-align: center;
  color: var(--w5e92-text-primary);
  font-weight: 500;
  line-height: 1.3;
  min-height: 4rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Bottom Navigation */
.w5e92-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--w5e92-bottom-nav-height);
  background: linear-gradient(135deg, var(--w5e92-dark) 0%, var(--w5e92-bg-secondary) 100%);
  border-top: 2px solid var(--w5e92-primary);
  z-index: 1000;
  box-shadow: 0 -2px 12px var(--w5e92-shadow);
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 0.8rem;
}

.w5e92-bottom-nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 64px;
  min-height: 56px;
  text-decoration: none;
  color: var(--w5e92-text-secondary);
  transition: all 0.3s ease;
  border-radius: 8px;
  padding: 0.4rem;
}

.w5e92-bottom-nav-btn:hover,
.w5e92-bottom-nav-btn.w5e92-nav-active {
  color: var(--w5e92-primary);
  background: rgba(255, 191, 0, 0.1);
}

.w5e92-bottom-nav-icon {
  font-size: 2.4rem;
}

.w5e92-bottom-nav-text {
  font-size: 1.1rem;
  font-weight: 500;
  text-align: center;
}

/* Footer */
.w5e92-footer {
  background: var(--w5e92-bg-secondary);
  padding: 3rem 0 calc(var(--w5e92-bottom-nav-height) + 2rem);
  margin-top: 4rem;
  border-top: 2px solid var(--w5e92-primary);
}

.w5e92-footer-section {
  margin-bottom: 2rem;
}

.w5e92-footer-title {
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--w5e92-primary);
  margin-bottom: 1.2rem;
}

.w5e92-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.2rem;
  list-style: none;
}

.w5e92-footer-link {
  color: var(--w5e92-text-secondary);
  text-decoration: none;
  font-size: 1.3rem;
  transition: color 0.3s ease;
}

.w5e92-footer-link:hover {
  color: var(--w5e92-primary);
}

.w5e92-partners {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.2rem;
  margin-top: 1.6rem;
}

.w5e92-partner-img {
  width: 100%;
  height: auto;
  opacity: 0.6;
  transition: opacity 0.3s ease;
}

.w5e92-partner-img:hover {
  opacity: 1;
}

.w5e92-copyright {
  text-align: center;
  color: var(--w5e92-text-secondary);
  font-size: 1.2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--w5e92-border);
  margin-top: 2rem;
}

/* Card Components */
.w5e92-card {
  background: var(--w5e92-bg-card);
  border-radius: 12px;
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 2px 8px var(--w5e92-shadow);
}

/* FAQ */
.w5e92-faq-item {
  background: var(--w5e92-bg-card);
  border-radius: 12px;
  margin-bottom: 1.2rem;
  overflow: hidden;
}

.w5e92-faq-question {
  padding: 1.6rem;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--w5e92-text-primary);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: all 0.3s ease;
}

.w5e92-faq-question:hover {
  background: rgba(255, 191, 0, 0.1);
}

.w5e92-faq-answer {
  padding: 0 1.6rem;
  max-height: 0;
  overflow: hidden;
  transition: all 0.3s ease;
}

.w5e92-faq-active .w5e92-faq-answer {
  padding: 1.6rem;
  max-height: 500px;
}

/* Responsive */
@media (min-width: 769px) {
  .w5e92-bottom-nav {
    display: none;
  }

  .w5e92-wrapper {
    padding-bottom: 2rem;
  }

  .w5e92-footer {
    padding: 3rem 0 2rem;
  }
}

@media (max-width: 768px) {
  main {
    padding-bottom: 8rem;
  }
}

/* Utility Classes */
.w5e92-text-center {
  text-align: center;
}

.w5e92-mt-1 { margin-top: 1rem; }
.w5e92-mt-2 { margin-top: 2rem; }
.w5e92-mb-1 { margin-bottom: 1rem; }
.w5e92-mb-2 { margin-bottom: 2rem; }
