/* =========================================================
   citizen.css — application citoyenne (utilitaire, sobre)
   ========================================================= */

body.citizen-app { background: var(--surface-soft); color: var(--ink); }

/* --- Connexion page --- */
.auth-shell { min-height: calc(100vh - 29px); display: grid; grid-template-columns: 1.1fr 1fr; }
.auth-visual {
  position: relative; padding: 48px 56px;
  background: linear-gradient(150deg, var(--forest-950), var(--forest-800));
  color: #d6e2db; display: flex; flex-direction: column; justify-content: space-between;
  overflow: hidden;
}
.auth-visual::before { content: ""; position: absolute; top: -100px; right: -80px; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(circle, rgba(210, 165, 74, .12), transparent 65%); }
.auth-visual .brand { color: #fff; position: relative; z-index: 1; }
.auth-visual .brand-mark { color: var(--emerald-300); }
.auth-visual .brand-tag { color: #8ea59a; }
.auth-visual .auth-message { position: relative; z-index: 1; max-width: 460px; margin: auto 0; }
.auth-visual .auth-message h1 { color: #fff; font-size: clamp(2rem, 3vw, 2.8rem); margin-bottom: 16px; }
.auth-visual .auth-message p { color: #b7c8bf; font-size: 1.05rem; }
.auth-points { position: relative; z-index: 1; display: grid; gap: 12px; margin-top: 32px; }
.auth-point { display: flex; align-items: flex-start; gap: 10px; color: #c2d2c9; font-size: .88rem; }
.auth-point::before { content: "✓"; color: var(--emerald-300); font-weight: 700; margin-top: 1px; }
.auth-foot { position: relative; z-index: 1; font-size: .76rem; color: #6f8579; }
.auth-panel { align-self: center; padding: 48px 56px; background: var(--white); }
.auth-panel h2 { font-size: 1.7rem; margin-bottom: 8px; }
.auth-panel > p { color: var(--ink-soft); margin-bottom: 24px; }
.auth-back { margin-top: 18px; display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: .86rem; }
.auth-back:hover { color: var(--emerald-700); }

/* --- App shell authentifié --- */
.citizen-shell { min-height: calc(100vh - 29px); display: flex; flex-direction: column; }
.app-header {
  position: sticky; top: 0; z-index: 30;
  height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 0 24px; background: rgba(255, 255, 255, .9);
  backdrop-filter: saturate(160%) blur(12px); -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line-soft);
}
.app-title { font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; }
.app-id { color: var(--muted); font-size: .82rem; font-family: "SF Mono", "Roboto Mono", ui-monospace, monospace; }
.app-actions { display: flex; align-items: center; gap: 8px; }
.app-link { padding: 8px 12px; border-radius: var(--r-xs); color: var(--ink-soft); font-size: .86rem; font-weight: 500; transition: all var(--t-fast); }
.app-link:hover { background: var(--emerald-050); color: var(--emerald-700); }
.app-menu-toggle { display: none; }

.app-main { flex: 1; padding: 24px 0 96px; }
.app-main .container { width: min(720px, calc(100% - 40px)); }

/* --- Dossier : blocs --- */
.status-block {
  background: var(--white); border: 1px solid var(--line-soft); border-radius: var(--r-citizen);
  padding: 26px; box-shadow: var(--shadow-sm); margin-bottom: 16px;
}
.status-top { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.status-icon { width: 36px; height: 36px; border-radius: var(--r-citizen); background: var(--emerald-050); color: var(--emerald-600); display: grid; place-items: center; flex-shrink: 0; }
.status-icon svg { width: 20px; height: 20px; }
.status-block h2 { font-size: 1.5rem; margin-bottom: 6px; }
.status-block .status-explain { color: var(--ink-soft); margin-bottom: 18px; }
.next-action {
  margin-top: 18px; padding: 16px 18px; border-radius: var(--r-xs);
  background: var(--ivory); border-left: 3px solid var(--gold-500);
}
.next-action .label { font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.next-action .step { font-weight: 600; color: var(--ink); margin-top: 4px; }
.status-updated { margin-top: 16px; color: var(--muted); font-size: .82rem; }

/* progress blocks */
.block { background: var(--white); border: 1px solid var(--line-soft); border-radius: var(--r-citizen); padding: 22px 24px; box-shadow: var(--shadow-xs); margin-bottom: 14px; }
.block-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.block-head h3 { font-size: 1rem; }
.block-head .meta { color: var(--muted); font-size: .8rem; }

/* activation card */
.activation-card {
  background: linear-gradient(135deg, var(--white), var(--emerald-050));
  border: 1px solid var(--emerald-300); border-radius: var(--r-citizen);
  padding: 24px; box-shadow: var(--shadow-sm); margin-bottom: 14px;
}
.activation-card .label { color: var(--emerald-700); font-size: .74rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.activation-card h3 { font-size: 1.15rem; margin: 8px 0 8px; }
.activation-card p { color: var(--ink-soft); font-size: .9rem; margin-bottom: 14px; }
.activation-card .price { font-family: var(--font-display); font-weight: 600; color: var(--forest-950); }

/* notifications list */
.notif-list { display: grid; gap: 10px; }
.notif-day { color: var(--muted); font-size: .78rem; font-weight: 600; letter-spacing: .04em; margin: 18px 0 6px; }
.notif-day:first-child { margin-top: 0; }
.notif-item {
  display: grid; grid-template-columns: 10px 1fr auto; gap: 12px; align-items: start;
  padding: 14px 16px; border: 1px solid var(--line-soft); border-radius: var(--r-citizen); background: var(--white);
}
.notif-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--emerald-600); margin-top: 6px; box-shadow: 0 0 0 3px var(--emerald-100); }
.notif-item.read .notif-dot { background: var(--line-strong); box-shadow: none; }
.notif-body strong { display: block; font-size: .9rem; font-weight: 600; }
.notif-body p { margin: 2px 0 0; color: var(--muted); font-size: .82rem; }
.notif-channel { color: var(--muted); font-size: .74rem; align-self: center; }
.notif-empty { text-align: center; padding: 60px 20px; color: var(--muted); }

/* paiement page */
.pay-shell { min-height: calc(100vh - 29px); }
.pay-wrap { width: min(560px, calc(100% - 40px)); margin: 0 auto; padding: 32px 0 80px; }
.pay-steps { display: flex; align-items: center; gap: 4px; margin-bottom: 28px; }
.pay-step { flex: 1; height: 4px; border-radius: 2px; background: var(--line); }
.pay-step.active { background: var(--emerald-600); }
.pay-step.done { background: var(--emerald-600); }
.pay-card { background: var(--white); border: 1px solid var(--line-soft); border-radius: var(--r-citizen); padding: 28px; box-shadow: var(--shadow-sm); }
.pay-card h2 { font-size: 1.4rem; margin-bottom: 8px; }
.pay-card > p { color: var(--ink-soft); margin-bottom: 22px; }
.pay-summary { display: grid; gap: 2px; border: 1px solid var(--line-soft); border-radius: var(--r-citizen); overflow: hidden; margin: 18px 0; }
.pay-summary .receipt-row { background: var(--white); border-radius: 0; }
.pay-summary .receipt-row:nth-child(odd) { background: var(--ivory); }
.pay-note { padding: 12px 14px; border-radius: var(--r-xs); background: var(--warning-50); border-left: 3px solid var(--warning); color: var(--warning); font-size: .82rem; margin: 18px 0; }
.pay-foot { display: flex; gap: 10px; justify-content: space-between; margin-top: 22px; }
.processing { text-align: center; padding: 30px 0; }
.spinner { width: 40px; height: 40px; margin: 0 auto 18px; border: 3px solid var(--emerald-100); border-top-color: var(--emerald-600); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.receipt-success { text-align: center; }
.receipt-success .check { width: 56px; height: 56px; margin: 0 auto 18px; border-radius: 50%; background: var(--success-50); color: var(--success); display: grid; place-items: center; }
.receipt-success .check svg { width: 28px; height: 28px; }

/* --- Bottom nav mobile --- */
.bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 45;
  display: none; background: rgba(255, 255, 255, .95);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--line-soft);
  padding: 7px 12px max(7px, env(safe-area-inset-bottom));
  justify-content: space-around;
}
.bottom-nav a {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 8px 16px; border-radius: var(--r-pill);
  color: var(--muted); font-size: .66rem; font-weight: 600;
  transition: color var(--t-fast), background var(--t-fast);
}
.bottom-nav a svg { width: 22px; height: 22px; }
.bottom-nav a.active, .bottom-nav a:hover { color: var(--emerald-700); background: var(--emerald-050); }

/* --- Aide drawer/sheet --- */
.help-drawer {
  position: fixed; z-index: 61; top: 0; right: 0; bottom: 0;
  width: min(480px, 100%); background: var(--white); box-shadow: var(--shadow-lg); overflow: auto;
  transform: translateX(100%); transition: transform .24s var(--ease);
}
.help-drawer.open { transform: translateX(0); }
.help-backdrop { position: fixed; inset: 0; z-index: 60; background: rgba(6, 43, 32, .4); }
.help-item { padding: 18px 24px; border-bottom: 1px solid var(--line-soft); }
.help-item h4 { font-size: .96rem; margin-bottom: 6px; }
.help-item p { color: var(--ink-soft); font-size: .88rem; margin: 0; }
