/* Bocado V16 - correcoes de interface. Somente cliente, visual Moderno.
 * CSS adicional carregado APOS a folha compartilhada de botoes 3D.
 * Menus: navegacao discreta. Acoes reais: mantem o estilo 3D aprovado.
 */

/* LOGO: o limite de altura fixo anterior distorcia a proporcao 1440:1016.
 * Mantem a logo original e deixa o navegador calcular sua altura natural. */
body.storefront[data-bocado-header="app"] > header > .brand {
  display:flex!important;justify-content:flex-start!important;align-items:center!important;
  min-width:0!important;min-height:0!important;width:84px!important;
  max-width:none!important;
}
body.storefront[data-bocado-header="app"] > header > .brand > img {
  display:block!important;width:100%!important;height:auto!important;
  max-width:100%!important;max-height:none!important;
  object-fit:contain!important;object-position:center!important;
  aspect-ratio:auto!important;flex:0 0 auto!important;
}
@media (min-width:761px) {
  body.storefront[data-bocado-header="app"] > header {
    grid-template-columns:118px minmax(0,1fr)!important;
    column-gap:12px!important;
  }
  body.storefront[data-bocado-header="app"] > header > .brand {
    width:110px!important;
  }
}

/* PERFIL: menu de navegacao nunca parece um botao 3D. */
body.storefront[data-bocado-header="app"] .bocado-app-profile-dialog .bocado-app-profile-actions {
  display:grid;gap:0;margin-top:14px;
}
body.storefront[data-bocado-header="app"] .bocado-app-profile-dialog .bocado-app-profile-actions > button {
  display:grid!important;grid-template-columns:25px minmax(0,1fr) 18px!important;
  align-items:center!important;justify-items:stretch!important;column-gap:11px!important;
  width:100%!important;min-height:49px!important;
  margin:0!important;padding:10px 6px!important;
  border:0!important;border-bottom:1px solid #ede7e7!important;
  border-radius:0!important;background:#fff!important;
  color:#30282a!important;box-shadow:none!important;filter:none!important;
  transform:none!important;transition:background-color .15s ease!important;
  font-size:14px!important;line-height:1.35!important;text-align:left!important;
  font-weight:600!important;
}
body.storefront[data-bocado-header="app"] .bocado-app-profile-dialog .bocado-app-profile-actions > button:hover {
  background:#fff8f8!important;
}
body.storefront[data-bocado-header="app"] .bocado-app-profile-dialog .bocado-app-profile-actions > button:active {
  background:#fdefef!important;transform:none!important;box-shadow:none!important;
}
body.storefront[data-bocado-header="app"] .bocado-app-profile-dialog .bocado-app-profile-actions > button.bocado-app-logout {
  color:#a00b24!important;border-top:0!important;margin-top:6px!important;
}
body.storefront[data-bocado-header="app"] .bocado-app-profile-leading,
body.storefront[data-bocado-header="app"] .bocado-app-profile-trailing {
  display:flex;align-items:center;justify-content:center;min-width:0;
  color:#a82235;line-height:0;
}
body.storefront[data-bocado-header="app"] .bocado-app-profile-leading svg {
  display:block!important;width:20px!important;height:20px!important;
}
body.storefront[data-bocado-header="app"] .bocado-app-profile-trailing svg {
  display:block!important;width:16px!important;height:16px!important;
}
body.storefront[data-bocado-header="app"] .bocado-app-profile-label {min-width:0;overflow-wrap:anywhere}
body.storefront[data-bocado-header="app"] .bocado-app-profile-dialog [data-app-profile-info]:empty {display:none}

/* X: SVG ocupa o centro geométrico do círculo, sem dependência da linha da fonte. */
body.storefront[data-bocado-header="app"] .bocado-app-profile-dialog .bocado-app-dialog-close,
body.storefront[data-bocado-header="app"] .bocado-app-address-dialog .bocado-app-dialog-close {
  box-sizing:border-box!important;position:static!important;float:none!important;
  display:flex!important;align-items:center!important;justify-content:center!important;
  flex:0 0 36px!important;width:36px!important;height:36px!important;
  min-width:36px!important;max-width:36px!important;min-height:36px!important;
  padding:0!important;margin:0!important;border:0!important;
  border-radius:50%!important;background:#f5f3f3!important;color:#51474a!important;
  font-size:0!important;line-height:0!important;text-align:center!important;
  box-shadow:none!important;filter:none!important;transform:none!important;
}
body.storefront[data-bocado-header="app"] .bocado-app-dialog-close svg {
  display:block!important;flex:none!important;width:18px!important;height:18px!important;
  margin:0!important;padding:0!important;vertical-align:middle!important;
}
body.storefront[data-bocado-header="app"] .bocado-app-dialog-close:hover {background:#eee9e9!important}
body.storefront[data-bocado-header="app"] .bocado-app-dialog-close:focus-visible {outline:2px solid #b31b30!important;outline-offset:3px!important}

/* CARRINHO: lixeira iconografica com alvo de toque, em vez de 'Remover'. */
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-remove {
  box-sizing:border-box!important;display:inline-flex!important;
  align-items:center!important;justify-content:center!important;
  width:42px!important;height:42px!important;min-width:42px!important;min-height:42px!important;
  padding:0!important;border:0!important;border-radius:10px!important;
  background:#fff6f7!important;color:#a50b24!important;
  text-decoration:none!important;box-shadow:none!important;transform:none!important;
  cursor:pointer;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-remove svg {
  display:block;width:19px;height:19px;stroke-width:1.8;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-remove:hover {
  background:#fce8eb!important;
}

/* CHECKOUT: melhorar legibilidade, principalmente no computador; sem ampliar o
 * modal em dispositivos pequenos nem mudar passos, campos ou comportamento. */
body.storefront[data-bocado-header="app"] #checkoutdialog {
  width:min(650px,calc(100vw - 20px))!important;
  font-size:15px!important;line-height:1.45!important;
  text-rendering:optimizeLegibility;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-modern-progress {
  margin:12px 0 16px!important;gap:4px!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-progress-step small {
  font-size:clamp(10px,2.55vw,12px)!important;
  line-height:1.2!important;letter-spacing:normal!important;
  overflow:visible!important;white-space:normal!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-progress-icon {
  width:36px;height:36px;min-width:36px;min-height:36px;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-progress-icon svg {
  width:20px;height:20px;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-stage h2 {
  font-size:clamp(20px,3.1vw,24px)!important;line-height:1.25!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-info > strong {
  font-size:16px!important;line-height:1.35!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-info > small {
  font-size:13px!important;line-height:1.35!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-price {
  font-size:16px!important;line-height:1.3!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-controls {
  grid-template-columns:auto minmax(0,1fr) 42px!important;gap:8px!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-quantity span {
  font-size:15px!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-review-total {
  font-size:14px!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .checkout-step :is(p,legend,label),
body.storefront[data-bocado-header="app"] #checkoutdialog .checkout-intro {
  font-size:14px;line-height:1.45;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .checkout-step h2,
body.storefront[data-bocado-header="app"] #checkoutdialog #orderform > h2 {
  font-size:clamp(21px,3.2vw,27px)!important;line-height:1.2!important;
}
body.storefront[data-bocado-header="app"] #checkoutdialog .checkout-actions button {
  font-size:14px!important;
}
@media (max-width:350px) {
  body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-progress-icon {
    width:30px;min-width:30px;height:30px;min-height:30px;
  }
  body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-progress-step small {
    font-size:9px!important;
  }
  body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-controls {
    gap:4px!important;
  }
  body.storefront[data-bocado-header="app"] #checkoutdialog .bocado-app-cart-remove {
    width:38px!important;min-width:38px!important;height:40px!important;min-height:40px!important;
  }
}
@media (prefers-reduced-motion:reduce) {
  body.storefront[data-bocado-header="app"] .bocado-app-profile-actions > button {transition:none!important}
}

/* V16 iOS: sem deslocamento absoluto ou sticky no topo do cardapio.
 * O logo permanece dentro do fluxo; o padding de seguranca so aumenta quando
 * o WebKit reporta uma area visual efetivamente coberta. */
@supports (-webkit-touch-callout: none) {
  body.storefront[data-bocado-header="app"] > header {
    position:relative!important;
    top:auto!important;
    transform:none!important;
    height:auto!important;
    min-height:0!important;
    box-sizing:border-box!important;
    overflow:visible!important;
    padding-top:calc(12px + max(env(safe-area-inset-top, 0px), var(--bocado-ios-toolbar-offset, 0px)))!important;
  }
  body.storefront[data-bocado-header="app"] > header > .brand,
  body.storefront[data-bocado-header="app"] > header > .brand > img {
    position:relative!important;top:auto!important;transform:none!important;
  }
  @media (max-width:350px) {
    body.storefront[data-bocado-header="app"] > header {
      padding-top:calc(10px + max(env(safe-area-inset-top, 0px), var(--bocado-ios-toolbar-offset, 0px)))!important;
    }
  }
}
