:root{
  --gn-mobile-vh:1vh;
}

html.gn-idx-mobile-filter-open,
body.gn-idx-mobile-filter-open{
  overflow:hidden !important;
  touch-action:none;
}

@media (max-width:980px){
  .gn-idx,
  .gn-espo-idx{
    width:100% !important;
    margin-left:0 !important;
  }

  .gn-idx__topbar,
  .gn-idx__searchRow,
  .gn-idx__toolRow{
    padding-left:16px !important;
    padding-right:16px !important;
  }

  .gn-idx__count-row{
    font-size:16px !important;
  }

  .gn-idx__searchRow{
    gap:10px !important;
    padding-bottom:12px !important;
  }

  .gn-idx__searchBox{
    min-width:100% !important;
  }

  .gn-idx__toolRow{
    align-items:center !important;
    gap:10px !important;
    padding-bottom:14px !important;
  }

  .gn-idx__sortWrap,
  .gn-idx__btn--filter{
    width:100%;
  }

  .gn-idx__sortWrap{
    justify-content:space-between;
  }

  .gn-idx__sortSel,
  .gn-idx__btn--filter{
    min-height:44px;
  }

  .gn-idx__grid{
    grid-template-columns:1fr !important;
    gap:16px !important;
    padding:10px 16px 28px !important;
  }

  .gn-idx__card{
    border-radius:20px !important;
    border-color:rgba(0,0,0,.08) !important;
    box-shadow:0 12px 32px rgba(0,0,0,.10) !important;
  }

  .gn-idx__img,
  .gn-idx__noimg{
    width:100% !important;
    height:auto !important;
    aspect-ratio:4 / 3 !important;
    min-height:260px;
  }

  .gn-idx__card-body{
    padding:16px 16px 18px !important;
  }

  .gn-idx__card-price{
    font-size:28px !important;
    line-height:1.05;
  }

  .gn-idx__card-addr{
    font-size:15px !important;
    white-space:normal !important;
    line-height:1.35;
  }

  .gn-idx__card-type,
  .gn-idx__card-stats{
    font-size:13px !important;
  }

  .gn-idx__right{
    height:auto !important;
    min-height:0 !important;
  }

  .gn-idx__map{
    min-height:46vh;
  }

  .gn-idx__fp{
    position:fixed !important;
    inset:0 !important;
    width:100vw !important;
    height:calc(var(--gn-mobile-vh, 1vh) * 100) !important;
    max-height:none !important;
    border-radius:0 !important;
    border-left:none !important;
    box-shadow:none !important;
    z-index:999999 !important;
    transform:translateY(100%) !important;
    background:rgba(245,247,250,.98) !important;
  }

  .gn-idx__fp.gn-idx__fp--anim{
    transition:transform .28s ease, visibility .28s ease !important;
  }

  .gn-idx__fp.gn-idx__fp--open{
    transform:translateY(0) !important;
  }

  .gn-idx__fp-head{
    padding:calc(14px + env(safe-area-inset-top)) 16px 14px !important;
    gap:12px !important;
    z-index:4 !important;
  }

  .gn-idx__fp-close{
    position:relative !important;
    top:auto !important;
    right:auto !important;
    width:48px !important;
    min-width:48px !important;
    height:48px !important;
    min-height:48px !important;
    border-radius:999px !important;
    background:rgba(255,255,255,.96) !important;
    border:1px solid rgba(0,0,0,.10) !important;
    color:#243041 !important;
    box-shadow:0 10px 28px rgba(0,0,0,.14) !important;
    display:inline-flex !important;
    align-items:center !important;
    justify-content:center !important;
    flex-shrink:0 !important;
    touch-action:manipulation !important;
  }

  .gn-idx__fp-body{
    padding:0 16px 18px !important;
  }

  .gn-idx__fp-foot{
    padding:14px 16px calc(14px + env(safe-area-inset-bottom)) !important;
  }

  .gn-idx__fp-title{
    font-size:22px !important;
  }

  .gn-idx__toggle{
    margin-left:16px !important;
    margin-right:16px !important;
  }

  .gn-idx__qp-grid{
    grid-template-columns:1fr 1fr !important;
    gap:4px 10px !important;
  }

  .gn-idx__ms-drop{
    max-height:42vh !important;
  }

  .gn-detail__breadcrumbs{
    padding-left:16px !important;
    padding-right:16px !important;
  }

  .gn-detail__hero{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:10px !important;
    min-height:0 !important;
    padding:0 16px !important;
    background:transparent !important;
  }

  .gn-detail__hero-main{
    min-height:42vh !important;
    border-radius:24px !important;
  }

  .gn-detail__hero-main img{
    min-height:42vh !important;
  }

  .gn-detail__hero-side{
    grid-template-columns:repeat(3, minmax(0, 1fr)) !important;
    grid-auto-rows:minmax(108px, 1fr) !important;
    gap:10px !important;
  }

  .gn-detail__hero-side img,
  .gn-detail__hero-gallery{
    width:100% !important;
    height:100% !important;
    min-height:108px !important;
    border-radius:16px !important;
    overflow:hidden;
  }

  .gn-detail__info-bar{
    margin:12px 16px 0 !important;
    padding:20px 18px !important;
    border-radius:22px !important;
    box-shadow:0 12px 32px rgba(0,0,0,.10) !important;
  }

  .gn-detail__info-title{
    font-size:24px !important;
    line-height:1.15 !important;
  }

  .gn-detail__info-price{
    font-size:22px !important;
  }

  .gn-detail__body{
    padding:24px 16px 32px !important;
  }

  .gn-detail__section{
    margin-bottom:32px !important;
  }

  .gn-detail__contact,
  .gn-detail__cta{
    margin-left:0 !important;
    margin-right:0 !important;
  }

  .gn-detail__gallery-modal{
    z-index:1000001 !important;
    padding-top:0 !important;
    padding-bottom:env(safe-area-inset-bottom) !important;
  }

  .gn-detail__gallery-topbar{
    top:calc(10px + env(safe-area-inset-top)) !important;
    left:12px !important;
    right:12px !important;
    z-index:1000003 !important;
    align-items:center !important;
  }

  .gn-detail__gallery-close{
    position:relative !important;
    width:48px !important;
    min-width:48px !important;
    height:48px !important;
    min-height:48px !important;
    font-size:28px !important;
    background:rgba(20,24,31,.72) !important;
    border:1px solid rgba(255,255,255,.18) !important;
    color:#fff !important;
    box-shadow:0 10px 26px rgba(0,0,0,.28) !important;
    flex-shrink:0 !important;
    touch-action:manipulation !important;
  }

  .gn-detail__gallery-stage{
    padding:74px 8px 12px !important;
  }

  .gn-detail__gallery-img{
    padding:0 4px !important;
  }

  .gn-detail__gallery-img img{
    max-width:100% !important;
    max-height:calc(var(--gn-mobile-vh, 1vh) * 72) !important;
  }

  .gn-detail__gallery-arrow{
    width:44px !important;
    height:44px !important;
    font-size:24px !important;
  }

  .gn-detail__gallery-arrow--prev{
    left:8px !important;
  }

  .gn-detail__gallery-arrow--next{
    right:8px !important;
  }

  .gn-detail__gallery-bottom{
    padding:0 12px calc(12px + env(safe-area-inset-bottom)) !important;
  }

  .gn-detail__gallery-thumbs{
    gap:10px !important;
  }

  .gn-detail__gallery-thumbs img{
    width:112px !important;
    height:80px !important;
    border-radius:12px !important;
    opacity:.92 !important;
  }
}
