/* 方向性: 謎解きカードと同じ、招待状のような紙もの。白い紙・水彩の丸・金の細線・筆記体と明朝 */
:root {
  --ink: #2f2724;
  --ink-soft: #857a74;
  --ink-faint: #b9aea7;
  --gold: #b48a52;
  --gold-soft: #e3d2b6;
  --blush: #f8e7e4;
  --blush-deep: #d79d97;
  --rose: #b0485b;
  --paper: #fffdfa;
  --paper-deep: #f6f1ea;
  --line: #ece4dc;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
[hidden] { display: none !important; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: "Shippori Mincho", "Hiragino Mincho ProN", "Yu Mincho", serif;
  line-height: 1.9;
  letter-spacing: .05em;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
  overflow-x: hidden;
}

/* 紙の質感（ごく薄いノイズ） */
body.paper::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  opacity: .35;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .55  0 0 0 0 .5  0 0 0 0 .45  0 0 0 .09 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* 四隅の水彩の丸。ゆっくり漂う */
.wc-layer { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.wc { position: absolute; pointer-events: none; mix-blend-mode: multiply; opacity: 0; animation: wc-in 1.6s var(--ease-out) forwards, drift 14s ease-in-out infinite alternate; }
.wc-pink   { top: -34px;  left: -40px;  width: 150px; animation-delay: .05s, 0s; }
.wc-blue   { top: -40px;  right: -34px; width: 128px; animation-delay: .2s, -3s; }
.wc-yellow { top: 74px;   right: -14px; width: 78px;  animation-delay: .3s, -5s; }
.wc-green  { bottom: -44px; left: -46px; width: 150px; animation-delay: .4s, -7s; }
.wc-purple { bottom: -46px; right: -46px; width: 170px; animation-delay: .6s, -11s; }
@keyframes wc-in { from { opacity: 0; transform: scale(.85); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes drift { from { translate: 0 0; rotate: 0deg; } to { translate: 6px -8px; rotate: 8deg; } }

main {
  position: relative;
  z-index: 1;
  max-width: 440px;
  margin: 0 auto;
  padding: 64px 24px 120px;
}

.reveal { opacity: 0; transform: translateY(14px); filter: blur(6px); animation: reveal .9s var(--ease-out) forwards; animation-delay: calc(var(--i, 0) * 90ms + 150ms); }
@keyframes reveal { to { opacity: 1; transform: none; filter: none; } }

.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: "Cormorant Garamond", serif;
  font-weight: 500;
  color: var(--gold);
  font-size: 12px;
  letter-spacing: .34em;
  text-transform: uppercase;
  margin: 0 0 6px;
}
.eyebrow::after { content: ""; flex: 0 0 42px; height: 1px; background: var(--gold-soft); }
.eyebrow.center { justify-content: center; }
.eyebrow.center::before { content: ""; flex: 0 0 42px; height: 1px; background: var(--gold-soft); }

.script {
  font-family: "Ms Madi", cursive;
  font-weight: 400;
  font-size: 58px;
  line-height: 1.15;
  margin: 0 0 18px;
  letter-spacing: 0;
}
.script.write { clip-path: inset(-20% 100% -20% 0); animation: write 1.6s cubic-bezier(.6, .05, .25, 1) .25s forwards; }
@keyframes write { to { clip-path: inset(-20% -5% -20% 0); } }

.lead { font-size: 14.5px; margin: 0 0 30px; }
.note { font-size: 12.5px; color: var(--ink-soft); letter-spacing: .06em; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }

/* ボタン（招待状の二重線） */
.btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  font: inherit;
  font-size: 15px;
  letter-spacing: .2em;
  text-decoration: none;
  padding: 16px 20px;
  margin: 0 0 14px;
  border: 0;
  border-radius: 0;
  background: var(--ink);
  color: #fff;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
  transition: transform .25s var(--ease-out), opacity .2s;
  box-shadow: 0 10px 24px -14px rgba(47, 39, 36, .55);
}
.btn::before { content: ""; position: absolute; inset: 4px; border: 1px solid rgba(255, 255, 255, .28); pointer-events: none; }
.btn:active { transform: scale(.985); }
.btn:disabled { opacity: .45; cursor: default; }
.btn-light { background: #fff; color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.btn-light::before { border-color: var(--line); }
.btn-danger { background: #fff; color: var(--rose); box-shadow: inset 0 0 0 1px var(--rose); }
.btn-danger::before { border-color: var(--blush); }
.btn svg { width: 20px; height: 20px; flex: none; }

.link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  text-decoration: none;
  font-size: 14px;
  letter-spacing: .14em;
  padding-bottom: 2px;
}
.link::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--ink); transform-origin: right; transition: transform .45s var(--ease-out); }
.link:hover::after { transform: scaleX(0); }

.msg { font-size: 13.5px; margin: 0 0 16px; min-height: 1.6em; letter-spacing: .06em; }
.msg.error { color: var(--rose); }

.ornament { display: flex; align-items: center; gap: 12px; margin: 30px 0 26px; color: var(--gold); }
.ornament::before, .ornament::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, transparent, var(--gold-soft)); }
.ornament::after { background: linear-gradient(90deg, var(--gold-soft), transparent); }
.ornament span { width: 6px; height: 6px; border: 1px solid var(--gold); transform: rotate(45deg); }

/* ---- カメラ ---- */
.shutter-wrap { display: grid; place-items: center; margin: 8px 0 30px; }
.shutter {
  position: relative;
  width: 188px;
  height: 188px;
  border-radius: 50%;
  border: 0;
  padding: 0;
  background: #fff;
  color: var(--ink);
  font: inherit;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  box-shadow: 0 0 0 1px var(--gold-soft), 0 0 0 9px #fff, 0 0 0 10px var(--gold-soft), 0 24px 40px -22px rgba(47, 39, 36, .5);
  display: grid;
  place-items: center;
  transition: transform .3s var(--ease-out);
}
.shutter::before {
  content: "";
  position: absolute;
  inset: 14px;
  border-radius: 50%;
  background: var(--blush);
  box-shadow: inset 0 0 0 1px var(--blush-deep);
  transition: transform .3s var(--ease-out);
}
.shutter:active { transform: scale(.96); }
.shutter:active::before { transform: scale(.94); }
.shutter-inner { position: relative; display: grid; justify-items: center; gap: 6px; }
.shutter svg { width: 46px; height: 46px; }
.shutter-label { font-size: 15px; letter-spacing: .3em; padding-left: .3em; }
.shutter-ring { position: absolute; inset: -22px; border-radius: 50%; border: 1px solid var(--gold-soft); opacity: 0; animation: ring 3.2s var(--ease-out) infinite; pointer-events: none; }
.shutter-ring.r2 { animation-delay: 1.6s; }
@keyframes ring { 0% { opacity: .9; transform: scale(.86); } 100% { opacity: 0; transform: scale(1.12); } }

/* 送信中の表示と送った写真の一覧は、出すものがあるときだけ場所を取る */
.status { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 28px; font-size: 13px; color: var(--ink-soft); letter-spacing: .08em; margin: -6px 0 14px; }
.status:empty { display: none; }
.sent-strip:empty { display: none; }
.status .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--gold); animation: blink 1.2s ease-in-out infinite; }
.status.done .dot { animation: none; background: #6f9b7e; }
.status.wait .dot { animation: none; background: var(--blush-deep); }
@keyframes blink { 50% { opacity: .2; } }

.sent-strip { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; margin: 0 0 20px; min-height: 0; }
.sent-item { position: relative; width: 58px; height: 58px; background: #fff; padding: 3px; box-shadow: 0 0 0 1px var(--line), 0 8px 16px -12px rgba(47, 39, 36, .5); animation: drop .6s var(--ease-out); }
.sent-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: opacity .4s; }
.sent-item.sending img { opacity: .55; }
.sent-item .mark { position: absolute; right: -6px; bottom: -6px; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: #fff; box-shadow: 0 0 0 1px var(--line); }
.sent-item .mark svg { width: 12px; height: 12px; }
.sent-item.sending .mark::after { content: ""; width: 10px; height: 10px; border: 1.5px solid var(--gold-soft); border-top-color: var(--gold); border-radius: 50%; animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes drop { from { opacity: 0; transform: translateY(-10px) scale(.9); } to { opacity: 1; transform: none; } }

/* 初回の名前の案内（下から出る小さなシート。後ろの「撮る」が見えたまま） */
.welcome { position: fixed; inset: 0; z-index: 20; display: flex; flex-direction: column; justify-content: flex-end; }
.welcome-backdrop { position: absolute; inset: 0; background: rgba(47, 39, 36, .18); animation: fade .4s ease; }
.welcome-sheet {
  position: relative;
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  background: var(--paper);
  padding: 26px 22px calc(20px + env(safe-area-inset-bottom));
  box-shadow: 0 -18px 40px -24px rgba(47, 39, 36, .45);
  border-top: 1px solid var(--gold-soft);
  animation: sheet-up .6s var(--ease-out);
}
@keyframes sheet-up { from { transform: translateY(100%); } }
.welcome-title { display: flex; justify-content: center; align-items: center; gap: 10px; margin: 4px 0 2px; font-size: 17px; letter-spacing: .1em; }
.welcome-sheet .note { margin: 0 0 16px; }
.welcome-sheet input {
  width: 100%;
  font: inherit;
  font-size: 16px;
  padding: 12px 14px;
  border: 0;
  border-bottom: 1px solid var(--ink);
  background: #fff;
  color: var(--ink);
  border-radius: 0;
  -webkit-appearance: none;
  appearance: none;
  outline: none;
  text-align: center;
}
.welcome-sheet input:focus { border-color: var(--gold); }
.welcome-sheet .msg { margin: 6px 0 6px; min-height: 1.2em; }
.welcome-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.welcome-actions .btn { margin: 0; padding: 15px 8px; font-size: 14px; letter-spacing: .14em; }

.see-links { display: flex; flex-direction: column; align-items: center; gap: 14px; margin: 6px 0 0; }

/* 名前（任意）: 普段は1行 */
.name-area { text-align: center; margin: 0 0 22px; }
.name-toggle, .name-change { font: inherit; background: none; border: 0; padding: 6px 4px; color: var(--ink); cursor: pointer; -webkit-tap-highlight-color: transparent; }
.name-toggle { display: inline-flex; align-items: center; gap: 10px; font-size: 13.5px; letter-spacing: .14em; border-bottom: 1px dashed var(--ink-faint); padding-bottom: 3px; }
.optional { font-size: 11px; color: var(--gold); border: 1px solid var(--gold-soft); padding: 0 8px; letter-spacing: .1em; line-height: 1.7; }
.name-set { display: inline-flex; align-items: baseline; gap: 10px; margin: 0; font-size: 15px; letter-spacing: .1em; }
.name-set .by { font-family: "Cormorant Garamond", serif; color: var(--gold); font-size: 13px; letter-spacing: .2em; }
.name-change { font-size: 12px; color: var(--ink-soft); text-decoration: underline; text-underline-offset: 3px; letter-spacing: .1em; }
.name-form { text-align: left; animation: drop .4s var(--ease-out); }
.name-form .note { display: block; margin: 0 0 6px; }
.name-row { display: flex; gap: 8px; align-items: stretch; }
.name-row .small-btn { flex: none; padding: 0 18px; }
.name-form #name-note { margin: 6px 0 0; color: var(--rose); }
.name-form input {
  flex: 1;
  min-width: 0;
  width: 100%;
  font: inherit;
  font-size: 16px; /* iOS で画面が拡大されない大きさ */
  padding: 12px 14px;
  border: 0;
  border-bottom: 1px solid var(--ink);
  background: rgba(255, 255, 255, .7);
  color: var(--ink);
  border-radius: 0;
  -webkit-appearance: none;
  appearance: none;
  outline: none;
  transition: background .3s, border-color .3s;
}
.name-form input:focus { background: #fff; border-color: var(--gold); }
.name-form input::placeholder { color: var(--ink-faint); }

.viewer-name { text-align: center; margin: 10px 0 0; min-height: 1.8em; font-size: 14px; letter-spacing: .12em; }
.viewer-name .by { font-family: "Cormorant Garamond", serif; color: var(--gold); font-size: 13px; letter-spacing: .2em; margin-right: 8px; }
.admin-tile .who { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 8px 5px; font-size: 11.5px; color: #fff; background: linear-gradient(transparent, rgba(0, 0, 0, .55)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: .06em; }

.file-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

/* ---- アルバム ---- */
.album-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 0 0 18px; }
.album-head .script { margin: 0; font-size: 48px; }
.count { font-size: 13px; color: var(--ink-soft); letter-spacing: .1em; white-space: nowrap; padding-bottom: 8px; }
.count b { font-family: "Cormorant Garamond", serif; font-weight: 500; font-size: 22px; color: var(--ink); letter-spacing: .02em; margin-right: 2px; }

.album-main { max-width: 960px; padding: 32px 12px 60px; }
.album-main > header { padding: 0 8px; }
.album-top { display: flex; align-items: center; justify-content: space-between; margin: 0 0 4px; }
.album-top .eyebrow { margin: 0; }
.back-link { display: inline-flex; align-items: center; gap: 6px; color: var(--ink); text-decoration: none; font-size: 13px; letter-spacing: .16em; padding: 6px 0 6px 10px; }

/* 表示形式（文字のタブ・金の下線）と絞り込み（スイッチ）。箱で囲まず、招待状の細い線でまとめる */
.album-tools { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin: 0 0 16px; border-bottom: 1px solid var(--line); }
.view-tabs { position: relative; display: flex; gap: 22px; }
.view-tabs button {
  font: inherit;
  font-size: 14px;
  letter-spacing: .22em;
  padding: 8px 0 11px;
  border: 0;
  background: none;
  color: var(--ink-faint);
  cursor: pointer;
  white-space: nowrap;
  transition: color .4s;
  -webkit-tap-highlight-color: transparent;
}
.view-tabs button[aria-pressed="true"] { color: var(--ink); }
.view-tabs button:hover { color: var(--ink-soft); }
.view-tabs button[aria-pressed="true"]:hover { color: var(--ink); }
.tab-ink { position: absolute; left: 0; bottom: -1px; height: 1.5px; width: 0; background: var(--gold); transition: transform .55s var(--ease-out), width .55s var(--ease-out); }

.mine-toggle { display: inline-flex; align-items: center; gap: 8px; padding: 0 0 11px; font-size: 12px; letter-spacing: .12em; color: var(--ink-soft); cursor: pointer; white-space: nowrap; -webkit-tap-highlight-color: transparent; }
.mine-toggle input { position: absolute; opacity: 0; pointer-events: none; }
.mine-toggle .track { position: relative; width: 30px; height: 17px; border-radius: 17px; border: 1px solid var(--gold-soft); background: #fff; transition: background .35s, border-color .35s; }
.mine-toggle .knob { position: absolute; top: 2px; left: 2px; width: 11px; height: 11px; border-radius: 50%; background: var(--gold-soft); transition: transform .35s var(--ease-out), background .35s; }
.mine-toggle input:checked + .track { background: var(--gold); border-color: var(--gold); }
.mine-toggle input:checked + .track .knob { transform: translateX(13px); background: #fff; }
.mine-toggle input:checked ~ * { color: var(--ink); }
.mine-toggle input:focus-visible + .track { outline: 2px solid var(--gold-soft); outline-offset: 2px; }

/* 並べて見る（正方形の一覧） */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(4, 1fr); gap: 6px; } }
@media (min-width: 900px) { .grid { grid-template-columns: repeat(5, 1fr); } }
.item { position: relative; }
.item.new { animation: tile-in .8s var(--ease-out); }
@keyframes tile-in { from { opacity: 0; transform: scale(.8); } to { opacity: 1; transform: none; } }
.item.gone { animation: tile-out .4s ease forwards; }
@keyframes tile-out { to { opacity: 0; transform: scale(.9); } }
.grid.only-mine .item:not(.mine) { display: none; }
.tile { position: relative; display: block; width: 100%; aspect-ratio: 1; background: var(--paper-deep); border: 0; padding: 0; cursor: pointer; overflow: hidden; -webkit-tap-highlight-color: transparent; }
.tile img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: 0; transition: opacity .5s, transform .5s var(--ease-out); }
.tile img.loaded { opacity: 1; }
.tile:active img { transform: scale(.97); }
.meta { display: none; }
/* 「自分」に絞った一覧では、右上から消せる */
.quick-del { display: none; position: absolute; top: 6px; right: 6px; width: 32px; height: 32px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .92); color: var(--rose); place-items: center; cursor: pointer; box-shadow: 0 2px 8px rgba(0, 0, 0, .15); }
.quick-del svg { width: 15px; height: 15px; }
.grid.only-mine:not(.feed) .quick-del { display: grid; }

/* 大きく見る（1列・縦横そのまま・名前つき） */
.grid.feed { grid-template-columns: minmax(0, 560px); justify-content: center; gap: 26px; }
.grid.feed .tile { aspect-ratio: var(--ar); background: #fff; padding: 6px; box-shadow: 0 0 0 1px var(--line), 0 16px 30px -22px rgba(47, 39, 36, .5); }
.grid.feed .tile img { object-fit: contain; }
.grid.feed .meta { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; min-height: 1.6em; margin: 10px 4px 0; font-size: 13.5px; letter-spacing: .1em; }
.meta .by { font-family: "Cormorant Garamond", serif; color: var(--gold); font-size: 12.5px; letter-spacing: .2em; margin-right: 8px; }
.meta-del { font: inherit; font-size: 12.5px; color: var(--rose); background: none; border: 0; padding: 4px 0; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; letter-spacing: .1em; }

.empty { text-align: center; padding: 60px 20px; color: var(--ink-soft); font-size: 14px; }

/* 1枚表示 */
.viewer { position: fixed; inset: 0; z-index: 10; background: rgba(255, 253, 250, .97); display: grid; grid-template-rows: auto 1fr auto; animation: fade .3s ease; }
@keyframes fade { from { opacity: 0; } }
.viewer-top { display: flex; justify-content: space-between; align-items: center; padding: calc(10px + env(safe-area-inset-top)) 12px 6px 18px; font-size: 12px; color: var(--ink-soft); letter-spacing: .12em; }
.icon-btn { width: 44px; height: 44px; display: grid; place-items: center; border: 0; background: none; color: var(--ink); cursor: pointer; -webkit-tap-highlight-color: transparent; }
.icon-btn svg { width: 22px; height: 22px; }
/* 名前は写真のすぐ下に */
.viewer-stage { position: relative; display: flex; flex-direction: column; justify-content: center; align-items: center; min-height: 0; overflow: hidden; touch-action: pan-y; padding: 0 10px; }
.viewer-stage img { max-width: 100%; max-height: calc(100% - 3em); min-height: 0; object-fit: contain; background: #fff; padding: 6px; box-shadow: 0 0 0 1px var(--line), 0 20px 40px -24px rgba(47, 39, 36, .5); transition: transform .3s var(--ease-out), opacity .3s; user-select: none; -webkit-user-drag: none; }
.viewer-stage .nav { position: absolute; top: 50%; transform: translateY(-50%); }
.viewer-stage .nav.prev { left: 2px; }
.viewer-stage .nav.next { right: 2px; }
@media (hover: none) { .viewer-stage .nav { display: none; } }
.viewer-bottom { display: flex; gap: 10px; padding: 12px 16px calc(14px + env(safe-area-inset-bottom)); max-width: 520px; width: 100%; margin: 0 auto; }
.viewer-bottom .btn { margin: 0; padding: 14px 10px; font-size: 13.5px; letter-spacing: .12em; }
.viewer-bottom .btn-danger { flex: 0 0 34%; }

/* ---- 管理 ---- */
.admin-main { max-width: 960px; padding: 40px 16px 80px; }
.panel { background: #fff; border: 1px solid var(--line); padding: 18px 18px 6px; margin: 0 0 18px; }
.panel h2 { font-size: 15px; font-weight: 600; letter-spacing: .14em; margin: 0 0 10px; }
.field { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 12px; font-size: 14px; }
.field label { min-width: 9em; }
.stepper { display: inline-flex; align-items: stretch; border: 1px solid var(--ink); }
.stepper button { width: 40px; border: 0; background: #fff; font: inherit; font-size: 18px; cursor: pointer; }
.stepper input { width: 64px; border: 0; border-left: 1px solid var(--line); border-right: 1px solid var(--line); text-align: center; font: inherit; font-size: 16px; padding: 8px 0; -moz-appearance: textfield; }
.stepper input::-webkit-inner-spin-button { -webkit-appearance: none; }
.small-btn { font: inherit; font-size: 13px; letter-spacing: .12em; padding: 9px 16px; border: 0; background: var(--ink); color: #fff; cursor: pointer; }
.small-btn.light { background: #fff; color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.seg { display: inline-flex; border: 1px solid var(--ink); }
.seg button { font: inherit; font-size: 13px; letter-spacing: .1em; padding: 9px 14px; border: 0; background: #fff; color: var(--ink); cursor: pointer; }
.seg button + button { border-left: 1px solid var(--ink); }
.seg button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.url-row { display: flex; gap: 8px; align-items: center; margin: 0 0 12px; }
.url-row code { flex: 1; min-width: 0; overflow-x: auto; white-space: nowrap; font-size: 12px; background: var(--paper-deep); padding: 9px 10px; font-family: ui-monospace, Menlo, monospace; letter-spacing: 0; }
.url-label { font-size: 13px; color: var(--ink-soft); margin: 0 0 4px; }
.admin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.admin-tile { position: relative; aspect-ratio: 1; background: var(--paper-deep); overflow: hidden; }
.admin-tile img { width: 100%; height: 100%; object-fit: cover; display: block; cursor: zoom-in; }
.admin-tile .del { position: absolute; top: 6px; right: 6px; width: 32px; height: 32px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .92); color: var(--rose); display: grid; place-items: center; cursor: pointer; box-shadow: 0 2px 8px rgba(0, 0, 0, .15); }
.admin-tile .del svg { width: 16px; height: 16px; }
.admin-tile.gone { opacity: .2; pointer-events: none; transition: opacity .3s; }

/* ---- 開けないとき ---- */
.blocked { text-align: center; padding-top: 30vh; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .reveal, .wc { opacity: 1; transform: none; filter: none; }
  .script.write { clip-path: none; }
}
