/* CashBookPro V89 — Navegação móvel do painel (afiliado e administrador).
 * Escopo: somente .shell > aside. Não modifica o menu público de login.
 * Não interfere com React, gateway DiviPay, requisições ou dados financeiros.
 */
.cbp-v89-hamburger,
.cbp-v89-backdrop { display: none; }

@media screen and (max-width: 760px) {
  .shell > aside {
    position: relative !important;
    z-index: 1101 !important;
  }
  .shell > aside > a:first-child {
    max-width: calc(100% - 112px) !important;
    min-width: 0;
  }
  .shell > aside .cbp-v89-hamburger {
    box-sizing: border-box;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 7px;
    position: absolute;
    top: 15px;
    right: 12px;
    min-width: 97px;
    height: 43px;
    padding: 8px 11px;
    border: 1px solid #e7c775;
    border-radius: 11px;
    background: #fff4d8;
    color: #6b4c07;
    font: 700 14px/1.2 system-ui, -apple-system, "Segoe UI", sans-serif;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }
  .shell > aside .cbp-v89-hamburger:hover,
  .shell > aside .cbp-v89-hamburger[aria-expanded="true"] {
    background: #f9e6b3;
  }
  .shell > aside .cbp-v89-hamburger:focus-visible {
    outline: 3px solid #9e7100;
    outline-offset: 3px;
  }
  .shell > aside .cbp-v89-hamburger svg {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
  }
  .shell > aside .cbp-v89-hamburger .cbp-v89-icon-close,
  .shell > aside .cbp-v89-hamburger[aria-expanded="true"] .cbp-v89-icon-open {
    display: none;
  }
  .shell > aside .cbp-v89-hamburger[aria-expanded="true"] .cbp-v89-icon-close {
    display: block;
  }
  /* Substitui a antiga régua horizontal (overflow-x:auto) por lista vertical. */
  .shell > aside > nav {
    display: none !important;
    position: absolute !important;
    top: calc(100% + 7px);
    left: 10px;
    right: 10px;
    z-index: 1103;
    width: auto !important;
    max-height: min(70dvh, 620px);
    margin: 0 !important;
    padding: 10px !important;
    background: #ffffff;
    border: 1px solid #e9dcc2;
    border-radius: 15px;
    box-shadow: 0 16px 42px rgba(22, 23, 20, 0.20);
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    align-items: stretch !important;
    gap: 4px !important;
    scrollbar-width: thin;
  }
  .shell > aside.cbp-v89-menu-open > nav {
    display: flex !important;
  }
  .shell > aside > nav a,
  .shell > aside > nav span {
    width: 100% !important;
    min-height: 43px;
    box-sizing: border-box;
    flex: 0 0 auto !important;
    display: flex !important;
    align-items: center;
    white-space: normal !important;
    overflow-wrap: anywhere;
    text-align: left;
    padding: 11px 13px !important;
    border-radius: 9px;
  }
  .shell > aside > nav a:focus-visible {
    outline: 2px solid #a77a1b;
    outline-offset: -2px;
  }
  .cbp-v89-backdrop:not([hidden]) {
    display: block !important;
    position: fixed;
    inset: 0;
    z-index: 1100;
    background: rgba(21, 22, 26, .42);
  }
  body.cbp-v89-scroll-lock { overflow: hidden !important; }
}

@media screen and (min-width: 761px) {
  .shell > aside .cbp-v89-hamburger,
  .cbp-v89-backdrop { display: none !important; }
}
