:root {
  --paper: #f2efe7;
  --paper-deep: #e9e5db;
  --surface: #fbfaf6;
  --white: #ffffff;
  --ink: #16211b;
  --ink-soft: #26342c;
  --muted: #69746d;
  --muted-light: #8c948f;
  --line: #d9d6cd;
  --line-dark: #c6c4bb;
  --green: #17634a;
  --green-light: #d9eee4;
  --green-neon: #8becbc;
  --orange: #ff6b18;
  --orange-soft: #fff0e5;
  --red: #b13d32;
  --red-soft: #fae9e6;
  --blue: #2a63b7;
  --blue-soft: #e8f0fb;
  --shadow-sm: 0 8px 24px rgba(22, 33, 27, 0.07);
  --shadow-lg: 0 30px 80px rgba(22, 33, 27, 0.13);
  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --shell: min(1180px, calc(100vw - 48px));
  color-scheme: light;
  font-family:
    Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

button,
input,
select,
textarea {
  color: inherit;
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

svg {
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.shell {
  width: var(--shell);
  margin-inline: auto;
}

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

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 12px;
  left: 12px;
  transform: translateY(-150%);
  padding: 10px 14px;
  border-radius: 8px;
  color: var(--white);
  background: var(--ink);
}

.skip-link:focus {
  transform: translateY(0);
}

:focus-visible {
  outline: 3px solid rgba(255, 107, 24, 0.55);
  outline-offset: 3px;
}

.site-header {
  position: relative;
  z-index: 20;
  display: flex;
  width: var(--shell);
  min-height: 86px;
  margin-inline: auto;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(22, 33, 27, 0.14);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-size: 17px;
  font-weight: 650;
  letter-spacing: -0.03em;
}

.brand b {
  font-weight: 800;
}

.brand-mark {
  position: relative;
  display: inline-block;
  width: 28px;
  height: 28px;
  border-radius: 7px;
  overflow: hidden;
  background: var(--orange);
  box-shadow: inset 0 0 0 1px rgba(22, 33, 27, 0.08);
}

.brand-mark span {
  position: absolute;
  display: block;
  width: 22px;
  height: 11px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  border-bottom-color: transparent;
}

.brand-mark span:first-child {
  top: 6px;
  left: -4px;
  transform: rotate(13deg);
}

.brand-mark span:last-child {
  right: -4px;
  bottom: 3px;
  transform: rotate(193deg);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 30px;
  font-size: 13px;
  font-weight: 650;
}

.site-nav > a:not(.nav-console) {
  color: var(--muted);
  transition: color 160ms ease;
}

.site-nav > a:not(.nav-console):hover {
  color: var(--ink);
}

.nav-console {
  display: inline-flex;
  min-height: 40px;
  padding: 0 16px;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line-dark);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.44);
  transition:
    border-color 160ms ease,
    background 160ms ease,
    transform 160ms ease;
}

.nav-console:hover {
  border-color: var(--ink);
  background: var(--white);
  transform: translateY(-1px);
}

.nav-console svg {
  width: 15px;
  height: 15px;
}

.hero {
  position: relative;
  display: grid;
  min-height: 740px;
  padding: 76px 0 88px;
  grid-template-columns: minmax(0, 1.06fr) minmax(470px, 0.78fr);
  gap: clamp(44px, 6vw, 80px);
  align-items: center;
}

.hero::before {
  position: absolute;
  z-index: -1;
  top: -86px;
  right: 29%;
  width: 1px;
  height: 860px;
  background: linear-gradient(transparent, rgba(22, 33, 27, 0.12), transparent);
  content: "";
  transform: rotate(20deg);
}

.eyebrow,
.card-kicker {
  margin: 0;
  color: var(--green);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.17em;
  line-height: 1.4;
  text-transform: uppercase;
}

.live-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 5px rgba(23, 99, 74, 0.1);
}

.hero h1 {
  margin: 24px 0 24px;
  font-size: clamp(46px, 5.25vw, 66px);
  font-weight: 760;
  letter-spacing: -0.075em;
  line-height: 1.08;
}

.hero h1 em {
  color: var(--green);
  font-family: Georgia, "Noto Serif JP", serif;
  font-weight: 500;
}

.hero-headline {
  white-space: nowrap;
}

.hero-accent {
  position: relative;
  display: inline-block;
}

.hero-accent::after {
  position: absolute;
  right: 2%;
  bottom: -7px;
  left: 4%;
  height: 9px;
  border-top: 2px solid var(--orange);
  border-radius: 50%;
  content: "";
  transform: rotate(-1.5deg);
}

.hero-lead {
  max-width: 560px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  letter-spacing: 0.015em;
  line-height: 1.95;
}

.product-row {
  display: flex;
  margin-top: 32px;
  flex-wrap: wrap;
  gap: 8px;
}

.product-row span {
  padding: 7px 10px;
  border: 1px solid var(--line-dark);
  border-radius: 6px;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.36);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-stats {
  display: flex;
  margin: 42px 0 0;
  gap: 0;
}

.hero-stats div {
  min-width: 116px;
  padding-right: 25px;
}

.hero-stats div + div {
  padding-left: 25px;
  border-left: 1px solid var(--line-dark);
}

.hero-stats dt {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.hero-stats dd {
  margin: 4px 0 0;
  color: var(--muted-light);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.form-stage {
  position: relative;
}

.form-orbit {
  position: absolute;
  z-index: -1;
  border: 1px solid rgba(23, 99, 74, 0.14);
  border-radius: 50%;
}

.form-orbit-one {
  top: -36px;
  right: -28px;
  width: 190px;
  height: 190px;
}

.form-orbit-two {
  right: -30px;
  bottom: -42px;
  width: 90px;
  height: 90px;
  border-color: rgba(255, 107, 24, 0.35);
}

.contact-card {
  position: relative;
  min-height: 620px;
  padding: 30px 32px 25px;
  border: 1px solid rgba(22, 33, 27, 0.15);
  border-radius: var(--radius-lg);
  background: rgba(251, 250, 246, 0.96);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(16px);
}

.contact-card::before {
  position: absolute;
  top: -9px;
  left: 30px;
  width: 54px;
  height: 16px;
  border: 1px solid rgba(22, 33, 27, 0.14);
  border-radius: 4px;
  background: var(--orange);
  content: "";
  transform: rotate(-3deg);
}

.card-heading {
  display: flex;
  margin-bottom: 24px;
  align-items: flex-start;
  justify-content: space-between;
}

.card-heading h2 {
  margin: 7px 0 0;
  font-size: 25px;
  letter-spacing: -0.045em;
}

.secure-pill {
  display: inline-flex;
  padding: 6px 9px;
  align-items: center;
  gap: 5px;
  border: 1px solid #b9d7c8;
  border-radius: 999px;
  color: var(--green);
  background: var(--green-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.secure-pill svg {
  width: 12px;
  height: 12px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 14px;
  row-gap: 16px;
}

.field-wide {
  grid-column: 1 / -1;
}

.field label {
  display: flex;
  margin-bottom: 7px;
  align-items: center;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 750;
}

.field label span {
  color: var(--orange);
  font-size: 8px;
  letter-spacing: 0.06em;
}

.field label small {
  color: var(--muted-light);
  font-size: 9px;
  font-weight: 600;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  outline: none;
  background: var(--white);
  transition:
    border-color 150ms ease,
    box-shadow 150ms ease,
    background 150ms ease;
}

.field input,
.field select {
  height: 43px;
  padding: 0 12px;
}

.field textarea {
  min-height: 99px;
  padding: 11px 12px;
  line-height: 1.6;
  resize: vertical;
}

.field input:hover,
.field select:hover,
.field textarea:hover {
  border-color: var(--line-dark);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(23, 99, 74, 0.1);
}

.field [aria-invalid="true"] {
  border-color: var(--red);
  background: #fffafa;
}

.select-wrap {
  position: relative;
}

.select-wrap select {
  padding-right: 36px;
  appearance: none;
}

.select-wrap > svg {
  position: absolute;
  top: 50%;
  right: 12px;
  width: 14px;
  height: 14px;
  pointer-events: none;
  transform: translateY(-50%);
}

.field-error {
  min-height: 0;
  margin: 4px 0 0;
  color: var(--red);
  font-size: 10px;
  line-height: 1.4;
}

.field-error:empty {
  display: none;
}

.field-meta {
  display: flex;
  min-height: 16px;
  align-items: flex-start;
  justify-content: space-between;
}

.field-meta > span {
  margin: 5px 2px 0 auto;
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
}

.honeypot {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip: rect(1px, 1px, 1px, 1px) !important;
}

.check-field {
  display: inline-flex;
  margin-top: 15px;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  cursor: pointer;
  font-size: 10px;
}

.check-field input {
  position: absolute;
  opacity: 0;
}

.custom-check {
  display: grid;
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
  border: 1px solid var(--line-dark);
  border-radius: 5px;
  background: var(--white);
  place-items: center;
  transition: 150ms ease;
}

.custom-check svg {
  width: 12px;
  height: 12px;
  stroke-width: 2.5;
  opacity: 0;
}

.check-field input:checked + .custom-check {
  border-color: var(--green);
  color: var(--white);
  background: var(--green);
}

.check-field input:checked + .custom-check svg {
  opacity: 1;
}

.check-field input:focus-visible + .custom-check {
  outline: 3px solid rgba(255, 107, 24, 0.5);
  outline-offset: 2px;
}

.turnstile-row {
  margin-top: 12px;
}

#turnstile-container {
  min-height: 0;
}

.form-alert {
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid #e0b3ad;
  border-radius: 8px;
  color: var(--red);
  background: var(--red-soft);
  font-size: 11px;
  line-height: 1.5;
}

.submit-button {
  display: flex;
  width: 100%;
  height: 48px;
  margin-top: 13px;
  padding: 0 17px;
  border: 0;
  border-radius: 11px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--white);
  background: var(--ink);
  box-shadow: 0 8px 20px rgba(22, 33, 27, 0.15);
  cursor: pointer;
  font-size: 12px;
  font-weight: 750;
  transition:
    background 150ms ease,
    transform 150ms ease,
    box-shadow 150ms ease;
}

.submit-button:hover:not(:disabled) {
  background: var(--green);
  box-shadow: 0 10px 24px rgba(23, 99, 74, 0.25);
  transform: translateY(-1px);
}

.submit-button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.submit-button > svg {
  width: 17px;
  height: 17px;
}

.button-loader {
  display: none;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}

.submit-button.loading .button-loader {
  display: block;
}

.submit-button.loading > svg {
  display: none;
}

.form-footnote {
  display: flex;
  margin: 10px 0 0;
  align-items: center;
  justify-content: center;
  gap: 5px;
  color: var(--muted-light);
  font-size: 8px;
}

.form-footnote svg {
  width: 12px;
  height: 12px;
  color: var(--green);
}

.success-panel {
  display: flex;
  min-height: 510px;
  padding: 42px 12px 10px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.success-panel[hidden] {
  display: none;
}

.success-icon {
  display: grid;
  width: 72px;
  height: 72px;
  margin-bottom: 24px;
  border: 1px solid #acd4c0;
  border-radius: 50%;
  color: var(--green);
  background: var(--green-light);
  place-items: center;
  animation: successIn 450ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.success-icon svg {
  width: 34px;
  height: 34px;
  stroke-width: 2.4;
}

.success-panel h2 {
  margin: 12px 0 10px;
  font-size: 28px;
  letter-spacing: -0.045em;
}

.success-panel > p:not(.card-kicker) {
  max-width: 350px;
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.8;
}

.ticket-card {
  display: grid;
  width: min(100%, 360px);
  padding: 15px 16px;
  border: 1px solid var(--line);
  border-radius: 13px;
  grid-template-columns: 1fr auto;
  align-items: center;
  text-align: left;
  background: var(--paper);
}

.ticket-card span {
  color: var(--muted-light);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ticket-card strong {
  margin-top: 3px;
  grid-column: 1;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 16px;
}

.ticket-card button {
  display: grid;
  width: 35px;
  height: 35px;
  border: 1px solid var(--line-dark);
  border-radius: 9px;
  grid-column: 2;
  grid-row: 1 / 3;
  background: var(--white);
  cursor: pointer;
  place-items: center;
}

.ticket-card button svg {
  width: 16px;
  height: 16px;
}

.success-route {
  display: flex;
  width: min(100%, 360px);
  margin: 24px 0;
  align-items: center;
  justify-content: center;
}

.success-route span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--muted-light);
  font-size: 9px;
  font-weight: 700;
}

.success-route span::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--line-dark);
  content: "";
}

.success-route span.done,
.success-route span.active {
  color: var(--green);
}

.success-route span.done::before {
  background: var(--green);
}

.success-route span.active::before {
  background: var(--green-neon);
  box-shadow: 0 0 0 4px rgba(23, 99, 74, 0.1);
}

.success-route i {
  width: 28px;
  height: 1px;
  margin: 0 8px;
  background: var(--line-dark);
}

.text-button {
  border: 0;
  border-bottom: 1px solid var(--ink);
  background: transparent;
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
}

.flow-section {
  padding: 112px 0 120px;
  color: var(--white);
  background: var(--ink);
}

.section-heading {
  display: grid;
  margin-bottom: 64px;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 80px;
  align-items: end;
}

.section-heading h2 {
  margin: 17px 0 0;
  font-size: clamp(36px, 4.2vw, 54px);
  letter-spacing: -0.065em;
  line-height: 1.18;
}

.section-heading > p {
  margin: 0 0 4px;
  color: rgba(255, 255, 255, 0.57);
  font-size: 13px;
  line-height: 1.9;
}

.flow-section .eyebrow {
  color: var(--green-neon);
}

.pipeline {
  display: grid;
  margin: 0;
  padding: 0;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  list-style: none;
}

.pipeline li {
  position: relative;
  min-height: 285px;
  padding: 30px 24px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
  border-left: 1px solid rgba(255, 255, 255, 0.16);
}

.pipeline li:last-child {
  border-right: 1px solid rgba(255, 255, 255, 0.16);
}

.pipeline li:not(:last-child)::after {
  position: absolute;
  z-index: 2;
  top: 94px;
  right: -10px;
  display: grid;
  width: 20px;
  height: 20px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  color: var(--green-neon);
  background: var(--ink);
  content: "→";
  font-size: 10px;
  place-items: center;
}

.pipeline-number {
  color: rgba(255, 255, 255, 0.35);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
  letter-spacing: 0.08em;
}

.pipeline-icon {
  display: grid;
  width: 52px;
  height: 52px;
  margin: 26px 0 24px;
  border: 1px solid rgba(139, 236, 188, 0.35);
  border-radius: 15px;
  color: var(--green-neon);
  background: rgba(139, 236, 188, 0.07);
  place-items: center;
}

.pipeline-icon svg {
  width: 24px;
  height: 24px;
}

.pipeline h3 {
  margin: 0 0 8px;
  font-size: 15px;
}

.pipeline p {
  min-height: 38px;
  margin: 0 0 20px;
  color: rgba(255, 255, 255, 0.47);
  font-size: 10px;
  line-height: 1.7;
}

.pipeline b {
  color: rgba(255, 255, 255, 0.7);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.inbound-section {
  padding: 105px 0;
}

.inbound-card {
  position: relative;
  display: grid;
  min-height: 480px;
  padding: 64px 68px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  color: var(--white);
  background: var(--green);
  grid-template-columns: 0.95fr 1.05fr;
  gap: 64px;
  align-items: center;
}

.inbound-card::before,
.inbound-card::after {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 50%;
  content: "";
}

.inbound-card::before {
  top: -180px;
  right: -40px;
  width: 520px;
  height: 520px;
}

.inbound-card::after {
  right: 80px;
  bottom: -260px;
  width: 560px;
  height: 560px;
}

.eyebrow-light {
  color: var(--green-neon);
}

.inbound-copy {
  position: relative;
  z-index: 2;
}

.inbound-copy h2 {
  margin: 18px 0 20px;
  font-size: clamp(34px, 4vw, 49px);
  letter-spacing: -0.065em;
  line-height: 1.2;
}

.inbound-copy > p:not(.eyebrow) {
  margin: 0;
  color: rgba(255, 255, 255, 0.66);
  font-size: 13px;
  line-height: 1.9;
}

.email-address-box {
  display: flex;
  margin-top: 31px;
  padding: 15px 16px 15px 19px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 13px;
  align-items: center;
  justify-content: space-between;
  background: rgba(5, 34, 24, 0.25);
}

.email-address-box span {
  display: block;
  margin-bottom: 5px;
  color: rgba(255, 255, 255, 0.45);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.email-address-box strong {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  font-weight: 600;
}

.email-address-box button {
  display: inline-flex;
  height: 36px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 9px;
  align-items: center;
  gap: 6px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
  font-size: 9px;
}

.email-address-box button svg {
  width: 14px;
  height: 14px;
}

.mail-visual {
  position: relative;
  z-index: 2;
  perspective: 1000px;
}

.mail-window {
  padding: 0 24px 24px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 18px;
  background: rgba(10, 41, 31, 0.82);
  box-shadow: 0 30px 80px rgba(5, 24, 17, 0.3);
  transform: rotateY(-3deg) rotateX(1deg);
}

.mail-window-head {
  display: flex;
  height: 48px;
  margin-bottom: 14px;
  align-items: center;
  gap: 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.mail-window-head i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
}

.mail-window-head i:first-child {
  background: var(--orange);
}

.mail-window-head span {
  margin-left: auto;
  color: rgba(255, 255, 255, 0.35);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
  letter-spacing: 0.1em;
}

.mail-row {
  display: grid;
  min-height: 37px;
  padding: 7px 3px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  grid-template-columns: 66px 1fr;
  align-items: center;
}

.mail-row span {
  color: rgba(255, 255, 255, 0.36);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
}

.mail-row strong {
  overflow: hidden;
  font-size: 10px;
  font-weight: 550;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mail-body {
  display: flex;
  min-height: 84px;
  padding: 23px 4px;
  flex-direction: column;
  gap: 9px;
}

.mail-body i {
  display: block;
  width: 92%;
  height: 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.12);
}

.mail-body i:nth-child(2) {
  width: 75%;
}

.mail-body i:nth-child(3) {
  width: 48%;
}

.mail-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
}

.mail-actions span {
  padding: 10px 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.48);
  background: rgba(255, 255, 255, 0.035);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
  text-align: center;
}

.mail-actions b {
  margin-right: 4px;
  color: rgba(255, 255, 255, 0.3);
}

.mail-actions .mail-action-active {
  border-color: rgba(139, 236, 188, 0.45);
  color: var(--green-neon);
  background: rgba(139, 236, 188, 0.08);
}

.stack-section {
  padding: 45px 0 120px;
}

.stack-heading {
  color: var(--ink);
}

.outline-link {
  display: inline-flex;
  width: fit-content;
  min-height: 43px;
  padding: 0 16px;
  align-items: center;
  justify-self: end;
  gap: 20px;
  border: 1px solid var(--line-dark);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}

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

.stack-card {
  min-height: 320px;
  padding: 25px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease;
}

.stack-card:hover {
  border-color: var(--line-dark);
  box-shadow: var(--shadow-sm);
  transform: translateY(-3px);
}

.stack-card-featured {
  border-color: var(--ink);
  color: var(--white);
  background: var(--ink);
}

.stack-code {
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.stack-card-featured .stack-code {
  color: rgba(255, 255, 255, 0.4);
}

.stack-symbol {
  position: relative;
  width: 66px;
  height: 66px;
  margin: 34px 0 28px;
}

.worker-symbol i {
  position: absolute;
  display: block;
  width: 34px;
  height: 34px;
  border: 1px solid var(--green-neon);
  border-radius: 8px;
  transform: rotate(45deg);
}

.worker-symbol i:nth-child(1) {
  top: 4px;
  left: 4px;
}

.worker-symbol i:nth-child(2) {
  top: 20px;
  left: 20px;
}

.worker-symbol i:nth-child(3) {
  top: 4px;
  left: 36px;
  border-color: var(--orange);
}

.database-symbol i {
  position: absolute;
  left: 7px;
  width: 52px;
  height: 22px;
  border: 1px solid var(--green);
  border-radius: 50%;
}

.database-symbol i:nth-child(1) {
  top: 5px;
  background: var(--green-light);
}

.database-symbol i:nth-child(2) {
  top: 21px;
}

.database-symbol i:nth-child(3) {
  top: 37px;
}

.queue-symbol i {
  position: absolute;
  left: 4px;
  width: 56px;
  height: 14px;
  border-radius: 5px;
  background: var(--paper-deep);
}

.queue-symbol i::after {
  position: absolute;
  top: 4px;
  right: 6px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--orange);
  content: "";
}

.queue-symbol i:nth-child(1) {
  top: 4px;
}

.queue-symbol i:nth-child(2) {
  top: 25px;
}

.queue-symbol i:nth-child(3) {
  top: 46px;
}

.mail-symbol {
  width: 63px;
  height: 45px;
  margin-top: 40px;
  border: 1px solid var(--green);
  border-radius: 8px;
}

.mail-symbol::before,
.mail-symbol::after {
  position: absolute;
  top: 6px;
  width: 37px;
  height: 1px;
  background: var(--green);
  content: "";
}

.mail-symbol::before {
  left: 1px;
  transform: rotate(34deg);
}

.mail-symbol::after {
  right: 1px;
  transform: rotate(-34deg);
}

.mail-symbol i {
  position: absolute;
  right: -5px;
  bottom: -5px;
  width: 14px;
  height: 14px;
  border: 3px solid var(--surface);
  border-radius: 50%;
  background: var(--orange);
}

.stack-card h3 {
  margin: 0 0 13px;
  font-size: 17px;
  letter-spacing: -0.035em;
}

.stack-card p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.8;
}

.stack-card-featured p {
  color: rgba(255, 255, 255, 0.55);
}

.status-line {
  display: flex;
  margin-top: 24px;
  align-items: center;
  gap: 7px;
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.status-line span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
}

.stack-card-featured .status-line {
  color: rgba(255, 255, 255, 0.4);
}

.stack-card-featured .status-line span {
  background: var(--green-neon);
}

.stack-card-wide {
  display: grid;
  min-height: 220px;
  grid-column: 1 / -1;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  overflow: hidden;
}

.stack-card-wide > div:first-child {
  max-width: 500px;
}

.stack-card-wide h3 {
  margin-top: 22px;
  font-size: 24px;
}

.wide-card-visual {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 34px;
}

.wide-card-visual > i {
  width: 90px;
  height: 1px;
  background: repeating-linear-gradient(90deg, var(--line-dark) 0 5px, transparent 5px 10px);
}

.shield-shape,
.archive-shape {
  display: grid;
  width: 86px;
  height: 86px;
  border: 1px solid var(--green);
  color: var(--green);
  background: var(--green-light);
  place-items: center;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 20px;
  font-weight: 800;
}

.shield-shape {
  border-radius: 42% 42% 55% 55%;
}

.archive-shape {
  border-color: var(--orange);
  border-radius: 50%;
  color: var(--orange);
  background: var(--orange-soft);
}

.cta-section {
  display: flex;
  padding: 72px 0;
  border-top: 1px solid var(--line-dark);
  align-items: flex-end;
  justify-content: space-between;
}

.cta-section h2 {
  margin: 15px 0 0;
  font-size: clamp(35px, 4vw, 52px);
  letter-spacing: -0.065em;
  line-height: 1.18;
}

.cta-actions {
  display: flex;
  gap: 10px;
}

.primary-link,
.secondary-link {
  display: inline-flex;
  min-height: 49px;
  padding: 0 20px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  align-items: center;
  gap: 24px;
  font-size: 11px;
  font-weight: 750;
}

.primary-link {
  color: var(--white);
  background: var(--ink);
}

.secondary-link {
  background: transparent;
}

.site-footer {
  display: flex;
  min-height: 104px;
  border-top: 1px solid var(--line-dark);
  align-items: center;
  justify-content: space-between;
}

.brand-footer {
  font-size: 14px;
}

.brand-footer .brand-mark {
  width: 24px;
  height: 24px;
}

.site-footer > p {
  color: var(--muted-light);
  font-size: 9px;
}

.site-footer > span {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
  text-transform: uppercase;
}

.site-footer > span i,
.sync-label i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(23, 99, 74, 0.1);
}

.site-footer > span.offline i {
  background: var(--red);
}

.toast {
  position: fixed;
  z-index: 100;
  right: 24px;
  bottom: 24px;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 10px;
  color: var(--white);
  background: var(--ink);
  box-shadow: var(--shadow-lg);
  font-size: 11px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.toast.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Operations console */
.console-page {
  min-height: 100vh;
  background: #eeece6;
}

.console-shell {
  display: grid;
  min-height: 100vh;
  grid-template-columns: 222px minmax(0, 1fr);
}

.console-sidebar {
  position: sticky;
  top: 0;
  display: flex;
  height: 100vh;
  padding: 24px 18px 18px;
  flex-direction: column;
  color: var(--white);
  background: var(--ink);
}

.brand-console {
  padding: 0 8px 25px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.11);
  font-size: 14px;
}

.brand-console .brand-mark {
  width: 25px;
  height: 25px;
}

.sidebar-label {
  margin: 25px 9px 10px;
  color: rgba(255, 255, 255, 0.3);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.console-nav {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.console-nav a {
  display: flex;
  min-height: 42px;
  padding: 0 11px;
  border-radius: 9px;
  align-items: center;
  gap: 10px;
  color: rgba(255, 255, 255, 0.53);
  font-size: 10px;
  font-weight: 650;
}

.console-nav a:hover,
.console-nav a.active {
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.console-nav a.active {
  box-shadow: inset 2px 0 var(--green-neon);
}

.console-nav svg {
  width: 17px;
  height: 17px;
}

.console-nav a > span {
  display: grid;
  min-width: 20px;
  height: 18px;
  margin-left: auto;
  padding: 0 5px;
  border-radius: 999px;
  color: var(--ink);
  background: var(--green-neon);
  place-items: center;
  font-size: 8px;
  font-weight: 800;
}

.sidebar-services {
  margin-top: 16px;
}

.sidebar-services ul {
  margin: 0;
  padding: 0 9px;
  list-style: none;
}

.sidebar-services li {
  display: grid;
  min-height: 31px;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.46);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
}

.sidebar-services li > span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--green-neon);
  box-shadow: 0 0 0 3px rgba(139, 236, 188, 0.07);
}

.sidebar-services li b {
  color: rgba(255, 255, 255, 0.27);
  font-weight: 500;
}

.sidebar-user {
  display: flex;
  margin-top: auto;
  padding: 15px 8px 3px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  align-items: center;
  gap: 9px;
}

.sidebar-user > span {
  display: grid;
  width: 31px;
  height: 31px;
  flex: 0 0 auto;
  border-radius: 9px;
  color: var(--ink);
  background: var(--orange);
  place-items: center;
  font-size: 11px;
  font-weight: 800;
}

.sidebar-user div {
  min-width: 0;
}

.sidebar-user strong,
.sidebar-user small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-user strong {
  max-width: 135px;
  font-size: 8px;
  font-weight: 650;
}

.sidebar-user small {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.32);
  font-size: 7px;
}

.console-main {
  min-width: 0;
}

.console-topbar {
  display: flex;
  min-height: 80px;
  padding: 0 34px;
  border-bottom: 1px solid var(--line);
  align-items: center;
  justify-content: space-between;
  background: rgba(251, 250, 246, 0.76);
  backdrop-filter: blur(16px);
}

.console-topbar p {
  margin: 0 0 4px;
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.console-topbar h1 {
  margin: 0;
  font-size: 19px;
  letter-spacing: -0.04em;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sync-label {
  display: flex;
  margin-right: 8px;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
  text-transform: uppercase;
}

.sync-label.syncing i {
  animation: pulse 700ms ease infinite alternate;
}

.topbar-actions button,
.topbar-actions a {
  display: inline-flex;
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line-dark);
  border-radius: 8px;
  align-items: center;
  gap: 6px;
  background: var(--surface);
  cursor: pointer;
  font-size: 9px;
  font-weight: 650;
}

.topbar-actions button:disabled {
  opacity: 0.5;
}

.topbar-actions svg {
  width: 14px;
  height: 14px;
}

.console-content {
  padding: 34px;
}

.console-section-head {
  display: flex;
  margin-bottom: 21px;
  align-items: flex-end;
  justify-content: space-between;
}

.console-section-head h2,
.inbox-head h2 {
  margin: 7px 0 0;
  font-size: 23px;
  letter-spacing: -0.045em;
}

.console-section-head > p {
  margin: 0;
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.metric-card {
  position: relative;
  min-height: 150px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
}

.metric-card > span {
  display: block;
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
}

.metric-card > strong {
  display: block;
  margin: 9px 0 7px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 30px;
  letter-spacing: -0.06em;
}

.metric-card > small {
  color: var(--muted-light);
  font-size: 8px;
}

.metric-card > small b {
  color: var(--green);
}

.metric-icon {
  position: absolute;
  top: 16px;
  right: 16px;
  display: grid;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: var(--green);
  background: var(--paper);
  place-items: center;
}

.metric-icon svg {
  width: 17px;
  height: 17px;
}

.metric-primary {
  border-color: var(--ink);
  color: var(--white);
  background: var(--ink);
}

.metric-primary > span,
.metric-primary > small {
  color: rgba(255, 255, 255, 0.48);
}

.metric-primary > small b {
  color: var(--green-neon);
}

.metric-primary .metric-icon {
  border-color: rgba(255, 255, 255, 0.13);
  color: var(--green-neon);
  background: rgba(255, 255, 255, 0.06);
}

.inbox-panel {
  margin-top: 23px;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: var(--surface);
}

.inbox-head {
  display: flex;
  min-height: 82px;
  padding: 18px 21px;
  border-bottom: 1px solid var(--line);
  align-items: center;
  justify-content: space-between;
}

.inbox-controls,
.filter-group {
  display: flex;
  align-items: center;
}

.inbox-controls {
  gap: 9px;
}

.filter-group {
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--paper);
}

.filter-group button {
  height: 29px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  font-size: 8px;
  font-weight: 650;
}

.filter-group button.active {
  color: var(--ink);
  background: var(--white);
  box-shadow: 0 2px 7px rgba(22, 33, 27, 0.08);
}

.status-filter select,
.detail-status-select select {
  height: 37px;
  padding: 0 30px 0 10px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--white);
  font-size: 8px;
}

.inbox-layout {
  display: grid;
  min-height: 500px;
  grid-template-columns: minmax(440px, 0.95fr) minmax(380px, 1.05fr);
}

.thread-list-wrap {
  min-width: 0;
  border-right: 1px solid var(--line);
}

.thread-columns {
  display: grid;
  height: 33px;
  padding: 0 16px;
  border-bottom: 1px solid var(--line);
  grid-template-columns: 1fr 90px;
  align-items: center;
  color: var(--muted-light);
  background: rgba(242, 239, 231, 0.55);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 6px;
  font-weight: 700;
  letter-spacing: 0.13em;
}

.thread-columns span:last-child {
  text-align: right;
}

.thread-list {
  max-height: 620px;
  overflow: auto;
}

.thread-row {
  display: grid;
  width: 100%;
  min-height: 104px;
  padding: 14px 16px;
  border: 0;
  border-bottom: 1px solid var(--line);
  grid-template-columns: minmax(0, 1fr) 90px;
  align-items: center;
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition: background 130ms ease;
}

.thread-row:hover,
.thread-row.selected {
  background: #f5f3ed;
}

.thread-row.selected {
  box-shadow: inset 3px 0 var(--green);
}

.thread-identity {
  display: flex;
  min-width: 0;
  align-items: flex-start;
  gap: 11px;
}

.thread-avatar {
  display: grid;
  width: 35px;
  height: 35px;
  flex: 0 0 auto;
  border-radius: 10px;
  color: var(--green);
  background: var(--green-light);
  place-items: center;
  font-size: 10px;
  font-weight: 800;
}

.thread-avatar.source-email {
  color: var(--orange);
  background: var(--orange-soft);
}

.thread-names {
  min-width: 0;
  flex: 1;
}

.thread-name-line {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.thread-name-line strong {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.thread-name-line time {
  flex: 0 0 auto;
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
}

.thread-subject {
  display: flex;
  min-width: 0;
  margin: 5px 0 4px;
  align-items: center;
  gap: 6px;
  overflow: hidden;
  font-size: 9px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.channel-tag {
  padding: 2px 4px;
  border-radius: 3px;
  color: var(--green);
  background: var(--green-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 6px;
  letter-spacing: 0.05em;
}

.channel-email {
  color: var(--orange);
  background: var(--orange-soft);
}

.thread-preview {
  overflow: hidden;
  margin: 0;
  color: var(--muted-light);
  font-size: 8px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.thread-status-wrap {
  display: flex;
  align-items: flex-end;
  flex-direction: column;
  gap: 5px;
}

.status-badge {
  display: inline-flex;
  min-height: 21px;
  padding: 0 7px;
  border-radius: 999px;
  align-items: center;
  color: var(--blue);
  background: var(--blue-soft);
  font-size: 7px;
  font-weight: 700;
}

.status-new {
  color: var(--orange);
  background: var(--orange-soft);
}

.status-waiting {
  color: #7a6516;
  background: #f5efcf;
}

.status-resolved {
  color: var(--green);
  background: var(--green-light);
}

.thread-status-wrap small {
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 6px;
}

.delivery-warning {
  color: var(--red);
  font-size: 6px;
  font-weight: 700;
}

.list-loading,
.list-empty,
.list-error {
  display: flex;
  min-height: 430px;
  padding: 30px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--muted-light);
  text-align: center;
}

.list-loading {
  gap: 14px;
  font-size: 9px;
}

.list-loading i {
  width: 20px;
  height: 20px;
  border: 2px solid var(--line);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}

.list-empty strong {
  color: var(--ink);
  font-size: 13px;
}

.list-empty p {
  max-width: 290px;
  margin: 9px 0 18px;
  font-size: 9px;
  line-height: 1.7;
}

.list-empty a {
  padding-bottom: 2px;
  border-bottom: 1px solid var(--ink);
  color: var(--ink);
  font-size: 8px;
  font-weight: 700;
}

.list-error {
  color: var(--red);
  font-size: 10px;
}

.thread-detail {
  min-width: 0;
  max-height: 653px;
  overflow: auto;
  background: #faf9f5;
}

.detail-empty {
  display: flex;
  min-height: 500px;
  padding: 30px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.detail-empty-icon {
  display: grid;
  width: 58px;
  height: 58px;
  margin-bottom: 17px;
  border: 1px solid var(--line);
  border-radius: 17px;
  color: var(--green);
  background: var(--paper);
  place-items: center;
}

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

.detail-empty h3 {
  margin: 0 0 7px;
  font-size: 14px;
}

.detail-empty p {
  max-width: 260px;
  margin: 0;
  color: var(--muted-light);
  font-size: 9px;
  line-height: 1.7;
}

.detail-head {
  display: flex;
  padding: 21px;
  border-bottom: 1px solid var(--line);
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  background: var(--white);
}

.detail-reference {
  color: var(--green);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0.07em;
}

.detail-title h3 {
  margin: 7px 0 5px;
  font-size: 16px;
  letter-spacing: -0.035em;
}

.detail-title p {
  margin: 0;
  color: var(--muted);
  font-size: 8px;
}

.detail-contact-grid {
  display: grid;
  padding: 13px 21px;
  border-bottom: 1px solid var(--line);
  grid-template-columns: repeat(3, 1fr);
  background: rgba(242, 239, 231, 0.55);
}

.detail-contact-grid div {
  padding: 0 13px;
  border-right: 1px solid var(--line);
}

.detail-contact-grid div:first-child {
  padding-left: 0;
}

.detail-contact-grid div:last-child {
  border: 0;
}

.detail-contact-grid span,
.detail-contact-grid strong {
  display: block;
}

.detail-contact-grid span {
  margin-bottom: 4px;
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 6px;
  letter-spacing: 0.1em;
}

.detail-contact-grid strong {
  overflow: hidden;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-stream {
  display: flex;
  padding: 21px;
  flex-direction: column;
  gap: 12px;
}

.message-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--white);
}

.message-outbound {
  margin-left: 24px;
  border-color: #bcd9cc;
  background: #f5fbf8;
}

.message-inbound {
  margin-right: 24px;
}

.message-card-head {
  display: flex;
  margin-bottom: 11px;
  align-items: flex-start;
  gap: 9px;
}

.message-direction {
  display: inline-flex;
  min-height: 20px;
  padding: 0 6px;
  border-radius: 5px;
  align-items: center;
  color: var(--orange);
  background: var(--orange-soft);
  font-size: 7px;
  font-weight: 700;
}

.direction-outbound {
  color: var(--green);
  background: var(--green-light);
}

.message-meta {
  min-width: 0;
}

.message-meta strong,
.message-meta time {
  display: block;
}

.message-meta strong {
  overflow: hidden;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-meta time {
  margin-top: 3px;
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 6px;
}

.message-body {
  margin: 0;
  color: var(--ink-soft);
  font-size: 9px;
  line-height: 1.75;
  white-space: pre-wrap;
  word-break: break-word;
}

.message-foot {
  display: flex;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  align-items: center;
  gap: 7px;
  color: var(--muted-light);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 6px;
}

.delivery-state {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.delivery-state::before {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--muted-light);
  content: "";
}

.delivery-sent,
.delivery-received {
  color: var(--green);
}

.delivery-sent::before,
.delivery-received::before {
  background: var(--green);
}

.delivery-failed,
.message-error-code {
  color: var(--red);
}

.delivery-failed::before {
  background: var(--red);
}

.message-error-code {
  margin-left: auto;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes pulse {
  to {
    opacity: 0.25;
    transform: scale(0.8);
  }
}

@keyframes successIn {
  from {
    opacity: 0;
    transform: scale(0.7) rotate(-8deg);
  }
}

@media (max-width: 1050px) {
  .hero {
    grid-template-columns: minmax(0, 0.92fr) minmax(430px, 1fr);
    gap: 42px;
  }

  .pipeline li {
    padding-inline: 16px;
  }

  .inbound-card {
    padding: 54px 46px;
    gap: 38px;
  }

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

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

  .inbox-layout {
    grid-template-columns: minmax(390px, 0.9fr) minmax(350px, 1.1fr);
  }
}

@media (max-width: 860px) {
  :root {
    --shell: min(100% - 32px, 720px);
  }

  .site-nav > a:not(.nav-console) {
    display: none;
  }

  .hero {
    padding-top: 58px;
    grid-template-columns: 1fr;
  }

  .hero-copy {
    max-width: 650px;
  }

  .form-stage {
    width: min(100%, 560px);
    margin-inline: auto;
  }

  .section-heading {
    grid-template-columns: 1fr;
    gap: 22px;
  }

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

  .pipeline li:nth-child(2n) {
    border-right: 1px solid rgba(255, 255, 255, 0.16);
  }

  .pipeline li:last-child {
    grid-column: 1 / -1;
  }

  .pipeline li:nth-child(2)::after,
  .pipeline li:nth-child(4)::after {
    display: none;
  }

  .inbound-card {
    grid-template-columns: 1fr;
  }

  .mail-visual {
    max-width: 560px;
  }

  .cta-section {
    align-items: flex-start;
    flex-direction: column;
    gap: 32px;
  }

  .console-shell {
    grid-template-columns: 70px minmax(0, 1fr);
  }

  .console-sidebar {
    padding-inline: 10px;
  }

  .brand-console > span:last-child,
  .sidebar-label,
  .console-nav a:not(.active) span,
  .console-nav a {
    font-size: 0;
  }

  .brand-console {
    justify-content: center;
    padding-inline: 0;
  }

  .console-nav a {
    justify-content: center;
  }

  .console-nav svg {
    width: 19px;
    height: 19px;
  }

  .console-nav a > span {
    position: absolute;
    margin: -22px 0 0 22px;
    min-width: 14px;
    height: 14px;
    font-size: 6px;
  }

  .sidebar-services,
  .sidebar-user div {
    display: none;
  }

  .sidebar-user {
    justify-content: center;
    padding-inline: 0;
  }

  .console-content {
    padding: 22px;
  }

  .inbox-layout {
    grid-template-columns: 1fr;
  }

  .thread-list-wrap {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .thread-detail {
    max-height: none;
  }
}

@media (max-width: 620px) {
  :root {
    --shell: calc(100% - 24px);
  }

  .site-header {
    min-height: 72px;
  }

  .brand {
    font-size: 14px;
  }

  .nav-console {
    min-height: 36px;
    padding-inline: 11px;
    font-size: 10px;
  }

  .hero {
    padding: 46px 0 66px;
  }

  .hero h1 {
    font-size: clamp(37px, 10.8vw, 45px);
  }

  .form-orbit {
    display: none;
  }

  .hero-lead {
    font-size: 14px;
  }

  .hero-stats div {
    min-width: 0;
    padding-right: 15px;
    flex: 1;
  }

  .hero-stats div + div {
    padding-left: 15px;
  }

  .hero-stats dt {
    font-size: 18px;
  }

  .hero-stats dd {
    font-size: 7px;
  }

  .contact-card {
    padding: 27px 19px 22px;
    border-radius: 22px;
  }

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

  .field-wide {
    grid-column: auto;
  }

  .flow-section {
    padding: 76px 0 84px;
  }

  .section-heading {
    margin-bottom: 42px;
  }

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

  .pipeline li,
  .pipeline li:nth-child(2n) {
    min-height: 240px;
    border-right: 1px solid rgba(255, 255, 255, 0.16);
  }

  .pipeline li:last-child {
    grid-column: auto;
  }

  .pipeline li::after {
    display: none;
  }

  .inbound-section {
    padding: 72px 0;
  }

  .inbound-card {
    padding: 38px 22px;
  }

  .email-address-box {
    align-items: flex-start;
    flex-direction: column;
    gap: 13px;
  }

  .email-address-box strong {
    display: block;
    max-width: 270px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .mail-window {
    padding-inline: 14px;
  }

  .mail-actions {
    grid-template-columns: 1fr;
  }

  .stack-section {
    padding-bottom: 80px;
  }

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

  .stack-card-wide {
    grid-template-columns: 1fr;
    gap: 35px;
  }

  .wide-card-visual > i {
    width: 36px;
  }

  .shield-shape,
  .archive-shape {
    width: 68px;
    height: 68px;
  }

  .cta-actions,
  .primary-link,
  .secondary-link {
    width: 100%;
  }

  .primary-link,
  .secondary-link {
    justify-content: space-between;
  }

  .site-footer {
    padding: 30px 0;
    align-items: flex-start;
    flex-direction: column;
    gap: 18px;
  }

  .console-shell {
    display: block;
  }

  .console-sidebar {
    position: relative;
    display: none;
  }

  .console-topbar {
    min-height: 70px;
    padding: 0 14px;
  }

  .console-topbar p,
  .sync-label,
  .topbar-actions button span,
  .topbar-actions a {
    display: none;
  }

  .console-content {
    padding: 18px 12px;
  }

  .console-section-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 7px;
  }

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

  .metric-card {
    min-height: 132px;
    padding: 14px;
  }

  .metric-card > strong {
    font-size: 25px;
  }

  .inbox-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 15px;
  }

  .inbox-controls {
    width: 100%;
    align-items: stretch;
    flex-direction: column;
  }

  .filter-group button {
    flex: 1;
  }

  .status-filter select {
    width: 100%;
  }

  .thread-columns {
    display: none;
  }

  .thread-row {
    grid-template-columns: minmax(0, 1fr) 73px;
    padding-inline: 11px;
  }

  .thread-avatar {
    width: 31px;
    height: 31px;
  }

  .detail-head {
    flex-direction: column;
  }

  .detail-status-select,
  .detail-status-select select {
    width: 100%;
  }

  .detail-contact-grid {
    grid-template-columns: 1fr;
    gap: 11px;
  }

  .detail-contact-grid div,
  .detail-contact-grid div:first-child {
    padding: 0 0 10px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .detail-contact-grid div:last-child {
    padding-bottom: 0;
    border-bottom: 0;
  }

  .message-stream {
    padding: 13px;
  }

  .message-inbound,
  .message-outbound {
    margin: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
