/* Основа сообщения → дополнительная переработка готового текста. */
.mrs-page {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  min-height: 100%;
  padding: 28px 42px 30px;
  background: #121c19;
  color: #f0f3e9;
  font-family: Inter, 'Helvetica Neue', Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
.mrs-page *, .mrs-page *::before, .mrs-page *::after { box-sizing: border-box; }
.mrs-page :where(h1, h2, h3, p, pre, blockquote) { margin: 0; }
.mrs-page :where(section, div, aside) { min-width: 0; }
.mrs-page code { font-family: Menlo, Consolas, 'Liberation Mono', monospace; }
.mrs-opening { margin-bottom: 25px; }
.mrs-kicker { color: #c2b8ff; font-size: 11px; font-weight: 500; letter-spacing: .13em; text-transform: uppercase; }
.mrs-opening h1 { margin-top: 9px; font-size: 64px; font-weight: 600; line-height: 1.03; letter-spacing: -.055em; }
.mrs-level { display: flex; align-items: center; gap: 12px; font-size: 24px; font-weight: 500; letter-spacing: -.035em; }
.mrs-level > span { display: grid; place-items: center; width: 31px; height: 31px; border-radius: 50%; color: #14271b; background: #d0f5a5; font-size: 12px; font-weight: 600; letter-spacing: 0; }
.mrs-inputs { display: grid; grid-template-columns: minmax(0, 1.7fr) 52px minmax(0, 1fr); margin-top: 16px; }
.mrs-source h3 { font-size: 23px; font-weight: 500; line-height: 1.2; letter-spacing: -.03em; }
.mrs-spintax h3 { color: #d0f5a5; }
.mrs-ai { display: flex; flex-direction: column; }
.mrs-ai h3 { color: #c2b8ff; }
.mrs-explain { margin-top: 7px !important; color: #b6c3b9; font-size: 15px; line-height: 1.4; }
.mrs-template { margin-top: 12px !important; padding: 13px 17px; border: 1px solid #40543f; border-radius: 12px; background: #1a2920; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; line-height: 1.85; }
.mrs-template code { font-size: inherit; }
.mrs-template b { color: #c2b8ff; font-weight: 600; }
.mrs-template span { color: #d0f5a5; }
.mrs-or { align-self: center; text-align: center; color: #a2b0a8; font-family: Georgia, serif; font-size: 18px; font-style: italic; }
.mrs-prompt { display: flex; align-items: center; flex: 1; margin-top: 12px !important; padding: 17px 22px; border: 1px solid #665b83; border-radius: 12px; background: #28263a; color: #ece7ff; font-size: 21px; line-height: 1.4; letter-spacing: -.02em; }
.mrs-bridge { position: relative; height: 44px; margin: 11px 0 8px; color: #708a64; }
.mrs-bridge > svg { display: block; width: 100%; height: 44px; }
.mrs-bridge > span { position: absolute; top: 14px; left: 50%; transform: translateX(-50%); padding: 0 12px; background: #121c19; color: #b6c3b9; font-size: 11px; line-height: 15px; white-space: nowrap; }
.mrs-second { padding-top: 9px; }
.mrs-second-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.mrs-second .mrs-level > span { background: #c2b8ff; color: #2c253d; }
.mrs-command { display: flex; align-items: center; gap: 9px; color: #a2b0a8; font-size: 13px; }
.mrs-command code { padding: 7px 11px; border: 1px solid #625878; border-radius: 7px; color: #c2b8ff; font-size: 16px; }
.mrs-purpose { margin-top: 12px !important; color: #b6c3b9; font-size: 16px; line-height: 1.45; }
.mrs-purpose strong { color: #f0f3e9; font-weight: 500; }
.mrs-rewrite { display: grid; grid-template-columns: minmax(0, 1fr) 32px minmax(0, 1fr); gap: 24px; align-items: center; margin-top: 17px; }
.mrs-rewrite > div { padding: 0 16px; border-left: 2px solid #48564d; }
.mrs-rewrite > div:last-child { padding: 12px 20px; border-color: #c2b8ff; border-radius: 0 10px 10px 0; background: #222330; }
.mrs-caption { display: block; margin-bottom: 6px; color: #a2b0a8; font-size: 10px; font-weight: 500; letter-spacing: .09em; text-transform: uppercase; }
.mrs-rewrite p { font-size: 23px; line-height: 1.3; letter-spacing: -.03em; }
.mrs-rewrite > div:last-child p { color: #c2b8ff; }
.mrs-rewrite > svg { display: block; width: 32px; height: 20px; color: #849380; }
.mrs-memory { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 24px; align-items: start; margin-top: 21px; padding-top: 15px; border-top: 1px solid #35463e; }
.mrs-memory h3 { color: #efc4d8; font-size: 18px; font-weight: 500; line-height: 1.4; letter-spacing: -.025em; }
.mrs-memory p { color: #b6c3b9; font-size: 15px; line-height: 1.45; }

@container reader (max-width: 1000px) {
  .mrs-page { padding: 24px 28px; }
  .mrs-opening h1 { font-size: 52px; }
  .mrs-inputs { grid-template-columns: minmax(0, 1.6fr) 40px minmax(0, 1fr); }
  .mrs-rewrite { gap: 16px; }
}

@container reader (max-width: 720px) {
  .mrs-page { padding: 24px 20px; }
  .mrs-opening h1 { font-size: clamp(26px, 6.4cqw, 42px); }
  .mrs-inputs, .mrs-rewrite, .mrs-memory { grid-template-columns: minmax(0, 1fr); }
  .mrs-inputs { gap: 16px; }
  .mrs-join-inputs { display: none; }
  .mrs-second-heading { flex-direction: column; align-items: flex-start; gap: 12px; }
  .mrs-rewrite { gap: 18px; }
  .mrs-rewrite > svg { justify-self: center; transform: rotate(90deg); }
  .mrs-memory { gap: 5px; }
}
