:root {
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", "Noto Sans CJK SC", system-ui, sans-serif;
  --paper: #f3f7fd;
  --ink: #14243e;
  --muted: #51617a;
  --line: #dbe5f1;
  --blue: #1864d7;
  --blue-dark: #104fae;
  --header-height: 68px;
}
* { box-sizing: border-box; }
html { font-family: var(--font); scroll-padding-top: calc(var(--header-height) + 16px); line-break: strict; }
body { margin: 0; background: #fff; color: var(--ink); line-height: 1.7; }
h1, h2, h3, p, figure, dl, dd { margin: 0; }
h1, h2, h3 { line-height: 1.2; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
a:focus-visible, summary:focus-visible, .screenshots-grid:focus-visible { outline: 3px solid #398cf8; outline-offset: 4px; }
.container { width: min(1160px, calc(100% - 64px)); margin-inline: auto; }

.site-header { position: sticky; top: 0; z-index: 2; color: #f5f9ff; background: #101f36; border-bottom: 1px solid #293b56; }
.header-inner { display: flex; align-items: center; gap: 32px; min-height: var(--header-height); }
.brand { display: inline-flex; flex: none; align-items: center; gap: 10px; font-size: 19px; font-weight: 800; line-height: 1; white-space: nowrap; }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
.desktop-nav, .footer-nav { display: flex; gap: clamp(16px, 2.7vw, 36px); margin-left: auto; font-size: 14px; white-space: nowrap; }
.desktop-nav { color: #cedbea; }
.desktop-nav a:hover { color: #fff; }
.header-cta { display: inline-flex; align-items: center; justify-content: center; flex: none; min-height: 36px; padding: 0 19px; border-radius: 8px; background: var(--blue); color: #fff; font-size: 14px; font-weight: 700; white-space: nowrap; }
.header-cta:hover, .button:hover { background: var(--blue-dark); }

.hero { overflow: hidden; color: #fff; background: radial-gradient(ellipse at 78% 26%, #1a4074 0%, transparent 54%), linear-gradient(125deg, #0f203c, #112748 64%, #122339); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .96fr); align-items: center; gap: clamp(30px, 5.6vw, 80px); min-height: 495px; padding-block: 54px; }
.hero h1 { font-size: clamp(48px, 6.3vw, 91px); font-weight: 850; letter-spacing: -.045em; line-height: 1; }
.hero-tagline { margin-top: 23px; color: #9ac9ff; font-size: clamp(22px, 2.6vw, 36px); font-weight: 750; line-height: 1.25; }
.hero-description { max-width: 31em; margin-top: 21px; color: #d6e3f6; font-size: 16px; line-height: 1.8; text-wrap: pretty; }
.keep-together { white-space: nowrap; }
.hero-actions { margin-top: 29px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; width: min(268px, 100%); min-height: 54px; padding: 12px 22px; border-radius: 10px; background: var(--blue); color: #fff; font-size: 17px; font-weight: 750; line-height: 1.2; text-align: center; transition: background-color .16s ease; }
.download-icon { position: relative; display: inline-block; flex: none; width: 20px; height: 20px; background: linear-gradient(currentColor,currentColor) center 1px / 2px 10px no-repeat; }
.download-icon::before { content: ""; position: absolute; left: 6px; top: 5px; width: 8px; height: 8px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.download-icon::after { content: ""; position: absolute; inset: auto 1px 0; height: 5px; border: 2px solid currentColor; border-top: 0; border-radius: 0 0 3px 3px; }
.hero-media {
  position: relative; display: grid; place-items: center; isolation: isolate;
  min-height: 353px; padding: 32px; overflow: hidden; border: 1px solid #557eaa;
  border-radius: 28px;
  background: radial-gradient(circle, #86bfff 1px, transparent 1.5px) 0 0 / 20px 20px, linear-gradient(145deg, #316eb4 0%, #1c467b 45%, #132e55 100%);
  box-shadow: 0 24px 60px #08172c80;
}
.hero-media::before {
  content: ""; position: absolute; z-index: -1; width: 120%; height: 70%;
  background: linear-gradient(0deg, #88c4ff12, #91c9ff48);
  border: 1px solid #acdbff45; border-radius: 50%; transform: translateY(24%) rotate(-25deg);
}
.game-wall { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); grid-template-rows: repeat(2, auto); align-items: center; gap: 13px; width: min(330px, 100%); transform: rotate(-5deg); }
.game-card { display: grid; min-width: 0; padding: 8px; border: 1px solid #779cc8; border-radius: 15px; background: #152c4a; box-shadow: 0 8px 20px #091c3780; }
.game-card img { width: 100%; aspect-ratio: 1; border-radius: 9px; object-fit: cover; }
.game-card figcaption { padding: 5px 3px 0; overflow-wrap: anywhere; color: #f1f7ff; font-size: 12px; font-weight: 700; line-height: 1.35; }
.game-card-nikke { grid-row: span 2; }
.game-card-nikke figcaption { font-size: 14px; padding-block: 9px 3px; }

.section { padding-block: 78px; }
.section-heading { margin-bottom: 30px; }
.section-heading h2, .download-inner h2 { font-size: clamp(30px, 3.25vw, 46px); font-weight: 800; }
.screenshots-section { padding-block: 59px 58px; background: var(--paper); }
.screenshots-grid {
  display: grid; grid-auto-flow: column; grid-auto-columns: max(177px, calc((100% - 64px) / 5)); gap: 16px;
  margin: 0; padding: 2px 0 12px; overflow-x: auto; overscroll-behavior-x: contain;
  list-style: none; scroll-snap-type: x proximity; scrollbar-color: #9eb4cf #e3ebf5; scrollbar-width: thin;
}
.screenshots-grid li { scroll-snap-align: start; }
.screenshots-grid a { display: block; overflow: hidden; border: 1px solid #c7d7ea; border-radius: 14px; background: #fff; }
.screenshots-grid a:focus-visible { outline-offset: -4px; }
.screenshots-grid img { width: 100%; }

.centered { text-align: center; }
.feature-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.feature-card { padding: clamp(24px, 3vw, 36px); border: 1px solid var(--line); border-radius: 18px; background: #f8fbff; }
.feature-card h3, .usage-card h3 { margin-bottom: 12px; font-size: 23px; font-weight: 750; }
.feature-card p, .usage-card p, .usage-card dd { color: var(--muted); }
.feature-icon { display: grid; place-items: center; width: 48px; height: 48px; margin-bottom: 21px; border-radius: 13px; background: #e3efff; color: var(--blue-dark); }
.search-icon { position: relative; width: 15px; height: 15px; margin: 0 4px 4px 0; border: 2px solid currentColor; border-radius: 50%; }
.search-icon::after { content: ""; position: absolute; top: 10px; left: 10px; width: 8px; height: 2px; border-radius: 2px; background: currentColor; transform: rotate(45deg); transform-origin: left; }
.details-icon { width: 16px; height: 20px; border: 2px solid currentColor; border-radius: 3px; background: linear-gradient(currentColor,currentColor) center 5px / 7px 2px no-repeat, linear-gradient(currentColor,currentColor) center 10px / 7px 2px no-repeat; }

.usage-section { background: var(--paper); }
.usage-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; }
.usage-card { padding: clamp(23px, 3.25vw, 39px); border: 1px solid var(--line); border-radius: 18px; background: #fff; }
.version-card { border-color: #c9ddf5; background: #ecf4ff; }
.versions { margin-top: 22px; }
.versions > div { display: grid; grid-template-columns: minmax(104px, .8fr) minmax(0, 1.9fr); gap: 8px 14px; padding-block: 12px; border-top: 1px solid #cddcf0; }
.versions dt { font-weight: 730; }
.versions dd { margin: 0; }
.steps { display: grid; gap: 16px; margin: 19px 0 0; padding-left: 1.3em; color: var(--muted); }
.steps li { padding-left: 6px; }
.steps li::marker { color: var(--blue-dark); font-weight: 800; }

.faq-grid { display: grid; grid-template-columns: minmax(190px, .55fr) minmax(0, 1fr); gap: 24px 50px; }
.faq-grid .section-heading { margin: 0; }
.faq-list { border-top: 1px solid var(--line); }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-block: 17px; font-size: 17px; font-weight: 700; cursor: pointer; list-style: none; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: ""; flex: none; width: 9px; height: 9px; margin-right: 4px; border: solid var(--blue-dark); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.faq-list details[open] summary { color: var(--blue-dark); }
.faq-list details[open] summary::after { transform: rotate(225deg); }
.faq-list p { max-width: 46em; padding: 0 18px 18px 0; color: var(--muted); }

.download-section { padding-bottom: 72px; }
.download-inner { display: flex; align-items: center; justify-content: space-between; gap: 23px; padding: clamp(26px, 5vw, 62px); border-radius: 23px; background: linear-gradient(112deg, #142c50, #1c4b85); color: #fff; }
.download-inner h2 { overflow-wrap: anywhere; }
.app-info { display: flex; flex-wrap: wrap; gap: 4px 22px; margin-top: 17px; font-size: 14px; }
.app-info > div { display: flex; flex-wrap: wrap; gap: 2px 8px; }
.app-info dt { color: #c8dcf8; }
.app-info code { font-size: inherit; }
.site-footer { padding-block: 28px; border-top: 1px solid var(--line); }
.footer-main { display: flex; align-items: center; gap: 22px; }
.footer-nav { color: var(--muted); }
.footer-nav a:hover { color: var(--blue-dark); }

@media (max-width: 900px) {
  .hero-grid { gap: 25px; }
  .hero-media { padding: 23px; min-height: 300px; }
  .feature-grid { gap: 12px; }
}
@media (max-width: 730px) {
  :root { --header-height: 93px; }
  .container { width: calc(100% - 36px); }
  .header-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: 56px 37px; gap: 0 12px; }
  .desktop-nav { grid-column: 1 / -1; grid-row: 2; align-self: stretch; align-items: center; justify-content: space-between; gap: 8px; margin: 0; border-top: 1px solid #293b56; }
  .header-cta { grid-column: 2; grid-row: 1; }
  .hero-grid { grid-template-columns: 1fr; gap: 28px; min-height: auto; padding-block: 39px 30px; }
  .hero h1 { font-size: clamp(42px, 10.5vw, 74px); }
  .hero-tagline { margin-top: 15px; }
  .hero-description { margin-top: 15px; }
  .hero-actions { margin-top: 22px; }
  .button { width: 100%; }
  .hero-media { min-height: auto; padding: 23px 15px; border-radius: 17px; }
  .game-wall { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: auto; align-items: start; width: min(100%, 445px); gap: 8px; transform: none; }
  .game-card { padding: 5px; border-radius: 10px; }
  .game-card img { border-radius: 6px; }
  .game-card-nikke { grid-row: auto; }
  .game-card-nikke figcaption { padding: 5px 3px 0; font-size: 12px; }
  .section { padding-block: 51px; }
  .section-heading { margin-bottom: 22px; }
  .screenshots-grid { grid-auto-columns: clamp(168px, 55vw, 240px); gap: 12px; }
  .feature-grid, .usage-grid, .faq-grid { grid-template-columns: 1fr; }
  .download-section { padding-bottom: 50px; }
  .download-inner, .footer-main { align-items: flex-start; flex-direction: column; }
  .footer-nav { flex-wrap: wrap; gap: 9px 16px; margin-left: 0; }
}
@media (max-width: 430px) {
  .versions > div { grid-template-columns: 1fr; gap: 3px; }
}
