/* Nerdium Forever local item tooltip: readable at mobile widths.
   Scoped to the existing v4 item popup, not quest or NPC dialogs. */
.ndfe-v3-flyout {
  width: min(350px, calc(100vw - 24px));
  min-width: 0;
}
.ndfe-v3-flyout .ndwi-card,
.ndfe-v3-flyout .ndwi-paper {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
}
@media (max-width: 600px), (hover: none) and (pointer: coarse) {
  .ndfe-v3-flyout[role="dialog"] {
    position: fixed !important;
    left: 50% !important;
    top: 50% !important;
    transform: translate(-50%, -50%);
    width: min(350px, calc(100vw - 24px)) !important;
    max-height: min(78dvh, 700px) !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }
  .ndfe-v3-flyout[role="dialog"] > button {
    float: none !important;
    display: block;
    margin: 0 0 8px auto;
  }
  .ndfe-v3-flyout .ndwi-card {
    overflow-wrap: normal;
    word-break: normal;
  }
  .ndfe-v3-flyout .ndwi-paper {
    overflow-wrap: break-word;
  }
}
