body.admin { background: #F2ECE2; font-family: Montserrat, system-ui, sans-serif; color: #2A190E; }
.admin .top { background: #1F2A4A; color: #fff; padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; gap: 10px; position: sticky; top: 0; z-index: 5; }
.admin .top h1 { margin: 0; font-size: 17px; font-weight: 700; }
.admin .top button { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.5); border-radius: 8px; padding: 8px 12px; font: inherit; font-size: 13px; cursor: pointer; min-height: 40px; }
.admin main { max-width: 820px; margin: 0 auto; padding: 14px 12px 60px; display: flex; flex-direction: column; gap: 14px; }
.tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; background: #fff; padding: 6px; border-radius: 12px; }
.tabs button { min-height: 44px; border: 0; border-radius: 8px; background: transparent; font: inherit; font-weight: 700; font-size: 14px; color: #5E4A3A; cursor: pointer; }
.tabs button[aria-selected="true"] { background: #1F2A4A; color: #fff; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.stat { background: #fff; border-radius: 12px; padding: 12px 10px; text-align: center; }
.stat b { display: block; font-size: 24px; }
.stat span { font-size: 12px; color: #5E4A3A; }
.stat.main { background: #1F2A4A; color: #fff; }
.stat.main span { color: #E6DCCB; }
.stat.ok b { color: #2E7D4F; }
.stats-max { margin: -4px 2px 0; font-size: 13px; color: #5E4A3A; line-height: 1.5; }
.stats-max:empty { display: none; }
.box { background: #fff; border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.box h2 { margin: 0; font-size: 18px; }
.box p.hint { margin: 0; font-size: 13px; color: #5E4A3A; line-height: 1.5; }
.row { display: flex; gap: 8px; flex-wrap: wrap; }
.row > * { flex: 1 1 160px; }
.admin label.f { display: flex; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 600; }
.admin input, .admin select, .admin textarea { font: inherit; font-size: 16px; padding: 10px 12px; border: 1.5px solid #CDBDA5; border-radius: 9px; background: #fff; color: #2A190E; min-height: 44px; }
.admin textarea { min-height: 90px; resize: vertical; }
.admin .check { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; min-height: 44px; }
.admin .check input { width: 22px; height: 22px; min-height: 0; }
.b { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 42px; padding: 8px 14px; border-radius: 9px; border: 1.5px solid #1F2A4A; background: #fff; color: #1F2A4A; font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; text-decoration: none; }
.b.primary { background: #1F2A4A; color: #fff; }
.b.wa { background: #1E7A45; border-color: #1E7A45; color: #fff; }
.b.danger { border-color: #9A2A1A; color: #9A2A1A; }
.b:disabled { opacity: .55; cursor: default; }
.guest { background: #fff; border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.guest.inactive { opacity: .6; }
.guest-head { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.guest-name { font-weight: 700; font-size: 16px; }
.guest-sub { font-size: 13px; color: #5E4A3A; margin-top: 2px; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badge { font-size: 12px; font-weight: 700; padding: 4px 8px; border-radius: 999px; background: #EEE6DA; color: #4A3A2C; }
.badge.ok { background: #DDEEDC; color: #23562C; }
.badge.no { background: #F4E0DB; color: #8A2414; }
.badge.warn { background: #FFF0C7; color: #6B4A00; }
.badge.blue { background: #DCE3F3; color: #1F2A4A; }
.guest-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; }
.guest details summary { cursor: pointer; font-size: 13px; font-weight: 700; color: #1F2A4A; min-height: 32px; display: flex; align-items: center; }
.guest details[open] summary { margin-bottom: 10px; }
.guest .msg { font-size: 13px; background: #F7F2EA; border-radius: 8px; padding: 8px 10px; font-style: italic; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); background: #2A190E; color: #fff; padding: 12px 18px; border-radius: 10px; font-size: 14px; font-weight: 600; z-index: 50; max-width: 90vw; }
.login { max-width: 380px; margin: 12vh auto 0; }
.empty { text-align: center; color: #5E4A3A; font-size: 14px; padding: 24px 0; }
.checkin-name { font-size: 28px; font-weight: 700; text-align: center; }
.checkin-state { text-align: center; font-size: 16px; font-weight: 700; padding: 14px; border-radius: 10px; }
.relance h2 { font-size: 17px; }
.relance-next { display: flex; flex-direction: column; gap: 10px; background: #F3F7F2; border: 1.5px solid #BFD9C4; border-radius: 10px; padding: 12px; }
.relance-next b { display: block; font-size: 17px; }
.relance-next span { display: block; font-size: 13px; color: #5E4A3A; margin-top: 2px; }

/* Contrat : période du site (consultation, fermé), invitations payées, champs verrouillés */
.contrat { gap: 6px; border-left: 4px solid #B8860B; font-size: 15px; line-height: 1.55; color: #3B2A1C; }
.contrat b { font-size: 17px; }
.quota { margin: 0; padding: 10px 14px; border-radius: 10px; background: #fff; font-size: 14px; color: #3B2A1C; }
.quota.plein { background: #FFF0C7; color: #6B4A00; font-weight: 600; }
input[readonly] { background: #F3EFE9; color: #5E4A3A; cursor: not-allowed; }
.phase-consultation .tabs, .phase-consultation #relance,
.phase-consultation .guest-actions, .phase-consultation .guest details, .phase-consultation #lien-checkin { display: none !important; }
.phase-ferme .tabs, .phase-ferme section[role="tabpanel"] { display: none !important; }

/* Appareils d'une invitation : autorisés (✓) et bloqués (🔒, avec « Autoriser cet appareil ») */
.appareils { border: 1px solid #E6DDD2; border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; background: #FBF8F4; }
.appareils.alerte { border-color: #E3A39B; background: #FFF4F2; }
.appareils .app-titre { margin: 0; font-weight: 700; font-size: 14px; }
.appareils.alerte .app-titre { color: #A8322D; }
.appareils ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.appareils .app { font-size: 14px; line-height: 1.45; }
.appareils .app.ok { color: #2F5D45; }
.appareils .app.bloque { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding-top: 8px; border-top: 1px dashed #E3C7C2; }
.appareils .app.bloque b { flex-basis: 100%; }
.appareils .app-sub { font-size: 13px; color: #5E4A3A; }
.appareils .hint { margin: 0; font-size: 12.5px; color: #5E4A3A; line-height: 1.5; }
.phase-consultation .appareils button { display: none; }

/* Numéros de téléphone : choix du pays (assets/telephone.js) */
.tel-champ > input { width: 100%; }
.bulk-pays { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tel-pays { font-family: Montserrat, system-ui, sans-serif; }
.row > .tel-large { flex: 1 1 100%; min-width: 0; }

/* Scanner de l'accueil jour J (admin/checkin.html) */
.scan { align-items: stretch; }
.scan-video { position: relative; border-radius: 12px; overflow: hidden; background: #000; aspect-ratio: 1 / 1; max-height: 62vh; }
.scan-video video { width: 100%; height: 100%; object-fit: cover; display: block; }
.scan-cadre { position: absolute; inset: 16%; border: 3px solid rgba(255, 255, 255, .9); border-radius: 18px; box-shadow: 0 0 0 999px rgba(0, 0, 0, .28); }
.scan-pause { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); margin: 0; padding: 8px 14px; border-radius: 999px; background: rgba(0, 0, 0, .65); color: #fff; font-weight: 600; font-size: 14px; }
.scan-bouton { min-height: 52px; font-size: 16px; }
#scan-info { text-align: center; }
