body.panel { background: var(--paper); }
.pad { padding: 24px; }
.login { min-height: 100vh; display: grid; place-items: center; padding: 20px; }
.login form { width: 100%; max-width: 380px; background: var(--card); padding: 26px 22px; border-radius: 22px; display: grid; gap: 16px; box-shadow: 0 10px 30px rgba(11,47,46,.12); }
.login h1 { font-size: 1.6rem; }

.top { position: sticky; top: 0; z-index: 5; background: var(--ink); color: #fff; }
.top-in { max-width: 960px; margin: 0 auto; padding: 10px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.top strong { font-size: 1.1rem; overflow-wrap: anywhere; }
.top .who { color: #a9cbc7; font-size: .85rem; }
.tabs { max-width: 960px; margin: 0 auto; display: flex; gap: 4px; padding: 0 12px 10px; overflow-x: auto; }
.tab { flex: 1 0 auto; min-height: 44px; padding: 0 14px; border: 0; border-radius: 10px; background: transparent; color: #cfe3e0; font-weight: 700; cursor: pointer; white-space: nowrap; }
.tab[aria-selected="true"] { background: #fff; color: var(--ink); }
.main { max-width: 960px; margin: 0 auto; padding: 18px 16px 60px; display: grid; gap: 16px; }
.panel-card { background: var(--card); border-radius: var(--radius); padding: 18px 16px; box-shadow: 0 1px 0 var(--line); min-width: 0; }
.panel-card h2 { font-size: 1.1rem; margin-bottom: 12px; }
.grid2 { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 760px) { .grid2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 760px) { .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.stat { background: var(--card); border-radius: var(--radius); padding: 14px; box-shadow: 0 1px 0 var(--line); }
.stat b { display: block; font-size: 2rem; line-height: 1.1; }
.stat span { color: var(--muted); font-size: .9rem; }
.stat.hot { background: var(--mango); }
.stat.hot span { color: #3b2a00; }
.form-row { display: grid; gap: 12px; }
@media (min-width: 560px) { .form-row.two { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.rows { list-style: none; margin: 0; padding: 0; }
.rows > li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); min-width: 0; }
.rows > li:first-child { border-top: 0; }
.rows .main-col { min-width: 0; flex: 1; }
.rows .main-col b { display: block; overflow-wrap: anywhere; }
.rows .actions { display: flex; gap: 8px; flex: none; flex-wrap: wrap; justify-content: flex-end; }
.rows button.row-btn { all: unset; cursor: pointer; display: block; min-width: 0; flex: 1; }
.rows button.row-btn:focus-visible { outline: 3px solid var(--mango); outline-offset: 2px; border-radius: 6px; }
.pill { display: inline-block; font-size: .8rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: #e5eeec; white-space: nowrap; }
.pill.gold { background: var(--mango); color: #3b2a00; }
.bar { height: 8px; border-radius: 99px; background: #dbe6e3; overflow: hidden; margin-top: 6px; }
.bar > i { display: block; height: 100%; width: var(--w, 0%); background: var(--stamp); }
.toolbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.toolbar .input { flex: 1; min-width: 160px; }

/* QR del local */
.qr-stage { display: grid; justify-items: center; gap: 14px; text-align: center; }
.qr-box { width: min(86vw, 420px); aspect-ratio: 1; background: #fff; padding: 10px; border-radius: 18px; border: 2px solid var(--line); }
.qr-box svg { width: 100%; height: 100%; display: block; }
.qr-code { font-size: 2.2rem; font-weight: 800; letter-spacing: .2em; padding-left: .2em; }
.qr-timer { width: min(86vw, 420px); }
.qr-stage .biz { font-size: 1.4rem; font-weight: 800; }
.qr-stage:fullscreen { background: #fff; align-content: center; padding: 20px; }
.qr-stage:fullscreen .qr-box { width: min(80vh, 90vw); }
.detail-qr { width: 200px; max-width: 100%; background: #fff; padding: 6px; border-radius: 12px; border: 2px solid var(--line); }
.detail-qr svg { width: 100%; display: block; }
.link-box { word-break: break-all; font-size: .85rem; background: #f1f6f5; padding: 10px; border-radius: 10px; }
.modal-back { position: fixed; inset: 0; z-index: 20; background: rgba(8,30,29,.55); display: grid; place-items: end center; }
@media (min-width: 640px) { .modal-back { place-items: center; } }
.modal { background: var(--paper); width: 100%; max-width: 520px; max-height: 92vh; overflow: auto; border-radius: 22px 22px 0 0; padding: 18px 16px 28px; display: grid; gap: 14px; }
@media (min-width: 640px) { .modal { border-radius: 22px; } }
.modal-head { display: flex; justify-content: space-between; align-items: start; gap: 12px; }
.modal-head h2 { font-size: 1.3rem; overflow-wrap: anywhere; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 30; max-width: 92vw; padding: 12px 16px; border-radius: 12px; background: var(--ink); color: #fff; font-weight: 600; }
.toast.err { background: var(--danger); }
.empty { color: var(--muted); padding: 6px 0; }

@media print {
  body.panel .top, body.panel .tabs, body.panel .no-print { display: none !important; }
  body.panel { background: #fff; }
  .main { padding: 0; } .panel-card { box-shadow: none; }
}
