/* ============================================================
   GamzyHost – Navbar  (navbar.css)
   ============================================================ */

:root {
  --nav-h: 68px;
  --nav-bg: rgba(16, 13, 9, 0.75);
  --nav-border: rgba(255,255,255,0.07);
}

.ghnav *, .ghnav *::before, .ghnav *::after { box-sizing: border-box; }

/* ══════════════════════════════════
   BARRA PRINCIPAL
   ══════════════════════════════════ */
.ghnav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 9000;
  background: var(--nav-bg);
  backdrop-filter: blur(22px) saturate(150%);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
  /* Borde inferior simple, sin gradiente llamativo */
  border-bottom: 1px solid var(--nav-border);
  transition: background 0.3s, box-shadow 0.3s;
}

.ghnav.ghnav-scrolled {
  background: rgba(13, 11, 7, 0.97);
  box-shadow: 0 8px 32px rgba(0,0,0,0.45);
}

/* ── Contenedor ── */
.ghnav-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

/* ── Logo ── */
.ghnav-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
}
.ghnav-logo img {
  height: 34px;
  width: auto;
  display: block;
  transition: opacity 0.2s, transform 0.2s;
}
.ghnav-logo:hover img { opacity: 0.85; transform: scale(1.02); }

/* ══════════════════════════════════
   LINKS CENTRO
   ══════════════════════════════════ */
.ghnav-links {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 0.1rem;
}

.ghnav-item {
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  font-weight: 500;
  color: #afa89d;
  text-decoration: none;
  padding: 0.48rem 0.85rem;
  border-radius: 7px;
  position: relative;
  transition: color 0.15s, background 0.15s;
  white-space: nowrap;
  cursor: pointer;
  border: none;
  background: transparent;
  display: flex;
  align-items: center;
  line-height: 1;
}
.ghnav-item:hover {
  color: #fff;
  background: rgba(255,255,255,0.055);
}

/* Activo: color blanco + dot naranja abajo */
.ghnav-item.ghnav-active { color: #fff; font-weight: 600; }
.ghnav-item.ghnav-active::after {
  content: "";
  position: absolute;
  bottom: 3px;
  left: 50%; transform: translateX(-50%);
  width: 16px; height: 2px;
  background: #f7a01e;
  border-radius: 999px;
}

/* ── Dropdown trigger ── */
.ghnav-dropdown-trigger {
  display: flex;
  align-items: center;
  gap: 5px;
  user-select: none;
}
.ghnav-chevron {
  font-size: 0.6rem !important;
  transition: transform 0.2s ease;
  opacity: 0.6;
}
.ghnav-has-dropdown:hover .ghnav-chevron,
.ghnav-has-dropdown.ghnav-dd-open .ghnav-chevron {
  transform: rotate(180deg);
  opacity: 1;
}

/* ══════════════════════════════════
   MEGA-DROPDOWN — REDISEÑO
   ══════════════════════════════════ */
.ghnav-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  width: 480px;
  background: #111009;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 18px;
  padding: 0.75rem;
  box-shadow:
    0 32px 80px rgba(0,0,0,0.8),
    0 0 0 1px rgba(255,255,255,0.03),
    inset 0 1px 0 rgba(255,255,255,0.05);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

/* Puente hover desktop */
@media (hover: hover) and (pointer: fine) {
  .ghnav-has-dropdown::before {
    content: "";
    position: absolute;
    top: 100%;
    left: -30px; right: -30px;
    height: 16px;
  }
  .ghnav-has-dropdown:hover .ghnav-dropdown {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
  }
}
.ghnav-has-dropdown.ghnav-dd-open .ghnav-dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

/* Header */
.ghdd-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.2rem 0.6rem 0.6rem;
  margin-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.ghdd-header-label {
  font-size: 0.63rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: rgba(175,168,157,0.4);
}
.ghdd-header-all {
  font-size: 0.7rem;
  font-weight: 600;
  color: #f7a01e;
  text-decoration: none;
  opacity: 0.7;
  transition: opacity 0.15s;
}
.ghdd-header-all:hover { opacity: 1; }

/* Grid — 2 columnas para más de 1 juego */
.ghdd-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
}

/* Tarjeta — layout vertical con imagen arriba */
.ghdd-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-radius: 12px;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,0.06);
  background: rgba(255,255,255,0.02);
  transition: background 0.15s, border-color 0.18s, transform 0.15s, box-shadow 0.18s;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.ghdd-card:hover {
  background: rgba(255,255,255,0.055);
  border-color: var(--game-color, #f7a01e);
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(0,0,0,0.4), 0 0 0 1px var(--game-color, #f7a01e);
}

/* Glow de fondo del color del juego */
.ghdd-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at top center,
    var(--game-color, #f7a01e) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 0.22s;
  pointer-events: none;
}
.ghdd-card:hover::before { opacity: 0.06; }

.ghdd-card-soon { opacity: 0.38; cursor: not-allowed; }
.ghdd-card-soon:hover {
  background: rgba(255,255,255,0.02) !important;
  border-color: rgba(255,255,255,0.06) !important;
  transform: none !important;
  box-shadow: none !important;
}
.ghdd-card-soon:hover::before { opacity: 0 !important; }

/* Imagen — banner horizontal */
.ghdd-img-wrap {
  width: 100%;
  height: 110px;
  overflow: hidden;
  flex-shrink: 0;
  background: rgba(255,255,255,0.04);
  position: relative;
}
.ghdd-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  transition: transform 0.35s ease;
}
.ghdd-card:hover .ghdd-img-wrap img {
  transform: scale(1.06);
}
.ghdd-img-fallback {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  background: linear-gradient(135deg, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0.07) 100%);
}

/* Degradado sobre imagen */
.ghdd-img-wrap::after {
  content: "";
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 50px;
  background: linear-gradient(to top, #111009 0%, transparent 100%);
  pointer-events: none;
}

/* Info — debajo de la imagen */
.ghdd-info {
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
  padding: 0.6rem 0.75rem 0.7rem;
}
.ghdd-name {
  font-size: 0.875rem;
  font-weight: 700;
  color: #f2ede7;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  line-height: 1.2;
}
.ghdd-desc {
  font-size: 0.72rem;
  color: rgba(175,168,157,0.6);
  line-height: 1.35;
}
.ghdd-price {
  font-size: 0.75rem;
  font-weight: 700;
  color: #f7a01e;
  margin-top: 0.15rem;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}
.ghdd-price::before {
  content: "";
  display: inline-block;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: #f7a01e;
  flex-shrink: 0;
}

/* Badges */
.ghdd-badge {
  font-size: 0.56rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 2px 5px;
  border-radius: 4px;
  background: #f7a01e;
  color: #1d1a15;
  line-height: 1.5;
}
.ghdd-badge-soon {
  background: rgba(255,255,255,0.1);
  color: rgba(175,168,157,0.7);
}

/* ══════════════════════════════════
   DERECHA
   ══════════════════════════════════ */
.ghnav-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

/* Status: solo punto verde, sin "Online" ni pill */
.ghnav-status {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: rgba(34,197,94,0.08);
  border: 1px solid rgba(34,197,94,0.2);
  text-decoration: none;
  transition: background 0.2s;
  flex-shrink: 0;
}
.ghnav-status:hover { background: rgba(34,197,94,0.15); }

.ghnav-status-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #22c55e;
  animation: nav-pulse 2.5s infinite;
}
@keyframes nav-pulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(34,197,94,0.55); }
  50%      { box-shadow: 0 0 0 4px rgba(34,197,94,0); }
}
/* Ocultar la etiqueta "Online" — solo queda el punto */
.ghnav-status-label { display: none; }

/* Usuario */
.ghnav-user-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  color: #afa89d;
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
  position: relative;
}
.ghnav-user-icon i { font-size: 1.1rem; }
.ghnav-user-icon::after {
  content: "";
  position: absolute;
  right: 2px; bottom: 2px;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #f7a01e;
  border: 1.5px solid #1d1a15;
}
.ghnav-user-icon:hover {
  border-color: rgba(247,160,30,0.4);
  color: #f7a01e;
  background: rgba(247,160,30,0.06);
}

/* CTA */
.ghnav-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0.5rem 1.1rem;
  border-radius: 8px;
  background: #f7a01e;
  color: #1d1a15;
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background 0.15s, transform 0.15s, box-shadow 0.15s;
  box-shadow: 0 2px 10px rgba(247,160,30,0.25);
  white-space: nowrap;
}
.ghnav-cta i { font-size: 1rem; }
.ghnav-cta:hover {
  background: #ffb030;
  transform: translateY(-1px);
  box-shadow: 0 5px 18px rgba(247,160,30,0.38);
}
.ghnav-cta:active { transform: translateY(0); }

/* Hamburguesa */
.ghnav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 38px; height: 38px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s;
}
.ghnav-hamburger:hover { background: rgba(255,255,255,0.08); }
.ghnav-hamburger span {
  display: block;
  width: 18px; height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.24s, opacity 0.24s, width 0.24s;
  transform-origin: center;
}
.ghnav-hamburger.ghnav-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.ghnav-hamburger.ghnav-open span:nth-child(2) { opacity: 0; width: 0; }
.ghnav-hamburger.ghnav-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.ghnav-btn-mobile { display: none; }

/* ══════════════════════════════════
   MÓVIL
   ══════════════════════════════════ */
@media (max-width: 860px) {
  .ghnav-inner { padding: 0 1.25rem; }

  .ghnav-links {
    position: fixed;
    top: var(--nav-h);
    left: 0; right: 0;
    transform: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.2rem;
    background: #0f0d08;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    padding: 1rem 1rem 1.25rem;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
    transition: opacity 0.22s ease, transform 0.22s ease;
    max-height: calc(100vh - var(--nav-h));
    overflow-y: auto;
  }
  .ghnav-links.ghnav-open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .ghnav-item {
    font-size: 0.95rem;
    padding: 0.7rem 0.85rem;
    border-radius: 8px;
    justify-content: flex-start;
  }
  .ghnav-item.ghnav-active::after { display: none; }
  .ghnav-item.ghnav-active {
    background: rgba(247,160,30,0.08);
    color: #f7a01e;
  }

  .ghnav-has-dropdown { flex-direction: column; align-items: stretch; }
  .ghnav-dropdown-trigger { padding: 0.7rem 0.85rem; border-radius: 8px; width: 100%; }

  .ghnav-dropdown {
    position: static !important;
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    box-shadow: none;
    border: none;
    background: rgba(255,255,255,0.02);
    border-radius: 9px;
    padding: 0.35rem;
    margin-top: 0.2rem;
    width: 100%;
    min-width: unset;
  }
  .ghdd-header { display: none; }
  /* En móvil: tarjetas en fila horizontal compacta */
  .ghdd-grid { grid-template-columns: 1fr 1fr; gap: 0.3rem; }
  .ghdd-img-wrap { height: 70px; }
  .ghdd-info { padding: 0.45rem 0.55rem 0.5rem; }
  .ghdd-name { font-size: 0.78rem; }
  .ghdd-desc { display: none; }
  .ghdd-card:hover { transform: none; box-shadow: none; }
  .ghdd-card:hover::before { opacity: 0; }

  .ghnav-status { display: none; }
  .ghnav-cta-desktop { display: none; }
  .ghnav-hamburger { display: flex; }

  .ghnav-btn-mobile {
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    margin-top: 0.6rem;
    padding: 0.7rem;
    border-radius: 8px;
    background: #f7a01e;
    color: #1d1a15;
    font-size: 0.875rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    text-decoration: none;
  }
}

@media (max-width: 480px) {
  .ghnav-user-icon { display: none; }
}

body { padding-top: var(--nav-h) !important; }