/* Realm Offline — marketing only. Not a SaaS template. */

:root {
  --ink: #13241c;
  --ink-soft: #3d5248;
  --mist: #e7eeea;
  --foam: #f4f7f5;
  --leaf: #2f6b52;
  --leaf-deep: #1a4334;
  --sand: #c4b29a;
  --line: rgba(19, 36, 28, 0.12);
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Sora", "Avenir Next", sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font: 400 1.05rem/1.55 var(--font-body);
  background: var(--foam);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

.skip {
  position: absolute;
  left: -999px;
  top: 0;
}

.skip:focus {
  left: 1rem;
  top: 1rem;
  z-index: 40;
  background: #fff;
  padding: 0.5rem 0.75rem;
}

/* —— Top —— */
.site-top {
  position: fixed;
  inset: 0 0 auto;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem clamp(1rem, 4vw, 2.5rem);
  pointer-events: auto;
}

.site-top .mark,
.site-top nav a {
  pointer-events: auto;
  position: relative;
  z-index: 2;
  cursor: pointer;
}

a.mark {
  text-decoration: none;
  color: inherit;
}

.site-top .mark {
  margin: 0;
  font: 700 1.15rem/1 var(--font-display);
  letter-spacing: -0.02em;
  color: #f4f7f5;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.35);
  mix-blend-mode: normal;
}

body.scrolled .site-top .mark {
  color: var(--ink);
  text-shadow: none;
}

.site-top nav {
  display: flex;
  gap: 1.25rem;
}

.site-top nav a {
  text-decoration: none;
  font: 500 0.88rem/1 var(--font-body);
  color: rgba(244, 247, 245, 0.92);
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.3);
}

body.scrolled .site-top nav a {
  color: var(--ink-soft);
  text-shadow: none;
}

/* —— Hero: one composition —— */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  align-items: end;
  overflow: hidden;
  color: #f4f7f5;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 55% 40%;
  transform: scale(1.08);
  animation: drift 28s var(--ease) infinite alternate;
  will-change: transform;
}

@keyframes drift {
  from {
    transform: scale(1.08) translate3d(0, 0, 0);
  }
  to {
    transform: scale(1.14) translate3d(-1.5%, -1%, 0);
  }
}

.hero-veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(10, 22, 16, 0.35) 0%, rgba(10, 22, 16, 0.15) 38%, rgba(10, 22, 16, 0.72) 100%),
    radial-gradient(ellipse 70% 50% at 20% 80%, rgba(47, 107, 82, 0.35), transparent 60%);
}

.hero-copy {
  position: relative;
  z-index: 1;
  width: min(40rem, calc(100% - clamp(16rem, 24vw, 21rem)));
  padding: clamp(5.5rem, 14vh, 8rem) clamp(1.1rem, 5vw, 3rem) clamp(2.4rem, 6vh, 3.5rem);
}

.hero-rail {
  position: absolute;
  z-index: 2;
  top: 4.35rem;
  right: 0;
  bottom: 0.7rem;
  width: clamp(16rem, 24vw, 21rem);
  display: grid;
  grid-template-rows: repeat(6, minmax(0, 1fr));
  gap: 0.42rem;
}

.rail-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 0;
  padding: 0;
  text-decoration: none;
  color: #f6f3ec;
  background: #10241c;
  border: 0;
  border-radius: 0.85rem 0 0 0.85rem;
  overflow: hidden;
  transition: transform 0.35s var(--ease);
}

.rail-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rail-card .rail-copy {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 100%;
  padding: 0.55rem 0.8rem 0.6rem;
  background: linear-gradient(to top, rgba(8, 14, 12, 0.92) 0%, rgba(8, 14, 12, 0.15) 62%, transparent 100%);
}

.rail-card:hover {
  transform: translateX(-4px);
}

.rail-kicker {
  margin-bottom: auto;
  font: 600 0.62rem/1 var(--font-body);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #c4b29a;
}

.rail-card strong {
  display: block;
  margin-top: 0.28rem;
  font: 500 clamp(1.02rem, 1.4vw, 1.28rem)/1.05 var(--font-display);
  letter-spacing: -0.02em;
}

.rail-card em {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  margin-top: 0.18rem;
  overflow: hidden;
  font-style: normal;
  font: 400 0.72rem/1.3 var(--font-body);
  color: rgba(246, 243, 236, 0.82);
}

.rail-card.games,
.rail-card.games:hover {
  background: #10241c;
  color: #f6f3ec;
}

.rail-card.games .rail-kicker { color: #d7c4a4; }
.rail-card.games em { color: rgba(246, 243, 236, 0.82); }

.hero-copy .brand {
  margin: 0 0 0.85rem;
  font: 700 clamp(3.6rem, 12vw, 7.5rem) / 0.9 var(--font-display);
  letter-spacing: -0.04em;
  opacity: 0;
  transform: translateY(1.2rem);
  animation: rise 1.1s var(--ease) 0.15s forwards;
}

.hero-copy h1 {
  margin: 0 0 0.85rem;
  font: 500 clamp(1.55rem, 3.6vw, 2.35rem) / 1.15 var(--font-display);
  letter-spacing: -0.02em;
  max-width: 14ch;
  opacity: 0;
  transform: translateY(1rem);
  animation: rise 1s var(--ease) 0.35s forwards;
}

.hero-copy .lede {
  margin: 0 0 1.5rem;
  max-width: 34ch;
  font: 400 1.02rem / 1.55 var(--font-body);
  color: rgba(244, 247, 245, 0.88);
  opacity: 0;
  transform: translateY(0.8rem);
  animation: rise 1s var(--ease) 0.55s forwards;
}

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

.cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 0.85rem;
  opacity: 0;
  animation: rise 1s var(--ease) 0.75s forwards;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.25rem;
  text-decoration: none;
  font: 600 0.92rem / 1 var(--font-body);
  border: 1px solid transparent;
  transition: transform 0.35s var(--ease), background 0.35s var(--ease), color 0.35s var(--ease);
}

.btn:hover {
  transform: translateY(-2px);
}

.btn.solid {
  background: var(--foam);
  color: var(--leaf-deep);
}

.btn.quiet {
  background: transparent;
  color: #f4f7f5;
  border-color: rgba(244, 247, 245, 0.4);
}

.btn.quiet:hover {
  background: rgba(244, 247, 245, 0.1);
}

/* —— Sections —— */
.band {
  padding: clamp(4rem, 10vw, 7rem) clamp(1.1rem, 5vw, 3rem);
}

.band-inner {
  width: min(68rem, 100%);
  margin: 0 auto;
}

.kicker {
  margin: 0 0 0.65rem;
  font: 600 0.78rem / 1 var(--font-body);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--leaf);
}

.band h2 {
  margin: 0 0 0.9rem;
  font: 500 clamp(2rem, 4.5vw, 3.25rem) / 1.1 var(--font-display);
  letter-spacing: -0.03em;
  max-width: 16ch;
}

.support {
  margin: 0 0 2rem;
  max-width: 38rem;
  color: var(--ink-soft);
  font-size: 1.05rem;
}

.how {
  background:
    radial-gradient(ellipse 50% 40% at 100% 0%, rgba(47, 107, 82, 0.12), transparent 55%),
    linear-gradient(180deg, var(--foam), var(--mist));
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.1rem;
  max-width: 36rem;
}

.steps li {
  display: grid;
  grid-template-columns: 2.6rem 1fr;
  gap: 0.85rem;
  align-items: baseline;
  font-size: 1.05rem;
  color: var(--ink);
}

.steps span {
  font: 600 0.85rem / 1 var(--font-body);
  letter-spacing: 0.08em;
  color: var(--leaf);
}

/* App names as a flowing river — not a card dashboard */
.apps {
  background: var(--leaf-deep);
  color: #e8f0eb;
  overflow: hidden;
}

.apps .kicker {
  color: #9dceb6;
}

.apps .support {
  color: rgba(232, 240, 235, 0.78);
}

.app-river {
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 1.4rem;
}

.app-river li {
  font: 500 clamp(1.35rem, 3.2vw, 2rem) / 1.2 var(--font-display);
  letter-spacing: -0.02em;
  opacity: 0.55;
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease);
}

.app-river li:nth-child(odd) {
  opacity: 0.92;
}

.app-river li:hover {
  opacity: 1;
  transform: translateY(-3px);
  color: #fff;
}

.promise {
  background:
    linear-gradient(135deg, rgba(196, 178, 154, 0.28), transparent 45%),
    var(--foam);
}

.promise-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: end;
}

.promise-copy {
  margin: 0;
  font: 400 1.15rem / 1.6 var(--font-body);
  color: var(--ink-soft);
  max-width: 32rem;
}

.download {
  background:
    radial-gradient(ellipse 60% 50% at 0% 100%, rgba(47, 107, 82, 0.14), transparent 55%),
    var(--mist);
}

.dl-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
  margin: 1.5rem 0 1rem;
}

.dl {
  display: block;
  padding: 1.15rem 1.1rem 1.2rem;
  text-decoration: none;
  border-bottom: 2px solid var(--leaf);
  background: rgba(255, 255, 255, 0.45);
  transition: background 0.35s var(--ease), transform 0.35s var(--ease);
}

.dl:hover {
  background: #fff;
  transform: translateY(-3px);
}

.dl strong {
  display: block;
  font: 600 1.05rem / 1.2 var(--font-display);
  margin-bottom: 0.35rem;
}

.dl span {
  font-size: 0.86rem;
  color: var(--ink-soft);
}

.fine {
  margin: 0;
  font-size: 0.86rem;
  color: var(--ink-soft);
  max-width: 40rem;
}

.site-foot {
  padding: 2.5rem clamp(1.1rem, 5vw, 3rem) 3rem;
  border-top: 1px solid var(--line);
  background: var(--foam);
}

.site-foot .mark {
  margin: 0 0 0.4rem;
  font: 700 1.35rem / 1 var(--font-display);
}

.site-foot p:last-child {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(1.25rem);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}

.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  .hero {
    min-height: auto;
    display: block;
    overflow: visible;
  }

  .hero-copy {
    width: min(40rem, 100%);
  }

  .hero-rail {
    position: relative;
    top: auto;
    right: auto;
    bottom: auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: none;
    width: auto;
    gap: 0.55rem;
    padding: 0 0.75rem 1rem;
  }

  .rail-card {
    min-height: 12rem;
    border-radius: 1rem;
  }
}

@media (max-width: 860px) {
  .promise-grid {
    grid-template-columns: 1fr;
  }

  .dl-row {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 520px) {
  .site-top nav {
    gap: 0.85rem;
  }

  .dl-row {
    grid-template-columns: 1fr;
  }

  .hero-copy .brand {
    font-size: clamp(3.2rem, 18vw, 4.5rem);
  }
}

/* —— Inner pages —— */
body.subpage {
  background: var(--foam);
}

body.subpage .site-top {
  background: rgba(244, 247, 245, 0.94);
  border-bottom: 1px solid var(--line);
}

body.subpage .site-top .mark,
body.subpage .site-top nav a {
  color: var(--ink);
  text-shadow: none;
}

.page-lead {
  padding-top: clamp(6.5rem, 12vw, 8rem);
}

.page-lead h1 {
  margin: 0 0 0.85rem;
  font: 500 clamp(2.4rem, 5vw, 3.6rem) / 1.05 var(--font-display);
  letter-spacing: -0.03em;
  max-width: 16ch;
}

.phone-grid,
.realm-grid {
  display: grid;
  gap: 0.85rem;
}

.phone-grid {
  grid-template-columns: 1fr 1fr;
}

.phone-card,
.realm-card {
  background: #fff;
  border: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
}

.phone-card {
  padding: 1.15rem 1.15rem 1.2rem;
}

.phone-card .who {
  margin: 0 0 0.35rem;
  font: 600 0.72rem / 1 var(--font-body);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--leaf);
}

.phone-card h2 {
  margin: 0 0 0.45rem;
  max-width: none;
  font-size: clamp(1.45rem, 2vw, 1.8rem);
}

.phone-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.steps.guide {
  max-width: none;
  grid-template-columns: 1fr;
}

.realm-note {
  margin: 0 0 1.25rem;
  max-width: 40rem;
  padding: 0.9rem 1rem;
  background: rgba(255, 255, 255, 0.08);
  border-left: 3px solid #9dceb6;
  color: #e8f0eb;
}

body.subpage .btn.solid {
  background: var(--leaf-deep);
  color: #f4f7f5;
}

.realm-grid {
  grid-template-columns: repeat(3, 1fr);
}

.realm-card {
  display: block;
  overflow: hidden;
}

.thumb {
  display: block;
  aspect-ratio: 16 / 10;
  background: #143028;
}

.thumb svg {
  width: 100%;
  height: 100%;
  display: block;
}

.realm-card figcaption {
  padding: 0.75rem 0.85rem 0.9rem;
}

.realm-card strong {
  display: block;
  font: 600 1.05rem / 1.2 var(--font-display);
}

.realm-card span {
  display: block;
  margin-top: 0.2rem;
  color: var(--ink-soft);
  font-size: 0.86rem;
}

.status {
  display: inline-block;
  margin-top: 0.85rem;
  padding: 0.28rem 0.55rem;
  font: 600 0.72rem / 1 var(--font-body);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--leaf-deep);
  background: rgba(47, 107, 82, 0.12);
}

@media (max-width: 860px) {
  .phone-grid,
  .realm-grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-media img,
  .hero-copy .brand,
  .hero-copy h1,
  .hero-copy .lede,
  .cta,
  .reveal {
    animation: none !important;
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}

.shot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15.5rem, 1fr));
  gap: 0.85rem;
  margin: 1.4rem 0 0;
  padding: 0;
  list-style: none;
}
.shot-card {
  position: relative;
  display: flex;
  min-height: 15.5rem;
  overflow: hidden;
  border-radius: 1.05rem;
  color: #f6f3ec;
  text-decoration: none;
  background: #10241c;
}
.shot-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s var(--ease);
}
.shot-card:hover img { transform: scale(1.04); }
.shot-card span {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  width: 100%;
  margin-top: auto;
  padding: 2.4rem 0.9rem 0.85rem;
  background: linear-gradient(to top, rgba(8, 14, 12, 0.92), rgba(8, 14, 12, 0.05));
}
.shot-card strong { font: 560 1.35rem/1.1 var(--font-display); }
.shot-card em { margin-top: 0.2rem; font-style: normal; font-size: 0.86rem; color: rgba(246, 243, 236, 0.84); }
.showcase-hero { width: min(72rem, calc(100% - 2rem)); margin: 5.6rem auto 0; }
.showcase-hero img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 1.2rem; }
.game-grid .shot-card { min-height: 18rem; }

.use-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr));
  gap: 0.9rem;
  margin: 1.6rem 0 0;
  padding: 0;
  list-style: none;
}

.use-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 1.1rem;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
}

.use-card img {
  width: 100%;
  height: 10.5rem;
  object-fit: cover;
}

.use-card div { padding: 0.95rem 1rem 1.1rem; }

.use-card h2 {
  margin: 0 0 0.4rem;
  font: 560 1.35rem/1.15 var(--font-display);
}

.use-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.98rem;
}
