/* Inbox-specific UI extracted from the shared stylesheet. */

#inboxPage.servicePage {
  max-width: none;
  width: 100%;
}

#inboxPage .serviceHero {
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
}

.inboxBadge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 6px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  margin-left: 6px;
}

.inboxTableWrap {
  width: 100%;
  max-height: 520px;
  overflow-x: auto;
  overflow-y: auto;
}

.inboxTitleRow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 18px 10px;
}

.inboxTitleRow h1 {
  margin: 0;
}

#inboxPage .serviceContent {
  max-width: none;
  width: calc(100% - 32px);
  margin: 0 auto;
  min-width: 0;
}

.inboxLoadingPill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 2px 10px;
  border-radius: 999px;
  background: #f1ecfb;
  color: #5a2e83;
  font-weight: 900;
  font-size: 15px;
  line-height: 1;
}

.inboxTabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
  margin: 0 18px 0;
  border: 1px solid #dbe3ef;
  background: #f8fafc;
  border-radius: 6px;
  overflow: hidden;
}

.inboxTabBtn {
  border: none;
  border-radius: 0;
  background: #ffffff;
  color: #123d74;
  font-weight: 900;
  font-size: 30px;
  cursor: pointer;
  padding: 12px 10px;
  line-height: 1.05;
}

.inboxTabBtn.active {
  background: #2e3d84;
  color: #ffffff;
}

.inboxTable {
  min-width: 100%;
  table-layout: auto;
}

#inboxPage .adminTableWrap {
  width: 100%;
}

#inboxPage #inboxMessage {
  min-height: 0;
  margin: 0 18px;
  font-size: 14px;
  line-height: 1.2;
}

#inboxPage #inboxMessage:empty {
  display: none;
}

#inboxPage #inboxReceivedWrap {
  margin-top: 0;
}

#inboxPage .inboxTable th,
#inboxPage .inboxTable td {
  padding: 8px 12px;
}

#inboxPage .inboxTable th:nth-child(1),
#inboxPage .inboxTable td:nth-child(1) {
  width: 44px;
  padding-left: 8px;
  padding-right: 6px;
}

#inboxPage .inboxTable th:nth-child(2),
#inboxPage .inboxTable td:nth-child(2) {
  width: 110px;
  padding-left: 8px;
  padding-right: 8px;
  white-space: nowrap;
}

#inboxPage .inboxTable th:nth-child(3),
#inboxPage .inboxTable td:nth-child(3) {
  width: 280px;
}

#inboxPage .inboxTable th:nth-child(4),
#inboxPage .inboxTable td:nth-child(4) {
  min-width: 420px;
}

#inboxPage .sortableHeader {
  cursor: pointer;
  user-select: none;
}

#inboxPage #inboxWriteWrap {
  grid-template-columns: minmax(0, 1fr);
  margin: 0 18px 0;
  padding: 12px;
  border: 1px solid #123d74;
  border-radius: 12px;
  background: #fff;
}

#inboxPage .inboxWriteActions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 2px;
  padding-top: 0;
  border-top: none;
}

.inboxDeleteBtn {
  border: 1px solid #fecaca;
  background: #fff1f2;
  color: #b91c1c;
  border-radius: 8px;
  width: 28px;
  height: 28px;
  font-weight: 900;
  cursor: pointer;
}

.inboxRowUnread td {
  background: #fff7ed;
  font-weight: 900;
}

#inboxPage .inboxTable tbody tr:not(.inboxRowUnread) td {
  font-weight: 400;
}

#inboxPage .inboxTable td .inboxUnreadIndicator {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 10px;
  border-radius: 999px;
  background: #f97316;
  box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.18);
  vertical-align: middle;
}

@media (max-width: 900px) {
  #inboxPage .serviceContent {
    width: calc(100% - 24px);
  }

  .inboxTableWrap {
    max-height: 440px;
  }

  #inboxPage .inboxTable th:nth-child(3),
  #inboxPage .inboxTable td:nth-child(3) {
    width: 180px;
  }

  #inboxPage .inboxTable th:nth-child(4),
  #inboxPage .inboxTable td:nth-child(4) {
    min-width: 260px;
  }
}
