/* --- GLOBAL RESET & FIXES --- */
*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  overflow-x: hidden;
  width: 100%;
}

:root {
  --bg: #050505;
  --accent: #2962ff;
  --accent-glow: rgba(41, 98, 255, 0.6);
  --text: #eee;
  --text-muted: #bbb;
  --border: rgba(255, 255, 255, 0.1);
  
  --glass-bg: rgba(10, 10, 14, 0.7); 
  --glass-border: 1px solid rgba(255, 255, 255, 0.08);
  --glass-blur: blur(8px);
  --glass-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
  
  --font-ui: 'Segoe UI', system-ui, sans-serif;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

a { color: inherit; text-decoration: none; transition: 0.2s; }
a:hover { color: #fff; }
a.text-link { color: var(--accent); text-decoration: none; }
a.text-link:hover { text-decoration: underline; color: #fff; }

.glass-panel {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: var(--glass-border);
  box-shadow: var(--glass-shadow);
}

/* --- HERO BACKGROUND --- */
.hero-bg-container {
  position: fixed;
  top: 0; left: 0; 
  width: 100%; 
  height: 100vh;
  height: 100dvh;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.hero-bg {
  width: 100%;
  height: 60%;
  background: url('bg.jpg') no-repeat top center;
  background-size: cover;
  mask-image: linear-gradient(to bottom, black 50%, transparent 95%),
              linear-gradient(to right, transparent 0%, black 25%, black 75%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, black 50%, transparent 95%),
                      linear-gradient(to right, transparent 0%, black 25%, black 75%, transparent 100%);
  mask-composite: intersect;
  -webkit-mask-composite: source-in;
}

@media (max-width: 768px) {
  .hero-bg { background-size: 320% auto !important; }
}

.hero-overlay {
  position: absolute; inset: 0;
  background:
    linear-gradient(to bottom, transparent 40%, var(--bg) 100%),
    linear-gradient(to right, var(--bg) 0%, transparent 30%, transparent 70%, var(--bg) 100%);
}

/* --- LANGUAGE SWITCHER --- */
.lang-switcher {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 1000;
}
.lang-switcher select {
  background: rgba(10, 10, 14, 0.7);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 8px 14px;
  border-radius: 6px;
  font-family: var(--font-ui);
  font-size: 13px;
  cursor: pointer;
  backdrop-filter: blur(8px);
  outline: none;
}
.lang-switcher select option { background: #111; color: #fff; }

/* --- HEADER & MENU --- */
header {
  margin-top: 40px;
  margin-bottom: 10px; /* Controls top spacing of the equal-margin layout */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  z-index: 100; 
  width: 100%;
  max-width: 900px;
  padding: 0 20px;
}

.logo-img {
  max-width: 400px;
  width: 80%;
  height: auto;
  filter: drop-shadow(0 0 20px var(--accent-glow));
  transition: transform 0.2s;
  cursor: pointer;
}
.logo-img:hover { transform: scale(1.02); }

.social-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 100%;
}
.social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  color: #ccc;
  transition: all 0.2s ease;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  border: var(--glass-border);
  padding: 0;
}
.social-btn svg { width: 18px; height: 18px; fill: currentColor; display: block; }
.social-btn:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 0 15px var(--accent-glow);
}
#pk-socials { justify-content: flex-start; }

.menu-container {
  display: flex;
  flex-direction: column;
  align-items: stretch; 
  width: 100%;
  max-width: 450px;
  gap: 15px;
}

.nav-tabs {
  display: flex;
  width: 100%;
  padding: 8px;
  border-radius: 12px;
  justify-content: space-between;
  gap: 8px;
  box-shadow: 0 0 20px rgba(41, 98, 255, 0.15);
}

.tab-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: #aaa;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.2s;
  font-family: var(--font-ui);
}
.tab-btn:hover { color: #fff; background: rgba(255,255,255,0.05); }
.tab-btn.active {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 20px var(--accent-glow);
  text-shadow: 0 0 5px rgba(255,255,255,0.5);
}

.wishlist-header-btn {
  display: flex; 
  width: 100%;
  justify-content: center;
  box-sizing: border-box;
}

.cta-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px; /* More breathing room between icon and text */
  text-decoration: none;
  color: #fff;
  background: rgba(41, 98, 255, 0.15);
  border: 2px solid var(--accent);
  padding: 14px 20px; /* Generous breathing room on desktop */
  border-radius: 6px;
  font-weight: 800;
  font-size: clamp(8px, 3vw, 16px); /* Tweaked to allow proper shrinking */
  text-transform: uppercase;
  letter-spacing: 0.5px;
  backdrop-filter: blur(20px);
  transition: all 0.2s ease;
  box-shadow: 0 0 30px var(--accent-glow);
  white-space: nowrap; 
}

.cta-btn:hover { 
  background: var(--accent); 
  transform: scale(1.02); 
  box-shadow: 0 0 50px var(--accent-glow); 
}

.cta-btn svg { 
  width: 22px; 
  height: 22px; 
  fill: #fff; 
  filter: drop-shadow(0 0 5px rgba(255,255,255,0.5)); 
  flex-shrink: 0; 
}

/* --- MAIN CONTENT --- */
main {
  width: 100%;
  max-width: 900px;
  padding: 0 20px 20px 20px; 
  margin-top: 0;
  z-index: 10;
  flex: 1;
}

.panel { display: none; animation: fadeIn 0.4s ease; }
.panel.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

#glue-anim-container {
  width: 100%;
  height: 250px; 
  position: relative;
  z-index: 5;
  pointer-events: none; 
  margin-top: -80px; 
  margin-bottom: -10px; 
}

/* Spacing and Dimensions for Video/Tagline Alignment */
.video-container {
  position: relative;
  width: 100%; 
  max-width: 670px;
  aspect-ratio: 16 / 9; /* Modern fix for perfect video proportions */
  height: auto;
  margin: 0px auto; /* 30px gap above achieved by header's margin-bottom */
  overflow: hidden;
  border-radius: 12px;
  border: 2px solid rgba(41, 98, 255, 0.5);
  box-shadow: 0 0 30px var(--accent-glow);
  background: #000;
  margin-bottom: 20px;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transform: scale(1.0025);
  transform-origin: center center;
}

.home-desc-box {
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  max-width: 670px; 
  margin: 0 auto 20px auto;
}

.tagline {
  font-size: 20px;
  color: #ddd;
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
  text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

/* Dynamic Grid Systems for the PressKit */
.media-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; }
.media-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 15px; }
.logo-flex { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px; align-items: center; background: rgba(0,0,0,0.3); padding: 20px; border-radius: 8px; }

.faq-section { max-width: 700px; margin: 0 auto; }
.faq-title { text-align: center; font-size: 32px; margin-bottom: 24px; font-family: var(--font-ui); font-weight: 800; color: #fff; text-transform: uppercase; letter-spacing: 4px; }

details.faq-item { margin-bottom: 12px; border-radius: 8px; overflow: hidden; transition: background 0.2s; }
details.faq-item[open] { background: rgba(5, 5, 8, 0.9); border-color: #555; }
summary.faq-q { padding: 18px 24px; cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 10px; user-select: none; font-size: 16px; color: #fff; font-family: var(--font-ui); }
summary.faq-q::-webkit-details-marker { display: none; }
summary.faq-q::after { content: '+'; font-size: 20px; color: var(--text-muted); font-weight: 300; transition: transform 0.2s; flex-shrink: 0; }
details[open] summary.faq-q::after { transform: rotate(45deg); }
.faq-a { padding: 0 24px 24px 24px; color: var(--text-muted); line-height: 1.6; font-size: 15px; border-top: 1px solid rgba(255,255,255,0.05); margin-top: 0; padding-top: 15px; font-family: var(--font-ui); }

/* --- LEADERBOARD & SECTIONS --- */
.card { border-radius: 12px; padding: 30px; }
.lb-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; flex-wrap: wrap; gap: 12px; }
.lb-header h2 { margin: 0; font-size: 24px; text-transform: uppercase; letter-spacing: 2px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { font-size: 13px; padding: 6px 12px; border-radius: 20px; border: 1px solid var(--border); background: rgba(0,0,0,0.3); color: #888; cursor: pointer; transition: 0.2s; }
.chip:hover { color: #fff; border-color: #555; }
.chip[data-active="true"] { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 0 10px var(--accent-glow); }

.lb-rows { display: flex; flex-direction: column; }
.lb-row { display: flex; align-items: center; padding: 12px 8px; border-bottom: 1px dashed var(--border); }
.lb-row.head { font-weight: bold; color: #888; font-size: 12px; text-transform: uppercase; border-bottom: 1px solid #444; }
.col-rank { width: 40px; text-align: center; color: var(--accent); font-weight: bold; }
.col-name { flex: 1; padding: 0 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.col-score { width: 100px; text-align: right; font-family: monospace; font-size: 16px; font-weight: bold; color: #fff; }
.lb-msg { padding: 20px; text-align: center; color: #666; font-style: italic; }

.streamer-guide { background: rgba(0,0,0,0.3); padding: 20px; border-radius: 8px; border: 1px solid var(--border); margin-top: 20px; }
.streamer-guide h4 { margin-top: 0; color: #fff; }
.streamer-guide ol { padding-left: 20px; color: #ccc; line-height: 1.6; }
.streamer-box-row { display: flex; gap: 10px; margin-top: 10px; }
.streamer-link-box { background: #111; padding: 10px; border: 1px dashed #444; color: #888; font-family: monospace; font-size: 12px; word-break: break-all; border-radius: 4px; flex: 1; min-width: 0; }
.copy-btn { background: #222; border: 1px solid #444; color: #fff; padding: 12px 16px; border-radius: 4px; cursor: pointer; font-weight: bold; font-size: 12px; text-transform: uppercase; transition: all 0.2s; min-height: 44px; display: flex; align-items: center; justify-content: center; }
.copy-btn:hover { background: var(--accent); border-color: var(--accent); }

/* --- PRESS KIT --- */
.pk-header { border-bottom: 1px solid var(--border); padding-bottom: 20px; margin-bottom: 30px; }
.pk-header h2 { margin: 0; font-size: 28px; color: #fff; text-transform: uppercase; letter-spacing: 2px; }
.pk-grid { display: grid; grid-template-columns: 260px 1fr; gap: 40px; align-items: start; }
.pk-sidebar { padding: 20px; border-radius: 8px; }
.pk-section-title { font-size: 14px; color: #fff; text-transform: uppercase; letter-spacing: 1px; border-bottom: 1px solid #333; padding-bottom: 8px; margin-bottom: 15px; margin-top: 0; }
.pk-fact { margin-bottom: 16px; }
.pk-fact strong { display: block; color: #888; font-size: 11px; text-transform: uppercase; margin-bottom: 4px; }
.pk-fact span, .pk-fact a:not(.social-btn) { color: #eee; font-size: 14px; display: block; line-height: 1.4; }

.pk-block { margin-bottom: 40px; }
.pk-block h3 { border-bottom: 1px solid var(--border); padding-bottom: 10px; color: var(--accent); text-transform: uppercase; letter-spacing: 1px; font-size: 16px; margin-top: 0; }
.pk-block p { color: #ccc; line-height: 1.7; margin-bottom: 15px; }
.pk-block ul { padding-left: 20px; color: #ccc; line-height: 1.7; }
.pk-block li { margin-bottom: 8px; }
.pk-copy-text { display: block; background: rgba(0,0,0,0.3); padding: 12px; border-left: 3px solid var(--accent); color: #ddd; font-style: italic; font-size: 14px; margin-top: 5px; }
.pk-angles-list li { margin-bottom: 12px; }
.pk-angles-list strong { color: #fff; }

.btn-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.btn-pk { display: inline-flex; align-items: center; gap: 8px; background: linear-gradient(135deg, #1a237e 0%, #283593 100%); border: 1px solid #3949ab; color: #fff; padding: 12px 20px; border-radius: 6px; font-size: 13px; font-weight: 700; text-decoration: none; text-transform: uppercase; letter-spacing: 0.5px; box-shadow: 0 4px 6px rgba(0,0,0,0.3); transition: all 0.2s ease; }
.btn-pk:hover { background: linear-gradient(135deg, #283593 0%, #3949ab 100%); transform: translateY(-2px); box-shadow: 0 6px 12px rgba(41, 98, 255, 0.3); border-color: #5c6bc0; }

/* --- FOOTER --- */
footer { margin-top: auto; padding: 60px 20px; width: 100%; background: linear-gradient(to top, #000 0%, transparent 100%); text-align: center; color: #999; font-size: 11px; line-height: 1.6; }
.footer-content { max-width: 800px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; }
.footer-logo { width: 100px; height: auto; opacity: 0.6; margin-bottom: 10px; transition: opacity 0.3s; }
.footer-logo:hover { opacity: 1; }
.steam-logo { width: 100px; height: auto; opacity: 0.5; margin-bottom: 15px; margin-top: 10px; }
.legal-text { margin-bottom: 15px; }

.other-games { margin-bottom: 30px; margin-top: 20px; }
.other-games h4 { margin: 0 0 10px 0; color: #FFF; text-transform: uppercase; font-size: 10px; letter-spacing: 1px; }
.game-links { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; }
.game-links a { color: #999; font-size: 12px; font-weight: bold; text-transform: uppercase; border-bottom: 1px solid transparent; }
.game-links a:hover { color: #fff; border-color: #2962ff; }

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
  .lang-switcher { position: relative; top: 0; right: 0; margin-top: 15px; }
  .pk-grid { grid-template-columns: 1fr; }
  .pk-sidebar { order: 1; }
  .pk-main { order: 2; }
  .lb-header { flex-direction: column; align-items: flex-start; }
  
  /* Mobile Stacking Resets for Media */
  .media-grid-3 { grid-template-columns: 1fr; }
  .media-grid-2 { grid-template-columns: 1fr; }
  .logo-flex { flex-direction: column; text-align: center; }

  .card { border-radius: 12px; padding: 15px; }
  
  .nav-tabs { padding: 4px; gap: 4px; }
  .tab-btn { padding: 12px 2px; font-size: 11px; }
  
  .logo-img { width: 90%; max-width: 320px; } /* Ensures logo scales down smoothly */
  header { padding: 0 10px; }
  main { padding: 0 10px 20px 10px; }
  .tagline { padding: 0 10px; font-size: 16px; }
  .streamer-box-row { flex-direction: column; }
  .copy-btn { width: 100%; }
  
  /* Shrink social icons slightly to guarantee they fit */
  .social-row { gap: 6px; }
  .social-btn { width: 32px; height: 32px; }
  .social-btn svg { width: 16px; height: 16px; }
  
  .cta-btn { padding: 12px 4px; }
}

/* let grid children actually shrink on small screens */
.pk-sidebar,
.pk-main {
  min-width: 0;
}

/* wrap long fact values (languages, emails, etc) */
.pk-fact span,
.pk-fact a:not(.social-btn) {
  overflow-wrap: anywhere;
  word-break: break-word;
}