@media (min-width: 1200px) {
  .header-bottom__row {
    display: grid !important;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    column-gap: 24px;
  }

  .header-bottom__row > .logo {
    grid-column: 1;
    justify-self: start;
    margin: 0 !important;
  }

  .header-bottom__row > .main-menu {
    grid-column: 2;
    justify-self: center;
    width: 100%;
    margin: 0 !important;
    display: block !important;
  }

  #search_widget,
  .search-widget {
    grid-column: 3;
    justify-self: end;
    margin: 0 !important;
    max-width: 320px;
  }

  .custom-desktop-shortmenu {
    width: 100%;
    position: static;
  }

  .custom-short-menu {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin: 0;
    padding: 8px 0;
    list-style: none;
  }

  .custom-short-menu__item {
    position: relative;
  }

  .custom-short-menu__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 42px;
    padding: 0 16px;
    border-radius: 10px;
    text-decoration: none;
    color: #2f3842;
    line-height: 1;
    white-space: nowrap;
    transition: all .2s ease;
  }

  .custom-short-menu__link:hover {
    color: #0d6efd;
    background: rgba(13, 110, 253, 0.08);
  }

  .custom-short-menu__link--toggle {
    background: #0d6efd;
    color: #fff !important;
    font-weight: 600;
  }

  .custom-short-menu__link--toggle:hover {
    background: #0b5ed7;
    color: #fff !important;
  }

  .custom-short-menu__dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 340px;
    max-width: 900px;
    margin-top: 0;
    padding: 14px 18px;
    background: #fff;
    border: 1px solid #ececec;
    border-radius: 14px;
    box-shadow: 0 16px 40px rgba(0,0,0,.12);
    z-index: 9999;
    overflow: visible;
  }

  .custom-short-menu__item--products::after {
    content: "";
    position: absolute;
    left: 0;
    top: 100%;
    width: 100%;
    height: 16px;
    z-index: 9998;
  }

  .custom-short-menu__item--products:hover .custom-short-menu__dropdown,
  .custom-short-menu__item--products:focus-within .custom-short-menu__dropdown {
    display: block;
  }

  .custom-short-menu__dropdown #top-menu.custom-products-menu {
    display: block;
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .custom-short-menu__dropdown #top-menu.custom-products-menu > li.main-menu__tree__item {
    display: block;
    margin: 0;
    padding: 0;
    position: relative;
  }

  .custom-short-menu__dropdown #top-menu.custom-products-menu > li.main-menu__tree__item > a.main-menu__tree__link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-width: 260px;
    padding: 10px 0;
    text-decoration: none;
    white-space: nowrap;
    border-bottom: 1px solid #f3f3f3;
    color: #2f3842;
  }

  .custom-short-menu__dropdown #top-menu.custom-products-menu > li.main-menu__tree__item > a.main-menu__tree__link:hover {
    color: #0d6efd;
  }

  .custom-short-menu__dropdown #top-menu.custom-products-menu > li.main-menu__tree__item:last-child > a.main-menu__tree__link {
    border-bottom: 0;
  }

  .custom-short-menu__dropdown .menu-container {
    left: calc(100% + 12px) !important;
    top: 0 !important;
    min-width: 320px;
  }

  .header-bottom .logo img,
  .header-bottom .logo .img-fluid {
    max-height: 56px;
    width: auto;
  }
}

@media (max-width: 991.98px) {
  #category #left-column,
  .page-category #left-column,
  body#category #left-column {
    display: none !important;
  }

  #category #content-wrapper,
  .page-category #content-wrapper,
  body#category #content-wrapper {
    flex: 0 0 100% !important;
    max-width: 100% !important;
    width: 100% !important;
  }
}

.cod-terms-error {
  border: 1px solid #dc3545;
  border-radius: 6px;
  padding: 8px;
  background: rgba(220, 53, 69, 0.06);
}

.cod-terms-error-message {
  margin-top: 6px;
  color: #dc3545;
  font-size: 14px;
  line-height: 1.3;
}

@media (min-width: 1200px) {
  /* coluna esquerda SEMPRE vertical */
  .custom-short-menu__dropdown #top-menu.custom-products-menu {
    display: flex !important;
    flex-direction: column !important;
    width: 320px !important;
    min-width: 320px !important;
    max-width: 320px !important;
  }

  .custom-short-menu__dropdown #top-menu.custom-products-menu > li.main-menu__tree__item {
    display: block !important;
    width: 100% !important;
    min-width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    clear: both !important;
    flex: 0 0 100% !important;
  }

  .custom-short-menu__dropdown #top-menu.custom-products-menu > li.main-menu__tree__item > a.main-menu__tree__link {
    display: flex !important;
    width: 100% !important;
    min-width: 100% !important;
    white-space: nowrap !important;
  }

  /* painel direito maior e mais legível */
  .custom-short-menu__dropdown .menu-container {
    left: calc(100% + 14px) !important;
    min-width: 820px !important;
    max-width: 980px !important;
    padding: 18px 22px !important;
  }

  /* transformar subcategorias em lista/grelha limpa */
  .custom-short-menu__dropdown .menu-container > .container > ul.row {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(220px, 1fr)) !important;
    gap: 12px 28px !important;
    margin: 0 !important;
  }

  .custom-short-menu__dropdown .menu-container > .container > ul.row > li,
  .custom-short-menu__dropdown .menu-container > .container > ul.row > .col,
  .custom-short-menu__dropdown .menu-container > .container > ul.row > [class*="col-"] {
    width: auto !important;
    max-width: none !important;
    flex: 0 0 auto !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  .custom-short-menu__dropdown .menu-container a,
  .custom-short-menu__dropdown .dropdown-item,
  .custom-short-menu__dropdown .submenu a {
    display: block !important;
    font-size: 14px !important;
    line-height: 1.25 !important;
    font-weight: 500 !important;
    white-space: normal !important;
    word-break: normal !important;
    overflow-wrap: break-word !important;
    hyphens: none !important;
    padding: 3px 0 !important;
  }

  .custom-short-menu__dropdown .submenu {
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
  }
}


@media (min-width: 1200px) {
  /* o item Produtos não pode cortar o dropdown */
  .custom-short-menu__item--products {
    position: relative !important;
  }

  /* dropdown principal mais largo e sem cortar */
  .custom-short-menu__dropdown {
    overflow: visible !important;
    min-width: 360px !important;
  }

  /* ponte invisível entre botão azul e dropdown */
  .custom-short-menu__item--products::after {
    content: "" !important;
    position: absolute !important;
    left: 0 !important;
    top: 100% !important;
    width: 100% !important;
    height: 22px !important;
    z-index: 10000 !important;
  }

  /* manter dropdown aberto também ao fazer hover no próprio painel */
  .custom-short-menu__item--products:hover .custom-short-menu__dropdown,
  .custom-short-menu__item--products:focus-within .custom-short-menu__dropdown,
  .custom-short-menu__dropdown:hover {
    display: block !important;
  }

  /* coluna esquerda: UL vertical sem wrap nem row */
  .custom-short-menu__dropdown ul#top-menu.custom-products-menu {
    display: block !important;
    width: 320px !important;
    min-width: 320px !important;
    max-width: 320px !important;
    float: left !important;
    clear: left !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  /* cada categoria pai ocupa linha inteira */
  .custom-short-menu__dropdown ul#top-menu.custom-products-menu > li,
  .custom-short-menu__dropdown ul#top-menu.custom-products-menu > li.main-menu__tree__item {
    display: block !important;
    float: none !important;
    clear: both !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    flex: none !important;
  }

  .custom-short-menu__dropdown ul#top-menu.custom-products-menu > li > a,
  .custom-short-menu__dropdown ul#top-menu.custom-products-menu > li.main-menu__tree__item > a.main-menu__tree__link {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    min-width: 100% !important;
    white-space: nowrap !important;
  }

  /* item pai cria a ponte para o submenu da direita */
  .custom-short-menu__dropdown ul#top-menu.custom-products-menu > li.main-menu__tree__item {
    position: relative !important;
  }

  .custom-short-menu__dropdown ul#top-menu.custom-products-menu > li.main-menu__tree__item::after {
    content: "" !important;
    position: absolute !important;
    top: 0 !important;
    left: 100% !important;
    width: 26px !important;
    height: 100% !important;
    z-index: 10000 !important;
  }

  /* submenu direito mais perto para não haver buraco */
  .custom-short-menu__dropdown .menu-container {
    left: calc(100% + 4px) !important;
    top: 0 !important;
    z-index: 10001 !important;
    overflow: auto !important;
  }

  /* mantém submenu aberto quando o rato entra nele */
  .custom-short-menu__dropdown ul#top-menu.custom-products-menu > li.main-menu__tree__item:hover > .menu-container,
  .custom-short-menu__dropdown ul#top-menu.custom-products-menu > li.main-menu__tree__item:focus-within > .menu-container,
  .custom-short-menu__dropdown .menu-container:hover {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
  }
}


@media (min-width: 1200px) {
  /* manter aberto o dropdown de Produtos */
  .custom-short-menu__item--products:hover .custom-short-menu__dropdown,
  .custom-short-menu__item--products:focus-within .custom-short-menu__dropdown,
  .custom-short-menu__dropdown:hover {
    display: block !important;
  }

  /* ponte maior entre botão Produtos e painel */
  .custom-short-menu__item--products::after {
    content: "" !important;
    position: absolute !important;
    left: 0 !important;
    top: 100% !important;
    width: 100% !important;
    height: 28px !important;
    z-index: 10020 !important;
  }

  .custom-short-menu__dropdown {
    overflow: visible !important;
    z-index: 10010 !important;
  }

  /* UL da esquerda fixa */
  .custom-short-menu__dropdown #top-menu {
    width: 320px !important;
    min-width: 320px !important;
    max-width: 320px !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
  }

  /* aqui está o fix principal: matar o d-flex do tema */
  .custom-short-menu__dropdown #top-menu > li.main-menu__tree__item {
    display: block !important;
    width: 100% !important;
    min-width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    clear: both !important;
    flex: none !important;
    height: auto !important;
    align-items: initial !important;
    position: relative !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .custom-short-menu__dropdown #top-menu > li.main-menu__tree__item > a.main-menu__tree__link {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    min-width: 100% !important;
    padding: 10px 0 !important;
    white-space: nowrap !important;
  }

  /* ponte entre coluna esquerda e submenu */
  .custom-short-menu__dropdown #top-menu > li.main-menu__tree__item::after {
    content: "" !important;
    position: absolute !important;
    top: 0 !important;
    left: 100% !important;
    width: 36px !important;
    height: 100% !important;
    z-index: 10020 !important;
  }

  /* submenu mais perto */
  .custom-short-menu__dropdown .menu-container {
    left: calc(100% + 2px) !important;
    top: 0 !important;
    z-index: 10030 !important;
  }

  /* manter submenu aberto */
  .custom-short-menu__dropdown #top-menu > li.main-menu__tree__item:hover > .menu-container,
  .custom-short-menu__dropdown #top-menu > li.main-menu__tree__item:focus-within > .menu-container,
  .custom-short-menu__dropdown .menu-container:hover {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
  }
}

