/* Ajustes nossos sobre o CSS original da loja (assets/pp-bagy.css). Manter mínimo: o visual é o da Bagy. */
.woocommerce-store-notice, p.demo_store { display: none !important; }

/* Avisos de erro/validação da vitrine em laranjinha suave da marca (não vermelho). Texto #A8431A = contraste AA. */
:root { --pp-aviso-texto: #A8431A; --pp-aviso-campo: #E8662E; --pp-aviso-fundo: #FCF0EA; --pp-aviso-borda: #F5D2C0; }
.woocommerce-error, .woocommerce-NoticeGroup .woocommerce-error { background: var(--pp-aviso-fundo) !important; color: var(--pp-aviso-texto) !important; border: 1px solid var(--pp-aviso-borda) !important; border-radius: 8px; list-style: none; padding: 12px 16px; }
.woocommerce-error::before { color: var(--pp-aviso-campo) !important; }
.woocommerce-invalid input, .woocommerce-invalid select, .woocommerce-invalid textarea, .form-control.is-invalid { border-color: var(--pp-aviso-campo) !important; }
.woocommerce-invalid label, .invalid-feedback, .checkout-inline-error-message { color: var(--pp-aviso-texto) !important; }
.footer-newsletter .footer-errors, .email-capture-modal .email-capture-errors, .theme-custom-modal .email-capture-errors, .email-capture-errors { background: var(--pp-aviso-fundo) !important; border: 1px solid var(--pp-aviso-borda); }
.footer-newsletter .footer-errors .text, .email-capture-modal .email-capture-errors .text, .theme-custom-modal .email-capture-errors .text, .email-capture-errors .text { color: var(--pp-aviso-texto) !important; }
.page-contact-form-errors .text { background: var(--pp-aviso-fundo) !important; color: var(--pp-aviso-texto) !important; border: 1px solid var(--pp-aviso-borda); border-radius: 8px; }
.error_response_message { background: var(--pp-aviso-fundo) !important; color: var(--pp-aviso-texto) !important; border: 1px solid var(--pp-aviso-borda); border-radius: 8px; }

/* Marcas: logo da marca (Produtos > Marcas no painel) na galeria "Compre por marcas" e no topo da página da marca */
.brands-link .pp-marca-logo { width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: contain; background: #fff; }
.brands-link .pp-marca-nome { display: flex; align-items: center; justify-content: center; aspect-ratio: 1 / 1; padding: 1rem; border: 1px solid #ece6ef; border-radius: 1.6rem; background: #fff; color: #440143; font-family: var(--h2-ff, 'Jost'), sans-serif; font-weight: 600; font-size: 1.8rem; line-height: 1.2; text-align: center; letter-spacing: .02em; overflow-wrap: anywhere; }
.pp-marca-topo { max-height: 64px; max-width: 160px; width: auto; height: auto; object-fit: contain; }

/* ===== Barra do administrador do WordPress (só existe para quem está logado com ela: sem body.admin-bar nada muda) =====
   A barra é fixa no alto (32px no computador, 46px até 782px; até 600px ela é rolável). O cabeçalho grudado e tudo o que é fixo
   no topo descem a altura dela, para a barra não cobrir o logo, o telefone nem o topo das gavetas. */
body.admin-bar { --pp-barra: var(--wp-admin--admin-bar--height, 32px); }
@media screen and (max-width: 600px) { body.admin-bar { --pp-barra: 0px; } }
body.admin-bar:not(.page-static) header.header,
body.admin-bar .header.is-fixed, body.admin-bar .header.is-fixed-mobile, body.admin-bar .header .header-box.is-fixed,
body.admin-bar .header-box.header-fixed-smart { top: var(--pp-barra); }
body.admin-bar .collection-sidebar, body.admin-bar .collection-sidebar.top { top: var(--pp-barra); height: calc(100vh - var(--pp-barra)); }
body.admin-bar #sideCart { top: var(--pp-barra); height: calc(100dvh - var(--pp-barra)); }
body.admin-bar .modal { top: var(--pp-barra); }
body.admin-bar a[href*="utm_campaign=faixa-live"] { top: var(--pp-barra) !important; } /* faixa "AO VIVO" (plugin de regras, estilo no próprio elemento) */

/* ===== Quantidade mínima e intervalo de compra: aviso pequeno e discreto (card, produto, grade, carrinho, gaveta) ===== */
.pp-qtd-aviso { font-size: 12px; line-height: 1.3; color: #6b5a72; opacity: .9; }
.product-card .pp-qtd-aviso { text-align: center; margin: -6px 0 8px; }
.pp-qtd-aviso-dig { font-size: 12px; line-height: 1.3; color: #8a4b00; background: #fff6e5; border-radius: 4px; padding: 3px 6px; margin-top: 4px; text-align: center; }

/* ===== Marcas (menu do topo, gaveta do celular e página /marcas): lista automática da taxonomia, com logo ou inicial colorida ===== */
.pp-marca-ic { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 28px; height: 28px; margin-right: 10px; border-radius: 50%; overflow: hidden; background: #fff; box-shadow: 0 0 0 1px rgba(68, 1, 67, .08); font: 600 13px/1 Jost, sans-serif; color: #440143; }
.pp-marca-ic img { width: 100%; height: 100%; object-fit: contain; display: block; }
html body .header .navigation .navigation-item .menu-dropdown .menu-dropdown-item a.menu-dropdown-link.pp-marca-link, html body .header .navigation.rv-last-items .navigation-item:nth-last-of-type(-n+2) .menu-dropdown .menu-dropdown-item a.menu-dropdown-link.pp-marca-link { flex-direction: row !important; justify-content: flex-start !important; padding-top: 6px !important; padding-bottom: 6px !important; }
#sideMenu .side-link .pp-marca-ic { width: 26px; height: 26px; margin-right: 12px; font-size: 12px; }
.pp-marcas-pagina { padding: 24px 0 56px; }
.pp-marcas-trilha { font-size: 13px; color: #6b5a72; margin: 8px 0 18px; }
.pp-marcas-trilha a { color: inherit; text-decoration: underline; }
.pp-marcas-topo h1 { margin: 0 0 8px; }
.pp-marcas-topo p { max-width: 560px; margin: 0 auto 26px; color: #5a4a62; }
.pp-marcas-grade { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 16px; }
.pp-marca-cartao { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 12px 16px; height: 100%; border-radius: 20px; background: #FEF2E2; border: 1px solid rgba(252, 79, 0, .12); text-decoration: none; color: #440143; transition: transform .15s ease, box-shadow .15s ease; }
.pp-marca-cartao:hover, .pp-marca-cartao:focus-visible { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(252, 79, 0, .16); outline: none; }
.pp-marca-cartao-img { display: flex; align-items: center; justify-content: center; width: 100%; aspect-ratio: 1 / 1; max-width: 150px; border-radius: 16px; overflow: hidden; }
.pp-marca-cartao-img img { width: 100%; height: 100%; object-fit: contain; display: block; }
.pp-marca-cartao-img b { font: 600 44px/1 Jost, sans-serif; color: #440143; }
.pp-marca-cartao-nome { font-weight: 600; font-size: 16px; text-align: center; line-height: 1.2; }
.pp-marca-cartao-n { font-size: 13px; color: #7a2a00; background: #FFE1D0; border-radius: 999px; padding: 2px 10px; }
@media (max-width: 575.98px) { .pp-marcas-grade { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; } .pp-marca-cartao-nome { font-size: 15px; } }

/* Página do produto no celular/tablet: título menor, bloco de compra compacto e barra de compra fixa, para o Comprar aparecer sem rolar.
   Só layout; quantidade mínima, múltiplos e carrinho seguem o mesmo formulário. */
@media (max-width: 991.98px) {
  .product-info-content .product-title { gap: 1rem !important; margin-top: 1.2rem !important; }
  .product-info-content .product-title .brand-price-wrapper .product-brand { width: 5.6rem; height: 5.6rem; min-width: 5.6rem; margin-right: 1rem !important; }
  .product-info-content .product-title .h1 { font-size: 18px; line-height: 1.25; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
  .product-info-content .product-title .product-reference { margin-top: .4rem !important; }
  .product-info-content .product-action { margin-top: .8rem !important; }
  .product-info-content .product-values { margin: 0 0 .6rem !important; padding: 0 !important; }
  .product-info-content .review-stars { margin-top: 0 !important; }
  .product-info-content .product-action-price { margin: .6rem 0 !important; }
  .product-info-content .product-action-price .row { gap: .4rem; }
  .product-info-content .product-buy { margin-top: .8rem !important; flex-wrap: nowrap; align-items: stretch; }
  .product-info-content .product-buy > .dc-quantity { flex: 0 0 38%; max-width: 38%; margin: 0 .8rem 0 0 !important; }
  .product-info-content .product-buy .dc-input,
  .product-info-content .product-buy .dc-decrease,
  .product-info-content .product-buy .dc-increase,
  .product-info-content .product-buy > .dc-quantity { min-height: 5rem; }
  .product-info-content .product-buy .product-action-buy { padding: 1rem !important; min-height: 5rem; }
}

/* Barra de compra fixa (celular): aparece só quando o botão Comprar real sai da tela. */
.pp-barra-compra { display: none; }
@media (max-width: 991.98px) {
  .pp-barra-compra { position: fixed; left: 0; right: 0; bottom: 0; z-index: 9980; align-items: center; gap: 1.2rem; padding: 1rem 1.6rem calc(1rem + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid #e1e1e1; box-shadow: 0 -4px 16px rgba(68, 1, 67, .12); transform: translateY(110%); transition: transform .2s ease; }
  body.pp-compra-fixa .pp-barra-compra { display: flex; transform: none; }
  .pp-barra-compra .pp-barra-preco { flex: 1 1 auto; min-width: 0; line-height: 1.2; color: #440143; }
  .pp-barra-compra .pp-barra-preco strong { display: block; font-size: 1.9rem; font-weight: 800; }
  .pp-barra-compra .pp-barra-preco span { display: block; font-size: 1.2rem; opacity: .75; }
  .pp-barra-compra .pp-barra-btn { flex: 0 0 auto; min-height: 4.8rem; padding: 0 2.4rem; border: 0; border-radius: 6px; background: #08B65D; color: #FEF2E2; font-weight: 700; font-size: 1.5rem; text-transform: lowercase; }
  .pp-barra-compra.sem-preco .pp-barra-btn { flex: 1 1 auto; }
  /* flutuantes (selo, app, chat) sobem para não ficarem por cima da barra */
  body.pp-compra-fixa #pp-gcr-selo { bottom: calc(32px + 7.6rem) !important; }
  body.pp-compra-fixa .app-fab--left { bottom: calc(27px + 7.6rem) !important; }
  body.pp-compra-fixa #ppc-b { bottom: calc(32px + 7.6rem) !important; }
  body.pp-compra-fixa #ppc-c { bottom: calc(100px + 7.6rem) !important; }
  body.pp-compra-fixa { padding-bottom: 7.2rem; }
}
