:root {
  color-scheme: dark;
  --background: #07191e;
  --surface: #0c2228;
  --text: #f5f1e5;
  --muted: #a7b7b8;
  --accent: #ffd080;
  --line: #294047;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 2rem; }
body { margin: 0; background: var(--background); color: var(--text); font-size: 1rem; line-height: 1.65; }
body::before { content: ""; position: absolute; z-index: -1; inset: 0 0 auto; height: 48rem; background: radial-gradient(ellipse at 85% 10%, #10484c55, transparent 60%); pointer-events: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a, button { touch-action: manipulation; }
button:focus-visible, a:focus-visible { outline: 3px solid var(--accent); outline-offset: 5px; }
img { display: block; max-width: 100%; height: auto; }
::selection { background: #ffd080; color: #07191e; }
.page-shell { width: min(1240px, calc(100% - 96px)); margin-inline: auto; }
.skip-link { position: fixed; z-index: 10; top: 1rem; left: 1rem; transform: translateY(-200%); padding: .75rem 1rem; background: var(--accent); color: var(--background); border-radius: .5rem; }
.skip-link:focus { transform: translateY(0); }

.site-header { min-height: 112px; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: .8rem; flex-shrink: 0; }
.brand img { width: 48px; height: 48px; border-radius: 12px; }
.brand-name { font-size: .95rem; font-weight: 750; letter-spacing: .055em; line-height: 1.35; }
.brand-name span { display: block; font-weight: 500; font-size: .75rem; letter-spacing: .3em; color: var(--muted); }
.header-actions { display: flex; align-items: center; gap: 2rem; }
.nav-link { padding-block: .6rem; font-size: .9375rem; color: var(--muted); transition: color .18s ease; }
.nav-link:hover, .site-footer a:hover { color: var(--accent); }
.language-switch { display: flex; gap: .2rem; padding: .2rem; border: 1px solid var(--line); border-radius: 9px; }
.language-switch button { border: 0; padding: .5rem .7rem; min-height: 40px; min-width: 44px; background: transparent; border-radius: 5px; font-size: .875rem; line-height: 1.4; font-weight: 650; color: var(--muted); cursor: pointer; }
.language-switch button[aria-pressed="true"] { background: #203b42; color: var(--text); }
.language-switch button:hover { color: var(--text); }

.hero { display: grid; grid-template-columns: .95fr 1.05fr; align-items: center; gap: 3.5rem; padding: 6rem 0 5.5rem; }
.hero-copy { min-width: 0; }
.eyebrow { margin: 0 0 1.3rem; color: #73c9c6; font-size: .875rem; font-weight: 600; text-transform: uppercase; letter-spacing: .12em; }
h1 { margin: 0; font-size: clamp(3rem, 4.7vw, 4.8rem); font-weight: 760; line-height: 1.09; letter-spacing: -.055em; }
.warm-text { color: var(--accent); }
.hero-description { color: var(--muted); max-width: 29rem; margin: 1.7rem 0 0; font-size: 1.125rem; line-height: 1.75; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 1.5rem; margin-top: 2rem; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 1.2rem; min-height: 52px; padding: .8rem 1.2rem; border-radius: 9px; font-size: 1rem; font-weight: 650; transition: background .18s ease, transform .18s ease; }
.button-primary { background: var(--accent); color: #17272a; }
.button-primary:hover { background: #ffdeb0; transform: translateY(-2px); }
.arrow { width: 20px; height: 20px; flex: 0 0 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.text-link { display: inline-flex; gap: .9rem; align-items: center; padding-block: .75rem; font-size: .9375rem; }
.text-link:hover span:first-child { text-decoration: underline; text-underline-offset: 5px; }
.hero-art { min-width: 0; position: relative; }
.hero-art::before { content: ""; position: absolute; inset: 5% -3% 15%; z-index: -1; background: #e8973220; filter: blur(45px); }
.hero-art > img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border: 1px solid #56727866; border-radius: 18px; box-shadow: 0 24px 70px #0005; }
.art-caption { display: flex; justify-content: space-between; gap: 1rem; margin: 1rem .25rem 0; color: #829d9f; font-size: .75rem; line-height: 1.5; letter-spacing: .22em; }

.games-section { padding: 1rem 0 4.5rem; }
.section-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 1.5rem; flex-wrap: wrap; margin-bottom: 1.8rem; }
h2 { margin: 0; font-size: clamp(1.65rem, 2.5vw, 2.125rem); line-height: 1.3; letter-spacing: -.035em; font-weight: 680; }
.section-note { color: var(--muted); font-size: .875rem; }
.games-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.4rem; }
.game { overflow: hidden; min-width: 0; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.game-art { height: 220px; display: grid; place-items: center; position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.game-art img { width: 170px; height: 170px; object-fit: contain; position: relative; transition: transform .35s ease; }
.game:hover .game-art img { transform: translateY(-4px); }
.game-number { position: absolute; left: 1.35rem; top: 1rem; font-size: .8125rem; color: #91a5a8; font-variant-numeric: tabular-nums; }
.spellarium-art { background: radial-gradient(ellipse at 65% 50%, #16516670, transparent 65%), radial-gradient(ellipse at 25% 75%, #92522355, transparent 65%), #081b20; }
.spellarium-art img { width: 192px; height: 192px; filter: drop-shadow(0 10px 20px #0005); }
.iron-art { background: radial-gradient(ellipse at 50% 85%, #946a2550, transparent 70%), #101e24; }
.iron-art img, .swipe-art img { border: 1px solid #a0b5b233; border-radius: 22px; box-shadow: 0 12px 28px #0005; }
.swipe-art { background: radial-gradient(ellipse at 50% 75%, #486d6440, transparent 70%), #15222c; }
.game-content { display: flex; flex-direction: column; flex: 1; padding: 1.65rem 1.6rem 1.5rem; }
.game-genre { margin: 0 0 .7rem; font-size: .875rem; font-weight: 500; color: #81c7c3; }
.game-iron .game-genre { color: #debb80; }
.game-swipe .game-genre { color: #b6b2e1; }
h3 { margin: 0; min-height: 4.5rem; font-size: 1.6rem; line-height: 1.3; font-weight: 650; letter-spacing: -.03em; }
.game-subtitle { display: block; margin-top: .22rem; font-size: .9375rem; font-weight: 450; letter-spacing: .015em; color: var(--muted); }
.game-description { margin: .8rem 0 1.7rem; color: var(--muted); font-size: 1rem; line-height: 1.7; }
.game-link { display: flex; align-items: center; justify-content: space-between; gap: .8rem; min-height: 49px; margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--line); font-size: .9375rem; font-weight: 600; }
.game-link:hover { color: var(--accent); }
.game-link .arrow { transition: transform .18s ease; }
.game-link:hover .arrow { transform: translate(2px, -2px); }
.coming-soon { margin: auto 0 0; min-height: 49px; padding-top: 1rem; border-top: 1px solid var(--line); color: #debb80; font-size: .9375rem; }

.site-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem 2rem; padding: 1.75rem 0 2.25rem; border-top: 1px solid var(--line); font-size: .875rem; color: var(--muted); }
.site-footer p { margin: 0; }
.site-footer a { color: var(--text); padding-block: .6rem; }
.footer-message { color: #91a8aa; }

@media (min-width: 801px) and (max-width: 1100px) {
  .page-shell { width: calc(100% - 64px); }
  .hero { gap: 2rem; padding-block: 4.5rem; }
  .hero-actions { gap: .6rem 1rem; }
  .game-content { padding-inline: 1.25rem; }
  .games-grid { gap: 1rem; }
  .game-genre { min-height: 3rem; }
  .game-link, .coming-soon { min-height: 4.5rem; }
}

@media (max-width: 800px) {
  .page-shell { width: calc(100% - 40px); max-width: 620px; }
  .site-header { min-height: 90px; }
  .header-actions { gap: 1rem; }
  .brand { gap: .6rem; }
  .brand img { width: 42px; height: 42px; }
  .brand-name { font-size: .8125rem; }
  .brand-name span { font-size: .75rem; }
  .hero { grid-template-columns: 1fr; padding: 3.5rem 0 3rem; gap: 2.7rem; }
  h1 { font-size: clamp(2.85rem, 8.5vw, 4.25rem); }
  .hero-description { font-size: 1.0625rem; max-width: 31rem; margin-top: 1.35rem; }
  .hero-actions { margin-top: 1.6rem; }
  .hero-art > img { border-radius: 12px; }
  .section-heading { margin-bottom: 1.5rem; gap: .5rem; }
  .games-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .game-art { height: 225px; }
  .game-content { padding: 1.4rem 1.5rem; }
  h3 { min-height: 0; font-size: 1.7rem; }
  .game-description { margin-top: 1rem; }
  .games-section { padding-bottom: 3rem; }
  .footer-message { display: none; }
}

@media (max-width: 420px) {
  .nav-link { display: none; }
  .site-header { gap: .75rem; }
  .hero { padding-top: 2.75rem; }
  .eyebrow { font-size: .875rem; letter-spacing: .07em; }
  .hero-actions { gap: .65rem 1.25rem; }
  .button { padding-inline: 1rem; }
  .art-caption { letter-spacing: .14em; }
  .section-heading { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
  .game:hover .game-art img, .button-primary:hover, .game-link:hover .arrow { transform: none; }
}
