@import url("../inicio/inicio.css");
body {
  overflow: hidden;
  background: #020403;
}
.galeria-pagina {
  position: absolute;
  top: 50%;
  left: 50%;
  isolation: isolate;
  width: 1920px;
  height: 1080px;
  overflow: hidden;
  color: #e9e0d2;
  background: url("../imagenes/6.1.png") center/cover no-repeat;
  transform: translate(-50%, -50%) scale(var(--escala, 1));
  transform-origin: center;
}
.galeria-pagina::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  content: "";
  background: rgba(0, 5, 4, 0.58);
  box-shadow: inset 0 0 140px #000;
}
.galeria-pagina a {
  text-decoration: none;
}
.cabecera {
  position: absolute;
  top: 24px;
  right: 35px;
  left: 35px;
  display: flex;
  align-items: center;
  gap: 18px;
}
.insignia {
  width: 78px;
  color: var(--oro-claro);
  font-size: 28px;
}
.marca {
  font-size: 17px;
}
.marca span {
  font-size: 12px;
}
.controles {
  margin-left: auto;
}
.controles button,
.controles span {
  padding: 13px 18px;
}
.titulo {
  position: absolute;
  top: 72px;
  left: 410px;
  width: 1370px;
  text-align: center;
}
.titulo h1 {
  font-size: 48px;
  line-height: 1;
  letter-spacing: 0.01em;
}
.titulo p {
  margin: 8px 0;
  color: var(--cian);
  font-size: 16px;
}
.panel-lateral {
  position: absolute;
  top: 145px;
  left: 75px;
  width: 305px;
}
.filtros {
  padding: 15px 18px;
  border: 1px solid #805719;
  background: #030707e8;
}
.filtros h2 {
  margin: 0 0 16px;
  color: var(--cian);
  font-size: 13px;
}
.filtros button {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  height: 40px;
  margin: 0 0 8px;
  padding: 0 14px;
  border: 1px solid #805719;
  color: #e2d8c9;
  background: #050807;
  text-align: left;
}
.filtros button.activo {
  border-color: var(--cian);
  color: var(--cian);
  background: #062126;
}
.estadisticas {
  margin-top: 16px;
  border: 1px solid #805719;
  background: #030707e8;
}
.estadisticas p {
  display: flex;
  align-items: center;
  height: 64px;
  margin: 0;
  padding: 10px 24px;
  border-bottom: 1px solid #805719;
}
.estadisticas p:last-child {
  border: 0;
}
.estadisticas b {
  width: 105px;
  color: var(--oro-claro);
  font-size: 24px;
}
.estadisticas span {
  font-size: 12px;
  line-height: 1.4;
}
.volver {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 16px;
  padding: 19px;
  border: 1px solid #805719;
  color: var(--cian);
  background: #030707e8;
  font-size: 16px;
}
.volver span {
  display: flex;
  flex-direction: column;
}
.volver small {
  margin-top: 7px;
  font-size: 10px;
}
.proyectos {
  position: absolute;
  top: 170px;
  left: 430px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-auto-rows: 122px;
  gap: 9px;
  width: 1415px;
}
.tarjeta {
  position: relative;
  overflow: hidden;
  padding: 6px;
  border: 1px solid #805719;
  color: #ddd3c5;
  background: #030707e8;
  cursor: pointer;
}
.tarjeta:hover,
.tarjeta:focus-visible {
  border-color: var(--cian);
  filter: brightness(1.2);
  outline: none;
}
.tarjeta img,
.sin-imagen {
  display: block;
  width: 100%;
  height: 72px;
  object-fit: cover;
  object-position: top;
  border-bottom: 1px solid #4f3918;
  background: #111;
}
.sin-imagen {
  display: grid;
  place-items: center;
  color: #796e5d;
}
.numero {
  position: absolute;
  top: 6px;
  left: 6px;
  display: grid;
  place-items: center;
  width: 35px;
  height: 30px;
  border: 1px solid #a97420;
  color: var(--oro-claro);
  background: #050807e8;
  font-size: 18px;
}
.tarjeta strong {
  display: block;
  margin-top: 5px;
  color: var(--oro-claro);
  font-size: 13px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tarjeta small {
  display: block;
  margin-top: 2px;
  overflow: hidden;
  color: var(--cian);
  font-size: 9px;
  text-align: center;
  text-transform: uppercase;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.menu-inferior {
  position: absolute;
  right: 35px;
  bottom: 22px;
  left: 35px;
  display: grid;
  grid-template-columns: 1.1fr repeat(3, 1fr) 120px repeat(3, 1fr);
  height: 88px;
  border: 2px solid #805719;
  background: #030706f2;
}
.menu-inferior > a,
.menu-inferior > span:not(.sello) {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 10px;
  border-right: 1px solid #634315;
  color: var(--oro-claro);
}
.menu-inferior a span,
.menu-inferior > span {
  font-weight: 700;
}
.menu-inferior small {
  display: block;
  margin-top: 6px;
  color: #d4cbbb;
  font-size: 10px;
}
.menu-inferior .sello {
  display: grid;
  place-items: center;
  width: 112px;
  height: 112px;
  align-self: center;
  border: 5px double var(--oro);
  border-radius: 50%;
  color: var(--oro-claro);
  background: #050808;
  box-shadow:
    0 0 0 5px #062c32,
    0 0 0 7px var(--cian);
  font:
    700 28px Georgia,
    serif;
}
.visor {
  width: min(92vw, 1150px);
  height: 88vh;
  padding: 0;
  overflow: visible;
  border: 2px solid #9a671b;
  color: #eee5d8;
  background: #030606;
}
.visor::backdrop {
  background: #000d;
}
.visor header {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 13px 17px;
  border-bottom: 1px solid #805719;
  background: #050807;
}
.visor header strong {
  color: var(--oro-claro);
}
.visor header button {
  border: 1px solid #805719;
  color: var(--cian);
  background: #080b0a;
  font-size: 24px;
}
.visor-contenido {
  height: calc(88vh - 58px);
  overflow: auto;
}
.visor img {
  display: block;
  width: 100%;
  height: auto;
}

/* Galería vertical de 30 misiones para móvil: 2 columnas × 15 filas. */
@media (max-width: 760px) {
  html,
  body {
    width: 100%;
    height: auto;
    min-height: 100%;
    overflow-x: hidden;
    background: #020403;
  }

  html {
    overflow-y: auto;
  }

  body {
    overflow-y: visible;
  }

  .galeria-pagina {
    position: relative;
    top: auto;
    left: auto;
    box-sizing: border-box;
    width: 100%;
    height: auto;
    min-height: 100dvh;
    padding: 0.65rem 0.65rem 5.7rem;
    overflow: visible;
    background-color: #020403;
    background-image: url("../imagenes/6.1.png");
    background-position: center top;
    background-size: auto 100dvh;
    background-attachment: fixed;
    transform: none;
  }

  .galeria-pagina::before {
    position: fixed;
    background: rgba(0, 5, 4, 0.68);
    box-shadow: inset 0 0 4rem #000;
  }

  .cabecera {
    position: relative;
    top: auto;
    right: auto;
    left: auto;
    display: grid;
    grid-template-columns: 3rem minmax(0, 1fr) auto;
    gap: 0.5rem;
    min-height: 3rem;
  }

  .insignia {
    display: grid;
    place-items: center;
    width: 3rem;
    height: 3rem;
    font-size: 1.25rem;
  }

  .marca {
    min-width: 0;
    font-size: 0.68rem;
  }

  .marca strong,
  .marca span {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .marca span {
    margin-top: 0.2rem;
    font-size: 0.5rem;
  }

  .controles {
    display: flex;
    align-items: center;
    margin: 0;
  }

  .controles button {
    min-width: 2rem;
    min-height: 2.25rem;
    padding: 0.3rem;
    font-size: 0.62rem;
  }

  .controles span {
    display: none;
  }

  .titulo {
    position: relative;
    top: auto;
    left: auto;
    width: auto;
    margin: 0.85rem 0 0.65rem;
  }

  .titulo h1 {
    margin: 0;
    font-size: clamp(1.55rem, 8vw, 2.1rem);
    line-height: 1;
    text-shadow: 0 0.15rem 0.65rem #000;
  }

  .titulo p {
    margin: 0.35rem 0 0;
    font-size: 0.64rem;
  }

  .panel-lateral {
    position: relative;
    top: auto;
    left: auto;
    width: auto;
  }

  .filtros {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.32rem;
    padding: 0.5rem;
    border-width: 1px;
    background: rgba(3, 7, 7, 0.86);
  }

  .filtros h2 {
    grid-column: 1 / -1;
    margin: 0 0 0.1rem;
    font-size: 0.68rem;
    text-align: center;
  }

  .filtros button {
    justify-content: center;
    gap: 0.25rem;
    height: 2rem;
    margin: 0;
    padding: 0.25rem;
    font-size: 0.56rem;
    text-align: center;
  }

  .estadisticas {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 0.45rem;
    background: rgba(3, 7, 7, 0.84);
  }

  .estadisticas p {
    flex-direction: column;
    justify-content: center;
    height: 3.2rem;
    padding: 0.25rem;
    border-right: 1px solid #805719;
    border-bottom: 0;
    text-align: center;
  }

  .estadisticas p:last-child {
    border-right: 0;
  }

  .estadisticas b {
    width: auto;
    font-size: 0.9rem;
  }

  .estadisticas span {
    margin-top: 0.18rem;
    font-size: 0.46rem;
    line-height: 1.15;
  }

  .volver {
    justify-content: center;
    gap: 0.45rem;
    margin-top: 0.45rem;
    padding: 0.48rem;
    font-size: 0.62rem;
  }

  .volver small {
    display: none;
  }

  .proyectos {
    position: relative;
    top: auto;
    left: auto;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: clamp(8rem, 38vw, 9.25rem);
    gap: 0.48rem;
    width: auto;
    margin-top: 0.65rem;
  }

  .tarjeta {
    min-width: 0;
    padding: 0.3rem;
    background: rgba(3, 7, 7, 0.88);
  }

  .tarjeta img,
  .sin-imagen {
    height: clamp(4.7rem, 23vw, 5.7rem);
  }

  .numero {
    top: 0.3rem;
    left: 0.3rem;
    width: 1.7rem;
    height: 1.45rem;
    font-size: 0.72rem;
  }

  .tarjeta strong {
    margin-top: 0.32rem;
    font-size: 0.66rem;
  }

  .tarjeta small {
    margin-top: 0.18rem;
    font-size: 0.45rem;
  }

  .galeria-pagina .menu-global {
    position: fixed;
    right: 0.45rem;
    bottom: 0.45rem;
    left: 0.45rem;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    min-height: 3.8rem;
    clip-path: none;
  }

  .galeria-pagina .menu-global__ubicacion,
  .galeria-pagina .menu-global__atributos,
  .galeria-pagina .menu-global__sello {
    display: none;
  }

  .galeria-pagina .menu-global__item {
    gap: 0.2rem;
    padding: 0.35rem 0.2rem;
    text-align: center;
  }

  .galeria-pagina .menu-global__item > b {
    font-size: 1.05rem;
  }

  .galeria-pagina .menu-global__item > span {
    align-items: center;
  }

  .galeria-pagina .menu-global__item strong {
    font-size: 0.62rem;
  }

  .galeria-pagina .menu-global__item small,
  .galeria-pagina .menu-global__item em {
    display: none;
  }

  .visor {
    width: calc(100vw - 1rem);
    height: calc(100dvh - 1rem);
    max-width: none;
  }

  .visor-contenido {
    height: calc(100dvh - 4.6rem);
  }
}
