:root {
  color-scheme: light dark;
  --fond: #ffffff;
  --texte: #1c1c1e;
  --gris: #6c6c70;
  --discret: #e5e5ea;
  --accent: #a13d2d;
  --marge: 20px;
  font-family: -apple-system, "SF Pro Text", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.3;
  -webkit-text-size-adjust: 100%;
}

@media (prefers-color-scheme: dark) {
  :root {
    --fond: #000000;
    --texte: #f2f2f7;
    --gris: #98989f;
    --discret: #2c2c2e;
    --accent: #e0806b;
  }
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--fond);
  color: var(--texte);
  overscroll-behavior: none;
}

body {
  min-height: 100dvh;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
}

.ecran {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: 0 var(--marge) calc(var(--marge) + env(safe-area-inset-bottom));
}
.ecran[hidden] { display: none; }

.barre {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
}

h1 {
  font-size: 34px;
  font-weight: 700;
  letter-spacing: 0.01em;
  margin: 4px 0 20px;
}
.barre h1 { margin: 0; }

h2 {
  font-size: 13px;
  font-weight: 400;
  color: var(--gris);
  margin: 28px 0 4px;
}

.liste { list-style: none; margin: 0; padding: 0; }
.liste li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 44px;
}

.chiffre, .liste li > span:last-child {
  font-variant-numeric: tabular-nums;
}
.liste li > span:last-child { color: var(--gris); }

button, .action {
  font: inherit;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.lien {
  background: none;
  border: 0;
  padding: 0 0 0 12px;
  min-height: 44px;
  color: var(--accent);
}
.barre .lien:first-child { padding: 0 12px 0 0; }

.action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 20px;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: var(--fond);
  font-weight: 600;
  cursor: pointer;
}
.action.secondaire {
  background: none;
  color: var(--accent);
  padding: 0 4px;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.pied {
  margin-top: auto;
  padding-top: 24px;
  display: flex;
}
.pied .action { flex: 1; }

.boutons {
  display: flex;
  gap: 16px;
  align-items: center;
  margin-top: 16px;
}

.champs input {
  display: block;
  width: 100%;
  font: inherit;
  font-size: 17px;
  color: var(--texte);
  background: none;
  border: 0;
  border-bottom: 1px solid var(--discret);
  border-radius: 0;
  padding: 11px 0;
  min-height: 44px;
}

.etat { color: var(--gris); min-height: 1.3em; margin: 16px 0 0; }
