/* Go Viking website. Colours match the game's menus (FSurvivalMenuStyle). */
:root {
  --bg: #0b0c0e;
  --bg-raised: #121418;
  --text: #ede8de;
  --text-dim: rgba(237, 232, 222, 0.62);
  --text-faint: rgba(237, 232, 222, 0.4);
  --accent: #d99e54;
  --accent-deep: #b97c36;
  --line: rgba(255, 255, 255, 0.09);
  --display: "Cinzel", Georgia, serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --gutter: clamp(16px, 5vw, 64px);
  --max: 1200px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 600; }
p { margin: 0; }

.wrap { width: min(var(--max), 100% - 2 * var(--gutter)); margin-inline: auto; position: relative; }

.kicker {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--accent);
}
.stroke { display: block; width: 44px; height: 2px; background: var(--accent); }
.lede { color: var(--text-dim); font-size: clamp(16px, 1.4vw, 19px); max-width: 38em; }

/* ---- buttons */
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 26px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, transform 0.2s;
}
.button:focus-visible, .nav a:focus-visible, .news-card:focus-visible, .reader-close:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.button-primary { background: var(--accent); color: #17120b; }
.button-primary:hover { background: #e7b06a; transform: translateY(-1px); }
.button-ghost { border: 1px solid rgba(237, 232, 222, 0.35); color: var(--text); background: rgba(0, 0, 0, 0.2); backdrop-filter: blur(6px); }
.button-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* ---- nav */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px var(--gutter);
  transition: background-color 0.3s, padding 0.3s, border-color 0.3s;
  border-bottom: 1px solid transparent;
}
.nav.solid { background: rgba(11, 12, 14, 0.88); backdrop-filter: blur(12px); padding-block: 12px; border-bottom-color: var(--line); }
.nav-brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; }
.nav-brand span { font-family: var(--display); font-size: 15px; letter-spacing: 0.24em; text-transform: uppercase; }
.nav-links { display: flex; gap: clamp(16px, 3vw, 36px); }
.nav-links a { font-size: 12px; font-weight: 600; letter-spacing: 0.24em; text-transform: uppercase; text-decoration: none; color: var(--text-dim); transition: color 0.2s; }
.nav-links a:hover { color: var(--text); }

/* ---- hero */
.hero { position: relative; min-height: 100svh; display: flex; align-items: center; overflow: hidden; isolation: isolate; }
.hero-art, .band-art { position: absolute; inset: 0; z-index: -2; }
.hero-art img, .band-art img { width: 100%; height: 100%; object-fit: cover; }
.hero-art img { object-position: 62% 50%; animation: drift 40s ease-in-out infinite alternate; transform-origin: 70% 50%; }
@keyframes drift { from { transform: scale(1.02); } to { transform: scale(1.1) translateX(-1.5%); } }
.hero-shade {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(8, 9, 11, 0.92) 0%, rgba(8, 9, 11, 0.7) 32%, rgba(8, 9, 11, 0.12) 64%, rgba(8, 9, 11, 0) 100%),
    linear-gradient(0deg, var(--bg) 0%, rgba(11, 12, 14, 0) 26%);
}
.hero-content { width: min(var(--max), 100% - 2 * var(--gutter)); margin-inline: auto; padding-block: 120px 96px; display: grid; gap: 22px; max-width: var(--max); }
.hero-content > * { max-width: 560px; }
.hero-logo { width: min(440px, 78vw); height: auto; margin-bottom: 6px; filter: drop-shadow(0 6px 24px rgba(0, 0, 0, 0.45)); }
.hero h1 { font-family: var(--display); font-size: clamp(28px, 3.6vw, 46px); line-height: 1.18; letter-spacing: 0.02em; }
.hero .actions { margin-top: 8px; }
.scroll-cue { position: absolute; left: 50%; bottom: 28px; width: 26px; height: 42px; margin-left: -13px; border: 1px solid rgba(237, 232, 222, 0.4); border-radius: 14px; }
.scroll-cue span { position: absolute; left: 50%; top: 9px; width: 2px; height: 8px; margin-left: -1px; background: var(--accent); border-radius: 1px; animation: cue 2.2s ease-in-out infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 80% { opacity: 0; transform: translateY(12px); } 100% { opacity: 0; } }

/* ---- pillars */
.pillars, .closing { position: relative; isolation: isolate; overflow: hidden; }
.pillars { padding-block: clamp(96px, 12vw, 160px); }
.band-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, var(--bg) 0%, rgba(11, 12, 14, 0.86) 22%, rgba(11, 12, 14, 0.86) 78%, var(--bg) 100%); }
.band-shade-strong {
  background:
    radial-gradient(ellipse 60% 48% at 50% 52%, rgba(8, 9, 11, 0.78) 0%, rgba(8, 9, 11, 0.35) 70%, rgba(8, 9, 11, 0) 100%),
    linear-gradient(180deg, var(--bg) 0%, rgba(11, 12, 14, 0.5) 30%, rgba(11, 12, 14, 0.5) 60%, var(--bg) 100%);
}
.closing h2, .closing .lede { text-shadow: 0 2px 18px rgba(0, 0, 0, 0.7); }
.pillars h2, .news h2, .closing h2 { font-family: var(--display); font-size: clamp(28px, 3.4vw, 44px); line-height: 1.2; margin-top: 14px; }
.grid { margin-top: clamp(40px, 6vw, 72px); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.pillar { background: rgba(13, 15, 18, 0.82); backdrop-filter: blur(6px); padding: 34px 30px 36px; transition: background-color 0.25s; }
.pillar:hover { background: rgba(22, 24, 29, 0.9); }
.pillar .rune { display: block; font-size: 28px; line-height: 1; color: var(--accent); margin-bottom: 20px; }
.pillar h3 { font-size: 17px; letter-spacing: 0.04em; margin-bottom: 10px; }
.pillar p { color: var(--text-dim); font-size: 15.5px; }

/* ---- news */
.news { padding-block: clamp(80px, 10vw, 140px); background: var(--bg); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: clamp(32px, 4vw, 52px); }
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 24px; }
.news-grid .news-card:first-child { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); }
.news-card {
  display: flex; flex-direction: column;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: 3px;
  overflow: hidden;
  text-decoration: none;
  cursor: pointer;
  text-align: left;
  color: inherit;
  font: inherit;
  padding: 0;
  transition: border-color 0.25s, transform 0.25s;
}
.news-card:hover { border-color: rgba(217, 158, 84, 0.55); transform: translateY(-3px); }
.news-card:hover h3 { color: var(--accent); }
.news-thumb { aspect-ratio: 16 / 9; background: #1a1d22; overflow: hidden; }
.news-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s; }
.news-card:hover .news-thumb img { transform: scale(1.04); }
.news-text { padding: 22px 24px 26px; display: grid; gap: 10px; align-content: start; }
.news-card:first-child .news-thumb { aspect-ratio: auto; min-height: 320px; }
.news-card:first-child .news-text { padding: clamp(24px, 3vw, 44px); align-content: center; }
.news-card:first-child h3 { font-size: clamp(22px, 2.2vw, 30px); }
.news-meta { font-size: 11px; font-weight: 600; letter-spacing: 0.26em; text-transform: uppercase; color: var(--text-faint); }
.news-meta .new { color: var(--accent); margin-left: 10px; }
.news-card h3 { font-size: 19px; line-height: 1.35; transition: color 0.2s; }
.news-card p { color: var(--text-dim); font-size: 15px; }
.news-empty { color: var(--text-faint); }

/* ---- closing */
.closing { padding-block: clamp(120px, 16vw, 220px); text-align: center; }
.closing-content { display: grid; justify-items: center; gap: 18px; }
.closing-content .lede { margin-inline: auto; }
.closing-symbol { width: 72px; height: 72px; opacity: 0.9; margin-bottom: 6px; }
.closing .button { margin-top: 10px; }

/* ---- studio credit */
.presents { font-size: 12px; font-weight: 500; letter-spacing: 0.34em; text-transform: uppercase; color: var(--text-dim); margin-bottom: -6px; }
.studio { padding-block: clamp(72px, 9vw, 120px); border-top: 1px solid var(--line); background: radial-gradient(ellipse 50% 80% at 30% 50%, #15171b 0%, var(--bg) 70%); }
.studio-row { display: flex; align-items: center; justify-content: center; gap: clamp(32px, 6vw, 80px); }
.studio-logo { width: clamp(120px, 14vw, 170px); height: auto; opacity: 0.92; }
.studio-text { display: grid; gap: 12px; max-width: 30em; }
.studio-text h2 { font-family: var(--display); font-size: clamp(24px, 2.6vw, 34px); }
.studio-text p:last-child { color: var(--text-dim); }

/* ---- footer */
.footer { border-top: 1px solid var(--line); padding-block: 28px; }
.footer-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.footer p { color: var(--text-faint); font-size: 13px; }

/* ---- article reader */
.reader {
  width: min(900px, 100% - 32px);
  max-height: min(88svh, 1000px);
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #0f1114;
  color: var(--text);
  overflow: hidden;
}
.reader::backdrop { background: rgba(5, 6, 8, 0.78); backdrop-filter: blur(10px); }
.reader[open] { display: flex; flex-direction: column; animation: rise 0.28s ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.reader-scroll { overflow-y: auto; }
.reader-cover { aspect-ratio: 12 / 5; background: #1a1d22 center / cover no-repeat; }
.reader-cover:empty:not([style]) { display: none; }
.reader-body { padding: clamp(24px, 5vw, 56px); display: grid; gap: 14px; }
.reader-body h2 { font-family: var(--display); font-size: clamp(26px, 3vw, 38px); line-height: 1.2; }
.reader-body .stroke { margin-block: 8px 14px; }
#reader-content { display: grid; gap: 16px; color: rgba(237, 232, 222, 0.82); }
#reader-content h3 { font-size: 22px; color: var(--text); margin-top: 14px; }
#reader-content h4 { margin: 8px 0 0; font-size: 16px; color: var(--accent); }
#reader-content strong { color: var(--text); }
#reader-content ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
#reader-content li { position: relative; padding-left: 22px; }
#reader-content li::before { content: ""; position: absolute; left: 2px; top: 0.68em; width: 6px; height: 6px; background: var(--accent); }
#reader-content hr { border: 0; height: 1px; background: var(--line); margin: 8px 0; width: 100%; }
#reader-content figure { margin: 6px 0; display: grid; gap: 8px; }
#reader-content figure img { width: 100%; border-radius: 2px; }
#reader-content figcaption { font-size: 13px; color: var(--text-faint); }
.reader-link { justify-self: start; margin-top: 12px; }
.reader-close {
  position: absolute; top: 14px; right: 14px; z-index: 2;
  width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.55); color: var(--text);
  font-size: 15px; cursor: pointer;
}
.reader-close:hover { border-color: var(--accent); color: var(--accent); }

/* ---- reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---- small screens */
@media (max-width: 760px) {
  body { font-size: 16px; }
  .nav-links { gap: 18px; }
  .nav-links a[href="#alpha"] { display: none; }
  .nav-brand span { display: none; }
  .hero { align-items: flex-end; }
  .hero-art img { object-position: 72% 50%; }
  .hero-shade { background: linear-gradient(0deg, var(--bg) 0%, rgba(8, 9, 11, 0.86) 45%, rgba(8, 9, 11, 0.25) 100%); }
  .hero-content { padding-block: 120px 88px; }
  .scroll-cue { display: none; }
  .news-grid .news-card:first-child { display: flex; }
  .news-card:first-child .news-thumb { aspect-ratio: 16 / 9; min-height: 0; }
  .button { flex: 1 1 auto; }
  .studio-row { flex-direction: column; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-art img, .scroll-cue span { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .news-card, .news-thumb img, .button { transition: none; }
}
