﻿:root {
  --ink: #17233c;
  --muted: #77829a;
  --line: #e8ebf1;
  --surface: #ffffff;
  --canvas: #f6f7fa;
  --blue: #4355db;
  --blue-dark: #3041c7;
  --blue-soft: #eef0ff;
  --green: #16a673;
  --green-soft: #eaf9f3;
  --red: #e4495b;
  --red-soft: #fff0f2;
  --amber: #f3a427;
  --shadow: 0 12px 35px rgba(23, 35, 60, .07);
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--canvas); }
body { margin: 0; min-height: 100vh; color: var(--ink); background: var(--canvas); font-family: "DM Sans", sans-serif; }
button, input, select { font: inherit; }
button { color: inherit; }

.app-shell { min-height: 100vh; }
.app-shell.locked { display: none; }
.login-screen { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: radial-gradient(circle at top left, #eef0ff, transparent 40%), var(--canvas); }
.login-screen.hidden { display: none; }
.login-card { width: min(100%, 420px); padding: 36px; border: 1px solid var(--line); border-radius: 18px; background: #fff; box-shadow: var(--shadow); }
.login-brand { display: flex; align-items: center; gap: 11px; margin-bottom: 38px; font: 800 24px "Manrope"; }
.login-brand .business-brand-name { color: var(--ink); }
.login-card h1 { margin-bottom: 8px; }
.login-form { display: grid; gap: 15px; margin-top: 26px; }
.login-form label, .dialog-form > label { display: grid; gap: 7px; font-size: 14px; font-weight: 700; }
.login-form input { border: 1px solid var(--line); border-radius: 9px; padding: 13px; outline: 0; }
.login-form input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.login-error { margin: 0; color: var(--red); font-size: 14px; font-weight: 700; }
.demo-access { margin-top: 22px; padding: 13px; border-radius: 9px; background: var(--blue-soft); font-size: 13px; color: var(--muted); }
.demo-access strong, .demo-access span { display: block; }
.demo-access strong { color: var(--ink); margin-bottom: 3px; }
.app-header {
  position: sticky; top: 0; z-index: 40; display: grid; grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center; gap: 18px; padding: 16px 4.5vw; background: rgba(255,255,255,.96);
  border-bottom: 1px solid var(--line); box-shadow: 0 8px 26px rgba(23, 35, 60, .05); backdrop-filter: blur(12px);
}
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; color: var(--ink); font: 800 23px "Manrope"; letter-spacing: -.7px; }
.brand > span:last-child > span { color: var(--blue); }
.brand-mark { width: 31px; height: 31px; display: grid; grid-template-columns: 1fr 1fr; gap: 3px; }
.brand-mark span { border: 3px solid var(--blue); border-radius: 3px; }
.brand-mark span:nth-child(2), .brand-mark span:nth-child(3) { border-width: 3px 0 0 3px; }
.brand-mark.light span { border-color: #fff; }
.main-nav { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; min-width: 0; overflow: visible; padding: 2px 4px 5px; }
.nav-group-label { margin: 0 4px; color: #a0a8b9; font-size: 11px; font-weight: 800; letter-spacing: 1.4px; white-space: nowrap; }
.nav-item {
  border: 0; background: transparent; padding: 10px 13px; display: flex; gap: 9px; align-items: center;
  border-radius: 10px; color: #717b91; font-weight: 600; cursor: pointer; text-align: left; white-space: nowrap;
}
.nav-item:hover { background: #f7f8fb; color: var(--ink); }
.nav-item.active { color: var(--blue); background: var(--blue-soft); }
.nav-icon { width: 22px; text-align: center; font-size: 22px; }
.nav-dropdown { position: relative; }
.nav-dropdown-toggle { text-transform: uppercase; letter-spacing: .5px; }
.nav-caret { margin-left: 2px; color: #a0a8b9; font-size: 15px; transition: transform .16s ease; }
.nav-dropdown-menu {
  position: absolute; top: calc(100% + 8px); left: 0; z-index: 60; min-width: 190px; padding: 8px;
  display: grid; gap: 4px; border: 1px solid var(--line); border-radius: 12px; background: #fff;
  box-shadow: var(--shadow); opacity: 0; visibility: hidden; transform: translateY(6px); transition: .16s ease;
}
.nav-dropdown:hover .nav-dropdown-menu, .nav-dropdown:focus-within .nav-dropdown-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.nav-dropdown:hover .nav-caret, .nav-dropdown:focus-within .nav-caret { transform: rotate(180deg); }
.nav-dropdown:has(.nav-item.active) > .nav-dropdown-toggle { color: var(--blue); background: var(--blue-soft); }
.nav-dropdown-menu .nav-item { width: 100%; }
.scanner-link { color: #717b91; background: transparent; }
.scanner-link:hover { background: #f7f8fb; color: var(--ink); }
.scanner-link.active { color: var(--blue); background: var(--blue-soft); }
.header-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; min-width: 0; }
.profile { min-width: 178px; padding: 0; display: grid; grid-template-columns: 38px 1fr; align-items: center; gap: 10px; text-align: left; }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: #dfe3ff; display: grid; place-items: center; color: var(--blue); font-weight: 700; font-size: 14px; }
.profile strong, .profile span { display: block; font-size: 14px; }
.profile span { color: var(--muted); margin-top: 2px; }
.logout-btn { margin: 0; border: 0; background: var(--red-soft); color: var(--red); font-size: 13px; font-weight: 700; cursor: pointer; border-radius: 10px; }
.admin-only[hidden] { display: none !important; }

.main { padding: 32px 4.5vw 40px; min-height: calc(100vh - 180px); }
.app-footer {
  margin: 0 4.5vw 28px; padding: 24px; display: grid; grid-template-columns: 1.15fr 1fr 1fr;
  align-items: stretch; gap: 18px; color: #fff; background: linear-gradient(135deg, #17233c, #263760);
  border-radius: 18px; box-shadow: var(--shadow);
}
.footer-column {
  min-width: 0; padding: 16px; border: 1px solid rgba(255,255,255,.12); border-radius: 15px;
  background: rgba(255,255,255,.055);
}
.footer-brand-column { display: grid; align-content: space-between; gap: 18px; }
.footer-brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.footer-brand .brand-mark { width: 32px; height: 32px; flex: 0 0 auto; }
.footer-brand strong, .footer-brand span { display: block; }
.footer-brand strong { font: 800 18px "Manrope"; }
.footer-brand span { margin-top: 3px; color: #c5ccdc; font-size: 13px; }
.footer-contact { display: grid; gap: 7px; color: #dbe2f1; font-size: 13px; line-height: 1.35; }
.footer-contact span {
  display: grid; grid-template-columns: 22px 1fr; gap: 7px; align-items: start;
  padding-bottom: 7px; border-bottom: 1px solid rgba(255,255,255,.1);
}
.footer-contact span:last-child { border-bottom: 0; padding-bottom: 0; }
.footer-contact i { font-style: normal; color: #aeb7cb; text-align: center; }
.footer-column h3 { margin: 0 0 12px; font: 800 13px "Manrope"; letter-spacing: 1px; text-transform: uppercase; color: #dbe2f1; }
.footer-metrics { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.footer-metrics span {
  padding: 8px 11px; border: 1px solid rgba(255,255,255,.14); border-radius: 999px;
  background: rgba(255,255,255,.07); color: #dbe2f1; font-size: 13px; font-weight: 700;
}
.footer-metrics strong { color: #fff; margin-right: 3px; }
.footer-feature { display: grid; gap: 5px; margin-bottom: 12px; }
.footer-feature strong { font: 800 18px "Manrope"; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.footer-feature span { color: #c5ccdc; font-size: 13px; line-height: 1.4; }
.footer-mini-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.footer-mini-stats span {
  padding: 9px 8px; text-align: center; border-radius: 12px; color: #dbe2f1;
  background: rgba(255,255,255,.08); font-size: 12px; font-weight: 700;
}
.footer-mini-stats strong { display: block; color: #fff; font: 800 18px "Manrope"; }
.footer-list { display: grid; gap: 9px; color: #dbe2f1; font-size: 13px; font-weight: 700; }
.footer-list span { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 9px; border-bottom: 1px solid rgba(255,255,255,.1); }
.footer-list span:last-child { border-bottom: 0; padding-bottom: 0; }
.footer-list strong { color: #fff; font-size: 16px; }
.footer-list em { color: #c5ccdc; font-style: normal; text-align: right; }
.footer-events-row { align-items: flex-start; }
.footer-events-row em { display: grid; gap: 4px; }
.footer-events-row em span { display: block; padding: 0; border: 0; color: #dbe2f1; }
.footer-events-row small { display: block; margin-top: 2px; color: #aeb7cb; font-size: 11px; }
.footer-status {
  display: inline-flex; align-items: center; gap: 8px; justify-self: start; width: fit-content; padding: 8px 11px;
  border-radius: 999px; color: #dffbed; background: rgba(22,166,115,.16); font-size: 13px; font-weight: 800;
}
.online-dot { width: 8px; height: 8px; border-radius: 50%; background: #4ad49f; box-shadow: 0 0 0 5px rgba(74,212,159,.14); }
.view { display: none; max-width: 1260px; margin: auto; animation: fade .22s ease; }
.view.active { display: block; }
@keyframes fade { from { opacity: 0; transform: translateY(4px); } }
.mobile-header, .bottom-nav { display: none; }
.page-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 30px; }
.page-actions { display: flex; align-items: center; gap: 9px; }
.eyebrow { margin: 0 0 8px; color: var(--blue); font-size: 13px; font-weight: 800; letter-spacing: 1.5px; }
h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 8px; font: 800 32px "Manrope"; letter-spacing: -1px; }
h2 { font: 700 19px "Manrope"; letter-spacing: -.3px; }
.subtitle { color: var(--muted); margin: 0; font-size: 16px; }
.primary-btn, .secondary-btn {
  border: 0; border-radius: 9px; padding: 12px 18px; font-weight: 700; cursor: pointer; transition: .18s;
}
.primary-btn { color: #fff; background: var(--blue); box-shadow: 0 7px 18px rgba(67, 85, 219, .2); }
.primary-btn:hover { background: var(--blue-dark); transform: translateY(-1px); }
.secondary-btn { background: #f1f3f7; color: var(--ink); }
.wide { width: 100%; }
.icon-process-btn { position: relative; width: 42px; min-width: 42px; height: 42px; padding: 0 !important; display: inline-grid; place-items: center; overflow: visible; }
.icon-process-btn.wide { width: 100%; }
.icon-process-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
.icon-process-btn::after {
  content: attr(data-tooltip); position: absolute; z-index: 80; left: 50%; bottom: calc(100% + 8px);
  transform: translate(-50%, 4px); width: max-content; max-width: 220px; padding: 7px 9px;
  border-radius: 7px; color: #fff; background: var(--ink); box-shadow: var(--shadow);
  font-size: 12px; font-weight: 700; line-height: 1.25; white-space: normal;
  opacity: 0; visibility: hidden; pointer-events: none; transition: .15s;
}
.icon-process-btn::before {
  content: ""; position: absolute; z-index: 81; left: 50%; bottom: calc(100% + 3px);
  transform: translateX(-50%); border: 5px solid transparent; border-top-color: var(--ink);
  opacity: 0; visibility: hidden; transition: .15s;
}
.icon-process-btn:hover::after, .icon-process-btn:hover::before,
.icon-process-btn:focus-visible::after, .icon-process-btn:focus-visible::before { opacity: 1; visibility: visible; }
.icon-process-btn:disabled::after, .icon-process-btn:disabled::before { display: none; }

.event-switcher { background: var(--ink); color: #fff; border-radius: 14px; padding: 20px 25px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 20px; box-shadow: var(--shadow); }
.event-date { width: 54px; height: 60px; border-radius: 9px; overflow: hidden; text-align: center; background: #fff; color: var(--ink); display: flex; flex-direction: column; justify-content: center; }
.event-date strong { font: 800 24px "Manrope"; line-height: 1; }
.event-date span { font-size: 11px; font-weight: 800; color: var(--blue); margin-top: 3px; letter-spacing: 1px; }
.event-title > span { font-size: 11px; font-weight: 700; letter-spacing: 1.3px; color: #aeb7cb; }
.event-title select { display: block; color: var(--ink); background: #fff; border: 1px solid rgba(255,255,255,.28); border-radius: 7px; padding: 7px 30px 7px 10px; font: 700 18px "Manrope"; outline: none; max-width: 100%; }
.event-title select option { color: var(--ink); }
.event-title p { margin: 2px 0 0; color: #b9c1d2; font-size: 14px; }
.live-pill, .online-pill { font-size: 12px; font-weight: 800; letter-spacing: .6px; padding: 7px 10px; border-radius: 20px; background: rgba(255,255,255,.08); }
.live-pill i, .online-pill i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #4ad49f; margin-right: 5px; box-shadow: 0 0 0 4px rgba(74,212,159,.12); }

.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 20px; }
.stat-card, .panel { background: var(--surface); border: 1px solid var(--line); border-radius: 13px; box-shadow: 0 7px 22px rgba(23,35,60,.035); }
.stat-card { padding: 20px 22px; min-height: 150px; border-top: 3px solid transparent; }
.stat-card.guests-card { background: linear-gradient(135deg, #fff7ed, #ffffff 72%); border-color: #ffd7a8; border-top-color: #f59e0b; }
.stat-card.access-card { background: linear-gradient(135deg, #ecfdf5, #ffffff 72%); border-color: #b8efd7; border-top-color: var(--green); }
.stat-card.hour-card { background: linear-gradient(135deg, #eff6ff, #ffffff 72%); border-color: #c7ddff; border-top-color: #3b82f6; }
.stat-card.duplicate-card { background: linear-gradient(135deg, #fff1f2, #ffffff 72%); border-color: #ffc9d0; border-top-color: var(--red); }
.stat-card.accent { border-top-color: var(--green); }
.stat-top { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 14px; font-weight: 600; }
.metric-icon { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; font-style: normal; font-size: 18px; }
.metric-icon.people { background: #fff2e8; color: #e78a43; }
.metric-icon.check { background: var(--green-soft); color: var(--green); }
.metric-icon.clock { background: var(--blue-soft); color: var(--blue); }
.metric-icon.duplicate { background: var(--red-soft); color: var(--red); }
.duplicate-text { color: var(--red); font-weight: 700; }
.stat-card > strong { display: block; font: 800 33px "Manrope"; margin: 13px 0 7px; letter-spacing: -1px; }
.stat-foot { display: flex; justify-content: space-between; color: #99a1b1; font-size: 12px; }
.trend { color: var(--green); font-weight: 700; }
.progress { height: 5px; overflow: hidden; border-radius: 5px; background: #edf0f5; margin: 2px 0 10px; }
.progress i { height: 100%; display: block; width: 0; background: var(--blue); border-radius: inherit; transition: width .5s ease; }

.dashboard-grid { display: grid; grid-template-columns: 1.7fr .85fr; gap: 18px; margin-top: 20px; }
.panel { padding: 22px; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 18px; }
.panel-head h2 { margin-bottom: 4px; }
.panel-head p { color: var(--muted); font-size: 13px; margin: 0; }
.text-btn { border: 0; background: transparent; color: var(--blue); font-weight: 700; font-size: 13px; cursor: pointer; padding: 5px; }
.recent-list { display: grid; }
.recent-item { display: grid; grid-template-columns: 38px 1fr auto; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.recent-item:first-child { border-top: 0; }
.guest-avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 800; color: var(--blue); background: var(--blue-soft); }
.recent-item strong, .recent-item span { display: block; font-size: 14px; }
.recent-item span { color: var(--muted); font-size: 12px; margin-top: 3px; }
.recent-time { text-align: right; }
.status-chip { display: inline-flex !important; align-items: center; gap: 5px; padding: 5px 8px; border-radius: 12px; font-weight: 700; }
.status-chip.checked { color: var(--green); background: var(--green-soft); }
.status-chip.pending { color: #a97112; background: #fff6df; }
.status-chip.duplicate { color: var(--red); background: var(--red-soft); }
.group-chip { display: inline-flex; padding: 5px 9px; border-radius: 12px; color: var(--blue); background: var(--blue-soft); font-size: 12px; font-weight: 800; white-space: nowrap; }
.row-action:disabled { color: #9aa3b5; background: #f1f3f7; cursor: not-allowed; }
.donut-wrap { display: grid; place-items: center; padding: 3px 0 20px; }
.donut { --percent: 0; width: 154px; height: 154px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--blue) calc(var(--percent) * 1%), #edf0f5 0); position: relative; }
.donut::after { content: ""; position: absolute; width: 112px; height: 112px; border-radius: 50%; background: #fff; }
.donut div { z-index: 1; text-align: center; }
.donut strong, .donut span { display: block; }
.donut strong { font: 800 29px "Manrope"; }
.donut span { color: var(--muted); font-size: 12px; }
.capacity-numbers { border-top: 1px solid var(--line); padding-top: 16px; display: grid; gap: 10px; }
.capacity-numbers div { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.capacity-numbers strong { color: var(--ink); font-size: 14px; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--blue); }
.dot.pending { background: #dfe3ec; }
.duplicate-dot { background: var(--red); }

.toolbar { display: flex; gap: 12px; margin-bottom: 16px; }
.guest-event-picker { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 14px; margin-bottom: 16px; padding: 15px 18px; border-radius: 12px; background: var(--ink); color: #fff; }
.event-date.compact { width: 48px; height: 52px; }
.guest-event-picker label { display: grid; gap: 3px; min-width: 0; }
.guest-event-picker label > span { color: #aeb7cb; font-size: 11px; font-weight: 800; letter-spacing: 1.2px; }
.guest-event-picker select { width: 100%; border: 1px solid rgba(255,255,255,.3); border-radius: 7px; outline: 0; padding: 7px 28px 7px 10px; background: #fff; color: var(--ink); font: 700 17px "Manrope"; }
.guest-event-picker select option { color: var(--ink); }
.guest-event-picker small { color: #b9c1d2; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.role-explainer { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 18px; }
.role-explainer div { display: grid; gap: 4px; padding: 16px; border: 1px solid var(--line); border-radius: 11px; background: #fff; }
.role-explainer strong { font-size: 15px; color: var(--blue); }
.role-explainer span { font-size: 13px; color: var(--muted); }
.dialog-form select { border: 1px solid var(--line); border-radius: 9px; padding: 12px; background: #fff; outline: 0; }
.mobile-menu-dialog { width: min(92vw, 390px); }
.mobile-menu-nav { display: grid; gap: 6px; }
.mobile-menu-nav .nav-item { width: 100%; }
.summary-dialog { width: min(92vw, 620px); }
.location-events-dialog { width: min(96vw, 1100px); max-width: 1100px; }
.location-events-table-wrap { border: 1px solid var(--line); border-radius: 10px; }
.summary-event-meta { margin: -8px 0 20px; color: var(--muted); font-size: 14px; }
.summary-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.summary-stats div { padding: 16px; border: 1px solid var(--line); border-radius: 10px; background: #fafbfc; }
.summary-stats span, .summary-stats strong { display: block; }
.summary-stats span { color: var(--muted); font-size: 12px; }
.summary-stats strong { margin-top: 6px; font: 800 24px "Manrope"; }
.summary-stats .summary-duplicate { background: var(--red-soft); }
.summary-stats .summary-duplicate strong { color: var(--red); }
.summary-progress { margin-top: 18px; }
.danger-btn { border: 0; border-radius: 7px; padding: 7px 10px; color: var(--red); background: var(--red-soft); font-size: 13px; font-weight: 700; cursor: pointer; }
.danger-btn:disabled { color: #a5adbc; background: #f1f3f7; cursor: not-allowed; }
.account-actions { display: flex; justify-content: flex-end; align-items: center; gap: 6px; }
.account-actions .icon-process-btn { width: 34px; min-width: 34px; height: 34px; }
.account-actions .icon-process-btn svg { width: 17px; height: 17px; }
.field-help { margin: 5px 0 0; color: var(--muted); font-size: 12px; }
.catalog-picker { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 9px; align-items: stretch; }
.dialog-form .catalog-picker select {
  min-width: 0; height: 42px; color: var(--ink);
  font: 700 14px "DM Sans", sans-serif;
}
.dialog-form .catalog-picker select option { color: var(--ink); font: 700 14px "DM Sans", sans-serif; }
.catalog-picker .secondary-btn { white-space: nowrap; }
.optional-label { color: var(--muted); font-weight: 500; }
.form-section-title { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); color: var(--blue); font-size: 13px; font-weight: 800; letter-spacing: .7px; text-transform: uppercase; }
.business-form { max-width: 760px; }
.business-preview { display: flex; align-items: center; gap: 14px; padding-bottom: 20px; margin-bottom: 6px; border-bottom: 1px solid var(--line); }
.business-initials { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 13px; color: #fff; background: var(--blue); font: 800 19px "Manrope"; }
.business-preview strong, .business-preview span { display: block; }
.business-preview strong { font: 700 20px "Manrope"; }
.business-preview span { margin-top: 3px; color: var(--muted); font-size: 13px; }
.business-fields > label, .business-fields .form-row label { display: grid; gap: 7px; margin-top: 16px; font-size: 14px; font-weight: 700; }
.business-fields input { border: 1px solid var(--line); border-radius: 9px; padding: 12px; outline: 0; }
.business-fields input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.search-box { flex: 1; display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 0 14px; }
.search-box span { color: var(--muted); font-size: 23px; }
.search-box input { width: 100%; border: 0; outline: 0; padding: 12px 0; color: var(--ink); }
.toolbar select { min-width: 180px; border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 0 12px; color: var(--ink); }
.guest-table-wrap { padding: 0; overflow-x: auto; }
.guest-table { width: 100%; border-collapse: collapse; }
.guest-table th { text-align: left; padding: 13px 18px; color: var(--muted); background: #fafbfc; font-size: 12px; text-transform: uppercase; letter-spacing: .7px; }
.guest-table td { padding: 15px 18px; border-top: 1px solid var(--line); font-size: 14px; transition: background-color .16s ease; }
.guest-table tbody tr:hover td { background: var(--blue-soft); }
.guest-table tbody tr:hover td:first-child { box-shadow: inset 3px 0 0 var(--blue); }
.table-pagination { min-width: 720px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 18px; padding: 14px 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.table-pagination label { display: flex; align-items: center; gap: 7px; }
.table-pagination select { border: 1px solid var(--line); border-radius: 7px; padding: 6px 25px 6px 8px; background: #fff; color: var(--ink); }
.pagination-actions { display: flex; align-items: center; gap: 10px; }
.pagination-actions button { border: 1px solid var(--line); border-radius: 7px; padding: 7px 10px; background: #fff; color: var(--blue); font-size: 13px; font-weight: 700; cursor: pointer; }
.pagination-actions button:disabled { color: #a5adbc; background: #f4f5f7; cursor: not-allowed; }
.guest-cell { display: flex; align-items: center; gap: 10px; }
.guest-cell strong, .guest-cell span { display: block; }
.guest-cell span { color: var(--muted); font-size: 12px; margin-top: 2px; }
.folio { font-family: Consolas, monospace; color: #59647b; }
.row-action { border: 1px solid var(--line); background: #fff; color: var(--blue); border-radius: 7px; padding: 7px 10px; font-size: 13px; font-weight: 700; cursor: pointer; }
.row-action.icon-process-btn, .danger-btn.icon-process-btn { width: 34px; min-width: 34px; height: 34px; }
.empty-state { padding: 55px 20px; text-align: center; color: var(--muted); }

.scanner-view { max-width: 1120px; }
.scanner-head { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 18px; margin-bottom: 25px; }
.scanner-head h1 { margin: 0; }
.back-btn { width: 39px; height: 39px; border: 1px solid var(--line); border-radius: 10px; background: #fff; cursor: pointer; font-size: 21px; }
.online-pill { color: var(--green); background: var(--green-soft); }
.scanner-active-event { margin: -7px 0 22px; padding: 16px 18px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; color: #fff; background: var(--ink); border-radius: 13px; box-shadow: var(--shadow); }
.scanner-event-icon { width: 43px; height: 43px; display: grid; place-items: center; border-radius: 10px; color: #fff; background: var(--blue); font-size: 24px; }
.scanner-active-event span, .scanner-active-event small { display: block; }
.scanner-active-event span { margin-bottom: 3px; color: #aeb7cb; font-size: 11px; font-weight: 800; letter-spacing: 1.2px; }
.scanner-active-event select { width: min(100%, 620px); border: 1px solid rgba(255,255,255,.28); border-radius: 7px; padding: 7px 30px 7px 10px; color: var(--ink); background: #fff; font: 800 17px "Manrope"; outline: none; }
.scanner-active-event select:disabled { opacity: .86; cursor: not-allowed; }
.scanner-active-event small { margin-top: 3px; color: #c4cada; font-size: 13px; }
.scanner-event-status { padding: 7px 10px; border-radius: 18px; color: #72e0b7; background: rgba(22,166,115,.15); font-size: 11px; font-weight: 800; letter-spacing: .7px; white-space: nowrap; }
.scanner-event-status i { display: inline-block; width: 7px; height: 7px; margin-right: 5px; border-radius: 50%; background: #4ad49f; box-shadow: 0 0 0 4px rgba(74,212,159,.12); }
.scanner-active-event.inactive { background: #59647b; }
.scanner-active-event.inactive .scanner-event-icon { background: #77829a; }
.scanner-active-event.inactive .scanner-event-status { color: #fff; background: rgba(255,255,255,.12); }
.scanner-active-event.inactive .scanner-event-status i { background: #cbd1dc; box-shadow: none; }
.scanner-layout { display: grid; grid-template-columns: 1.2fr .8fr; gap: 24px; }
.camera-card { background: #fff; padding: 18px; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); }
.camera-stage { position: relative; min-height: 410px; background: #111a2d; border-radius: 12px; overflow: hidden; display: grid; place-items: center; color: #fff; }
.camera-stage video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: none; }
.camera-placeholder { text-align: center; width: 260px; color: #d4d9e5; }
.camera-placeholder strong { display: block; color: #fff; font: 700 20px "Manrope"; margin: 8px 0; }
.camera-placeholder p { color: #9ea8bc; font-size: 14px; line-height: 1.5; }
.camera-symbol { font-size: 42px; color: #6f7cff; }
.scan-frame { position: absolute; width: 235px; height: 235px; display: none; }
.scan-frame i { width: 42px; height: 42px; position: absolute; border-color: #fff; border-style: solid; }
.scan-frame i:nth-child(1) { inset: 0 auto auto 0; border-width: 4px 0 0 4px; border-radius: 8px 0 0; }
.scan-frame i:nth-child(2) { inset: 0 0 auto auto; border-width: 4px 4px 0 0; border-radius: 0 8px 0 0; }
.scan-frame i:nth-child(3) { inset: auto auto 0 0; border-width: 0 0 4px 4px; border-radius: 0 0 0 8px; }
.scan-frame i:nth-child(4) { inset: auto 0 0 auto; border-width: 0 4px 4px 0; border-radius: 0 0 8px; }
.scan-line { display: none; width: 210px; height: 2px; background: #7583ff; position: absolute; box-shadow: 0 0 10px #7583ff; animation: scanning 2s infinite ease-in-out; }
@keyframes scanning { 0%, 100% { transform: translateY(-88px); } 50% { transform: translateY(88px); } }
.camera-stage.active .scan-frame, .camera-stage.active .scan-line, .camera-stage.active video { display: block; }
.camera-stage.active .camera-placeholder { display: none; }
.camera-card > .primary-btn { margin-top: 14px; }
.scanner-help { color: var(--muted); text-align: center; font-size: 13px; margin: 15px 0 8px; }
.manual-form { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.manual-form input { border: 1px solid var(--line); border-radius: 9px; padding: 11px 12px; outline: 0; text-transform: uppercase; }
.manual-form input:focus { border-color: var(--blue); }
.manual-form button { border: 0; border-radius: 9px; background: var(--ink); color: #fff; padding: 0 18px; font-weight: 700; cursor: pointer; }
.scan-side { display: grid; gap: 18px; align-content: start; }
.scan-result { border-radius: 16px; padding: 40px 26px; text-align: center; background: #fff; border: 1px solid var(--line); }
.result-icon { margin: auto auto 14px; width: 62px; height: 62px; border-radius: 50%; display: grid; place-items: center; font-size: 29px; background: var(--blue-soft); color: var(--blue); }
.scan-result h2 { font-size: 22px; margin-bottom: 7px; }
.scan-result p { color: var(--muted); font-size: 14px; line-height: 1.5; margin: 0; }
.scan-result.success { background: var(--green-soft); border-color: #c9efdf; }
.scan-result.success .result-icon { color: #fff; background: var(--green); }
.scan-result.error { background: var(--red-soft); border-color: #ffd2d8; }
.scan-result.error .result-icon { color: #fff; background: var(--red); }
.scan-message-dialog { width: min(92vw, 460px); }
.scan-message-content { position: relative; padding: 18px; }
.scan-message-content .scan-result { padding: 42px 24px 34px; border: 0; }
.scan-message-close { position: absolute; z-index: 2; top: 28px; right: 28px; }
.scan-message-content > .primary-btn { margin-top: 12px; }
.import-summary-dialog { width: min(92vw, 520px); }
.import-summary-total { padding: 18px; margin-bottom: 14px; border-radius: 11px; color: #fff; background: var(--blue); }
.import-summary-total span, .import-summary-total strong, .import-summary-total small { display: block; }
.import-summary-total span { font-size: 12px; font-weight: 800; letter-spacing: .8px; text-transform: uppercase; }
.import-summary-total strong { margin: 4px 0; font: 800 32px "Manrope"; }
.import-summary-total small { color: #dfe3ff; font-size: 13px; }
.import-group-list { max-height: 320px; overflow-y: auto; margin-bottom: 18px; border: 1px solid var(--line); border-radius: 10px; }
.import-group-item { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 13px 15px; border-top: 1px solid var(--line); }
.import-group-item:first-child { border-top: 0; }
.import-group-item span { font-size: 14px; font-weight: 700; }
.import-group-item strong { min-width: 34px; padding: 5px 8px; border-radius: 12px; text-align: center; color: var(--blue); background: var(--blue-soft); font-size: 13px; }
.mini-history { padding-bottom: 12px; }
.history-item { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); padding: 11px 0; font-size: 13px; }
.history-item:first-child { border-top: 0; }
.history-item span { color: var(--muted); }

dialog { border: 0; border-radius: 16px; padding: 0; box-shadow: 0 24px 70px rgba(23,35,60,.25); width: min(92vw, 500px); color: var(--ink); }
dialog::backdrop { background: rgba(17,26,45,.56); backdrop-filter: blur(3px); }
.dialog-form { padding: 26px; }
.dialog-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 22px; }
.dialog-head h2 { font-size: 24px; margin: 0; }
.close-btn { border: 0; background: #f1f3f7; width: 32px; height: 32px; border-radius: 50%; cursor: pointer; font-size: 21px; }
.dialog-form > label, .form-row label { display: grid; gap: 7px; font-size: 14px; font-weight: 700; margin-top: 14px; }
.dialog-form input { border: 1px solid var(--line); border-radius: 9px; padding: 12px; outline: 0; }
.dialog-form input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 25px; }
.pass-dialog-content { padding: 18px; position: relative; }
.pass-close { position: absolute; right: 26px; top: 26px; z-index: 2; }
.digital-pass { overflow: hidden; border-radius: 15px; text-align: center; background: #fff; border: 1px solid var(--line); padding-bottom: 22px; }
.pass-top { padding: 22px; color: #fff; background: var(--ink); display: flex; align-items: center; justify-content: center; gap: 10px; }
.pass-top .brand-mark { width: 24px; height: 24px; }
.pass-top strong { font: 800 18px "Manrope"; letter-spacing: 1px; }
.digital-pass > p { color: var(--blue); font-size: 11px; letter-spacing: 1.8px; font-weight: 800; margin: 24px 0 5px; }
.digital-pass h2 { font-size: 25px; margin-bottom: 18px; }
.pass-group { display: inline-block; margin: -10px 0 14px; padding: 5px 10px; border-radius: 12px; color: var(--blue); background: var(--blue-soft); font-size: 12px; font-weight: 800; }
.pass-qr { min-height: 180px; display: grid; place-items: center; margin-bottom: 12px; }
.pass-qr img { margin: auto; }
.digital-pass > strong { font-family: Consolas, monospace; letter-spacing: 1px; }
.pass-event { margin: 20px 24px 0; border-top: 1px dashed #cbd1dc; padding-top: 16px; }
.pass-event span, .pass-event small { display: block; }
.pass-event span { font-weight: 800; }
.pass-event small { color: var(--muted); margin-top: 4px; }
.pass-dialog-content > .primary-btn { margin-top: 12px; }
.toast { position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 9px; font-size: 14px; opacity: 0; pointer-events: none; transition: .22s; z-index: 100; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 1050px) {
  .app-header { grid-template-columns: 1fr auto; align-items: start; padding-inline: 3vw; }
  .main-nav { grid-column: 1 / -1; order: 3; width: 100%; }
  .header-actions { justify-self: end; }
  .main { padding-inline: 3vw; }
  .app-footer { margin-inline: 3vw; grid-template-columns: 1fr; align-items: start; }
  .footer-status { justify-self: start; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat-card:last-child { grid-column: auto; }
  .dashboard-grid { grid-template-columns: 1.4fr .8fr; }
}

@media (max-width: 760px) {
  body { padding-bottom: 0; }
  .app-header { grid-template-columns: 1fr auto; gap: 10px; padding: 12px 17px; }
  .app-header .brand { font-size: 20px; }
  .app-header .brand-mark { width: 27px; height: 27px; }
  .main-nav { grid-column: 1 / -1; margin: 0 -3px; padding-bottom: 4px; }
  .nav-group-label { display: none; }
  .nav-item { padding: 9px 10px; gap: 7px; }
  .nav-icon { width: 18px; font-size: 19px; }
  .nav-dropdown { position: static; }
  .nav-dropdown-menu { left: 17px; right: 17px; min-width: 0; }
  .profile { display: none; }
  .logout-btn { width: 40px; min-width: 40px; height: 40px; }
  .main { padding: 24px 17px 28px; }
  .app-footer { margin: 0 17px 20px; padding: 18px; }
  .footer-metrics { grid-template-columns: 1fr; width: 100%; }
  .footer-metrics span { width: 100%; }
  .footer-mini-stats { grid-template-columns: 1fr; }
  .footer-column { padding: 14px; }
  .footer-list span { display: grid; grid-template-columns: auto 1fr; }
  .page-head { align-items: flex-end; }
  .page-head h1 { font-size: 27px; }
  .page-head .primary-btn { padding: 10px 12px; font-size: 13px; }
  .page-actions { align-items: stretch; flex-direction: column-reverse; }
  .page-actions .secondary-btn { padding: 9px 11px; font-size: 12px; }
  .event-switcher { padding: 16px; grid-template-columns: auto 1fr; gap: 14px; }
  .event-title select { font-size: 17px; width: 100%; }
  .live-pill { display: none; }
  .stats-grid, .dashboard-grid, .scanner-layout { grid-template-columns: 1fr; }
  .stat-card:last-child { grid-column: auto; }
  .stats-grid { gap: 11px; }
  .stat-card { min-height: 132px; }
  .dashboard-grid { gap: 12px; }
  .capacity-panel { order: -1; }
  .toolbar { display: grid; }
  .role-explainer { grid-template-columns: 1fr; }
  .toolbar select { min-height: 43px; }
  #guest-table-panel .guest-table th:nth-child(3), #guest-table-panel .guest-table td:nth-child(3),
  #guest-table-panel .guest-table th:nth-child(5), #guest-table-panel .guest-table td:nth-child(5) { display: none; }
  .guest-table th, .guest-table td { padding-inline: 12px; }
  .scanner-head { grid-template-columns: auto 1fr; }
  .scanner-head .online-pill { display: none; }
  .scanner-head h1 { font-size: 26px; }
  .scanner-active-event { grid-template-columns: auto 1fr; }
  .scanner-event-status { grid-column: 2; justify-self: start; }
  .camera-stage { min-height: 360px; }
  .camera-card { padding: 10px; }
  .form-row { grid-template-columns: 1fr; gap: 0; }
  .catalog-picker { grid-template-columns: 1fr; }
  .summary-stats { grid-template-columns: 1fr 1fr; }
}

