/* Admin part: the owner's page, a full-screen panel over the app. Colours, corners and
   sizes come from the shell's variables; tap targets are 48 px (--tap). */

.adm-page {
  position: fixed; inset: 0; z-index: 15;   /* over the app, under toasts (20) and sheets (30) */
  display: flex; flex-direction: column;
  background: var(--bg); color: var(--text);
}
.adm-page[hidden] { display: none; }
.adm-bar {
  display: flex; align-items: center; gap: 8px;
  min-height: 56px; padding: env(safe-area-inset-top, 0px) 8px 0;
  background: var(--bar-bg, var(--accent)); color: var(--bar-ink, var(--on-accent));
}
.adm-bar svg.ico { width: 22px; height: 22px; }
.adm-title { font-size: var(--appbar-title-fs, 19px); font-weight: var(--appbar-title-weight, 650); }
.adm-scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.adm-content { max-width: 720px; margin: 0 auto; padding: 12px 16px calc(28px + env(safe-area-inset-bottom, 0px)); }
.adm-intro { margin: 4px 2px 12px; font-size: 15px; }

.adm-card { margin-bottom: 14px; }
.adm-card .h2 { margin: 0 0 4px; }
.adm-note { margin: 0 0 10px; font-size: 15px; }
.adm-body { display: flex; flex-direction: column; gap: 12px; }
.adm-h3 { margin: 6px 0 0; font-size: 16px; font-weight: 650; }
.adm-small { font-size: 13px; }
.adm-field { display: flex; flex-direction: column; gap: 6px; }
.adm-text { min-height: 140px; font-size: 16px; line-height: 1.4; }
.adm-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.adm-row .input { flex: 1; min-width: 140px; }
.adm-row .btn svg.ico, .adm-menu .btn svg.ico { width: 18px; height: 18px; }
.adm-form { display: flex; flex-direction: column; gap: 10px; }
.adm-armed { outline: 3px solid var(--danger); outline-offset: 1px; }

.adm-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.adm-tile { background: var(--surface-2); border-radius: var(--radius-input, 12px); padding: 10px 12px; }
.adm-num { font-size: 24px; font-weight: 700; line-height: 1.1; }
.adm-lbl { font-size: 13px; color: var(--muted); }

.adm-choices { display: flex; flex-direction: column; gap: 8px; }
.adm-choice {
  display: flex; align-items: flex-start; gap: 12px; width: 100%; min-height: var(--tap, 48px);
  padding: 12px; text-align: left; font: inherit; color: var(--text);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-input, 12px);
}
.adm-choice.on { border-color: var(--accent); background: var(--accent-soft); }
.adm-dot {
  flex: none; width: 22px; height: 22px; margin-top: 1px; border-radius: 50%;
  border: 2px solid var(--muted); box-sizing: border-box;
}
.adm-choice.on .adm-dot { border-color: var(--accent); box-shadow: inset 0 0 0 4px var(--surface); background: var(--accent); }
.adm-choice-text { display: flex; flex-direction: column; gap: 2px; }
.adm-choice-text span { font-size: 14px; color: var(--muted); }

.adm-build { margin: 0; font-size: 14px; color: var(--muted); }
.adm-build.changed { color: var(--text); padding: 8px 10px; border-radius: var(--radius-input, 12px); background: var(--accent-soft); }
.adm-link { min-height: 40px; }

.adm-people, .adm-entries, .adm-ways { display: flex; flex-direction: column; }
.adm-person, .adm-entry {
  display: flex; align-items: center; gap: 10px; min-height: var(--tap, 48px);
  padding: 8px 2px; border-top: 1px solid var(--line);
}
.adm-person:first-child, .adm-entry:first-child { border-top: 0; }
.adm-person[role="button"] { cursor: pointer; }
.adm-person .grow, .adm-entry .grow { flex: 1; min-width: 0; }
.adm-pname { font-weight: 600; overflow-wrap: anywhere; }
.adm-st.locked { background: color-mix(in srgb, var(--danger) 16%, var(--surface)); color: var(--text); }
.adm-st.ready { background: color-mix(in srgb, var(--ok) 16%, var(--surface)); color: var(--text); }

.adm-chip {
  min-height: 40px; padding: 0 16px; border-radius: 999px; font: inherit; font-size: 15px; font-weight: 600;
  background: var(--surface-2); color: var(--text); border: 1px solid var(--line);
}
.adm-chip.on { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }

.adm-group { display: flex; flex-direction: column; gap: 8px; padding-top: 6px; border-top: 1px solid var(--line); }
.adm-group:first-child { border-top: 0; padding-top: 0; }
.adm-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.adm-opt {
  display: inline-flex; align-items: center; gap: 2px; padding-left: 12px; min-height: 40px;
  border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); font-size: 15px;
}
.adm-x { width: 40px; height: 40px; border: 0; background: transparent; color: var(--muted); display: grid; place-items: center; border-radius: 50%; }
.adm-x svg.ico { width: 16px; height: 16px; }

.adm-invite {
  display: flex; flex-direction: column; gap: 8px; padding: 12px;
  border-radius: var(--radius-input, 12px); background: var(--accent-soft);
}
.adm-invite p { margin: 0; font-size: 15px; }
.adm-code {
  font-size: 26px; font-weight: 700; letter-spacing: .12em; text-align: center;
  padding: 8px; border-radius: var(--radius-input, 12px); background: var(--surface); user-select: all;
}
.adm-code.adm-long { font-size: 13px; letter-spacing: 0; font-weight: 600; overflow-wrap: anywhere; text-align: left; }

.adm-sheet .adm-menu { display: flex; flex-direction: column; gap: 10px; }
