/* Account + admin pages (and the new bits of the reservation form).
   Builds on the tokens and components in style.css — load that first.        */

:root {
  --ok: #35d07f;
  --warn: #ffc93c;
  --danger: #ff6b8b;
  --info: #7aa7ff;
  --soft: rgba(255, 255, 255, 0.06);
}

/* ── Fields ──────────────────────────────────────────────────────────── */

.field select {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  color: var(--text);
  border-radius: 14px;
  padding: 14px 12px;
  font-size: 1rem;
  font-family: var(--font-body);
  appearance: none;
  -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-muted) 50%),
    linear-gradient(135deg, var(--text-muted) 50%, transparent 50%);
  background-position: calc(100% - 17px) 52%, calc(100% - 12px) 52%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 30px;
}

.field select:focus {
  outline: none;
  border-color: var(--orange);
}

.field input[readonly],
.field select:disabled {
  opacity: 0.65;
}

.phone-row {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 10px;
}

.field-error {
  margin: 0;
  font-size: 0.84rem;
  color: #ff9bb8;
}

.field-hint {
  margin: 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.pw-input {
  position: relative;
}

.pw-input input {
  padding-right: 50px;
}

.pw-eye {
  position: absolute;
  top: 50%;
  right: 6px;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  background: none;
  border: none;
  border-radius: 10px;
  color: var(--text-muted);
  cursor: pointer;
}

.pw-eye:hover,
.pw-eye[aria-pressed="true"] {
  color: var(--gold);
}

/* ── Password setup ──────────────────────────────────────────────────── */

.pw-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.pw-meter {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-top: -2px;
}

.pw-meter span {
  height: 6px;
  border-radius: 99px;
  background: var(--soft);
  transition: background 0.25s ease, box-shadow 0.25s ease;
}

.pw-meter[data-score="1"] span:nth-child(-n + 1) { background: var(--danger); }
.pw-meter[data-score="2"] span:nth-child(-n + 2) { background: var(--orange); }
.pw-meter[data-score="3"] span:nth-child(-n + 3) { background: var(--warn); }
.pw-meter[data-score="4"] span:nth-child(-n + 4) { background: #8bdc6b; }
.pw-meter[data-score="5"] span { background: var(--ok); box-shadow: 0 0 10px rgba(53, 208, 127, 0.55); }

.pw-label {
  margin: -6px 0 0;
  min-height: 1.2em;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
}

.pw-label[data-score="0"] { color: var(--danger); }
.pw-label[data-score="1"] { color: var(--orange); }
.pw-label[data-score="2"] { color: var(--warn); }
.pw-label[data-score="3"] { color: #8bdc6b; }
.pw-label[data-score="4"] { color: var(--ok); }

.pw-checks {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.pw-checks li {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 0.84rem;
  color: var(--text-muted);
  transition: color 0.2s ease;
}

.pw-checks .tick {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1.5px solid var(--text-muted);
  opacity: 0.6;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  transition: all 0.2s ease;
}

.pw-checks li.pass { color: var(--text); }
.pw-checks li.pass .tick { background: var(--ok); border-color: var(--ok); color: #05301b; opacity: 1; }
.pw-checks li.pass .tick::after { content: "✓"; }
.pw-checks li.fail { color: #ffb7c9; }
.pw-checks li.fail .tick { border-color: var(--danger); color: var(--danger); opacity: 1; }
.pw-checks li.fail .tick::after { content: "!"; }

.pw-tips {
  margin: -4px 0 0;
  min-height: 1.1em;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.pw-match {
  margin: -6px 0 0;
  min-height: 1.2em;
  font-size: 0.84rem;
  font-weight: 600;
}

.pw-match.ok { color: var(--ok); }
.pw-match.bad { color: #ff9bb8; }

/* ── Generic app bits ────────────────────────────────────────────────── */

.ap-header-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
}

.ap-iconbtn {
  min-width: 38px;
  height: 38px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 12px;
  cursor: pointer;
}

.ap-iconbtn:hover {
  color: var(--text);
  border-color: rgba(255, 122, 48, 0.5);
}

.ap-card {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  padding: 16px;
}

.ap-section-title {
  margin: 8px 0 -6px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.ap-link {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
  background: none;
  border: none;
  font: inherit;
  cursor: pointer;
  padding: 0;
}

.ap-muted {
  color: var(--text-muted);
  font-size: 0.88rem;
}

.ap-center {
  text-align: center;
}

.ap-notice {
  background: rgba(255, 201, 60, 0.1);
  border: 1px solid rgba(255, 201, 60, 0.28);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-size: 0.9rem;
}

.phone-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  background: var(--soft);
  border: 1px solid var(--surface-border);
  border-radius: 99px;
  padding: 7px 14px;
  font-weight: 600;
  font-size: 0.95rem;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 99px;
  color: var(--text-muted);
  background: var(--soft);
}

.chip.ok { color: var(--ok); background: rgba(53, 208, 127, 0.14); }
.chip.warn { color: var(--warn); background: rgba(255, 201, 60, 0.14); }
.chip.hot { color: #ff8fb0; background: rgba(255, 45, 120, 0.16); }
.chip.info { color: var(--info); background: rgba(122, 167, 255, 0.15); }
.chip.orange { color: var(--orange); background: rgba(255, 122, 48, 0.15); }
.chip.dim { opacity: 0.6; }

/* ── Account page ────────────────────────────────────────────────────── */

.points-card {
  position: relative;
  border-radius: var(--radius-md);
  padding: 20px;
  border: 1px solid transparent;
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    var(--gradient-brand) border-box;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.points-kicker {
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.points-top {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.points-num {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
}

.points-unit {
  font-weight: 700;
  color: var(--text-muted);
}

.points-bar {
  height: 10px;
  border-radius: 99px;
  background: var(--soft);
  overflow: hidden;
}

.points-bar > span {
  display: block;
  height: 100%;
  width: 0;
  border-radius: 99px;
  background: var(--gradient-brand);
  transition: width 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.points-note {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.points-note strong {
  color: var(--text);
}

.ap-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ap-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 16px;
  padding: 14px 16px;
}

.ap-row-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.ap-row-title {
  font-weight: 700;
}

.ap-row-sub {
  font-size: 0.84rem;
  color: var(--text-muted);
}

.ledger-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 2px;
  border-bottom: 1px solid var(--surface-border);
  font-size: 0.92rem;
}

.ledger-row:last-child {
  border-bottom: none;
}

.ledger-delta {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.ledger-delta.plus { color: var(--ok); }
.ledger-delta.minus { color: #ff9bb8; }

.ap-admin-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--gold);
  background: rgba(255, 201, 60, 0.08);
  border: 1px solid rgba(255, 201, 60, 0.25);
  border-radius: var(--radius-sm);
}

.ap-admin-link:hover {
  background: rgba(255, 201, 60, 0.14);
}

.invite-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 16px;
  border-radius: var(--radius-md);
  background: rgba(255, 201, 60, 0.07);
  border: 1px solid rgba(255, 201, 60, 0.25);
}

.invite-icon {
  width: 26px;
  height: 26px;
  color: var(--gold);
}

.invite-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: left;
}

.invite-copy span {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.invite-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  width: 100%;
}

.invite-actions .btn {
  flex: 1 1 180px;
  padding: 13px 18px;
  font-size: 0.95rem;
  border-radius: var(--radius-sm);
}

.legal {
  max-width: 680px;
  line-height: 1.65;
  color: var(--text-muted);
}

.legal .rsv-h,
.legal .rsv-header {
  color: var(--text);
}

.legal p,
.legal ul {
  margin: 0 0 14px;
}

.legal ul {
  padding-left: 20px;
}

.legal li {
  margin-bottom: 6px;
}

.legal h2 {
  margin: 30px 0 10px;
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--text);
}

.legal h3 {
  margin: 18px 0 8px;
  font-size: 0.95rem;
  color: var(--text);
}

.legal strong {
  color: var(--text);
}

.legal code {
  font-size: 0.85em;
}

.legal-back {
  margin-top: 32px;
}

.terms-privacy {
  margin: 0 0 12px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.venue-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  text-align: left;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    var(--gradient-brand) border-box;
}

.venue-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.venue-pin {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  color: var(--gold);
  background: rgba(255, 201, 60, 0.12);
}

.venue-pin svg {
  width: 22px;
  height: 22px;
}

.venue-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.venue-text strong {
  font-size: 1.02rem;
  color: var(--text);
}

.venue-kicker {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.venue-when {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}

.venue-link {
  padding: 13px 18px;
  font-size: 0.95rem;
  border-radius: var(--radius-sm);
}

.log-tools {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.log-day {
  margin: 18px 0 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.log-list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-radius: var(--radius-md);
  border: 1px solid var(--surface-border);
  background: var(--surface);
}

.log-row {
  display: grid;
  grid-template-columns: 10px 1fr auto;
  align-items: baseline;
  gap: 10px;
  padding: 11px 14px;
  font-size: 0.9rem;
  line-height: 1.4;
  color: var(--text);
}

.log-row + .log-row {
  border-top: 1px solid var(--surface-border);
}

.log-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #35d07f;
  transform: translateY(-1px);
}

.is-admin .log-dot { background: var(--orange); }
.is-system .log-dot { background: #b9a8ff; }

.log-time {
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
  color: var(--text-muted);
  white-space: nowrap;
}

.log-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 0;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.log-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.adm-class-tools {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.move-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 40vh;
  overflow-y: auto;
}

.move-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 12px 14px;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  text-align: left;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.move-option small {
  font-weight: 500;
  white-space: nowrap;
  color: var(--text-muted);
}

.move-option[aria-pressed="true"] {
  border-color: var(--orange);
  background: rgba(255, 122, 48, 0.12);
}

.video-hero {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  margin-bottom: 20px;
  border-radius: var(--radius-md);
  color: var(--gold);
  background:
    radial-gradient(80% 100% at 50% 0%, rgba(255, 45, 120, 0.25), transparent 70%),
    var(--surface);
  border: 1px solid var(--surface-border);
}

.video-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 999px;
  color: #1a0b2e;
  background: var(--gradient-brand);
}

.video-done {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  background: rgba(53, 208, 127, 0.1);
  border: 1px solid rgba(53, 208, 127, 0.3);
}

.video-done strong { color: var(--ok); }
.video-done span { font-size: 0.9rem; color: var(--text-muted); }

.ap-security {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}

.ap-details {
  width: 100%;
}

.ap-details summary {
  list-style: none;
  cursor: pointer;
  display: inline-block;
  padding: 8px 0;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.ap-details summary::-webkit-details-marker { display: none; }

.ap-details > div {
  margin: 6px 0 4px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 16px;
}

.ap-logout {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 36px;
  padding: 8px 0;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.ap-logout:hover {
  color: var(--text);
}

.ap-info {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 0;
}

.ap-info svg {
  flex-shrink: 0;
  margin-top: 2px;
}

/* ── Reservation form additions ──────────────────────────────────────── */

.rsv-account {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 18px;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.rsv-account strong { color: var(--text); }

.redeem-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-radius: var(--radius-md);
  padding: 16px;
  border: 1px solid transparent;
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    var(--gradient-brand) border-box;
}

.redeem-card p { margin: 0; font-size: 0.92rem; color: var(--text-muted); }
.redeem-card strong { color: var(--text); }
.redeem-card .btn-large { margin-top: 2px; }

.or-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.or-divider::before,
.or-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--surface-border);
}

.points-perk {
  font-size: 0.84rem;
  color: var(--text-muted);
  text-align: center;
  margin: 0;
}

.points-perk strong { color: var(--gold); }

/* ── Admin ───────────────────────────────────────────────────────────── */

.ap-admin {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  padding: 0 0 calc(86px + env(safe-area-inset-bottom));
}

.ap-admin .container {
  max-width: 640px;
  padding: 0 16px;
}

.adm-top {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(21, 10, 36, 0.92);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--surface-border);
  padding: calc(10px + env(safe-area-inset-top)) 0 10px;
}

.adm-top .container {
  display: flex;
  align-items: center;
  gap: 10px;
}

.adm-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.15rem;
}

.adm-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-top: 14px;
}

.adm-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  background: rgba(28, 15, 48, 0.96);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--surface-border);
  padding-bottom: env(safe-area-inset-bottom);
}

.adm-nav-inner {
  max-width: 640px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
}

.adm-tab {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 10px 0 9px;
  font: inherit;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-muted);
  background: none;
  border: none;
  cursor: pointer;
}

.adm-tab svg { width: 24px; height: 24px; }
.adm-tab[aria-selected="true"] { color: var(--text); }
.adm-tab[aria-selected="true"] svg { color: var(--orange); }

.adm-badge {
  position: absolute;
  top: 5px;
  left: calc(50% + 8px);
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 99px;
  display: grid;
  place-items: center;
  font-size: 0.68rem;
  font-weight: 800;
  background: var(--gradient-brand);
  color: #1a0b2e;
}

.chip-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  margin: 0 -16px;
  padding: 2px 16px 6px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.chip-scroll::-webkit-scrollbar { display: none; }

.cls-chip {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  min-width: 96px;
  padding: 9px 13px;
  font: inherit;
  text-align: left;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 14px;
  cursor: pointer;
}

.cls-chip[aria-pressed="true"] {
  border-color: transparent;
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    var(--gradient-brand) border-box;
}

.cls-chip b { font-size: 0.92rem; }
.cls-chip small { font-size: 0.72rem; color: var(--text-muted); }
.cls-chip .chip { margin-top: 3px; padding: 2px 8px; font-size: 0.66rem; }

.adm-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.adm-stat {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 14px;
  padding: 10px 12px;
  font: inherit;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.adm-stat[aria-pressed="true"] {
  border-color: var(--orange);
  background: rgba(255, 122, 48, 0.12);
}

.seg.seg-wrap {
  grid-auto-flow: row;
  grid-template-columns: repeat(2, 1fr);
}

.adm-stat b {
  display: block;
  font-family: var(--font-display);
  font-size: 1.35rem;
  line-height: 1.1;
}

.adm-stat span {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 600;
}

.seg {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 4px;
  background: var(--soft);
  padding: 4px;
  border-radius: 14px;
}

.seg button {
  font: inherit;
  font-size: 0.86rem;
  font-weight: 700;
  padding: 9px 6px;
  color: var(--text-muted);
  background: none;
  border: none;
  border-radius: 10px;
  cursor: pointer;
}

.seg button[aria-pressed="true"] {
  color: var(--text);
  background: var(--surface);
  box-shadow: 0 2px 8px -2px rgba(0, 0, 0, 0.5);
}

.adm-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 18px;
  padding: 14px;
}

.adm-card.is-cancelled { opacity: 0.55; }
.adm-card.is-pending { border-color: rgba(255, 201, 60, 0.4); }

.adm-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.adm-name {
  font-weight: 800;
  font-size: 1.02rem;
  line-height: 1.25;
  word-break: break-word;
}

.adm-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  font-size: 0.84rem;
  color: var(--text-muted);
}

.adm-meta a {
  color: var(--text);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.adm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.adm-actions .span2 { grid-column: 1 / -1; }

.abtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 10px;
  white-space: nowrap;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text);
  background: var(--soft);
  border: 1px solid var(--surface-border);
  border-radius: 14px;
  cursor: pointer;
  text-decoration: none;
  transition: filter 0.15s ease, transform 0.1s ease;
}

.abtn:active { transform: scale(0.98); }
.abtn:disabled { opacity: 0.5; cursor: not-allowed; }
.abtn svg { width: 17px; height: 17px; flex-shrink: 0; }
.abtn.primary { background: var(--gradient-brand); color: #1a0b2e; border-color: transparent; }
.abtn.wa { background: #25d366; color: #04371f; border-color: transparent; }
.abtn.danger { color: #ff9bb8; border-color: rgba(255, 107, 139, 0.35); background: rgba(255, 107, 139, 0.08); }

.adm-empty {
  text-align: center;
  padding: 34px 10px;
  color: var(--text-muted);
}

.adm-empty b { display: block; color: var(--text); margin-bottom: 4px; }

.push-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  padding: 12px 14px;
  font-size: 0.88rem;
  color: var(--text-muted);
  background: rgba(255, 201, 60, 0.07);
  border: 1px solid rgba(255, 201, 60, 0.22);
  border-radius: var(--radius-sm);
}

.push-card > span:nth-child(2) {
  flex: 1 1 200px;
}

.adm-export {
  justify-self: stretch;
}

.adm-export-box {
  width: 100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.78rem;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-sm);
  padding: 10px;
  resize: vertical;
}

.ref-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.ref-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 10px 6px;
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 12px;
}

.ref-stat b {
  font-family: var(--font-display);
  font-size: 1.25rem;
}

.ref-stat span {
  font-size: 0.7rem;
  line-height: 1.2;
  color: var(--text-muted);
}

.ref-reward {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 12px 0;
  padding: 12px;
  border-radius: var(--radius-sm);
  background: rgba(255, 201, 60, 0.08);
  border: 1px solid rgba(255, 201, 60, 0.25);
}

.ref-reward p {
  margin: 0;
  font-size: 0.9rem;
}

.invitee-list {
  display: flex;
  flex-direction: column;
  max-height: 38vh;
  overflow-y: auto;
}

.invitee {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px 0;
  border-top: 1px solid var(--surface-border);
}

.adm-userhead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.adm-userhead .ap-muted {
  margin: 0;
}

.adm-search {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  color: var(--text);
  border-radius: 14px;
  padding: 13px 15px;
  font: inherit;
  font-size: 1rem;
}

.adm-search:focus { outline: none; border-color: var(--orange); }

/* Bottom sheet */

.sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(8, 3, 16, 0.7);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fade-in 0.18s ease;
}

.sheet {
  width: 100%;
  max-width: 520px;
  max-height: 88vh;
  overflow-y: auto;
  background: var(--bg-alt);
  border: 1px solid var(--surface-border);
  border-bottom: none;
  border-radius: 24px 24px 0 0;
  padding: 10px 20px calc(20px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 14px;
  animation: sheet-up 0.22s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.sheet::before {
  content: "";
  align-self: center;
  width: 38px;
  height: 4px;
  border-radius: 99px;
  background: var(--surface-border);
  margin-bottom: 4px;
}

.sheet h2 { font-size: 1.25rem; }
.sheet p { margin: 0; color: var(--text-muted); font-size: 0.95rem; }
.sheet p strong { color: var(--text); }
.sheet p.field-error { color: #ff9bb8; }
.sheet ul { margin: 0; padding-left: 18px; color: var(--text-muted); font-size: 0.94rem; display: grid; gap: 6px; }
.sheet ul strong { color: var(--text); }

.sheet-actions { display: grid; gap: 8px; }

.field-row { display: flex; gap: 10px; }
.field-row .field { flex: 1; }

@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes sheet-up { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  .sheet, .sheet-backdrop { animation: none; }
  .points-bar > span { transition: none; }
}

@media (min-width: 720px) {
  .sheet-backdrop { align-items: center; }
  .sheet { border-radius: 24px; border-bottom: 1px solid var(--surface-border); }
}

/* The admin tab bar is fixed at the bottom, so lift the toast above it. */
body.has-nav .rsv-toast {
  bottom: calc(88px + env(safe-area-inset-bottom));
}

/* ── Payment proof: student uploader and admin viewer ────────────────── */

.proof {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Visually hidden but not display:none, so iOS Safari opens the picker from the <label>. */
.file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
}

.file-input:focus-visible + .proof-drop {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

.proof-drop {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  width: 100%;
  padding: 22px 16px;
  font: inherit;
  text-align: center;
  color: var(--text);
  background: var(--surface);
  border: 1.5px dashed rgba(255, 201, 60, 0.5);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.proof-drop:hover {
  border-color: var(--gold);
  background: rgba(255, 201, 60, 0.06);
}

.proof-drop strong { font-size: 1.02rem; }
.proof-drop span { font-size: 0.85rem; color: var(--text-muted); }
.proof-icon { width: 30px; height: 30px; color: var(--gold); margin-bottom: 2px; }

.proof-drop.is-busy {
  cursor: progress;
  color: var(--text-muted);
  animation: proof-pulse 1.1s ease-in-out infinite;
}

@keyframes proof-pulse { 50% { opacity: 0.55; } }

.proof-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px 10px 10px;
  background: var(--surface);
  border: 1px solid rgba(53, 208, 127, 0.45);
  border-radius: var(--radius-md);
}

.proof-thumb {
  width: 52px;
  height: 68px;
  flex-shrink: 0;
  object-fit: cover;
  object-position: top;
  border-radius: 10px;
  background: #fff;
}

.proof-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}

.proof-meta strong { color: var(--ok); font-size: 0.95rem; }

.proof-meta span {
  font-size: 0.8rem;
  color: var(--text-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.proof-img {
  display: block;
  width: 100%;
  max-height: 58vh;
  object-fit: contain;
  background: #fff;
  border-radius: 14px;
}

.proof-slot { display: flex; flex-direction: column; gap: 8px; }
.proof-slot small { color: var(--text-muted); font-size: 0.8rem; }
.proof-slot.compact .proof-img { max-height: 32vh; }

@media (prefers-reduced-motion: reduce) {
  .proof-drop.is-busy { animation: none; }
}

/* Admin: sign-ups left unpaid, and the analytics tab */
.adm-alert {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin: 0 0 12px;
  padding: 12px 14px;
  border: 1px solid rgba(255, 176, 77, 0.45);
  border-radius: 14px;
  background: rgba(255, 176, 77, 0.1);
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.adm-alert b { display: block; font-size: 0.95rem; }
.adm-alert span { font-size: 0.85rem; color: var(--text-muted); }
.adm-alert i { font-style: normal; font-weight: 600; white-space: nowrap; color: var(--text); }
.adm-h { margin: 22px 0 10px; font-size: 1rem; }
.fun-row + .fun-row { margin-top: 12px; }
.fun-head { display: flex; align-items: baseline; gap: 8px; font-size: 0.9rem; }
.fun-head span { flex: 1; }
.fun-head small { color: var(--text-muted); font-size: 0.78rem; }
.fun-bar { height: 8px; margin-top: 6px; border-radius: 99px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.fun-bar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #ff4d8d, #ffb04d); }

/* Invite card and its "how it works" sheet; "Mis invitados" on the account page */
.invite-title { font-size: 1.12rem; line-height: 1.25; }
.invite-title em { font-style: normal; color: var(--gold); }
.invite-how { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.invite-how li { display: flex; gap: 12px; align-items: flex-start; color: var(--text-muted); font-size: 0.95rem; }
.invite-how strong { color: var(--text); }
.invite-how i {
  flex: none;
  min-width: 40px;
  height: 28px;
  padding: 0 8px;
  border-radius: 99px;
  display: grid;
  place-items: center;
  font-style: normal;
  font-weight: 800;
  font-size: 0.82rem;
  color: var(--text);
  background: rgba(255, 255, 255, 0.1);
}
.invite-how i.pts { color: #1a0f14; background: var(--gold); }
.friends-total { margin: 10px 0 4px; font-size: 0.92rem; color: var(--text-muted); }
.friends-total strong { color: var(--text); }
.friend-chips { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.sheet-actions .btn { width: 100%; padding: 13px 18px; font-size: 0.95rem; border-radius: var(--radius-sm); }
