:root { color-scheme: light; --ink: #172033; --muted: #637083; --line: #dfe4eb; --accent: #155eef; --paper: #fff; --wash: #f5f7fa; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--wash); color: var(--ink); font: 15px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif; }
a { color: var(--accent); }
.topbar { min-height: 64px; padding: 0 24px; background: var(--paper); border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { color: var(--ink); font-size: 20px; font-weight: 750; text-decoration: none; }
.account { display: flex; align-items: center; gap: 14px; color: var(--muted); }
.account form { margin: 0; }
.shell { width: min(100% - 32px, 980px); margin: 40px auto; }
h1, h2 { line-height: 1.2; }
h1 { margin: 0 0 8px; font-size: clamp(25px, 4vw, 34px); }
.muted { color: var(--muted); margin: 0; }
.login-card, .mail-card, .empty { background: var(--paper); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 8px 28px rgb(32 46 66 / 7%); }
.login-card { width: min(100%, 430px); margin: 9vh auto 0; padding: 32px; }
.stack { display: grid; gap: 18px; margin-top: 26px; }
label { display: grid; gap: 7px; font-weight: 650; }
input { width: 100%; padding: 11px 12px; border: 1px solid #b9c2cf; border-radius: 8px; background: #fff; color: var(--ink); font: inherit; }
input:focus { outline: 3px solid rgb(21 94 239 / 18%); border-color: var(--accent); }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 9px 16px; border: 1px solid var(--accent); border-radius: 8px; background: var(--accent); color: white; cursor: pointer; font: inherit; font-weight: 700; text-decoration: none; }
.button-small { min-height: 34px; padding: 6px 11px; font-size: 13px; }
.error { padding: 10px 12px; border-radius: 8px; background: #fff0f0; color: #9d1722; }
.heading-row { margin-bottom: 22px; }
.message-list { overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.message-row { display: grid; grid-template-columns: minmax(150px, 1fr) minmax(260px, 2fr) auto; gap: 18px; padding: 15px 18px; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.message-row:last-child { border-bottom: 0; }
.message-row:hover { background: #f8faff; }
.message-row.unread { background: #f1f6ff; font-weight: 700; }
.message-row span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.message-row time { color: var(--muted); font-size: 13px; white-space: nowrap; }
.pagination { margin-top: 18px; display: flex; align-items: center; justify-content: center; gap: 15px; color: var(--muted); }
.empty { padding: 70px 30px; text-align: center; }
.back { display: inline-block; margin-bottom: 18px; text-decoration: none; }
.mail-card { padding: clamp(22px, 4vw, 40px); }
.metadata { display: grid; grid-template-columns: max-content 1fr; gap: 6px 15px; margin: 24px 0; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.metadata dt { color: var(--muted); font-weight: 700; }
.metadata dd { min-width: 0; margin: 0; overflow-wrap: anywhere; }
.mail-body { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; font: 14px/1.65 ui-monospace, "SFMono-Regular", Consolas, monospace; }
@media (max-width: 700px) { .topbar { padding: 12px 16px; align-items: flex-start; } .account { align-items: flex-end; flex-direction: column; gap: 6px; } .shell { margin-top: 24px; } .message-row { grid-template-columns: 1fr auto; gap: 3px 12px; } .message-row .subject { grid-column: 1 / -1; grid-row: 2; } .login-card { margin-top: 4vh; padding: 24px; } }

