@charset "UTF-8";
/* ============================================================
   たんけんず（仮） — 見た目の決めごと
   トークンは :root の1か所だけ。生の値をこの下に書かない。
   ============================================================ */

:root {
  /* --- 書体 --- */
  --font-ui: "Hiragino Kaku Gothic ProN", "Yu Gothic Medium", "Noto Sans JP", Meiryo, system-ui, sans-serif;
  --font-display: "Hiragino Maru Gothic ProN", "Yu Gothic Medium", "Noto Sans JP", Meiryo, system-ui, sans-serif;

  /* --- 文字の大きさ（このスケール以外を使わない） --- */
  --fs-12: 12px; --fs-14: 14px; --fs-16: 16px; --fs-18: 18px;
  --fs-20: 20px; --fs-24: 24px; --fs-30: 30px; --fs-36: 36px;
  --fs-48: 48px; --fs-60: 60px;

  /* --- すき間（8の倍数・微調整だけ4） --- */
  --sp-4: 4px; --sp-8: 8px; --sp-12: 12px; --sp-16: 16px;
  --sp-24: 24px; --sp-32: 32px; --sp-48: 48px; --sp-64: 64px;

  /* --- 色 --- */
  --forest-900: #0E2118;
  --forest-800: #16311F;
  --forest-700: #1E4434;
  --forest-500: #2F6B51;
  --forest-300: #6FA98B;
  --amber-700: #8A5F22;
  --amber-600: #B7833B;
  --amber-400: #E0A94F;
  --amber-200: #F2D9A4;
  --amber-100: #F6E8CE;
  --paper: #FAF6EE;
  --paper-2: #F1EADC;
  --paper-3: #E4DAC6;
  --ink: #16241D;
  --ink-2: #4A5A52;
  --ink-3: #74827B;
  --sky-500: #3B7EA1;
  --berry-600: #A8465C;

  /* 役わり */
  --bg-app: var(--forest-900);
  --bg-card: var(--paper);
  --text-on-dark: rgba(255, 255, 255, .92);
  --text-on-dark-2: rgba(255, 255, 255, .68);
  --line-soft: rgba(22, 36, 29, .12);

  /* --- 角の丸み --- */
  --r-6: 6px; --r-12: 12px; --r-18: 18px; --r-28: 28px; --r-full: 9999px;

  /* --- 影（純黒を使わない） --- */
  --sh-1: 0 1px 2px rgba(14, 33, 24, .10);
  --sh-2: 0 4px 12px rgba(14, 33, 24, .14);
  --sh-3: 0 12px 28px rgba(14, 33, 24, .20);
  --sh-4: 0 24px 60px rgba(14, 33, 24, .34);

  /* --- 動き --- */
  --t-micro: 90ms;
  --t-comp: 220ms;
  --t-scene: 420ms;
  --ease-in-fast: cubic-bezier(.4, 0, 1, 1);
  --ease-out-soft: cubic-bezier(.16, .84, .44, 1);
}

* { box-sizing: border-box; }

/* <picture> はレイアウトに出さない（中の img が そのまま並びの一員になる） */
picture { display: contents; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  overscroll-behavior: none;
}

body {
  background:
    radial-gradient(90% 60% at 50% 0%, rgba(47, 107, 81, .30), transparent 62%),
    linear-gradient(180deg, var(--forest-800), var(--forest-900) 70%);
  background-attachment: fixed;
  font-family: var(--font-ui);
  font-size: var(--fs-16);
  line-height: 1.7;
  letter-spacing: .02em;
  font-feature-settings: "palt" 1;
  color: var(--ink);
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

button, input, textarea, select { font: inherit; letter-spacing: inherit; }

:focus-visible {
  outline: 3px solid var(--amber-400);
  outline-offset: 2px;
  border-radius: var(--r-6);
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ============================================================
   共通の部品
   ============================================================ */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--sp-8);
  min-height: 52px;
  padding: 0 var(--sp-24);
  border: 0;
  border-radius: var(--r-full);
  font-family: var(--font-display);
  font-size: var(--fs-18);
  font-weight: 700;
  cursor: pointer;
  transition: transform var(--t-micro) var(--ease-out-soft),
              box-shadow var(--t-micro) var(--ease-out-soft),
              background-color var(--t-micro) linear;
}
.btn:active { transform: scale(.97); }

.btn--primary {
  background: linear-gradient(180deg, var(--amber-400), var(--amber-600));
  color: #2A1B04;
  box-shadow: var(--sh-2), inset 0 1px 0 rgba(255, 255, 255, .5);
}
.btn--primary:hover { box-shadow: var(--sh-3), inset 0 1px 0 rgba(255, 255, 255, .5); }

.btn--ghost {
  background: transparent;
  color: var(--forest-700);
  border: 2px solid var(--paper-3);
}
.btn--ghost:hover { border-color: var(--forest-300); }

.btn--onDark {
  background: rgba(255, 255, 255, .10);
  color: var(--text-on-dark);
  border: 1.5px solid rgba(255, 255, 255, .22);
}
.btn--onDark:hover { background: rgba(255, 255, 255, .18); }

.btn--sm { min-height: 44px; font-size: var(--fs-16); padding: 0 var(--sp-16); }
.btn[disabled] { opacity: .45; cursor: not-allowed; }

/* ============================================================
   画面1: 入口（園えらび）
   ============================================================ */

.screen { display: none; }
.screen.is-on { display: block; }

/* スマホで見る画面。PCで開いた時は 中央に立てて置く */
.gate {
  min-height: 100dvh;
  max-width: 560px;
  margin-inline: auto;
  padding: calc(env(safe-area-inset-top) + var(--sp-32)) var(--sp-24) calc(env(safe-area-inset-bottom) + var(--sp-32));
  background:
    radial-gradient(120% 70% at 50% 0%, rgba(47, 107, 81, .55), transparent 62%),
    linear-gradient(180deg, var(--forest-800), var(--forest-900) 70%);
  color: var(--text-on-dark);
  display: flex; flex-direction: column; gap: var(--sp-24);
}

.gate__hero {
  position: relative;
  border-radius: var(--r-18) var(--r-18) var(--r-28) var(--r-28);
  overflow: hidden;
  min-height: 224px;
  margin: calc(var(--sp-24) * -1) calc(var(--sp-24) * -1) 0;
  display: grid; place-items: center;
  background: var(--forest-700);
  box-shadow: var(--sh-4);
}
.gate__hero img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
}
.gate__hero::after {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(70% 60% at 50% 58%, rgba(14, 33, 24, .58), transparent 72%),
    linear-gradient(180deg, rgba(14, 33, 24, .22), rgba(14, 33, 24, .66));
}
.gate__title {
  position: relative; z-index: 1; text-align: center;
  font-family: var(--font-display);
  margin: 0; padding: var(--sp-24);
}
.gate__title b {
  display: block;
  font-size: var(--fs-36);
  line-height: 1.3;
  letter-spacing: .04em;
  text-shadow: 0 2px 12px rgba(14, 33, 24, .8);
}
.gate__title small {
  display: block; margin-top: var(--sp-8);
  font-size: var(--fs-14); font-weight: 400;
  color: var(--text-on-dark-2);
  letter-spacing: .08em;
}

.gate h2 {
  font-family: var(--font-display);
  font-size: var(--fs-20);
  margin: 0 0 calc(var(--sp-8) * -1);
}
.gate p.lead {
  margin: 0; color: var(--text-on-dark-2); font-size: var(--fs-14);
}

.zooList { display: grid; gap: var(--sp-12); }

.zooCard {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  align-items: center;
  gap: var(--sp-16);
  width: 100%;
  padding: var(--sp-16);
  text-align: left;
  border: 2px solid rgba(255, 255, 255, .14);
  border-radius: var(--r-18);
  background: rgba(255, 255, 255, .07);
  color: var(--text-on-dark);
  cursor: pointer;
  transition: transform var(--t-micro) var(--ease-out-soft), border-color var(--t-micro) linear, background-color var(--t-micro) linear;
}
.zooCard { box-shadow: var(--sh-2); }
.zooCard:hover { background: rgba(255, 255, 255, .13); border-color: var(--amber-400); }
.zooCard:active { transform: scale(.98); }
.zooCard__mark {
  width: 64px; height: 64px; border-radius: var(--r-full);
  display: grid; place-items: center;
  background: linear-gradient(160deg, var(--forest-500), var(--forest-700));
  border: 2px solid rgba(255, 255, 255, .18);
  font-family: var(--font-display); font-size: var(--fs-24); font-weight: 700;
  color: var(--amber-200);
}
.zooCard__name { font-family: var(--font-display); font-size: var(--fs-20); font-weight: 700; }
.zooCard__meta { font-size: var(--fs-14); color: var(--text-on-dark-2); }
.zooCard__go {
  flex: 0 0 auto;
  width: 36px; height: 36px; border-radius: var(--r-full);
  display: grid; place-items: center;
  background: var(--amber-600); color: #2A1B04;
  font-size: var(--fs-20); font-weight: 700; line-height: 1;
}

.deviceRow {
  display: flex; align-items: center; gap: var(--sp-12); flex-wrap: wrap;
  padding: var(--sp-16);
  border-radius: var(--r-18);
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .12);
}
.deviceRow label { font-size: var(--fs-16); font-weight: 700; color: var(--text-on-dark); display: flex; align-items: center; }
#deviceHelp { font-size: var(--fs-14); color: rgba(255, 255, 255, .62); }

/* 手順の番号（園が先か ばんごうが先か 迷わせない） */
.stepNo {
  display: inline-grid; place-items: center;
  width: 26px; height: 26px; margin-right: var(--sp-8);
  border-radius: var(--r-full);
  background: var(--amber-600); color: #2A1B04;
  font-family: var(--font-display); font-size: var(--fs-14); font-weight: 700;
  vertical-align: 2px;
}
.deviceRow select {
  min-height: 44px; padding: 0 var(--sp-12);
  border-radius: var(--r-12);
  border: 1.5px solid rgba(255, 255, 255, .24);
  background: rgba(14, 33, 24, .6);
  color: var(--text-on-dark);
  font-size: var(--fs-16);
}

.gate__note {
  font-size: var(--fs-14);
  color: rgba(255, 255, 255, .62);
  line-height: 1.8;
  margin: 0;
}

/* ============================================================
   画面2: たんけん（浮かぶ玉）
   ============================================================ */

.explore {
  position: fixed; inset: 0;
  max-width: 560px;
  margin-inline: auto;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .06);
  display: flex; flex-direction: column;
  background:
    radial-gradient(90% 60% at 20% 0%, rgba(47, 107, 81, .5), transparent 60%),
    radial-gradient(80% 50% at 90% 100%, rgba(184, 131, 59, .22), transparent 60%),
    linear-gradient(180deg, var(--forest-800), var(--forest-900));
  color: var(--text-on-dark);
  overflow: hidden;
}
.explore__bg {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; opacity: .20; pointer-events: none;
  filter: saturate(.85);
}

.topbar {
  position: relative; z-index: 3;
  flex: 0 0 auto;
  display: flex; align-items: center; gap: var(--sp-12);
  padding: calc(env(safe-area-inset-top) + var(--sp-12)) var(--sp-16) var(--sp-12);
}
.topbar__zoo {
  flex: 1 1 auto; min-width: 0;
  display: flex; flex-direction: column;
}
.topbar__zoo b {
  font-family: var(--font-display); font-size: var(--fs-18); font-weight: 700;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.topbar__zoo span { font-size: var(--fs-12); color: var(--text-on-dark-2); }
.iconBtn {
  flex: 0 0 auto;
  min-width: 44px; min-height: 44px;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 0 var(--sp-12);
  border-radius: var(--r-full);
  border: 1.5px solid rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .08);
  color: var(--text-on-dark);
  font-size: var(--fs-14); font-weight: 700;
  cursor: pointer;
}
.iconBtn:hover { background: rgba(255, 255, 255, .16); }
.iconBtn svg { width: 20px; height: 20px; }

.field {
  position: relative; z-index: 2;
  flex: 1 1 auto;
  touch-action: manipulation;
}

.ball {
  position: absolute;
  left: 0; top: 0;
  width: var(--d); height: var(--d);
  padding: 0;
  border: 0;
  border-radius: var(--r-full);
  background: transparent;
  cursor: pointer;
  will-change: transform;
  -webkit-tap-highlight-color: transparent;
}
.ball__skin {
  position: absolute; inset: 0;
  border-radius: var(--r-full);
  background:
    radial-gradient(120% 120% at 30% 22%, rgba(255, 255, 255, .55), rgba(255, 255, 255, .06) 42%, rgba(255, 255, 255, 0) 60%),
    radial-gradient(90% 90% at 70% 80%, var(--ball-b), var(--ball-a));
  box-shadow:
    var(--sh-3),
    inset 0 0 0 1.5px rgba(255, 255, 255, .30),
    inset 0 -10px 22px rgba(14, 33, 24, .30);
  transition: transform var(--t-comp) var(--ease-out-soft), box-shadow var(--t-comp) var(--ease-out-soft);
}
.ball img {
  position: absolute; left: 50%; top: 46%;
  width: 74%; height: 74%;
  transform: translate(-50%, -50%);
  object-fit: contain;
  filter: drop-shadow(0 3px 6px rgba(14, 33, 24, .35));
  pointer-events: none;
}
.ball__fallback {
  position: absolute; left: 50%; top: 46%;
  transform: translate(-50%, -50%);
  font-size: calc(var(--d) * .40);
  line-height: 1;
  pointer-events: none;
}
.ball__name {
  position: absolute; left: 50%; bottom: 8%;
  transform: translateX(-50%);
  width: max-content; max-width: 168px;
  padding: 2px 10px;
  border-radius: var(--r-full);
  background: rgba(14, 33, 24, .82);
  color: #fff;
  font-size: var(--fs-12);
  font-weight: 700;
  letter-spacing: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  pointer-events: none;
}
.ball__pips {
  position: absolute; left: 50%; top: 7%;
  transform: translateX(-50%);
  display: flex; gap: 4px;
  pointer-events: none;
}
.ball__pip {
  width: 8px; height: 8px; border-radius: var(--r-full);
  background: rgba(255, 255, 255, .28);
  box-shadow: inset 0 0 0 1px rgba(14, 33, 24, .25);
}
.ball__pip.is-on { background: var(--amber-400); box-shadow: 0 0 8px var(--amber-400); }
.ball.is-done .ball__skin {
  box-shadow:
    var(--sh-3),
    inset 0 0 0 2.5px var(--amber-400),
    inset 0 -10px 22px rgba(14, 33, 24, .30),
    0 0 22px rgba(224, 169, 79, .45);
}
.ball:active .ball__skin { transform: scale(.93); }

/* 下の帯（スタンプ） */
.dock {
  position: relative; z-index: 3;
  flex: 0 0 auto;
  display: flex; align-items: center; gap: var(--sp-12);
  padding: var(--sp-12) var(--sp-16) calc(env(safe-area-inset-bottom) + var(--sp-12));
  background: linear-gradient(180deg, rgba(14, 33, 24, 0), rgba(14, 33, 24, .82) 38%);
}
.dock__btn {
  flex: 1 1 auto;
  display: flex; align-items: center; gap: var(--sp-12);
  min-height: 60px;
  padding: var(--sp-8) var(--sp-16);
  border-radius: var(--r-18);
  border: 1.5px solid rgba(255, 255, 255, .18);
  background: rgba(255, 255, 255, .09);
  color: var(--text-on-dark);
  cursor: pointer;
  text-align: left;
}
.dock__btn:hover { background: rgba(255, 255, 255, .16); }
.dock__count {
  font-family: var(--font-display);
  font-size: var(--fs-30); font-weight: 700; line-height: 1;
  color: var(--amber-400);
  font-variant-numeric: tabular-nums;
}
.dock__count i { font-size: var(--fs-16); font-style: normal; color: var(--text-on-dark-2); }
.dock__label { font-size: var(--fs-14); line-height: 1.4; }
.dock__label b { display: block; font-size: var(--fs-16); font-family: var(--font-display); }

.meter { height: 6px; border-radius: var(--r-full); background: rgba(255, 255, 255, .16); overflow: hidden; margin-top: 6px; }
.meter i { display: block; height: 100%; background: linear-gradient(90deg, var(--amber-600), var(--amber-400)); transition: width var(--t-scene) var(--ease-out-soft); }

/* ============================================================
   シート（動物をひらいた時）
   ============================================================ */

.sheetWrap {
  position: fixed; inset: 0; z-index: 20;
  display: none;
}
.sheetWrap.is-on { display: block; }
.sheetWrap__scrim {
  position: absolute; inset: 0;
  background: rgba(8, 20, 14, .62);
  backdrop-filter: blur(3px);
  animation: fadeIn var(--t-comp) var(--ease-out-soft);
}
@keyframes fadeIn { from { opacity: 0 } to { opacity: 1 } }

.sheet {
  position: absolute; left: 0; right: 0; bottom: 0;
  max-width: 560px; margin-inline: auto;
  max-height: 92dvh;
  display: flex; flex-direction: column;
  background: var(--bg-card);
  border-radius: var(--r-28) var(--r-28) 0 0;
  box-shadow: var(--sh-4);
  animation: slideUp var(--t-scene) var(--ease-out-soft);
  overflow: hidden;
}
@keyframes slideUp { from { transform: translateY(14%); opacity: .4 } to { transform: none; opacity: 1 } }

.sheet__head {
  position: relative;
  flex: 0 0 auto;
  padding: var(--sp-16) var(--sp-16) var(--sp-12);
  background: linear-gradient(180deg, var(--amber-100), var(--paper));
  border-bottom: 1px solid var(--line-soft);
  display: grid;
  grid-template-columns: 76px 1fr 44px;
  align-items: center;
  gap: var(--sp-12);
}
.sheet__thumb {
  width: 76px; height: 76px; border-radius: var(--r-full);
  background: radial-gradient(120% 120% at 30% 22%, #fff, var(--paper-2));
  box-shadow: var(--sh-1), inset 0 0 0 2px var(--amber-200);
  display: grid; place-items: center; overflow: hidden;
}
.sheet__thumb img { width: 84%; height: 84%; object-fit: contain; }
.sheet__thumb span { font-size: var(--fs-36); }
.sheet__name { font-family: var(--font-display); font-size: var(--fs-24); font-weight: 700; margin: 0; line-height: 1.35; }
.sheet__kana { font-size: var(--fs-12); color: var(--ink-3); margin: 0; letter-spacing: .08em; }
.sheet__close {
  width: 44px; height: 44px; border-radius: var(--r-full);
  border: 0; background: rgba(22, 36, 29, .08); color: var(--ink);
  font-size: var(--fs-20); cursor: pointer;
}
.sheet__close:hover { background: rgba(22, 36, 29, .16); }

.tabs {
  flex: 0 0 auto;
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-4);
  padding: var(--sp-8) var(--sp-12) 0;
  background: var(--bg-card);
}
.tab {
  min-height: 48px;
  border: 0;
  border-radius: var(--r-12) var(--r-12) 0 0;
  background: var(--paper-2);
  color: var(--ink-2);
  font-family: var(--font-display);
  font-size: var(--fs-14); font-weight: 700;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  border-bottom: 3px solid transparent;
}
.tab.is-on { background: var(--bg-card); color: var(--forest-700); border-bottom-color: var(--amber-600); }
.tab__dot { width: 8px; height: 8px; border-radius: var(--r-full); background: var(--paper-3); }
.tab.is-cleared .tab__dot { background: var(--amber-600); }

.sheet__body {
  flex: 1 1 auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: var(--sp-16) var(--sp-16) calc(env(safe-area-inset-bottom) + var(--sp-32));
}
.pane { display: none; }
.pane.is-on { display: block; }

/* 映像の置き場所（本番はここに映像が入る） */
.videoSlot {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--r-18);
  overflow: hidden;
  background: linear-gradient(160deg, var(--forest-700), var(--forest-900));
  box-shadow: var(--sh-2);
  margin-bottom: var(--sp-24);
  display: grid; place-items: center;
}
.videoSlot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.videoSlot::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(14, 33, 24, .18), rgba(14, 33, 24, .68));
}
.videoSlot__inner { position: relative; z-index: 1; text-align: center; color: var(--text-on-dark); padding: var(--sp-16); }
.videoSlot__play {
  width: 58px; height: 58px; margin: 0 auto var(--sp-8);
  border-radius: var(--r-full);
  background: rgba(255, 255, 255, .16);
  border: 2px solid rgba(255, 255, 255, .55);
  display: grid; place-items: center;
}
.videoSlot__play svg { width: 22px; height: 22px; margin-left: 3px; }
.videoSlot__label { font-family: var(--font-display); font-size: var(--fs-14); font-weight: 700; }
.videoSlot__note { font-size: var(--fs-12); color: var(--text-on-dark-2); margin-top: 2px; }

/* クイズ */
.qCard { margin-bottom: var(--sp-24); }
.qCard__no {
  display: inline-block;
  font-size: var(--fs-12); font-weight: 700; letter-spacing: .1em;
  color: var(--amber-700);
  margin-bottom: var(--sp-4);
}
.qCard__q {
  font-family: var(--font-display);
  font-size: var(--fs-18); font-weight: 700; line-height: 1.6;
  margin: 0 0 var(--sp-12);
  max-width: 38em;
}
.choices { display: grid; gap: var(--sp-8); }
.choice {
  display: flex; align-items: center; gap: var(--sp-12);
  min-height: 56px;
  padding: var(--sp-8) var(--sp-16);
  border-radius: var(--r-12);
  border: 2px solid var(--paper-3);
  background: #fff;
  color: var(--ink);
  font-size: var(--fs-16);
  text-align: left;
  cursor: pointer;
  transition: transform var(--t-micro) var(--ease-out-soft), border-color var(--t-micro) linear, background-color var(--t-micro) linear;
}
.choice:hover { border-color: var(--forest-300); }
.choice:active { transform: scale(.98); }
.choice__key {
  flex: 0 0 auto;
  width: 30px; height: 30px; border-radius: var(--r-full);
  display: grid; place-items: center;
  background: var(--paper-2); color: var(--ink-2);
  font-family: var(--font-display); font-weight: 700; font-size: var(--fs-14);
}
.choice.is-right { border-color: var(--forest-500); background: #EEF7F1; }
.choice.is-right .choice__key { background: var(--forest-500); color: #fff; }
.choice.is-wrong { border-color: var(--berry-600); background: #FBEEF1; }
.choice.is-wrong .choice__key { background: var(--berry-600); color: #fff; }
.choice[disabled] { cursor: default; opacity: 1; }

.verdict {
  margin-top: var(--sp-12);
  padding: var(--sp-12) var(--sp-16);
  border-radius: var(--r-12);
  background: var(--paper-2);
  border-left: 4px solid var(--forest-500);
  font-size: var(--fs-14);
  line-height: 1.8;
  max-width: 38em;
}
.verdict b { font-family: var(--font-display); display: block; margin-bottom: 2px; }
.verdict.is-wrong { border-left-color: var(--berry-600); }
.verdict a { color: var(--amber-700); word-break: break-all; font-size: var(--fs-12); }

/* ？カード */
.hatenaCard {
  position: relative;
  border-radius: var(--r-18);
  padding: var(--sp-24) var(--sp-16) var(--sp-16);
  background:
    radial-gradient(120% 90% at 80% 0%, rgba(224, 169, 79, .28), transparent 55%),
    linear-gradient(165deg, var(--forest-700), var(--forest-800));
  color: var(--text-on-dark);
  box-shadow: var(--sh-2);
  overflow: hidden;
}
.hatenaCard::before {
  content: "?";
  position: absolute; right: 10px; bottom: -34px;
  font-family: var(--font-display);
  font-size: 150px; font-weight: 700; line-height: 1;
  color: rgba(224, 169, 79, .12);
}
.hatenaCard__label {
  position: relative;
  display: inline-block;
  font-size: var(--fs-12); font-weight: 700; letter-spacing: .12em;
  color: var(--amber-200);
  margin-bottom: var(--sp-8);
}
.hatenaCard__text {
  position: relative;
  font-family: var(--font-display);
  font-size: var(--fs-20); font-weight: 700; line-height: 1.7;
  margin: 0 0 var(--sp-12);
  max-width: 38em;
}
.hatenaCard__detail {
  position: relative;
  font-size: var(--fs-14); line-height: 1.85;
  color: var(--text-on-dark-2);
  margin: 0;
  max-width: 38em;
}
.hatenaCard__src { position: relative; display: block; margin-top: var(--sp-16); font-size: var(--fs-14); color: rgba(255, 255, 255, .55); }
.hatenaCard__src a {
  color: var(--amber-200);
  display: inline-flex; align-items: center; gap: 5px;
  min-height: 32px; padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, .28); border-radius: var(--r-full);
  text-decoration: none;
}
.hatenaCard__src a:hover { background: rgba(255, 255, 255, .12); }

.myHatena { margin-top: var(--sp-24); }
.myHatena h4 {
  font-family: var(--font-display); font-size: var(--fs-18); margin: 0 0 var(--sp-4);
}
.myHatena p.hint { margin: 0 0 var(--sp-12); font-size: var(--fs-14); color: var(--ink-2); max-width: 38em; }
.myHatena textarea {
  width: 100%;
  min-height: 104px;
  padding: var(--sp-12);
  border-radius: var(--r-12);
  border: 2px solid var(--paper-3);
  background: #fff;
  color: var(--ink);
  font-size: var(--fs-16);
  line-height: 1.7;
  resize: vertical;
}
.myHatena textarea:focus { border-color: var(--forest-300); }
.chips { display: flex; flex-wrap: wrap; gap: var(--sp-8); margin-bottom: var(--sp-12); }
.chip {
  min-height: 40px; padding: 0 var(--sp-12);
  border-radius: var(--r-full);
  border: 1.5px solid var(--paper-3);
  background: var(--paper-2);
  color: var(--ink-2);
  font-size: var(--fs-14);
  cursor: pointer;
}
.chip:hover { border-color: var(--amber-600); color: var(--amber-700); }
.formRow { display: flex; gap: var(--sp-12); align-items: center; margin-top: var(--sp-12); flex-wrap: wrap; }

/* しゃしん */
.shot {
  border-radius: var(--r-18);
  border: 2px dashed var(--paper-3);
  background: var(--paper-2);
  padding: var(--sp-24) var(--sp-16);
  text-align: center;
}
.shot h4 { font-family: var(--font-display); font-size: var(--fs-18); margin: 0 0 var(--sp-4); }
.shot p { margin: 0 auto var(--sp-16); font-size: var(--fs-14); color: var(--ink-2); max-width: 32em; }
.shot__preview {
  width: 100%; max-width: 340px;
  aspect-ratio: 4 / 3;
  margin: 0 auto var(--sp-16);
  border-radius: var(--r-12);
  overflow: hidden;
  background: var(--paper-3);
  display: none;
  box-shadow: var(--sh-2);
}
.shot__preview.is-on { display: block; }
.shot__preview img { width: 100%; height: 100%; object-fit: cover; display: block; }
.shot__status { margin-top: var(--sp-12); font-size: var(--fs-14); font-weight: 700; }
.shot__status.ok { color: var(--forest-500); }
.shot__status.ng { color: var(--berry-600); }
.shot__status.wait { color: var(--amber-700); }
.shotList { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-8); margin-top: var(--sp-16); }
.shotList img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--r-12); box-shadow: var(--sh-1); }

/* ============================================================
   スタンプ帳
   ============================================================ */

.book {
  position: fixed; inset: 0; z-index: 25;
  display: none;
  flex-direction: column;
  background: linear-gradient(180deg, var(--paper), var(--paper-2));
}
.book.is-on { display: flex; }
.book { max-width: 560px; margin-inline: auto; }
.book__head {
  flex: 0 0 auto;
  display: flex; align-items: center; gap: var(--sp-12);
  padding: calc(env(safe-area-inset-top) + var(--sp-16)) var(--sp-16) var(--sp-12);
  border-bottom: 1px solid var(--line-soft);
}
.book__head h2 { font-family: var(--font-display); font-size: var(--fs-24); margin: 0; flex: 1; }
.book__body { flex: 1 1 auto; overflow-y: auto; padding: var(--sp-16) var(--sp-16) calc(env(safe-area-inset-bottom) + var(--sp-32)); }
.book__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: var(--sp-12); }
.stamp {
  aspect-ratio: 1;
  border-radius: var(--r-18);
  background: #fff;
  border: 2px solid var(--paper-3);
  display: grid; place-items: center;
  position: relative;
  overflow: hidden;
  box-shadow: var(--sh-1);
}
.stamp__face { width: 78%; height: 78%; object-fit: contain; }
.stamp__kind {
  position: absolute; right: 5px; top: 5px;
  width: 30%; height: 30%; object-fit: contain;
  filter: drop-shadow(0 1px 2px rgba(14, 33, 24, .3));
}
.stamp__ghost { font-size: var(--fs-30); opacity: .18; filter: grayscale(1); }
.stamp__cap {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 3px 4px;
  font-size: 10.5px; text-align: center;
  background: rgba(250, 246, 238, .92);
  color: var(--ink-2);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.stamp.is-on { border-color: var(--amber-400); background: linear-gradient(160deg, #fff, var(--amber-100)); }
.book__section { margin-bottom: var(--sp-32); }
.book__section h3 { font-family: var(--font-display); font-size: var(--fs-18); margin: 0 0 var(--sp-12); display: flex; align-items: center; gap: var(--sp-8); }
.book__section h3 em { font-style: normal; font-size: var(--fs-14); color: var(--ink-3); font-weight: 400; }

/* ============================================================
   その他
   ============================================================ */

.toast {
  position: fixed; left: 50%; bottom: calc(env(safe-area-inset-bottom) + 96px);
  transform: translateX(-50%) translateY(12px);
  z-index: 40;
  max-width: min(92vw, 420px);
  padding: var(--sp-12) var(--sp-24);
  border-radius: var(--r-full);
  background: rgba(14, 33, 24, .94);
  color: #fff;
  font-family: var(--font-display); font-weight: 700; font-size: var(--fs-16);
  box-shadow: var(--sh-3);
  opacity: 0; pointer-events: none;
  transition: opacity var(--t-comp) var(--ease-out-soft), transform var(--t-comp) var(--ease-out-soft);
  text-align: center;
}
.toast.is-on { opacity: 1; transform: translateX(-50%) translateY(0); }

.burst {
  position: fixed; inset: 0; z-index: 35;
  pointer-events: none;
  display: grid; place-items: center;
  opacity: 0;
}
.burst.is-on { animation: burst 900ms var(--ease-out-soft); }
.burst img { width: min(72vw, 380px); }
@keyframes burst {
  0% { opacity: 0; transform: scale(.6) }
  25% { opacity: 1; transform: scale(1.02) }
  100% { opacity: 0; transform: scale(1.18) }
}

.offlineBar {
  position: fixed; left: 0; right: 0; top: 0; z-index: 50;
  padding: calc(env(safe-area-inset-top) + 6px) var(--sp-16) 6px;
  background: var(--amber-600); color: #2A1B04;
  font-size: var(--fs-14); font-weight: 700; text-align: center;
  display: none;
}
.offlineBar.is-on { display: block; }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
