/**
 * PHLWINNER Design System
 * Mobile-first gaming website styles
 */

/* CSS Variables */
:root {
  --g797-primary: #32CD32;
  --g797-secondary: #90EE90;
  --g797-dark: #333333;
  --g797-light: #CCCCCC;
  --g797-background: #E0F2F1;
  --g797-text: #212121;
  --g797-white: #FFFFFF;
  --g797-shadow: rgba(0, 0, 0, 0.1);
  --g797-radius: 8px;
  --g797-transition: all 0.3s ease;
}

/* Reset and Base Styles */
* {
  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, Arial, sans-serif;
  font-size: 1.6rem;
  line-height: 1.5;
  color: var(--g797-text);
  background-color: var(--g797-background);
  overflow-x: hidden;
}

/* Container */
.g797-container {
  max-width: 430px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.g797-wrapper {
  min-height: 100vh;
  padding-bottom: 8rem;
}

/* Header */
.g797-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: linear-gradient(135deg, var(--g797-primary), var(--g797-secondary));
  box-shadow: 0 2px 10px var(--g797-shadow);
  backdrop-filter: blur(10px);
}

.g797-header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  max-width: 430px;
  margin: 0 auto;
}

.g797-logo {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  text-decoration: none;
  color: var(--g797-white);
}

.g797-logo-icon {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  background: var(--g797-white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  color: var(--g797-primary);
}

.g797-logo-text {
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.g797-header-actions {
  display: flex;
  gap: 1rem;
}

.g797-btn {
  padding: 0.8rem 1.6rem;
  border: none;
  border-radius: var(--g797-radius);
  font-size: 1.4rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--g797-transition);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 4.4rem;
  touch-action: manipulation;
}

.g797-btn-primary {
  background: var(--g797-white);
  color: var(--g797-primary);
}

.g797-btn-primary:hover {
  background: var(--g797-light);
  transform: translateY(-1px);
}

.g797-btn-outline {
  background: transparent;
  color: var(--g797-white);
  border: 2px solid var(--g797-white);
}

.g797-btn-outline:hover {
  background: var(--g797-white);
  color: var(--g797-primary);
}

.g797-menu-toggle {
  background: none;
  border: none;
  color: var(--g797-white);
  font-size: 2.4rem;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: var(--g797-radius);
  transition: var(--g797-transition);
}

.g797-menu-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* Mobile Menu */
.g797-mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 320px;
  height: 100vh;
  background: var(--g797-white);
  z-index: 9999;
  transition: right 0.3s ease;
  box-shadow: -5px 0 15px var(--g797-shadow);
}

.g797-mobile-menu.active {
  right: 0;
}

.g797-menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: var(--g797-transition);
}

.g797-menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

.g797-menu-header {
  padding: 1.5rem;
  background: linear-gradient(135deg, var(--g797-primary), var(--g797-secondary));
  color: var(--g797-white);
}

.g797-menu-close {
  background: none;
  border: none;
  color: var(--g797-white);
  font-size: 2.4rem;
  cursor: pointer;
  float: right;
}

.g797-menu-nav {
  padding: 1.5rem;
}

.g797-menu-item {
  display: block;
  padding: 1.2rem 0;
  color: var(--g797-text);
  text-decoration: none;
  border-bottom: 1px solid var(--g797-light);
  transition: var(--g797-transition);
}

.g797-menu-item:hover {
  color: var(--g797-primary);
  padding-left: 1rem;
}

/* Main Content */
.g797-main {
  padding-top: 7rem;
  min-height: 100vh;
}

/* Carousel */
.g797-carousel {
  position: relative;
  margin-bottom: 2rem;
  border-radius: var(--g797-radius);
  overflow: hidden;
  box-shadow: 0 4px 15px var(--g797-shadow);
}

.g797-carousel-container {
  display: flex;
  transition: transform 0.5s ease;
}

.g797-carousel-slide {
  min-width: 100%;
  position: relative;
}

.g797-carousel-slide img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.g797-carousel-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2rem;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
  color: var(--g797-white);
}

.g797-carousel-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.g797-carousel-text {
  font-size: 1.4rem;
  opacity: 0.9;
}

.g797-carousel-indicators {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.5rem;
}

.g797-carousel-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: var(--g797-transition);
}

.g797-carousel-indicator.active {
  background: var(--g797-white);
  width: 24px;
  border-radius: 4px;
}

/* Game Grid */
.g797-game-section {
  margin-bottom: 3rem;
}

.g797-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.g797-section-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--g797-dark);
}

.g797-section-link {
  color: var(--g797-primary);
  text-decoration: none;
  font-size: 1.4rem;
  font-weight: 600;
}

.g797-game-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.g797-game-item {
  background: var(--g797-white);
  border-radius: var(--g797-radius);
  overflow: hidden;
  box-shadow: 0 2px 8px var(--g797-shadow);
  transition: var(--g797-transition);
  cursor: pointer;
}

.g797-game-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px var(--g797-shadow);
}

.g797-game-image {
  width: 100%;
  height: 80px;
  object-fit: cover;
  border-bottom: 2px solid var(--g797-primary);
}

.g797-game-name {
  padding: 0.8rem;
  font-size: 1.2rem;
  font-weight: 600;
  text-align: center;
  color: var(--g797-text);
  line-height: 1.3;
}

/* Content Sections */
.g797-content-section {
  background: var(--g797-white);
  border-radius: var(--g797-radius);
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 2px 8px var(--g797-shadow);
}

.g797-content-title {
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--g797-dark);
  margin-bottom: 1.5rem;
  text-align: center;
}

.g797-content-text {
  font-size: 1.6rem;
  line-height: 1.6;
  color: var(--g797-text);
  margin-bottom: 1.5rem;
}

.g797-content-link {
  color: var(--g797-primary);
  text-decoration: none;
  font-weight: 600;
  transition: var(--g797-transition);
}

.g797-content-link:hover {
  text-decoration: underline;
}

.g797-btn-large {
  padding: 1.2rem 2.4rem;
  font-size: 1.6rem;
  min-height: 4.8rem;
  width: 100%;
  max-width: 300px;
  margin: 1rem auto;
  display: block;
}

/* Footer */
.g797-footer {
  background: var(--g797-dark);
  color: var(--g797-white);
  padding: 3rem 0 8rem;
  margin-top: 3rem;
}

.g797-footer-content {
  text-align: center;
}

.g797-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.g797-footer-link {
  color: var(--g797-light);
  text-decoration: none;
  font-size: 1.4rem;
  transition: var(--g797-transition);
}

.g797-footer-link:hover {
  color: var(--g797-primary);
}

.g797-partners {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin: 2rem 0;
}

.g797-partner {
  width: 40px;
  height: 40px;
  object-fit: contain;
  opacity: 0.8;
  transition: var(--g797-transition);
}

.g797-partner:hover {
  opacity: 1;
}

.g797-copyright {
  font-size: 1.2rem;
  color: var(--g797-light);
  margin-top: 2rem;
}

/* Bottom Navigation */
.g797-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--g797-white);
  border-top: 1px solid var(--g797-light);
  box-shadow: 0 -2px 10px var(--g797-shadow);
  z-index: 1000;
  display: none;
}

.g797-bottom-nav-items {
  display: flex;
  justify-content: space-around;
  align-items: center;
  height: 6rem;
  max-width: 430px;
  margin: 0 auto;
}

.g797-bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 6rem;
  min-height: 6rem;
  text-decoration: none;
  color: var(--g797-text);
  transition: var(--g797-transition);
  cursor: pointer;
  border: none;
  background: none;
}

.g797-bottom-nav-item:hover,
.g797-bottom-nav-item.active {
  color: var(--g797-primary);
  transform: scale(1.05);
}

.g797-bottom-nav-icon {
  font-size: 2.4rem;
  margin-bottom: 0.2rem;
}

.g797-bottom-nav-text {
  font-size: 1rem;
  font-weight: 500;
  text-align: center;
}

/* Responsive Design */
@media (max-width: 768px) {
  .g797-bottom-nav {
    display: block;
  }

  .g797-main {
    padding-bottom: 8rem;
  }

  .g797-game-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 480px) {
  .g797-game-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .g797-container {
    padding: 0 1rem;
  }
}

/* Utility Classes */
.g797-text-center { text-align: center; }
.g797-text-left { text-align: left; }
.g797-text-right { text-align: right; }

.g797-mb-1 { margin-bottom: 1rem; }
.g797-mb-2 { margin-bottom: 2rem; }
.g797-mb-3 { margin-bottom: 3rem; }

.g797-mt-1 { margin-top: 1rem; }
.g797-mt-2 { margin-top: 2rem; }
.g797-mt-3 { margin-top: 3rem; }

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    animation: none !important;
  }
}

/* Focus styles */
.g797-btn:focus,
.g797-menu-toggle:focus,
.g797-bottom-nav-item:focus {
  outline: 2px solid var(--g797-primary);
  outline-offset: 2px;
}

/* Loading states */
.g797-loading {
  opacity: 0.6;
  pointer-events: none;
}

.g797-loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 2rem;
  height: 2rem;
  margin: -1rem 0 0 -1rem;
  border: 2px solid var(--g797-primary);
  border-top-color: transparent;
  border-radius: 50%;
  animation: g797-spin 1s linear infinite;
}

@keyframes g797-spin {
  to {
    transform: rotate(360deg);
  }
}