/* yaongisgreat.com — shared styles */

:root {
  --bg: #0f1a15;
  --bg-raised: #15241d;
  --bg-sunken: #0b130f;
  --line: #24382e;
  --text: #e3eee6;
  --text-dim: #9fb5a7;
  --moss: #8fd16a;
  --moss-deep: #4f8f3a;
  --water: #7fd1d9;
  --accent-ink: #0d1a10;
  --radius: 10px;
  --max: 1080px;
  --font-body: "Noto Sans KR", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-pixel: "Silkscreen", "Noto Sans KR", monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--water); text-underline-offset: 3px; }
a:hover { color: #b5eef2; }

/* ---------- language switching ---------- */
html.lang-en .ko, html.lang-ko .en { display: none !important; }

/* ---------- layout ---------- */
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
section { padding: 72px 0; }
section + section { border-top: 1px solid var(--line); }

h1, h2, h3 { line-height: 1.25; margin: 0 0 .6em; text-wrap: balance; }
h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
.lead { font-size: 1.1rem; color: var(--text-dim); max-width: 46em; }
.eyebrow {
  font-family: var(--font-pixel);
  font-size: .8rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--moss);
  margin: 0 0 .8em;
}

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(15, 26, 21, .88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; gap: 16px;
  min-height: 60px;
}
.brand {
  font-family: var(--font-pixel);
  font-size: 1.05rem;
  color: var(--text);
  text-decoration: none;
  display: flex; align-items: center; gap: 10px;
  margin-right: auto;
}
.brand img { width: 28px; height: 28px; image-rendering: pixelated; border-radius: 4px; }
.brand:hover { color: var(--moss); }
.nav { display: flex; gap: 18px; align-items: center; }
.nav a { color: var(--text-dim); text-decoration: none; font-size: .95rem; }
.nav a:hover { color: var(--text); }
.lang-toggle {
  font: inherit; font-size: .85rem;
  color: var(--text);
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 12px;
  cursor: pointer;
}
.lang-toggle:hover { border-color: var(--moss-deep); }
@media (max-width: 560px) {
  .nav .nav-link { display: none; }
}

/* ---------- hero ---------- */
.hero {
  position: relative;
  padding: 120px 0 96px;
  background:
    linear-gradient(90deg, rgba(15,26,21,.96) 0%, rgba(15,26,21,.75) 45%, rgba(15,26,21,.15) 100%),
    url("games/mossy-box/hero.png") center right / cover no-repeat;
  image-rendering: pixelated;
  border-bottom: 1px solid var(--line);
}
.hero h1 {
  font-family: var(--font-pixel);
  font-weight: 700;
  font-size: clamp(2rem, 6vw, 3.6rem);
  color: var(--moss);
  letter-spacing: .02em;
  margin-bottom: .3em;
}
.hero .lead { color: var(--text); opacity: .9; max-width: 32em; }
@media (max-width: 720px) {
  .hero { padding: 80px 0 64px; }
}
@media (max-width: 1000px) {
  .hero { background:
    linear-gradient(180deg, rgba(15,26,21,.88), rgba(15,26,21,.94)),
    url("games/mossy-box/hero.png") 72% center / cover no-repeat; }
}

/* ---------- buttons ---------- */
.btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 20px;
  border-radius: var(--radius);
  font-weight: 700;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform .12s ease, background .12s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--moss); color: var(--accent-ink); }
.btn-primary:hover { background: #a6e283; color: var(--accent-ink); }
.btn-ghost { border-color: var(--line); color: var(--text); background: var(--bg-raised); }
.btn-ghost:hover { border-color: var(--moss-deep); color: var(--text); }

/* ---------- game cards ---------- */
.games { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr)); gap: 24px; margin-top: 32px; }
.game-card {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex; flex-direction: column;
  text-decoration: none; color: inherit;
  transition: border-color .15s ease, transform .15s ease;
}
.game-card:hover { border-color: var(--moss-deep); transform: translateY(-2px); color: inherit; }
.game-card img { aspect-ratio: 920 / 430; width: 100%; object-fit: cover; image-rendering: pixelated; }
.game-card .body { padding: 20px 22px 24px; }
.game-card h3 { margin-bottom: .3em; }
.game-card p { color: var(--text-dim); margin: 0; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.tag {
  font-size: .78rem;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--bg-sunken);
  border: 1px solid var(--line);
  color: var(--text-dim);
}
.tag.status { color: var(--moss); border-color: var(--moss-deep); }

.game-card.placeholder {
  border-style: dashed;
  align-items: center; justify-content: center;
  min-height: 220px;
  color: var(--text-dim);
  text-align: center;
  padding: 24px;
}
.game-card.placeholder:hover { transform: none; border-color: var(--line); }
.game-card.placeholder .pixel { font-family: var(--font-pixel); color: var(--moss-deep); font-size: 1.4rem; margin-bottom: 6px; }

/* ---------- about / contact ---------- */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
@media (max-width: 760px) { .two-col { grid-template-columns: 1fr; gap: 24px; } }
.contact-box {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.contact-box dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 10px 16px; }
.contact-box dt { color: var(--text-dim); font-size: .9rem; }
.contact-box dd { margin: 0; }

/* ---------- game page ---------- */
.game-hero {
  padding: 64px 0 56px;
  background:
    linear-gradient(90deg, rgba(15,26,21,.95) 0%, rgba(15,26,21,.7) 50%, rgba(15,26,21,.1) 100%),
    url("games/mossy-box/hero.png") center right / cover no-repeat;
  image-rendering: pixelated;
  border-bottom: 1px solid var(--line);
}
@media (max-width: 1000px) {
  .game-hero { background:
    linear-gradient(180deg, rgba(15,26,21,.86), rgba(15,26,21,.94)),
    url("games/mossy-box/hero.png") 72% center / cover no-repeat; }
}
.game-hero .logo { width: min(520px, 100%); image-rendering: pixelated; margin-bottom: 18px; }
.game-hero .lead { color: var(--text); max-width: 32em; }

.trailer {
  aspect-ratio: 16 / 9; width: 100%;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--bg-sunken);
}

.shots { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 28px; }
@media (max-width: 640px) { .shots { grid-template-columns: 1fr; } }
.shots a { display: block; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.shots img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; image-rendering: pixelated; transition: transform .25s ease; }
.shots a:hover img { transform: scale(1.03); }

.features { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 20px; margin-top: 28px; }
.feature {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}
.feature h3 { color: var(--moss); }
.feature p, .feature li { color: var(--text-dim); }
.feature ul { margin: 0; padding-left: 1.1em; }
.feature li + li { margin-top: .3em; }

.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); gap: 12px; margin-top: 24px; }
.fact { background: var(--bg-sunken); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.fact .n { font-family: var(--font-pixel); color: var(--water); font-size: 1.6rem; line-height: 1.1; }
.fact .l { color: var(--text-dim); font-size: .88rem; }

/* ---------- prose (privacy) ---------- */
.prose { max-width: 46em; }
.prose h2 { margin-top: 1.8em; font-size: 1.3rem; }
.prose ul { padding-left: 1.2em; }
.prose code { background: var(--bg-raised); padding: 1px 6px; border-radius: 4px; font-size: .92em; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 32px 0 48px; color: var(--text-dim); font-size: .9rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; }
.site-footer .spacer { margin-right: auto; }
.site-footer a { color: var(--text-dim); }
.site-footer a:hover { color: var(--text); }

/* ---------- lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(5, 10, 8, .92);
  display: none; align-items: center; justify-content: center;
  padding: 16px; cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox img { max-height: 100%; max-width: 100%; image-rendering: pixelated; border-radius: 6px; }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}

:focus-visible { outline: 2px solid var(--water); outline-offset: 3px; border-radius: 4px; }
