/*
 * Mobile layer for every nb page (attendee, organizer, staff, public).
 * Layout and usability only - the look (font, colours, icons, radii) is unchanged and
 * every value comes from tokens.css. Loaded last by layouts/nb.blade.php.
 *
 *  ≤1199px  tables become cards (fixes the 768px tablet overflow found in the audit, and
 *           1024px with the full sidebar - see docs/sidebar-audit.md)
 *  ≤768px   phone rules: 16px inputs, 44px tap targets, 14px body text, 16px side
 *           padding, bottom tab bar, safe areas, toasts above the tab bar
 * Audit + before/after screenshots: docs/mobile-audit.md, docs/mobile-screens/.
 */

/* ---------------------------------------------------------------- safe areas */
.nb .topbar { padding-top: env(safe-area-inset-top); }
.nb .topbar-in { padding-left: max(var(--pad), env(safe-area-inset-left)); padding-right: max(var(--pad), env(safe-area-inset-right)); }

/* ---------------------------------------------------------------- tables → cards */
@media (max-width: 1199px) {
  .nb .data-table .table-head { display: none; }
  .nb .list-row { display: flex; flex-direction: column; align-items: stretch; gap: 6px; }
  .nb .list-row .row-amount { text-align: left; }
  /* Simple "label · value" rows outside tables stay side by side. */
  .nb :not(.table-body) > .list-row[style*="1fr auto"] { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; }
  /* Labelled cells (nb-mobile.js copies the column header into data-label). */
  .nb .data-table .list-row > [data-label]:not(:first-child):not(.m-actions)::before {
    content: attr(data-label); display: block; font-family: var(--fm); font-size: 12px;
    letter-spacing: .06em; text-transform: uppercase; color: var(--mut); margin-bottom: 2px;
  }
  .nb .data-table .list-row > [data-label=""]::before { content: none !important; }
  .nb .data-table .list-row > .m-actions { display: flex !important; flex-wrap: wrap; gap: 8px; justify-self: stretch; align-self: stretch; width: auto; }
  .nb .data-table .list-row > .m-actions > .btn, .nb .data-table .list-row > .m-actions .btn { flex: 1 1 0; border: 1px solid var(--line); }
  .nb .data-table .list-row > .btn.m-actions { display: inline-flex; justify-content: center; }
  .nb .data-table .list-row.m-collapsed > .m-more { display: none !important; }
  .nb .m-details-toggle { align-self: flex-start; min-height: 44px; padding: 0; border: 0; background: none; color: var(--acc-d); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
}

@media (max-width: 768px) {
  .nb { --pad: 16px; }
  html { -webkit-text-size-adjust: 100%; }
  body { font-size: 16px; }

  /* Inputs at 16px stop iOS/Android zooming in on focus. */
  .nb input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]),
  .nb select, .nb textarea { font-size: 16px !important; }
  /* field height: --h-field (48px here) in nb-polish.css */

  /* --------------------------------------------------------------- tap targets ≥44 */
  .nb .btn, .nb .btn.b-sm { min-height: 44px; }
  .nb .btn.b-sm { padding-left: 14px; padding-right: 14px; }
  .nb .ib, .nb .avatar, .nb .sheet-close, .nb .qty-btn { min-width: 44px; min-height: 44px; }
  .nb .qty-input { min-height: 44px; }
  .nb .brand { min-height: 44px; }
  .nb .topbar .city { min-height: 44px; position: relative; }
  .nb .topbar .city select { min-height: 44px; }
  .nb .side-link { min-height: 44px; font-size: 15px; }
  .nb .tab { min-height: 44px; padding: 0 16px; font-size: 14px; }
  .nb .see-all, .nb .row-menu summary, .nb .page-link { min-height: 44px; display: inline-flex; align-items: center; }
  .nb .footer-cols a { padding: 11px 0; font-size: 14px; }
  .nb .chk { min-height: 44px; }
  /* Links inside sentences: a bigger hit area without changing the line. */
  .nb p a:not(.btn), .nb .hint a, .nb .auth-sub a { padding: 10px 2px; margin: -10px -2px; }

  /* --------------------------------------------------------------- readable text */
  /* Body text ≥14px. Small mono labels (eyebrows, badges, table labels) are labels,
     not body text: they keep their style but never drop below 12px. */
  .nb p, .nb .hint, .nb .field .hint, .nb .row-sub, .nb .auth-sub, .nb .btn, .nb .see-all,
  .nb .footer-cols h4, .nb .site p, .nb .site span, .nb .list-row, .nb .stat-card .stat-meta,
  .nb .org-tile-meta, .nb .poster .cap .d, .nb .field label { font-size: max(14px, 1em); }
  .nb .field label { font-size: 14px; }
  .nb .hint { font-size: 14px; }
  .nb .field .hint { font-size: 13px; } /* helper text under a field: 13px (polish pass) */
  .nb .eyebrow, .nb .status-badge, .nb .stat-card .stat-label, .nb .org-pill, .nb .lbl, .nb .tagx,
  .nb .mono, .nb .data-table .table-head, .nb .sidebar small { font-size: 12px; }

  /* --------------------------------------------------------------- tabs: one row, swipe */
  .nb .tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
    margin-left: calc(-1 * var(--pad)); margin-right: calc(-1 * var(--pad)); padding: 0 var(--pad) 2px;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 var(--pad), #000 calc(100% - 28px), transparent);
            mask-image: linear-gradient(90deg, transparent 0, #000 var(--pad), #000 calc(100% - 28px), transparent); }
  .nb .tabs::-webkit-scrollbar { display: none; }
  .nb .tab { flex: none; white-space: nowrap; }

  /* --------------------------------------------------------------- stat cards swipe */
  .nb .stats-row { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    margin-left: calc(-1 * var(--pad)); margin-right: calc(-1 * var(--pad)); padding: 0 var(--pad) 4px; }
  .nb .stats-row::-webkit-scrollbar { display: none; }
  .nb .stats-row > * { flex: 0 0 min(72%, 240px); scroll-snap-align: start; }

  /* Contact details are reference information, not dashboard metrics. Keep every
     method visible rather than making a visitor discover a horizontal carousel. */
  .nb .stats-row.contact-info-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
    overflow: visible;
    scroll-snap-type: none;
    margin: 0 0 18px;
    padding: 0;
  }
  .nb .stats-row.contact-info-row > * { flex: initial; }

  /* --------------------------------------------------------------- page chrome */
  .nb .page-grid { padding-top: 16px; }
  .nb .page-grid > .sidebar { display: none; } /* replaced by the bottom tab bar + More sheet */
  .nb .wrap { padding-left: max(var(--pad), env(safe-area-inset-left)); padding-right: max(var(--pad), env(safe-area-inset-right)); }

  /* Room for the floating tab bar (--tb-clear, below) so it never covers the last thing on the page. */
  body.has-tabbar .nb { padding-bottom: calc(var(--tb-clear) + 16px); }

  /* Toasts at the bottom, above the tab bar / sticky action bars. */
  .iziToast-wrapper-bottomCenter { bottom: calc(76px + env(safe-area-inset-bottom)) !important; padding: 0 12px !important; }
  body.has-tabbar .iziToast-wrapper-bottomCenter { bottom: calc(var(--tb-clear) + 10px) !important; }
  .iziToast { min-width: 0 !important; width: 100%; }
}

/* =================================================================== bottom tab bar
   Phones only. A floating white card like the app's tab bar (lib/design tokens): 16px in
   from the sides, 16px off the bottom (or safe-area + 8px), max 398px wide, the page
   scrolls behind it. The current tab's icon sits in an orange circle. Organisers get a big
   round Scan button rising out of the middle. It slides away on a scroll down and comes
   back on a scroll up / at the end of the page (nb-mobile.js, body.tb-hidden).

   Shared sizes - everything that has to clear the bar uses these:
     --tb-gap    space between the bar and the bottom of the screen
     --tb-top    screen bottom -> top edge of the card
     --tb-bump   how far the organiser Scan circle rises above the card (0 otherwise)
     --tb-clear  screen bottom -> top of the bar including the bump */
.nb .m-tabbar { display: none; }
@media (max-width: 768px) {
  :root { --tb-h: 72px; --tb-gap: max(16px, env(safe-area-inset-bottom) + 8px); --tb-top: calc(var(--tb-h) + var(--tb-gap)); --tb-bump: 0px; --tb-clear: calc(var(--tb-top) + var(--tb-bump)); }
  :root:has(.m-tabbar .m-tab--scan) { --tb-bump: 20px; }

  .nb .m-tabbar { position: fixed; left: calc(16px + env(safe-area-inset-left)); right: calc(16px + env(safe-area-inset-right)); bottom: var(--tb-gap);
    z-index: calc(var(--z-bar) + 1); max-width: 398px; margin: 0 auto; min-height: var(--tb-h); box-sizing: border-box;
    display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); align-items: stretch; padding: 6px 8px;
    background: #FFFFFF; border: 1.5px solid #E8DED2; border-radius: 24px;
    box-shadow: 0 1px 0 rgba(20, 20, 20, .06), 0 14px 28px -12px rgba(20, 20, 20, .30);
    transition: transform .28s cubic-bezier(.2, .8, .2, 1), opacity .2s ease; }
  body.tb-hidden .nb .m-tabbar { transform: translateY(calc(100% + var(--tb-gap) + var(--tb-bump) + 16px)); opacity: 0; }

  .nb .m-tab { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-width: 0; min-height: 56px; padding: 0 2px;
    border: 0; border-radius: 16px; background: none; color: #6B645C; font: inherit; text-decoration: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
  .nb .m-tab__ico { display: flex; align-items: center; justify-content: center; flex: none; width: 36px; height: 36px; border-radius: 50%;
    transition: background-color .22s ease, color .22s ease, transform .22s cubic-bezier(.2, .8, .2, 1); }
  .nb .m-tab__ico svg { width: 23px; height: 23px; display: block; }
  .nb .m-tab__label { font-size: 12px; font-weight: 600; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
  .nb .m-tab[aria-current=page] { color: #141414; }
  .nb .m-tab[aria-current=page] .m-tab__ico { background: #FE5C36; color: #141414; transform: scale(1.08); }
  .nb .m-tab[aria-current=page] .m-tab__label { font-weight: 700; }
  .nb .m-tab:focus-visible { outline: 2px solid #141414; outline-offset: -2px; }

  /* Organiser Scan: a 64px orange circle with a white ring, bottom-aligned in the 36px icon
     slot so it rises out of the card; the label lines up with the others. */
  .nb .m-tab--scan, .nb .m-tab--scan[aria-current=page] { color: #141414; }
  .nb .m-tab--scan .m-tab__ico, .nb .m-tab--scan[aria-current=page] .m-tab__ico { width: 64px; height: 64px; margin-top: -28px; box-sizing: border-box;
    background: #FE5C36; color: #141414; border: 4px solid #FFFFFF; transform: none;
    box-shadow: 0 1px 0 rgba(20, 20, 20, .06), 0 14px 28px -12px rgba(20, 20, 20, .30); }
  .nb .m-tab--scan .m-tab__ico svg { width: 26px; height: 26px; }
  .nb .m-tab--scan .m-tab__label { font-weight: 700; }
  .nb .m-tab--scan:focus-visible { outline: 0; }
  .nb .m-tab--scan:focus-visible .m-tab__ico { outline: 2px solid #141414; outline-offset: 2px; }
  .nb .m-tab--scan:active .m-tab__ico { transform: scale(.96); }

  @media (prefers-reduced-motion: reduce) {
    .nb .m-tabbar, .nb .m-tab__ico { transition: none; }
    body.tb-hidden .nb .m-tabbar { transform: none; opacity: 1; } /* no slide: it just stays */
  }
}

/* =================================================================== floating "Create event" */
.nb .m-fab { display: none; }
@media (max-width: 768px) {
  /* above the floating bar (and the Scan circle); follows the bar down when it hides */
  .nb .m-fab { position: fixed; right: max(16px, env(safe-area-inset-right)); bottom: calc(var(--tb-clear) + 12px); z-index: calc(var(--z-bar) + 1);
    display: inline-flex; align-items: center; gap: 8px; min-height: 52px; padding: 0 20px; border-radius: var(--r-pill);
    background: var(--acc); color: var(--ink); font-weight: 600; font-size: 15px; text-decoration: none; border: 1px solid var(--acc);
    box-shadow: 0 1px 0 rgba(20, 20, 20, .06), 0 14px 28px -12px rgba(20, 20, 20, .30); transition: transform .28s cubic-bezier(.2, .8, .2, 1); }
  body.tb-hidden .nb .m-fab { transform: translateY(calc(var(--tb-clear) - var(--tb-gap))); }
  .nb .m-fab svg { width: 20px; height: 20px; }
  @media (prefers-reduced-motion: reduce) { .nb .m-fab { transition: none; } body.tb-hidden .nb .m-fab { transform: none; } }
}

/* =================================================================== bottom sheet (shared) */
.nb .m-sheet[hidden] { display: none !important; }
.nb .m-sheet-backdrop { position: fixed; inset: 0; z-index: var(--z-overlay); background: rgba(18, 18, 17, .45); opacity: 0; pointer-events: none; transition: opacity .2s; }
.nb .m-sheet { position: fixed; left: 0; right: 0; bottom: 0; z-index: var(--z-sheet); max-height: 90vh; display: flex; flex-direction: column;
  background: var(--surface); border-radius: var(--r-lg) var(--r-lg) 0 0; transform: translateY(105%); transition: transform .22s ease-out;
  padding-bottom: env(safe-area-inset-bottom); }
.nb .m-sheet.is-open { transform: none; }
.nb .m-sheet.is-open + .m-sheet-backdrop, .nb .m-sheet-backdrop.is-open { opacity: 1; pointer-events: auto; }
.nb .m-sheet__handle { width: 40px; height: 5px; border-radius: 3px; background: var(--line-2); margin: 10px auto 4px; flex: none; }
.nb .m-sheet__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 4px 16px 8px; flex: none; }
.nb .m-sheet__head h2 { font-size: 17px; margin: 0; }
.nb .m-sheet__body { overflow-y: auto; padding: 0 8px 12px; overscroll-behavior: contain; }
.nb .m-sheet__link { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 0 12px; border-radius: var(--r-sm);
  color: var(--ink); font-size: 16px; text-decoration: none; background: none; border: 0; width: 100%; font-family: inherit; cursor: pointer; text-align: left; }
.nb .m-sheet__link svg { width: 22px; height: 22px; color: var(--ink-2); flex: none; }
.nb .m-sheet__link:active, .nb .m-sheet__link:hover { background: var(--line-2); }
.nb .m-sheet__link small { margin-left: auto; color: var(--mut); font-size: 13px; }
.nb .m-sheet__sep { height: 1px; background: var(--line); margin: 6px 12px; }
@media (min-width: 769px) {
  .nb .m-sheet { left: 50%; right: auto; width: 440px; bottom: 50%; transform: translate(-50%, 60%) scale(.98); opacity: 0; pointer-events: none; border-radius: var(--r-lg); }
  .nb .m-sheet.is-open { transform: translate(-50%, 50%); opacity: 1; pointer-events: auto; }
  .nb .m-sheet__handle { display: none; }
}

/* =================================================================== small helpers */
@media (max-width: 768px) {
  .nb .m-hide { display: none !important; }
  .nb .m-sticky-cta { position: sticky; bottom: 0; z-index: var(--z-sticky); margin: 16px calc(-1 * var(--pad)) 0; padding: 12px var(--pad) calc(12px + env(safe-area-inset-bottom));
    background: var(--surface); border-top: 1px solid var(--line); }
  .nb .m-sticky-cta .btn { width: 100%; min-height: 48px; }
}
@media (min-width: 769px) { .nb .m-only { display: none !important; } }

@media (prefers-reduced-motion: reduce) {
  .nb .m-sheet, .nb .m-sheet-backdrop { transition: none; }
}

/* =================================================================== organizer dashboard (phone) */
@media (max-width: 768px) {
  .nb .stats-row { margin-left: 0; margin-right: 0; padding-left: 0; padding-right: 0; }
  .nb .m-next-event { display: block; padding: 16px; margin-bottom: 12px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); color: inherit; text-decoration: none; }
  .nb .m-next-event__title { display: block; font-size: 18px; letter-spacing: -.02em; margin: 6px 0 12px; }
  .nb .m-next-event__bar { height: 8px; border-radius: 4px; background: var(--line-2); overflow: hidden; }
  .nb .m-next-event__bar span { display: block; height: 100%; background: var(--acc); }
  .nb .m-next-event__nums { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }
  .nb .m-next-event__nums b { display: block; font-size: 18px; letter-spacing: -.02em; }
  .nb .m-next-event__nums small { font-size: 13px; color: var(--mut); font-weight: 400; }
  .nb .m-next-event__nums span { font-size: 13px; color: var(--mut); }
  .nb .m-quick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 16px; }
  .nb .m-quick__btn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 76px; padding: 8px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); color: var(--ink); font: inherit; font-size: 14px; font-weight: 600; text-align: center; text-decoration: none; cursor: pointer; }
  .nb .m-quick__btn svg { color: var(--acc-d); }
}

/* =================================================================== list cards (phone) */
@media (max-width: 768px) {
  .nb .m-event-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 4px; font-size: 14px; color: var(--ink-2); }
  .nb .m-progress { margin-top: 8px; }
  .nb .m-progress__bar { height: 6px; border-radius: 3px; background: var(--line-2); overflow: hidden; }
  .nb .m-progress__bar span { display: block; height: 100%; background: var(--acc); }
  .nb .m-progress small { display: block; margin-top: 4px; font-size: 13px; color: var(--mut); }
  .nb .list-row .row-info { align-items: flex-start; }
  .nb .list-row .row-title { white-space: normal; }
  .nb .list-row .row-sub { white-space: normal; }
  .nb .list-row .m-actions .btn { flex: 1; }
}

/* =================================================================== body text ≥14px (phone)
   Each selector below set its own size under 14px; raised here on phones only.
   Labels (eyebrows, badges, stat labels, tab-bar labels) stay at 12px. */
@media (max-width: 768px) {
  .nb .sec-head .sub, .nb .nav-links a, .nb .poster .cap .d, .nb .tile .over .d, .nb .band .step p,
  .nb .rrow .meta, .nb .host .kpi .d, .nb .footer-cols h4, .nb .footer-cols a, .nb .site p, .nb .f-12, .nb .f-13,
  .nb .profile-card .handle, .nb .side-submenu a, .nb .stat-card .stat-meta, .nb .upload-box b, .nb .upload-box .upload-copy span,
  .nb .pagination, .nb .pages a, .nb .pages button, .nb .row-menu-list a, .nb .row-menu-list button,
  .nb .row-info .row-sub, .nb .row-amount span, .nb .radio-pill, .nb .head-row p, .nb .auth-shell .auth-sub, .nb .auth-switch,
  .nb .auth-switch a, .nb .divider, .nb .divider span, .nb .chk, .nb .org-tile-meta, .nb .phone-in__prefix, .nb .upload-text b, .nb .upload-text span,
  .nb .ew-saved, .nb .ew-opt, .nb .ew .field label, .nb .ew .field legend, .nb .ew-venue-opt span, .nb .ew-ticket__payout,
  .nb .ew-lock, .nb .ew-card span, .nb .ew-counter, .nb .ew-photos__add, .nb .ew-preview__label, .nb .ew-tile span,
  .nb .u-between > strong, .nb .form-section > p { font-size: 14px !important; }
  .nb .footer-cols a { padding: 12px 0; }
}

/* =================================================================== page frame (phone)
   body kept the browser's default 8px margin, leaving a white frame and 8px of every
   phone screen unused. Removed on phones; desktop is left exactly as it was. */
@media (max-width: 768px) {
  body { margin: 0; }
  .nb .hero-grid > * { min-width: 0; }
}

@media (max-width: 768px) {
  /* label tier: never under 12px */
  .nb .stats .k, .nb .stats .n, .nb .day .dw, .nb .day .dn, .nb .band .mono, .nb .rrow .no, .nb .step .no, .nb .mono,
  .nb .tab .count{ font-size: 12px !important; }
   .nb .rrow .t { font-size: 14px !important; }
  /* footer bottom row (Privacy · Terms · Cookies) */
  .nb .site span > a, .nb .site .footer-bottom a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 6px; }
}

/* =================================================================== payment page (all widths) */
.nb .d-none { display: none !important; }
.nb .pay-shell { max-width: 620px; margin: 0 auto; padding: 24px 0 40px; }
.nb .pay-h2 { font-size: 17px; margin: 0 0 12px; }
.nb .pay-timer { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; padding: 12px 14px; border-radius: var(--r); background: var(--acc-w); border: 1px solid var(--acc-b); font-size: 15px; color: var(--ink); }
.nb .pay-timer svg { flex: none; color: var(--acc-d); }
.nb .pay-methods { display: grid; gap: 8px; }
.nb .pay-method { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; min-height: 56px; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--surface); cursor: pointer; font-size: 16px; font-weight: 600; }
.nb .pay-method:has(input:checked) { border-color: var(--ink); background: var(--acc-w); }
.nb .pay-method input { width: 20px; height: 20px; margin: 0; accent-color: var(--acc); }
.nb .pay-method__logo { height: 28px; width: auto; max-width: 72px; object-fit: contain; }
.nb .pay-amount { display: flex; align-items: center; gap: 4px; font-weight: 600; }
.nb .pay-amount input { width: 9ch; field-sizing: content; min-width: 4ch; text-align: right; border: 0; background: none; font: inherit; font-size: 16px; color: var(--ink); padding: 0; }
.nb .pay-amount input:not([readonly]) { border-bottom: 1px solid var(--line-2); }
/* booking total, then (only when the gateway charges) the processing fee, then You pay */
.nb .pay-fee { margin-top: 10px; color: var(--ink-2); font-size: 14px; }
.nb .pay-total { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 17px; }
.nb .pay-limit { margin: 10px 0 0; color: var(--err); font-weight: 600; }
.nb .pay-cta .btn { min-height: 52px; font-size: 16px; }
.nb .pay-cta .hint { margin-top: 8px; }
@media (max-width: 760px) {
  .nb :not(.table-body) > .list-row[style*="1fr auto"] { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; }
}

/* =================================================================== My Tickets: past bookings fold */
.nb .past-bookings > summary { display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 16px; cursor: pointer; font-weight: 600; color: var(--ink-2); border-top: 1px solid var(--line); list-style: none; }
.nb .past-bookings > summary::-webkit-details-marker { display: none; }
.nb .past-bookings > summary::after { content: ""; margin-left: auto; width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); }
.nb .past-bookings[open] > summary::after { transform: rotate(-135deg); }
.nb .past-bookings .count { font-size: 12px; color: var(--mut); }
.nb .past-bookings > .list-row { border-top: 1px solid var(--line-2); padding: 13px 16px; opacity: .85; }

/* =================================================================== ticket view: nb-ticket.css (.tkv) */
@media (max-width: 768px) {
  .nb .page-header .head-actions { flex-wrap: wrap; }
}

/* =================================================================== event page */
.nb .ev-meta { font-size: 13.5px; }
.nb .ev-map { color: inherit; text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
@media (max-width: 768px) {
  .nb .ev-meta { font-size: 15px; gap: 10px 20px !important; }
  .nb .ev-meta > span { min-height: 32px; }
  /* Sticky "Get tickets" bar: it reaches the bottom of the screen and the floating tab bar
     sits over its lower part (extra bottom padding), so nothing hangs in mid-air. When the
     tab bar slides away the panel drops by the same amount and only the CTA row stays. */
  body.has-tabbar .nb .ev-bottombar { bottom: 0; padding-bottom: calc(var(--tb-clear) + 12px); transition: transform .28s cubic-bezier(.2, .8, .2, 1); }
  body.has-tabbar.tb-hidden .nb .ev-bottombar { transform: translateY(var(--tb-clear)); }
  body.has-tabbar .nb .ev-bottombar-spacer { height: 88px; }
}

/* =================================================================== checkout */
@media (max-width: 768px) {
  .nb .checkout-cta { position: fixed; left: 0; right: 0; bottom: 0; z-index: var(--z-bar); padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: var(--surface); border-top: 1px solid var(--line); }
  .nb .checkout-cta .list-row { font-size: 16px; }
  .nb .checkout-cta .btn { min-height: 52px; margin-top: 8px !important; font-size: 16px; }
  body:has(.checkout-cta) .nb { padding-bottom: calc(130px + env(safe-area-inset-bottom)); }
  .nb .ticket-holder .ticket-remove { min-width: 44px; }
}

/* Table cards: labelled fields two per row; title, actions and the toggle span both. */
@media (max-width: 1199px) {
  .nb .data-table .table-body .list-row:not([style*="1fr auto"]) { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; align-items: start; }
  .nb .data-table .table-body .list-row > :first-child,
  .nb .data-table .table-body .list-row > .m-actions,
  .nb .data-table .table-body .list-row > .m-details-toggle,
  .nb .data-table .table-body .list-row > .row-info,
  .nb .data-table .table-body .list-row > .empty-state { grid-column: 1 / -1; }
  .nb .data-table .table-body .list-row > [hidden] { display: none !important; }
}
@media (max-width: 1199px) {
  .nb .data-table .table-body .list-row > .m-details-toggle { justify-self: start; }
  .nb .data-table .table-body .list-row > .m-actions { justify-self: stretch !important; }
}

/* =================================================================== filters (phone) */
@media (max-width: 768px) {
  .nb .toolbar { flex-wrap: nowrap; gap: 8px; }
  .nb .toolbar .search { min-width: 0 !important; flex: 1; }
  .nb .toolbar-filters-btn { flex: none; gap: 6px; }
  .nb .toolbar-filters-btn .count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; border-radius: 10px; background: var(--ink); color: var(--surface); font-size: 12px; }
  .nb .filter-chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: -4px 0 12px; }
  .nb .filter-chip { flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 12px; border-radius: var(--r-pill); background: var(--ink); color: var(--surface); font-size: 14px; text-decoration: none; }
}

/* =================================================================== event grids (phone)
   One full-width column on small phones, two columns from 400px. */
@media (max-width: 768px) {
  .nb .toolbar .view-toggle { display: none; }
  .nb .poster-grid, .nb .poster-grid.view-list { grid-template-columns: 1fr; gap: 12px; }
  .nb .poster-grid .poster { width: 100%; height: auto; aspect-ratio: 230 / 306; max-height: 70vh; }
}
@media (min-width: 400px) and (max-width: 768px) {
  .nb .poster-grid, .nb .poster-grid.view-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nb .poster-grid .poster .cap .t { font-size: 15px; }
}

/* =================================================================== last audit round (phone) */
@media (max-width: 768px) {
  .nb .toolbar .search input { min-height: 44px; }
  .nb .toolbar .search button { min-width: 44px; min-height: 44px; }
  .nb .list-row a.row-title, .nb .org-tile-name { display: inline-flex; align-items: center; min-height: 44px; }
  .nb .radio-pill { min-height: 44px; }
  .nb .list-row select, .nb .form-card select { min-height: 44px; }
  .nb .poster .pin.badge { font-size: 12px; }
  .nb .m-progress small, .nb .m-next-event__nums span, .nb .m-next-event__nums small,
  .nb .sp-card strong, .nb .tp-type__name small, .nb .u-row > span, .nb .ev-meta span,
  .nb .row-sub, .nb .sp-card { font-size: 14px !important; }
}

/* Same look as the old h4s - only the heading level changed (accessibility: heading order). */
.nb .footer-cols .footer-h { font-size: 12.5px; margin: 0 0 12px; font-weight: 600; letter-spacing: normal; }
.nb .band .step .step-h { font-size: 17px; margin-top: 14px; }
.nb main { display: block; }
@media (max-width: 768px) { .nb .footer-cols .footer-h { font-size: 14px; } }
.nb .footer-word::before { content: attr(data-word); }

/* The event page's ticket sheet (and its dimmer) sit above the bottom tab bar, and the
   price row leaves room for the sheet's close button. Found in the booking journey test. */
@media (max-width: 768px) {
  .nb .sheet-overlay { z-index: var(--z-overlay) !important; }
  .nb .sheet { z-index: var(--z-sheet) !important; padding-bottom: calc(16px + env(safe-area-inset-bottom)); }
  .nb .sheet .tp-price-row { padding-right: 56px; }
}

/* Cookie notice on phones: a compact strip above the bottom bars, not a large card
   covering the Pay / Book buttons. */
@media (max-width: 768px) {
  .nb .cookies-card { left: 8px !important; right: 8px !important; bottom: calc(72px + env(safe-area-inset-bottom)) !important; width: auto !important; max-width: none !important;
    display: flex; align-items: center; gap: 12px; padding: 12px 14px !important; text-align: left !important; z-index: var(--z-banner); }
  body.has-tabbar .nb .cookies-card { bottom: calc(var(--tb-clear) + 10px) !important; } /* above the floating tab bar */
  .nb .cookies-card.hide { display: none !important; }
  .nb .cookies-card__icon { display: none !important; }
  .nb .cookies-card__content { margin: 0 !important; font-size: 14px !important; line-height: 1.4; flex: 1; }
  .nb .cookies-card > .u-mt-16 { margin: 0 !important; flex: none; }
}

/* =================================================================== mono scale (phone)
   Plex Mono runs wide, so mono data (IDs, refs, times) stays at 13px instead of the 14px
   body-text floor above - it already reads as large as 14px sans. Labels stay at 12px.
   Selectors are doubled up to outrank the body-text !important rules. */
@media (max-width: 768px) {
  .nb .row-info .row-sub.mono-data, .nb .list-row .mono-data, .nb .mono-data.mono-data { font-size: 13px !important; }
  .nb .xpass__hint span { font-size: 13px; }
}

/* A .nb nested inside the page (<x-dynamic-form> wraps its fields in one so they get the .nb field styles) never takes the
   page-bottom room for the tab bar / checkout bar - that left an empty block inside the KYC / payment forms on phones. */
body.has-tabbar .nb .nb, body:has(.checkout-cta) .nb .nb { padding-bottom: 0; }
