:root{
    /* Merch lightbox card size */
    --merch-lightbox-card-size: 400px;
  --bg-dark:#000;
  --accent:#e84a53;
  --muted:#999;
  --card-shadow: rgba(0,0,0,0.6);
  
  /* Tweakable sizing variables */
  --get-app-btn-left: 0px; /* Controls left margin for Get App button in header */
  --main-logo-size: 100px;
  --header-icon-size: 100px;
  --menu-icon-size: 45px;
  --header-icon-gap: -10px;
  --header-padding: 0px 0px;
  --section-padding: 10px 0;
  --section-title-size: 22px;
  --subtitle-size: 12px;
  --card-width: 140px;
  --card-height: 170px;
  --merch-card-width: 200px;
  --merch-card-height: 200px;
  --footer-padding: 0px 0;
  --carousel-gap: 12px;
  
  /* Lightbox positioning */
  --lightbox-vertical-offset: 0px;
  --lightbox-close-top: 35px;
  --lightbox-close-right: 15px;
  
  /* Popout modal close button positioning */
  --fs-modal-close-right: 5px;
  --get-app-popup-close-top: 5px; /* Controls top offset for Get App popup close button */
  
  /* Playlist video card size */
  --playlist-card-max-width: 150px;
  --playlist-card-bg-max-width: 320px; /* Controls the max width of the playlist card background */
  --playlist-card-bg-max-height:100px; /* Controls the max height of the playlist card background */
}

/* Global Scrollbar Styles */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(50, 50, 50, 0.8) rgba(20, 20, 20, 0.3);
}

*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

*::-webkit-scrollbar-track {
  background: rgba(20, 20, 20, 0.3);
}

*::-webkit-scrollbar-thumb {
  background: rgba(50, 50, 50, 0.8);
  border-radius: 4px;
}

*::-webkit-scrollbar-thumb:hover {
  background: rgba(70, 70, 70, 0.9);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-color: #000;
  position: fixed;
}

body {
  color: #fff;
  font-family: 'Nunito', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  display: flex;
  justify-content: center;
  align-items: stretch;
}

/* Main container with fixed aspect ratio */
.page-container {
  width: 100%;
  height: 100%;
  min-height: 100vh;
  min-height: -webkit-fill-available;
  position: relative;
  background-image: url('img/1080x1920_background.png');
  background-size: 100% 100%;
  background-position: top center;
  background-repeat: no-repeat;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overflow-x: hidden;
  padding-top: 80px;
  padding-bottom: 200px;
  -webkit-overflow-scrolling: touch;
}

/* Desktop: keep mobile aspect ratio centered */
@media (min-width: 600px) {
  .page-container {
    max-width: 540px;
    margin: 0 auto;
  }
}

@media (min-width: 1080px) {
  .page-container {
    max-width: 1080px;
  }
}

/* Header styles */
.site-header{ 
  display: flex;
  justify-content: center;
  padding: var(--header-padding);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  flex-shrink: 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  min-height: 80px;
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 500;
}

.site-header::before {
  content: '';
  display: block;
  width: 100%;
  max-width: 600px;
  position: relative;
}

.header-left {
  position: fixed;
  left: 50%;
  margin-left: calc(-300px + 20px);
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  max-width: 600px;
}

@media (max-width: 600px) {
  .header-left {
    left: 20px;
    margin-left: 0;
    transform: translateY(-50%);
  }
}

.header-icon {
  display: block;
  width: var(--header-icon-size);
  height: auto;
  transition: transform 0.2s ease;
  line-height: 0;
}

.header-icon:hover {
  transform: scale(1.1);
}

.header-icon img {
  width: 100%;
  height: auto;
  display: block;
}

.logo-container {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

.main-logo {
  height: var(--main-logo-size);
  width: auto;
  display: block;
}

.header-right {
  position: fixed;
  right: 50%;
  margin-right: calc(-300px + 20px);
  top: 15px;
  display: flex;
  align-items: center;
  gap: 10px;
}

@media (max-width: 600px) {
  .header-right {
    right: 20px;
    margin-right: 0;
  }
}

.get-app-btn {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  padding: 6px 10px;
  color: white;
  font-family: 'Nunito', sans-serif;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1.2;
  gap: 2px;
  margin-left: var(--get-app-btn-left);
}

.get-app-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: scale(1.05);
}

.menu-icon{ 
  width: var(--menu-icon-size);
  cursor: pointer;
  transition: transform 0.2s ease;
}

.menu-icon:hover {
  transform: scale(1.1);
}

/* Main content area - flex to distribute space */
.site-wrap{ 
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 2px 0 100px 0;
  min-height: 0;
}

/* Section styles */
section{ 
  text-align: left;
  padding: var(--section-padding);
  flex-shrink: 0;
  overflow: visible;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 20px 12px 20px;
}

.section-header .section-title {
  margin: 0;
}

.section-title{ 
  font-family: 'Nunito', sans-serif;
  font-size: var(--section-title-size);
  margin: 0;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 700;
}

.search-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  padding: 8px 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 18px;
  color: white;
}

.search-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.05);
}

.search-icon {
  display: block;
  color: white;
  font-size: 20px;
}

.search-container {
  margin: 0 20px 12px 20px;
  display: flex;
  gap: 8px;
  align-items: center;
}

.search-container.active {
  position: sticky;
  top: 0;
  background: rgba(0, 0, 0, 0.95);
  padding: 12px 20px;
  margin: 0 0 12px 0;
  z-index: 100;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.search-input {
  flex: 1;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  padding: 10px 15px;
  color: white;
  font-family: 'Nunito', sans-serif;
  font-size: 14px;
  outline: none;
}

.search-input::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.search-input:focus {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.4);
}

.search-clear {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  padding: 8px 12px;
  cursor: pointer;
  color: white;
  font-size: 16px;
  transition: all 0.2s ease;
}

.search-clear:hover {
  background: rgba(255, 255, 255, 0.2);
}

.section-title{ 
  font-family: 'Nunito', sans-serif;
  font-size: var(--section-title-size);
  margin: 0 0 12px 20px;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 700;
}

.subtitle-inline {
  font-family: 'Nunito', sans-serif;
  font-size: var(--subtitle-size);
  font-weight: 700;
  color: #fff;
  margin-left: 8px;
  text-transform: lowercase;
}

.subtitle{ 
  color: var(--muted);
  margin: 0;
  padding: 0;
  font-size: var(--subtitle-size);
}

.carousel{ 
  display:flex; 
  overflow-x:auto; 
  overflow-y: hidden;
  gap: var(--carousel-gap); 
  padding:0px 12px; 
  scrollbar-width:none; 
  -ms-overflow-style:none;
  -webkit-overflow-scrolling: touch; /* Enable smooth scrolling on iOS */
  scroll-behavior: smooth;
  cursor: grab;
}

.carousel:active { cursor: grabbing; }
.carousel::-webkit-scrollbar{ display:none }

.card{ 
  min-width: var(--card-width);
  max-width: var(--card-width);
  background: transparent;
  border-radius: 8px;
  padding: 0;
  position: relative;
  display: block;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  flex-shrink: 0;
  overflow: hidden;
}

.card .media{ 
  display: block;
  width: 100%;
  height: var(--card-height);
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 4px 12px var(--card-shadow);
  border: none;
}

.short-card, .game-card{ 
  background: transparent;
  padding: 0;
  border-radius: 8px;
  position: relative;
}

.merch-card{ 
  min-width: var(--merch-card-width);
  max-width: var(--merch-card-width);
}

.merch-card .media {
  height: var(--merch-card-height);
}

.card .caption{ 
  margin-top: 8px;
  font-weight: 600;
  color: #fff;
  font-size: 13px;
  line-height: 1.3;
  padding: 0 4px;
  display: none;
}

.card .caption .muted{ 
  display: block;
  font-weight: 400;
  color: var(--muted);
  font-size: 11px;
  margin-top: 2px;
}

/* Play badge overlay */
.play-badge{ 
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0,0,0,0.75);
  color: #fff;
  padding: 8px 14px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 800;
  pointer-events: none;
  font-size: 11px;
  letter-spacing: 1px;
}

.play-badge .dot{ 
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  display: inline-block;
}

/* merch card style: simplified */
.merch-frame{ 
  background: #fff;
  padding: 10px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.merch-frame img{ 
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.site-footer{ 
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 10px 0;
  z-index: 10002;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3);
}

.footer-nav {
  display: flex;
  justify-content: space-around;
  align-items: center;
  max-width: 600px;
  margin: 0 auto;
  padding: 0 10px;
}

.footer-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  padding: 8px 12px;
  transition: all 0.2s ease;
  flex: 1;
  max-width: 100px;
}

.footer-btn:hover,
.footer-btn.active {
  color: white;
  transform: translateY(-2px);
}

.footer-btn-icon {
  font-size: 24px;
  line-height: 1;
}

.footer-btn-label {
  font-size: 10px;
  font-weight: 600;
  font-family: 'Nunito', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.site-footer .socials{ 
  display: none;
}

.social-link {
  display: none;
}

.footer-icon{ 
  display: none;
}

.copyright{ 
  display: none;
}

/* Splash screen for logo animation */
.splash-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeOut 0.5s ease-in-out 1.5s forwards;
}

.splash-screen .main-logo {
  animation: logoPopIn 1s ease-out;
}

@keyframes logoPopIn {
  0% { transform: scale(0); opacity: 0; }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes fadeOut {
  to { opacity: 0; visibility: hidden; }
}

/* Card shine animation on first click */
.card.shine::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.6), transparent);
  animation: shine 0.6s ease-in-out;
  pointer-events: none;
  z-index: 10;
}

@keyframes shine {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* Play badge blink animation */
.play-badge.blink {
  animation: blinkPlay 0.5s ease-in-out infinite;
}

@keyframes blinkPlay {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

/* Card activated state */
.card.activated {
  transform: scale(0.98);
  transition: transform 0.1s ease;
}

/* Coming Soon Alert */
.coming-soon-alert {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  background: rgba(0, 0, 0, 0.9);
  color: #ffffff;
  padding: 20px 40px;
  border-radius: 12px;
  font-size: 24px;
  font-weight: bold;
  text-align: center;
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  pointer-events: none;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.coming-soon-alert.show {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

/* Lightbox Modal */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  z-index: 10000;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  background: #000000;
  border-radius: 0;
  max-width: 540px;
  width: 100%;
  height: 100vh;
  max-height: 100vh;
  position: relative;
  text-align: center;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateY(var(--lightbox-vertical-offset));
  margin: 0 auto;
}

@media (min-width: 1080px) {
  .lightbox-content {
    max-width: 1080px;
  }
}

.lightbox-close {
  position: absolute;
  top: var(--lightbox-close-top);
  right: var(--lightbox-close-right);
  background: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
  font-weight: bold;
  transition: transform 0.2s ease;
  z-index: 10002;
  pointer-events: auto;
}

.lightbox-close:hover {
  transform: scale(1.1);
}

.lightbox-header-section {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 80px 20px 20px;
  background: #000000;
  width: 100%;
}

.lightbox-trailer {
  width: 100%;
  max-width: 400px;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 16px;
  flex-shrink: 0;
  align-self: center;
}

.lightbox-trailer iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.lightbox-image {
  width: 100%;
  max-width: 250px;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
  flex-shrink: 0;
  margin-bottom: 16px;
  align-self: center;
}

.lightbox.lightbox-merch .lightbox-image {
  max-width: var(--merch-lightbox-card-size);
  width: var(--merch-lightbox-card-size);
}

.lightbox-youtube {
  display: none;
  width: 100%;
  background: #000;
  overflow-y: auto;
  overflow-x: hidden;
  flex: 1;
  -webkit-overflow-scrolling: touch;
  border-radius: 0 0 16px 16px;
  padding-bottom: 80px;
}

.lightbox-youtube iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.lightbox-title {
  font-family: 'Nunito', sans-serif;
  font-size: 20px;
  font-weight: 700;
  margin: 12px 0 6px 0;
  color: white;
  flex-shrink: 0;
  text-align: left;
}

.lightbox-description {
  font-family: 'Nunito', sans-serif;
  font-size: 13px;
  font-weight: 400;
  margin: 0 0 16px 0;
  color: #ccc;
  flex-shrink: 0;
  text-align: left;
}

/* Center text for games and merch lightboxes */
.lightbox.lightbox-game .lightbox-header-section,
.lightbox.lightbox-merch .lightbox-header-section {
  align-items: center !important;
}

.lightbox.lightbox-game .lightbox-title,
.lightbox.lightbox-merch .lightbox-title {
  text-align: center !important;
  width: 100%;
}

.lightbox.lightbox-game .lightbox-description,
.lightbox.lightbox-merch .lightbox-description {
  text-align: center !important;
  width: 100%;
}

.lightbox.lightbox-game .lightbox-play-btn,
.lightbox.lightbox-merch .lightbox-play-btn {
  align-self: center;
}

.lightbox-play-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: white;
  color: #000;
  padding: 15px 40px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease;
  border: 3px solid #000;
  align-self: center;
}

.lightbox-play-btn:hover {
  transform: scale(1.05);
  background: #f0f0f0;
}

.lightbox-play-btn .play-icon {
  font-size: 16px;
}

/* Side Menu */
.side-menu {
  position: fixed;
  top: 0;
  right: -300px;
  width: 300px;
  height: 100%;
  background: #000;
  z-index: 10001;
  transition: right 0.3s ease;
  box-shadow: -4px 0 20px rgba(0, 0, 0, 0.5);
}

.side-menu.active {
  right: 0;
}

.side-menu-content {
  padding: 30px;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.side-menu-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
  font-weight: bold;
  transition: transform 0.2s ease;
}

.side-menu-close:hover {
  transform: scale(1.1);
}

.side-menu-title {
  font-family: 'Nunito', sans-serif;
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 30px 0;
  color: white;
}

.side-menu-nav {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.side-menu-link {
  display: block;
  padding: 15px 20px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  color: white;
  text-decoration: none;
  font-family: 'Nunito', sans-serif;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.2s ease;
  text-align: center;
}

.side-menu-link:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateX(-5px);
}

/* Get the App Modal */
.get-app-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 10002;
  align-items: center;
  justify-content: center;
  padding: 20px;
  overflow-y: auto;
}

.get-app-modal.active {
  display: flex;
}

.get-app-modal-content {
  background: #000000;
  border-radius: 16px;
  max-width: 600px;
  width: 100%;
  padding: 40px 30px;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
}

.get-app-modal-close {
  position: absolute;
  top: var(--get-app-popup-close-top);
  right: 15px;
  background: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
  font-weight: bold;
  transition: transform 0.2s ease;
}

.get-app-modal-close:hover {
  transform: scale(1.1);
}

.get-app-modal-title {
  font-family: 'Nunito', sans-serif;
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 15px 0;
  color: white;
  text-align: center;
}

.get-app-modal-subtitle {
  font-family: 'Nunito', sans-serif;
  font-size: 16px;
  font-weight: 400;
  margin: 0 0 30px 0;
  color: #ccc;
  text-align: center;
  line-height: 1.5;
}

.platform-instructions {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.platform-dropdown {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.platform-header {
  width: 100%;
  padding: 18px 20px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: white;
  font-family: 'Nunito', sans-serif;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background 0.2s ease;
}

.platform-header:hover {
  background: rgba(255, 255, 255, 0.15);
}

.platform-name {
  display: flex;
  align-items: center;
  gap: 10px;
}

.dropdown-arrow {
  transition: transform 0.3s ease;
  font-size: 14px;
}

.platform-dropdown.active .dropdown-arrow {
  transform: rotate(180deg);
}

.platform-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 20px;
}

.platform-dropdown.active .platform-content {
  max-height: 300px;
  padding: 20px;
}

.platform-content ol {
  margin: 0;
  padding-left: 20px;
  color: #ddd;
  font-family: 'Nunito', sans-serif;
  font-size: 15px;
  line-height: 1.8;
}

.platform-content li {
  margin-bottom: 8px;
}

/* Scroll spacer to ensure content can scroll past footer */
.scroll-spacer {
  height: 180px;
  flex-shrink: 0;
}

/* Search Results Grid (Netflix-style) */
.search-results-container {
  display: none;
  padding: 20px;
  width: 100%;
  flex-direction: column;
}

.search-results-container.active {
  display: flex;
}

.search-back-button {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  padding: 12px 20px;
  color: white;
  font-family: 'Nunito', sans-serif;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 20px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
}

.search-back-button:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateX(-3px);
}

.search-input-section {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 20px;
  position: sticky;
  top: 0;
  background: rgba(0, 0, 0, 0.95);
  padding: 12px 0;
  z-index: 100;
  backdrop-filter: blur(10px);
}

.search-results-header {
  margin-bottom: 20px;
}

.search-results-count {
  font-family: 'Nunito', sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: white;
  margin: 0;
}

.search-results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(115px, 1fr));
  gap: 20px;
  padding-bottom: 100px;
}

.search-no-results {
  text-align: center;
  padding: 60px 20px;
  color: var(--muted);
  font-size: 16px;
}

/* Hide sections when search is active */
.site-wrap.search-active > section {
  display: none;
}

.site-wrap.search-active > .scroll-spacer {
  display: none;
}

/* Trending Page Styles */
.trending-page-container {
  display: none;
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 540px;
  height: calc(100vh - 80px);
  background: var(--background-color);
  z-index: 400;
  flex-direction: column;
}

@media (min-width: 1080px) {
  .trending-page-container {
    max-width: 1080px;
  }
}

.trending-page-container.active {
  display: flex;
}

.trending-section {
  margin-bottom: 30px;
}

.trending-section .section-title {
  margin: 0 0 15px 0;
  font-size: 20px;
}

/* Hide sections when trending page is active */
.site-wrap.trending-active > section {
  display: none;
}

.site-wrap.trending-active > .scroll-spacer {
  display: none;
}

/* Games Page Styles */
.games-page-container {
  display: none;
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 540px;
  height: calc(100vh - 80px);
  background: var(--background-color);
  z-index: 400;
  flex-direction: column;
}

@media (min-width: 1080px) {
  .games-page-container {
    max-width: 1080px;
  }
}

.games-page-container.active {
  display: flex;
}

.games-page-section {
  margin-bottom: 30px;
}

.games-page-section .section-title {
  margin: 0 0 15px 0;
  font-size: 20px;
}

/* Hide sections when games page is active */
.site-wrap.games-active > section {
  display: none;
}

.site-wrap.games-active > .scroll-spacer {
  display: none;
}

/* Merch Page Styles */
.merch-page-container {
  display: none;
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 540px;
  height: calc(100vh - 80px);
  background: var(--background-color);
  z-index: 400;
  flex-direction: column;
}

@media (min-width: 1080px) {
  .merch-page-container {
    max-width: 1080px;
  }
}

.merch-page-container.active {
  display: flex;
}

.merch-page-section {
  margin-bottom: 30px;
}

.merch-page-section .section-title {
  margin: 0 0 15px 0;
  font-size: 20px;
}

/* Hide sections when merch page is active */
.site-wrap.merch-active > section {
  display: none;
}

.site-wrap.merch-active > .scroll-spacer {
  display: none;
}

/* Rank Badge */
.rank-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.85);
  color: white;
  min-width: 32px;
  height: 32px;
  padding: 0 8px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 18px;
  font-family: 'Nunito', sans-serif;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
  z-index: 10;
  border: 2px solid rgba(255, 255, 255, 0.8);
}

/* Page Header Bar Styles */
.page-header-bar {
  position: sticky;
  top: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 15px 20px;
  display: flex;
  align-items: center;
  gap: 15px;
  z-index: 100;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.page-back-button {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  padding: 8px 16px;
  border-radius: 20px;
  color: white;
  font-family: 'Nunito', sans-serif;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.page-back-button:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateX(-2px);
}

.page-back-button:active {
  transform: scale(0.95);
}

.page-title {
  font-family: 'Nunito', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: white;
  margin: 0;
  flex: 1;
  text-align: left;
}

.page-search-input {
  flex: 1;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 10px 15px;
  border-radius: 20px;
  color: white;
  font-family: 'Nunito', sans-serif;
  font-size: 14px;
  outline: none;
  transition: all 0.2s ease;
}

.page-search-input::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.page-search-input:focus {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.4);
}

.page-content-scroll {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 20px;
  -webkit-overflow-scrolling: touch;
}

.page-main-title {
  font-family: 'Nunito', sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: white;
  margin: 0 0 25px 0;
  padding: 0;
  text-align: left;
}

/* Games page subtitle (small text under main title) */
.games-page-container .page-subtitle {
  font-family: 'Nunito', sans-serif;
  font-size: 13px;
  font-weight: 400;
  color: #bbbbbb;
  margin: -8px 0 18px 0;
  text-transform: none;
  letter-spacing: 0;
}

.page-content-scroll::-webkit-scrollbar {
  width: 8px;
}

.page-content-scroll::-webkit-scrollbar-track {
  background: rgba(20, 20, 20, 0.3);
}

.page-content-scroll::-webkit-scrollbar-thumb {
  background: rgba(50, 50, 50, 0.8);
  border-radius: 4px;
}

.page-content-scroll::-webkit-scrollbar-thumb:hover {
  background: rgba(70, 70, 70, 0.9);
}

/* YouTube Playlist Widget Styles */
.fs-wrapper {
  max-width: 100%;
  margin: 0 auto;
  padding: 0 0 40px 0;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

.fs-header {
  display: none;
}

.fs-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.fs-badge {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #bbbbbb;
}

/* Customizer (dev use) - controlled by SHOW_DEV_TOOLS */
.fs-customizer {
  background: #101010;
  border-radius: 14px;
  padding: 10px 12px;
  margin: 0 12px 16px;
  border: 1px solid #222;
  font-size: 12px;
}

.fs-customizer.hidden {
  display: none !important;
}

.fs-customizer h2 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: 6px;
  color: #bbbbbb;
}

.fs-customizer-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}

.fs-customizer-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1 1 120px;
}

.fs-customizer label {
  font-size: 11px;
  color: #bbbbbb;
}

.fs-customizer input[type="color"],
.fs-customizer input[type="range"],
.fs-customizer select {
  background: #0b0b0b;
  border-radius: 6px;
  border: 1px solid #333;
  color: #fff;
  padding: 3px 6px;
  font-size: 12px;
}

.fs-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #bbbbbb;
}

.fs-toggle input {
  accent-color: #ff0000;
}

/* Playlist Grid */
.fs-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  padding: 12px;
  flex: 1;
}

.fs-card {
  background: #000;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  cursor: pointer;
  transition: transform 0.12s ease-out, box-shadow 0.12s ease-out, background 0.12s ease-out;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: var(--playlist-card-bg-max-width);
  max-height: var(--playlist-card-bg-max-height);
}

.fs-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.45);
  background: #111;
}

.fs-thumb-wrap {
  position: relative;
  width: var(--playlist-card-max-width);
  flex-shrink: 0;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000;
}

.fs-thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.01);
}

.fs-duration {
  position: absolute;
  right: 5px;
  bottom: 5px;
  background: rgba(0, 0, 0, 0.8);
  color: #fff;
  font-size: 9px;
  padding: 2px 4px;
  border-radius: 4px;
  line-height: 1;
}

.fs-card-body {
  padding: 8px 12px 8px 0;
  flex: 1;
  min-width: 0;
}

.fs-video-title {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 3px;
  color: #ffffff;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.fs-video-date {
  font-size: 13px;
  color: #bbbbbb;
}

.fs-empty-state {
  color: #bbbbbb;
  font-size: 13px;
  padding: 16px 12px;
  text-align: center;
}

/* Playlist Modal */
.fs-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(3px);
  display: none;
  align-items: flex-start;
  justify-content: center;
  z-index: 10000;
  overflow-y: auto;
  padding: 0;
  padding-top: 0vh;
}

.fs-modal-backdrop.fs-open {
  display: flex;
}

.fs-modal {
  width: min(400px, 90vw);
  max-height: 90vh;
  margin: 0 auto 20px;
  border-radius: 18px;
  overflow: hidden;
  background: #000;
  box-shadow: 0 22px 40px rgba(0, 0, 0, 0.7);
  position: relative;
}

.fs-modal-inner {
  position: relative;
  padding-bottom: 177.78%;
  height: 0;
}

.fs-modal iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.fs-modal-close {
  position: absolute;
  top: 10px;
  right: var(--fs-modal-close-right);
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 20px;
  cursor: pointer;
  z-index: 2;
  transition: all 0.2s ease;
}

.fs-modal-close:hover {
  background: rgba(0, 0, 0, 0.9);
  transform: scale(1.1);
}

@media (max-width: 640px) {
  .fs-modal {
    width: 100vw;
    height: 100vh;
    margin: 0;
    border-radius: 0;
  }

  .fs-modal-close {
    top: 18px;
    right: 14px;
    width: 40px;
    height: 40px;
  }
}
