/* PH Bingo Layout Styles - All classes use pg39- prefix */
/* Color palette: #40E0D0 | #FFFFFF | #E0F2F1 | #FFEFD5 | #F0FDFF | #0F0F23 */

:root {
  --pg39-primary: #40E0D0;
  --pg39-white: #FFFFFF;
  --pg39-light-bg: #E0F2F1;
  --pg39-warm: #FFEFD5;
  --pg39-ice: #F0FDFF;
  --pg39-dark: #0F0F23;
  --pg39-accent: #40E0D0;
  --pg39-text: #FFFFFF;
  --pg39-text-dark: #0F0F23;
  --pg39-gradient: linear-gradient(135deg, #0F0F23 0%, #1a1a3e 50%, #0F0F23 100%);
  --pg39-card-bg: rgba(255,255,255,0.06);
  --pg39-border: rgba(64,224,208,0.25);
  --pg39-shadow: 0 4px 20px rgba(64,224,208,0.15);
}

/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 62.5%; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 1.6rem;
  line-height: 1.5rem;
  background: var(--pg39-dark);
  color: var(--pg39-text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--pg39-primary); text-decoration: none; transition: color 0.3s; }
a:hover { color: #7fffd4; }
img { max-width: 100%; height: auto; display: block; }

/* Container */
.pg39-container { max-width: 430px; margin: 0 auto; padding: 0 1.2rem; width: 100%; }
.pg39-wrapper { width: 100%; position: relative; }

/* Header */
.pg39-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: linear-gradient(180deg, var(--pg39-dark) 0%, rgba(15,15,35,0.95) 100%);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--pg39-border);
  height: 5.6rem;
}
.pg39-header-inner {
  display: flex; align-items: center; justify-content: space-between;
  max-width: 430px; margin: 0 auto; padding: 0 1.2rem; height: 100%;
}
.pg39-logo { display: flex; align-items: center; gap: 0.8rem; }
.pg39-logo img { width: 3.2rem; height: 3.2rem; border-radius: 0.6rem; }
.pg39-logo-text { font-size: 1.8rem; font-weight: 800; color: var(--pg39-primary); letter-spacing: -0.5px; }
.pg39-header-actions { display: flex; align-items: center; gap: 0.6rem; }
.pg39-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
  padding: 0.7rem 1.4rem; border-radius: 2rem; font-size: 1.3rem; font-weight: 700;
  cursor: pointer; border: none; transition: all 0.3s ease; min-height: 3.6rem;
  text-decoration: none; white-space: nowrap;
}
.pg39-btn-register {
  background: var(--pg39-primary); color: var(--pg39-dark);
  box-shadow: 0 0 16px rgba(64,224,208,0.4);
}
.pg39-btn-register:hover { background: #5ef5e5; transform: translateY(-1px); box-shadow: 0 0 24px rgba(64,224,208,0.6); }
.pg39-btn-login {
  background: transparent; color: var(--pg39-primary);
  border: 1.5px solid var(--pg39-primary);
}
.pg39-btn-login:hover { background: rgba(64,224,208,0.1); }
.pg39-hamburger {
  background: none; border: none; color: var(--pg39-primary);
  font-size: 2.4rem; cursor: pointer; padding: 0.4rem; display: none;
}

/* Desktop nav */
.pg39-desktop-nav { display: flex; align-items: center; gap: 1.6rem; }
.pg39-desktop-nav a { color: var(--pg39-text); font-size: 1.3rem; font-weight: 500; opacity: 0.85; transition: all 0.3s; }
.pg39-desktop-nav a:hover { opacity: 1; color: var(--pg39-primary); }

/* Mobile Menu */
.pg39-menu-overlay {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.7); z-index: 9998; opacity: 0;
  pointer-events: none; transition: opacity 0.3s;
}
.pg39-overlay-active { opacity: 1; pointer-events: auto; }
.pg39-mobile-menu {
  position: fixed; top: 0; right: -80%; width: 75%; height: 100vh;
  background: var(--pg39-dark); z-index: 9999;
  transition: right 0.35s cubic-bezier(0.4,0,0.2,1);
  padding: 2rem; border-left: 1px solid var(--pg39-border);
  overflow-y: auto;
}
.pg39-menu-active { right: 0; }
.pg39-menu-close {
  background: none; border: none; color: var(--pg39-text); font-size: 2.8rem;
  cursor: pointer; position: absolute; top: 1rem; right: 1.2rem;
}
.pg39-menu-links { margin-top: 4rem; display: flex; flex-direction: column; gap: 0.4rem; }
.pg39-menu-link {
  display: block; padding: 1.2rem 1rem; color: var(--pg39-text); font-size: 1.5rem;
  border-radius: 0.8rem; transition: all 0.3s; font-weight: 500;
}
.pg39-menu-link:hover { background: rgba(64,224,208,0.1); color: var(--pg39-primary); }

/* Carousel */
.pg39-carousel { position: relative; overflow: hidden; border-radius: 1rem; margin: 1rem 0; }
.pg39-slide { display: none; width: 100%; cursor: pointer; border-radius: 1rem; overflow: hidden; }
.pg39-slide img { width: 100%; height: auto; display: block; aspect-ratio: 430/200; object-fit: cover; }
.pg39-slide:first-child { display: block; }
.pg39-carousel-dots { text-align: center; padding: 0.8rem 0; display: flex; justify-content: center; gap: 0.6rem; }
.pg39-dot {
  width: 1rem; height: 1rem; border-radius: 50%; background: rgba(255,255,255,0.3);
  cursor: pointer; transition: all 0.3s; border: none;
}
.pg39-dot-active { background: var(--pg39-primary); transform: scale(1.2); }

/* Section */
.pg39-section { padding: 2rem 0; }
.pg39-section-title {
  font-size: 2rem; font-weight: 800; color: var(--pg39-primary);
  margin-bottom: 1.2rem; padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--pg39-border);
}

/* Game Grid */
.pg39-game-panel { display: none; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.pg39-game-panel:first-of-type { display: grid; }
.pg39-game-item {
  background: var(--pg39-card-bg); border-radius: 1rem; overflow: hidden;
  border: 1px solid var(--pg39-border); cursor: pointer; transition: all 0.3s;
}
.pg39-game-item:hover { transform: translateY(-3px); box-shadow: var(--pg39-shadow); border-color: var(--pg39-primary); }
.pg39-game-img { width: 100%; aspect-ratio: 1/1.1; object-fit: cover; }
.pg39-game-name {
  padding: 0.6rem 0.5rem; font-size: 1.1rem; font-weight: 600;
  text-align: center; color: var(--pg39-text); white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}

/* Tab buttons */
.pg39-tabs { display: flex; gap: 0.5rem; overflow-x: auto; padding: 0.5rem 0 1rem; -webkit-overflow-scrolling: touch; }
.pg39-tabs::-webkit-scrollbar { display: none; }
.pg39-tab-btn {
  padding: 0.6rem 1.2rem; border-radius: 2rem; font-size: 1.2rem; font-weight: 600;
  background: var(--pg39-card-bg); color: var(--pg39-text); border: 1px solid var(--pg39-border);
  cursor: pointer; white-space: nowrap; transition: all 0.3s;
}
.pg39-tab-active { background: var(--pg39-primary); color: var(--pg39-dark); border-color: var(--pg39-primary); }

/* Content Cards */
.pg39-card {
  background: var(--pg39-card-bg); border: 1px solid var(--pg39-border);
  border-radius: 1rem; padding: 1.6rem; margin-bottom: 1.2rem;
}
.pg39-card h3 { font-size: 1.6rem; color: var(--pg39-primary); margin-bottom: 0.8rem; }
.pg39-card p { font-size: 1.4rem; line-height: 2.2rem; color: rgba(255,255,255,0.85); }

/* Promo Button */
.pg39-promo-btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 1rem 2.4rem; border-radius: 2.5rem; font-size: 1.5rem; font-weight: 800;
  background: linear-gradient(135deg, #40E0D0 0%, #2ec4b6 100%);
  color: var(--pg39-dark); cursor: pointer; border: none;
  box-shadow: 0 0 20px rgba(64,224,208,0.4); transition: all 0.3s;
  text-decoration: none;
}
.pg39-promo-btn:hover { transform: scale(1.05); box-shadow: 0 0 30px rgba(64,224,208,0.6); }

/* Footer */
.pg39-footer {
  background: linear-gradient(180deg, var(--pg39-dark) 0%, rgba(15,15,35,0.98) 100%);
  border-top: 1px solid var(--pg39-border); padding: 2rem 0 1rem; margin-top: 2rem;
}
.pg39-footer-brand { text-align: center; margin-bottom: 1.5rem; }
.pg39-footer-brand h3 { font-size: 1.8rem; color: var(--pg39-primary); margin-bottom: 0.5rem; }
.pg39-footer-brand p { font-size: 1.3rem; color: rgba(255,255,255,0.6); line-height: 2rem; }
.pg39-footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.8rem; margin: 1.2rem 0; }
.pg39-footer-link {
  padding: 0.5rem 1rem; border-radius: 2rem; font-size: 1.2rem; font-weight: 600;
  background: var(--pg39-card-bg); color: var(--pg39-primary);
  border: 1px solid var(--pg39-border); cursor: pointer; transition: all 0.3s;
}
.pg39-footer-link:hover { background: var(--pg39-primary); color: var(--pg39-dark); }
.pg39-footer-copy { text-align: center; font-size: 1.2rem; color: rgba(255,255,255,0.4); margin-top: 1.5rem; padding-top: 1rem; border-top: 1px solid rgba(255,255,255,0.05); }

/* Mobile Bottom Navigation */
.pg39-bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 1000;
  background: linear-gradient(180deg, rgba(15,15,35,0.98) 0%, var(--pg39-dark) 100%);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--pg39-border);
  display: flex; justify-content: space-around; align-items: center;
  height: 6rem; padding: 0 0.5rem;
}
.pg39-bottom-btn {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-width: 6rem; min-height: 5rem; background: none; border: none;
  color: rgba(255,255,255,0.5); cursor: pointer; transition: all 0.3s;
  padding: 0.4rem; border-radius: 0.8rem; position: relative;
}
.pg39-bottom-btn:hover, .pg39-bottom-btn.pg39-bottom-active { color: var(--pg39-primary); }
.pg39-bottom-btn.pg39-bottom-active::after {
  content: ''; position: absolute; top: -0.2rem; left: 50%; transform: translateX(-50%);
  width: 2rem; height: 0.3rem; background: var(--pg39-primary); border-radius: 2rem;
}
.pg39-bottom-btn span.material-icons,
.pg39-bottom-btn i { font-size: 2.4rem; margin-bottom: 0.2rem; }
.pg39-bottom-btn span.pg39-bottom-label { font-size: 1rem; font-weight: 600; }

/* Grid layout */
.pg39-grid { display: grid; gap: 1rem; }
.pg39-grid-2 { grid-template-columns: repeat(2, 1fr); }
.pg39-grid-3 { grid-template-columns: repeat(3, 1fr); }

/* Hero Banner */
.pg39-hero { padding-top: 6rem; }

/* Text utilities */
.pg39-text-primary { color: var(--pg39-primary); }
.pg39-text-center { text-align: center; }
.pg39-text-bold { font-weight: 700; }
.pg39-mt-1 { margin-top: 1rem; }
.pg39-mt-2 { margin-top: 2rem; }
.pg39-mb-1 { margin-bottom: 1rem; }
.pg39-mb-2 { margin-bottom: 2rem; }

/* Highlight box */
.pg39-highlight {
  background: linear-gradient(135deg, rgba(64,224,208,0.1) 0%, rgba(64,224,208,0.05) 100%);
  border-left: 3px solid var(--pg39-primary);
  padding: 1.2rem 1.4rem; border-radius: 0 0.8rem 0.8rem 0;
  margin: 1rem 0;
}
.pg39-highlight p { font-size: 1.4rem; line-height: 2.2rem; color: rgba(255,255,255,0.9); }

/* Responsive - Mobile only for bottom nav */
@media (min-width: 769px) {
  .pg39-bottom-nav { display: none; }
  .pg39-container { max-width: 430px; }
}
@media (max-width: 768px) {
  main { padding-bottom: 8rem; }
  .pg39-hamburger { display: block; }
  .pg39-desktop-nav { display: none; }
}
