/**
 * WJSlot Gaming Platform - Core Theme CSS
 * Copyright 2025 - wjslot.click
 * Mobile-first responsive design with v79d prefix
 */

/* CSS Variables with prefix */
:root {
  --v79d-primary: #212F3D;
  --v79d-secondary: #6F4E37;
  --v79d-accent: #AFEEEE;
  --v79d-highlight: #D2B48C;
  --v79d-background: #FAF0E6;
  --v79d-text-light: #FAF0E6;
  --v79d-text-dark: #212F3D;
  --v79d-gradient: linear-gradient(135deg, var(--v79d-primary), var(--v79d-secondary));
  --v79d-shadow: 0 4px 15px rgba(33, 47, 61, 0.2);
  --v79d-border-radius: 8px;
  --v79d-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  font-size: 62.5%; /* 10px base for rem calculations */
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 1.6rem;
  line-height: 1.5;
  color: var(--v79d-text-dark);
  background-color: var(--v79d-background);
  overflow-x: hidden;
}

/* Container and layout classes */
.v79d-container {
  max-width: 430px;
  margin: 0 auto;
  padding: 0 1.6rem;
  width: 100%;
}

.v79d-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.v79d-grid {
  display: grid;
  gap: 1.6rem;
}

.v79d-flex {
  display: flex;
}

.v79d-flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.v79d-flex-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Header and navigation */
.v79d-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--v79d-gradient);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(175, 238, 238, 0.2);
  transition: var(--v79d-transition);
}

.v79d-header.v79d-hidden {
  transform: translateY(-100%);
}

.v79d-nav {
  height: 6rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.6rem;
  position: relative;
  z-index: 1001;
}

.v79d-logo {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  text-decoration: none;
  color: var(--v79d-text-light);
  font-weight: 700;
  font-size: 1.8rem;
}

.v79d-logo img {
  width: 3.2rem;
  height: 3.2rem;
  border-radius: var(--v79d-border-radius);
}

.v79d-nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.v79d-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 1.6rem;
  border: none;
  border-radius: var(--v79d-border-radius);
  font-size: 1.4rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: var(--v79d-transition);
  min-height: 44px;
  min-width: 44px;
}

.v79d-btn-primary {
  background: linear-gradient(135deg, var(--v79d-accent), var(--v79d-highlight));
  color: var(--v79d-text-dark);
  box-shadow: var(--v79d-shadow);
}

.v79d-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(175, 238, 238, 0.4);
}

.v79d-btn-secondary {
  background: transparent;
  color: var(--v79d-text-light);
  border: 2px solid var(--v79d-accent);
}

.v79d-btn-secondary:hover {
  background: var(--v79d-accent);
  color: var(--v79d-text-dark);
}

/* Mobile menu toggle */
.v79d-menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.v79d-menu-toggle span {
  display: block;
  height: 3px;
  width: 2.4rem;
  background: var(--v79d-text-light);
  margin: 3px 0;
  transition: var(--v79d-transition);
  transform-origin: center;
}

.v79d-menu-toggle.v79d-active span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.v79d-menu-toggle.v79d-active span:nth-child(2) {
  opacity: 0;
}

.v79d-menu-toggle.v79d-active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* Mobile menu */
.v79d-mobile-menu {
  position: fixed;
  top: 6rem;
  left: 0;
  right: 0;
  background: var(--v79d-gradient);
  transform: translateY(-100%);
  transition: var(--v79d-transition);
  z-index: 999;
  box-shadow: var(--v79d-shadow);
  pointer-events: none;
}

.v79d-mobile-menu.v79d-menu-active {
  transform: translateY(0);
  pointer-events: auto;
}

.v79d-mobile-menu ul {
  list-style: none;
  padding: 2rem;
}

.v79d-mobile-menu li {
  margin-bottom: 1rem;
}

.v79d-mobile-menu a {
  display: block;
  padding: 1.2rem 1.6rem;
  color: var(--v79d-text-light);
  text-decoration: none;
  font-weight: 500;
  border-radius: var(--v79d-border-radius);
  transition: var(--v79d-transition);
}

.v79d-mobile-menu a:hover {
  background: rgba(175, 238, 238, 0.2);
  transform: translateX(0.5rem);
}

/* Main content */
.v79d-main {
  flex: 1;
  margin-top: 6rem;
  padding-bottom: 8rem;
}

.v79d-section {
  padding: 2rem 0;
}

.v79d-section-title {
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--v79d-primary);
  margin-bottom: 1.6rem;
  text-align: center;
}

.v79d-section-subtitle {
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--v79d-secondary);
  margin-bottom: 1.2rem;
}

/* Hero/Banner section */
.v79d-hero {
  background: var(--v79d-gradient);
  color: var(--v79d-text-light);
  padding: 4rem 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.v79d-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 20"><defs><radialGradient id="a" cx="50%" cy="50%"><stop offset="0%" stop-color="rgba(175,238,238,0.1)"/><stop offset="100%" stop-color="transparent"/></radialGradient></defs><circle fill="url(%23a)" cx="10" cy="10" r="10"/><circle fill="url(%23a)" cx="90" cy="10" r="10"/></svg>') repeat;
  opacity: 0.3;
  animation: v79d-float 20s infinite linear;
}

@keyframes v79d-float {
  from { transform: translateX(-100px); }
  to { transform: translateX(100px); }
}

.v79d-hero-title {
  font-size: 3.2rem;
  font-weight: 800;
  margin-bottom: 1.6rem;
  line-height: 1.2;
}

.v79d-hero-subtitle {
  font-size: 1.8rem;
  margin-bottom: 2.4rem;
  opacity: 0.9;
}

/* Carousel */
.v79d-carousel {
  position: relative;
  margin-bottom: 3rem;
  border-radius: var(--v79d-border-radius);
  overflow: hidden;
  box-shadow: var(--v79d-shadow);
}

.v79d-slide {
  display: none;
  position: relative;
  cursor: pointer;
}

.v79d-slide.v79d-active {
  display: block;
}

.v79d-slide img {
  width: 100%;
  height: 20rem;
  object-fit: cover;
}

.v79d-slide-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  color: white;
  padding: 2rem;
}

/* Game grid */
.v79d-game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr));
  gap: 1.2rem;
  margin-bottom: 3rem;
}

.v79d-game-card {
  background: white;
  border-radius: var(--v79d-border-radius);
  padding: 1rem;
  text-align: center;
  box-shadow: var(--v79d-shadow);
  transition: var(--v79d-transition);
  cursor: pointer;
}

.v79d-game-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(33, 47, 61, 0.3);
}

.v79d-game-card img {
  width: 4.8rem;
  height: 4.8rem;
  border-radius: 0.4rem;
  margin-bottom: 0.8rem;
  object-fit: cover;
}

.v79d-game-name {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--v79d-text-dark);
  line-height: 1.2;
}

/* Cards and components */
.v79d-card {
  background: white;
  border-radius: var(--v79d-border-radius);
  padding: 2rem;
  box-shadow: var(--v79d-shadow);
  margin-bottom: 2rem;
}

.v79d-card-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--v79d-primary);
  margin-bottom: 1rem;
}

.v79d-card-text {
  color: var(--v79d-text-dark);
  line-height: 1.6;
  margin-bottom: 1rem;
}

/* Features grid */
.v79d-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(26rem, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.v79d-feature {
  text-align: center;
  padding: 2rem;
  background: white;
  border-radius: var(--v79d-border-radius);
  box-shadow: var(--v79d-shadow);
  transition: var(--v79d-transition);
}

.v79d-feature:hover {
  transform: translateY(-2px);
}

.v79d-feature-icon {
  font-size: 3.2rem;
  color: var(--v79d-accent);
  margin-bottom: 1.6rem;
}

.v79d-feature-title {
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--v79d-primary);
  margin-bottom: 1rem;
}

/* Bottom navigation */
.v79d-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid rgba(33, 47, 61, 0.1);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  height: 6rem;
  z-index: 999;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

.v79d-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: var(--v79d-secondary);
  font-size: 1.2rem;
  font-weight: 500;
  transition: var(--v79d-transition);
  min-height: 44px;
}

.v79d-nav-item:hover,
.v79d-nav-item.v79d-active {
  color: var(--v79d-primary);
  background: rgba(175, 238, 238, 0.1);
}

.v79d-nav-item i {
  font-size: 2rem;
  margin-bottom: 0.4rem;
}

/* Footer */
.v79d-footer {
  background: var(--v79d-gradient);
  color: var(--v79d-text-light);
  padding: 3rem 0 2rem;
  margin-top: auto;
}

.v79d-footer-content {
  text-align: center;
}

.v79d-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem 2rem;
  margin-bottom: 2rem;
}

.v79d-footer-links a {
  color: var(--v79d-text-light);
  text-decoration: none;
  font-size: 1.4rem;
  opacity: 0.8;
  transition: var(--v79d-transition);
}

.v79d-footer-links a:hover {
  opacity: 1;
  text-decoration: underline;
}

.v79d-partners {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin: 2rem 0;
}

.v79d-partner-logo {
  width: 4rem;
  height: 4rem;
  object-fit: contain;
  opacity: 0.7;
  transition: var(--v79d-transition);
}

.v79d-partner-logo:hover {
  opacity: 1;
}

.v79d-copyright {
  font-size: 1.2rem;
  opacity: 0.7;
  margin-top: 2rem;
}

/* Utility classes */
.v79d-text-center { text-align: center; }
.v79d-text-left { text-align: left; }
.v79d-text-right { text-align: right; }

.v79d-mt-1 { margin-top: 1rem; }
.v79d-mt-2 { margin-top: 2rem; }
.v79d-mb-1 { margin-bottom: 1rem; }
.v79d-mb-2 { margin-bottom: 2rem; }

.v79d-p-1 { padding: 1rem; }
.v79d-p-2 { padding: 2rem; }

.v79d-hidden { display: none !important; }
.v79d-visible { display: block !important; }

/* Loading states */
.v79d-loading {
  position: relative;
  overflow: hidden;
}

.v79d-loading::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(175, 238, 238, 0.2), transparent);
  animation: v79d-loading 1.5s infinite;
}

@keyframes v79d-loading {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* Scroll progress indicator */
.v79d-scroll-progress {
  position: fixed;
  top: 6rem;
  left: 0;
  height: 3px;
  background: var(--v79d-accent);
  z-index: 1001;
  transition: width 0.3s ease;
}

/* Notifications */
.v79d-notification {
  position: fixed;
  top: 7rem;
  right: 1rem;
  max-width: 30rem;
  padding: 1.6rem;
  border-radius: var(--v79d-border-radius);
  color: white;
  font-weight: 600;
  transform: translateX(100%);
  transition: var(--v79d-transition);
  z-index: 1002;
}

.v79d-notification.v79d-show {
  transform: translateX(0);
}

.v79d-notification.v79d-info {
  background: var(--v79d-accent);
  color: var(--v79d-text-dark);
}

.v79d-notification.v79d-success {
  background: #4CAF50;
}

.v79d-notification.v79d-error {
  background: #F44336;
}

/* Responsive breakpoints */
@media (min-width: 480px) {
  .v79d-container {
    max-width: 48rem;
  }
  
  .v79d-game-grid {
    grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr));
  }
  
  .v79d-hero-title {
    font-size: 3.6rem;
  }
}

@media (min-width: 768px) {
  .v79d-container {
    max-width: 76.8rem;
  }
  
  .v79d-bottom-nav {
    display: none;
  }
  
  .v79d-main {
    padding-bottom: 2rem;
  }
  
  /* Keep mobile menu functional on all screen sizes for now */
  .v79d-menu-toggle {
    display: flex;
  }
  
  .v79d-mobile-menu {
    position: fixed;
    top: 6rem;
    left: 0;
    right: 0;
    background: var(--v79d-gradient);
    transform: translateY(-100%);
    transition: var(--v79d-transition);
    z-index: 999;
    box-shadow: var(--v79d-shadow);
  }
}

/* Print styles */
@media print {
  .v79d-header,
  .v79d-bottom-nav,
  .v79d-footer {
    display: none;
  }
  
  .v79d-main {
    margin-top: 0;
    padding-bottom: 0;
  }
}