/* ============================================================
   Deletion — the verification page
   The page is the site. The panel in the middle is deliberately
   not: it is a stock verification widget, light and system-font,
   sitting on the dark gallery like something bolted on.
   ============================================================ */

.del {
  min-height: 100svh;
  padding: clamp(6rem, 11vh, 8.5rem) clamp(1rem, 4vw, 2.5rem) clamp(3rem, 6vw, 5rem);
  max-width: 780px; margin: 0 auto;
  display: flex; flex-direction: column; align-items: center;
}

/* ---------- the warning ---------- */
.del-head { text-align: center; max-width: 40rem; margin-bottom: clamp(1.8rem, 3.2vw, 2.6rem) }
.del-kicker {
  font-size: .68rem; letter-spacing: .34em; text-transform: uppercase;
  color: #b4483c; margin-bottom: .9rem;
}
.del-title {
  font-family: var(--display, Georgia, serif); font-weight: 300;
  font-size: clamp(2.6rem, 8vw, 4.4rem); line-height: 1.02; margin-bottom: 1.2rem;
}
.del-lede { color: var(--ink, #ece6da); opacity: .82; line-height: 1.72;
  font-size: clamp(1.02rem, 1.6vw, 1.18rem) }
.del-lede strong { color: var(--ink, #ece6da); font-weight: 400 }


/* ============================================================
   The widget — system font, light, borrowed furniture
   ============================================================ */
.cap {
  width: min(100%, 34rem);
  font-family: Roboto, "Helvetica Neue", Arial, sans-serif;
  background: #fff; color: #000;
  border: 1px solid #d3d3d3; border-radius: 3px;
  box-shadow: 0 2px 14px rgba(0, 0, 0, .5);
  overflow: hidden;
}
.cap.is-wrong { animation: cap-shake .4s ease }
@keyframes cap-shake {
  0%, 100% { transform: translateX(0) }
  20% { transform: translateX(-7px) }
  40% { transform: translateX(6px) }
  60% { transform: translateX(-4px) }
  80% { transform: translateX(3px) }
}
.cap.is-checking { pointer-events: none }
.cap.is-checking .cap-body { opacity: .45 }

.cap-top {
  background: #4a90e2; color: #fff;
  padding: 16px 18px 18px; line-height: 1.28;
}
.cap-head { font-size: 16px; font-weight: 400 }
.cap-strong { display: block; font-size: 29px; font-weight: 500; margin-top: 3px }
.cap-sub { font-size: 13px; margin-top: 7px; opacity: .93; line-height: 1.4 }

.cap-body {
  padding: 14px; background: #fff; min-height: 252px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px; transition: opacity .2s ease;
}

/* image grid */
.cap-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; width: 100% }
.cap-cell {
  position: relative; padding: 0; border: 0; background: #eee;
  aspect-ratio: 1 / 1; overflow: hidden; cursor: pointer; display: block;
}
.cap-cell canvas { width: 100%; height: 100%; display: block }
.cap-cell.is-on canvas { transform: scale(.82); transition: transform .18s ease }
.cap-cell canvas { transition: transform .18s ease }
.cap-tick {
  position: absolute; inset: 0; pointer-events: none;
  opacity: 0; transition: opacity .15s ease;
}
.cap-cell.is-on .cap-tick { opacity: 1 }
.cap-cell.is-on .cap-tick::after {
  content: ""; position: absolute; top: 6px; left: 6px; width: 22px; height: 22px;
  border-radius: 50%; background: #4a90e2 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3'%3E%3Cpath d='M4 12l5 5L20 6'/%3E%3C/svg%3E") center/14px no-repeat;
}
.cap-grid-plain .cap-cell-plain { background: #dfe3e6; border: 1px solid #cfd4d8 }
.cap-cell-plain.is-lit { background: #4a90e2 }
.cap-cell-plain.is-hit { background: #9ec6f0 }

/* text / inputs */
.cap-text-canvas, .cap-wide { max-width: 100%; border: 1px solid #ddd; display: block }
.cap-rot { border: 1px solid #ddd; transition: transform .25s ease }
.cap-rot-wrap { display: grid; place-items: center; width: 180px; height: 180px; overflow: hidden }
.cap-rot-bar { display: flex; gap: 8px }
.cap-rot-btn {
  width: 40px; height: 32px; font-size: 17px; cursor: pointer;
  border: 1px solid #c8c8c8; background: #f6f6f6; border-radius: 2px;
}
.cap-rot-btn:hover { background: #ececec }

.cap-input {
  width: 100%; max-width: 330px; font: inherit; font-size: 16px;
  padding: 9px 10px; border: 1px solid #c8c8c8; border-radius: 2px;
  background: #fff; color: #000; text-align: center;
}
.cap-input:focus { outline: 2px solid #4a90e2; outline-offset: -1px }

.cap-seq {
  font-family: "Roboto Mono", Consolas, monospace; font-size: 17px;
  letter-spacing: .04em; text-align: center; color: #222;
}
.cap-note { font-size: 12px; color: #666 }

/* options */
.cap-opts { display: grid; gap: 6px; width: 100% }
.cap-opts-tight { grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)) }
.cap-opt {
  font: inherit; font-size: 15px; text-align: left; cursor: pointer;
  padding: 10px 12px; border: 1px solid #ccc; border-radius: 2px;
  background: #fafafa; color: #111;
}
.cap-opt:hover { background: #f0f4f9; border-color: #9fc2ea }
.cap-opt.is-on { background: #e3eefb; border-color: #4a90e2; box-shadow: inset 0 0 0 1px #4a90e2 }

/* slider */
.cap-track {
  position: relative; width: 100%; max-width: 300px; height: 34px;
  background: #eef1f3; border: 1px solid #d5d9dc; border-radius: 2px;
}
.cap-gap {
  position: absolute; top: 4px; width: 22px; height: 24px; margin-left: -11px;
  background: #cfd6dc; border: 1px dashed #9aa4ad;
}
.cap-knob {
  position: absolute; top: 4px; left: 0; width: 20px; height: 24px; margin-left: -10px;
  background: #4a90e2; border-radius: 2px; transition: left .05s linear;
}
.cap-range { width: 100%; max-width: 300px }

/* footer */
.cap-foot {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 10px; background: #fafafa; border-top: 1px solid #e4e4e4;
}
.cap-tools { display: flex; gap: 2px }
.cap-tool {
  width: 30px; height: 30px; display: grid; place-items: center;
  border: 0; background: none; cursor: pointer; color: #9aa0a6; font-size: 15px;
  border-radius: 50%;
}
.cap-tool:hover { background: #ececec; color: #5f6368 }
.cap-verify {
  font: inherit; font-size: 15px; letter-spacing: .02em; cursor: pointer;
  background: #4a90e2; color: #fff; border: 0; border-radius: 2px;
  padding: 10px 24px;
}
.cap-verify:hover { background: #3f80cd }
.cap-verify:disabled { background: #a9c6e8; cursor: default }
.cap-err {
  color: #d93025; font-size: 12px; min-height: 15px;
  padding: 0 12px 8px; background: #fff; text-align: center;
}

.del-fine {
  margin-top: 1.5rem; max-width: 30rem; text-align: center;
  font-size: .58rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--dimmer, #6c6456); line-height: 2;
}

/* ---------- the closing sequence ---------- */
.del-done { width: min(100%, 30rem); text-align: left }
.del-done p {
  font-family: "Roboto Mono", Consolas, monospace; font-size: .76rem;
  color: var(--dim, #9c9384); opacity: 0; transform: translateY(4px);
  transition: opacity .5s ease, transform .5s ease; margin-bottom: .5rem;
}
.del-done p.is-on { opacity: 1; transform: none }
.del-done p.is-final { color: #c4584a }

@media (max-width: 460px) {
  .cap-strong { font-size: 21px }
  .cap-body { min-height: 180px }
}
@media (prefers-reduced-motion: reduce) {
  .cap.is-wrong { animation: none }
  .cap-prog i, .cap-rot, .del-done p { transition: none }
}

/* ---------- progress, inside the widget ---------- */
.cap-prog { height: 3px; background: #e3e6e8; overflow: hidden }
.cap-prog i {
  display: block; height: 100%; width: 0; background: #4a90e2;
  transition: width .45s cubic-bezier(.16, 1, .3, 1);
}
.cap-count {
  font-size: 13px; color: #9aa0a6; margin-left: auto; margin-right: 12px;
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.cap-count em { font-style: normal; color: #bdc1c6; margin-left: 4px }

/* ---------- the added challenge types ---------- */
.cap-stroop {
  font-size: 46px; font-weight: 700; letter-spacing: .06em;
  text-align: center; line-height: 1.1;
}
.cap-magic { display: grid; grid-template-columns: repeat(3, 56px); gap: 3px; justify-content: center }
.cap-magic-cell {
  display: grid; place-items: center; height: 46px;
  background: #f3f5f7; border: 1px solid #dcdfe2;
  font-size: 16px; font-variant-numeric: tabular-nums; color: #222;
}
.cap-magic-cell.is-blank { background: #e3eefb; border-color: #4a90e2; color: #4a90e2; font-weight: 700 }

.cap-cell-word {
  display: grid; place-items: center; aspect-ratio: auto; min-height: 54px;
  background: #f5f6f7; border: 1px solid #dcdfe2; font-size: 13px; color: #202124;
  padding: 4px; word-break: break-all; text-align: center;
}
.cap-cell-word.is-on { background: #cfe3fb; border-color: #4a90e2; box-shadow: inset 0 0 0 1px #4a90e2 }
.cap-grid-word { grid-template-columns: repeat(3, 1fr) }

.cap-words { display: flex; flex-wrap: wrap; gap: 5px; justify-content: center }
.cap-word {
  font: inherit; font-size: 14px; cursor: pointer; padding: 6px 9px;
  border: 1px solid #d6d9dc; background: #fafbfc; border-radius: 2px; color: #202124;
}
.cap-word:hover { background: #eef3f9; border-color: #9fc2ea }
.cap-word.is-on { background: #e3eefb; border-color: #4a90e2; box-shadow: inset 0 0 0 1px #4a90e2 }

.cap-passage {
  font-size: 14px; line-height: 1.65; color: #202124; text-align: center;
  max-width: 320px; background: #f7f8f9; border: 1px solid #e4e6e8; padding: 10px;
}

.cap-dice { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center }
.cap-die { border-radius: 8px; box-shadow: 0 1px 3px rgba(0,0,0,.25) }

.cap-mirror-ref { border: 2px solid #4a90e2; display: block }
.cap-mirror-row { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center }
.cap-mirror-opt { padding: 0; border: 1px solid #d0d3d6; background: #fff; cursor: pointer; line-height: 0 }
.cap-mirror-opt:hover { border-color: #9fc2ea }
.cap-mirror-opt.is-on { border-color: #4a90e2; box-shadow: 0 0 0 2px #4a90e2 }

.cap-matrix { display: grid; grid-template-columns: repeat(3, 54px); gap: 3px; justify-content: center }
.cap-matrix-cell {
  display: grid; place-items: center; height: 54px;
  background: #f6f7f8; border: 1px solid #e0e2e4;
}
.cap-matrix-cell.is-blank { background: #e3eefb; border-color: #4a90e2; color: #4a90e2; font-size: 20px; font-weight: 700 }
.cap-matrix-opts { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap }
.cap-matrix-opt {
  padding: 4px; border: 1px solid #d0d3d6; background: #fff; cursor: pointer; line-height: 0;
}
.cap-matrix-opt:hover { border-color: #9fc2ea }
.cap-matrix-opt.is-on { border-color: #4a90e2; box-shadow: 0 0 0 2px #4a90e2 }

/* ---------- between rounds ---------- */
.cap-wait { display: grid; place-items: center; gap: 14px }
.cap-spinner {
  width: 30px; height: 30px; border-radius: 50%;
  border: 3px solid #dfe3e6; border-top-color: #4a90e2;
  animation: cap-spin .9s linear infinite;
}
@keyframes cap-spin { to { transform: rotate(360deg) } }
.cap-wait-note { font-size: 13px; color: #5f6368 }

.cap-gate-text {
  font-size: 15px; line-height: 1.6; color: #202124;
  text-align: center; max-width: 27rem;
}
.cap-gate-ref {
  margin-top: 12px; font-size: 11px; letter-spacing: .1em;
  color: #9aa0a6; text-transform: uppercase;
}
@media (prefers-reduced-motion: reduce) { .cap-spinner { animation: none } }

.del-lede-2 { margin-top: .85rem; opacity: .62; font-size: 1rem }
