.email-settings-layout {
  width: min(1080px, calc(100% - 48px));
  margin: 0 auto 24px;
  display: grid;
  gap: 22px;
}
body:has(#email-preferences:not([hidden])) #account-app { min-height: 0; }
.email-settings-layout:not(:has(> :not([hidden]))) { display: none; }
.email-card { font-size: 1rem; }
.email-card fieldset { margin: 16px 0 0; padding: 0; border: 0; min-width: 0; }
.email-card .field { margin-bottom: 16px; font-size: 0.95rem; }
.email-card select, .email-card textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid #50504d;
  border-radius: 10px;
  background: #131310;
  color: var(--ink);
  font: inherit;
}
.email-card textarea { resize: vertical; }
.email-card :is(select, textarea, summary):focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.email-option { display: flex; align-items: center; gap: 14px; padding: 12px 0; cursor: pointer; }
.email-option input { width: 20px; height: 20px; flex: 0 0 20px; accent-color: var(--accent); }
.email-option strong, .email-option small { display: block; }
.email-option small { color: var(--muted); font-size: 0.9rem; }
.email-card .button { max-width: 100%; font-size: 0.9rem; overflow-wrap: anywhere; }
.email-card .email-option + .button, #email-unsubscribe button { margin-top: 12px; }
.email-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.email-preview { margin-top: 24px; border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
.email-preview pre { white-space: pre-wrap; overflow-wrap: anywhere; font: inherit; }
.email-status:not(:empty) { margin: 12px 0; }
.email-history { margin-top: 16px; }
.email-history summary { cursor: pointer; }
.email-history ul { display: flex; flex-wrap: wrap; list-style: none; gap: 8px; margin: 8px 0 0; padding: 0; }
.email-visually-hidden { position: absolute; clip-path: inset(50%); width: 1px; height: 1px; overflow: hidden; white-space: nowrap; }
@media (max-width: 500px) { .email-settings-layout { width: calc(100% - 32px); } }

.email-card .email-confirmation { padding: 12px; border: 1px solid var(--line); border-radius: 10px; }
.email-confirmation .email-actions { margin-top: 10px; }
