/* Jiliph App Theme Styles - Mobile First Design */
/* All classes use prefix: w778f- */
/* Color scheme: #333333 (background) | #FFB6C1 (pink) | #E9967A (salmon) */

/* ========================================
   ROOT & RESET
   ======================================== */
:root {
  --w778f-dark-bg: #333333;
  --w778f-pink: #FFB6C1;
  --w778f-salmon: #E9967A;
  --w778f-white: #FFFFFF;
  --w778f-light-gray: #F5F5F5;
  --w778f-medium-gray: #CCCCCC;
  --w778f-dark-gray: #555555;
  --w778f-text-light: #FFFFFF;
  --w778f-text-dark: #333333;
  --w778f-header-height: 60px;
  --w778f-bottom-nav-height: 60px;
  --w778f-transition: all 0.3s ease;
  font-size: 62.5%; /* 1rem = 10px */
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 1.4rem;
  line-height: 1.5;
  color: var(--w778f-text-light);
  background-color: var(--w778f-dark-bg);
  overflow-x: hidden;
}

/* ========================================
   LAYOUT CONTAINERS
   ======================================== */
.w778f-container {
  max-width: 430px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.w778f-wrapper {
  width: 100%;
  position: relative;
}

.w778f-grid {
  display: grid;
  gap: 1.5rem;
}

.w778f-flex {
  display: flex;
}

.w778f-flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ========================================
   HEADER & NAVIGATION
   ======================================== */
.w778f-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--w778f-header-height);
  background: linear-gradient(135deg, var(--w778f-dark-bg) 0%, var(--w778f-dark-gray) 100%);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  z-index: 1000;
  transition: var(--w778f-transition);
}

.w778f-header-scrolled {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.w778f-header-content {
  max-width: 430px;
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
}

.w778f-logo-wrapper {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 1;
}

.w778f-logo {
  width: 3.2rem;
  height: 3.2rem;
  object-fit: contain;
}

.w778f-site-name {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--w778f-pink);
  text-decoration: none;
  white-space: nowrap;
}

.w778f-header-actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.w778f-btn-header {
  padding: 0.6rem 1.2rem;
  font-size: 1.2rem;
  font-weight: 600;
  border: none;
  border-radius: 2rem;
  cursor: pointer;
  transition: var(--w778f-transition);
  white-space: nowrap;
  min-height: 44px;
}

.w778f-btn-register {
  background: linear-gradient(135deg, var(--w778f-pink) 0%, var(--w778f-salmon) 100%);
  color: var(--w778f-white);
}

.w778f-btn-register:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(255, 182, 193, 0.4);
}

.w778f-btn-login {
  background: transparent;
  color: var(--w778f-pink);
  border: 2px solid var(--w778f-pink);
}

.w778f-btn-login:hover {
  background: var(--w778f-pink);
  color: var(--w778f-white);
}

.w778f-menu-toggle {
  background: none;
  border: none;
  color: var(--w778f-pink);
  font-size: 2.4rem;
  cursor: pointer;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  min-height: 44px;
  min-width: 44px;
}

/* Mobile Menu */
.w778f-mobile-menu {
  position: fixed;
  top: var(--w778f-header-height);
  left: -100%;
  width: 80%;
  max-width: 300px;
  height: calc(100vh - var(--w778f-header-height));
  background: linear-gradient(180deg, var(--w778f-dark-gray) 0%, var(--w778f-dark-bg) 100%);
  transition: left 0.3s ease;
  z-index: 9999;
  overflow-y: auto;
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.5);
}

.w778f-menu-active {
  left: 0;
}

.w778f-menu-list {
  list-style: none;
  padding: 2rem 0;
}

.w778f-menu-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.w778f-menu-link {
  display: block;
  padding: 1.5rem 2rem;
  color: var(--w778f-text-light);
  text-decoration: none;
  font-size: 1.4rem;
  transition: var(--w778f-transition);
  min-height: 44px;
}

.w778f-menu-link:hover,
.w778f-menu-link:active {
  background: rgba(255, 182, 193, 0.1);
  color: var(--w778f-pink);
  padding-left: 2.5rem;
}

/* ========================================
   MAIN CONTENT
   ======================================== */
.w778f-main {
  margin-top: var(--w778f-header-height);
  min-height: calc(100vh - var(--w778f-header-height));
  padding-bottom: 8rem;
}

@media (max-width: 768px) {
  .w778f-main {
    padding-bottom: calc(var(--w778f-bottom-nav-height) + 2rem);
  }
}

/* ========================================
   CAROUSEL
   ======================================== */
.w778f-carousel {
  position: relative;
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 1rem;
}

.w778f-carousel-container {
  position: relative;
  width: 100%;
  height: 200px;
}

.w778f-carousel-slide {
  display: none;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.w778f-carousel-slide.w778f-active {
  display: block;
  animation: w778f-fadeIn 0.5s ease;
}

.w778f-carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.w778f-carousel-dots {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.8rem;
  z-index: 10;
}

.w778f-carousel-dot {
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  border: none;
  cursor: pointer;
  transition: var(--w778f-transition);
  padding: 0;
}

.w778f-carousel-dot.w778f-active {
  background: var(--w778f-pink);
  width: 2.5rem;
  border-radius: 0.5rem;
}

@keyframes w778f-fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ========================================
   SECTIONS
   ======================================== */
.w778f-section {
  padding: 2rem 0;
}

.w778f-section-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--w778f-pink);
  margin-bottom: 1.5rem;
  text-align: center;
}

.w778f-section-subtitle {
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--w778f-salmon);
  margin-bottom: 1rem;
}

.w778f-section-content {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 1rem;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

/* ========================================
   GAME GRID
   ======================================== */
.w778f-game-category {
  margin-bottom: 3rem;
}

.w778f-game-category-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--w778f-salmon);
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--w778f-pink);
  text-transform: uppercase;
}

.w778f-game-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.w778f-game-item {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 0.8rem;
  padding: 0.8rem;
  text-align: center;
  cursor: pointer;
  transition: var(--w778f-transition);
  border: 2px solid transparent;
}

.w778f-game-item:hover {
  transform: translateY(-5px);
  border-color: var(--w778f-pink);
  box-shadow: 0 4px 12px rgba(255, 182, 193, 0.3);
}

.w778f-game-icon {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 0.5rem;
  margin-bottom: 0.5rem;
}

.w778f-game-name {
  font-size: 1.1rem;
  color: var(--w778f-text-light);
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ========================================
   BUTTONS
   ======================================== */
.w778f-btn {
  display: inline-block;
  padding: 1.2rem 2.4rem;
  font-size: 1.4rem;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  border: none;
  border-radius: 2.5rem;
  cursor: pointer;
  transition: var(--w778f-transition);
  min-height: 44px;
  line-height: 1.5;
}

.w778f-btn-primary {
  background: linear-gradient(135deg, var(--w778f-pink) 0%, var(--w778f-salmon) 100%);
  color: var(--w778f-white);
  box-shadow: 0 4px 12px rgba(255, 182, 193, 0.3);
}

.w778f-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 182, 193, 0.5);
}

.w778f-btn-secondary {
  background: transparent;
  color: var(--w778f-pink);
  border: 2px solid var(--w778f-pink);
}

.w778f-btn-secondary:hover {
  background: var(--w778f-pink);
  color: var(--w778f-white);
}

.w778f-btn-full {
  width: 100%;
  display: block;
}

/* ========================================
   CARDS
   ======================================== */
.w778f-card {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 1rem;
  padding: 2rem;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(255, 182, 193, 0.2);
}

.w778f-card-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--w778f-pink);
  margin-bottom: 1rem;
}

.w778f-card-content {
  font-size: 1.4rem;
  line-height: 1.6;
  color: var(--w778f-text-light);
}

.w778f-card-content p {
  margin-bottom: 1rem;
}

.w778f-card-content ul,
.w778f-card-content ol {
  margin-left: 2rem;
  margin-bottom: 1rem;
}

.w778f-card-content li {
  margin-bottom: 0.5rem;
}

/* ========================================
   FOOTER
   ======================================== */
.w778f-footer {
  background: linear-gradient(180deg, var(--w778f-dark-bg) 0%, #222222 100%);
  padding: 3rem 0 1rem;
  margin-top: 4rem;
  border-top: 2px solid var(--w778f-pink);
}

.w778f-footer-content {
  max-width: 430px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.w778f-footer-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}

.w778f-footer-link {
  color: var(--w778f-text-light);
  text-decoration: none;
  font-size: 1.3rem;
  padding: 0.5rem;
  transition: var(--w778f-transition);
  min-height: 44px;
  display: flex;
  align-items: center;
}

.w778f-footer-link:hover {
  color: var(--w778f-pink);
  padding-left: 1rem;
}

.w778f-partners {
  margin: 2rem 0;
}

.w778f-partners-title {
  font-size: 1.4rem;
  color: var(--w778f-salmon);
  margin-bottom: 1rem;
  text-align: center;
}

.w778f-partners-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
  align-items: center;
}

.w778f-partner-logo {
  width: 100%;
  height: auto;
  opacity: 0.7;
  transition: var(--w778f-transition);
}

.w778f-partner-logo:hover {
  opacity: 1;
  transform: scale(1.1);
}

.w778f-copyright {
  text-align: center;
  padding: 1.5rem 0;
  font-size: 1.2rem;
  color: var(--w778f-medium-gray);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ========================================
   BOTTOM NAVIGATION (Mobile)
   ======================================== */
.w778f-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--w778f-bottom-nav-height);
  background: linear-gradient(180deg, var(--w778f-dark-gray) 0%, var(--w778f-dark-bg) 100%);
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3);
  z-index: 1000;
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 0.5rem 0;
}

.w778f-bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: var(--w778f-medium-gray);
  transition: var(--w778f-transition);
  min-width: 60px;
  min-height: 60px;
  flex: 1;
}

.w778f-bottom-nav-item:hover,
.w778f-bottom-nav-item.w778f-active {
  color: var(--w778f-pink);
}

.w778f-bottom-nav-icon {
  font-size: 2.4rem;
  margin-bottom: 0.3rem;
}

.w778f-bottom-nav-label {
  font-size: 1rem;
  text-align: center;
}

@media (min-width: 769px) {
  .w778f-bottom-nav {
    display: none;
  }
}

/* ========================================
   UTILITY CLASSES
   ======================================== */
.w778f-text-center {
  text-align: center;
}

.w778f-text-pink {
  color: var(--w778f-pink);
}

.w778f-text-salmon {
  color: var(--w778f-salmon);
}

.w778f-text-bold {
  font-weight: 700;
}

.w778f-mb-1 {
  margin-bottom: 1rem;
}

.w778f-mb-2 {
  margin-bottom: 2rem;
}

.w778f-mt-1 {
  margin-top: 1rem;
}

.w778f-mt-2 {
  margin-top: 2rem;
}

.w778f-hidden {
  display: none;
}

/* ========================================
   ANIMATIONS
   ======================================== */
.w778f-animate-on-scroll {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.w778f-animated {
  opacity: 1;
  transform: translateY(0);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */
@media (max-width: 768px) {
  :root {
    font-size: 58%;
  }

  .w778f-game-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.8rem;
  }

  .w778f-game-name {
    font-size: 1rem;
  }
}

@media (min-width: 431px) {
  .w778f-container,
  .w778f-header-content,
  .w778f-footer-content {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}
