/* paris-app — sombre, mobile d'abord, gros boutons.
   Regle de couleur : le VERT est reserve au CLV significatif. Jamais un pari
   gagne ne colore quoi que ce soit en vert — c'est tout l'interet de l'app. */

:root {
  --bg:      #0f1115;
  --carte:   #171a21;
  --carte2:  #1e2230;
  --bord:    #2a2f3d;
  --txt:     #e6e8ee;
  --gris:    #8b93a7;
  --gris2:   #5e6678;
  --vert:    #35c27a;
  --rouge:   #e05561;
  --ambre:   #d9a441;
  --bleu:    #5b9cf8;
}

* { box-sizing: border-box; }

body {
  margin: 0; background: var(--bg); color: var(--txt);
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  padding-bottom: 3rem;
}

nav {
  display: flex; gap: .25rem; padding: .5rem;
  background: var(--carte); border-bottom: 1px solid var(--bord);
  position: sticky; top: 0; z-index: 10;
}
nav a {
  flex: 1; text-align: center; padding: .7rem .4rem; border-radius: 9px;
  color: var(--gris); text-decoration: none; font-weight: 600; font-size: .92rem;
}
nav a.on { background: var(--carte2); color: var(--txt); }
nav a b {
  background: var(--bleu); color: #0b1220; border-radius: 99px;
  padding: 0 .4rem; font-size: .78rem; margin-left: .15rem;
}

main { padding: .9rem; max-width: 760px; margin: 0 auto; }
footer {
  text-align: center; color: var(--gris2); font-size: .78rem;
  padding: 1.2rem .9rem 2rem;
}

h1 { font-size: 1.25rem; margin: .2rem 0 1rem; }
h2 { font-size: 1rem; margin: 1.6rem 0 .6rem; color: var(--gris); font-weight: 600; }
.muet { color: var(--gris); font-size: .85rem; }
.mini { font-size: .78rem; color: var(--gris2); }

/* ── cartes ───────────────────────────────────────────────────────────── */
.carte {
  background: var(--carte); border: 1px solid var(--bord);
  border-radius: 13px; padding: .85rem; margin-bottom: .6rem;
}
.match { display: block; text-decoration: none; color: inherit; }
.match:active { background: var(--carte2); }
.match .haut { display: flex; justify-content: space-between; gap: .6rem; align-items: baseline; }
.match .noms { font-weight: 600; }
.cotes { display: flex; gap: .4rem; margin-top: .5rem; }
.cotes span {
  background: var(--carte2); border: 1px solid var(--bord); border-radius: 8px;
  padding: .25rem .5rem; font-variant-numeric: tabular-nums; font-size: .9rem;
}

.etiq {
  display: inline-block; font-size: .7rem; text-transform: uppercase;
  letter-spacing: .04em; color: var(--gris2); border: 1px solid var(--bord);
  border-radius: 99px; padding: .05rem .5rem;
}

/* Surfaces : couleurs du tennis, pas de vert (reserve au CLV significatif). */
.etiq.surf-clay  { color: #e08a4a; border-color: #6b4326; }
.etiq.surf-hard  { color: #5b9cf8; border-color: #2a4570; }
.etiq.surf-grass { color: #7fc6a4; border-color: #2f5c48; }
.etiq.surf-carpet{ color: #b39ddb; border-color: #4a3d66; }
.etiq.surf-inconnue { color: var(--gris2); border-style: dashed; }

/* ── puces de filtre ──────────────────────────────────────────────────── */
.puces {
  display: flex; flex-wrap: wrap; gap: .35rem; margin: 0 0 .9rem;
}
.puces a {
  display: inline-flex; align-items: center; gap: .35rem;
  background: var(--carte); border: 1px solid var(--bord); border-radius: 99px;
  padding: .4rem .75rem; font-size: .85rem; font-weight: 600;
  color: var(--gris2); text-decoration: none;
}
.puces a.on { background: var(--bleu); border-color: var(--bleu); color: #0b1220; }
.puces a s { text-decoration: none; opacity: .55; font-weight: 500; }
.puces a.on s { opacity: .7; }
.puces a.reset { border-style: dashed; }

/* ── offres pariables ─────────────────────────────────────────────────── */
.offre {
  display: flex; align-items: center; gap: .6rem;
  border-top: 1px solid var(--bord); padding: .55rem 0;
}
.offre:first-of-type { border-top: 0; }
.offre .lib { flex: 1; font-size: .93rem; }
.offre button {
  background: var(--bleu); color: #0b1220; border: 0; border-radius: 9px;
  padding: .55rem .85rem; font-weight: 700; font-size: .95rem;
  font-variant-numeric: tabular-nums; cursor: pointer; min-width: 76px;
}
.offre button:active { transform: scale(.97); }

input[type=number] {
  background: var(--carte2); border: 1px solid var(--bord); color: var(--txt);
  border-radius: 8px; padding: .5rem; width: 74px; font-size: 1rem;
}

/* ── le compteur honnete ──────────────────────────────────────────────── */
.grand {
  font-size: 3rem; font-weight: 800; line-height: 1.05;
  font-variant-numeric: tabular-nums; letter-spacing: -.02em;
}
.bon      { color: var(--vert); }
.mauvais  { color: var(--rouge); }
.indecis, .tot, .vide { color: var(--txt); }

.jauge { background: var(--carte2); border-radius: 99px; height: 8px; overflow: hidden; margin: .8rem 0 .4rem; }
.jauge i { display: block; height: 100%; background: var(--bleu); }

.avert {
  border-left: 3px solid var(--ambre); background: rgba(217,164,65,.07);
  padding: .6rem .8rem; border-radius: 0 9px 9px 0; font-size: .86rem; color: var(--gris);
}

table { width: 100%; border-collapse: collapse; font-size: .88rem; }
th { text-align: left; color: var(--gris2); font-weight: 600; font-size: .76rem;
     text-transform: uppercase; letter-spacing: .04em; padding: .35rem .3rem; }
td { padding: .45rem .3rem; border-top: 1px solid var(--bord); font-variant-numeric: tabular-nums; }
td.num, th.num { text-align: right; }

/* ── boutons de resolution ────────────────────────────────────────────── */
.actions { display: flex; gap: .35rem; margin-top: .55rem; flex-wrap: wrap; }
.actions button {
  background: var(--carte2); color: var(--gris); border: 1px solid var(--bord);
  border-radius: 8px; padding: .4rem .7rem; font-size: .84rem; cursor: pointer;
}
.actions button:active { background: var(--bord); }
.actions form { display: inline; }

.vide-etat { text-align: center; color: var(--gris2); padding: 3rem 1rem; }
