@font-face {
  font-family: "PT Serif";
  src: url("/fonts/PTSerif-Bold.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --ink: #f5e7cd;
  --muted: #c7b69b;
  --gold: #efc988;
  --line: #80623d80;
  --serif: "PT Serif", Georgia, serif;
  background: #141411;
  color: var(--ink);
  font: 16px/1.65 system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
body, h1, h2, h3, p, figure { margin: 0; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid #ffe2a2; outline-offset: 4px; }
.frame { width: min(1120px, calc(100% - 64px)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
h2, h3 { font-family: var(--serif); color: #f3d8a3; line-height: 1.1; }
h2 { font-size: clamp(2.1rem, 4.6vw, 3.7rem); }
h3 { font-size: clamp(1.3rem, 2.2vw, 1.6rem); }

.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: .6rem max(32px, calc((100% - 1120px) / 2));
  border-bottom: 1px solid var(--line);
  background: linear-gradient(#171812ed, #171812f7), url("/art/branding/guild-wood.webp") center / 440px #171812;
}
.mast-brand { display: inline-flex; align-items: center; gap: .7rem; min-height: 44px; text-decoration: none; color: var(--gold); font: 700 1.18rem var(--serif); white-space: nowrap; }
.masthead nav, .language-switch { display: flex; align-items: center; gap: clamp(.55rem, 2.25vw, 1.6rem); }
.masthead nav > a { display: inline-grid; min-height: 44px; align-items: center; color: var(--ink); text-decoration: none; font-size: .88rem; }
:is(.masthead, footer) a:hover { color: #fff0bc; text-decoration: underline; text-underline-offset: .24em; }
.language-switch { gap: 4px; }
.language-switch button { display: flex; align-items: center; gap: 4px; min-height: 44px; padding: 0 .44rem; border: 1px solid transparent; background: #151714d9; border-radius: 3px; font-size: .71rem; }
.language-switch button[aria-pressed="true"], .language-switch button:hover { border-color: #a27a49; }
.flag { width: 16px; height: 11px; }
.flag-ru { background: linear-gradient(#fff 33%,#1f52a6 33% 66%,#b9363b 66%); }
.flag-en { background: linear-gradient(90deg, transparent 40%,#fff 40% 60%,transparent 60%), linear-gradient(transparent 35%,#fff 35% 65%,transparent 65%), linear-gradient(31deg, transparent 43%,#fff 43% 55%,transparent 55%), linear-gradient(-31deg, transparent 43%,#fff 43% 55%,transparent 55%),#29406e; position: relative; }
.flag-en::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg,transparent 44%,#bb293a 44% 56%,transparent 56%),linear-gradient(transparent 42%,#bb293a 42% 58%,transparent 58%); }

.landing-hero { position: relative; isolation: isolate; overflow: hidden; min-height: min(650px, 76vw); display: grid; align-items: center; background: #172927; border-bottom: 1px solid var(--line); }
.hero-landscape { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 55% 54%; z-index: -2; }
.landing-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, #111814f2 1%, #111a17d6 23%, #101b1780 45%, transparent 70%), linear-gradient(0deg,#161411 0%,transparent 28%); }
.hero-inner { padding-block: 3.1rem 4.25rem; }
.hero-copy { width: min(480px, 100%); }
.landing-logo { width: min(400px, 85%); margin-left: -.4rem; filter: drop-shadow(0 8px 12px #120d06cc); }
.hero-line { color: #ffdf9b; font: 700 clamp(1.75rem, 4.2vw, 3rem)/1.08 var(--serif); max-width: 13em; text-wrap: balance; margin-top: .55rem; }
.hero-description { margin-top: 1rem; max-width: 38ch; color: #f0e4cb; font-size: clamp(.98rem, 1.45vw, 1.1rem); }
.play-link { display: inline-flex; align-items: center; justify-content: center; gap: 1.1rem; min-height: 53px; min-width: 155px; padding: .58rem 1.3rem; border: 1px solid #ffdea0; border-radius: 4px; background: linear-gradient(#ffdf9f,#d8a552); box-shadow: inset 0 0 0 2px #6e49277d, 0 5px 14px #100a0888; color: #29190f; font: 700 1.12rem var(--serif); text-decoration: none; }
.play-link:hover { background: linear-gradient(#ffe9b5,#f1c479); }
.hero-copy .play-link { margin-top: 1.35rem; }
.browser-note { margin-top: .47rem; color: #ece0c8; font-size: .77rem; }

.world { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(2rem, 6vw, 5.3rem); align-items: center; padding-block: clamp(48px, 9vw, 100px); }
.guild-picture { border: 1px solid #947148; padding: 6px; border-radius: 5px; background: #2a2117; box-shadow: 0 16px 34px #08080778; }
.guild-picture img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 2px; }
.kicker { color: #cbab75; font-size: .77rem; text-transform: uppercase; letter-spacing: .12em; font-weight: 700; margin-bottom: .55rem; }
.world-copy > p:not(.kicker) { margin-top: 1rem; color: var(--muted); max-width: 51ch; }
.text-link { display: inline-flex; align-items: center; gap: .55rem; min-height: 44px; color: var(--gold); margin-top: .35rem; text-underline-offset: .24em; font-weight: 650; }
.how { padding-block: clamp(2.6rem, 5vw, 4.25rem); background: linear-gradient(#222219db,#171915f5),url("/art/branding/guild-wood.webp") center / 520px; border-block: 1px solid var(--line); }
.how h2 { font-size: clamp(1.85rem, 3.6vw, 2.9rem); }
.chapters { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 2rem; margin-top: 1.65rem; }
.chapters article { border-top: 1px solid #a67b48; padding-block: 1rem .15rem; }
.chapters svg { height: 26px; width: 26px; fill: none; stroke: #d8ad72; stroke-width: 1.35; margin-bottom: .35rem; }
.chapters p, .departure p { margin-top: .55rem; color: var(--muted); }
.departure { background: radial-gradient(ellipse at 12% 28%,#324037,#202b24 65%,#1c231d); border-bottom: 1px solid var(--line); }
.departure-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; padding-block: clamp(2.1rem, 5vw, 3.7rem); }
.departure h2 { font-size: clamp(1.85rem, 3.6vw, 2.9rem); }
.departure .play-link { flex: none; }
footer { background: #10120f; padding-block: 1.5rem; color: var(--muted); font-size: .83rem; }
.footer-inner { display: flex; justify-content: space-between; align-items: start; gap: 1.5rem; }
footer strong { color: var(--gold); font: 700 1.28rem var(--serif); }
footer nav { display: flex; flex-wrap: wrap; gap: .9rem; }
footer nav a { display: inline-grid; align-items: center; min-height: 44px; text-underline-offset: .24em; color: var(--gold); }

@media (max-width: 740px) {
  .frame { width: calc(100% - 36px); }
  .masthead { padding-inline: 18px; }
  .masthead .nav-how { display: none; }
  .landing-hero { min-height: 540px; align-items: end; }
  .hero-landscape { object-position: 68% center; }
  .landing-hero::after { background: linear-gradient(0deg,#121612 4%,#111b18ec 33%,#151d1878 62%,#13211d20 100%); }
  .hero-inner { padding-block: 11rem 2.2rem; }
  .landing-logo { width: min(285px, 82%); }
  .world { grid-template-columns: 1fr; gap: 1.45rem; }
  .world-copy { order: -1; }
  .chapters { grid-template-columns: 1fr; gap: 1rem; }
  .departure-inner, .footer-inner { align-items: start; flex-direction: column; }
}

@media (max-width: 430px) {
  .masthead .nav-world { display: none; }
}
