/* Shared styles for hyperiums.com gateway pages — deploy home.html + assets/ at site root */

:root {
  --bg-deep: #020408;
  --bg-panel: #0a0e1a;
  --accent: #999983;
  --accent-hover: #b0b099;
  --text: #e8eaef;
  --text-muted: #8b92a8;
  --legacy-url: url("assets/legacy-preview.png");
  --reborn-url: url("assets/reborn-preview.png");
  --legacy-href: index.html;
  --reborn-href: https://reborn.hyperiums.com/index.html;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg-deep);
  color: var(--text);
}

.brand-gradient {
  background: linear-gradient(135deg, #c4c4a8 0%, #999983 45%, #6b6b58 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-title {
  font-family: "Cinzel", Georgia, serif;
  font-weight: 700;
  letter-spacing: 0.02em;
}

/* Starfield background */
.starfield {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
  background:
    radial-gradient(ellipse 90% 60% at 50% -10%, rgba(40, 55, 90, 0.35), transparent 55%),
    radial-gradient(ellipse 70% 50% at 80% 90%, rgba(153, 153, 131, 0.06), transparent),
    var(--bg-deep);
}

.starfield__layer {
  position: absolute;
  inset: 0;
  background-repeat: repeat;
}

.starfield__layer--dense {
  background-image:
    radial-gradient(1px 1px at 5% 12%, rgba(255, 255, 255, 0.55), transparent),
    radial-gradient(1px 1px at 18% 78%, rgba(255, 255, 255, 0.35), transparent),
    radial-gradient(1px 1px at 32% 34%, rgba(255, 255, 255, 0.45), transparent),
    radial-gradient(1px 1px at 47% 8%, rgba(255, 255, 255, 0.4), transparent),
    radial-gradient(1px 1px at 61% 56%, rgba(255, 255, 255, 0.3), transparent),
    radial-gradient(1px 1px at 74% 22%, rgba(255, 255, 255, 0.5), transparent),
    radial-gradient(1px 1px at 88% 67%, rgba(255, 255, 255, 0.38), transparent),
    radial-gradient(1px 1px at 12% 44%, rgba(255, 255, 255, 0.28), transparent),
    radial-gradient(1px 1px at 55% 88%, rgba(255, 255, 255, 0.42), transparent),
    radial-gradient(1px 1px at 93% 41%, rgba(255, 255, 255, 0.32), transparent);
  background-size: 280px 220px;
  opacity: 0.9;
}

.starfield__layer--bright {
  background-image:
    radial-gradient(1.5px 1.5px at 8% 25%, rgba(255, 255, 255, 0.85), transparent),
    radial-gradient(1.5px 1.5px at 42% 62%, rgba(255, 255, 255, 0.7), transparent),
    radial-gradient(2px 2px at 68% 15%, rgba(200, 210, 255, 0.75), transparent),
    radial-gradient(1.5px 1.5px at 22% 91%, rgba(255, 255, 255, 0.65), transparent),
    radial-gradient(2px 2px at 85% 52%, rgba(255, 248, 220, 0.6), transparent),
    radial-gradient(1px 1px at 36% 18%, rgba(255, 255, 255, 0.5), transparent);
  background-size: 420px 360px;
  animation: starfield-drift 120s linear infinite;
}

.starfield__layer--twinkle {
  background-image:
    radial-gradient(2px 2px at 15% 35%, rgba(255, 255, 255, 0.9), transparent),
    radial-gradient(1.5px 1.5px at 58% 72%, rgba(255, 255, 255, 0.85), transparent),
    radial-gradient(2px 2px at 78% 28%, rgba(255, 255, 255, 0.8), transparent),
    radial-gradient(1.5px 1.5px at 28% 58%, rgba(255, 255, 255, 0.75), transparent);
  background-size: 500px 400px;
  animation: starfield-twinkle 5s ease-in-out infinite alternate;
}

@keyframes starfield-drift {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-40px, -24px, 0);
  }
}

@keyframes starfield-twinkle {
  from {
    opacity: 0.35;
  }
  to {
    opacity: 1;
  }
}

/* Main page title */
.gateway-main-title {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin: 0;
  font-family: "Cinzel", Georgia, serif;
  font-size: clamp(2.25rem, 6vw, 3.25rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0.04em;
  text-align: center;
}

.gateway-main-title__glow,
.gateway-main-title__text {
  display: block;
}

.gateway-main-title__glow {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  color: transparent;
  -webkit-text-stroke: 0.04em rgba(153, 153, 131, 0.55);
  text-shadow:
    0 0 24px rgba(153, 153, 131, 0.45),
    0 0 48px rgba(153, 153, 131, 0.2);
  filter: blur(0.5px);
  user-select: none;
}

.gateway-main-title__text {
  position: relative;
  background: linear-gradient(
    110deg,
    #e8e4d0 0%,
    #999983 22%,
    #c4c4a8 45%,
    #7a7a66 58%,
    #b0b099 72%,
    #999983 100%
  );
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: title-shimmer 8s ease-in-out infinite;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.6));
}

@keyframes title-shimmer {
  0%,
  100% {
    background-position: 0% center;
  }
  50% {
    background-position: 100% center;
  }
}

.choice-title__suffix {
  font-size: 0.7em;
  font-weight: 500;
  letter-spacing: 0.02em;
  opacity: 0.92;
  vertical-align: baseline;
}

.gateway-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.gateway-header {
  text-align: center;
  padding: 2rem 1.25rem 1rem;
}

.gateway-header > p {
  margin: 0.75rem auto 0;
  max-width: 32rem;
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--text-muted);
  text-align: center;
}

.gateway-choices {
  flex: 1;
  display: grid;
  gap: 1px;
  background: rgba(255, 255, 255, 0.06);
}

@media (min-width: 900px) {
  .gateway-choices {
    grid-template-columns: 1fr 1fr;
  }
}

.choice-link {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: min(52vh, 420px);
  padding: 1.75rem;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  background: var(--bg-panel);
  outline: none;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

@media (min-width: 900px) {
  .choice-link {
    min-height: 0;
  }
}

.choice-link::before {
  content: "";
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.6s ease, filter 0.4s ease;
  filter: saturate(0.95) brightness(0.86);
}

.choice-link--legacy::before {
  background-image: var(--legacy-url);
}

.choice-link--reborn::before {
  background-image: var(--reborn-url);
}

.choice-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(2, 4, 8, 0.05) 0%,
    rgba(2, 4, 8, 0.2) 45%,
    rgba(2, 4, 8, 0.88) 100%
  );
  transition: opacity 0.35s ease;
}

.choice-link:hover::before,
.choice-link:focus-visible::before {
  transform: scale(1.03);
  filter: saturate(1) brightness(0.92);
}

.choice-link:hover::after,
.choice-link:focus-visible::after {
  opacity: 0.95;
}

.choice-link:focus-visible {
  box-shadow: inset 0 0 0 3px var(--accent);
  z-index: 2;
}

.choice-body {
  position: relative;
  z-index: 1;
  margin: 0 -1.75rem -1.75rem;
  padding: 1.5rem 1.75rem 1.75rem;
  background: linear-gradient(
    to top,
    rgba(2, 4, 8, 0.92) 0%,
    rgba(2, 4, 8, 0.55) 55%,
    transparent 100%
  );
}

.choice-badge {
  display: inline-block;
  margin-bottom: 0.5rem;
  padding: 0.2rem 0.55rem;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border: 1px solid rgba(153, 153, 131, 0.45);
  border-radius: 4px;
  color: var(--accent-hover);
  background: rgba(0, 0, 0, 0.5);
}

.choice-body h2 {
  margin: 0;
  font-family: "Cinzel", Georgia, serif;
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 600;
  color: #fff;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.85);
}

.choice-body p {
  margin: 0.65rem 0 1.1rem;
  max-width: 28rem;
  font-size: 0.9rem;
  line-height: 1.45;
  color: rgba(232, 234, 239, 0.92);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.8);
}

.choice-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-hover);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.9);
}

.choice-cta svg {
  width: 1rem;
  height: 1rem;
  transition: transform 0.25s ease;
}

.choice-link:hover .choice-cta svg,
.choice-link:focus-visible .choice-cta svg {
  transform: translateX(4px);
}

.gateway-footer {
  padding: 1.25rem;
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-muted);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.gateway-footer a {
  color: var(--accent);
  text-decoration: none;
}

.gateway-footer a:hover {
  color: var(--accent-hover);
}
