.mail-workspace {
  grid-template-columns: 245px minmax(0, 1fr);
  align-items: start;
  gap: 20px;
}
.mail-workspace .mail-folders {
  position: sticky;
  top: 18px;
}
.mail-write {
  padding: 0 14px 18px;
  gap: 6px;
}
.mail-write button {
  flex: 1;
  padding: 10px 7px;
  font-size: 13px;
}
.mail-quick {
  display: flex;
  justify-content: space-around;
  padding: 4px 10px 17px;
  border-bottom: 1px solid var(--line, #e4e9f0);
}
.mail-quick button {
  border: 0;
  background: transparent;
  font-size: 12px;
}
.mail-quick button.active {
  color: #007eae;
  background: #e4f5fc;
}
.mail-folder-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.mail-folder-tools button {
  font-size: 11px;
  padding: 7px;
}
.mail-workspace .folder {
  padding: 12px 16px;
}
.mail-workspace .folder small {
  white-space: nowrap;
}
.mail-workspace .folder b {
  color: #007fae;
}
.mail-main {
  min-width: 0;
  overflow: hidden;
}
.mail-main h2 {
  font-size: 20px;
  margin: 0 0 8px;
}
.mail-main .toolbar {
  padding: 22px 24px;
  gap: 12px;
  flex-wrap: wrap;
}
.mail-sync-line {
  padding: 0 24px 18px;
  color: #65808f;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}
.mail-tools {
  padding: 12px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-block: 1px solid #e8edf3;
  background: #f9fbfd;
  flex-wrap: wrap;
}
.mail-tools .row {
  gap: 6px;
  flex-wrap: wrap;
}
.mail-tools button {
  font-size: 12px;
  padding: 7px 9px;
}
.mail-tools .check {
  font-size: 12px;
}
.mail-sort {
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.mail-sort select {
  max-width: 115px;
  padding: 7px;
}
.mail-workspace table {
  font-size: 13px;
  min-width: 680px;
}
.mail-workspace th,
.mail-workspace td {
  padding: 15px 12px;
}
.mail-workspace .mail-person {
  max-width: 190px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mail-workspace .title-cell {
  min-width: 220px;
  max-width: 490px;
}
.mail-workspace .mail-subject {
  text-align: left;
  line-height: 1.55;
  overflow-wrap: anywhere;
}
.mail-workspace .mail-row.unread {
  background: #f3faff;
}
.mail-workspace .mail-row.unread .mail-subject {
  font-weight: 700;
  color: #073e64;
}
.mail-workspace .mail-row input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #008bc2;
}
.mail-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
  padding: 20px;
  font-size: 12px;
}
.mail-pagination button {
  font-size: 12px;
}
.mail-help,
.mail-pending {
  padding: 14px 24px;
  margin: 0;
  background: #f2f8fc;
  font-size: 12px;
  line-height: 1.7;
}
.mail-pending > div + div {
  margin-top: 6px;
}
.mail-message-tools {
  border-top: 1px solid #e5eaf0;
  padding-top: 18px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.mail-message-tools button {
  font-size: 12px;
}
.mail-compose textarea {
  min-height: 260px;
  max-height: 48vh;
}
.mail-compose .form-grid {
  gap: 16px;
}
.mail-compose .full {
  grid-column: 1/-1;
}
.mail-compose .compose-attachment-note {
  font-size: 12px;
  color: #5d7285;
  background: #f3f7fb;
  padding: 12px;
  border-radius: 8px;
}
.mail-compose input[type="text"] {
  min-width: 0;
}
.mail-workspace .mail-address select {
  width: 100%;
  font-size: 13px;
}
.mail-stream-error {
  color: #a44913;
}
[data-mail-intent="draft"] {
  background: #fff !important;
  color: #155574 !important;
  border: 1px solid #bfd2de !important;
}
@media (max-width: 1180px) {
  .mail-workspace {
    grid-template-columns: 205px minmax(0, 1fr);
    gap: 12px;
  }
  .mail-workspace .mail-person {
    max-width: 150px;
  }
  .mail-main .toolbar {
    padding: 18px;
  }
}
@media (max-width: 850px) {
  .mail-workspace {
    grid-template-columns: 1fr;
  }
  .mail-workspace .mail-folders {
    position: static;
  }
  .mail-workspace .folder-list {
    display: flex;
    overflow-x: auto;
  }
  .mail-workspace .folder {
    min-width: 135px;
  }
  .mail-write {
    max-width: 370px;
  }
  .mail-quick {
    justify-content: flex-start;
    gap: 25px;
  }
  .mail-folder-tools {
    display: none;
  }
  .mail-workspace .mail-address {
    max-width: 420px;
  }
  .mail-tools {
    padding: 10px;
  }
  .mail-sort {
    margin-left: auto;
  }
}
#dialog:has(.mail-compose) {
  width: min(1080px, calc(100vw - 40px));
  max-width: 1080px;
}
.mail-compose textarea[name="body"] {
  min-height: 140px;
  height: 160px;
}
.mail-compose .field:has(input[name="subject"]) {
  grid-column: 1 / -1;
}
.mail-upload-panel {
  border: 1px solid #cddfea;
  border-radius: 12px;
  padding: 18px;
  margin: 12px 0;
  background: #f7fbfe;
}
.mail-upload-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.mail-upload-heading h3 {
  margin: 0;
}
.mail-upload-heading > span,
.mail-upload-zone > span,
.mail-expiry > span {
  color: #5c7081;
  font-size: 12px;
}
.mail-upload-zones {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.mail-upload-zone {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 16px;
  border: 1px dashed #8bb8d1;
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  min-width: 0;
}
.mail-upload-zone.large {
  background: #f0f8ff;
}
.mail-upload-zone.dragging {
  outline: 3px solid #079bcf;
  background: #e3f5fc;
}
.mail-upload-zone input {
  max-width: 100%;
  font-size: 12px;
}
.mail-upload-zone input::file-selector-button {
  border: 1px solid #a9bfd0;
  border-radius: 6px;
  background: white;
  color: #005d86;
  padding: 7px 10px;
  cursor: pointer;
  margin-right: 8px;
}
.mail-expiry {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0 8px;
  flex-wrap: wrap;
}
.mail-expiry select {
  width: 90px;
}
.mail-upload-item {
  border-top: 1px solid #dce7ee;
  padding: 10px 0;
}
.mail-upload-item > div {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.mail-upload-item strong {
  font-size: 13px;
  overflow-wrap: anywhere;
}
.mail-upload-item span {
  font-size: 12px;
}
.mail-upload-kind {
  color: #006c92;
  background: #e0f1f9;
  padding: 3px 6px;
  border-radius: 4px;
}
.mail-upload-progress {
  margin-top: 8px;
}
.mail-upload-progress progress {
  width: 120px;
  height: 8px;
  accent-color: #008bbd;
}
.mail-upload-progress > span {
  flex: 1;
  min-width: 100px;
  overflow-wrap: anywhere;
}
.mail-body a {
  color: #006a9c;
  text-decoration: underline;
  overflow-wrap: anywhere;
}
@media (max-width: 700px) {
  .mail-upload-zones {
    grid-template-columns: 1fr;
  }
  .mail-upload-heading {
    align-items: flex-start;
    flex-direction: column;
  }
}
@media print {
  body.printing-mail #root,
  body.printing-mail #toast,
  body.printing-mail dialog::backdrop {
    display: none !important;
  }
  body.printing-mail dialog {
    position: static !important;
    display: block !important;
    max-width: none !important;
    width: 100% !important;
    max-height: none !important;
    overflow: visible !important;
    border: 0 !important;
    box-shadow: none !important;
  }
  body.printing-mail .dialog-head button,
  body.printing-mail .message-actions,
  body.printing-mail .mail-message-tools {
    display: none !important;
  }
  body.printing-mail .dialog-content {
    max-height: none;
    overflow: visible;
  }
  body.printing-mail .mail-body {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    color: #000;
    background: #fff;
  }
}
