/* Orbizzy Responsive Layer v400
   Faixas: celular, tablet/iPad, notebook/desktop, telas grandes/TV.
   Este arquivo deve ser carregado por ultimo para corrigir limites fixos antigos. */

:root{
  --orbz-fluid-gutter:clamp(10px,2.1vw,40px);
  --orbz-desktop-max:1280px;
  --orbz-wide-max:1760px;
  --orbz-tv-max:2800px;
}

html{
  width:100%;
  min-width:0;
  overflow-x:hidden;
  -webkit-text-size-adjust:100%;
  text-size-adjust:100%;
}
body{
  width:100%;
  min-width:0;
  overflow-x:hidden;
}
*,*::before,*::after{box-sizing:border-box}
img,video,canvas,svg{max-width:100%}
input,button,select,textarea{max-width:100%}

/* Evita estouro em estruturas flex/grid compartilhadas. */
.orbi-header__row1,.orbi-header__row2-inner,.orbi-nav-left,.orbi-nav-right,
.orbz-container,.orbz-product-shell,.oc-shell,.opx-wrap,.ob227-wrap,
.orbizzy-da-exact .container.row,.orbi-deals-desktop,.orbi-plus-desktop{
  min-width:0;
}

/* =============== CELULAR PEQUENO =============== */
@media (max-width:599px){
  .orbi-header-mobile,
  .orbz-mobile-home,
  .orbz-system-page,
  .orbz-product-shell{width:100%;max-width:100%}

  .orbz-container{width:calc(100% - 14px)!important;max-width:none!important}
  .orbz-product-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .orbz-link-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}

  .orbz-mobile-banner-carousel,
  .orbz-mobile-banner,
  .orbz-mobile-banner img,
  .orbz-mobile-banner video{max-width:100%!important}

  .orbi-footer{width:100%;max-width:100%;padding-left:14px!important;padding-right:14px!important}
}

/* =============== TABLET / IPAD EM RETRATO =============== */
@media (min-width:600px) and (max-width:860px){
  .orbi-header-mobile{width:100%;max-width:none}

  .orbz-container{
    width:calc(100% - 32px)!important;
    max-width:820px!important;
  }
  .orbz-product-grid{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:12px!important;
  }
  .orbz-link-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}
  .orbz-info-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}

  body.orbz-product-document .orbz-product-related-grid{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:12px!important;
  }
  body.orbz-product-document .orbz-product-related-card__image{
    height:clamp(160px,23vw,210px)!important;
  }

  .orbz-mobile-secondary,
  .orbz-mobile-offerday,
  .orbi-plus-mobile,
  .orbz-mobile-categories,
  .orbz-mobile-frete{
    max-width:820px!important;
  }

  .orbi-footer{width:calc(100% - 32px);max-width:820px;padding-left:0!important;padding-right:0!important}
}

/* Tablets maiores em modo paisagem e notebooks compactos. */
@media (min-width:861px) and (max-width:1199px){
  .orbi-header__row1,.orbi-header__row2-inner{width:100%;max-width:100%!important;padding-left:18px!important;padding-right:18px!important}
  .orbi-nav-left{gap:clamp(12px,1.6vw,20px)!important}
  .orbi-media-slot.orbi-media-slot--video{flex-basis:clamp(190px,21vw,240px)!important;width:clamp(190px,21vw,240px)!important}

  .orbz-container{width:calc(100% - 32px)!important;max-width:none!important}
  .orbz-product-shell{width:calc(100% - 24px)!important;max-width:none!important}
  .oc-breadcrumb,.oc-shell,.opx-wrap,.ob227-wrap{width:calc(100% - 32px)!important;max-width:none!important}
}

/* =============== DESKTOP PADRAO =============== */
@media (min-width:1200px) and (max-width:1599px){
  .orbi-header__row1,.orbi-header__row2-inner,.orbi-footer{max-width:1360px!important}
  .orbz-container{width:min(1280px,calc(100% - 48px))!important;max-width:none!important}
  .orbz-product-shell{max-width:1320px!important}
  .oc-breadcrumb,.oc-shell{max-width:1320px!important}
  .opx-wrap,.ob227-wrap,.ob227-topbanner__inner{max-width:1280px!important}
  .orbizzy-da-exact .container.row,.orbi-deals-desktop,.orbi-plus-desktop{max-width:1280px!important}
}

/* =============== DESKTOP GRANDE / MONITOR 2K =============== */
@media (min-width:1600px) and (max-width:2199px){
  :root{--orbz-current-wide:min(92vw,var(--orbz-wide-max))}

  .navbar{padding-left:clamp(28px,4vw,74px)!important;padding-right:clamp(28px,4vw,74px)!important;font-size:14px!important}
  .orbi-header__row1,.orbi-header__row2-inner,.orbi-footer{
    width:var(--orbz-current-wide)!important;
    max-width:none!important;
  }
  .orbi-header__row1{gap:24px!important;padding-left:0!important;padding-right:0!important}
  .orbi-header__row2-inner{padding-left:0!important;padding-right:0!important}
  .orbi-logo img{height:38px!important;width:auto!important}
  .orbi-search{height:46px!important}
  .orbi-media-slot.orbi-media-slot--video{
    flex-basis:300px!important;width:300px!important;height:46px!important;
  }
  .orbi-nav-left{gap:26px!important}
  .orbi-navlink,.orbi-categ-trigger{font-size:14px!important}

  .orbz-desktop-hero,.orbz-desktop-carousel,.orbz-desktop-slide,.orbz-desktop-slide img,.orbz-desktop-slide video{
    height:clamp(390px,22vw,500px)!important;
  }
  .orbz-desktop-hero{min-height:clamp(390px,22vw,500px)!important}

  .orbizzy-da-exact .container.row,
  .orbi-deals-desktop,
  .orbi-plus-desktop,
  .orbz-container,
  .orbz-product-shell,
  .oc-breadcrumb,.oc-shell,
  .opx-wrap,
  .ob227-wrap,.ob227-topbanner__inner{
    width:var(--orbz-current-wide)!important;
    max-width:none!important;
  }

  .orbz-product-grid{grid-template-columns:repeat(5,minmax(0,1fr))!important;gap:18px!important}
  .orbz-store-list-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important}
  .orbz-link-grid{grid-template-columns:repeat(5,minmax(0,1fr))!important}
  .orbz-info-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important}

  body.orbz-product-document .orbz-product-main-card{
    grid-template-columns:minmax(0,1.7fr) minmax(360px,.8fr)!important;
    gap:22px!important;
  }
  body.orbz-product-document .orbz-product-stage{min-height:560px!important}
  body.orbz-product-document .orbz-product-stage img{height:550px!important;max-height:550px!important}
  body.orbz-product-document .orbz-product-desktop-carousel .orbz-product-related-card{
    flex:0 0 calc((100% - 64px)/5)!important;
    width:calc((100% - 64px)/5)!important;
    min-width:calc((100% - 64px)/5)!important;
    max-width:calc((100% - 64px)/5)!important;
  }
  body.orbz-product-document .orbz-product-related-grid{gap:16px!important}

  .oc-shell{grid-template-columns:280px minmax(0,1fr)!important;gap:24px!important}
  .opx-section{padding:clamp(30px,2vw,40px)!important}
  .ob227-hero h2{font-size:clamp(30px,2vw,38px)!important}

  .orbi-footer{font-size:13.5px!important;padding-left:0!important;padding-right:0!important}
}

/* =============== TV / 4K / TELAS MUITO GRANDES =============== */
@media (min-width:2200px){
  :root{--orbz-current-tv:min(90vw,var(--orbz-tv-max))}

  .navbar{
    min-height:44px!important;
    height:auto!important;
    padding:8px max(5vw,56px)!important;
    font-size:clamp(14px,.48vw,18px)!important;
  }
  .navbar .flex{gap:clamp(16px,.75vw,28px)!important}
  .navbar__links{gap:clamp(20px,1vw,36px)!important}

  .orbi-header__row1,.orbi-header__row2-inner,.orbi-footer{
    width:var(--orbz-current-tv)!important;
    max-width:none!important;
  }
  .orbi-header__row1{
    gap:clamp(24px,1.2vw,42px)!important;
    padding:clamp(16px,.8vw,26px) 0 12px!important;
  }
  .orbi-header__row2-inner{padding:0 0 clamp(12px,.7vw,22px)!important;gap:28px!important}
  .orbi-logo img{height:clamp(42px,1.45vw,58px)!important;width:auto!important}
  .orbi-search{height:clamp(50px,1.5vw,62px)!important;border-radius:10px!important}
  .orbi-search input{font-size:clamp(15px,.55vw,20px)!important;padding-left:18px!important}
  .orbi-search button{width:clamp(46px,1.4vw,58px)!important}
  .orbi-media-slot.orbi-media-slot--video{
    flex:0 0 clamp(330px,12vw,440px)!important;
    width:clamp(330px,12vw,440px)!important;
    height:clamp(50px,1.5vw,62px)!important;
  }
  .orbi-nav-left{gap:clamp(24px,1vw,38px)!important;padding-top:16px!important}
  .orbi-navlink,.orbi-categ-trigger{font-size:clamp(14px,.5vw,18px)!important}
  .orbi-location__label{font-size:clamp(11px,.4vw,15px)!important}
  .orbi-location__value{font-size:clamp(13px,.46vw,17px)!important}

  .orbz-desktop-hero,.orbz-desktop-carousel,.orbz-desktop-slide,.orbz-desktop-slide img,.orbz-desktop-slide video{
    height:clamp(500px,19vw,730px)!important;
  }
  .orbz-desktop-hero{min-height:clamp(500px,19vw,730px)!important}
  .orbz-desktop-arrow{width:50px!important;height:50px!important}

  .orbizzy-da-exact .container.row,
  .orbi-deals-desktop,
  .orbi-plus-desktop,
  .orbz-container,
  .orbz-product-shell,
  .oc-breadcrumb,.oc-shell,
  .opx-wrap,
  .ob227-wrap,.ob227-topbanner__inner{
    width:var(--orbz-current-tv)!important;
    max-width:none!important;
  }

  .orbizzy-da-exact .andes-card.dynamic-access-card{min-height:390px!important}
  .orbi-deals-grid{grid-template-columns:minmax(340px,.8fr) minmax(0,3.2fr)!important;gap:22px!important}
  .orbi-deal-card,.orbi-offers-panel{min-height:560px!important}
  .orbi-plus-desktop__box{height:360px!important}

  .orbz-container{margin-left:auto!important;margin-right:auto!important}
  .orbz-product-grid{grid-template-columns:repeat(6,minmax(0,1fr))!important;gap:20px!important}
  .orbz-store-list-grid{grid-template-columns:repeat(5,minmax(0,1fr))!important;gap:20px!important}
  .orbz-link-grid{grid-template-columns:repeat(6,minmax(0,1fr))!important;gap:18px!important}
  .orbz-info-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:20px!important}
  .orbz-product-card__title{font-size:clamp(14px,.45vw,18px)!important;line-height:1.35!important}
  .orbz-product-card__price{font-size:clamp(22px,.75vw,30px)!important}
  .orbz-product-card__installment,.orbz-product-card__shipping,.orbz-product-card__seller{font-size:clamp(12px,.4vw,16px)!important}

  body.orbz-product-document .orbz-product-main-card{
    grid-template-columns:minmax(0,1.75fr) minmax(420px,.72fr)!important;
    gap:28px!important;
    padding:24px!important;
  }
  body.orbz-product-document .orbz-product-stage{min-height:680px!important}
  body.orbz-product-document .orbz-product-stage img{height:670px!important;max-height:670px!important}
  body.orbz-product-document .orbz-product-section{padding:28px!important}
  body.orbz-product-document .orbz-product-desktop-carousel .orbz-product-related-card{
    flex:0 0 calc((100% - 100px)/6)!important;
    width:calc((100% - 100px)/6)!important;
    min-width:calc((100% - 100px)/6)!important;
    max-width:calc((100% - 100px)/6)!important;
  }
  body.orbz-product-document .orbz-product-related-grid{gap:20px!important}

  .oc-shell{grid-template-columns:320px minmax(0,1fr)!important;gap:28px!important}
  .oc-panel{font-size:clamp(14px,.42vw,18px)!important}
  .opx-section{padding:clamp(38px,1.7vw,58px)!important}
  .opx-section-head h2{font-size:clamp(28px,1vw,40px)!important}
  .opx-section-head p{font-size:clamp(14px,.48vw,18px)!important}
  .ob227-hero h2{font-size:clamp(34px,1.2vw,46px)!important}
  .ob227-hero p{font-size:clamp(14px,.48vw,18px)!important;max-width:1500px!important}

  .orbi-auth-page{width:min(92vw,1900px)!important;max-width:none!important}
  .orbi-footer{font-size:clamp(13px,.42vw,17px)!important;padding:34px 0!important}
}

/* Telas muito largas e baixas (TV/monitor ultrawide): evita banner exageradamente alto. */
@media (min-width:1600px) and (max-height:900px){
  .orbz-desktop-hero,.orbz-desktop-carousel,.orbz-desktop-slide,.orbz-desktop-slide img,.orbz-desktop-slide video{
    height:clamp(340px,43vh,440px)!important;
  }
  .orbz-desktop-hero{min-height:clamp(340px,43vh,440px)!important}
}

/* PWA / aparelhos com notch e barras do sistema. */
@supports (padding:max(0px)){
  @media (max-width:860px){
    .orbi-header-mobile{padding-left:max(0px,env(safe-area-inset-left));padding-right:max(0px,env(safe-area-inset-right))}
    .orbz-mobile-bottom-nav{padding-bottom:env(safe-area-inset-bottom)!important;height:calc(64px + env(safe-area-inset-bottom))!important;max-height:none!important}
    body.orbz-product-document{padding-bottom:calc(66px + env(safe-area-inset-bottom))!important}
  }
}
