/* Enarian Studios — shared site chrome + landings */
:root {
  --bg: #0a0c10;
  --bg-elevated: rgba(14, 18, 26, 0.92);
  --text: #e6ebf5;
  --text-muted: #9aa3b8;
  --border: rgba(180, 200, 230, 0.14);
  --accent: #c9a66b;
  --eo: #7b8fd4;
  --oc: #5ec8e8;
  --ir: #d4a056;
  --lotr: #e07a4a;
  --font-display: "Segoe UI", "Trebuchet MS", "Gill Sans", sans-serif;
  --font-body: "Segoe UI", system-ui, sans-serif;
  --max: 72rem;
  --bar-h: 2.75rem;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100%;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: #fff; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* —— Studio bar —— */
.studio-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--bar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 1rem;
  background: rgba(8, 10, 14, 0.88);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(10px);
}

.studio-bar__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.92rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.studio-bar__brand img {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 0.25rem;
}

.studio-bar__actions {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.studio-bar__btn {
  appearance: none;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
  font-size: 0.85rem;
  padding: 0.35rem 0.75rem;
  border-radius: 0.4rem;
  cursor: pointer;
}

.studio-bar__btn:hover,
.studio-bar__btn[aria-expanded="true"] {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.25);
}

.studio-bar__menu-btn { display: none; }

@media (max-width: 820px) {
  .studio-bar__menu-btn { display: inline-flex; }
}

/* Games panel */
.games-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 0.4rem);
  width: min(22rem, calc(100vw - 2rem));
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 0.65rem;
  padding: 0.5rem;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
  display: none;
  z-index: 110;
}

.games-panel.is-open { display: block; }

.games-panel a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.65rem 0.75rem;
  border-radius: 0.45rem;
  font-size: 0.92rem;
}

.games-panel a:hover { background: rgba(255, 255, 255, 0.06); }

.games-panel .status {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.games-panel a[data-game="eo"]:hover { color: var(--eo); }
.games-panel a[data-game="oc"]:hover { color: var(--oc); }
.games-panel a[data-game="ir"]:hover { color: var(--ir); }
.games-panel a[data-game="lotr"]:hover { color: var(--lotr); }

/* Mobile drawer */
.mobile-drawer {
  position: fixed;
  inset: var(--bar-h) 0 0 0;
  background: rgba(6, 8, 12, 0.96);
  z-index: 95;
  padding: 1.25rem;
  overflow-y: auto;
  display: none;
}

.mobile-drawer.is-open { display: block; }

.mobile-drawer h3 {
  margin: 0 0 0.75rem;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.mobile-drawer ul {
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 0;
}

.mobile-drawer a {
  display: block;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 1.05rem;
}

body.drawer-open { overflow: hidden; }

/* —— Layout helpers —— */
.wrap {
  width: min(var(--max), calc(100% - 2.5rem));
  margin-inline: auto;
}

.section {
  padding: 4.5rem 0;
}

.eyebrow {
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 0.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.85rem 1.35rem;
  border-radius: 0.55rem;
  font-weight: 650;
  border: 1px solid transparent;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary {
  background: linear-gradient(180deg, #d4b57a, #b88945);
  color: #1a1208;
}

.btn-primary:hover { color: #1a1208; }

.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}

.btn-steam {
  background: #1b2838;
  border-color: #66c0f4;
  color: #c7d5e0;
}

.btn-steam:hover { color: #fff; border-color: #8ed0f8; }

.badge {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text-muted);
}

.badge-live {
  border-color: rgba(94, 200, 150, 0.45);
  color: #8fdfb4;
}

.badge-dev {
  border-color: rgba(212, 160, 86, 0.45);
  color: #e0b878;
}

/* —— Hub —— */
.hub-hero {
  position: relative;
  min-height: calc(100vh - var(--bar-h));
  display: grid;
  align-items: end;
  overflow: hidden;
}

.hub-hero__bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(8, 10, 14, 0.35) 0%, rgba(8, 10, 14, 0.72) 55%, rgba(8, 10, 14, 0.96) 100%),
    url("../assets/studio/hub-atmosphere.jpg") center / cover no-repeat;
  transform: scale(1.02);
}

.hub-hero__content {
  position: relative;
  z-index: 1;
  padding: 5rem 0 4rem;
}

.hub-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 7vw, 4.6rem);
  line-height: 1.05;
  letter-spacing: 0.02em;
  margin: 0 0 1rem;
  text-shadow: 0 8px 40px rgba(0, 0, 0, 0.55);
}

.hub-hero p {
  max-width: 34rem;
  margin: 0 0 1.75rem;
  color: var(--text-muted);
  font-size: 1.1rem;
}

.hub-hero__cta { display: flex; flex-wrap: wrap; gap: 0.75rem; }

.game-grid {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 720px) {
  .game-grid { grid-template-columns: 1fr 1fr; }
}

.game-tile {
  position: relative;
  display: block;
  min-height: 16rem;
  border-radius: 0.85rem;
  overflow: hidden;
  border: 1px solid var(--border);
  isolation: isolate;
}

.game-tile__media {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.45s ease;
  z-index: -1;
}

.game-tile:hover .game-tile__media { transform: scale(1.04); }

.game-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(6, 8, 12, 0.15), rgba(6, 8, 12, 0.88) 70%);
  z-index: 0;
}

.game-tile__body {
  position: relative;
  z-index: 1;
  height: 100%;
  min-height: 16rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.35rem;
}

.game-tile h2 {
  margin: 0.45rem 0 0.35rem;
  font-size: 1.45rem;
  font-family: var(--font-display);
}

.game-tile p {
  margin: 0;
  color: #c5cddf;
  font-size: 0.95rem;
  max-width: 28rem;
}

.game-tile__meta {
  margin-top: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  font-size: 0.85rem;
  color: var(--accent);
}

.game-tile[data-accent="eo"] { box-shadow: inset 0 0 0 1px rgba(123, 143, 212, 0.12); }
.game-tile[data-accent="oc"] { box-shadow: inset 0 0 0 1px rgba(94, 200, 232, 0.12); }
.game-tile[data-accent="ir"] { box-shadow: inset 0 0 0 1px rgba(212, 160, 86, 0.12); }
.game-tile[data-accent="lotr"] { box-shadow: inset 0 0 0 1px rgba(224, 122, 74, 0.12); }

/* —— Game landings —— */
.landing-hero {
  position: relative;
  min-height: calc(92vh - var(--bar-h));
  display: grid;
  align-items: end;
  overflow: hidden;
}

.landing-hero__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.landing-hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8, 10, 14, 0.25) 0%, rgba(8, 10, 14, 0.78) 58%, var(--bg) 100%);
}

.landing-hero__content {
  position: relative;
  z-index: 1;
  padding: 5rem 0 3.5rem;
}

.landing-logo {
  max-height: 4.5rem;
  width: auto;
  margin-bottom: 1.25rem;
  filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.45));
}

.landing-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5.5vw, 3.6rem);
  margin: 0 0 0.85rem;
  line-height: 1.08;
  max-width: 16ch;
}

.landing-hero .lede {
  max-width: 36rem;
  color: #c8d0e2;
  font-size: 1.08rem;
  margin: 0 0 1.5rem;
}

.landing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.prose-block {
  max-width: 44rem;
}

.prose-block h2 {
  font-family: var(--font-display);
  font-size: 1.7rem;
  margin: 0 0 0.85rem;
}

.prose-block p { color: var(--text-muted); margin: 0 0 1rem; }

.feature-list {
  display: grid;
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 700px) {
  .feature-list { grid-template-columns: 1fr 1fr; }
}

.feature-list li {
  border: 1px solid var(--border);
  border-radius: 0.7rem;
  padding: 1.1rem 1.15rem;
  background: rgba(255, 255, 255, 0.025);
}

.feature-list h3 {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
}

.feature-list p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}

.media-grid {
  display: grid;
  gap: 0.85rem;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .media-grid { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 960px) {
  .media-grid { grid-template-columns: 1fr 1fr 1fr; }
}

.media-grid figure {
  margin: 0;
  border-radius: 0.65rem;
  overflow: hidden;
  border: 1px solid var(--border);
  background: #111;
}

.media-grid img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.media-note {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0 0 1rem;
}

.reqs {
  display: grid;
  gap: 1rem;
}

@media (min-width: 700px) {
  .reqs { grid-template-columns: 1fr 1fr; }
}

.reqs article {
  border: 1px solid var(--border);
  border-radius: 0.7rem;
  padding: 1.15rem;
  background: rgba(255, 255, 255, 0.025);
}

.reqs h3 { margin: 0 0 0.6rem; font-size: 1rem; }
.reqs ul { margin: 0; padding-left: 1.1rem; color: var(--text-muted); font-size: 0.9rem; }

.site-footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 0 3rem;
  margin-top: 2rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.site-footer__row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2rem;
  justify-content: space-between;
  align-items: center;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.site-footer a:hover { color: #fff; }

/* EO pages: offset for studio bar sitting above fixed EO nav */
body.eo-site {
  --eo-bar-offset: var(--bar-h);
}

body.eo-site .studio-bar {
  position: fixed;
  inset: 0 0 auto 0;
}

body.eo-site header.fixed,
body.eo-site > header {
  top: var(--bar-h) !important;
}

body.eo-site #game {
  padding-top: calc(7rem + var(--bar-h)) !important;
}
