/* style.css */

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

/* Body with animated gradient */
body {
  font-family: 'Roboto', sans-serif;
  background: linear-gradient(-45deg, #011034, #2B4F8D, #011034, #2B4F8D);
  background-size: 400% 400%;
  animation: gradientBG 15s ease infinite;
  color: #FE00EC;
}

/* Gradient animation */
@keyframes gradientBG {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Header */
.header {
  text-align: center;
  padding: 40px 20px;
  font-family: 'Press Start 2P', cursive;
  font-size: 42px;
  color: #FE00EC;
  text-shadow: 0 0 5px #FE00EC, 0 0 10px #FE00EC, 0 0 20px #FE00EC;
}

/* Hero Banner */
.hero {
  background: url('https://via.placeholder.com/1200x400.png?text=Featured+Game') center/cover no-repeat;
  height: 300px;
  border-radius: 15px;
  margin: 20px;
  box-shadow: 0 0 20px rgba(255,0,236,0.7);
  border: 2px solid #FE00EC;
}

/* Main container for left and right columns */
.main-container {
  display: flex;
  align-items: flex-start; /* ensures right column starts at same height as left */
  gap: 20px;
  padding: 20px;
  width: 100%;
}

/* Left column placeholder acts like .leftcolumn */
#left-column-placeholder {
  flex: 1;
  min-width: 0;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
}

/* Left column */
.leftcolumn {
  flex: 1;
}

/* Game Cards */
.card {
  background-color: rgba(2,201,175,0.9);
  padding: 20px;
  margin-bottom: 20px;
  border-radius: 15px;
  box-shadow: 0 0 10px #FE00EC, 0 0 20px #02C9AF;
  transition: transform 0.2s, box-shadow 0.3s;
  color: #011034;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 0 20px #FE00EC, 0 0 40px #02C9AF;
}

.card h2 {
  font-family: 'Press Start 2P', cursive;
  color: #FE00EC;
  text-shadow: 0 0 3px #FE00EC;
  margin-bottom: 10px;
}

/* Right Sidebar wrapper */
.rightcolumn-wrapper {
  width: 250px;
  flex-shrink: 0;
  align-self: flex-start; /* aligns sidebar with top of left column */
}

/* Sticky sidebar (scrolls normally but stays visible) */
.rightcolumn {
  position: sticky;
  top: 20px; /* sits right below hero/banner */
  width: 250px;
  max-height: calc(100vh - 40px); /* avoids footer overlap */
  overflow-y: auto;
  background: none;
  z-index: 5;
}

/* Sidebar panels */
.rightcolumn .sidepanels {
  background-color: rgba(2,201,175,0.9);
  padding: 15px;
  margin-bottom: 20px;
  border-radius: 10px;
  box-shadow: 0 0 10px #FE00EC, 0 0 20px #02C9AF;
}

/* Links */
a {
  color: #FE00EC;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* Footer */
.footer {
  text-align: center;
  padding: 20px;
  background: rgba(43,79,141,0.9);
  color: #FE00EC;
  font-family: 'Press Start 2P', cursive;
  margin-top: 20px;
  text-shadow: 0 0 5px #FE00EC;
}

/* Game container layout */
.game-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 100%;
}

/* Toolbar stays full width */
.game-toolbar {
  width: 100%;
  text-align: left;
  display: flex;
  gap: 10px;
  justify-content: flex-start;
}

/* Buttons */
.back-btn, .fullscreen-btn {
  padding: 8px 16px;
  border: none;
  border-radius: 8px;
  background-color: #02C9AF;
  color: #011034;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.back-btn:hover, .fullscreen-btn:hover {
  background-color: #03E4C4;
}

/* Game frame wrapper fills available space */
.game-frame-wrapper {
  width: 100%;
  flex-grow: 1;
  min-height: 70vh; /* fits nicely under header */
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #000;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 0 10px rgba(0,0,0,0.4);
}

/* Game iframe fills horizontally & vertically */
.game-frame {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
  background: #000;
  border-radius: 10px;
}

/* Responsive layout */
@media screen and (max-width: 800px) {
  .main-container {
    flex-direction: column;
  }

  .leftcolumn,
  #left-column-placeholder {
    width: 100%;
  }

  .rightcolumn-wrapper {
    width: 100%;
  }

  .rightcolumn {
    position: relative;
    top: 0;
    max-height: none;
    overflow: visible;
    right: 0;
  }

  .hero {
    height: 200px;
    margin: 10px 0;
  }

  .game-frame-wrapper {
    min-height: 60vh;
  }
}
