/* Synthetic Hearts — desktop viewport compact v1
   Obiettivo: dashboard Scopri e Chat dentro una viewport desktop standard
   senza scroll della pagina. Le aree interne della chat restano scrollabili. */

@media (min-width: 1101px) and (min-height: 700px) {
  /* DISCOVER */
  .member-shell.swipe-dashboard{
    padding-top: 24px !important;
    padding-bottom: 18px !important;
  }

  .swipe-topbar{
    align-items: center !important;
    margin-bottom: 16px !important;
  }

  .swipe-topbar h1{
    font-size: clamp(2.7rem, 3.7vw, 3.65rem) !important;
    line-height: .96 !important;
  }

  .swipe-topbar > div > p{
    margin-top: 10px !important;
    line-height: 1.45 !important;
  }

  .compact-profile{
    transform: scale(.92);
    transform-origin: right center;
  }

  .discovery-layout{
    min-height: 0 !important;
    height: min(570px, calc(100dvh - 285px)) !important;
    gap: 30px !important;
  }

  .discovery-side{
    padding: 20px !important;
  }

  .discovery-side h2{
    font-size: 1.55rem !important;
  }

  .discovery-side > p{
    margin-top: 10px !important;
    line-height: 1.5 !important;
  }

  .swipe-legend{
    margin-top: 18px !important;
  }

  .swipe-deck{
    height: 100% !important;
    min-height: 0 !important;
  }

  .swipe-card{
    height: calc(100% - 12px) !important;
    max-height: 520px !important;
    min-height: 430px !important;
    width: min(100%, 405px) !important;
    border-radius: 27px !important;
  }

  .swipe-photo{
    height: calc(100% - 112px) !important;
  }

  .swipe-card-detail{
    height: 112px !important;
    padding: 15px 21px !important;
  }

  .swipe-card-detail p{
    font-size: .81rem !important;
    line-height: 1.38 !important;
  }

  .persona-content{
    left: 21px !important;
    right: 21px !important;
    bottom: 18px !important;
  }

  .persona-name-row h2{
    font-size: 1.9rem !important;
  }

  .swipe-controls{
    margin-top: 8px !important;
  }

  .swipe-pass,.swipe-match{
    width: 54px !important;
    height: 54px !important;
  }

  .swipe-hint{
    margin-top: 7px !important;
  }

  /* CHAT: il documento non deve scrollare; scrollano messaggi/lista. */
  body:has(.chat-page){
    overflow: hidden !important;
  }

  .chat-page{
    height: calc(100dvh - 88px) !important;
    min-height: 0 !important;
    margin: 78px auto 10px !important;
  }

  .chat-sidebar{
    padding-top: 18px !important;
    padding-bottom: 14px !important;
  }

  .chat-sidebar-head{
    padding-bottom: 12px !important;
  }

  .chat-search{
    margin-bottom: 10px !important;
  }

  .chat-list{
    max-height: none !important;
    min-height: 0 !important;
    overflow-y: auto !important;
  }

  .chat-main{
    min-height: 0 !important;
  }

  .chat-messages{
    min-height: 0 !important;
    overflow-y: auto !important;
  }

  .chat-relationship{
    min-height: 0 !important;
    overflow-y: auto !important;
    padding-top: 18px !important;
    padding-bottom: 16px !important;
  }

  .relationship-profile{
    padding-top: 4px !important;
    padding-bottom: 17px !important;
  }

  .relationship-profile img{
    width: 76px !important;
    height: 76px !important;
  }
}

/* Schermi desktop più bassi (es. notebook 768px): compressione ulteriore. */
@media (min-width: 1101px) and (max-height: 820px) {
  .member-shell.swipe-dashboard{
    padding-top: 12px !important;
  }
  .swipe-topbar{
    margin-bottom: 10px !important;
  }
  .swipe-topbar h1{
    font-size: 2.75rem !important;
  }
  .swipe-topbar > div > p{
    margin-top: 6px !important;
    font-size: .86rem !important;
  }
  .discovery-layout{
    height: calc(100dvh - 235px) !important;
  }
  .swipe-card{
    min-height: 390px !important;
  }
  .swipe-controls{
    display: none !important;
  }
  .swipe-hint{
    display: none !important;
  }
}
