/* Secret Santa — a cosy Christmas-night theme: pine-green night sky, falling snow, a string of
   fairy lights, cream "gift tag" cards with red + gold trim. One fixed palette (it's a night scene
   in both light and dark mode). Mobile first; checked at 360 px. No inline styles (CSP). */
:root {
  --night: #0b2b21;
  --night-2: #08211a;
  --pine: #14503b;
  --pine-2: #1d6b50;
  --berry: #c8312f;
  --berry-2: #a3221f;
  --gold: #f2c14e;
  --gold-2: #d9a531;
  --cream: #fdf7ec;
  --paper: #fffdf8;
  --ink: #2a1c14;
  --ink-2: #6b5545;
  --line: #ead9c2;
  --ok: #1f7a4d;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .28), 0 2px 6px rgba(0, 0, 0, .18);
  --display: 'Mountains of Christmas', 'Georgia', serif;
  --body: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.5;
  color: var(--cream);
  background-color: var(--night);
  background-image:
    radial-gradient(1200px 600px at 50% -10%, rgba(242, 193, 78, .12), transparent 60%),
    radial-gradient(900px 500px at 100% 100%, rgba(200, 49, 47, .14), transparent 60%),
    linear-gradient(180deg, var(--night) 0%, var(--night-2) 100%);
  background-attachment: fixed;
  overflow-x: hidden;
}
a { color: var(--gold); }
img { max-width: 100%; }

#snow, #confetti { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; }
#snow { z-index: 0; }
#confetti { z-index: 50; }

/* ── fairy lights ─────────────────────────────────────────────────────────── */
.lights {
  position: relative; z-index: 2;
  display: flex; justify-content: space-around; align-items: flex-start;
  height: 34px; padding: 0 8px; overflow: hidden;
}
.lights::before {
  content: ''; position: absolute; left: -5%; right: -5%; top: -26px; height: 40px;
  border-bottom: 2px solid #233b2f; border-radius: 0 0 50% 50% / 0 0 100% 100%;
}
.bulb {
  position: relative; width: 11px; height: 17px; margin-top: 10px; border-radius: 50%;
  background: var(--c, var(--gold)); box-shadow: 0 2px 14px 3px var(--c, var(--gold));
  animation: twinkle 2.4s ease-in-out infinite;
}
.bulb::before { content: ''; position: absolute; top: -5px; left: 2px; width: 7px; height: 6px; border-radius: 2px; background: #3a4a40; }
.bulb:nth-child(4n+1) { --c: #ff5a4f; animation-delay: -.3s; }
.bulb:nth-child(4n+2) { --c: #ffd166; animation-delay: -1.1s; }
.bulb:nth-child(4n+3) { --c: #5ee08f; animation-delay: -1.7s; }
.bulb:nth-child(4n+4) { --c: #6cc6ff; animation-delay: -.7s; }
.bulb:nth-child(odd) { margin-top: 14px; }
@keyframes twinkle { 0%, 100% { opacity: 1; } 50% { opacity: .35; box-shadow: 0 2px 4px 0 var(--c); } }

/* ── layout ───────────────────────────────────────────────────────────────── */
.top, .wrap, .foot { position: relative; z-index: 1; }
.top { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 16px; padding: 6px 16px 0; max-width: 960px; margin: 0 auto; }
@media (min-width: 720px) { .top { justify-content: space-between; } }
.nav { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px; }
.nav:empty { display: none; }
.navname { font-weight: 700; color: rgba(253, 247, 236, .85); max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.navbtn {
  display: inline-flex; align-items: center; gap: 6px; font: inherit; font-weight: 800; font-size: 14px; line-height: 1;
  padding: 8px 14px; border-radius: 999px; cursor: pointer; text-decoration: none;
  background: rgba(253, 247, 236, .1); color: var(--cream); border: 1px solid rgba(253, 247, 236, .25);
}
.navbtn:hover { background: rgba(253, 247, 236, .18); }
.navbtn.gold { background: var(--gold); color: var(--ink); border-color: var(--gold); }
.right { text-align: right; margin: 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--cream); }
.brand-hat { font-size: 30px; filter: drop-shadow(0 3px 6px rgba(0,0,0,.4)); }
.brand-name { font-family: var(--display); font-size: 40px; line-height: 1; color: var(--cream); text-shadow: 0 3px 0 var(--berry-2), 0 6px 18px rgba(0,0,0,.4); }
.wrap { max-width: 760px; margin: 0 auto; padding: 18px 16px 40px; }
.foot { text-align: center; color: rgba(253, 247, 236, .55); font-size: 14px; padding: 10px 16px 30px; }

h1, h2, h3 { margin: 0 0 .4em; line-height: 1.15; }
h1 { font-family: var(--display); font-size: 44px; color: var(--cream); text-shadow: 0 2px 0 rgba(0,0,0,.3); }
h2 { font-family: var(--display); font-size: 32px; }
h3 { font-size: 18px; font-weight: 800; }
.lede { font-size: 18px; color: rgba(253, 247, 236, .85); margin: 0 0 18px; }
.center { text-align: center; }
.muted { color: var(--ink-2); }
.on-night .muted, .hero .muted { color: rgba(253, 247, 236, .7); }
.small { font-size: 14px; }
.stack > * + * { margin-top: 18px; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.row > .grow { flex: 1 1 200px; min-width: 0; }
.spacer { flex: 1; }

.hero { text-align: center; padding: 14px 0 8px; }
.hero h1 { font-size: 48px; margin-bottom: 6px; }
.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 10px 0 0; padding: 0; list-style: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; background: rgba(253, 247, 236, .1); border: 1px solid rgba(253, 247, 236, .18); font-weight: 700; font-size: 14px; color: var(--cream); }

/* ── gift-tag cards ───────────────────────────────────────────────────────── */
.card {
  position: relative;
  background: var(--paper);
  color: var(--ink);
  border-radius: var(--radius);
  padding: 22px 20px;
  box-shadow: var(--shadow);
  border-top: 6px solid var(--berry);
}
.card.gold { border-top-color: var(--gold); }
.card.green { border-top-color: var(--pine-2); }
.card h2 { color: var(--berry-2); }
.card .lede { color: var(--ink-2); }
.card a:not(.btn) { color: var(--berry-2); }
.ribbon {
  position: absolute; top: -6px; right: 22px; width: 34px; height: 44px; background: var(--gold);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 78%, 0 100%);
}
.message { white-space: pre-wrap; background: var(--cream); border-left: 4px solid var(--gold); padding: 12px 14px; border-radius: 10px; margin: 0; }

/* ── forms ────────────────────────────────────────────────────────────────── */
label, .label { display: block; font-weight: 700; font-size: 14px; margin: 0 0 6px; color: var(--ink); }
.field + .field { margin-top: 14px; }
input, textarea, select {
  width: 100%; font: inherit; color: var(--ink); background: #fff;
  border: 2px solid var(--line); border-radius: 12px; padding: 11px 13px;
}
textarea { min-height: 90px; resize: vertical; }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--gold-2); box-shadow: 0 0 0 4px rgba(242, 193, 78, .3); }
.grid2 { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 560px) { .grid2 { grid-template-columns: 1fr 1fr; } }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 800; font-size: 16px; line-height: 1.2;
  padding: 12px 20px; border-radius: 999px; border: 0; cursor: pointer; text-decoration: none;
  background: var(--berry); color: #fff; box-shadow: 0 4px 0 var(--berry-2), 0 8px 18px rgba(0,0,0,.18);
  transition: transform .08s ease, box-shadow .08s ease, filter .15s;
}
.btn:hover { filter: brightness(1.06); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--berry-2), 0 3px 8px rgba(0,0,0,.18); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn.gold { background: var(--gold); color: var(--ink); box-shadow: 0 4px 0 var(--gold-2), 0 8px 18px rgba(0,0,0,.18); }
.btn.green { background: var(--pine-2); box-shadow: 0 4px 0 var(--pine), 0 8px 18px rgba(0,0,0,.18); }
.btn.ghost { background: transparent; color: var(--berry-2); box-shadow: inset 0 0 0 2px var(--line); }
.btn.ghost:active { transform: none; }
.btn.small { padding: 7px 14px; font-size: 14px; }
.btn.wide { width: 100%; }
.btn.danger { background: transparent; color: var(--berry-2); box-shadow: inset 0 0 0 2px #f0c4c2; }
.btn.danger.armed { background: var(--berry); color: #fff; box-shadow: none; }
.linkbtn { background: none; border: 0; padding: 0; font: inherit; color: var(--gold); text-decoration: underline; cursor: pointer; }
.card .linkbtn { color: var(--berry-2); }

.copy { display: flex; gap: 8px; flex-wrap: wrap; }
.copy input { flex: 1 1 220px; min-width: 0; font-size: 14px; background: var(--cream); }

.error { color: var(--berry-2); font-weight: 700; margin: 10px 0 0; }
.error:empty { display: none; }
.notice { background: #fff6dc; border: 2px dashed var(--gold-2); border-radius: 14px; padding: 14px; color: var(--ink); }
.notice h3 { margin-bottom: 4px; }

/* ── people ───────────────────────────────────────────────────────────────── */
.people { list-style: none; margin: 0; padding: 0; }
.people li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px dashed var(--line); flex-wrap: wrap; }
.people li:first-child { border-top: 0; }
.people .who { flex: 1 1 160px; min-width: 0; }
.people .name { font-weight: 800; overflow-wrap: anywhere; }
.avatar {
  flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  font-weight: 800; color: #fff; background: var(--pine-2); box-shadow: inset 0 -3px 0 rgba(0,0,0,.15);
}
.people li:nth-child(3n+2) .avatar { background: var(--berry); }
.people li:nth-child(3n+3) .avatar { background: var(--gold-2); color: var(--ink); }
a.person { text-decoration: none; color: inherit; }
.tick { color: var(--ok); font-weight: 800; }
.badge { display: inline-block; font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 999px; background: var(--cream); color: var(--ink-2); border: 1px solid var(--line); }
.badge.ok { background: #e2f4ea; color: var(--ok); border-color: #bfe3cf; }
.badge.red { background: #fde6e5; color: var(--berry-2); border-color: #f3c1bf; }

/* ── wishlist ─────────────────────────────────────────────────────────────── */
.wishes { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.wish { display: flex; gap: 12px; align-items: stretch; background: #fff; border: 2px solid var(--line); border-radius: 14px; padding: 10px; overflow: hidden; }
.wish.text { align-items: center; }
.wish .thumb { flex: none; width: 84px; height: 84px; border-radius: 10px; background: var(--cream) center / cover no-repeat; display: grid; place-items: center; font-size: 34px; overflow: hidden; }
.wish .thumb img { width: 100%; height: 100%; object-fit: cover; }
.wish .body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.wish .title { font-weight: 800; color: var(--ink); text-decoration: none; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.wish a.title:hover { text-decoration: underline; }
.wish .site { font-size: 13px; color: var(--ink-2); overflow-wrap: anywhere; }
.wish .note { white-space: pre-wrap; overflow-wrap: anywhere; color: var(--ink); }
.wish.link .note { font-size: 14px; color: var(--ink-2); }
.wish .price { font-weight: 800; color: var(--pine); }
.wish .actions { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.wish .bullet { flex: none; width: 34px; height: 34px; display: grid; place-items: center; font-size: 22px; }
.skeleton { background: linear-gradient(90deg, var(--cream) 25%, #f3e6d0 50%, var(--cream) 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: 6px; height: 14px; width: 70%; }
@keyframes shimmer { to { background-position: -200% 0; } }
.empty { text-align: center; color: var(--ink-2); padding: 18px 8px; }
.empty .big { font-size: 40px; display: block; }

.addwish textarea { min-height: 54px; }
.addwish { margin-bottom: 20px; padding-bottom: 20px; border-bottom: 2px dashed var(--line); }
.tabs { display: inline-flex; background: var(--cream); border-radius: 999px; padding: 4px; gap: 4px; border: 1px solid var(--line); }
.tabs button { font: inherit; font-weight: 800; font-size: 14px; border: 0; background: transparent; padding: 7px 14px; border-radius: 999px; cursor: pointer; color: var(--ink-2); }
.tabs button[aria-pressed="true"] { background: var(--berry); color: #fff; }

/* ── item page ────────────────────────────────────────────────────────────── */
.itempage .hero-img { width: 100%; max-height: 380px; object-fit: contain; background: var(--cream); border-radius: 14px; display: block; }
.itempage .noimg { height: 160px; border-radius: 14px; background: var(--cream); display: grid; place-items: center; font-size: 64px; }
.itempage h2 { font-family: var(--body); font-weight: 800; font-size: 24px; color: var(--ink); margin-top: 16px; overflow-wrap: anywhere; }
.itempage .desc { color: var(--ink-2); overflow-wrap: anywhere; }
.itempage .urlline { font-size: 13px; color: var(--ink-2); overflow-wrap: anywhere; }
.frame { width: 100%; height: 70vh; min-height: 420px; border: 2px solid var(--line); border-radius: 14px; background: #fff; display: block; }
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--cream); text-decoration: none; font-weight: 700; margin-bottom: 12px; }
.back:hover { text-decoration: underline; }

/* ── the draw: a gift to unwrap ───────────────────────────────────────────── */
.draw { text-align: center; }
.gift { position: relative; width: 170px; height: 170px; margin: 26px auto 8px; cursor: pointer; border: 0; background: none; padding: 0; }
.gift:focus-visible { outline: 3px solid var(--gold); outline-offset: 8px; border-radius: 12px; }
.gift .box { position: absolute; left: 15px; right: 15px; bottom: 0; height: 110px; background: var(--berry); border-radius: 8px; box-shadow: inset 0 -10px 0 rgba(0,0,0,.12); }
.gift .box::before { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 22px; margin-left: -11px; background: var(--gold); }
.gift .lid { position: absolute; left: 5px; right: 5px; top: 30px; height: 36px; background: #e0453f; border-radius: 8px; box-shadow: 0 6px 0 rgba(0,0,0,.12); transform-origin: 20% 100%; }
.gift .lid::before { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 22px; margin-left: -11px; background: var(--gold); }
.gift .bow { position: absolute; left: 50%; top: -26px; width: 80px; height: 32px; margin-left: -40px; }
.gift .bow::before, .gift .bow::after { content: ''; position: absolute; top: 0; width: 36px; height: 28px; border: 8px solid var(--gold); border-radius: 50% 50% 0 50%; }
.gift .bow::before { left: 0; transform: rotate(-12deg); }
.gift .bow::after { right: 0; transform: scaleX(-1) rotate(-12deg); }
.gift.idle { animation: bob 2.6s ease-in-out infinite; }
.gift.shake { animation: shake .5s ease-in-out infinite; }
.gift.open .lid { animation: lidoff .7s cubic-bezier(.3,1.4,.6,1) forwards; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
@keyframes shake { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-6deg); } 75% { transform: rotate(6deg); } }
@keyframes lidoff { to { transform: translate(-70px, -90px) rotate(-35deg); opacity: 0; } }
.spinner-name { font-family: var(--display); font-size: 34px; color: var(--ink-2); min-height: 48px; }
.reveal { animation: pop .6s cubic-bezier(.2,1.6,.4,1) both; }
.reveal .to { font-size: 15px; text-transform: uppercase; letter-spacing: .14em; font-weight: 800; color: var(--ink-2); }
.reveal .giftee { font-family: var(--display); font-size: 54px; line-height: 1.05; color: var(--berry); overflow-wrap: anywhere; }
@keyframes pop { from { transform: scale(.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.waiting .big { font-size: 52px; display: block; animation: bob 2.6s ease-in-out infinite; }

.countdown { font-family: var(--display); font-size: 26px; color: var(--gold); }

/* ── toast ────────────────────────────────────────────────────────────────── */
.toast {
  position: fixed; z-index: 60; left: 50%; bottom: 22px; transform: translateX(-50%);
  background: var(--ink); color: var(--cream); padding: 11px 18px; border-radius: 999px; font-weight: 700;
  box-shadow: var(--shadow); max-width: calc(100% - 32px); text-align: center;
}

.hostbar { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.hostbar h1 { margin: 0; font-size: 38px; }
.evlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.evlist a { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 14px; background: #fff; border: 2px solid var(--line); color: var(--ink); text-decoration: none; flex-wrap: wrap; }
.evlist a:hover { border-color: var(--gold-2); }
.evlist .grow { flex: 1 1 180px; min-width: 0; font-weight: 800; overflow-wrap: anywhere; }

@media (max-width: 420px) {
  .brand-name { font-size: 34px; }
  h1, .hero h1 { font-size: 38px; }
  .card { padding: 20px 16px; }
  .wish .thumb { width: 64px; height: 64px; }
  .reveal .giftee { font-size: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ── sign in ──────────────────────────────────────────────────────────────── */
.signin { max-width: 460px; margin-left: auto; margin-right: auto; }
.signin > * + * { margin-top: 16px; }
.btn.google { background: #fff; color: #1f1f1f; box-shadow: inset 0 0 0 2px var(--line), 0 4px 0 var(--line); }
.btn.google .g { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; font-weight: 900; color: #fff; background: conic-gradient(#ea4335 0 25%, #fbbc05 0 50%, #34a853 0 75%, #4285f4 0); }
.or { display: flex; align-items: center; gap: 10px; color: var(--ink-2); font-size: 14px; }
.or::before, .or::after { content: ''; flex: 1; border-top: 1px dashed var(--line); }

/* ── event info ───────────────────────────────────────────────────────────── */
.eventinfo { padding: 0; overflow: hidden; }
.eventinfo .cover { display: block; width: 100%; aspect-ratio: 16 / 7; object-fit: cover; background: var(--cream); }
.eventinfo .cover.placeholder { display: grid; place-items: center; font-size: 42px; letter-spacing: 8px;
  background: repeating-linear-gradient(45deg, #fbeede 0 18px, #f6e3cb 18px 36px); }
.eventinfo-body { padding: 18px 20px 22px; }
.evname { color: var(--berry-2); font-size: 40px; margin-bottom: 4px; overflow-wrap: anywhere; text-shadow: none; }
.eventinfo .countdown { color: var(--pine-2); margin: 0 0 8px; }
.facts { display: grid; gap: 10px; margin: 12px 0 14px; }
@media (min-width: 560px) { .facts { grid-template-columns: 1fr 1fr; } }
.facts dt { font-size: 13px; font-weight: 800; color: var(--ink-2); text-transform: uppercase; letter-spacing: .04em; }
.facts dd { margin: 2px 0 0; font-weight: 700; overflow-wrap: anywhere; }
.map { display: block; width: 100%; height: 240px; border: 0; border-radius: 14px; margin-top: 14px; background: var(--cream); }
.cover-preview { display: block; width: 100%; max-height: 260px; object-fit: cover; border-radius: 14px; margin-bottom: 12px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.filebtn { cursor: pointer; margin: 0; }
.hint { margin: 6px 0 0; }
.on-night-h { color: var(--cream); margin: 8px 0 0; }

/* ── home ─────────────────────────────────────────────────────────────────── */
.evgrid { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
@media (min-width: 560px) { .evgrid { grid-template-columns: 1fr 1fr; } }
.evcard { display: flex; flex-direction: column; height: 100%; background: var(--paper); color: var(--ink); text-decoration: none; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); border-top: 6px solid var(--berry); transition: transform .12s; }
.evcard:hover { transform: translateY(-2px); }
.evcard img, .evcard-ph { width: 100%; aspect-ratio: 16 / 7; object-fit: cover; display: grid; place-items: center; font-size: 40px; background: repeating-linear-gradient(45deg, #fbeede 0 18px, #f6e3cb 18px 36px); }
.evcard-body { padding: 12px 16px 16px; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.evcard-name { font-weight: 800; font-size: 18px; overflow-wrap: anywhere; }
.code-input { text-transform: uppercase; letter-spacing: .2em; font-weight: 800; }

/* ── admin ────────────────────────────────────────────────────────────────── */
.codebig { display: flex; justify-content: center; gap: 6px; margin: 4px 0 16px; flex-wrap: wrap; }
.codebig span { width: 44px; height: 54px; display: grid; place-items: center; font-size: 28px; font-weight: 900; color: var(--berry-2); background: var(--cream); border: 2px solid var(--line); border-radius: 10px; }
@media (max-width: 400px) { .codebig span { width: 38px; height: 48px; font-size: 24px; } }
.people li > .notice { flex: 1 1 100%; }
.people .email { overflow-wrap: anywhere; }
.people .name .badge { margin-left: 4px; vertical-align: middle; }
.spoilers { background: var(--cream); border: 2px dashed var(--line); border-radius: 14px; padding: 12px 14px; margin: 10px 0 14px; }
.spoilers summary { cursor: pointer; font-weight: 800; }
.assign { list-style: none; margin: 8px 0 12px; padding: 0; display: grid; gap: 6px; }
.spoiler { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 8px 10px; background: #fff; border-radius: 10px; border: 1px solid var(--line); cursor: pointer; }
.spoiler.shown { cursor: default; }
.spoiler .giver { font-weight: 800; }
.spoiler .receiver { flex: 1 1 100px; min-width: 0; font-weight: 800; color: var(--berry-2); }
.spoiler .blur { filter: blur(7px); user-select: none; transition: filter .25s; display: inline-block; }
.spoiler:not(.shown):hover .blur { filter: blur(5px); }
.spoiler.shown .blur { filter: none; user-select: auto; }
.card.glow { box-shadow: var(--shadow), 0 0 0 4px rgba(242, 193, 78, .7); }

/* ── exclusions ───────────────────────────────────────────────────────────── */
.exlist { list-style: none; margin: 0 0 14px; padding: 0; display: grid; gap: 8px; }
.exlist li { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 12px; background: var(--cream); border: 1px solid var(--line); border-radius: 12px; }
.exlist .pair { flex: 1 1 180px; min-width: 0; overflow-wrap: anywhere; }
.exform { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.exform select { flex: 1 1 140px; min-width: 0; }
.exform .amp { font-weight: 800; color: var(--ink-2); }

/* ── cover cropper ────────────────────────────────────────────────────────── */
body.noscroll { overflow: hidden; }
.crop-overlay { position: fixed; inset: 0; z-index: 40; background: rgba(4, 18, 13, .78); display: grid; place-items: center; padding: 16px; overflow-y: auto; }
.crop-card { width: min(720px, 100%); }
.crop-frame { position: relative; width: 100%; aspect-ratio: 16 / 7; overflow: hidden; border-radius: 12px; background: #000; cursor: grab; touch-action: none; user-select: none; outline-offset: 3px; }
.crop-frame:active { cursor: grabbing; }
.crop-frame:focus-visible { outline: 3px solid var(--gold); }
.crop-frame::after { content: ''; position: absolute; inset: 0; pointer-events: none; border-radius: 12px; box-shadow: inset 0 0 0 2px rgba(255,255,255,.7);
  background-image: linear-gradient(rgba(255,255,255,.25), rgba(255,255,255,.25)), linear-gradient(rgba(255,255,255,.25), rgba(255,255,255,.25)),
    linear-gradient(90deg, rgba(255,255,255,.25), rgba(255,255,255,.25)), linear-gradient(90deg, rgba(255,255,255,.25), rgba(255,255,255,.25));
  background-size: 100% 1px, 100% 1px, 1px 100%, 1px 100%; background-position: 0 33.33%, 0 66.66%, 33.33% 0, 66.66% 0; background-repeat: no-repeat; }
.crop-img { position: absolute; left: 0; top: 0; max-width: none; transform-origin: 0 0; pointer-events: none; }
.crop-zoom { display: flex; align-items: center; gap: 10px; margin-top: 14px; }
.crop-zoom input { flex: 1; padding: 0; border: 0; accent-color: var(--berry); }
.crop-actions { margin-top: 16px; }

.switch { display: flex; align-items: center; gap: 10px; margin: 10px 0 0; font-weight: 700; cursor: pointer; }
.switch input { width: 20px; height: 20px; padding: 0; accent-color: var(--berry); flex: none; color-scheme: light; }
.plainloc { overflow-wrap: anywhere; }
