/* pzlers 公式Web。和文は太い現代ゴシック、欧文と数字は等幅(パズルのマスに揃う)。
   パズルごとの色の面に実際の盤を置く。飾りの影・グラデーション文字・ぼかし背景は使わない */
@font-face {
  font-family: "Martian Mono";
  src: url("../assets/fonts/martian-mono-latin.woff2") format("woff2");
  font-weight: 100 800;
  font-stretch: 75% 112.5%;
  font-display: swap;
}
:root {
  --bg: #ffffff;
  --bg-2: #f3f3f1;
  --ink: #0e0e10;
  --ink-2: #4b4b52;
  --ink-3: #8b8b93;
  --line: #e4e4e0;
  --hot: #ff4f3d;
  --sans: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Noto Sans CJK JP", "Yu Gothic UI", system-ui, sans-serif;
  --mono: "Martian Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --r: 22px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #0e0e10; --bg-2: #18181b; --ink: #f2f2ef; --ink-2: #b4b4bb; --ink-3: #75757d; --line: #2a2a2f; }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.8; -webkit-font-smoothing: antialiased; }
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p { margin: 0; }
.mono { font-family: var(--mono); font-feature-settings: "zero" 0; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; z-index: 9; background: var(--bg); padding: 6px 10px; }
:focus-visible { outline: 3px solid var(--hot); outline-offset: 3px; border-radius: 6px; }

/* ---------- ナビ ---------- */
.nav-in { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.logo-mark { width: 30px; height: 30px; color: var(--ink); }
.logo-word { font-family: var(--mono); font-weight: 800; font-size: 22px; font-stretch: 112.5%; letter-spacing: 0; display: inline-flex; }
/* 字ごとのカーニング(字の見た目の間の白を揃える。等幅の字送りのままだと l の両側だけ白が広い)。値は docs/brand/logo-r4 で測定 */
.logo-word > span { margin-left: var(--k, 0); }
.logo-word .k-z { --k: -0.015em; } .logo-word .k-l { --k: -0.12em; } .logo-word .k-e { --k: -0.084em; } .logo-word .k-r { --k: -0.057em; } .logo-word .k-s { --k: -0.027em; }
.nav-links { display: flex; gap: 6px; }
.nav-links a { white-space: nowrap; padding: 8px 14px; border-radius: 999px; text-decoration: none; font-size: 14px; font-weight: 700; color: var(--ink-2); }
.nav-links a:hover { background: var(--bg-2); color: var(--ink); }

/* ---------- ヒーロー ---------- */
.hero { padding: 24px 0 96px; }
.hero-in { display: grid; gap: 48px; align-items: center; }
@media (min-width: 1020px) { .hero-in { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 64px; } .hero { padding: 40px 0 120px; } }
.hero-in > * { min-width: 0; }

.hero-brand { margin-top: 0; font-size: 13px; font-weight: 700; color: var(--ink-3); letter-spacing: .12em; }
.hero h1 .nw { white-space: nowrap; }
.hero h1 { margin-top: 26px; font-weight: 900; font-size: clamp(40px, 6.6vw, 72px); line-height: 1.14; letter-spacing: -0.03em; font-feature-settings: "palt" 1; }
.lead { margin-top: 22px; max-width: 30em; font-size: 17px; line-height: 1.9; color: var(--ink-2); font-feature-settings: "palt" 1; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 54px; padding: 0 24px; border-radius: 14px; font-weight: 800; font-size: 16px; text-decoration: none; border: 0; cursor: pointer; font-family: inherit; transition: transform .15s ease, background .15s ease; }
.btn:active { transform: scale(.97); }
.btn-ink { background: var(--ink); color: var(--bg); }
.btn-ink:hover { background: var(--hot); color: #fff; }
.btn-line { box-shadow: inset 0 0 0 2px var(--ink); color: var(--ink); background: transparent; }
.btn-line:hover { background: var(--bg-2); }
.hero-note { margin-top: 22px; font-size: 13px; color: var(--ink-3); }
.hero-note a { color: var(--ink); font-weight: 700; }

/* 遊ぶ面(右): パズルの色の面に、実物の Web版 */
/* 遊ぶ面(右): 元のスマホの絵(暗いベゼル・ノッチ)に戻した。6d5b29b4 で青い面に替えていた */
.stage { --c: #2f6bff; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.chips { display: flex; gap: 6px; max-width: 100%; overflow-x: auto; scrollbar-width: none; padding: 5px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); }
.chips::-webkit-scrollbar { display: none; }
@media (min-width: 1020px) { .chips { flex-wrap: wrap; justify-content: center; border-radius: 22px; } }
.chips button { flex: none; border: 0; border-radius: 999px; padding: 8px 14px; background: none; color: var(--ink-2); font: inherit; font-size: 13px; font-weight: 800; cursor: pointer; white-space: nowrap; }
.chips button:hover { background: var(--bg-2); }
.chips button[aria-selected="true"] { background: var(--ink); color: var(--bg); }
.player { position: relative; width: min(340px, 86vw); aspect-ratio: 390 / 780; border-radius: 44px; background: linear-gradient(145deg, #1f2937, #0b1020); box-shadow: 0 30px 80px rgb(15 23 42 / 0.35), inset 0 0 0 2px rgb(255 255 255 / 0.06); }
.player::before { content: ""; position: absolute; top: 18px; left: 50%; transform: translateX(-50%); width: 92px; height: 24px; border-radius: 999px; background: #000; z-index: 3; }

.player iframe { position: absolute; inset: 12px; width: calc(100% - 24px); height: calc(100% - 24px); border: 0; border-radius: 33px; background: #f6f7fb; }
.player-start { position: absolute; inset: 12px; z-index: 1; border: 0; padding: 0; border-radius: 33px; overflow: hidden; cursor: pointer; background: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px; }
.plate { width: min(78%, 380px); }
.plate img { width: 100%; }
.player-cta { display: inline-flex; align-items: center; gap: 10px; min-height: 50px; padding: 0 24px; border-radius: 14px; background: #0e0e10; color: #fff; font-weight: 800; font-size: 15px; }
.player-start:hover .player-cta { background: var(--c); }
.dot { width: 9px; height: 9px; border-radius: 50%; background: #3ddc84; }
.player[data-live] .player-start { display: none; }
.stage-cap { display: flex; gap: 12px; align-items: baseline; color: var(--ink-2); font-size: 14px; font-weight: 700; }
.stage-cap .mono { font-weight: 800; opacity: .8; }

/* ---------- 見出し ---------- */
.head { display: grid; gap: 16px; margin-bottom: 44px; }
@media (min-width: 900px) { .head { grid-template-columns: 1fr 1fr; align-items: end; } }
.head h2 { font-size: clamp(32px, 5vw, 52px); font-weight: 900; line-height: 1.15; letter-spacing: -0.04em; font-feature-settings: "palt" 1; }
.head p { color: var(--ink-2); max-width: 30em; }
.head-tight { grid-template-columns: 1fr !important; margin-bottom: 28px; }

/* ---------- 6つのパズル ---------- */
.shelf { padding: 96px 0; background: var(--bg-2); }
.tiles { display: grid; gap: 18px; }
@media (min-width: 680px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .tiles { grid-template-columns: repeat(3, 1fr); } }
.tile { --c: #2f6bff; display: flex; flex-direction: column; border-radius: var(--r); overflow: hidden; background: var(--bg); }
.tile:target { outline: 4px solid var(--c); outline-offset: 3px; }
.tile-stage { position: relative; background: var(--c); padding: 22px 22px 0; height: 270px; overflow: hidden; }
.tile-no { position: absolute; top: 16px; left: 20px; font-family: var(--mono); font-weight: 800; font-size: 14px; color: rgb(255 255 255 / .85); }
.tile-en { position: absolute; top: 16px; right: 20px; font-family: var(--mono); font-weight: 600; font-size: 11px; letter-spacing: .04em; color: rgb(255 255 255 / .85); text-transform: uppercase; }
.tile-plate { position: absolute; left: 50%; bottom: -40px; width: 230px; transform: translateX(-50%); background: #fff; border-radius: 16px 16px 0 0; padding: 12px 12px 52px; transition: transform .35s cubic-bezier(.2, .8, .2, 1); }
.tile:hover .tile-plate { transform: translateX(-50%) translateY(-10px); }
.tile-body { display: flex; flex-direction: column; gap: 10px; padding: 22px 22px 24px; flex: 1; }
.tile-body h3 { font-size: 26px; font-weight: 900; letter-spacing: -0.03em; line-height: 1.3; }
.tile-tag { color: var(--ink-2); font-size: 15px; }
.tile-rules { margin: 4px 0 0; padding: 12px 0 0; list-style: none; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink-2); line-height: 1.75; }
.tile-rules li { display: grid; grid-template-columns: 1.6em 1fr; }
.tile-rules li::before { content: counter(list-item); font-family: var(--mono); font-weight: 800; color: var(--c); }
.tile-status { font-size: 12px; color: var(--ink-3); }
.tile-act { margin-top: auto; padding-top: 8px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.tile-act .btn { min-height: 46px; padding: 0 18px; font-size: 14px; background: var(--ink); color: var(--bg); }
.tile-act .btn:hover { background: var(--c); color: #fff; }
.tile-act .here { border: 0; background: none; padding: 8px 4px; font: inherit; font-size: 14px; font-weight: 800; color: var(--ink); cursor: pointer; text-decoration: underline; text-underline-offset: .25em; text-decoration-thickness: 2px; text-decoration-color: var(--c); }
.tile-links { width: 100%; display: flex; gap: 12px; font-size: 12px; }
.tile-links a { color: var(--ink-3); }

/* ---------- ヒント ---------- */
.hint { padding: 104px 0; background: #0e0e10; color: #f2f2ef; }
.hint .head p { color: #b4b4bb; }
.steps { margin: 0; padding: 0; list-style: none; display: grid; gap: 28px; }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps figure { margin: 0 0 16px; border-radius: 18px; overflow: hidden; background: #fff; }
.step-k { display: flex; gap: 12px; align-items: baseline; font-size: 20px; font-weight: 900; letter-spacing: -0.02em; }
.step-k .mono { font-size: 14px; color: #ffd23f; font-weight: 800; }
.steps li > p:last-child { margin-top: 4px; color: #b4b4bb; font-size: 14px; }
.clip { margin: 64px 0 0; display: flex; gap: 36px; align-items: center; flex-wrap: wrap; }
.clip video { width: 260px; aspect-ratio: 390 / 844; object-fit: cover; border-radius: 22px; background: #f6f7fb; }
.clip figcaption { max-width: 26em; font-size: 14px; color: #b4b4bb; display: grid; gap: 8px; }
.clip figcaption strong { color: #f2f2ef; font-size: clamp(24px, 3vw, 34px); font-weight: 900; letter-spacing: -0.03em; line-height: 1.2; }
.clip .mono { color: #ffd23f; font-weight: 800; }

/* ---------- アプリ ---------- */
.app { padding: 104px 0; }
.app-in { display: grid; gap: 48px; }
@media (min-width: 1020px) { .app-in { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 72px; align-items: center; } }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.side { padding: 20px; border-radius: 18px; background: var(--bg-2); }
.side-app { background: var(--ink); color: var(--bg); }
.side-k { font-family: var(--mono); font-weight: 800; font-size: 13px; letter-spacing: .02em; margin-bottom: 10px; }
.side ul { margin: 0; padding: 0; list-style: none; font-size: 14px; line-height: 1.7; }
.side li { position: relative; padding-left: 20px; margin-top: 8px; }
.side li::before { content: ""; position: absolute; left: 0; top: .55em; width: 9px; height: 9px; border-radius: 2px; background: currentColor; opacity: .45; }
.side-app li::before { background: var(--hot); opacity: 1; }
.store { margin-top: 16px; font-size: 13px; color: var(--ink-2); display: flex; gap: 12px; align-items: baseline; flex-wrap: wrap; }
.store .mono { font-size: 11px; font-weight: 800; padding: 3px 8px; border-radius: 6px; background: var(--bg-2); color: var(--ink); }
.app-shots { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.app-shots figure { margin: 0; }
.app-shots img { border-radius: 20px; outline: 1px solid var(--line); }
.app-shots figcaption { margin-top: 10px; font-size: 13px; font-weight: 800; }

/* ---------- フッター ---------- */
.foot { border-top: 1px solid var(--line); padding: 36px 0 calc(44px + env(safe-area-inset-bottom)); }
.foot-in { display: grid; gap: 14px; }
@media (min-width: 900px) { .foot-in { grid-template-columns: auto 1fr auto; gap: 40px; align-items: center; } }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13px; }
.foot-links a, .foot-copy a { color: var(--ink-2); }
.foot-copy { font-size: 12px; color: var(--ink-3); }

@media (max-width: 600px) {
  .wrap { padding: 0 18px; }
  .nav-in { height: 64px; }
  .nav-links a { padding: 6px 10px; font-size: 13px; }
  .hero { padding: 8px 0 64px; }
  .shelf, .hint, .app { padding: 64px 0; }
  .split { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
@media (max-width: 360px) { .nav-links { gap: 0; } .nav-links a { padding: 6px 7px; } .logo-word { font-size: 20px; } }
