/* GameCreate のサイト（tools/home/build.py が作るページの共通の見た目）
   考え方: 卓上のゲームを作る小さな工房。主役は「卓の上に置いたアプリのアイコン」の 1 か所だけで、ほかは静かに。
   色: 墨紺 ink・地 paper・卓 felt・牌 ivory・灯 lime（フォーカスと小さな印だけ） */
:root {
  --ink: #1f2b45;
  --ink-2: #4b5670;
  --paper: #eef1ec;
  --felt: #2e6b63;
  --felt-deep: #24564f;
  --ivory: #fbfaf4;
  --line: #d5dbd3;
  --lime: #c9e96b;
  --jp: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Noto Sans JP", sans-serif;
  --latin: "Outfit", var(--jp);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--jp); font-weight: 500;
  font-size: 16px; line-height: 1.8; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--lime); outline-offset: 3px; border-radius: 6px; }
.wrap { width: min(1080px, 100% - 48px); margin-inline: auto; }

/* 見出しの帯 */
.top { padding: 18px 0; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.mark { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; min-height: 44px; }
.mark-tile { width: 30px; height: 36px; border-radius: 7px; background: var(--ivory); border: 2px solid var(--ink);
  box-shadow: 0 3px 0 var(--ink); display: grid; place-items: center; font: 700 17px/1 var(--latin); }
.mark-name { font: 600 21px/1 var(--latin); letter-spacing: .01em; }
.nav { display: flex; gap: 4px; flex-wrap: wrap; }
.nav a { text-decoration: none; font-weight: 700; font-size: 15px; padding: 10px 12px; min-height: 44px;
  display: inline-flex; align-items: center; border-radius: 10px; }
.nav a:hover { background: rgba(31, 43, 69, .07); }
.nav a[aria-current="page"] { box-shadow: inset 0 -3px 0 var(--felt); border-radius: 0; }

/* 最初の画面: 卓。下の縁を楕円にして卓の天板に見せ、その上にアプリのアイコンを置く */
.table { background: var(--felt); color: var(--ivory); border-radius: 0 0 48% 48% / 0 0 90px 90px;
  box-shadow: inset 0 -14px 0 var(--felt-deep); padding: 56px 0 96px; overflow: hidden; }
.table .wrap { display: grid; grid-template-columns: 1.45fr 1fr; gap: 32px; align-items: center; }
.table h1 { font-weight: 900; font-size: clamp(27px, 4.2vw, 48px); line-height: 1.35; margin: 0 0 18px;
  letter-spacing: .02em; }
.table p { margin: 0; max-width: 32em; color: #dcebe7; font-size: 17px; }
.pieces { position: relative; height: 300px; }
.piece { position: absolute; width: 168px; border-radius: 36px; overflow: hidden; text-decoration: none;
  box-shadow: 0 18px 0 rgba(0, 0, 0, .16), 0 26px 40px rgba(0, 0, 0, .18); }
.piece img { width: 100%; }
.piece:nth-child(1) { left: 8%; top: 40px; transform: rotate(-8deg); }
.piece:nth-child(2) { left: 48%; top: 86px; transform: rotate(7deg); }
.piece:nth-child(3) { left: 28%; top: 150px; transform: rotate(-2deg); width: 128px; border-radius: 28px; }
@media (prefers-reduced-motion: no-preference) {
  .piece { animation: deal .7s cubic-bezier(.2, .8, .2, 1) both; }
  .piece:nth-child(2) { animation-delay: .12s; }
  .piece:nth-child(3) { animation-delay: .24s; }
  @keyframes deal { from { opacity: 0; translate: 0 -40px; } }
}

/* 本文の区画 */
main > section { padding: 64px 0 8px; }
h2 { font-weight: 900; font-size: 28px; line-height: 1.4; margin: 0 0 24px; }
.lead { color: var(--ink-2); margin: -12px 0 28px; max-width: 40em; }

/* ゲームの行（1 本 = 1 行。アイコン・名前・ひとこと・入れられる所・ページへのリンク） */
.games { display: grid; gap: 18px; }
.game { display: grid; grid-template-columns: 112px 1fr auto; gap: 24px; align-items: center; background: var(--ivory);
  border: 1px solid var(--line); border-radius: 24px; padding: 22px 26px; }
.game > img { width: 112px; border-radius: 26px; }
.game h3 { margin: 0; font-weight: 900; font-size: 24px; line-height: 1.4; }
.game h3 a { text-decoration: none; }
.game h3 a:hover { text-decoration: underline; text-underline-offset: 5px; }
.game .kind { font-weight: 700; font-size: 14px; color: var(--felt); margin: 0 0 2px; }
.game .tagline { margin: 4px 0 0; }
.game .status { margin: 6px 0 0; font-size: 14px; color: var(--ink-2); }
.game .acts { display: flex; flex-direction: column; gap: 8px; align-items: stretch; min-width: 168px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 18px;
  border-radius: 12px; font-weight: 700; font-size: 15px; text-decoration: none; border: 2px solid var(--ink); }
.btn.primary { background: var(--ink); color: var(--ivory); }
.btn.primary:hover { background: var(--felt-deep); border-color: var(--felt-deep); }
.btn:not(.primary):hover { background: rgba(31, 43, 69, .07); }
.small-links { display: flex; gap: 14px; flex-wrap: wrap; font-size: 14px; margin-top: 10px; }
.small-links a { color: var(--ink-2); min-height: 32px; display: inline-flex; align-items: center; }

/* ゲームの紹介ページ */
.game-hero { display: grid; grid-template-columns: 160px 1fr; gap: 32px; align-items: center; padding: 40px 0 8px; }
.game-hero img { width: 160px; border-radius: 36px; box-shadow: 0 14px 0 rgba(31, 43, 69, .12); }
.game-hero h1 { font-weight: 900; font-size: clamp(30px, 4vw, 44px); line-height: 1.3; margin: 2px 0 10px; }
.game-hero .kind { font-weight: 700; color: var(--felt); margin: 0; }
.game-hero p.tagline { font-size: 19px; margin: 0; }
.prose { max-width: 40em; }
.prose p { margin: 0 0 1em; }
.shots { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; margin-top: 8px; }
.shots img { border-radius: 16px; border: 1px solid var(--line); }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: 10px 24px; margin: 0; }
.facts dt { font-weight: 700; color: var(--ink-2); }
.facts dd { margin: 0; }

/* 運営者・お問い合わせ */
.card { background: var(--ivory); border: 1px solid var(--line); border-radius: 24px; padding: 28px; max-width: 720px; }
.mail { font: 600 22px/1.4 var(--latin); word-break: break-all; }

/* 足もと */
footer { margin-top: 72px; padding: 32px 0 40px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
footer nav { display: flex; gap: 16px; flex-wrap: wrap; }
footer a { min-height: 32px; display: inline-flex; align-items: center; }

@media (max-width: 760px) {
  body { font-size: 15.5px; }
  .table { padding: 32px 0 64px; border-radius: 0 0 50% 50% / 0 0 44px 44px; }
  .table .wrap { grid-template-columns: 1fr; gap: 8px; }
  .table p { font-size: 16px; }
  .pieces { height: 190px; }
  .piece { width: 112px; border-radius: 24px; }
  .piece:nth-child(1) { left: 6%; top: 24px; }
  .piece:nth-child(2) { left: 52%; top: 40px; }
  .game { grid-template-columns: 72px 1fr; gap: 16px; padding: 18px; }
  .game > img { width: 72px; border-radius: 18px; }
  .game h3 { font-size: 20px; }
  .game .acts { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; min-width: 0; }
  .game .acts .btn { flex: 1 1 140px; }
  .game-hero { grid-template-columns: 96px 1fr; gap: 18px; padding-top: 24px; }
  .game-hero img { width: 96px; border-radius: 22px; }
  .game-hero p.tagline { font-size: 17px; }
  h2 { font-size: 24px; }
  .facts { grid-template-columns: 1fr; gap: 2px; }
  .facts dd { margin-bottom: 10px; }
}
