/* Garden Legends site. Look and feel of the game: grass-green backdrop, glossy flat pill buttons, cream and navy panels,
   Rubik Black headings with a brown outline (the game's own fonts, self-hosted, SIL OFL). No external requests, no scripts, no cookies. */
@font-face { font-family: "GL Rubik"; src: url("/fonts/rubik-black.woff") format("woff"); font-weight: 900; font-display: swap; }
@font-face { font-family: "GL JA"; src: url("/fonts/mplus-rounded-ja.woff") format("woff"); font-weight: 900; font-display: swap; unicode-range: U+2E80-9FFF, U+F900-FAFF, U+FF00-FFEF, U+3000-30FF; }
@font-face { font-family: "GL KO"; src: url("/fonts/jua-ko.woff") format("woff"); font-weight: 900; font-display: swap; unicode-range: U+1100-11FF, U+3130-318F, U+AC00-D7AF, U+3000-303F, U+FF00-FFEF; }
@font-face { font-family: "GL ZH"; src: url("/fonts/zcool-kuaile-zh.woff") format("woff"); font-weight: 900; font-display: swap; unicode-range: U+2E80-9FFF, U+F900-FAFF, U+FF00-FFEF, U+3000-303F; }

:root {
  --grass: #44983b;
  --grass-dark: #2a7a2a;
  --cream: #fff8e4;
  --cream-line: #ead9ae;
  --navy: #1e2352;
  --navy-2: #2a3170;
  --ink: #2c2016;          /* body text on cream */
  --muted: #5e5043;
  --brown: #3b2412;        /* outline of headings */
  --gold: #f1cb00;
  --blue: #3e94ee;
  --green: #17b35c;
  --purple: #a77be8;
  --pink: #ee6a9c;
  --orange: #f08a1c;
  --radius: 22px;
  --pill: 999px;
  --lift: 0 6px 0 rgba(0, 0, 0, .22);
  --body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --disp: "GL Rubik", "Arial Black", "Segoe UI Black", system-ui, sans-serif;
  color-scheme: light;
}
:lang(ja) { --body: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Yu Gothic", Meiryo, "Noto Sans JP", sans-serif; --disp: "GL Rubik", "GL JA", "Hiragino Maru Gothic ProN", "Hiragino Sans", sans-serif; }
:lang(ko) { --body: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif; --disp: "GL Rubik", "GL KO", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif; }
:lang(zh) { --body: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei UI", "Microsoft YaHei", "Noto Sans SC", sans-serif; --disp: "GL Rubik", "GL ZH", "PingFang SC", "Microsoft YaHei", sans-serif; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; background: var(--grass); }
body {
  margin: 0; color: var(--ink); font: 17px/1.65 var(--body); overflow-wrap: break-word; min-height: 100vh;
  background-color: var(--grass);
  background-image:
    linear-gradient(rgba(18, 74, 22, .30), rgba(18, 74, 22, .30)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, .05) 0 110px, rgba(0, 0, 0, .035) 110px 220px),
    url("/img/grass-tile.webp");
  background-size: auto, auto, 520px 520px;
}
body:lang(ja), body:lang(zh) { line-height: 1.85; }
body:lang(ko) { word-break: keep-all; line-height: 1.8; }
a { color: #1566b8; text-underline-offset: 3px; }
img { max-width: 100%; height: auto; display: block; }
.wrap { max-width: 1000px; margin: 0 auto; padding: 0 20px; }
.wrap.legal { max-width: 820px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 8px; }

/* Display type: white, brown outline, like the game's UI text */
.disp, h1, h2, .tagline, .brand span, .store, .soon, .pill, .button {
  font-family: var(--disp); font-weight: 900; letter-spacing: .01em;
}
h1, h2, .tagline {
  color: #fff; -webkit-text-stroke: .11em var(--brown); paint-order: stroke fill;
  text-shadow: 0 .07em 0 var(--brown), 0 .12em .14em rgba(0, 0, 0, .35);
}
h1, h2 { text-wrap: balance; }
:lang(ja) h1, :lang(ja) h2, :lang(ja) .tagline, :lang(ja) .sub { word-break: auto-phrase; }
h2 { font-size: clamp(1.7rem, 5vw, 2.4rem); line-height: 1.15; margin: 56px 0 18px; text-align: center; text-transform: none; }
h3 { margin: 0 0 6px; font-size: 1.15rem; font-weight: 800; line-height: 1.3; }

/* Top bar: sticky, inline menu on desktop, burger on phones */
.topbar { background: var(--navy); border-bottom: 5px solid var(--gold); position: sticky; top: 0; z-index: 50; box-shadow: 0 4px 14px rgba(0, 0, 0, .25); }
.topbar .wrap { display: flex; align-items: center; gap: 14px; min-height: 68px; max-width: 1140px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-size: 1.25rem; white-space: nowrap; }
.brand img { width: 44px; height: 44px; border-radius: 12px; border: 2px solid #fff; }
.mainnav { display: none; margin-left: 18px; gap: 4px; }
.nl { font-family: var(--disp); font-weight: 900; font-size: .95rem; color: #dfe4ff; text-decoration: none; padding: 9px 14px; border-radius: var(--pill); }
.nl:hover { background: rgba(255, 255, 255, .14); color: #fff; }
.tools { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.langs { position: relative; }
.langs summary { cursor: pointer; list-style: none; color: #fff; background: var(--blue); font-weight: 700; font-size: .95rem; min-height: 44px; display: flex; align-items: center; padding: 0 16px; border-radius: var(--pill); white-space: nowrap; box-shadow: 0 3px 0 rgba(0, 0, 0, .3); }
.langs summary::-webkit-details-marker, .burger summary::-webkit-details-marker { display: none; }
.langs summary:hover { filter: brightness(1.08); }
.langs .lc { display: none; }
.brand, .brand .bt { min-width: 0; }
.langs .menu { position: absolute; right: 0; top: calc(100% + 12px); z-index: 60; background: var(--cream); border: 4px solid #fff; border-radius: 18px; padding: 8px; display: grid; grid-template-columns: repeat(2, minmax(130px, 1fr)); gap: 3px; min-width: 300px; max-height: 75vh; overflow: auto; box-shadow: 0 14px 34px rgba(0, 0, 0, .35); }
.langs .menu a { padding: 12px 14px; color: var(--ink); text-decoration: none; border-radius: 12px; font-size: 1rem; font-weight: 600; }
.langs .menu a:hover { background: #fff; }
.langs .menu a[aria-current] { background: var(--gold); color: var(--brown); font-weight: 800; }
.burger summary { cursor: pointer; list-style: none; width: 48px; height: 44px; border-radius: var(--pill); background: var(--pink); box-shadow: 0 3px 0 rgba(0, 0, 0, .3); display: flex; align-items: center; justify-content: center; }
.burger summary span, .burger summary span::before, .burger summary span::after { display: block; width: 20px; height: 3px; border-radius: 2px; background: #fff; content: ""; position: relative; transition: transform .2s; }
.burger summary span::before { position: absolute; top: -7px; }
.burger summary span::after { position: absolute; top: 7px; }
.burger[open] summary span { background: transparent; }
.burger[open] summary span::before { transform: translateY(7px) rotate(45deg); }
.burger[open] summary span::after { transform: translateY(-7px) rotate(-45deg); }
.drawer { position: absolute; left: 0; right: 0; top: 100%; background: var(--navy); border-bottom: 5px solid var(--gold); padding: 8px 16px 18px; display: grid; box-shadow: 0 18px 30px rgba(0, 0, 0, .4); }
.drawer .nl { font-size: 1.15rem; padding: 16px 12px; border-radius: 14px; border-bottom: 1px solid rgba(255, 255, 255, .1); }
@media (min-width: 900px) { .mainnav { display: flex; } .burger { display: none; } }
@media (max-width: 560px) { .topbar .wrap { position: relative; } .langs { position: static; } .langs .menu { left: 10px; right: 10px; min-width: 0; top: calc(100% + 6px); } .langs .ln { display: none; } .langs .lc { display: inline; } .langs summary { padding: 0 14px; } .topbar .wrap { gap: 10px; } }
@media (max-width: 420px) { .brand { font-size: 1.05rem; } .brand img { width: 38px; height: 38px; } }
@media (max-width: 359px) { .brand .bt { display: none; } }
[id] { scroll-margin-top: 92px; }

/* Hero */
.hero { text-align: center; position: relative; }
.hero .key { width: 100%; max-height: 680px; object-fit: cover; object-position: center 28%; }
.hero .inner { position: relative; padding: 26px 20px 28px; }
.hero .inner::before { content: ""; position: absolute; left: 0; right: 0; top: -70px; height: 120px; background: url("/img/grass-edge.webp") repeat-x bottom / auto 120px; pointer-events: none; }
.hero h1 { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.tagline { font-size: clamp(1.9rem, 6.4vw, 3.3rem); line-height: 1.15; margin: 14px auto 10px; max-width: 18em; text-wrap: balance; }
.sub { margin: 0 auto 26px; max-width: 34em; color: #fff; font-size: 1.15rem; font-weight: 700; text-shadow: 0 2px 0 rgba(0, 0, 0, .55), 0 0 10px rgba(0, 0, 0, .35); text-wrap: balance; }
.stores { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.store {
  display: inline-flex; align-items: center; justify-content: center; min-width: 210px; padding: 14px 28px;
  background: var(--navy); color: #fff; border-radius: var(--pill); border: 4px solid #fff;
  font-size: 1.2rem; line-height: 1.2; cursor: default; box-shadow: var(--lift); opacity: .96;
  text-shadow: 0 2px 0 rgba(0, 0, 0, .45);
}
.soon { display: inline-block; margin-top: 22px; background: var(--gold); color: var(--brown); font-size: 1.05rem; padding: 7px 22px; border-radius: var(--pill); box-shadow: 0 4px 0 rgba(0, 0, 0, .25); transform: rotate(-2deg); }

.dancer { position: absolute; bottom: 8px; height: 330px; width: auto; display: none; filter: drop-shadow(0 8px 6px rgba(0, 0, 0, .35)); animation: bob 2.6s ease-in-out infinite; }
.dancer.left { left: max(2vw, calc(50% - 560px)); }
.dancer.right { right: max(2vw, calc(50% - 560px)); animation-delay: -1.3s; }
@media (min-width: 1000px) { .dancer { display: block; } }
@keyframes bob { 0%, 100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-10px) rotate(2deg); } }
@media (prefers-reduced-motion: reduce) { .dancer { animation: none; } html { scroll-behavior: auto; } }

.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 26px auto 0; max-width: 760px; }
.chip { font-family: var(--disp); font-weight: 900; font-size: .95rem; color: #fff; padding: 9px 18px; border-radius: var(--pill); background: var(--blue); border: 3px solid #fff; box-shadow: 0 4px 0 rgba(0, 0, 0, .25); text-shadow: 0 2px 0 rgba(0, 0, 0, .3); }
.chip.c1 { background: var(--pink); } .chip.c2 { background: var(--purple); } .chip.c3 { background: var(--green); }


main { padding: 0 0 64px; }
.lead { font-size: 1.15rem; max-width: 44em; margin: 0 auto; text-align: center; color: #fff; font-weight: 600; background: rgba(20, 52, 24, .72); padding: 16px 24px; border-radius: 20px; border: 3px solid rgba(255, 255, 255, .55); }

/* Pillars: cream cards with a colored pill badge, like the game's shop rows */
.pillars { display: grid; gap: 22px; grid-template-columns: 1fr; margin-top: 8px; }
@media (min-width: 780px) { .pillars { grid-template-columns: repeat(3, 1fr); } }
.pillar { position: relative; background: var(--cream); border: 4px solid #fff; border-radius: var(--radius); padding: 44px 22px 24px; box-shadow: var(--lift); text-align: center; }
.pillar .ico { position: absolute; top: -26px; left: 50%; transform: translateX(-50%); width: 56px; height: 56px; line-height: 48px; font-size: 1.7rem; border-radius: 50%; background: var(--blue); border: 4px solid #fff; box-shadow: 0 4px 0 rgba(0, 0, 0, .22); }
.pillar:nth-child(2) .ico { background: var(--pink); }
.pillar:nth-child(3) .ico { background: var(--green); }
.pillar h3 { font-family: var(--disp); font-weight: 900; font-size: 1.25rem; color: var(--brown); }
.pillar p { margin: 0; color: var(--muted); }

/* Real in-game captures */
.shots { display: grid; gap: 20px; grid-template-columns: 1fr; margin-top: 8px; }
@media (min-width: 780px) { .shots { grid-template-columns: 1.55fr 1fr; grid-template-rows: auto auto; } .shot.big { grid-row: 1 / span 2; } }
.shot { margin: 0; border: 5px solid #fff; border-radius: 22px; overflow: hidden; background: var(--navy); box-shadow: var(--lift); transition: transform .2s; }
.shot img { width: 100%; height: 100%; object-fit: cover; }
.shot:hover { transform: rotate(-.6deg) scale(1.01); }

/* Character roster */
.roster { display: grid; gap: 18px; grid-template-columns: repeat(2, 1fr); margin-top: 28px; }
@media (min-width: 780px) { .roster { grid-template-columns: repeat(4, 1fr); } }
.char { position: relative; display: flex; flex-direction: column; align-items: center; padding: 16px 10px 14px; border: 4px solid #fff; border-radius: 22px; box-shadow: var(--lift); text-align: center; background: linear-gradient(180deg, #6db7f5, #3e94ee); }
.char.f { background: linear-gradient(180deg, #f7a6c4, #ee6a9c); }
.char img { height: 190px; width: 100%; object-fit: contain; filter: drop-shadow(0 6px 4px rgba(0, 0, 0, .3)); transition: transform .2s; }
.char:hover img { transform: translateY(-6px) scale(1.05); }
.char b { margin-top: 10px; font-family: var(--disp); font-weight: 900; font-size: 1.3rem; color: #fff; -webkit-text-stroke: .1em var(--brown); paint-order: stroke fill; text-shadow: 0 .06em 0 var(--brown); }
.char span { margin-top: 4px; font-size: .8rem; font-weight: 800; color: var(--brown); background: #fff; padding: 2px 12px; border-radius: 999px; letter-spacing: .03em; }

/* Navy panel with pink frame, like the game's "chapter complete" panel */
.panel { background: var(--navy); color: #fff; border: 6px solid #f3a6c4; border-radius: 26px; padding: 8px 24px; box-shadow: var(--lift); }
.checks { list-style: none; padding: 0; margin: 0; }
.checks li { position: relative; padding: 16px 0 16px 46px; border-bottom: 1px solid rgba(255, 255, 255, .16); }
.checks li:last-child { border-bottom: 0; }
.checks li::before { content: "✓"; position: absolute; left: 0; top: 16px; width: 30px; height: 30px; line-height: 30px; text-align: center; border-radius: 50%; background: var(--gold); color: var(--brown); font-weight: 900; font-size: 1rem; box-shadow: 0 3px 0 rgba(0, 0, 0, .3); }

.facts { list-style: none; padding: 0; margin: 0; background: var(--cream); border: 4px solid #fff; border-radius: var(--radius); box-shadow: var(--lift); }
.facts li { padding: 14px 22px; border-bottom: 1px solid var(--cream-line); }
.facts li:last-child { border-bottom: 0; }
.facts strong { display: inline-block; min-width: 10em; }
@media (max-width: 560px) { .facts strong { display: block; } }

/* Press kit */
.sheet { background: var(--cream); border: 4px solid #fff; border-radius: var(--radius); box-shadow: var(--lift); padding: 8px 28px 28px; margin-top: 18px; }
.pending { background: #fff3c4; color: var(--ink); border: 2px dashed #d9a91f; border-radius: 14px; padding: 16px 18px; margin: 16px 0; }
.pending strong { display: block; }
.downloads { display: grid; gap: 18px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .downloads { grid-template-columns: repeat(3, 1fr); } }
.dl { background: #fff; border: 2px solid var(--cream-line); border-radius: 18px; overflow: hidden; text-decoration: none; color: var(--ink); }
.dl .thumb { aspect-ratio: 16 / 9; display: flex; align-items: center; justify-content: center; background: #cfe8f7; }
.dl .thumb img { max-height: 100%; width: auto; object-fit: contain; }
.dl .thumb.cover img { width: 100%; height: 100%; object-fit: cover; }
.dl .label { padding: 10px 16px; font-weight: 700; }
.dl .label small { display: block; color: var(--muted); font-weight: 400; }
.button, .pill { display: inline-block; color: #fff; background: var(--green); padding: 13px 26px; border-radius: var(--pill); text-decoration: none; text-shadow: 0 2px 0 rgba(0, 0, 0, .35); box-shadow: 0 5px 0 rgba(0, 0, 0, .28); border: 0; }
.button:hover, .pill:hover { filter: brightness(1.07); transform: translateY(-1px); }
.button:active, .pill:active { transform: translateY(3px); box-shadow: 0 2px 0 rgba(0, 0, 0, .28); }

/* Footer */
footer.site { background: var(--navy); border-top: 5px solid var(--gold); color: #cfd6ff; font-size: .95rem; padding: 32px 0 48px; }
footer.site .links { display: flex; flex-wrap: wrap; gap: 12px; }
footer.site .links a { font-family: var(--disp); font-weight: 900; font-size: .95rem; color: #fff; text-decoration: none; padding: 9px 20px; border-radius: var(--pill); background: var(--blue); text-shadow: 0 2px 0 rgba(0, 0, 0, .35); box-shadow: 0 4px 0 rgba(0, 0, 0, .3); }
footer.site .links a:nth-child(2) { background: var(--purple); }
footer.site .links a:nth-child(3) { background: var(--green); }
footer.site .links a:hover { filter: brightness(1.08); }
footer.site a { color: #fff; }
footer.site .studio { display: flex; align-items: center; gap: 14px; margin-top: 26px; }
footer.site .studio img { width: 56px; height: 56px; border-radius: 14px; flex: none; border: 2px solid rgba(255, 255, 255, .5); }
footer.site p { margin: 0; line-height: 1.5; }

/* Legal pages: text on a cream sheet over the grass */
.legal h1 { margin: 40px 0 0; font-size: clamp(1.8rem, 5.4vw, 2.7rem); line-height: 1.15; text-align: center; }
.legal .sheet { margin-top: 22px; padding-top: 22px; }
.legal .upd { color: var(--muted); margin: 0 0 8px; font-size: .95rem; }
.legal h2 { color: var(--brown); -webkit-text-stroke: 0; text-shadow: none; text-align: left; font-size: clamp(1.25rem, 3.6vw, 1.55rem); margin: 38px 0 10px; }
.legal h3 { margin: 24px 0 6px; color: var(--brown); }
.legal ul { padding-left: 22px; }
.legal li { margin: 8px 0; }
.legal p { margin: 12px 0; }

.notfound { text-align: center; padding: 48px 0 56px; }
.notfound img { margin: 0 auto 18px; width: min(460px, 90%); }
.notfound .lead { margin-bottom: 24px; }

@media print { .topbar, footer.site { display: none; } body { background: #fff; color: #000; } h1, h2 { color: #000; -webkit-text-stroke: 0; text-shadow: none; } }

/* /download: the page every in-game share points to */
.dl-page { text-align: center; padding-top: 34px; padding-bottom: 20px; }
.dl-key { width: min(760px, 100%); margin: 0 auto 26px; border: 5px solid #fff; border-radius: 22px; box-shadow: var(--lift); }
.dl-page h1 { font-size: clamp(1.9rem, 6vw, 3rem); margin: 0 0 14px; }
.dl-page .lead { margin-bottom: 28px; }
.store.has-badge { background: transparent; border: 0; box-shadow: none; padding: 0; min-width: 0; opacity: 1; text-shadow: none; }
.store .badge { width: auto; display: block; }
.store .badge.as { height: 56px; }
.store .badge.gp { height: 80px; margin: -12px 0; }
a.store { text-decoration: none; }
a.store:hover { filter: brightness(1.08); transform: translateY(-1px); }

/* Phones (kept last so it overrides the base rules above) */
@media (max-width: 779px) {
  .hero .key { aspect-ratio: 4 / 3; object-position: 50% 30%; }
  .hero .inner { padding-top: 14px; }
  .store { width: 100%; max-width: 320px; padding: 16px 24px; }
  .stores { flex-direction: column; align-items: center; }
  .chips { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; margin: 22px -20px 0; padding: 4px 20px 10px; scrollbar-width: none; scroll-snap-type: x proximity; }
  .chips::-webkit-scrollbar, .shots::-webkit-scrollbar, .roster::-webkit-scrollbar { display: none; }
  .chip { flex: none; scroll-snap-align: start; }
  .shots, .roster { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 14px; margin-left: -20px; margin-right: -20px; padding: 6px 20px 18px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .shot { flex: none; width: 84%; scroll-snap-align: center; }
  .shot img { aspect-ratio: 16 / 9; }
  .char { flex: none; width: 46%; scroll-snap-align: start; }
  .char img { height: 170px; }
  h2 { margin-top: 46px; }
  .panel { padding: 4px 18px; border-width: 5px; }
  .legal h1 { margin-top: 28px; }
  .sheet { padding: 6px 18px 22px; }
  footer.site .links a { flex: 1 1 auto; text-align: center; padding: 13px 20px; }
}
