/* Relicora Games — corporate studio site. Palette from the purple faceted-lion logo:
   ground #220125 (logo background), lilac #e4b9ee (wordmark), amber accent from the mane highlight. */
:root {
  --ground: #220125;
  --ground-2: #2c0833;
  --panel: #331039;
  --line: #5b2a68;
  --lilac: #e4b9ee;
  --lilac-2: #c690d2;
  --amber: #f2a45a;
  --text: #f7eefa;
  --text-2: #d3bedb;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Hiragino Mincho ProN", "Yu Mincho", "Noto Serif CJK JP", "Noto Serif KR", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, system-ui, "Hiragino Sans", "Noto Sans JP", "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 120px; }
body { margin: 0; background: var(--ground); color: var(--text); font: 17px/1.65 var(--sans); overflow-wrap: anywhere; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--lilac); text-underline-offset: 3px; }
a:focus-visible, summary:focus-visible, button:focus-visible, .btn:focus-visible, h2:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; border-radius: 6px; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--text-2); }
.skip { position: absolute; left: 8px; top: -60px; z-index: 60; background: var(--lilac); color: var(--ground); padding: 10px 14px; border-radius: 8px; font-weight: 700; }
.skip:focus { top: 8px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 700; letter-spacing: -0.01em; }

/* Header: mark + real wordmark, language, primary navigation (second row on phones). */
header.top { position: sticky; top: 0; z-index: 30; background: rgba(34, 1, 37, 0.94); border-bottom: 1px solid var(--line); backdrop-filter: blur(6px); }
.top-inner { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "brand lang" "nav nav"; align-items: center; gap: 4px 12px; padding-top: 8px; padding-bottom: 4px; }
.brand { grid-area: brand; display: flex; align-items: center; gap: 10px; text-decoration: none; min-height: 44px; }
.brand-mark { width: 40px; height: 40px; border-radius: 10px; }
.brand-wordmark img { width: auto; height: 34px; }
nav.lang { grid-area: lang; position: relative; }
nav.primary { grid-area: nav; }
nav.primary ul { list-style: none; display: flex; gap: 2px; margin: 0; padding: 0; }
nav.primary a { display: inline-block; padding: 10px 12px; min-height: 44px; color: var(--text); text-decoration: none; border-radius: 8px; font-weight: 600; white-space: nowrap; }
nav.primary a:hover { background: var(--ground-2); }
nav.primary a[aria-current="page"] { color: var(--lilac); box-shadow: inset 0 -2px 0 var(--lilac); border-radius: 0; }
@media (min-width: 860px) {
  .top-inner { grid-template-columns: auto 1fr auto; grid-template-areas: "brand nav lang"; min-height: 72px; padding: 0 20px; }
  nav.primary ul { justify-content: flex-end; margin-right: 12px; }
  .brand-wordmark img { height: 40px; }
}

/* Language menu (works without JS) */
nav.lang summary { list-style: none; cursor: pointer; color: var(--text); border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-size: 14px; min-height: 44px; display: flex; align-items: center; gap: 6px; }
nav.lang summary::-webkit-details-marker { display: none; }
nav.lang summary::after { content: "▾"; color: var(--lilac); }
nav.lang .lang-label { color: var(--text-2); }
.lang-code { display: none; }
nav.lang ul { position: absolute; right: 0; top: calc(100% + 6px); z-index: 40; list-style: none; margin: 0; padding: 6px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; min-width: 210px; max-height: 70vh; overflow-y: auto; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45); }
nav.lang li a { display: block; padding: 10px 12px; border-radius: 8px; color: var(--text); text-decoration: none; min-height: 44px; }
nav.lang li a:hover, nav.lang li a:focus-visible { background: var(--ground-2); }
nav.lang li a[aria-current="true"] { color: var(--ground); background: var(--lilac); }
@media (max-width: 480px) {
  .lang-name, nav.lang .lang-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .lang-code { display: inline; font-weight: 700; }
  nav.lang summary { padding: 6px 10px; }
  .brand-wordmark img { height: 30px; }
  nav.primary a { padding: 10px 10px; }
}

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 12px 20px; border-radius: 12px; font-weight: 700; text-decoration: none; font-size: 16px; border: 0; cursor: pointer; font-family: var(--sans); }
.btn.primary { background: var(--lilac); color: var(--ground); }
.btn.primary:hover { background: #f0d2f6; }
.linklike { background: none; border: 0; color: var(--lilac); text-decoration: underline; font: inherit; cursor: pointer; padding: 6px 0; min-height: 44px; }

/* Studio hero: the lion relief is the brand image (decorative); copy sits on solid ground. */
.studio-hero { position: relative; overflow-x: clip; border-bottom: 1px solid var(--line); }
.studio-art { display: block; overflow: hidden; }
.studio-art img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 50%; }
.studio-copy { padding-top: 28px; padding-bottom: 40px; }
.kicker { color: var(--amber); font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; font-size: 13px; margin: 0 0 10px; }
.studio-copy h1 { font-size: clamp(32px, 7vw, 60px); line-height: 1.08; margin: 0 0 16px; max-width: 18ch; }
.intro { font-size: clamp(17px, 2.2vw, 21px); color: var(--text-2); max-width: 46ch; margin: 0; }
@media (min-width: 900px) {
  .studio-hero { display: grid; min-height: min(70vh, 640px); align-items: center; }
  /* Two columns: copy on solid ground (left), relief on the right with the lion centred in its column. */
  .studio-art { position: absolute; top: 0; bottom: 0; right: 0; left: 42%; }
  .studio-art img { height: 100%; aspect-ratio: auto; object-position: 50% 50%; }
  .studio-hero::before { content: ""; position: absolute; top: 0; bottom: 0; left: 42%; width: 18%; z-index: 1; background: linear-gradient(90deg, var(--ground) 0%, rgba(34, 1, 37, 0) 100%); }
  .studio-copy h1 { max-width: 15ch; }
  .intro { max-width: 40ch; }
  .studio-copy { position: relative; z-index: 2; width: 100%; padding-top: 72px; padding-bottom: 72px; }
}

/* Sections */
.section { padding-top: 56px; padding-bottom: 56px; }
.section h2 { font-size: clamp(28px, 4.4vw, 40px); line-height: 1.15; margin: 0 0 12px; }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 20px; }
.facts { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 0; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); border-top: 1px solid var(--line); }
.facts li { padding: 20px 20px 20px 0; border-bottom: 1px solid var(--line); }
.facts h3 { font-size: 21px; margin: 0 0 6px; }
.facts p { margin: 0; color: var(--text-2); }

/* Editorial game entry */
.game-entry { display: grid; gap: 20px; margin-top: 24px; background: var(--panel); border: 1px solid var(--line); border-radius: 20px; overflow: hidden; }
.game-cover img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.game-entry-body { padding: 0 20px 24px; }
.game-entry-body h2, .game-entry-body h3 { font-size: clamp(28px, 4vw, 40px); margin: 0 0 6px; }
.game-tagline { font-size: 19px; color: var(--text); margin: 0 0 10px; }
.eyebrow { color: var(--amber); font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; font-size: 13px; margin: 0 0 6px; }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--text-2); font-size: 15px; }
.badge { display: inline-block; background: var(--ground); border: 1px solid var(--amber); color: var(--amber); border-radius: 999px; padding: 2px 10px; font-weight: 700; font-size: 13px; }
@media (min-width: 900px) {
  .game-entry { grid-template-columns: 1.1fr 1fr; align-items: center; gap: 0; }
  .game-cover img { height: 100%; aspect-ratio: auto; min-height: 380px; }
  .game-entry-body { padding: 32px 36px; }
}

/* Contact */
.contact { border-top: 1px solid var(--line); }
.contact-list { display: grid; gap: 16px; margin: 16px 0 28px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.contact-list dt { color: var(--text-2); font-size: 14px; text-transform: uppercase; letter-spacing: 0.05em; }
.contact-list dd { margin: 4px 0 0; font-size: 19px; }
.contact h3 { font-size: 20px; margin: 0 0 8px; }
.social { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 0; padding: 0; }
.social a { display: inline-block; padding: 8px 0; min-height: 44px; font-weight: 600; }

/* Game page */
.game-banner { display: block; overflow: hidden; border-bottom: 1px solid var(--line); }
.game-banner img { width: 100%; aspect-ratio: 16 / 7; object-fit: cover; object-position: 70% 45%; }
.game-page { padding-top: 32px; }
.game-hero { display: grid; gap: 24px; align-items: center; }
.game-hero h1 { font-size: clamp(36px, 6vw, 60px); margin: 0 0 8px; line-height: 1.05; }
.lead { font-size: 20px; color: var(--text-2); margin: 0 0 12px; }
.game-hero-shot { margin: 0 auto; max-width: 300px; }
.game-hero-shot img, .shot img { border-radius: 18px; border: 1px solid var(--line); }
.game-hero-shot figcaption, .shot figcaption { color: var(--text-2); font-size: 14px; margin-top: 6px; }
@media (min-width: 900px) { .game-hero { grid-template-columns: 1fr 320px; } }
.game-page .section { padding-left: 0; padding-right: 0; }
.features { padding-left: 20px; }
.features li { margin: 8px 0; }
.shots { display: grid; gap: 16px; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 16px; }
.shot { margin: 0; }
.shot.wide { grid-column: 1 / -1; }
@media (min-width: 900px) { .shots { grid-template-columns: 300px 1fr; } .shot.wide { grid-column: auto; } }

/* Legal documents */
main.doc { padding-top: 32px; padding-bottom: 40px; max-width: 820px; }
main.doc h1 { color: var(--lilac); font-size: clamp(30px, 5vw, 40px); line-height: 1.2; }
main.doc h2 { font-size: 22px; margin-top: 32px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px 20px; margin: 16px 0; }

/* Consent (rendered only when analytics is configured) */
.consent { position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; background: var(--panel); border-top: 2px solid var(--lilac); box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.5); }
.consent[hidden] { display: none; }
.consent-inner { padding-top: 16px; padding-bottom: 16px; }
.consent h2 { font-size: 22px; margin: 0 0 6px; }
.consent p { margin: 0 0 10px; }
.consent-actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* Footer */
footer { border-top: 1px solid var(--line); padding: 28px 0 44px; color: var(--text-2); font-size: 15px; background: var(--ground-2); }
footer ul { list-style: none; padding: 0; margin: 0 0 12px; display: flex; flex-wrap: wrap; gap: 4px 20px; }
footer a { display: inline-block; padding: 8px 0; }
.footer-company { color: var(--text); }

@media (prefers-reduced-motion: no-preference) {
  .studio-copy { animation: rise 500ms ease-out both; }
  @keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
}
