html, body {
  height: 100%;
  margin: 0;
  background-color: var(--bg);
  background: var(--bg);
}

#app {
  display: flex;
  width: 100%;
  height: 100vh;
  max-height: 100vh;
  overflow: hidden;
}

#app:has(.login-screen),
#app.auth-mode {
  display: block;
}

/* Side Drawer Navigation */
nav#mainNav {
  background: var(--p);
  border-right: 1px solid var(--ln);
  padding: 16px 14px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  height: 100vh;
  box-sizing: border-box;
  overflow-y: auto;
  overflow-x: hidden;
  flex-shrink: 0;
  width: 240px;
  transition: width 0.22s cubic-bezier(0.16, 1, 0.3, 1), padding 0.22s ease, transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
}

#app.nav-collapsed nav#mainNav {
  width: 0;
  padding-left: 0;
  padding-right: 0;
  border-right: none;
  transform: translateX(-100%);
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}

.nav-drawer-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 16px;
  padding: 4px 4px 10px 4px;
}

.brand-block {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}

.brand-logo {
  width: 44px;
  height: 44px;
  object-fit: contain;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
}

.br {
  font-size: 24px;
  letter-spacing: -0.02em;
  font-weight: 500;
  line-height: 1.1;
  color: var(--a);
}

nav#mainNav a {
  padding: 7px 10px;
  border-radius: 8px;
  color: var(--mu);
  cursor: pointer;
  text-decoration: none;
  font-size: 13.5px;
  transition: background 0.15s, color 0.15s;
}

nav#mainNav a.on,
nav#mainNav a:hover {
  background: var(--p2);
  color: var(--tx);
}

.sp {
  flex: 1;
}

/* Three-Line Hamburger Button (Zero icons, zero emojis — pure CSS bars) */
.nav-hamburger-btn {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 3.5px;
  width: 32px;
  height: 32px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--ln);
  border-radius: 6px;
  cursor: pointer;
  flex-shrink: 0;
  color: var(--tx);
  transition: background 0.15s, border-color 0.15s, opacity 0.15s;
  box-sizing: border-box;
}

.nav-hamburger-btn:hover {
  background: var(--p2);
  border-color: var(--tx);
}

.nav-hamburger-btn:focus-visible {
  outline: 2px solid var(--a);
  outline-offset: 2px;
}

.hamburger-bar {
  display: block;
  width: 14px;
  height: 1.5px;
  background-color: currentColor;
  border-radius: 1px;
}

/* App Content Area & Topbar */
.app-content-wrap {
  display: flex;
  flex-direction: column;
  flex: 1 1 0%;
  width: 100%;
  height: 100vh;
  min-width: 0;
  overflow-x: hidden;
  overflow-y: hidden;
  background: var(--bg);
}

.app-topbar {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  height: 46px;
  padding: 0 24px;
  background: var(--p);
  border-bottom: 1px solid var(--ln);
  flex-shrink: 0;
  z-index: 3;
  box-sizing: border-box;
}

.app-topbar-title {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--tx);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav-drawer-backdrop {
  display: none;
}

main {
  padding: 24px 32px;
  max-width: none;
  width: 100%;
  min-width: 0;
  flex: 1 1 0%;
  height: calc(100vh - 46px);
  overflow-y: auto;
  overflow-x: hidden;
  box-sizing: border-box;
  background: var(--bg);
}

main::-webkit-scrollbar,
nav::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
main::-webkit-scrollbar-track,
nav::-webkit-scrollbar-track {
  background: transparent;
}
main::-webkit-scrollbar-thumb,
nav::-webkit-scrollbar-thumb {
  background: var(--ln);
  border-radius: 4px;
}
main::-webkit-scrollbar-thumb:hover,
nav::-webkit-scrollbar-thumb:hover {
  background: var(--mu);
}

/* Mobile & Tablet Styles (<= 820px) */
@media (max-width: 820px) {
  html, body {
    height: auto;
    overflow-x: hidden !important;
    overflow-y: auto;
    max-width: 100vw;
    width: 100%;
  }

  #app {
    display: flex;
    flex-direction: column;
    height: auto;
    min-height: 100vh;
    max-height: none;
    overflow-x: hidden !important;
    max-width: 100vw;
    width: 100%;
    min-width: 0;
  }

  .app-content-wrap {
    height: auto;
    min-height: 100vh;
    overflow-x: hidden !important;
    max-width: 100%;
    width: 100%;
    min-width: 0;
  }

  .nav-drawer-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
    backdrop-filter: blur(2px);
  }

  .nav-drawer-backdrop.active {
    opacity: 1;
    pointer-events: auto;
  }

  nav#mainNav {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 270px;
    max-width: 85vw;
    height: 100vh;
    height: 100dvh;
    z-index: 999;
    background: var(--p);
    border-right: 1px solid var(--ln);
    transform: translateX(-100%);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.6);
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    box-sizing: border-box;
    /* Respect iOS Safe Area (Dynamic Island, Notch, Status Bar & Home Indicator) */
    padding-top: max(48px, calc(env(safe-area-inset-top, 0px) + 16px));
    padding-bottom: max(24px, calc(env(safe-area-inset-bottom, 0px) + 16px));
    padding-left: max(14px, calc(env(safe-area-inset-left, 0px) + 14px));
    padding-right: max(14px, calc(env(safe-area-inset-right, 0px) + 14px));
  }

  nav#mainNav.open {
    transform: translateX(0);
  }

  #app.nav-collapsed nav#mainNav {
    transform: translateX(-100%);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  #app.nav-collapsed nav#mainNav.open {
    transform: translateX(0);
  }

  nav#mainNav a {
    padding: 11px 14px;
    min-height: 44px;
    font-size: 15px;
    display: flex;
    align-items: center;
    border-radius: 8px;
    touch-action: manipulation;
  }

  .nav-hamburger-btn {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    border-radius: 8px;
    touch-action: manipulation;
  }

  /* Prevent iOS Auto-Zoom on mobile */
  input, select, textarea, button {
    touch-action: manipulation;
  }

  input, select {
    font-size: 16px !important;
  }

  .app-topbar {
    padding-top: max(10px, env(safe-area-inset-top, 0px));
    height: calc(52px + max(10px, env(safe-area-inset-top, 0px)));
    padding-left: max(14px, calc(env(safe-area-inset-left, 0px) + 12px));
    padding-right: max(14px, calc(env(safe-area-inset-right, 0px) + 12px));
  }

  .g4, .g3, .g2, .sg, .dg {
    grid-template-columns: 1fr;
  }

  .dash-first-row {
    grid-template-columns: 1fr;
  }

  .dash-left-col {
    grid-template-columns: 1fr;
  }

  .dash-metrics-stack {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .g4 {
    grid-template-columns: 1fr 1fr;
  }

  @media (max-width: 480px) {
    .g4 {
      grid-template-columns: 1fr;
    }
  }

  main {
    height: auto;
    overflow-x: hidden !important;
    overflow-y: auto;
    max-width: 100%;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    padding: 16px;
    padding-left: max(14px, calc(env(safe-area-inset-left, 0px) + 14px));
    padding-right: max(14px, calc(env(safe-area-inset-right, 0px) + 14px));
    padding-bottom: max(96px, calc(env(safe-area-inset-bottom, 0px) + 80px));
  }
}

/* ====================================================================
 * Mobile Bottom Navigation, More Sheet, and Pull-to-Refresh
 * Strictly scoped to touch devices:
 * @media (hover: none) and (pointer: coarse) and (max-width: 1024px)
 * ==================================================================== */

.topbar-touch-brand,
.topbar-touch-avatar,
.topbar-touch-actions,
.topbar-touch-cal-btn,
.mobile-bottom-nav,
.mobile-more-backdrop,
.mobile-more-sheet {
  display: none;
}

@media (hover: none) and (pointer: coarse) and (max-width: 1024px) {
  html,
  body {
    overscroll-behavior-y: contain;
    height: auto;
    overflow-x: hidden !important;
    overflow-y: auto;
    max-width: 100vw;
    width: 100%;
  }

  #app {
    display: flex;
    flex-direction: column;
    height: auto;
    min-height: 100vh;
    max-height: none;
    overflow-x: hidden !important;
    max-width: 100vw;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }

  .app-content-wrap {
    height: auto;
    min-height: 100vh;
    overflow-x: hidden !important;
    max-width: 100%;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }

  /* Hide desktop sidebar links and hamburger on touch devices */
  nav#mainNav,
  .nav-drawer-backdrop,
  .app-topbar > .nav-hamburger-btn,
  .app-topbar > .app-topbar-title {
    display: none !important;
  }

  /* Top bar keeps only the brand on the left and the signed-in avatar block on the right */
  .app-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: var(--bg);
    background: var(--bg);
    padding-top: max(10px, env(safe-area-inset-top, 0px));
    height: calc(52px + max(10px, env(safe-area-inset-top, 0px)));
    padding-left: max(16px, calc(env(safe-area-inset-left, 0px) + 14px));
    padding-right: max(16px, calc(env(safe-area-inset-right, 0px) + 14px));
  }

  .topbar-touch-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 17px;
    font-weight: 600;
    color: var(--tx);
    letter-spacing: -0.01em;
  }

  .topbar-touch-actions {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
  }

  .topbar-touch-cal-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    min-width: 44px;
    min-height: 44px;
    padding: 0;
    background: transparent;
    border: none;
    color: var(--mu);
    border-radius: 8px;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    transition: color 150ms ease, background 150ms ease;
  }

  .topbar-touch-cal-btn:hover,
  .topbar-touch-cal-btn.on {
    color: var(--tx);
  }

  .topbar-touch-cal-btn.on {
    background: var(--p2);
    color: var(--a);
  }

  .topbar-touch-cal-btn svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    fill: none;
  }

  .topbar-cal-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 999px;
    background: var(--g);
    color: #16171b;
    font-size: 10px;
    font-weight: 700;
    line-height: 16px;
    text-align: center;
    box-sizing: border-box;
  }

  .topbar-touch-avatar {
    display: inline-flex;
    align-items: center;
  }

  .topbar-touch-avatar .nav-avatar-wrap {
    margin-top: 0;
    padding: 0;
    width: auto;
  }

  .topbar-touch-avatar .nav-account-btn {
    padding: 4px 8px;
    gap: 8px;
    width: auto;
  }

  .topbar-touch-avatar .status-popover {
    top: calc(52px + max(10px, env(safe-area-inset-top, 0px)));
    right: 14px;
    left: auto;
    bottom: auto;
  }

  /* Page content bottom padding: 88px + safe-area so last row is never hidden */
  main {
    overscroll-behavior-y: contain;
    height: auto;
    overflow-x: hidden !important;
    overflow-y: auto;
    max-width: 100%;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    padding: 16px;
    padding-left: max(14px, calc(env(safe-area-inset-left, 0px) + 14px));
    padding-right: max(14px, calc(env(safe-area-inset-right, 0px) + 14px));
    padding-bottom: calc(88px + env(safe-area-inset-bottom, 0px)) !important;
  }

  /* Bottom Navigation Bar: fixed bottom, full width, z-index 4, 56px + safe-area */
  .mobile-bottom-nav {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    z-index: 4;
    background: var(--p);
    border-top: 1px solid var(--ln);
    box-shadow: none;
    height: calc(56px + env(safe-area-inset-bottom, 0px));
    padding-bottom: env(safe-area-inset-bottom, 0px);
    padding-left: env(safe-area-inset-left, 0px);
    padding-right: env(safe-area-inset-right, 0px);
    box-sizing: border-box;
  }

  .mobile-bottom-nav-btn {
    flex: 1 1 20%;
    min-width: 56px;
    min-height: 56px;
    height: 56px;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 4px;
    margin: 0;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.2;
    color: var(--mu);
    text-transform: none;
    letter-spacing: 0;
    transition: color 150ms ease;
    transform: none !important;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  .mobile-bottom-nav-btn:hover {
    border: none !important;
    background: transparent !important;
  }

  .mobile-bottom-nav-btn.on,
  .mobile-bottom-nav-btn[aria-current="page"] {
    color: var(--tx);
  }

  .mobile-bottom-nav-btn.on::before,
  .mobile-bottom-nav-btn[aria-current="page"]::before {
    content: '';
    position: absolute;
    top: 0;
    left: 28%;
    right: 28%;
    height: 2px;
    background: var(--a);
    border-radius: 0 0 2px 2px;
  }

  .mobile-bottom-nav-btn:focus-visible {
    outline: 2px solid var(--a);
    outline-offset: -2px;
  }

  /* More Sheet & Dim Backdrop (z-index: 8) */
  .mobile-more-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 8;
    opacity: 0;
    pointer-events: none;
    transition: opacity 220ms ease;
  }

  .mobile-more-backdrop.open {
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-more-sheet {
    display: flex;
    flex-direction: column;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    background: var(--p);
    border-top: 1px solid var(--ln);
    border-radius: 18px 18px 0 0;
    z-index: 8;
    padding-bottom: env(safe-area-inset-bottom, 0px);
    transform: translateY(100%);
    pointer-events: none;
    transition: transform 220ms ease;
    box-sizing: border-box;
    box-shadow: none;
  }

  .mobile-more-sheet.open {
    transform: translateY(0);
    pointer-events: auto;
  }

  .mobile-more-header {
    font-size: 11px;
    font-weight: 500;
    color: var(--mu);
    padding: 14px 20px 10px 20px;
    border-bottom: 1px solid var(--ln);
    text-transform: none;
  }

  .mobile-more-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
    min-height: 52px;
    padding: 16px 20px;
    font-size: 15px;
    font-weight: 400;
    color: var(--tx);
    background: transparent !important;
    border: none !important;
    border-bottom: 1px solid var(--ln) !important;
    border-radius: 0 !important;
    text-align: left;
    cursor: pointer;
    transition: color 150ms ease;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  .mobile-more-row:last-child {
    border-bottom: none !important;
  }

  .mobile-more-row.on,
  .mobile-more-row[aria-current="page"] {
    color: var(--a);
    font-weight: 500;
  }

  .mobile-more-row:focus-visible {
    outline: 2px solid var(--a);
    outline-offset: -2px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-more-sheet,
  .mobile-more-backdrop,
  .mobile-bottom-nav-btn,
  .mobile-more-row {
    transition: none !important;
    animation: none !important;
  }
}



/* ====================================================================
 * Pull-to-refresh: B1 Solutions logo, tone on tone (aviveil-ptr-b1-logo spec)
 * Touch devices only. No text, spinner, bar, arrow, glow, shadow, gradient or accent.
 * Tones are mixes of --tx into --bg, so the logo works in both themes.
 * ==================================================================== */
@property --ptr-p {
  syntax: '<number>';
  inherits: true;
  initial-value: 0;
}

@property --ptr-travel {
  syntax: '<length>';
  inherits: true;
  initial-value: 0px;
}

:root {
  /* Dark theme (#16171b): empty #1e1f23 (1.09:1), filled #26262b (1.19:1, within 1.05-1.3) */
  --ptr-empty: 4%;
  --ptr-fill: 7.5%;
  --ptr-peak: 9.5%;
  --ptr-hold-y: 80px;
}

[data-theme="light"] {
  /* Light theme (#f6f4f8): empty #eeecf0 (1.07:1), filled #dcdade (1.27:1, within 1.05-1.3) */
  --ptr-empty: 4%;
  --ptr-fill: 13%;
  --ptr-peak: 16%;
}

.ptr-layer,
.ptr-offline-line {
  display: none;
}

/* Visually hidden aria-live message ("Refreshing" / "Updated") */
.ptr-live {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* One muted line for 2 seconds when the refresh happens offline */
.ptr-offline-line.show {
  display: block;
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 8px);
  left: 0;
  right: 0;
  text-align: center;
  font-size: 12px;
  color: var(--mu);
  z-index: 8;
  pointer-events: none;
}

@keyframes ptrBreath {
  0%,
  100% {
    background-color: color-mix(in srgb, var(--tx) var(--ptr-fill), var(--bg));
  }
  50% {
    background-color: color-mix(in srgb, var(--tx) var(--ptr-peak), var(--bg));
  }
}

@media (hover: none) and (pointer: coarse) {
  html,
  body {
    overscroll-behavior-y: contain;
    background-color: var(--bg);
    background: var(--bg);
  }

  /* Fixed layer with unified solid background covering the safe area + pull gap.
   * The logo is centred in the newly created refresh space below safe-area-inset-top. */
  .ptr-layer {
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding-top: env(safe-area-inset-top, 0px);
    height: calc(env(safe-area-inset-top, 0px) + var(--ptr-travel));
    box-sizing: border-box;
    background-color: var(--bg);
    align-items: center;
    justify-content: center;
    overflow: hidden;
    pointer-events: none;
    visibility: hidden;
    z-index: 10;
    contain: layout paint;
  }

  /* Solid safe-area shield so the logo clips cleanly at the bottom of the notch/status bar */
  .ptr-layer::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: env(safe-area-inset-top, 0px);
    background-color: var(--bg);
    z-index: 2;
    pointer-events: none;
  }

  .ptr-layer.on {
    visibility: visible;
  }

  .ptr-layer.anim {
    transition: --ptr-travel 200ms ease-out, --ptr-p 200ms ease-out;
  }

  .ptr-layer.return {
    transition: --ptr-travel 250ms ease-out;
  }

  .ptr-logo {
    position: relative;
    z-index: 1;
    flex: none;
    height: 44px;
    aspect-ratio: 1156.8 / 1323.4;
    opacity: 1;
    transform: scale(calc(0.92 + var(--ptr-p) * 0.08));
  }

  .ptr-logo::before,
  .ptr-logo::after {
    content: "";
    position: absolute;
    inset: 0;
    -webkit-mask: url(../assets/b1-mark.svg) center / contain no-repeat;
    mask: url(../assets/b1-mark.svg) center / contain no-repeat;
  }

  /* Empty outline of the shape */
  .ptr-logo::before {
    background: color-mix(in srgb, var(--tx) var(--ptr-empty), var(--bg));
  }

  /* Fill from bottom to top: filled height = p x logo height */
  .ptr-logo::after {
    background: linear-gradient(
      to top,
      color-mix(in srgb, var(--tx) var(--ptr-fill), var(--bg)) calc(var(--ptr-p) * 100%),
      transparent calc(var(--ptr-p) * 100%)
    );
  }

  .ptr-layer.refreshing .ptr-logo::after {
    background: color-mix(in srgb, var(--tx) var(--ptr-fill), var(--bg));
    animation: ptrBreath 1.4s ease-in-out infinite;
  }

  .ptr-layer.fading .ptr-logo {
    opacity: 0;
    transition: opacity 300ms ease-out;
  }

  /* Content stays held at the pulled position while refreshing (survives the in-place re-render) */
  html[data-ptr="hold"] .app-content-wrap {
    transform: translate3d(0, var(--ptr-hold-y, 80px), 0) !important;
    transition: none !important;
  }

  html[data-ptr="hold"],
  html[data-ptr="hold"] body {
    overscroll-behavior-y: none;
  }

  html[data-ptr="cancel"] .app-content-wrap {
    transform: translate3d(0, 0, 0);
    transition: transform 200ms ease-out;
  }

  html[data-ptr="return"] .app-content-wrap {
    transform: translate3d(0, 0, 0);
    transition: transform 250ms ease-out;
  }
}

/* Reduced motion: content does not move, no scaling, no breathing;
 * the logo simply fades in with the fill level. */
@media (hover: none) and (pointer: coarse) and (prefers-reduced-motion: reduce) {
  .ptr-layer,
  .ptr-layer.anim,
  .ptr-layer.return {
    height: calc(env(safe-area-inset-top, 0px) + 64px);
    transition: none;
  }

  .ptr-logo {
    transform: none;
    opacity: var(--ptr-p);
  }

  .ptr-layer.refreshing .ptr-logo::after {
    animation: none;
  }

  html[data-ptr] .app-content-wrap {
    transform: none !important;
    transition: none !important;
  }
}

/* Sidebar links: quiet line icon + label */
nav#mainNav a {
  display: flex;
  align-items: center;
  gap: 10px;
}
nav#mainNav a .ic {
  opacity: 0.75;
}
nav#mainNav a.on .ic,
nav#mainNav a:hover .ic {
  opacity: 1;
}

/* ====================================================================
 * Strict Responsive & Fluid Layouts (Desktop 2K & Tablet iPad)
 * Enforces Rule 2:
 * - Desktop 2K (1024px–2560px): Prevent infinite stretch with max-width container
 * - Tablet iPad (768px–1024px): 2-column grids and fluid flex layouts
 * - Mobile (Default): 1-column stack with 0 horizontal overflow
 * ==================================================================== */

@media (min-width: 1025px) {
  main > *:not(.board-fullscreen-view):not(.seat-editor-fullscreen):not(.ci) {
    max-width: 1440px;
    margin-left: auto;
    margin-right: auto;
    width: 100%;
    box-sizing: border-box;
  }
}

@media (min-width: 768px) and (max-width: 1024px) {
  .g3, .g4 {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
  .g2 {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  main {
    padding: 24px;
  }
}

