:root {
  --negro: #050505;
  --negro-2: #0a0a0a;
  --superficie: #111111;
  --dorado: #bf931c;
  --dorado-claro: #d4a520;
  --dorado-medio: #6f5410;
  --crema: #e3e3e3;
  --blanco: #f5f0e8;
  --linea: rgba(191, 147, 28, 0.3);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --font-body: 'Outfit', system-ui, sans-serif;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  background: var(--negro);
  color: var(--blanco);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}

[hidden] { display: none !important; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
ul { list-style: none; margin: 0; padding: 0; }

:focus-visible {
  outline: 2px solid var(--dorado-claro);
  outline-offset: 3px;
}

/* Fondo: nitido arriba, desenfocado y oscuro hacia abajo */
.bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: var(--negro);
}

.bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 38% 50%;
}

.bg__sharp {
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 22%, transparent 58%);
  mask-image: linear-gradient(to bottom, #000 0%, #000 22%, transparent 58%);
  animation: settle 1800ms var(--ease) both;
}

.bg__blur {
  -webkit-mask-image: linear-gradient(to bottom, transparent 18%, #000 52%);
  mask-image: linear-gradient(to bottom, transparent 18%, #000 52%);
}

.bg__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(5, 5, 5, 0.1) 0%,
    rgba(5, 5, 5, 0.42) 26%,
    rgba(5, 5, 5, 0.86) 58%,
    var(--negro) 84%
  );
}

@keyframes settle {
  from { transform: scale(1.08); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

/* Idioma */
.lang {
  position: absolute;
  top: max(14px, env(safe-area-inset-top));
  right: max(14px, env(safe-area-inset-right));
  z-index: 10;
  display: flex;
  background: rgba(5, 5, 5, 0.72);
  border: 1px solid var(--linea);
  border-radius: 9px;
  padding: 3px;
}

.lang__btn {
  min-width: 42px;
  min-height: 34px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--crema);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  transition: background-color 220ms var(--ease), color 220ms var(--ease);
}

.lang__btn[aria-pressed='true'] {
  background: var(--dorado);
  color: var(--negro-2);
}

.lang__btn:not([aria-pressed='true']):hover { color: var(--dorado-claro); }

/* Pagina */
.page {
  position: relative;
  z-index: 1;
  width: min(100%, 460px);
  margin: 0 auto;
  padding: clamp(72px, 12svh, 120px) 20px max(28px, env(safe-area-inset-bottom));
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}

.brand {
  text-align: center;
  margin-bottom: clamp(32px, 6svh, 52px);
}

.brand__logo { margin: 0; }

.brand__logo img {
  width: min(76vw, 300px);
  height: auto;
  margin: 0 auto;
  filter: drop-shadow(0 4px 24px rgba(0, 0, 0, 0.55));
}

.brand__line {
  margin: 16px auto 0;
  max-width: 26ch;
  font-size: 0.98rem;
  font-weight: 300;
  line-height: 1.45;
  color: var(--crema);
  text-shadow: 0 1px 14px rgba(0, 0, 0, 0.8);
}

/* Enlaces */
.links {
  display: grid;
  gap: 12px;
}

.link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  min-height: 68px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 10px;
  text-align: left;
  transition:
    transform 260ms var(--ease),
    background-color 260ms var(--ease),
    border-color 260ms var(--ease),
    color 260ms var(--ease);
}

.link:hover { transform: translateY(-2px); }
.link:active { transform: scale(0.985); }

.link__icon {
  flex: none;
  width: 30px;
  height: 30px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.link__icon .dot { fill: currentColor; stroke: none; }
.link__icon--fill { fill: currentColor; stroke: none; }

.link__text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.link__title {
  font-weight: 500;
  font-size: 1.1rem;
  line-height: 1.25;
}

.link__sub {
  font-size: 0.82rem;
  font-weight: 300;
  line-height: 1.35;
  opacity: 0.82;
}

.link__arrow {
  flex: none;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.6;
  transition: transform 260ms var(--ease), opacity 260ms var(--ease);
}

.link:hover .link__arrow { transform: translateX(3px); opacity: 1; }

.link--hero {
  min-height: 92px;
  background: var(--dorado);
  color: var(--negro-2);
}

.link--hero .link__title { font-size: 1.5rem; font-weight: 600; }
.link--hero .link__sub { opacity: 0.78; font-weight: 400; }
.link--hero .link__icon { width: 38px; height: 38px; stroke-width: 1.8; }
.link--hero:hover { background: var(--dorado-claro); }

.link--dark {
  background: var(--superficie);
  border-color: var(--linea);
  color: var(--blanco);
}

.link--dark .link__icon { color: var(--dorado-claro); }
.link--dark:hover { border-color: var(--dorado); background: #161616; }

.link--gold {
  background: var(--dorado-medio);
  color: var(--blanco);
}

.link--gold .link__sub { opacity: 0.88; }
.link--gold:hover { background: #82630f; }

/* Pie */
.foot {
  margin-top: auto;
  padding-top: clamp(36px, 6svh, 56px);
  text-align: center;
}

.social {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.social a {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--linea);
  border-radius: 10px;
  background: var(--superficie);
  color: var(--crema);
  transition:
    transform 260ms var(--ease),
    background-color 260ms var(--ease),
    color 260ms var(--ease),
    border-color 260ms var(--ease);
}

.social svg { width: 20px; height: 20px; fill: currentColor; }

.social a:hover {
  transform: translateY(-2px);
  background: var(--dorado);
  border-color: var(--dorado);
  color: var(--negro-2);
}

.foot__copy {
  margin: 22px 0 0;
  font-size: 0.74rem;
  font-weight: 300;
  color: rgba(227, 227, 227, 0.6);
}

.greca {
  height: 10px;
  margin: 20px -20px 0;
  opacity: 0.55;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='10' viewBox='0 0 24 10' shape-rendering='crispEdges'%3E%3Cpath d='M0 9.5H3V6.5H6V3.5H9V.5H12V3.5H15V6.5H18V9.5H21' fill='none' stroke='%23bf931c' stroke-width='1'/%3E%3C/svg%3E");
  background-repeat: repeat-x;
  background-position: center;
}

/* Wi-Fi */
.wifi {
  width: min(92vw, 420px);
  padding: 0;
  border: 1px solid var(--linea);
  border-radius: 14px;
  background: #0c0c0c;
  color: var(--blanco);
}

.wifi::backdrop { background: rgba(0, 0, 0, 0.82); }

.wifi[open] { animation: dialog-in 320ms var(--ease) both; }

@keyframes dialog-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.wifi__panel {
  display: grid;
  gap: 10px;
  padding: 10px;
}

.wifi__img {
  width: 100%;
  height: auto;
  max-height: calc(100svh - 120px);
  object-fit: contain;
  border-radius: 8px;
}

.wifi__close {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--linea);
  border-radius: 10px;
  background: var(--superficie);
  font-weight: 500;
  transition: border-color 220ms var(--ease), background-color 220ms var(--ease);
}

.wifi__close:hover { border-color: var(--dorado); background: #161616; }

/* Entrada */
@media (prefers-reduced-motion: no-preference) {
  .brand, .link, .foot {
    animation: rise 800ms var(--ease) both;
    animation-delay: calc(120ms + var(--i, 0) * 70ms);
  }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .bg__sharp, .wifi[open] { animation: none; }
  .link, .social a, .link__arrow { transition: none; }
}

@media (min-width: 700px) {
  .bg img { object-position: 40% 45%; }
}
