* {
  box-sizing:border-box
}
html {
  font-family:Inter,system-ui,-apple-system,"Segoe UI",sans-serif;
  color:#e8edf5;
  background:#07111f
}
body {
  margin:0;
  min-height:100vh;
  background:radial-gradient(ellipse at 20% 0%,rgba(34,91,152,.18),transparent 38%),#07111f;
  color:#e8edf5
}
a {
  color:inherit;
  text-decoration:none
}
button,input,select {
  font:inherit
}
.brand {
  display:inline-flex;
  align-items:center;
  gap:.75rem
}
.brand-logo {
  display:block;
  width:auto;
  height:40px;
  max-width:min(230px,60vw);
  object-fit:contain
}
.brand-label {
  padding-left:.85rem;
  border-left:1px solid rgba(255,255,255,.15);
  color:#92a4bd;
  font-size:.76rem;
  white-space:nowrap
}
.login-page {
  display:grid;
  place-items:center;
  padding:2rem
}
.login-shell {
  width:min(100%,430px)
}
.login-shell>.brand {
  flex-direction:column;
  align-items:flex-start;
  gap:.6rem;
  margin-bottom:2rem
}
.login-shell .brand-logo {
  height:50px;
  max-width:min(270px,70vw)
}
.login-shell .brand-label {
  padding-left:0;
  border-left:0
}
.login-card,.panel {
  background:rgba(15,28,47,.94);
  border:1px solid rgba(255,255,255,.09);
  border-radius:18px;
  box-shadow:0 20px 70px rgba(0,0,0,.24)
}
.login-card {
  padding:2.25rem
}
.eyebrow {
  margin:0 0 .55rem;
  color:#38bdf8;
  font-size:.69rem;
  font-weight:800;
  letter-spacing:.15em
}
.login-card h1,.page-heading h1 {
  margin:0;
  font-size:clamp(1.8rem,4vw,2.35rem);
  letter-spacing:-.04em
}
.muted {
  color:#93a4bc;
  line-height:1.6
}
.login-form {
  display:grid;
  gap:.7rem;
  margin-top:1.7rem
}
.login-form label {
  margin-top:.45rem;
  font-size:.83rem;
  font-weight:650
}
.login-form input,.search-box input,.filters select {
  min-width:0;
  width:100%;
  padding:.82rem .9rem;
  color:#e8edf5;
  background:#0b1728;
  border:1px solid rgba(255,255,255,.13);
  border-radius:9px;
  outline:none
}
.login-form input:focus,.search-box input:focus,.filters select:focus {
  border-color:#38bdf8;
  box-shadow:0 0 0 3px rgba(56,189,248,.12)
}
.button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.45rem;
  min-height:40px;
  padding:.6rem .9rem;
  border:1px solid transparent;
  border-radius:8px;
  background:transparent;
  color:#e8edf5;
  font-weight:650;
  cursor:pointer;
  transition:background .18s,border-color .18s
}
.button.primary {
  background:linear-gradient(135deg,#2563eb,#0891b2);
  color:white
}
.button.primary:hover {
  filter:brightness(1.12)
}
.button.outline {
  border-color:rgba(255,255,255,.14);
  background:rgba(255,255,255,.025)
}
.button.outline:hover {
  border-color:rgba(56,189,248,.5);
  background:rgba(56,189,248,.08)
}
.button.full {
  width:100%;
  margin-top:1rem;
  min-height:46px
}
.notice {
  margin-top:1rem;
  padding:.8rem 1rem;
  border-radius:9px;
  font-size:.88rem
}
.notice.error {
  color:#fecaca;
  background:rgba(220,38,38,.12);
  border:1px solid rgba(248,113,113,.24)
}
.login-foot {
  margin:1.2rem 0 0;
  text-align:center;
  color:#64748b;
  font-size:.77rem
}
.app-header {
  position:sticky;
  top:0;
  z-index:5;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  padding:.8rem clamp(1rem,4vw,3.5rem);
  background:rgba(6,13,24,.92);
  border-bottom:1px solid rgba(255,255,255,.08);
  backdrop-filter:blur(16px)
}
.header-right {
  display:flex;
  align-items:center;
  gap:1rem
}
.header-right form {
  margin:0
}
.admin-label {
  color:#93a4bc;
  font-size:.82rem
}
.admin-label strong {
  color:#e8edf5
}
.dashboard-main {
  width:min(100% - 2rem,1500px);
  margin:2.4rem auto 5rem
}
.page-heading {
  display:flex;
  justify-content:space-between;
  align-items:end;
  gap:1rem;
  margin-bottom:1.5rem
}
.page-heading .muted {
  margin:.45rem 0 0
}
.summary-chip {
  display:flex;
  align-items:baseline;
  gap:.5rem;
  padding:.65rem .9rem;
  border:1px solid rgba(255,255,255,.1);
  border-radius:9px;
  background:#101c2e
}
.summary-chip span {
  font-size:1.25rem;
  font-weight:800;
  color:#67e8f9
}
.summary-chip small {
  color:#93a4bc
}
.panel {
  overflow:hidden
}
.toolbar {
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:1rem;
  padding:1rem 1.15rem;
  border-bottom:1px solid rgba(255,255,255,.08)
}
.filters,.export-actions {
  display:flex;
  align-items:center;
  gap:.55rem
}
.search-box {
  width:min(42vw,390px)
}
.filters select {
  width:auto;
  min-width:142px
}
.table-wrap {
  overflow:auto
}
.message-table {
  width:100%;
  border-collapse:collapse;
  min-width:1050px
}
.message-table th,.message-table td {
  padding:.85rem .9rem;
  text-align:left;
  border-bottom:1px solid rgba(255,255,255,.065);
  font-size:.82rem;
  white-space:nowrap
}
.message-table th {
  color:#8fa3bf;
  background:#0b1728;
  font-size:.72rem;
  text-transform:uppercase;
  letter-spacing:.07em
}
.message-table tbody tr {
  cursor:pointer;
  transition:background .15s
}
.message-table tbody tr:hover {
  background:rgba(56,189,248,.055)
}
.message-table tbody tr.unread-row {
  background:rgba(37,99,235,.07)
}
.message-table td:nth-child(7) {
  max-width:250px;
  overflow:hidden;
  text-overflow:ellipsis
}
.message-table td:nth-child(4) {
  max-width:220px;
  overflow:hidden;
  text-overflow:ellipsis
}
.status-badge {
  display:inline-flex;
  align-items:center;
  gap:.4rem;
  padding:.25rem .55rem;
  border-radius:99px;
  font-size:.72rem;
  font-weight:700;
  text-transform:capitalize
}
.status-badge.unread {
  color:#bae6fd;
  background:rgba(14,165,233,.15)
}
.status-badge.read {
  color:#cbd5e1;
  background:rgba(148,163,184,.13)
}
.action-button,.icon-button {
  display:inline-grid;
  place-items:center;
  width:34px;
  height:34px;
  border:1px solid rgba(255,255,255,.1);
  border-radius:8px;
  background:transparent;
  color:#a5f3fc;
  cursor:pointer
}
.action-button:hover,.icon-button:hover {
  background:rgba(56,189,248,.12)
}
.action-button svg {
  width:17px;
  height:17px
}
.table-empty {
  text-align:center!important;
  color:#93a4bc!important;
  padding:2rem!important
}
.table-help {
  margin:0;
  padding:.85rem 1rem;
  color:#73849c;
  font-size:.76rem;
  border-top:1px solid rgba(255,255,255,.06)
}
.table-notice {
  display:none;
  padding:.75rem 1rem;
  color:#fecaca;
  background:rgba(220,38,38,.12);
  font-size:.85rem
}
.table-notice.visible {
  display:block
}
.message-dialog {
  width:min(900px,calc(100vw - 2rem));
  max-width:900px;
  max-height:min(88vh,850px);
  padding:0;
  color:#e8edf5;
  background:#101c2e;
  border:1px solid rgba(255,255,255,.12);
  border-radius:16px;
  box-shadow:0 30px 100px rgba(0,0,0,.6)
}
.message-dialog::backdrop {
  background:rgba(0,0,0,.72);
  backdrop-filter:blur(4px)
}
.dialog-header {
  display:flex;
  justify-content:space-between;
  align-items:start;
  padding:1.4rem 1.6rem;
  border-bottom:1px solid rgba(255,255,255,.08)
}
.dialog-header h2 {
  margin:0;
  font-size:1.45rem
}
.icon-button {
  font-size:1.45rem;
  color:#cbd5e1
}
.dialog-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:1rem;
  padding:1.5rem 1.6rem
}
.detail-field {
  min-width:0;
  padding:.9rem 1rem;
  background:#0b1728;
  border:1px solid rgba(255,255,255,.06);
  border-radius:9px
}
.detail-field span {
  display:block;
  margin-bottom:.35rem;
  color:#8fa3bf;
  font-size:.7rem;
  font-weight:700;
  letter-spacing:.08em;
  text-transform:uppercase
}
.detail-field strong {
  overflow-wrap:anywhere;
  font-size:.92rem
}
.detail-field.full-width {
  grid-column:1/-1
}
.detail-field p {
  margin:0;
  min-height:6rem;
  color:#d4deeb;
  line-height:1.7;
  white-space:pre-wrap;
  overflow-wrap:anywhere
}
.dialog-footer {
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:.7rem;
  padding:1rem 1.6rem;
  border-top:1px solid rgba(255,255,255,.08)
}
.dialog-footer .status-badge {
  margin-right:auto
}
.sr-only {
  position:absolute;
  width:1px;
  height:1px;
  padding:0;
  margin:-1px;
  overflow:hidden;
  clip:rect(0,0,0,0);
  white-space:nowrap;
  border:0
}
.print-heading {
  display:none
}
@media(max-width:900px) {
  .toolbar {
  align-items:stretch;
  flex-direction:column
}
.filters {
  width:100%
}
.search-box {
  width:auto;
  flex:1
}
.export-actions {
  justify-content:flex-end
}
.admin-label {
  display:none
}

}
@media(max-width:600px) {
  .app-header {
  padding:.7rem 1rem
}
  .app-header .brand-label {
    display:none
}
.dashboard-main {
  margin-top:1.5rem
}
.page-heading {
  align-items:start
}
.summary-chip {
  flex-direction:column;
  gap:0
}
.filters {
  flex-direction:column;
  align-items:stretch
}
.filters select {
  width:100%
}
.export-actions {
  display:grid;
  grid-template-columns:repeat(3,1fr)
}
.dialog-grid {
  grid-template-columns:1fr;
  padding:1rem
}
.detail-field.full-width {
  grid-column:auto
}
.dialog-header,.dialog-footer {
  padding:1rem
}
.dialog-footer {
  flex-wrap:wrap
}
.dialog-footer .status-badge {
  width:100%;
  margin:0
}
.login-card {
  padding:1.5rem
}

}
@media print {
  html,body {
  background:#fff!important;
  color:#111!important
}
.app-header,.toolbar,.table-help,.dialog-footer,.table-notice {
  display:none!important
}
.dashboard-main {
  width:100%;
  margin:0
}
.page-heading {
  margin:0 0 1rem
}
.page-heading .eyebrow,.page-heading .muted,.summary-chip {
  display:none
}
.page-heading h1 {
  font-size:1.4rem;
  color:#111
}
.panel {
  background:#fff;
  border:0;
  box-shadow:none
}
.message-table {
  min-width:0
}
.message-table th,.message-table td {
  padding:.35rem .4rem;
  color:#111;
  border:1px solid #bbb;
  font-size:8pt;
  white-space:normal
}
.message-table th {
  background:#eee
}
.message-table tbody tr {
  background:#fff!important
}
.message-table td:nth-child(4),.message-table td:nth-child(7) {
  max-width:none
}
.message-table th:last-child,.message-table td:last-child {
  display:none
}
.status-badge {
  background:none!important;
  color:#111!important
}
.print-heading {
  display:flex;
  justify-content:space-between;
  margin-bottom:.75rem;
  color:#111
}

}

