[hidden] { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.center { text-align: center; }
button.big, .btn.big { padding: 12px 20px; font-size: 1.05rem; }
.btn { display: inline-block; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-hover); }
.linkish { background: none; border: 0; color: var(--muted); text-decoration: underline; font-weight: 400; padding: 4px; }

.privacy { display: flex; gap: 14px; align-items: center; background: #ecfdf5; border: 1px solid #a7f3d0; color: #065f46; border-radius: 12px; padding: 12px 16px; }
.privacy b { display: block; }
.privacy-icon { font-size: 1.8rem; }
@media (prefers-color-scheme: dark) { .privacy { background: #0f2a22; border-color: #1f5f4a; color: #a7f3d0; } }

.drop { margin-top: 16px; border: 2px dashed var(--border); border-radius: 14px; padding: 32px 16px; text-align: center; transition: border-color .15s, background .15s; }
.drop.over { border-color: var(--accent); background: var(--accent-soft); }
.drop-icon { font-size: 2.6rem; }
.drop-btns { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin: 12px 0 6px; }
.notice { margin-top: 14px; }

.bar { height: 8px; background: var(--bg); border: 1px solid var(--border); border-radius: 99px; overflow: hidden; }
.bar > div { height: 100%; width: 0; background: var(--accent); transition: width .2s; }
.big-bar { height: 14px; margin: 16px 0 8px; }

.summary { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.sum-big { font-size: clamp(1.6rem, 5vw, 2.4rem); font-weight: 800; letter-spacing: -.02em; line-height: 1.2; margin: 4px 0; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; margin-top: 16px; }
.tile { text-align: left; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); cursor: pointer; display: flex; flex-direction: column; gap: 6px; font-weight: 400; }
.tile:hover { border-color: var(--accent); }
.tile[disabled] { opacity: .5; cursor: default; }
.tile .t-top { display: flex; justify-content: space-between; align-items: center; }
.tile .t-icon { font-size: 1.6rem; }
.tile .t-state { font-size: .75rem; padding: 2px 8px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); font-weight: 700; }
.tile .t-state.done { background: #d1fae5; color: #065f46; }
.tile b { font-size: 1.05rem; }
.tile .t-num { font-size: 1.6rem; font-weight: 800; line-height: 1.1; }
.tile .thumbs { display: flex; gap: 4px; margin-top: 4px; }
.tile .thumbs img { width: 44px; height: 44px; object-fit: cover; border-radius: 6px; }

.rv-head { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; margin-bottom: 12px; }
.rv-title { text-align: center; display: flex; flex-direction: column; }
.rv-actions { justify-content: center; margin-top: 14px; }

.group-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.gi { position: relative; border-radius: 12px; overflow: hidden; border: 3px solid transparent; cursor: pointer; background: var(--bg); padding: 0; font-weight: 400; text-align: left; }
.gi img { width: 100%; aspect-ratio: 1; object-fit: contain; display: block; background: #000; }
.gi.keep { border-color: #10b981; }
.gi.drop { border-color: #ef4444; }
.gi.drop img { opacity: .55; }
.gi .badge { position: absolute; top: 8px; left: 8px; padding: 3px 9px; border-radius: 99px; font-size: .78rem; font-weight: 700; color: #fff; }
.gi.keep .badge { background: #10b981; }
.gi.drop .badge { background: #ef4444; }
.gi .best { position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,.65); color: #fde68a; font-size: .75rem; padding: 3px 8px; border-radius: 99px; }
.gi .zoom { position: absolute; bottom: 58px; right: 8px; width: 30px; height: 30px; padding: 0; border-radius: 8px; background: rgba(0,0,0,.55); color: #fff; border: 0; font-size: .9rem; }
.gi .gi-meta { padding: 6px 8px; font-size: .78rem; color: var(--muted); line-height: 1.35; overflow-wrap: anywhere; }

.swipe-wrap { display: flex; justify-content: center; overflow: hidden; padding: 8px 0; }
.swipe-card { position: relative; width: min(100%, 520px); height: min(52vh, 500px); border-radius: 16px; overflow: hidden; background: #000; touch-action: pan-y; user-select: none; box-shadow: 0 8px 30px rgba(0,0,0,.2); cursor: grab; }
.swipe-card img { width: 100%; height: 100%; object-fit: contain; pointer-events: none; }
.swipe-card.anim { transition: transform .25s ease, opacity .25s ease; }
.stamp { position: absolute; top: 24px; padding: 6px 14px; border: 4px solid; border-radius: 10px; font-weight: 900; font-size: 1.4rem; opacity: 0; letter-spacing: .05em; }
.drop-stamp { right: 20px; color: #ef4444; transform: rotate(12deg); }
.keep-stamp { left: 20px; color: #10b981; transform: rotate(-12deg); }
.card-info { display: flex; flex-direction: column; align-items: center; margin-top: 10px; text-align: center; }
.single-actions button.big { min-width: 150px; }
button.danger-soft { background: #fee2e2; border-color: #fecaca; color: #991b1b; }
button.keep { background: #d1fae5; border-color: #a7f3d0; color: #065f46; }
@media (prefers-color-scheme: dark) {
  button.danger-soft { background: #3b1414; border-color: #5b1f1f; color: #fecaca; }
  button.keep { background: #0f2a22; border-color: #1f5f4a; color: #a7f3d0; }
}
.done-icon { font-size: 3rem; }

.bottom-bar { position: sticky; bottom: 12px; z-index: 30; margin-top: 16px; display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--text); color: var(--bg); border-radius: 14px; padding: 10px 12px 10px 18px; box-shadow: 0 8px 30px rgba(0,0,0,.25); }

.fin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 6px; max-height: 300px; overflow: auto; margin: 12px 0; }
.fin-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; }
.fin-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 700px) { .fin-actions { grid-template-columns: 1fr; } }
.fin-box { border: 1px solid var(--border); border-radius: 12px; padding: 14px; }
.fin-box p { margin: 6px 0 10px; }

.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(0,0,0,.9); display: flex; align-items: center; justify-content: center; cursor: zoom-out; }
.lightbox img { max-width: 96vw; max-height: 94vh; }
