:root {
  font-family:
    Inter,
    ui-sans-serif,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: #233c36;
  background: #f6f8f7;
  font-size: 16px;
  font-synthesis: none;
  --forest: #14372f;
  --ink: #233c36;
  --muted: #6e7f79;
  --line: #dfe7e2;
  --lime: #def58b;
  --white: #fff;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
textarea,
select {
  font: inherit;
}
button,
a,
input,
textarea,
select {
  outline-offset: 4px;
}
button {
  cursor: pointer;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
button {
  border: 0;
  background: none;
  color: inherit;
}
a {
  color: #286c53;
}
svg {
  width: 20px;
  height: 20px;
  vertical-align: middle;
  flex-shrink: 0;
}
button svg {
  pointer-events: none;
}
.layout {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  min-height: 100vh;
}
.sidebar {
  background: var(--forest);
  color: #dce8e2;
  padding: 34px 22px;
  display: flex;
  flex-direction: column;
  gap: 35px;
  position: sticky;
  top: 0;
  height: 100vh;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 4px;
}
.brand img {
  width: 36px;
  height: 36px;
}
.brand strong {
  display: block;
  font-size: 16px;
  letter-spacing: -0.4px;
}
.brand small {
  display: block;
  font-size: 12px;
  color: #a2b9af;
  margin-top: 5px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
}
.compose {
  padding: 15px 18px;
  border-radius: 9px;
  background: var(--lime);
  color: #173e2c;
  font-weight: 650;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.nav-label {
  font-size: 12px;
  color: #97afa4;
  letter-spacing: 1.5px;
  padding: 0 14px;
  margin-bottom: 12px;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  padding: 13px 14px;
  border-radius: 7px;
  font-size: 14px;
  margin-bottom: 5px;
}
.nav-item:hover {
  background: #ffffff0b;
}
.nav-item.active {
  background: #ffffff12;
  color: #edffc5;
}
.count {
  margin-left: auto;
  font-size: 12px;
  background: #dff58b;
  color: #14372f;
  border-radius: 5px;
  min-width: 23px;
  text-align: center;
  padding: 3px;
}
.sidebar-foot {
  margin-top: auto;
  border-top: 1px solid #ffffff20;
  padding-top: 22px;
}
.sidebar-foot p {
  font-size: 13px;
  color: #adc1b8;
  line-height: 1.6;
  margin: 10px 0;
}
.profile {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
}
.avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #eaf0ed;
  color: #35694f;
  font-size: 13px;
  font-weight: 650;
}
.profile .avatar {
  background: #38574d;
  color: #edffc5;
}
.main {
  min-width: 0;
}
.topbar {
  height: 86px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  padding: 0 40px;
  gap: 16px;
  background: #fff;
}
.breadcrumb {
  font-size: 14px;
  color: var(--muted);
}
.breadcrumb strong {
  font-weight: 500;
  color: var(--ink);
}
.top-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 20px;
}
.text-btn {
  font-size: 14px;
  color: var(--muted);
}
.pill {
  font-size: 12px;
  font-weight: 600;
  border-radius: 5px;
  background: #eef4ed;
  color: #40614a;
  padding: 6px 9px;
  white-space: nowrap;
}
.pill.amber {
  background: #fff3dc;
  color: #866026;
}
.pill.gray {
  background: #edf0ef;
  color: #5e6a65;
}
.content {
  padding: 38px 40px;
  max-width: 1600px;
  margin: auto;
}
.page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 20px;
}
.eyebrow {
  font-size: 12px;
  letter-spacing: 1.7px;
  text-transform: uppercase;
  color: #72887b;
  margin: 0 0 10px;
}
h1 {
  font-size: 32px;
  letter-spacing: -1.2px;
  font-weight: 550;
  margin: 0 0 9px;
}
p {
  line-height: 1.6;
}
.sub {
  color: var(--muted);
  font-size: 14px;
  margin: 0;
}
.quiet-stat {
  text-align: right;
  font-size: 14px;
  color: var(--muted);
}
.quiet-stat b {
  font-size: 28px;
  font-weight: 500;
  color: var(--forest);
  display: block;
}
.demo-banner {
  display: flex;
  align-items: center;
  gap: 11px;
  background: #eef4e4;
  border: 1px solid #dde9c5;
  border-radius: 8px;
  padding: 12px 16px;
  margin-bottom: 24px;
  font-size: 13px;
  color: #526341;
}
.workspace {
  display: grid;
  grid-template-columns: minmax(270px, 365px) minmax(0, 1fr);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  min-height: 630px;
  overflow: hidden;
}
.mail-list {
  border-right: 1px solid var(--line);
  min-width: 0;
}
.list-toolbar {
  padding: 20px 20px 0;
}
.search {
  display: flex;
  align-items: center;
  gap: 9px;
  background: #f5f7f6;
  border: 1px solid #e7ede9;
  border-radius: 7px;
  padding: 10px 12px;
  color: var(--muted);
}
.search input {
  background: transparent;
  border: 0;
  min-width: 0;
  width: 100%;
  font-size: 14px;
  color: var(--ink);
  outline-offset: 8px;
}
.filter-tabs {
  display: flex;
  gap: 18px;
  margin-top: 15px;
  border-bottom: 1px solid var(--line);
}
.filter-tabs button {
  font-size: 13px;
  padding: 11px 0;
  color: var(--muted);
  border-bottom: 2px solid transparent;
}
.filter-tabs .active {
  color: var(--forest);
  border-color: var(--forest);
  font-weight: 600;
}
.message-row {
  display: block;
  width: 100%;
  text-align: left;
  padding: 21px;
  border-bottom: 1px solid #e8edea;
  position: relative;
}
.message-row:hover {
  background: #f9fbf9;
}
.message-row.selected {
  background: #f0f5ec;
  border-left: 3px solid #65894f;
  padding-left: 18px;
}
.row-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  align-items: center;
  margin-bottom: 12px;
}
.row-top time {
  color: #7b8b82;
  font-size: 12px;
  white-space: nowrap;
}
.row-title {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.45;
  margin-bottom: 7px;
}
.row-preview {
  font-size: 13px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-bottom: 12px;
}
.row-meta {
  font-size: 12px;
  color: #7b8b82;
  display: flex;
  align-items: center;
  gap: 8px;
}
.unread-dot {
  height: 7px;
  width: 7px;
  background: #7d9b46;
  border-radius: 50%;
  display: inline-block;
  margin-right: 6px;
}
.detail {
  padding: 30px 34px;
  min-width: 0;
}
.detail-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 24px;
}
.security-caption {
  font-size: 12px;
  color: #68805e;
  display: flex;
  align-items: center;
  gap: 7px;
}
.detail h2 {
  font-size: 25px;
  font-weight: 550;
  letter-spacing: -0.6px;
  margin: 0 0 22px;
  line-height: 1.3;
}
.sender-line {
  display: flex;
  gap: 12px;
  align-items: center;
}
.sender-info {
  font-size: 14px;
  min-width: 0;
}
.sender-info strong {
  font-weight: 600;
}
.sender-info small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 5px;
  overflow-wrap: anywhere;
}
.sender-time {
  margin-left: auto;
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}
.message-body {
  white-space: pre-wrap;
  font-size: 16px;
  line-height: 1.8;
  color: #40514a;
  margin: 26px 0;
}
.attachment {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  font-size: 14px;
  margin: 12px 0;
  max-width: 400px;
}
.attachment small {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-top: 5px;
}
.file-icon {
  background: #f0f4ee;
  border-radius: 6px;
  padding: 10px;
  color: #67834e;
}
.attachment button {
  margin-left: auto;
}
.expiry-note {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12px;
  color: var(--muted);
  padding: 15px 0 25px;
  border-bottom: 1px solid var(--line);
}
.reply-box {
  margin-top: 25px;
}
.reply-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  margin-bottom: 11px;
}
.reply-box textarea {
  resize: vertical;
  min-height: 94px;
  width: 100%;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
}
.reply-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  gap: 12px;
}
.micro {
  font-size: 12px;
  color: var(--muted);
}
.primary {
  background: var(--forest);
  color: #fff;
  border-radius: 7px;
  padding: 12px 18px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 14px;
  font-weight: 550;
}
.secondary {
  border: 1px solid var(--line);
  background: white;
  border-radius: 7px;
  padding: 11px 15px;
  font-size: 14px;
}
.danger {
  color: #a24336;
}
.footer-note {
  font-size: 12px;
  color: #819087;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 20px;
  gap: 20px;
}
.empty {
  text-align: center;
  padding: 70px 20px;
  color: var(--muted);
  font-size: 14px;
}
.empty svg {
  width: 36px;
  height: 36px;
  margin-bottom: 14px;
}
.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 28px;
}
.settings-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.setting {
  border-bottom: 1px solid var(--line);
  padding: 18px 0;
  display: flex;
  gap: 20px;
  justify-content: space-between;
  align-items: start;
}
.setting p {
  font-size: 14px;
  margin: 5px 0 0;
  color: var(--muted);
}
.setting strong {
  font-size: 15px;
  font-weight: 550;
}
.audit-item {
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 14px;
}
.audit-item p {
  margin: 0;
  font-size: 14px;
}
.audit-item small {
  color: var(--muted);
  font-size: 12px;
}
.login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 25px;
  background: #14372f;
}
.login-card {
  padding: 45px;
  background: #fff;
  max-width: 460px;
  border-radius: 16px;
}
.login-card img {
  width: 48px;
}
.login-card h1 {
  margin-top: 25px;
}
.login-card p {
  color: var(--muted);
  font-size: 15px;
}
.login-card .primary {
  margin-top: 20px;
  text-decoration: none;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0;
  max-width: 680px;
  width: calc(100% - 30px);
  max-height: 92vh;
  color: var(--ink);
  box-shadow: 0 24px 90px #10281c33;
}
dialog::backdrop {
  background: #10282077;
  backdrop-filter: blur(3px);
}
.modal-head {
  padding: 24px 28px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-head h2 {
  margin: 0;
  font-weight: 550;
  font-size: 23px;
}
.modal-body {
  padding: 25px 28px;
}
.form-field {
  display: block;
  margin-bottom: 20px;
  font-size: 14px;
  font-weight: 550;
}
.form-field input,
.form-field textarea,
.form-field select {
  display: block;
  width: 100%;
  margin-top: 9px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  color: var(--ink);
  font-size: 14px;
}
.form-field textarea {
  min-height: 160px;
  resize: vertical;
}
.form-field small {
  display: block;
  font-size: 12px;
  font-weight: 400;
  color: var(--muted);
  margin-top: 8px;
  line-height: 1.5;
}
.modal-foot {
  padding: 20px 28px;
  background: #f7f9f7;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.file-picker {
  border: 1px dashed #bdcbbc;
  padding: 14px;
  border-radius: 7px;
  font-size: 13px;
}
.file-picker input {
  font-size: 13px;
  max-width: 100%;
}
.error {
  color: #a24336;
  font-size: 14px;
}
.boot {
  padding: 100px;
  text-align: center;
}
#toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: #183d31;
  color: white;
  border-radius: 9px;
  padding: 15px 22px;
  box-shadow: 0 5px 30px #12332722;
  z-index: 10;
  font-size: 14px;
  display: none;
  max-width: 90vw;
}
.mobile-brand {
  display: none;
}
.thread-entry + .thread-entry {
  border-top: 1px solid var(--line);
  padding-top: 25px;
}
.detail-scroll {
  max-height: 480px;
  overflow-y: auto;
}
.read-meta {
  font-size: 12px;
  color: #6f8269;
  margin-bottom: 15px;
}
.safety {
  font-size: 13px;
  border-left: 3px solid #b5cd85;
  padding: 9px 14px;
  background: #f5f8f0;
  line-height: 1.6;
}
.attachment-list {
  font-size: 12px;
  color: var(--muted);
}
@media (min-width: 1550px) {
  .content {
    padding-top: 48px;
  }
  .workspace {
    min-height: 710px;
  }
  .detail {
    padding: 36px 45px;
  }
}
@media (max-width: 1120px) {
  .layout {
    grid-template-columns: 210px minmax(0, 1fr);
  }
  .sidebar {
    padding: 28px 15px;
  }
  .content {
    padding: 28px 24px;
  }
  .topbar {
    padding: 0 24px;
  }
  .workspace {
    grid-template-columns: 280px minmax(0, 1fr);
  }
  .detail {
    padding: 24px 22px;
  }
  .sender-time {
    display: none;
  }
}
@media (max-width: 850px) {
  .layout {
    grid-template-columns: minmax(0, 1fr);
  }
  .sidebar {
    height: auto;
    position: relative;
    padding: 18px 20px;
    display: flex;
    flex-direction: row;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
  }
  .brand {
    margin-right: auto;
  }
  .sidebar .compose {
    padding: 11px 14px;
  }
  .sidebar nav {
    display: flex;
    order: 3;
    width: 100%;
    overflow: auto;
  }
  .nav-label,
  .sidebar-foot,
  .sidebar .profile {
    display: none;
  }
  .nav-item {
    width: auto;
    white-space: nowrap;
    margin: 0;
    font-size: 13px;
  }
  .topbar {
    height: 60px;
  }
  .workspace {
    grid-template-columns: 280px minmax(0, 1fr);
  }
  .content {
    padding: 26px 20px;
  }
  .settings-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 650px) {
  .workspace {
    grid-template-columns: minmax(0, 1fr);
  }
  .mail-list {
    border-right: 0;
  }
  .workspace.has-selection .mail-list {
    display: none;
  }
  .workspace:not(.has-selection) .detail {
    display: none;
  }
  .detail {
    padding: 24px 20px;
  }
  .page-head {
    align-items: start;
  }
  h1 {
    font-size: 27px;
  }
  .quiet-stat {
    display: none;
  }
  .top-actions .pill {
    display: none;
  }
  .demo-banner {
    align-items: start;
    line-height: 1.5;
  }
  .content {
    padding: 23px 14px;
  }
  .footer-note {
    display: block;
    line-height: 1.8;
  }
  .modal-body,
  .modal-head,
  .modal-foot {
    padding: 20px;
  }
  .reply-actions {
    flex-wrap: wrap;
  }
  .breadcrumb {
    font-size: 12px;
  }
  .topbar {
    padding: 0 20px;
  }
}
@media (min-width: 651px) {
  .back-button {
    display: none;
  }
}
@media (prefers-reduced-motion: no-preference) {
  dialog[open] {
    animation: appear 0.16s ease-out;
  }
  @keyframes appear {
    from {
      opacity: 0;
      transform: translateY(8px);
    }
  }
}

.sidebar {
  min-width: 0;
}

.sidebar nav {
  scrollbar-width: thin;
  scrollbar-color: #6e8875 #14372f;
}
