/* どぱぞんびの紹介ページの部品（スタートボタン・ヒーロー・更新履歴）。works/psenryaku-simu/page.css の複製に、縦画面のゲームのヒーローを足したもの。
   p戦略Simu 側を直したら手で合わせる */

/* 立体的なキー: 上面は白→薄い灰、下に厚み（影）を付ける */
.key {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 2em; height: 2em; padding: 0 .55em; margin: 2px 1px 5px;
  font-family: var(--latin); font-weight: 600; font-size: .92em; line-height: 1; color: var(--ink);
  background: linear-gradient(180deg, var(--paper) 0%, var(--mist) 100%);
  border: 1px solid color-mix(in srgb, var(--ink) 22%, var(--paper));
  border-radius: 7px;
  box-shadow:
    0 3px 0 color-mix(in srgb, var(--ink) 30%, var(--paper)),
    0 5px 8px color-mix(in srgb, var(--ink) 18%, transparent),
    inset 0 -2px 0 var(--line);
  white-space: nowrap; vertical-align: middle;
}
.key--wide { min-width: 3.6em; }
/* 矢印キーは上 1 つ・下 3 つに並べる */
.arrows { display: inline-grid; grid-template-columns: repeat(3, auto); gap: 0 2px; vertical-align: middle; }
.arrows .key { margin: 1px 0 4px; }
.arrows .up { grid-column: 2; }
.arrows .left { grid-column: 1; grid-row: 2; }
.arrows .down { grid-column: 2; grid-row: 2; }
.arrows .right { grid-column: 3; grid-row: 2; }

/* 画面右上のボタン（ゲーム内の見た目に寄せた暗いボタン） */
.hud {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 1.9em; height: 1.9em; padding: 0 .45em; margin: 2px 1px;
  font-size: .92em; line-height: 1; color: var(--paper);
  background: var(--night); border: 1px solid color-mix(in srgb, var(--paper) 45%, var(--night)); border-radius: 5px;
  vertical-align: middle; white-space: nowrap;
}

/* マウスの絵 */
.mouse { width: 44px; height: 34px; vertical-align: middle; margin-right: 6px; flex: none; }
.mouse .body { fill: var(--paper); stroke: var(--ink); stroke-width: 1.6; }
.mouse .seam { stroke: var(--ink); stroke-width: 1.2; fill: none; }
.mouse .on { fill: var(--blue); }
.mouse .wheel { fill: var(--ink-soft); }
.mouse .mark { stroke: var(--blue); stroke-width: 1.8; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.how { display: flex; align-items: center; gap: 2px; margin: 4px 0; }
.how + .how { margin-top: 8px; }

.ctrl-table td { vertical-align: middle; }
.ctrl-table td:first-child { font-weight: 700; white-space: nowrap; }
.ctrl-note { font-size: 13px; color: var(--ink-soft); }

/* 更新履歴 */
.history { display: grid; gap: 18px; }
.release { padding: 18px 22px; background: var(--paper); border: 1px solid var(--line); border-radius: 10px; }
.release h3 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px; font-size: 18px; margin: 0 0 8px; }
.release h3 .ver { font-family: var(--latin); font-size: 22px; color: var(--blue); }
.release h3 time { font-size: 14px; color: var(--ink-soft); font-weight: 500; }
.release ul { margin: 0; padding-left: 1.2em; }
.release li + li { margin-top: 4px; }

/* 狭い画面: 表をやめて、操作ごとのカードに縦に並べる（見出しは data-label から出す） */
@media (max-width: 640px) {
  .ctrl-table thead { display: none; }
  .ctrl-table, .ctrl-table tbody, .ctrl-table tr, .ctrl-table td { display: block; width: 100%; }
  .ctrl-table tr { padding: 12px 14px; margin-bottom: 12px; background: var(--paper); border: 1px solid var(--line); border-radius: 10px; }
  .ctrl-table td { position: relative; padding: 6px 0 6px 6.5em; border: 0; min-height: 2.4em; }
  .ctrl-table td::before { content: attr(data-label); position: absolute; left: 0; top: 10px; width: 6em; font-size: 12px; line-height: 1.4; color: var(--ink-soft); }
  .ctrl-table td:first-child { padding-left: 0; min-height: 0; font-size: 16px; padding-bottom: 8px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
  .ctrl-table td:first-child::before { content: none; }
}

/* 更新履歴の変更点（画面写真＋見出し＋説明） */
.changes { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 16px; margin-top: 12px; }
.changes--one { grid-template-columns: minmax(0, 1fr); }
.change { display: flex; flex-direction: column; gap: 6px; }
.change .change-shot { background: var(--night); border-radius: 8px; overflow: hidden; }
.change .change-shot img { display: block; width: 100%; height: auto; }
.change h4 { margin: 4px 0 0; font-size: 16px; }
.change p { margin: 0; font-size: 14px; line-height: 1.7; }
.changes--one .change { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: center; }
@media (max-width: 640px) { .changes--one .change { grid-template-columns: minmax(0, 1fr); } }

/* ヒーロー: 今のタイトル画面の絵とロゴに、スタートボタンを重ねる */
.work-kv.kv-title { background: var(--night); }
.work-kv.kv-title > .kv-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 70%; }
/* ロゴと文字が読めるよう、上と下に暗がりを敷く */
.work-kv.kv-title::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8, 10, 30, .55) 0%, rgba(8, 10, 30, .05) 45%, rgba(8, 10, 30, .65) 100%); }
.kv-start { position: absolute; inset: 0; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: clamp(10px, 2.4vw, 22px); padding: 16px; text-align: center; }
.kv-title-logo { width: min(52%, 520px); height: auto; filter: drop-shadow(0 6px 18px rgba(0, 0, 0, .45)); }
.kv-note { margin: 0; padding: 4px 14px; font-size: 13px; line-height: 1.6; color: #fff; background: rgba(8, 10, 30, .62); border-radius: 999px; }

/* スタートボタン（ゲームのメニューに寄せた、太い縁のボタン。▶ は点滅） */
.start-btn {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 14px 34px 14px 26px; min-height: 56px;
  font-size: clamp(18px, 2.2vw, 22px); font-weight: 700; letter-spacing: .08em; line-height: 1; color: #fff; text-decoration: none;
  background: linear-gradient(180deg, #2c2c6c 0%, #1a1a46 100%);
  border: 3px solid #d8d8f0; border-radius: 6px;
  box-shadow: 0 0 0 3px #0c0c20, 0 8px 22px rgba(0, 0, 0, .45);
  transition: transform .12s ease, background .12s ease;
}
.start-btn:hover { background: linear-gradient(180deg, #3a3a88 0%, #24245c 100%); transform: translateY(-2px); }
.start-btn:focus-visible { outline: 3px solid #f8d030; outline-offset: 4px; }
.start-mark { width: 0; height: 0; border-top: 9px solid transparent; border-bottom: 9px solid transparent; border-left: 13px solid #f8d030; animation: start-blink 1s steps(1) infinite; }
@keyframes start-blink { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .start-mark { animation: none; } .start-btn { transition: none; } }
.start-btn--small { min-height: 48px; padding: 10px 26px 10px 20px; font-size: 17px; }
.again { margin: 28px 0 0; text-align: center; }

@media (max-width: 640px) {
  .work-kv.kv-title { aspect-ratio: 4 / 3.4; }
  .kv-title-logo { width: 82%; }
  .kv-note { font-size: 12px; }
}

/* 遊びかたの手順（更新履歴の変更点と同じ並び。見出しに番号） */
.steps { margin-top: 0; gap: 22px; }
/* 写真の縦横比がそろわないので、枠を同じ比にして中に収める（見出しの高さをそろえる） */
.steps .change-shot { aspect-ratio: 16 / 10; display: flex; align-items: center; justify-content: center; }
.steps .change-shot img { width: 100%; height: 100%; object-fit: contain; }
.step { padding: 14px; background: var(--paper); border: 1px solid var(--line); border-radius: 10px; }
.step h4 { display: flex; align-items: center; gap: 10px; }
.step-no { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; flex: none; border-radius: 50%; background: var(--blue); color: #fff; font-family: var(--latin); font-size: 15px; font-weight: 600; }
.release-more { margin-top: 14px !important; font-size: 14px; }

/* 作品名の見出し: 文字の代わりにロゴ。後ろにタイトルの絵をぼかして敷く */
.work-intro h1.title-logo { position: relative; display: inline-flex; flex-direction: column; align-items: center; gap: 6px; margin: 0 0 18px; padding: 18px 28px 14px; border-radius: 12px; overflow: hidden; isolation: isolate; }
.work-intro h1.title-logo img { display: block; width: min(100%, 360px); height: auto; filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .5)); }
.work-intro h1.title-logo small { margin: 0; color: #e8ebf8; text-shadow: 0 1px 3px rgba(0, 0, 0, .7); }

/* ---- 縦画面のゲームのヒーロー（p戦略Simu の page.css には無い） ---- */
/* 縦画面のゲーム（どぱぞんび）のヒーロー: タイトル画面の写真を左に、スタートボタンを右に並べる */
.kv-start--phone { flex-direction: row; gap: clamp(14px, 4vw, 48px); }
.kv-phone { height: 88%; width: auto; border-radius: 10px; box-shadow: 0 0 0 3px rgba(255, 255, 255, .18), 0 12px 30px rgba(0, 0, 0, .55); }
.kv-side { display: flex; flex-direction: column; align-items: flex-start; gap: clamp(10px, 2vw, 18px); max-width: 360px; text-align: left; }
.kv-side .kv-note { border-radius: 10px; }
/* 背景はタイトル画面を大きくぼかして敷く（縦長の絵を横長の枠に広げるので、絵柄が分からないくらいに） */
.work-kv.kv-title > .kv-bg--blur { inset: -40px; width: calc(100% + 80px); height: calc(100% + 80px); object-position: center 30%; filter: blur(22px) brightness(.7) saturate(1.2); }
@media (max-width: 640px) {
  .kv-phone { height: 84%; }
  .kv-side .start-btn { padding: 12px 18px 12px 14px; min-height: 48px; font-size: 16px; gap: 8px; }
}
