:root {
  color-scheme: dark;
  --bg: #0d1119;
  --panel: rgba(20, 24, 34, 0.76);
  --panel-strong: rgba(25, 29, 40, 0.9);
  --line: rgba(139, 151, 173, 0.18);
  --line-bright: rgba(139, 92, 246, 0.58);
  --text: #f7f8fb;
  --muted: #b8bfce;
  --soft: #8f98aa;
  --purple: #7c3cff;
  --purple-2: #9a63ff;
  --green: #25e0a4;
  --orange: #ffad3d;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.44);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 50% 0%, rgba(124, 60, 255, 0.16), transparent 28rem),
    radial-gradient(circle at 15% 70%, rgba(124, 60, 255, 0.09), transparent 24rem),
    linear-gradient(180deg, #0e131d 0%, #0b1018 42%, #0e131c 100%);
  color: var(--text);
}

body:has(.inbox-shell[hidden]) {
  min-height: 100vh;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 74px 74px;
  mask-image: radial-gradient(circle at 50% 25%, black, transparent 72%);
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.topbar {
  min-height: 68px;
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(286px, 330px);
  align-items: center;
  gap: 10px;
  padding: 9px 16px 9px clamp(42px, 8vw, 150px);
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 14px 14px;
  background: rgba(13, 17, 25, 0.78);
  box-shadow: 0 12px 42px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(18px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-self: start;
}

.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 11px;
  background: linear-gradient(135deg, #5d2df8, #8b5cf6 54%, #4f46e5);
  box-shadow: 0 14px 34px rgba(124, 60, 255, 0.35);
  position: relative;
}

.brand-mark::before,
.brand-mark::after {
  content: "";
  position: absolute;
  height: 4px;
  border-radius: 999px;
  background: white;
}

.brand-mark::before {
  width: 26px;
  left: 9px;
  top: 22px;
  transform: rotate(39deg);
}

.brand-mark::after {
  width: 26px;
  left: 9px;
  top: 22px;
  transform: rotate(-39deg);
}

.brand strong {
  display: block;
  font-size: 1.14rem;
  line-height: 1;
}

.brand span {
  display: block;
  color: var(--muted);
  margin-top: 3px;
  font-size: 0.76rem;
}

.topnav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: clamp(8px, 1vw, 15px);
  min-width: 0;
}

.topnav a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #e6e9f1;
  font-weight: 650;
  font-size: 0.8rem;
  text-decoration: none;
  white-space: nowrap;
}

.nav-icon,
.retention-icon,
.mode-icon,
.benefit-icon,
.refresh-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  flex: 0 0 auto;
}

.nav-icon {
  width: 17px;
  height: 17px;
  color: #dce2ef;
}

.nav-icon svg,
.retention-icon svg,
.mode-icon svg,
.benefit-icon svg,
.create-plus svg,
.copy-email-button svg {
  width: 100%;
  height: 100%;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.35;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-icon::before,
.nav-icon::after,
.retention-icon::before,
.retention-icon::after,
.mode-icon::before,
.mode-icon::after,
.create-plus::before,
.create-plus::after,
.clock::before,
.clock::after,
.reuse::before,
.reuse::after,
.private::before,
.private::after,
.fast::before,
.fast::after {
  content: none !important;
  display: none !important;
}

.inbox-nav::before {
  content: "";
  position: absolute;
  inset: 4px 2px;
  border: 2px solid #dce2ef;
  border-radius: 3px;
}

.inbox-nav::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 7px;
  width: 12px;
  height: 8px;
  border-left: 2px solid #dce2ef;
  border-bottom: 2px solid #dce2ef;
  transform: rotate(-45deg);
}

.grid-nav::before {
  content: "";
  position: absolute;
  inset: 2px;
  background:
    linear-gradient(#dce2ef 0 0) left top / 5px 5px no-repeat,
    linear-gradient(#dce2ef 0 0) right top / 5px 5px no-repeat,
    linear-gradient(#dce2ef 0 0) left bottom / 5px 5px no-repeat,
    linear-gradient(#dce2ef 0 0) right bottom / 5px 5px no-repeat;
}

.help-nav::before {
  content: "?";
  position: absolute;
  inset: 1px;
  display: grid;
  place-items: center;
  border: 2px solid #dce2ef;
  border-radius: 50%;
  font-weight: 800;
  font-size: 0.78rem;
}

.shield-nav::before,
.retention-icon::before {
  content: "";
  position: absolute;
  inset: 1px 4px;
  background: transparent;
  border: 2px solid currentColor;
  clip-path: polygon(50% 0, 94% 16%, 86% 66%, 50% 100%, 14% 66%, 6% 16%);
}

.chat-nav::before {
  content: "";
  position: absolute;
  inset: 4px 2px 5px;
  border: 2px solid #dce2ef;
  border-radius: 4px;
}

.chat-nav::after {
  content: "";
  position: absolute;
  left: 6px;
  bottom: 2px;
  width: 7px;
  height: 7px;
  border-left: 2px solid #dce2ef;
  border-bottom: 2px solid #dce2ef;
  transform: rotate(-25deg);
}

.retention-card {
  justify-self: end;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  align-items: center;
  gap: 11px;
  width: min(100%, 306px);
  min-width: 0;
  min-height: 52px;
  padding: 9px 14px;
  border: 1px solid rgba(37, 224, 164, 0.16);
  border-radius: 12px;
  background: rgba(24, 48, 45, 0.42);
}

.retention-icon {
  width: 28px;
  height: 28px;
  color: var(--green);
}

.retention-card strong {
  display: block;
  color: var(--green);
  font-size: 0.9rem;
  white-space: nowrap;
}

.retention-card span {
  color: #e0e5ee;
  font-size: 0.76rem;
  white-space: nowrap;
}

.app {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
  flex: 1 0 auto;
  display: grid;
  align-items: stretch;
}

.hero {
  min-height: calc(100vh - 68px - 54px);
  padding: clamp(28px, 4vh, 46px) 0 clamp(22px, 3vh, 34px);
  display: grid;
  align-content: center;
  justify-items: center;
  gap: clamp(28px, 4vh, 42px);
}

.hero-copy {
  text-align: center;
}

.hero-copy h1 {
  margin: 0;
  font-size: clamp(1.72rem, 3vw, 2.34rem);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero-copy h1 span {
  color: var(--purple-2);
}

.hero-copy p {
  max-width: 660px;
  margin: 10px auto 0;
  color: var(--muted);
  font-size: clamp(0.92rem, 1.22vw, 1.05rem);
  line-height: 1.38;
}

.generator-card {
  width: min(960px, 100%);
  min-height: 232px;
  display: grid;
  gap: 13px;
  align-content: center;
  padding: 20px 34px;
  border: 1px solid rgba(124, 60, 255, 0.48);
  border-radius: 24px;
  background: rgba(18, 22, 32, 0.68);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), var(--shadow);
}

.mode-tabs {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.mode-button {
  width: 196px;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid rgba(139, 151, 173, 0.22);
  border-radius: 14px;
  background: rgba(12, 16, 24, 0.35);
  color: #f8fafc;
  font-weight: 800;
  font-size: 0.96rem;
}

.mode-button.active {
  border-color: rgba(124, 60, 255, 0.86);
  box-shadow: inset 0 0 0 1px rgba(124, 60, 255, 0.16);
}

.mode-icon {
  width: 20px;
  height: 20px;
  color: var(--purple-2);
}

.shuffle::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 5px;
  width: 17px;
  height: 12px;
  background:
    linear-gradient(currentColor 0 0) 2px 2px / 14px 3px no-repeat,
    linear-gradient(currentColor 0 0) 2px 9px / 14px 3px no-repeat;
}

.shuffle::after {
  content: "";
  position: absolute;
  right: 1px;
  top: 3px;
  width: 8px;
  height: 8px;
  border-top: 3px solid currentColor;
  border-right: 3px solid currentColor;
  transform: rotate(45deg);
  box-shadow: -13px 8px 0 -3px currentColor;
}

.history::before {
  content: "";
  position: absolute;
  inset: 3px;
  border: 3px solid currentColor;
  border-left-color: transparent;
  border-radius: 50%;
}

.history::after {
  content: "";
  position: absolute;
  left: 2px;
  top: 8px;
  width: 8px;
  height: 8px;
  border-left: 3px solid currentColor;
  border-top: 3px solid currentColor;
  transform: rotate(-32deg);
}

.create-form {
  display: grid;
  gap: 16px;
}

.email-compose {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(190px, 24%);
  border: 1px solid rgba(139, 151, 173, 0.22);
  border-radius: 14px;
  background: rgba(29, 34, 45, 0.64);
  overflow: hidden;
}

input,
select {
  min-height: 52px;
  border: 0;
  background: transparent;
  color: #f8fafc;
  outline: 0;
}

input {
  padding: 0 20px;
  font-size: 1rem;
}

input::placeholder {
  color: rgba(232, 236, 245, 0.48);
}

select {
  border-left: 1px solid rgba(139, 151, 173, 0.22);
  padding: 0 34px 0 14px;
  font-weight: 800;
  font-size: 0.92rem;
  appearance: none;
  background:
    linear-gradient(45deg, transparent 50%, #dce2ef 50%) calc(100% - 20px) 50% / 6px 6px no-repeat,
    linear-gradient(135deg, #dce2ef 50%, transparent 50%) calc(100% - 15px) 50% / 6px 6px no-repeat,
    linear-gradient(180deg, rgba(35, 40, 52, 0.96), rgba(24, 29, 40, 0.96));
  box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.03);
  min-width: 0;
  text-overflow: ellipsis;
}

select:hover {
  background:
    linear-gradient(45deg, transparent 50%, white 50%) calc(100% - 20px) 50% / 6px 6px no-repeat,
    linear-gradient(135deg, white 50%, transparent 50%) calc(100% - 15px) 50% / 6px 6px no-repeat,
    linear-gradient(180deg, rgba(43, 49, 64, 0.98), rgba(28, 33, 45, 0.98));
}

select:focus {
  box-shadow:
    inset 1px 0 0 rgba(255, 255, 255, 0.04),
    0 0 0 3px rgba(124, 60, 255, 0.24);
}

select option {
  background: #171c27;
  color: #f8fafc;
  font-weight: 800;
}

select option:checked {
  background: #6d35ff;
  color: white;
}

.email-preview {
  display: none;
}

.primary-action {
  min-width: 292px;
  min-height: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, #6d35ff, #7c3cff 52%, #5a2df2);
  color: white;
  font-size: 1.04rem;
  font-weight: 850;
  box-shadow: 0 20px 42px rgba(124, 60, 255, 0.28);
}

.create-actions {
  justify-self: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.copy-email-button {
  width: 56px;
  height: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(139, 92, 246, 0.52);
  border-radius: 14px;
  background: rgba(23, 28, 39, 0.72);
  color: #d9ccff;
  box-shadow: inset 0 0 0 1px rgba(124, 60, 255, 0.08);
}

.copy-email-button:hover {
  border-color: rgba(154, 99, 255, 0.86);
  color: white;
  background: rgba(42, 32, 71, 0.78);
}

.copy-email-button span {
  width: 22px;
  height: 22px;
}

.create-plus {
  width: 22px;
  height: 22px;
  position: relative;
  flex: 0 0 auto;
}

.create-plus::before,
.create-plus::after {
  content: "";
  position: absolute;
  background: white;
  border-radius: 999px;
}

.create-plus::before {
  width: 100%;
  height: 2.5px;
  top: 8.75px;
  left: 0;
}

.create-plus::after {
  width: 2.5px;
  height: 100%;
  left: 8.75px;
  top: 0;
}

.alert {
  justify-self: center;
  width: fit-content;
  max-width: 100%;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  border: 1px solid rgba(37, 224, 164, 0.28);
  border-radius: 999px;
  background: rgba(13, 35, 31, 0.86);
  color: #7ff5cd;
  text-align: center;
  font-weight: 800;
  font-size: 0.88rem;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.28);
}

.alert.is-error {
  border-color: rgba(255, 117, 103, 0.38);
  background: rgba(43, 21, 26, 0.88);
  color: #ffd4cf;
}

.history-panel {
  width: min(620px, 100%);
  justify-self: center;
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 16px;
  background: rgba(14, 18, 28, 0.74);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.history-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.history-head strong {
  color: #f8fafc;
  font-size: 0.92rem;
}

.history-actions {
  display: inline-flex;
  gap: 8px;
}

.history-head button {
  min-height: 30px;
  border: 1px solid rgba(139, 151, 173, 0.18);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-weight: 800;
  padding: 0 10px;
}

.history-empty {
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
  padding: 10px;
}

.history-list {
  display: grid;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.history-list li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px;
  gap: 8px;
}

.history-use,
.history-copy {
  min-height: 40px;
  border: 1px solid rgba(139, 151, 173, 0.16);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.04);
  color: #f8fafc;
}

.history-use {
  min-width: 0;
  padding: 0 12px;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 800;
}

.history-copy {
  display: grid;
  place-items: center;
  font-size: 1rem;
}

.history-use:hover,
.history-copy:hover,
.history-head button:hover {
  border-color: rgba(154, 99, 255, 0.5);
  background: rgba(124, 60, 255, 0.12);
  color: white;
}

.current {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  margin: 14px 14px 0;
  border: 1px solid rgba(139, 92, 246, 0.28);
  border-radius: 18px;
  background:
    radial-gradient(circle at 95% 0%, rgba(124, 60, 255, 0.15), transparent 42%),
    linear-gradient(135deg, rgba(37, 224, 164, 0.08), rgba(124, 60, 255, 0.08)),
    rgba(14, 22, 30, 0.74);
  padding: 13px 14px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.current-copy span {
  display: block;
  color: #8ff0cf;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 900;
}

.current-copy strong {
  display: block;
  margin-top: 5px;
  max-width: 100%;
  overflow-wrap: anywhere;
  color: rgba(247, 250, 252, 0.96);
  font-size: 0.92rem;
  line-height: 1.25;
}

.current-copy-button {
  width: 48px;
  height: 48px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(139, 92, 246, 0.52);
  border-radius: 14px;
  background: rgba(23, 28, 39, 0.72);
  color: #d9ccff;
  box-shadow: inset 0 0 0 1px rgba(124, 60, 255, 0.08);
  font-size: 1.18rem;
  line-height: 1;
}

.current-copy-button span {
  display: none;
}

.current-copy-button::before,
.current-copy-button::after {
  content: "";
  position: absolute;
  border: 2px solid currentColor;
  border-radius: 5px;
}

.current-copy-button::before {
  width: 14px;
  height: 17px;
  transform: translate(3px, 2px);
}

.current-copy-button::after {
  width: 14px;
  height: 17px;
  transform: translate(-3px, -3px);
  background: rgba(23, 28, 39, 0.95);
}

.current-copy-button:hover {
  border-color: rgba(154, 99, 255, 0.86);
  color: white;
  background: rgba(42, 32, 71, 0.78);
}

.benefits {
  width: min(1080px, 100%);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

.benefit-card {
  min-height: 142px;
  display: grid;
  justify-items: center;
  align-content: center;
  text-align: center;
  gap: 8px;
  padding: 0 24px;
  border-right: 1px solid rgba(139, 151, 173, 0.2);
}

.benefit-card:last-child {
  border-right: 0;
}

.benefit-icon {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  margin-bottom: 4px;
  display: grid;
  place-items: center;
}

.benefit-icon svg {
  width: 30px;
  height: 30px;
}

.clock {
  background: rgba(124, 60, 255, 0.24);
  color: var(--purple-2);
}

.reuse {
  background: rgba(37, 224, 164, 0.2);
  color: var(--green);
}

.private {
  background: rgba(124, 60, 255, 0.24);
  color: var(--purple-2);
}

.fast {
  background: rgba(255, 173, 61, 0.2);
  color: var(--orange);
}

.clock::before,
.reuse::before,
.private::before,
.fast::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 22px;
  height: 22px;
  transform: translate(-50%, -50%);
}

.clock::before {
  border: 3px solid var(--purple-2);
  border-radius: 50%;
}

.clock::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 7px;
  height: 11px;
  border-left: 3px solid var(--purple-2);
  border-bottom: 3px solid var(--purple-2);
  transform: translate(-15%, -58%);
}

.reuse::before {
  border: 3px solid var(--green);
  border-left-color: transparent;
  border-radius: 50%;
}

.private::before {
  width: 25px;
  height: 28px;
  border: 3px solid var(--purple-2);
  border-radius: 15px 15px 18px 18px;
  clip-path: polygon(50% 0, 94% 15%, 88% 67%, 50% 100%, 12% 67%, 6% 15%);
}

.private::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 3px;
  height: 13px;
  border-radius: 999px;
  background: var(--purple-2);
  transform: translate(-50%, -42%);
}

.fast::before {
  width: 22px;
  height: 27px;
  background: var(--orange);
  clip-path: polygon(56% 0, 92% 0, 65% 42%, 92% 42%, 38% 100%, 48% 56%, 12% 56%);
}

.benefit-card h2 {
  margin: 0;
  font-size: 1.02rem;
}

.benefit-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.35;
  font-size: 0.9rem;
}

.workspace {
  width: min(1080px, 100%);
  margin: 36px auto 0;
}

.content {
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(18, 22, 32, 0.72);
  box-shadow: var(--shadow);
}

.footer {
  width: min(1180px, calc(100vw - 32px));
  margin: auto auto 0;
  padding: 12px 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.88rem;
  flex: 0 0 auto;
}

.footer strong {
  color: var(--text);
}

.content {
  min-height: 620px;
  display: grid;
  grid-template-columns: minmax(310px, 360px) minmax(0, 1fr);
  overflow: hidden;
}

.messages-panel {
  min-width: 0;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--line);
  background:
    radial-gradient(circle at 20% 0%, rgba(124, 60, 255, 0.15), transparent 34%),
    rgba(15, 19, 28, 0.58);
}

.panel-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 16px 16px 12px;
}

.panel-head p {
  margin: 0 0 4px;
  color: var(--soft);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.panel-head h2 {
  margin: 0;
}

.message-count {
  display: grid;
  place-items: center;
  min-width: 34px;
  height: 30px;
  padding: 0 10px;
  border: 1px solid rgba(157, 102, 255, 0.35);
  border-radius: 999px;
  background: rgba(124, 60, 255, 0.22);
  color: var(--purple-2);
  box-shadow: 0 0 24px rgba(124, 60, 255, 0.15);
  font-weight: 900;
  font-size: 0.82rem;
}

.message-count.is-empty {
  border-color: rgba(139, 151, 173, 0.16);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  box-shadow: none;
}

.refresh-button {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.refresh-button:hover {
  border-color: rgba(157, 102, 255, 0.72);
  box-shadow: 0 0 24px rgba(124, 60, 255, 0.24);
  transform: translateY(-1px);
}

.refresh-icon {
  width: 20px;
  height: 20px;
}

.refresh-icon::before {
  content: "";
  position: absolute;
  inset: 2px;
  border: 2.5px solid var(--purple-2);
  border-right-color: transparent;
  border-radius: 50%;
}

.refresh-icon::after {
  content: "";
  position: absolute;
  right: 1px;
  top: 2px;
  width: 8px;
  height: 8px;
  border-top: 2.5px solid var(--purple-2);
  border-right: 2.5px solid var(--purple-2);
  transform: rotate(43deg);
}

.message-list {
  list-style: none;
  margin: 0;
  padding: 0 14px 18px;
  display: grid;
  gap: 10px;
  overflow: auto;
}

.message-list li {
  min-width: 0;
}

.message-button {
  width: 100%;
  min-height: 116px;
  display: grid;
  gap: 7px;
  align-content: start;
  padding: 14px;
  border: 1px solid rgba(139, 151, 173, 0.16);
  border-radius: 14px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.025)),
    rgba(11, 14, 22, 0.62);
  color: var(--text);
  text-align: left;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.message-button:hover,
.message-button.active {
  border-color: rgba(157, 102, 255, 0.64);
  background:
    linear-gradient(145deg, rgba(124, 60, 255, 0.17), rgba(255, 255, 255, 0.035)),
    rgba(11, 14, 22, 0.72);
  box-shadow: 0 0 0 1px rgba(124, 60, 255, 0.14), 0 18px 36px rgba(124, 60, 255, 0.18);
  transform: translateY(-1px);
}

.message-button.read:not(.active) {
  border-color: rgba(139, 151, 173, 0.1);
  opacity: 0.72;
}

.message-card-top {
  min-width: 0;
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 10px;
}

.message-subject,
.message-sender,
.message-preview {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-subject {
  min-width: 0;
  font-weight: 800;
  color: rgba(246, 247, 251, 0.95);
}

.message-date {
  flex: 0 0 auto;
  color: var(--purple-2);
  font-size: 0.72rem;
  font-weight: 900;
  line-height: 1.8;
}

.message-sender,
.message-preview {
  color: var(--muted);
  font-size: 0.9rem;
}

.message-sender {
  color: rgba(39, 245, 188, 0.86);
  font-size: 0.78rem;
  font-weight: 800;
}

.message-preview {
  display: -webkit-box;
  white-space: normal;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.38;
}

.empty,
.reader-empty {
  color: var(--muted);
  text-align: center;
}

.empty {
  margin: 0 14px 18px;
  min-height: 286px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  padding: 28px 18px;
  border: 1px dashed rgba(157, 102, 255, 0.34);
  border-radius: 20px;
  background:
    radial-gradient(circle at 50% 20%, rgba(124, 60, 255, 0.2), transparent 42%),
    rgba(255, 255, 255, 0.035);
}

.empty-icon,
.reader-empty-icon {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(157, 102, 255, 0.38);
  border-radius: 18px;
  background: rgba(124, 60, 255, 0.16);
  color: var(--purple-2);
  box-shadow: 0 16px 34px rgba(124, 60, 255, 0.18);
}

.empty-icon svg,
.reader-empty-icon svg {
  width: 28px;
  height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.empty strong {
  color: var(--text);
  font-size: 1rem;
}

.empty-address {
  max-width: 100%;
  display: block;
  padding: 8px 12px;
  border: 1px solid rgba(39, 245, 188, 0.18);
  border-radius: 999px;
  background: rgba(39, 245, 188, 0.08);
  color: rgba(229, 255, 247, 0.94);
  font-size: 0.84rem;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.empty-copy-button {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid rgba(157, 102, 255, 0.42);
  border-radius: 12px;
  background: rgba(124, 60, 255, 0.16);
  color: var(--text);
  font-weight: 900;
}

.empty-copy-button:hover {
  border-color: rgba(157, 102, 255, 0.78);
  box-shadow: 0 0 28px rgba(124, 60, 255, 0.22);
}

.reader {
  min-width: 0;
  padding: 24px;
  overflow: auto;
  background:
    radial-gradient(circle at 80% 10%, rgba(124, 60, 255, 0.1), transparent 34%),
    rgba(5, 8, 14, 0.18);
}

.reader-empty {
  min-height: 100%;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 10px;
  padding: 28px;
}

.reader-empty strong {
  color: var(--text);
}

.reader-head {
  display: grid;
  gap: 12px;
  margin-bottom: 18px;
  padding: 18px;
  border: 1px solid rgba(139, 151, 173, 0.16);
  border-radius: 20px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.025)),
    rgba(13, 17, 26, 0.66);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.reader-kicker {
  color: var(--purple-2);
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.reader h3 {
  margin: 0;
  color: rgba(246, 247, 251, 0.96);
  font-size: clamp(1.28rem, 2vw, 1.85rem);
  line-height: 1.16;
}

.reader-from {
  display: grid;
  gap: 3px;
}

.reader-from span {
  color: var(--soft);
  font-size: 0.75rem;
  font-weight: 900;
  text-transform: uppercase;
}

.reader-from strong {
  min-width: 0;
  color: rgba(39, 245, 188, 0.9);
  overflow-wrap: anywhere;
}

.reader-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: var(--muted);
  font-size: 0.86rem;
}

.message-body-card {
  min-height: 220px;
  padding: 22px;
  border: 1px solid rgba(139, 151, 173, 0.16);
  border-radius: 20px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.025)),
    rgba(10, 13, 21, 0.68);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.045);
}

.message-body {
  line-height: 1.65;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: rgba(234, 238, 248, 0.92);
}

.html-frame {
  width: 100%;
  min-height: 360px;
  border: 0;
  border-radius: 14px;
  background: rgba(247, 249, 252, 0.94);
}

.attachments {
  margin-top: 16px;
  padding: 16px;
  border: 1px solid rgba(139, 151, 173, 0.16);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.035);
}

.attachments strong {
  color: var(--text);
}

.attachments ul {
  margin: 10px 0 0;
  padding-left: 18px;
  color: var(--muted);
}

.inbox-shell[hidden] {
  display: none !important;
}

@media (max-width: 1100px) {
  .topbar {
    grid-template-columns: minmax(220px, 1fr) minmax(286px, 330px);
    padding-left: clamp(28px, 5vw, 72px);
  }

  .retention-card {
    justify-self: end;
  }

  .benefits {
    grid-template-columns: repeat(2, 1fr);
  }

  .benefit-card:nth-child(2) {
    border-right: 0;
  }
}

@media (max-width: 720px) {
  .topbar {
    min-height: auto;
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 12px 14px;
    position: relative;
    border-radius: 0 0 18px 18px;
  }

  .brand {
    justify-self: center;
    justify-content: center;
    transform: translateX(10px);
  }

  .brand-mark {
    width: 42px;
    height: 42px;
  }

  .retention-card {
    min-width: 0;
    width: min(100%, 330px);
    justify-self: center;
    grid-template-columns: 28px minmax(0, 1fr);
    padding: 9px 12px;
  }

  .retention-card strong,
  .retention-card span {
    white-space: nowrap;
  }

  .hero {
    min-height: auto;
    padding: 28px 0 22px;
    gap: 22px;
  }

  .generator-card {
    min-height: auto;
    padding: 18px;
    gap: 16px;
    border-radius: 20px;
  }

  .hero-copy h1 {
    max-width: 11ch;
    font-size: clamp(2rem, 11vw, 2.7rem);
    line-height: 1;
  }

  .hero-copy p {
    max-width: 31rem;
    font-size: 0.98rem;
    line-height: 1.45;
    padding: 0 4px;
  }

  .mode-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .mode-button {
    width: 100%;
    min-width: 0;
    min-height: 48px;
    gap: 9px;
    font-size: 0.88rem;
    padding: 0 10px;
  }

  .mode-icon {
    width: 19px;
    height: 19px;
  }

  .benefits {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .content,
  .email-compose {
    grid-template-columns: 1fr;
  }

  input,
  select {
    min-height: 54px;
  }

  input {
    padding: 0 18px;
    font-size: 0.98rem;
  }

  select {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 0 42px 0 18px;
    font-size: 0.98rem;
  }

  .primary-action {
    flex: 1 1 auto;
    width: auto;
    min-width: 0;
    min-height: 58px;
    font-size: 1rem;
  }

  .create-actions {
    width: 100%;
  }

  .copy-email-button {
    width: 58px;
    height: 58px;
  }

  .benefit-card {
    min-height: 158px;
    gap: 8px;
    padding: 18px 12px;
    border: 1px solid rgba(139, 151, 173, 0.18);
    border-radius: 16px;
    background: rgba(18, 22, 32, 0.42);
  }

  .benefit-card:nth-child(2) {
    border-right: 1px solid rgba(139, 151, 173, 0.18);
  }

  .benefit-card:last-child {
    border: 1px solid rgba(139, 151, 173, 0.18);
  }

  .benefit-icon {
    width: 52px;
    height: 52px;
    margin-bottom: 4px;
  }

  .benefit-icon svg {
    width: 27px;
    height: 27px;
  }

  .benefit-card h2 {
    font-size: 0.92rem;
    line-height: 1.2;
  }

  .benefit-card p {
    font-size: 0.78rem;
    line-height: 1.32;
  }

  .footer {
    width: min(100% - 28px, 1180px);
    padding: 12px 0 16px;
    font-size: 0.78rem;
    gap: 8px;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .content {
    min-height: auto;
  }

  .messages-panel {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .current {
    margin: 12px 12px 0;
  }

  .panel-head {
    padding: 14px 12px 10px;
  }

  .message-list {
    padding: 0 12px 14px;
    max-height: none;
  }

  .empty {
    min-height: 240px;
    margin: 0 12px 14px;
  }

  .reader {
    min-height: 420px;
    padding: 16px;
  }

  .reader-head,
  .message-body-card {
    border-radius: 18px;
  }

  .reader-meta {
    gap: 7px;
  }
}

@media (max-width: 420px) {
  .app {
    width: min(100% - 24px, 1180px);
  }

  .topbar {
    padding: 10px 12px;
    gap: 10px;
  }

  .brand span {
    font-size: 0.72rem;
  }

  .retention-card {
    width: 100%;
    min-height: 50px;
  }

  .retention-card strong {
    font-size: 0.84rem;
  }

  .retention-card span {
    font-size: 0.7rem;
  }

  .mode-tabs {
    grid-template-columns: 1fr;
  }

  .benefits {
    grid-template-columns: 1fr;
  }

  .benefit-card {
    min-height: 138px;
  }

  .current {
    grid-template-columns: minmax(0, 1fr) 40px;
    padding: 12px;
  }

  .current-copy-button {
    width: 40px;
    height: 40px;
  }

  .panel-head {
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 8px;
  }

  .message-button {
    min-height: 108px;
    padding: 13px;
  }

  .message-card-top {
    display: grid;
    gap: 3px;
  }

  .message-date {
    justify-self: start;
    line-height: 1.2;
  }

  .empty-address {
    max-width: 240px;
  }
}

@media (max-width: 380px) {
  .topbar {
    padding: 9px 10px;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

  .brand strong {
    font-size: 1.02rem;
  }

  .brand span {
    font-size: 0.68rem;
  }

  .retention-card {
    grid-template-columns: 24px minmax(0, 1fr);
    gap: 8px;
    padding: 8px 10px;
  }

  .retention-icon {
    width: 24px;
    height: 24px;
  }

  .retention-card strong {
    font-size: 0.78rem;
  }

  .retention-card span {
    font-size: 0.64rem;
  }

  .hero {
    padding-top: 22px;
    gap: 18px;
  }

  .hero-copy h1 {
    font-size: clamp(1.82rem, 10vw, 2.3rem);
  }

  .hero-copy p {
    font-size: 0.9rem;
  }

  .generator-card {
    padding: 14px;
    gap: 14px;
  }

  .mode-button {
    min-height: 44px;
  }

  .primary-action {
    min-height: 54px;
  }
}

.nav-icon::before,
.nav-icon::after,
.retention-icon::before,
.retention-icon::after,
.mode-icon::before,
.mode-icon::after,
.create-plus::before,
.create-plus::after,
.clock::before,
.clock::after,
.reuse::before,
.reuse::after,
.private::before,
.private::after,
.fast::before,
.fast::after {
  content: none !important;
  display: none !important;
}
