/* 确认弹层。取代原生 confirm()，见 js/ui/confirm.js 顶部说明。 */

.cf-mask {
  position: fixed; inset: 0;
  z-index: 200;                /* 登录层是 100，确认要能盖在它上面 */
  display: grid; place-items: center;
  padding: var(--sp-4);
  background: rgba(34, 31, 26, .38);
  animation: cf-in var(--dur) var(--ease);
}

.cf-box {
  width: min(420px, 100%);
  padding: var(--sp-6);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lift);
  animation: cf-rise var(--dur) var(--ease);
}

.cf-title {
  font-size: var(--fs-lg);
  font-weight: 600;
  line-height: 1.5;
  color: var(--ink);
}

.cf-body {
  margin-top: var(--sp-3);
  font-size: var(--fs-sm);
  line-height: 1.8;
  color: var(--ink2);
}

.cf-acts {
  display: flex; justify-content: flex-end; gap: var(--sp-2);
  margin-top: var(--sp-6);
}

/* 破坏性操作的确认键。用红字而非红底 —— 这套界面通篇是线框按钮，
   实心红块会重得像报错横幅。 */
.cf-yes.is-danger { color: var(--high); border-color: var(--line); }
.cf-yes.is-danger:hover { color: var(--high); border-color: var(--high); }

@keyframes cf-in   { from { opacity: 0 } }
@keyframes cf-rise { from { opacity: 0; transform: translateY(6px) } }

@media (prefers-reduced-motion: reduce) {
  .cf-mask, .cf-box { animation: none; }
}
