:root {
  --bg: #0a0e16;
  --card: rgba(16, 22, 34, 0.88);
  --line: rgba(212, 160, 23, 0.22);
  --text: #f2f5fa;
  --muted: #9aa8b8;
  --gold: #d4a017;
  --gold-soft: rgba(212, 160, 23, 0.15);
  --ok: #2a9d6a;
  --danger: #c44536;
  --font: "Segoe UI", system-ui, -apple-system, sans-serif;
  --radius: 20px;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; font-family: var(--font); color: var(--text); }

body.kiosk {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse at 15% 10%, rgba(212,160,23,0.18), transparent 45%),
    radial-gradient(ellipse at 85% 90%, rgba(42,157,106,0.12), transparent 40%),
    linear-gradient(165deg, rgba(8,11,18,0.92), rgba(10,14,22,0.94)),
    url('https://images.unsplash.com/photo-1497366216548-37526070297c?auto=format&fit=crop&w=1800&q=75');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}
body.admin-page {
  min-height: 100vh;
  background:
    radial-gradient(ellipse at 0% 0%, rgba(212,160,23,0.1), transparent 40%),
    linear-gradient(180deg, #0a0e16, #121a28);
  padding: 1.25rem;
}

/* Décor formes or */
.deco {
  position: fixed;
  pointer-events: none;
  z-index: 0;
  opacity: 0.35;
}
.deco-ring {
  width: 180px; height: 180px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  top: 8%; right: 6%;
}
.deco-ring::after {
  content: '';
  position: absolute;
  inset: 14px;
  border: 1px solid rgba(212,160,23,0.4);
  border-radius: 50%;
}
.deco-bar {
  width: 4px; height: 120px;
  background: linear-gradient(180deg, transparent, var(--gold), transparent);
  left: 4%; top: 30%;
  border-radius: 4px;
}
.deco-dot {
  width: 10px; height: 10px;
  background: var(--gold);
  border-radius: 50%;
  bottom: 12%; left: 12%;
  box-shadow: 0 0 20px var(--gold);
}

.shell { width: 100%; max-width: 440px; position: relative; z-index: 1; }
.shell.wide { max-width: 1120px; margin: 0 auto; }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem 1.35rem;
  box-shadow:
    0 20px 50px rgba(0,0,0,0.45),
    inset 0 1px 0 rgba(255,255,255,0.04);
  backdrop-filter: blur(16px);
  position: relative;
  overflow: hidden;
}
.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.brand-head {
  text-align: center;
  margin-bottom: 1.25rem;
}
.brand-logo {
  height: 52px; width: auto; max-width: 140px;
  object-fit: contain; display: none; margin: 0 auto 0.5rem;
  border-radius: 8px;
}
.brand-head.has-logo .brand-logo { display: block; }
.brand-head.has-logo .mark { display: none; }
.mark {
  width: 56px; height: 56px; margin: 0 auto 0.6rem;
  border-radius: 16px;
  background: linear-gradient(145deg, #e8c547, #a67c00);
  display: grid; place-items: center;
  font-weight: 800; font-size: 1.35rem; color: #1a1200;
  box-shadow: 0 8px 24px rgba(212,160,23,0.35);
}
.eyebrow {
  font-size: 0.68rem; font-weight: 700; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--gold); margin: 0;
}
h1 { margin: 0.25rem 0; font-size: 1.4rem; font-weight: 700; letter-spacing: 0.02em; }
h2 {
  margin: 0 0 0.85rem; font-size: 1.05rem; font-weight: 700;
  display: flex; align-items: center; gap: 0.5rem;
}
h2::before {
  content: '';
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--gold); box-shadow: 0 0 8px var(--gold);
}
.muted { color: var(--muted); font-size: 0.9rem; line-height: 1.45; }
.site-tag {
  color: var(--gold); font-size: 0.72rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
}

.btn {
  border: none; border-radius: 14px; padding: 0.95rem 1.15rem;
  font-weight: 700; font-size: 1rem; cursor: pointer;
  background: linear-gradient(145deg, #e0b12a, #b8860b);
  color: #1a1200; width: 100%;
  box-shadow: 0 6px 20px rgba(212,160,23,0.3);
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn:hover { transform: translateY(-1px); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
.btn.secondary {
  background: transparent; color: var(--text);
  border: 1px solid var(--line); box-shadow: none;
}
.btn.ok {
  background: linear-gradient(145deg, #34b87a, #1f7a50);
  color: #fff; box-shadow: 0 6px 18px rgba(42,157,106,0.3);
}
.btn.danger {
  background: linear-gradient(145deg, #e05a4a, #a33228);
  color: #fff; box-shadow: 0 6px 18px rgba(196,69,54,0.3);
}
.btn.half { width: auto; flex: 1; }
.btn.sm { width: auto; padding: 0.55rem 0.9rem; font-size: 0.85rem; }

.row { display: flex; gap: 0.65rem; }
select, input, textarea {
  width: 100%; padding: 0.85rem 0.95rem; border-radius: 12px;
  border: 1px solid var(--line); background: rgba(8,12,20,0.75);
  color: var(--text); margin: 0.35rem 0 0.85rem; font-size: 1rem;
}
label { font-size: 0.82rem; color: var(--muted); font-weight: 600; }
.hidden { display: none !important; }

/* Welcome + photo */
.welcome-screen { text-align: center; padding: 0.5rem 0 0.25rem; }
.photo-frame {
  width: 112px; height: 112px; margin: 0 auto 1rem;
  border-radius: 50%;
  padding: 4px;
  background: linear-gradient(145deg, #e8c547, #8a6a10);
  box-shadow: 0 10px 30px rgba(212,160,23,0.35);
}
.photo-frame img {
  width: 100%; height: 100%; border-radius: 50%;
  object-fit: cover; display: block; background: #1a2230;
}
.photo-placeholder {
  width: 100%; height: 100%; border-radius: 50%;
  background: linear-gradient(145deg, #2a3548, #1a2230);
  display: grid; place-items: center;
  font-size: 2rem; font-weight: 700; color: var(--gold);
}
.hello {
  font-size: clamp(1.25rem, 4.5vw, 1.7rem);
  font-weight: 700; color: var(--gold);
  margin: 0.35rem 0 0.75rem; line-height: 1.3;
}
.confirm-pill {
  display: inline-block;
  padding: 0.4rem 0.9rem; border-radius: 999px;
  font-size: 0.85rem; font-weight: 700;
  background: var(--gold-soft); color: var(--gold);
  border: 1px solid rgba(212,160,23,0.35);
  margin-bottom: 1rem;
}
.confirm-pill.late {
  background: rgba(196,69,54,0.15); color: #ff8a7a;
  border-color: rgba(196,69,54,0.35);
}
.info-grid {
  text-align: left; margin: 0.5rem 0 1rem;
  display: grid; gap: 0.45rem;
}
.info-grid div {
  display: flex; justify-content: space-between; gap: 0.75rem;
  padding: 0.6rem 0.75rem; border-radius: 12px;
  background: rgba(0,0,0,0.28);
  border: 1px solid rgba(255,255,255,0.06);
  font-size: 0.9rem;
}
.info-grid span { color: var(--muted); }
.info-grid strong { color: var(--text); text-align: right; }

table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
th, td { text-align: left; padding: 0.6rem 0.4rem; border-bottom: 1px solid rgba(255,255,255,0.06); }
th { color: var(--muted); font-weight: 600; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.04em; }
.badge {
  display: inline-block; padding: 0.2rem 0.55rem; border-radius: 999px;
  font-size: 0.72rem; font-weight: 700;
}
.badge.in { background: rgba(42,157,106,0.2); color: #3dd68c; }
.badge.out { background: rgba(196,69,54,0.2); color: #ff8a7a; }
.badge.late { background: rgba(212,160,23,0.2); color: #e8c547; }
.live { color: var(--ok); font-weight: 700; font-size: 0.82rem; }
.toolbar {
  display: flex; flex-wrap: wrap; gap: 0.6rem;
  margin-bottom: 1.15rem; align-items: center; justify-content: space-between;
}
.stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.65rem;
  margin-bottom: 1rem;
}
.stat {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 14px; padding: 0.9rem; text-align: center;
}
.stat .n { font-size: 1.6rem; font-weight: 800; color: var(--gold); }
.stat .l { font-size: 0.75rem; color: var(--muted); margin-top: 0.2rem; }
.thumb {
  width: 36px; height: 36px; border-radius: 50%; object-fit: cover;
  border: 2px solid rgba(212,160,23,0.4); vertical-align: middle; margin-right: 0.4rem;
}
.error { color: #ff8a8a; font-size: 0.9rem; }
.ok-msg { color: #6bcf9a; font-size: 0.9rem; }
.footer-link {
  margin-top: 1.15rem; text-align: center; font-size: 0.78rem; color: var(--muted);
}
.footer-link a { color: var(--gold); text-decoration: none; font-weight: 600; }
.search-row { margin-bottom: 0.75rem; }
.grid-2 { display: grid; gap: 1rem; }
@media (min-width: 900px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
}

#secretAdmin:hover { opacity: 0.7 !important; background: rgba(212,160,23,0.5) !important; }
