/**
 * SSBET77 - Universal Stylesheet
 * All classes use 'v8d7-' prefix for namespace isolation
 * Mobile-first responsive design (max-width: 430px)
 * Color palette: #00FA9A | #CD853F | #FFDEAD | #FAF0E6 | #0E1621
 */

/* === CSS Variables === */
:root {
  /* Color palette - unique to SSBET77 */
  --v8d7-primary: #00FA9A;
  --v8d7-secondary: #CD853F;
  --v8d7-accent: #FFDEAD;
  --v8d7-light: #FAF0E6;
  --v8d7-dark: #0E1621;
  --v8d7-bg: #0E1621;
  --v8d7-text: #FAF0E6;
  --v8d7-text-dim: rgba(250, 240, 230, 0.7);

  /* Spacing */
  --v8d7-space-xs: 0.4rem;
  --v8d7-space-sm: 0.8rem;
  --v8d7-space-md: 1.6rem;
  --v8d7-space-lg: 2.4rem;
  --v8d7-space-xl: 3.2rem;

  /* Typography */
  --v8d7-font-base: 1.6rem;
  --v8d7-font-sm: 1.2rem;
  --v8d7-font-lg: 1.8rem;
  --v8d7-font-xl: 2.4rem;
  --v8d7-line-height: 1.5;

  /* Borders & Radius */
  --v8d7-radius-sm: 0.6rem;
  --v8d7-radius-md: 1rem;
  --v8d7-radius-lg: 1.6rem;
  --v8d7-border: 1px solid rgba(0, 250, 154, 0.2);

  /* Shadows */
  --v8d7-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --v8d7-shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --v8d7-shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --v8d7-shadow-glow: 0 0 20px rgba(0, 250, 154, 0.3);

  /* Transitions */
  --v8d7-transition: all 0.3s ease;
  --v8d7-transition-fast: all 0.15s ease;
}

/* === 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: var(--v8d7-font-base);
  line-height: var(--v8d7-line-height);
  color: var(--v8d7-text);
  background: var(--v8d7-bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* === Layout Containers === */
.v8d7-container {
  max-width: 430px;
  margin: 0 auto;
  padding: 0 var(--v8d7-space-md);
}

.v8d7-wrapper {
  padding: var(--v8d7-space-md) 0;
}

.v8d7-section {
  padding: var(--v8d7-space-lg) 0;
  position: relative;
}

/* === Header === */
.v8d7-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: linear-gradient(135deg, #0E1621 0%, #1a2332 100%);
  border-bottom: 2px solid var(--v8d7-primary);
  padding: var(--v8d7-space-sm) var(--v8d7-space-md);
  z-index: 1000;
  transition: var(--v8d7-transition);
}

.v8d7-header-scrolled {
  box-shadow: var(--v8d7-shadow-md);
  background: rgba(14, 22, 33, 0.98);
  backdrop-filter: blur(10px);
}

.v8d7-header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 430px;
  margin: 0 auto;
}

.v8d7-logo-section {
  display: flex;
  align-items: center;
  gap: var(--v8d7-space-sm);
}

.v8d7-logo {
  width: 3.2rem;
  height: 3.2rem;
  border-radius: var(--v8d7-radius-sm);
}

.v8d7-site-name {
  font-size: 2rem;
  font-weight: 700;
  color: var(--v8d7-primary);
  text-shadow: 0 2px 8px rgba(0, 250, 154, 0.4);
}

.v8d7-header-actions {
  display: flex;
  align-items: center;
  gap: var(--v8d7-space-sm);
}

.v8d7-btn-register,
.v8d7-btn-login {
  padding: 0.6rem 1.2rem;
  font-size: var(--v8d7-font-sm);
  font-weight: 600;
  border: none;
  border-radius: var(--v8d7-radius-sm);
  cursor: pointer;
  transition: var(--v8d7-transition-fast);
  text-decoration: none;
  display: inline-block;
}

.v8d7-btn-register {
  background: linear-gradient(135deg, var(--v8d7-primary) 0%, #00d688 100%);
  color: var(--v8d7-dark);
  box-shadow: 0 4px 12px rgba(0, 250, 154, 0.3);
}

.v8d7-btn-register:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 250, 154, 0.5);
}

.v8d7-btn-login {
  background: rgba(205, 133, 63, 0.2);
  color: var(--v8d7-secondary);
  border: 1px solid var(--v8d7-secondary);
}

.v8d7-btn-login:hover {
  background: var(--v8d7-secondary);
  color: var(--v8d7-dark);
}

.v8d7-hamburger {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
}

.v8d7-hamburger span {
  width: 2.4rem;
  height: 2px;
  background: var(--v8d7-primary);
  transition: var(--v8d7-transition-fast);
  border-radius: 2px;
}

.v8d7-hamburger-active span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.v8d7-hamburger-active span:nth-child(2) {
  opacity: 0;
}

.v8d7-hamburger-active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* === Mobile Menu === */
.v8d7-menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: var(--v8d7-transition);
}

.v8d7-overlay-active {
  opacity: 1;
  visibility: visible;
}

.v8d7-mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 320px;
  height: 100vh;
  background: linear-gradient(180deg, #0E1621 0%, #1a2332 100%);
  border-left: 2px solid var(--v8d7-primary);
  padding: var(--v8d7-space-xl) var(--v8d7-space-md);
  overflow-y: auto;
  z-index: 9999;
  transition: right 0.3s ease;
}

.v8d7-menu-active {
  right: 0;
}

.v8d7-mobile-menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--v8d7-space-lg);
  padding-bottom: var(--v8d7-space-md);
  border-bottom: var(--v8d7-border);
}

.v8d7-menu-title {
  font-size: var(--v8d7-font-lg);
  color: var(--v8d7-primary);
  font-weight: 700;
}

.v8d7-nav-link {
  display: block;
  padding: var(--v8d7-space-md);
  color: var(--v8d7-text);
  text-decoration: none;
  font-size: var(--v8d7-font-base);
  border-radius: var(--v8d7-radius-sm);
  transition: var(--v8d7-transition-fast);
  margin-bottom: var(--v8d7-space-xs);
}

.v8d7-nav-link:hover,
.v8d7-nav-active {
  background: rgba(0, 250, 154, 0.1);
  color: var(--v8d7-primary);
  transform: translateX(5px);
}

/* === Main Content === */
main {
  padding-top: 6.4rem;
  padding-bottom: 8rem;
  min-height: 100vh;
}

@media (min-width: 769px) {
  main {
    padding-bottom: var(--v8d7-space-xl);
  }
}

/* === Carousel === */
.v8d7-carousel {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: var(--v8d7-radius-md);
  margin: var(--v8d7-space-md) 0;
  box-shadow: var(--v8d7-shadow-md);
}

.v8d7-carousel-track {
  display: flex;
  transition: transform 0.5s ease;
}

.v8d7-carousel-slide {
  min-width: 100%;
  cursor: pointer;
}

.v8d7-carousel-slide img {
  width: 100%;
  height: auto;
  display: block;
}

.v8d7-carousel-dots {
  position: absolute;
  bottom: var(--v8d7-space-sm);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: var(--v8d7-space-xs);
}

.v8d7-carousel-dot {
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
  background: rgba(250, 240, 230, 0.4);
  cursor: pointer;
  transition: var(--v8d7-transition-fast);
}

.v8d7-dot-active {
  background: var(--v8d7-primary);
  width: 2.4rem;
  border-radius: 0.4rem;
}

/* === Typography === */
.v8d7-h1 {
  font-size: 2.8rem;
  font-weight: 700;
  color: var(--v8d7-primary);
  margin-bottom: var(--v8d7-space-md);
  line-height: 1.2;
  text-shadow: 0 2px 8px rgba(0, 250, 154, 0.3);
}

.v8d7-h2 {
  font-size: 2.2rem;
  font-weight: 600;
  color: var(--v8d7-secondary);
  margin-bottom: var(--v8d7-space-md);
}

.v8d7-h3 {
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--v8d7-accent);
  margin-bottom: var(--v8d7-space-sm);
}

.v8d7-p {
  margin-bottom: var(--v8d7-space-md);
  color: var(--v8d7-text-dim);
}

/* === Game Grid === */
.v8d7-game-category {
  margin-bottom: var(--v8d7-space-xl);
}

.v8d7-category-title {
  font-size: var(--v8d7-font-lg);
  font-weight: 700;
  color: var(--v8d7-primary);
  margin-bottom: var(--v8d7-space-md);
  padding: var(--v8d7-space-sm) var(--v8d7-space-md);
  background: rgba(0, 250, 154, 0.1);
  border-left: 4px solid var(--v8d7-primary);
  border-radius: var(--v8d7-radius-sm);
}

.v8d7-game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr));
  gap: var(--v8d7-space-sm);
}

.v8d7-game-card {
  background: rgba(205, 133, 63, 0.1);
  border: 1px solid rgba(205, 133, 63, 0.3);
  border-radius: var(--v8d7-radius-md);
  padding: var(--v8d7-space-sm);
  text-align: center;
  cursor: pointer;
  transition: var(--v8d7-transition);
  text-decoration: none;
}

.v8d7-game-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--v8d7-shadow-glow);
  border-color: var(--v8d7-primary);
}

.v8d7-game-icon {
  width: 100%;
  height: auto;
  border-radius: var(--v8d7-radius-sm);
  margin-bottom: var(--v8d7-space-xs);
}

.v8d7-game-name {
  font-size: 1.1rem;
  color: var(--v8d7-text);
  font-weight: 500;
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* === Cards & Content Blocks === */
.v8d7-card {
  background: rgba(26, 35, 50, 0.6);
  border: var(--v8d7-border);
  border-radius: var(--v8d7-radius-md);
  padding: var(--v8d7-space-md);
  margin-bottom: var(--v8d7-space-md);
  transition: var(--v8d7-transition);
}

.v8d7-card:hover {
  border-color: var(--v8d7-primary);
  box-shadow: var(--v8d7-shadow-md);
}

/* === Buttons === */
.v8d7-btn {
  display: inline-block;
  padding: var(--v8d7-space-sm) var(--v8d7-space-md);
  font-size: var(--v8d7-font-base);
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  border-radius: var(--v8d7-radius-sm);
  border: none;
  cursor: pointer;
  transition: var(--v8d7-transition);
}

.v8d7-btn-primary {
  background: linear-gradient(135deg, var(--v8d7-primary) 0%, #00d688 100%);
  color: var(--v8d7-dark);
  box-shadow: 0 4px 12px rgba(0, 250, 154, 0.3);
}

.v8d7-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--v8d7-shadow-glow);
}

.v8d7-btn-secondary {
  background: linear-gradient(135deg, var(--v8d7-secondary) 0%, #b86f40 100%);
  color: var(--v8d7-light);
}

.v8d7-btn-outline {
  background: transparent;
  border: 2px solid var(--v8d7-primary);
  color: var(--v8d7-primary);
}

.v8d7-btn-outline:hover {
  background: var(--v8d7-primary);
  color: var(--v8d7-dark);
}

/* === Accordion === */
.v8d7-accordion-group {
  margin: var(--v8d7-space-md) 0;
}

.v8d7-accordion-item {
  background: rgba(26, 35, 50, 0.4);
  border: var(--v8d7-border);
  border-radius: var(--v8d7-radius-sm);
  margin-bottom: var(--v8d7-space-sm);
  overflow: hidden;
}

.v8d7-accordion-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--v8d7-space-md);
  cursor: pointer;
  font-weight: 600;
  color: var(--v8d7-text);
  transition: var(--v8d7-transition-fast);
}

.v8d7-accordion-header:hover {
  background: rgba(0, 250, 154, 0.05);
}

.v8d7-accordion-icon {
  transition: var(--v8d7-transition-fast);
  color: var(--v8d7-primary);
}

.v8d7-accordion-active .v8d7-accordion-icon {
  transform: rotate(180deg);
}

.v8d7-accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.v8d7-accordion-active .v8d7-accordion-content {
  max-height: 100rem;
  padding: var(--v8d7-space-md);
  border-top: var(--v8d7-border);
}

/* === Footer === */
.v8d7-footer {
  background: linear-gradient(180deg, #0E1621 0%, #000 100%);
  border-top: 2px solid var(--v8d7-primary);
  padding: var(--v8d7-space-xl) 0 var(--v8d7-space-md);
  margin-top: var(--v8d7-space-xl);
}

.v8d7-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--v8d7-space-sm);
  justify-content: center;
  margin-bottom: var(--v8d7-space-md);
}

.v8d7-footer-link {
  color: var(--v8d7-text-dim);
  text-decoration: none;
  font-size: var(--v8d7-font-sm);
  transition: var(--v8d7-transition-fast);
}

.v8d7-footer-link:hover {
  color: var(--v8d7-primary);
}

.v8d7-partners {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--v8d7-space-md);
  margin: var(--v8d7-space-lg) 0;
  padding: var(--v8d7-space-md) 0;
  border-top: var(--v8d7-border);
  border-bottom: var(--v8d7-border);
}

.v8d7-partner-logo {
  width: 4.8rem;
  height: auto;
  opacity: 0.6;
  transition: var(--v8d7-transition-fast);
  filter: grayscale(100%);
}

.v8d7-partner-logo:hover {
  opacity: 1;
  filter: grayscale(0%);
}

.v8d7-copyright {
  text-align: center;
  font-size: var(--v8d7-font-sm);
  color: var(--v8d7-text-dim);
  margin-top: var(--v8d7-space-md);
}

/* === Bottom Navigation (Mobile Only) === */
.v8d7-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, #1a2332 0%, #0E1621 100%);
  border-top: 2px solid var(--v8d7-primary);
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 0.8rem 0;
  z-index: 1000;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.5);
}

.v8d7-bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: var(--v8d7-text-dim);
  font-size: 1rem;
  min-width: 6rem;
  min-height: 6rem;
  padding: 0.4rem;
  transition: var(--v8d7-transition-fast);
  cursor: pointer;
}

.v8d7-bottom-nav-item i {
  font-size: 2.4rem;
  margin-bottom: 0.2rem;
}

.v8d7-bottom-nav-item:hover,
.v8d7-bottom-active {
  color: var(--v8d7-primary);
  transform: scale(1.1);
}

@media (min-width: 769px) {
  .v8d7-bottom-nav {
    display: none;
  }
}

/* === Scroll to Top Button === */
.v8d7-scroll-top {
  position: fixed;
  bottom: 8rem;
  right: var(--v8d7-space-md);
  width: 4.8rem;
  height: 4.8rem;
  background: var(--v8d7-primary);
  color: var(--v8d7-dark);
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: var(--v8d7-transition);
  box-shadow: var(--v8d7-shadow-md);
  z-index: 999;
}

.v8d7-scroll-visible {
  opacity: 1;
  visibility: visible;
}

.v8d7-scroll-top:hover {
  transform: translateY(-4px);
  box-shadow: var(--v8d7-shadow-glow);
}

@media (min-width: 769px) {
  .v8d7-scroll-top {
    bottom: var(--v8d7-space-md);
  }
}

/* === Utility Classes === */
.v8d7-text-center {
  text-align: center;
}

.v8d7-text-primary {
  color: var(--v8d7-primary);
}

.v8d7-text-secondary {
  color: var(--v8d7-secondary);
}

.v8d7-mt-md {
  margin-top: var(--v8d7-space-md);
}

.v8d7-mb-md {
  margin-bottom: var(--v8d7-space-md);
}

.v8d7-flex-center {
  display: flex;
  justify-content: center;
  align-items: center;
}
