
/*
 DATE48 DESKTOP V7
 Fluid desktop geometry.
 Mobile styles and application logic unchanged.
*/

@media (min-width: 1440px) {

  /* LEFT NAVIGATION — ALL DESKTOP ROUTES */

  body.d48-desktop-inner-page
  .d48-desktop-sidebar,
  body:has(.date48-real-feed)
  .d48-desktop-sidebar {
    box-sizing: border-box !important;
    position: fixed !important;
    top: 0 !important;
    bottom: 0 !important;
    left: 16px !important;
    width: 252px !important;
    height: 100vh !important;
  }

  /* HOME — FLUID THREE-COLUMN LAYOUT */

  body:has(.date48-real-feed)
  .app-shell {
    box-sizing: border-box !important;
    width: calc(100vw - 723px) !important;
    max-width: none !important;
    min-width: 0 !important;
    margin: 0 385px 0 288px !important;
    padding: 26px 0 90px !important;
  }

  body:has(.date48-real-feed)
  .screen-body {
    box-sizing: border-box !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }

  body:has(.date48-real-feed)
  .date48-real-feed {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  body:has(.date48-real-feed)
  .date48-event-v8-card {
    box-sizing: border-box !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  body:has(.date48-real-feed)
  .d48-desktop-aside {
    box-sizing: border-box !important;
    display: flex !important;
    position: fixed !important;
    top: 28px !important;
    left: auto !important;
    right: 20px !important;
    width: 344px !important;
    max-width: 344px !important;
    max-height: calc(100vh - 56px) !important;
    overflow-y: auto !important;
  }

  /* INNER ROUTES — USE REMAINING SCREEN WIDTH */

  body.d48-desktop-inner-page
  .app-shell {
    box-sizing: border-box !important;
    width: calc(100vw - 312px) !important;
    max-width: none !important;
    min-width: 0 !important;
    margin: 0 24px 0 288px !important;
    padding: 28px 20px 90px !important;
  }

  body.d48-desktop-inner-page
  .screen-body {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
  }

  /* PEOPLE */

  body[data-date48-desktop-route="people"]
  .date48-people-page--v3 {
    width: 100% !important;
    max-width: none !important;
  }

  body[data-date48-desktop-route="people"]
  .date48-people-v3__masonry {
    width: 100% !important;
    max-width: none !important;
    grid-template-columns:
      repeat(3, minmax(0, 1fr)) !important;
  }

  body[data-date48-desktop-route="people"]
  .date48-people-v3__card {
    min-width: 0 !important;
    max-width: 100% !important;
  }

  /* 48 HOURS */

  body[data-date48-desktop-route="48"]
  .d48v3-page {
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
  }

  body[data-date48-desktop-route="48"]
  .d48v3-place-rail {
    width: 100% !important;
    grid-template-columns:
      repeat(3, minmax(0, 1fr)) !important;
  }

  /* PROFILE */

  body[data-date48-desktop-route="profile"]
  .date48-account-page {
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    grid-template-columns:
      minmax(0, 1fr)
      minmax(0, 1fr) !important;
  }

  /* OPEN CHAT */

  body.d48-desktop-inner-page
  .date48-chat-page {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    margin: 0 !important;
  }

  body.d48-desktop-inner-page
  .date48-chat-thread {
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
  }

  body.d48-desktop-inner-page:has(.date48-chat-page)
  .date48-chat-composer {
    box-sizing: border-box !important;
    left: 288px !important;
    right: 24px !important;
    width: auto !important;
    max-width: none !important;
  }
}

@media (min-width: 1680px) {

  body[data-date48-desktop-route="people"]
  .date48-people-v3__masonry {
    grid-template-columns:
      repeat(4, minmax(0, 1fr)) !important;
  }

  body[data-date48-desktop-route="people"]
  .date48-people-v3__photo {
    max-height: 440px !important;
  }
}
