/* Page publique — pensee pour le mobile d'abord. */

:root {
  --bg: #080d18;
  --bg-2: #101a2e;
  --surface: rgba(255, 255, 255, 0.055);
  --surface-hover: rgba(255, 255, 255, 0.1);
  --border: rgba(255, 255, 255, 0.11);
  --text: #f2f6fc;
  --muted: #93a3bd;
  --tg-a: #33b1f0;
  --tg-b: #1d8fce;
  --radius: 18px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(24px, env(safe-area-inset-top)) 20px max(24px, env(safe-area-inset-bottom));
  background:
    radial-gradient(100% 65% at 50% 0%, rgba(51, 177, 240, 0.20) 0%, transparent 62%),
    linear-gradient(178deg, var(--bg-2) 0%, var(--bg) 55%);
  background-attachment: fixed;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.5;
}

.card {
  width: 100%;
  max-width: 440px;
  text-align: center;
  animation: rise 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* ---- Avatar ---- */

.avatar-wrap {
  display: inline-block;
  padding: 3px;
  border-radius: 50%;
  background: linear-gradient(150deg, var(--tg-a), rgba(255, 255, 255, 0.15) 55%, var(--tg-b));
  box-shadow: 0 14px 40px rgba(29, 143, 206, 0.32);
}

.avatar {
  display: block;
  width: 112px;
  height: 112px;
  border-radius: 50%;
  object-fit: cover;
  background: #16203a;
  border: 3px solid #0b1120;
}

.avatar--empty {
  display: grid;
  place-items: center;
  font-size: 38px;
  font-weight: 700;
  letter-spacing: 1px;
  color: #cfe6f7;
  background: linear-gradient(150deg, #1d3352, #12203a);
}

/* ---- Textes ---- */

.title {
  margin: 18px 0 0;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.4px;
  overflow-wrap: anywhere;
}

.subtitle {
  margin: 8px auto 0;
  max-width: 34ch;
  font-size: 15px;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.notice {
  margin: 16px 0 0;
  padding: 11px 14px;
  font-size: 13.5px;
  text-align: left;
  color: #ffe0b0;
  background: rgba(255, 176, 46, 0.11);
  border: 1px solid rgba(255, 176, 46, 0.3);
  border-radius: 13px;
  overflow-wrap: anywhere;
}

/* ---- Boutons ---- */

.links {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 26px;
}

.btn {
  display: flex;
  align-items: center;
  gap: 13px;
  min-height: 62px;
  padding: 0 16px;
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--text);
  font-size: 16.5px;
  font-weight: 600;
  text-align: left;
  border: 1px solid var(--border);
  background: var(--surface);
  transition: transform 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
  animation: rise 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: calc(0.07s * var(--i, 0) + 0.1s);
}

.btn--primary {
  background: linear-gradient(135deg, var(--tg-a), var(--tg-b));
  border-color: transparent;
  box-shadow: 0 10px 26px rgba(29, 143, 206, 0.35);
}

.btn__icon {
  display: grid;
  place-items: center;
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.16);
}

.btn__icon svg { width: 21px; height: 21px; fill: #fff; }

.btn--ghost .btn__icon { background: rgba(51, 177, 240, 0.17); }
.btn--ghost .btn__icon svg { fill: var(--tg-a); }

.btn__label { flex: 1; overflow-wrap: anywhere; }

.chev { width: 19px; height: 19px; flex: 0 0 19px; opacity: 0.55; }

@media (hover: hover) {
  .btn:hover { transform: translateY(-2px); background: var(--surface-hover); }
  .btn--primary:hover { background: linear-gradient(135deg, #3fbcf8, #2199da); }
}

.btn:active { transform: scale(0.985); }

.empty {
  padding: 26px 18px;
  color: var(--muted);
  font-size: 15px;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
}

/* ---- Pied de page ---- */

.foot {
  margin: 26px 0 0;
  font-size: 12.5px;
  color: rgba(147, 163, 189, 0.75);
}

.dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-bottom: 1px;
  border-radius: 50%;
  background: #3ddc84;
  box-shadow: 0 0 8px rgba(61, 220, 132, 0.8);
}

@keyframes rise {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

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

/* Tres petits ecrans */
@media (max-width: 360px) {
  .avatar { width: 92px; height: 92px; }
  .title { font-size: 23px; }
  .btn { min-height: 58px; font-size: 15.5px; }
}

/* ---- Acces administrateur (petit cadenas discret) ---- */

.lock {
  display: inline-grid;
  place-items: center;
  width: 44px;               /* zone tactile confortable */
  height: 44px;
  margin-top: 6px;
  border-radius: 50%;
  color: var(--muted);
  opacity: 0.32;
  text-decoration: none;
  transition: opacity 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.lock svg { width: 17px; height: 17px; fill: currentColor; }

.lock:active { transform: scale(0.92); opacity: 0.85; }

@media (hover: hover) {
  .lock:hover { opacity: 0.9; background: rgba(255, 255, 255, 0.07); }
}

.lock:focus-visible {
  outline: none;
  opacity: 1;
  box-shadow: 0 0 0 3px rgba(51, 177, 240, 0.35);
}
