:root { font-family: 'Segoe UI', system-ui, sans-serif; }
* { box-sizing: border-box; }
body {
  margin: 0; padding: 24px 16px 60px;
  background: linear-gradient(160deg, #0b3d2e 0%, #14532d 55%, #7f1d1d 130%);
  color: #f8fafc; min-height: 100vh;
  background-image:
    radial-gradient(circle at 12% 20%, rgba(255,255,255,.08) 0 2px, transparent 3px),
    radial-gradient(circle at 78% 34%, rgba(255,255,255,.07) 0 2px, transparent 3px),
    radial-gradient(circle at 45% 78%, rgba(255,255,255,.06) 0 2px, transparent 3px),
    linear-gradient(160deg, #0b3d2e 0%, #14532d 55%, #7f1d1d 130%);
}
.card {
  max-width: 560px; margin: 0 auto;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 20px; padding: 28px 24px;
  backdrop-filter: blur(6px);
  box-shadow: 0 20px 50px rgba(0,0,0,.35);
}
h1 { text-align: center; font-size: 1.5rem; margin: 0 0 4px; }
.subtitle { text-align: center; opacity: .85; font-size: .95rem; margin: 0 0 24px; }
.category {
  background: rgba(0,0,0,.22); border-radius: 14px;
  padding: 18px; margin-bottom: 18px;
  border: 1px solid rgba(255,255,255,.12);
}
.category label.cat-title {
  display: block; font-weight: 700; font-size: 1.05rem; margin-bottom: 10px;
}
input[type="text"] {
  width: 100%; padding: 12px 14px; font-size: 1rem;
  border-radius: 10px; border: 1px solid rgba(255,255,255,.25);
  background: rgba(255,255,255,.92); color: #111827;
}
input[type="text"]:focus { outline: 3px solid #fbbf24; }
.hint { font-size: .8rem; opacity: .7; margin: 6px 2px 0; }
.error { color: #fecaca; font-size: .85rem; margin: 10px 2px 0; display: none; text-align: center; }
button, a.btn {
  display: block; width: 100%; margin-top: 8px;
  padding: 15px; font-size: 1.05rem; font-weight: 700;
  border: none; border-radius: 12px; cursor: pointer;
  background: linear-gradient(180deg, #fbbf24, #d97706); color: #1c1917;
  box-shadow: 0 8px 20px rgba(217,119,6,.4);
  text-align: center; text-decoration: none;
}
button:active { transform: translateY(1px); }
button[disabled] { opacity: .6; cursor: wait; }
a.btn.secondary {
  background: rgba(255,255,255,.12); color: #f8fafc;
  box-shadow: none; border: 1px solid rgba(255,255,255,.25);
}
#confirmation { display: none; text-align: center; padding: 30px 10px; }
#confirmation .big { font-size: 3rem; }
footer { text-align: center; margin-top: 22px; font-size: .8rem; opacity: .6; }
footer a { color: inherit; }

/* --- Page de résultats --- */
.results-nav { display: flex; gap: 10px; margin-bottom: 20px; }
.results-nav a, .results-nav button {
  flex: 1; width: auto; margin-top: 0; padding: 10px; font-size: .95rem;
}
.result-block { margin-bottom: 8px; }
.result-line {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 4px; border-bottom: 1px dashed rgba(255,255,255,.14);
}
.result-line:last-child { border-bottom: none; }
.rank { width: 30px; text-align: center; font-size: 1.1rem; flex-shrink: 0; }
.name { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.count {
  background: rgba(251,191,36,.18); border: 1px solid rgba(251,191,36,.45);
  color: #fde68a; border-radius: 999px; padding: 2px 10px; font-size: .85rem; font-weight: 700;
}
.empty { opacity: .6; font-style: italic; text-align: center; margin: 6px 0; }

/* --- Zone organisateur (page de résultats) --- */
.admin input[type="password"] {
  width: 100%; padding: 12px 14px; font-size: 1rem;
  border-radius: 10px; border: 1px solid rgba(255,255,255,.25);
  background: rgba(255,255,255,.92); color: #111827;
}
.admin input[type="password"]:focus { outline: 3px solid #fbbf24; }
.admin button {
  background: linear-gradient(180deg, #ef4444, #b91c1c); color: #fff;
  box-shadow: 0 8px 20px rgba(185,28,28,.35); font-size: .95rem; padding: 12px;
}
