@media (max-width: 900px) and (pointer: coarse), (max-height: 560px) and (pointer: coarse) {
  :root {
    --ghr-edge-top: env(safe-area-inset-top, 0px);
    --ghr-edge-bottom: env(safe-area-inset-bottom, 0px);
    --ghr-edge-left: env(safe-area-inset-left, 0px);
    --ghr-edge-right: env(safe-area-inset-right, 0px);
  }

  .app {
    padding: var(--ghr-edge-top) var(--ghr-edge-right)
             var(--ghr-edge-bottom) var(--ghr-edge-left);
  }

  .app .chat .composer {
    padding-bottom: 8px;
  }

  .app .head,
  .app .head .replyAccountControl,
  .app .head .replyAccountControl select {
    min-width: 0;
  }

  .app .head .replyAccountControl select {
    max-width: 100%;
    text-overflow: ellipsis;
  }

  .app .chat .composer textarea,
  .app .chat .composer input,
  .ghrPdfTools input {
    font-size: 16px;
  }

  .overlay,
  .xcoreSettingsOverlay,
  .ac-overlay,
  .cv3-overlay {
    padding-top: max(8px, var(--ghr-edge-top));
    padding-right: max(8px, var(--ghr-edge-right));
    padding-bottom: max(8px, var(--ghr-edge-bottom));
    padding-left: max(8px, var(--ghr-edge-left));
  }

  .ghrPdfReader {
    box-sizing: border-box;
    width: 100vw;
    height: min(100dvh, var(--xcore-visible-height, 100dvh));
    border-radius: 0;
    padding: var(--ghr-edge-top) var(--ghr-edge-right)
             var(--ghr-edge-bottom) var(--ghr-edge-left);
  }

  .ghrPdfReader header,
  .ghrPdfTools {
    padding: 6px 8px;
    gap: 5px;
  }

  .ghrPdfReader header strong {
    flex-basis: 100%;
  }

  .ghrPdfTools form {
    margin-left: 0;
  }
}
