/* ═══════════════════════════════════════════════════════════
   hush-account.css — partagé entre delete-account.html
   et clear-messages.html
   ═══════════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ── TOKENS ─────────────────────────────────────────────── */
:root {
  --purple: #7B2FBE;
  --cyan:   #00D4FF;
  --red:    #e03055;
  --grad:   linear-gradient(135deg, var(--purple), var(--cyan));

  /* dark (défaut) */
  --bg:           #0d0d14;
  --surface:      #16161f;
  --surface2:     #1e1e2a;
  --border:       rgba(255,255,255,0.07);
  --text:         #f0f0f8;
  --text-muted:   rgba(240,240,248,0.48);
  --input-bg:     #1e1e2a;
  --input-border: rgba(255,255,255,0.1);
  --modal-bg:     #16161f;
}

/* ── LIGHT THEME ─────────────────────────────────────────── */
[data-theme="light"] {
  --bg:           #f4f4f8;
  --surface:      #ffffff;
  --surface2:     #f0f0f5;
  --border:       rgba(0,0,0,0.08);
  --text:         #111118;
  --text-muted:   rgba(17,17,24,0.48);
  --input-bg:     #f0f0f5;
  --input-border: rgba(0,0,0,0.1);
  --modal-bg:     #ffffff;
}

/* ── BASE ────────────────────────────────────────────────── */
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Poppins', sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 24px 16px 56px;
  transition: background .25s, color .25s;
}

/* ── HEADER ─────────────────────────────────────────────── */
header {
  width: 100%;
  max-width: 480px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 36px;
  margin-top: 8px;
}
.logo-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo-img {
  height: 32px;
  width: auto;
}
.logo-rcbg {
  height: 20px;
  width: auto;
  opacity: .55;
}

/* theme toggle */
.theme-btn {
  width: 36px; height: 36px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface2);
  color: var(--text-muted);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  transition: background .2s, color .2s;
  flex-shrink: 0;
}
.theme-btn:hover { background: var(--surface); color: var(--text); }

/* ── CARD ────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 32px 28px;
  width: 100%;
  max-width: 480px;
  transition: background .25s, border-color .25s;
}
.card-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 6px;
}
.card-sub {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 28px;
  line-height: 1.65;
}

/* ── DEMO BOX ────────────────────────────────────────────── */
.demo-box {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 28px;
}
.demo-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 10px;
}
.url-bar {
  background: rgba(0,0,0,0.2);
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 12px;
  font-family: 'Courier New', monospace;
  color: var(--text-muted);
  margin-bottom: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
[data-theme="light"] .url-bar {
  background: rgba(0,0,0,0.06);
}
.uid-highlight {
  color: var(--cyan);
  font-weight: 700;
  position: relative;
}
.uid-highlight::after {
  content: '';
  position: absolute;
  left: -3px; right: -3px; bottom: -2px; top: -2px;
  background: rgba(0,212,255,.15);
  border-radius: 4px;
  animation: pulse-hl 2s ease-in-out infinite;
}
@keyframes pulse-hl {
  0%,100% { opacity: .35; } 50% { opacity: 1; }
}
.extract-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.extract-arrow {
  font-size: 16px;
  color: var(--text-muted);
  animation: bounce-down 1.4s ease-in-out infinite;
}
@keyframes bounce-down {
  0%,100% { transform: translateY(0); }
  50%      { transform: translateY(4px); }
}
.extract-chip {
  background: rgba(0,212,255,.1);
  border: 1px solid rgba(0,212,255,.28);
  border-radius: 7px;
  padding: 5px 12px;
  font-size: 12px;
  font-family: 'Courier New', monospace;
  color: var(--cyan);
  font-weight: 700;
}
.extract-note {
  font-size: 11px;
  color: var(--text-muted);
}
.demo-desc {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-top: 6px;
}

/* ── STEPS ───────────────────────────────────────────────── */
.steps { margin-bottom: 28px; }
.step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 11px 0;
  border-bottom: 1px solid var(--border);
}
.step:last-child { border-bottom: none; }
.step-num {
  min-width: 26px; height: 26px;
  border-radius: 7px;
  background: var(--grad);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; color: #fff;
  flex-shrink: 0; margin-top: 2px;
}
.step-body { flex: 1; }
.step-title { font-size: 13px; font-weight: 600; margin-bottom: 2px; }
.step-desc  { font-size: 12px; color: var(--text-muted); line-height: 1.6; }
.step-code  {
  font-family: 'Courier New', monospace;
  color: var(--cyan);
  font-size: 11px;
}

/* ── FORM ────────────────────────────────────────────────── */
.form-section { margin-bottom: 20px; }
.field-label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 8px;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.input-wrap { position: relative; }
input[type="text"] {
  width: 100%;
  background: var(--input-bg);
  border: 1px solid var(--input-border);
  border-radius: 12px;
  padding: 13px 44px 13px 16px;
  font-size: 14px;
  font-family: 'Courier New', monospace;
  color: var(--text);
  outline: none;
  transition: border-color .2s, background .25s;
}
input[type="text"]:focus { border-color: var(--cyan); }
input[type="text"]::placeholder { color: var(--text-muted); font-family: 'Poppins', sans-serif; }
.input-icon {
  position: absolute; right: 14px; top: 50%;
  transform: translateY(-50%);
  font-size: 15px; pointer-events: none; color: var(--text-muted);
}

/* lookup result */
#lookup-result, #lookup-result-clear {
  margin-top: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  display: none;
  line-height: 1.5;
}
.result-found {
  background: rgba(0,212,255,.08);
  border: 1px solid rgba(0,212,255,.25);
  color: var(--cyan);
  display: block !important;
}
.result-error {
  background: rgba(224,48,85,.08);
  border: 1px solid rgba(224,48,85,.25);
  color: var(--red);
  display: block !important;
}
.result-loading { display: block !important; color: var(--text-muted); }

/* ── CHECKBOXES ─────────────────────────────────────────── */
.checks { display: flex; flex-direction: column; gap: 12px; margin-bottom: 24px; }
.check-row {
  display: flex; align-items: flex-start; gap: 12px; cursor: pointer;
}
.check-row input[type="checkbox"] { display: none; }
.check-box {
  min-width: 22px; height: 22px;
  border-radius: 6px;
  border: 1.5px solid var(--input-border);
  background: var(--input-bg);
  display: flex; align-items: center; justify-content: center;
  transition: all .2s; margin-top: 1px; flex-shrink: 0;
}
.check-row input:checked + .check-box {
  background: var(--red);
  border-color: var(--red);
}
.check-mark { display: none; }
.check-row input:checked + .check-box .check-mark { display: block; }
.check-label { font-size: 13px; line-height: 1.6; color: var(--text); }

/* ── BUTTONS ─────────────────────────────────────────────── */
.btn-action {
  width: 100%;
  padding: 14px;
  border-radius: 13px;
  border: none;
  font-size: 14px;
  font-weight: 700;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  color: #fff;
  transition: opacity .2s, transform .15s;
}
.btn-action:disabled { opacity: .3; cursor: not-allowed; transform: none !important; }
.btn-action:not(:disabled):hover { opacity: .9; transform: translateY(-1px); }
.btn-action:not(:disabled):active { transform: translateY(0); }
.btn-delete-color { background: var(--red); }
.btn-clear-color  {
  background: linear-gradient(135deg, var(--purple), #5b3fff);
}

/* ── MODAL ───────────────────────────────────────────────── */
.overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.65);
  backdrop-filter: blur(5px);
  display: flex; align-items: center; justify-content: center;
  z-index: 100;
  opacity: 0; pointer-events: none;
  transition: opacity .25s;
}
.overlay.visible { opacity: 1; pointer-events: all; }
.modal {
  background: var(--modal-bg);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 28px 24px;
  max-width: 360px;
  width: 90%;
  transform: scale(.95);
  transition: transform .25s, background .25s;
}
.overlay.visible .modal { transform: scale(1); }
.modal-header {
  width: 44px; height: 44px;
  border-radius: 12px;
  margin: 0 auto 14px;
  display: flex; align-items: center; justify-content: center;
}
.modal-header-delete { background: rgba(224,48,85,.15); }
.modal-header-clear  { background: rgba(123,47,190,.15); }
.modal-header svg { display: block; }
.modal-title {
  font-size: 17px; font-weight: 700;
  text-align: center; margin-bottom: 8px;
}
.modal-body {
  font-size: 13px; color: var(--text-muted);
  text-align: center; line-height: 1.7; margin-bottom: 24px;
}
.modal-uid { font-family: 'Courier New', monospace; color: var(--cyan); font-weight: 700; }
.modal-actions { display: flex; gap: 10px; }
.btn-modal-cancel {
  flex: 1; padding: 13px; border-radius: 12px;
  border: 1px solid var(--border);
  background: transparent; color: var(--text);
  font-family: 'Poppins', sans-serif; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: background .2s;
}
.btn-modal-cancel:hover { background: var(--surface2); }
.btn-modal-confirm-delete {
  flex: 1; padding: 13px; border-radius: 12px;
  border: none; background: var(--red);
  color: #fff; font-family: 'Poppins', sans-serif;
  font-size: 13px; font-weight: 700; cursor: pointer;
  transition: opacity .2s;
}
.btn-modal-confirm-clear {
  flex: 1; padding: 13px; border-radius: 12px;
  border: none;
  background: linear-gradient(135deg, var(--purple), #5b3fff);
  color: #fff; font-family: 'Poppins', sans-serif;
  font-size: 13px; font-weight: 700; cursor: pointer;
  transition: opacity .2s;
}
.btn-modal-confirm-delete:hover,
.btn-modal-confirm-clear:hover { opacity: .88; }

/* ── SUCCESS SCREEN ─────────────────────────────────────── */
.success-screen {
  display: none;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 16px 0 8px;
}
.success-icon-wrap {
  width: 64px; height: 64px;
  border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
}
.success-icon-delete { background: rgba(224,48,85,.12); }
.success-icon-clear  { background: rgba(123,47,190,.12); }
.success-title { font-size: 20px; font-weight: 700; margin-bottom: 10px; }
.success-sub {
  font-size: 13px; color: var(--text-muted);
  line-height: 1.75; max-width: 300px;
}

/* ── SPINNER ─────────────────────────────────────────────── */
.spinner {
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
  display: inline-block; vertical-align: middle; margin-right: 8px;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── DIVIDER ─────────────────────────────────────────────── */
.divider {
  height: 1px;
  background: var(--border);
  margin: 24px 0;
}

/* ── NAV LINK ────────────────────────────────────────────── */
.nav-link-wrap {
  margin-top: 16px;
  text-align: center;
}
.nav-link {
  font-size: 12px;
  color: var(--text-muted);
  text-decoration: none;
  border-bottom: 1px dashed var(--border);
  transition: color .2s;
}
.nav-link:hover { color: var(--cyan); }

/* ── FOOTER ──────────────────────────────────────────────── */
footer {
  margin-top: 32px;
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
}
footer a { color: var(--text-muted); text-decoration: none; }
footer a:hover { color: var(--cyan); }

/* ── RESPONSIVE ──────────────────────────────────────────── */
@media (max-width: 420px) {
  .card { padding: 24px 18px; }
  .card-title { font-size: 18px; }
}