/* =============================================
   CREATORS — Game Detail Page
   style-detail.css
   Dipakai oleh SEMUA halaman detail game.
   Load setelah /style.css global.
   ============================================= */

/* ===================== DETAIL HERO ===================== */
.detail-hero {
  position: relative;
  min-height: 52vh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  padding-bottom: 4rem;
}

.detail-hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.04);
  transition: transform 8s ease;
  filter: brightness(0.6);
}
.detail-hero:hover .detail-hero-bg {
  transform: scale(1.0);
}

.detail-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(10,10,20,1) 0%,
    rgba(10,10,20,0.75) 40%,
    rgba(10,10,20,0.3) 100%
  );
  z-index: 1;
}

.detail-hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(107,176,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(107,176,255,0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  z-index: 1;
  pointer-events: none;
}

.detail-hero-content {
  position: relative;
  z-index: 10;
  width: 100%;
  padding-top: 7rem;
}

.detail-hero-inner {
  max-width: 760px;
}

.detail-genre-badge {
  display: inline-block;
  background: rgba(254,206,72,0.15);
  border: 1px solid rgba(254,206,72,0.3);
  color: var(--yellow);
  font-family: var(--font-bold);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  margin-bottom: 1rem;
  text-transform: uppercase;
}

.detail-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.4rem);
  color: var(--white);
  line-height: 1.15;
  margin-bottom: 1.5rem;
  text-shadow: 0 2px 20px rgba(0,0,0,0.5);
  animation: glitch-text 4s infinite;
}

/* Meta row */
.detail-meta-row {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.detail-meta-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.meta-label {
  font-size: 0.7rem;
  color: rgba(255,255,255,0.35);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.meta-value {
  font-family: var(--font-bold);
  font-size: 0.9rem;
  color: rgba(255,255,255,0.85);
}

.detail-meta-sep {
  width: 1px;
  height: 32px;
  background: rgba(255,255,255,0.12);
  flex-shrink: 0;
}

/* Wave */
.detail-hero-wave {
  position: absolute;
  bottom: 0; left: 0;
  width: 100%;
  z-index: 5;
  line-height: 0;
}
.detail-hero-wave svg {
  width: 100%;
  height: 60px;
}

/* ===================== MAIN LAYOUT ===================== */
.detail-main {
  background: #0f0f1e;
  padding: 3rem 0 5rem;
}

.detail-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 2rem;
  align-items: start;
}

/* ===================== MAIN COLUMN CARDS ===================== */
.detail-card {
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-bottom: 1.5rem;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.detail-card.revealed {
  opacity: 1;
  transform: translateY(0);
}

.detail-card-label {
  font-size: 0.75rem;
  color: var(--cyan);
  font-family: var(--font-bold);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.detail-section-title {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 3vw, 1.8rem);
  color: var(--white);
  margin-bottom: 1.2rem;
  line-height: 1.3;
}

.detail-body-text p {
  color: rgba(255,255,255,0.65);
  font-size: 0.97rem;
  line-height: 1.8;
  margin-bottom: 1rem;
}
.detail-body-text p:last-child { margin-bottom: 0; }
.detail-body-text strong { color: var(--yellow); }
.detail-body-text em {
  color: var(--cyan);
  font-style: normal;
  font-family: var(--font-bold);
}

/* ===================== SCREENSHOT GRID ===================== */
.screenshot-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.ss-img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--dark-border);
  cursor: pointer;
  transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
  display: block;
}
.ss-img:hover {
  transform: scale(1.04);
  border-color: var(--yellow);
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.screenshot-empty {
  color: rgba(255,255,255,0.3);
  font-size: 0.88rem;
  text-align: center;
  padding: 2rem 0;
}

/* ===================== PLAY SECTION ===================== */
.play-warning {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  background: rgba(254,206,72,0.06);
  border: 1px solid rgba(254,206,72,0.15);
  border-radius: 10px;
  padding: 0.9rem 1.1rem;
  margin-bottom: 1.8rem;
  font-size: 0.88rem;
  color: rgba(255,255,255,0.55);
}
.warning-icon { font-size: 1.1rem; flex-shrink: 0; }
.play-warning strong { color: var(--yellow); }

.play-cta {
  text-align: center;
  padding: 1rem 0;
}
.play-cta p {
  color: rgba(255,255,255,0.45);
  font-size: 0.9rem;
  margin-bottom: 1.2rem;
}

/* Play button */
.btn-play {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(135deg, var(--orange) 0%, #ff8a00 100%);
  color: var(--white);
  font-family: var(--font-bold);
  font-size: 1.1rem;
  padding: 1rem 2.5rem;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 4px 24px rgba(255,72,0,0.35);
  letter-spacing: 0.02em;
}
.btn-play:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 32px rgba(255,72,0,0.5);
}
.play-icon {
  font-size: 1.3rem;
  animation: badge-dot-pulse 2s infinite;
}

/* Game iframe */
.game-iframe-wrapper {
  border: 1px solid var(--dark-border);
  border-radius: var(--radius);
  overflow: hidden;
  background: #000;
  box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}

.game-iframe-bar {
  background: rgba(255,255,255,0.04);
  border-bottom: 1px solid var(--dark-border);
  padding: 0.6rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.game-iframe-title {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.5);
  font-family: var(--font-bold);
}
.game-fullscreen-btn {
  background: none;
  border: 1px solid var(--dark-border);
  color: rgba(255,255,255,0.4);
  border-radius: 6px;
  padding: 0.2rem 0.5rem;
  cursor: pointer;
  font-size: 0.9rem;
  transition: color 0.2s, border-color 0.2s;
}
.game-fullscreen-btn:hover {
  color: var(--yellow);
  border-color: var(--yellow);
}

.iframe-inner {
  position: relative;
  width: 100%;
  aspect-ratio: 4/3;
}
.iframe-inner iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

/* ===================== SIDEBAR ===================== */
.detail-col-side {
  position: sticky;
  top: 80px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.side-card {
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-lg);
  padding: 1.4rem;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.side-card.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Dev card */
.dev-card {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.dev-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--dark);
  flex-shrink: 0;
  box-shadow: 0 0 16px rgba(107,176,255,0.3);
}
.dev-name {
  font-family: var(--font-bold);
  color: var(--white);
  font-size: 0.92rem;
  margin-bottom: 2px;
}
.dev-school {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.4);
  margin-bottom: 6px;
}
.dev-badge {
  display: inline-block;
  background: rgba(254,206,72,0.12);
  border: 1px solid rgba(254,206,72,0.25);
  color: var(--yellow);
  font-size: 0.68rem;
  font-family: var(--font-bold);
  padding: 0.15rem 0.6rem;
  border-radius: 999px;
  letter-spacing: 0.06em;
}

/* Info card */
.side-card-title {
  font-family: var(--font-bold);
  font-size: 0.75rem;
  color: var(--cyan);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.info-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.info-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.84rem;
  padding-bottom: 0.7rem;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.info-list li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.info-key { color: rgba(255,255,255,0.35); }
.info-val {
  color: rgba(255,255,255,0.75);
  font-family: var(--font-bold);
  text-align: right;
}
.status-live { color: #4caf50 !important; }

/* Back button */
.side-back-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.2rem;
  background: transparent;
  border: 1px solid var(--dark-border);
  border-radius: var(--radius);
  color: rgba(255,255,255,0.5);
  font-size: 0.88rem;
  font-family: var(--font-bold);
  transition: border-color 0.2s, color 0.2s, background 0.2s;
  text-decoration: none;
}
.side-back-btn:hover {
  border-color: var(--cyan);
  color: var(--cyan);
  background: rgba(0,240,255,0.05);
}

/* Promo card */
.promo-card {
  background: linear-gradient(135deg, rgba(107,176,255,0.08), rgba(0,240,255,0.05));
  border-color: rgba(107,176,255,0.2);
}
.promo-text p {
  color: rgba(255,255,255,0.6);
  font-size: 0.88rem;
  line-height: 1.6;
  margin-bottom: 1rem;
}

/* ===================== LIGHTBOX (screenshot click) ===================== */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.9);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(6px);
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: var(--radius);
  box-shadow: 0 0 60px rgba(0,0,0,0.8);
}
.lightbox-close {
  position: absolute;
  top: 1.5rem; right: 1.5rem;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  color: white;
  width: 40px; height: 40px;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}
.lightbox-close:hover { background: rgba(255,255,255,0.2); }

/* ===================== RESPONSIVE ===================== */
@media (max-width: 900px) {
  .detail-layout {
    grid-template-columns: 1fr;
  }
  .detail-col-side {
    position: static;
    /* Sidebar turun ke bawah main content di mobile */
  }
  .screenshot-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .detail-meta-row {
    gap: 0.8rem;
  }
}

@media (max-width: 480px) {
  .detail-hero { min-height: 44vh; }
  .detail-title { font-size: 1.8rem; }
  .screenshot-grid { grid-template-columns: repeat(2, 1fr); }
  .detail-card { padding: 1.4rem; }
  .detail-meta-sep { display: none; }
  .detail-meta-row { flex-direction: column; gap: 0.6rem; }
}
