.inbox-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; min-height: 20px; padding: 1px 6px; border-radius: 12px; background: #dff3ef; color: #0c6c62; font-size: 11px; font-weight: 700; }
.inbox-badge[hidden], .inbox [hidden], .inbox[hidden] { display: none !important; }
.inbox { color: #183d49; min-width: 0; }
#inboxPage { padding: 28px; }
.primary-navigation #inboxButton::after { content: none; }
.inbox *, .inbox *::before, .inbox *::after { box-sizing: border-box; }
.inbox .ib-heading { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 22px; }
.inbox h2 { margin: 0; font-size: 24px; }
.inbox p { margin: 0; }
.inbox .ib-description { margin-top: 9px; color: #657b85; font-size: 13px; line-height: 1.8; }
.inbox button, .inbox input, .inbox textarea, .inbox select { font: inherit; }
.inbox button { min-height: 44px; padding: 9px 14px; border: 1px solid #d6e1e4; border-radius: 8px; background: #fff; color: #254c59; cursor: pointer; font-size: 13px; }
.inbox button:hover { background: #f0f7f5; }
.inbox button:disabled { cursor: default; opacity: .55; }
.inbox button:focus-visible, .inbox input:focus-visible, .inbox textarea:focus-visible, .inbox select:focus-visible { outline: 3px solid #12afa14a; outline-offset: 2px; }
.inbox .ib-primary { background: #0b8178; border-color: #0b8178; color: white; }
.inbox .ib-primary:hover { background: #086c65; }
.inbox .ib-workspace { display: grid; grid-template-columns: minmax(230px, 300px) minmax(0,1fr); min-height: 600px; border: 1px solid #dce6e8; border-radius: 16px; background: white; overflow: hidden; }
.inbox .ib-list-pane { padding: 18px; border-right: 1px solid #e1e9eb; background: #fafcfb; min-width: 0; }
.inbox .ib-list-tools { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 16px; font-size: 12px; color: #647b84; }
.inbox .ib-list-tools label { display: flex; align-items: center; gap: 7px; margin: 0; font-size: 12px; }
.inbox input[type=checkbox] { width: 16px; height: 16px; min-height: 0; accent-color: #0b8178; }
.inbox .ib-thread-list { display: grid; gap: 8px; max-height: 590px; overflow-y: auto; }
.inbox .ib-thread { display: grid; width: 100%; gap: 8px; padding: 13px; text-align: left; min-width: 0; background: white; }
.inbox .ib-thread[aria-current=true] { background: #eef8f5; border-color: #78bfb2; }
.inbox .ib-thread-title { display: flex; gap: 8px; justify-content: space-between; align-items: flex-start; }
.inbox .ib-thread-title strong { min-width: 0; overflow-wrap: anywhere; font-size: 13px; line-height: 1.7; }
.inbox .ib-thread-title .inbox-badge { flex: 0 0 auto; }
.inbox .ib-preview { color: #657b85; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox .ib-meta { color: #7b8e96; font-size: 11px; line-height: 1.6; overflow-wrap: anywhere; }
.inbox .ib-pagination { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 18px; font-size: 12px; color: #657b85; }
.inbox .ib-pagination button { padding: 7px 9px; font-size: 12px; }
.inbox .ib-detail { min-width: 0; padding: 26px; }
.inbox .ib-detail-heading { border-bottom: 1px solid #e7eeee; padding-bottom: 18px; margin-bottom: 18px; }
.inbox h3 { margin: 0 0 7px; font-size: 18px; line-height: 1.7; overflow-wrap: anywhere; }
.inbox .ib-empty { padding: 70px 16px; text-align: center; color: #718791; font-size: 13px; line-height: 2; }
.inbox .ib-messages { display: grid; align-content: start; gap: 16px; max-height: 440px; overflow-y: auto; padding: 4px 6px 18px 0; overscroll-behavior: contain; }
.inbox .ib-message { max-width: 90%; padding: 12px 15px; border-radius: 12px; background: #f1f5f6; justify-self: start; min-width: 0; }
.inbox .ib-message.ib-own { justify-self: end; background: #e9f6f1; }
.inbox .ib-message-head { color: #5e7883; font-size: 11px; margin-bottom: 7px; }
.inbox .ib-message-content { white-space: pre-wrap; overflow-wrap: anywhere; color: #204450; font-size: 13px; line-height: 1.9; }
.inbox .ib-compose { display: grid; gap: 10px; }
.inbox .ib-compose label { display: block; margin: 5px 0 0; color: #496773; font-size: 13px; }
.inbox .ib-compose input, .inbox .ib-compose textarea, .inbox .ib-compose select { width: 100%; min-width: 0; border: 1px solid #cfdddf; border-radius: 9px; padding: 12px; background: white; color: #204450; font-size: 14px; }
.inbox .ib-recipient { display: grid; gap: 10px; padding-bottom: 12px; border-bottom: 1px solid #e7eeee; min-width: 0; }
.inbox .ib-recipient-search { display: flex; gap: 8px; min-width: 0; }
.inbox .ib-recipient-search input { flex: 1; }
.inbox .ib-recipient-search button { flex: 0 0 auto; }
.inbox .ib-compose input { min-height: 44px; }
.inbox .ib-compose textarea { min-height: 120px; max-height: 360px; resize: vertical; line-height: 1.8; }
.inbox .ib-compose-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.inbox .ib-status { margin: 12px 0; padding: 10px 12px; background: #f0f7f5; color: #397468; border-radius: 8px; font-size: 12px; line-height: 1.8; overflow-wrap: anywhere; }
.inbox .ib-status.ib-error { background: #fff0ef; color: #a23434; }
.inbox .ib-top-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.inbox .ib-older { margin-bottom: 14px; }
.inbox .ib-detail-nav { display: none; }
.inbox .ib-resume { width: 100%; margin-bottom: 12px; text-align: left; overflow-wrap: anywhere; }
@media(min-width:821px) { .inbox .ib-resume { display: none; } }
.inbox :is(input, textarea, select, button) { scroll-margin-block: var(--ib-focus-top, 12px) max(12px, calc(var(--platform-mobile-nav-height, 0px) + 12px - var(--ib-page-scroll-padding, 0px))); }
@media(max-width:850px) {
  .inbox .ib-workspace { grid-template-columns: minmax(190px, 240px) minmax(0,1fr); }
  .inbox .ib-detail { padding: 20px; }
}
@media(max-width:820px) {
  #inboxPage { padding: 20px 16px; }
  .inbox .ib-workspace { grid-template-columns: minmax(0,1fr); min-height: 0; border-radius: 12px; }
  .inbox .ib-list-pane { border-right: 0; border-bottom: 1px solid #e1e9eb; padding: 14px; }
  .inbox .ib-thread-list { max-height: min(60dvh, 600px); }
  .inbox .ib-detail { padding: 18px 14px; }
  .inbox .ib-empty { padding: 30px 12px; }
  .inbox .ib-message { max-width: 96%; }
  .inbox .ib-messages { max-height: clamp(100px, 32dvh, 360px); }
  .inbox[data-ib-view=list] .ib-detail, .inbox[data-ib-view=detail] .ib-list-pane { display: none; }
  .inbox .ib-detail-nav { display: grid; gap: 7px; margin-bottom: 18px; }
  .inbox .ib-detail-nav button { justify-self: start; }
  .inbox .ib-list-tools label { min-height: 44px; }
  .inbox .ib-preview { white-space: normal; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  .inbox .ib-compose :is(input, textarea, select) { font-size: 16px; }
  .inbox .ib-compose textarea { min-height: 100px; max-height: 200px; }
  .inbox .ib-compose-footer { flex-wrap: wrap; }
  .inbox .ib-recipient-search input { width: 0; }
}
