@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("assets/fonts/newsreader-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("assets/fonts/source-sans-3-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("assets/fonts/newsreader-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}

@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("assets/fonts/source-sans-3-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}

@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("assets/fonts/vazirmatn-arabic.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("assets/fonts/vazirmatn-arabic.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("assets/fonts/ibm-plex-mono-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  /* Dusk palette */
  --dusk-bg: #1E1A24;
  --dusk-fg: #EDE6DA;
  --dusk-muted: #A9A2B5;
  --dusk-accent: #E0A93B;
  --dusk-line: #4A4357;
  --dusk-accent-hover: #EBB852;
  --dusk-accent-active: #C99228;
  --dusk-accent-text: #E0A93B;
  --dusk-accent-tint: rgba(224, 169, 59, 0.14);
  --dusk-accent-tint-strong: rgba(224, 169, 59, 0.24);
  --dusk-surface: #282331;
  --dusk-surface-card: #2E2838;
  --dusk-input-bg: #26212E;
  --dusk-input-border: #635B73;
  --dusk-focus-ring: #E0A93B;
  --dusk-btn-primary-fg: #1E1A24;
  --dusk-shadow: rgba(18, 14, 24, 0.42);
  --dusk-veil: rgba(30, 26, 36, 0.36);

  /* Dawn palette */
  --dawn-bg: #F7F0E4;
  --dawn-fg: #2B2430;
  --dawn-muted: #6B6475;
  --dawn-accent: #C98A0B;
  --dawn-sage: #7A8B6A;
  --dawn-clay: #B5654A;
  --dawn-line: #DDD2BF;
  --dawn-accent-hover: #D99B1C;
  --dawn-accent-active: #C08209;
  --dawn-accent-text: #8F5E00;
  --dawn-accent-tint: rgba(201, 138, 11, 0.13);
  --dawn-accent-tint-strong: rgba(201, 138, 11, 0.22);
  --dawn-sage-tint: rgba(122, 139, 106, 0.16);
  --dawn-clay-tint: rgba(181, 101, 74, 0.14);
  --dawn-surface: #EFE6D5;
  --dawn-surface-card: #FFFBF4;
  --dawn-input-bg: #FFFBF4;
  --dawn-input-border: #8E8478;
  --dawn-focus-ring: #2B2430;
  --dawn-btn-primary-fg: #2B2430;
  --dawn-shadow: rgba(43, 36, 48, 0.16);

  /* Active theme variables (start at Dusk, shift smoothly to Dawn at the boundary) */
  --bg: var(--dusk-bg);
  --fg: var(--dusk-fg);
  --muted: var(--dusk-muted);
  --accent: var(--dusk-accent);
  --line: var(--dusk-line);
  --sage: var(--dawn-sage);
  --clay: var(--dawn-clay);
  --accent-hover: var(--dusk-accent-hover);
  --accent-active: var(--dusk-accent-active);
  --accent-text: var(--dusk-accent-text);
  --accent-tint: var(--dusk-accent-tint);
  --accent-tint-strong: var(--dusk-accent-tint-strong);
  --sage-tint: var(--dawn-sage-tint);
  --clay-tint: var(--dawn-clay-tint);
  --surface: var(--dusk-surface);
  --surface-card: var(--dusk-surface-card);
  --input-bg: var(--dusk-input-bg);
  --input-border: var(--dusk-input-border);
  --focus-ring: var(--dusk-focus-ring);
  --btn-primary-fg: var(--dusk-btn-primary-fg);
  --card-shadow: var(--dusk-shadow);
  --plate-veil: var(--dusk-veil);
  --hero-lamp-glow: radial-gradient(circle, rgba(224, 169, 59, 0.11), rgba(224, 169, 59, 0) 68%);
  --tap-highlight: rgba(224, 169, 59, 0.35);
  --device-shadow: drop-shadow(0 24px 32px rgba(18, 14, 24, 0.42));
  --sim-device-shadow: drop-shadow(0 22px 34px rgba(43, 36, 48, 0.22)) drop-shadow(0 6px 12px rgba(43, 36, 48, 0.12));

  /* Internal phone preview palette (preserved unchanged across Dusk and Dawn) */
  --phone-cloth: #1c1612;
  --phone-paper: #f3e6d0;
  --phone-ember: #f2b15e;
  --phone-ember-hot: #f6c27a;
  --phone-ember-deep: #e8a84a;
  --phone-ash: #c4b5a2;
  --phone-ink: #1c1612;
  --phone-ink-soft: #3f362f;
  --phone-tick: #5c534a;
  --phone-hw: #3a322b;
  --phone-bezel: linear-gradient(155deg, rgba(243, 230, 208, 0.55), rgba(243, 230, 208, 0) 24%), linear-gradient(165deg, #6e5f52, #2a241f 26%, #14110e 60%, #3c332c);
  --phone-bezel-ring: rgba(243, 230, 208, 0.28);
  --phone-screen-bg: #100e0c;
  --phone-screen-ring: #0a0908;
  --phone-chat-head-bg: rgba(16, 13, 11, 0.94);
  --phone-hairline: rgba(243, 230, 208, 0.08);
  --phone-hairline-md: rgba(243, 230, 208, 0.14);
  --phone-hairline-lg: rgba(243, 230, 208, 0.22);
  --phone-hairline-xl: rgba(243, 230, 208, 0.38);
  --phone-avatar-bg: #6b4e34;
  --phone-chat-wall-bg: #16130f;
  --phone-chat-wall-img: radial-gradient(circle at 18% 0%, rgba(242, 177, 94, 0.06), transparent 32%), url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='72' viewBox='0 0 72 72'%3E%3Cpath d='M36 10c4 7 4 11 0 18-4-7-4-11 0-18zm0 34c4 7 4 11 0 18-4-7-4-11 0-18zM10 36c7-4 11-4 18 0-7 4-11 4-18 0zm34 0c7-4 11-4 18 0-7 4-11 4-18 0z' fill='%23f3e6d0' fill-opacity='.05'/%3E%3C/svg%3E");
  --phone-app-wall-bg: radial-gradient(ellipse at 50% -8%, rgba(242, 177, 94, 0.2), transparent 52%), #1c1612;
  --phone-scroll-thumb: rgba(242, 177, 94, 0.42);
  --phone-day-bg: rgba(20, 16, 13, 0.62);
  --phone-bubble-shadow: rgba(16, 13, 11, 0.22);
  --phone-bubble-in: #2c261f;
  --phone-playhead-out: rgba(28, 22, 18, 0.16);
  --phone-playhead-in: rgba(243, 230, 208, 0.16);
  --phone-photo-bg: #2a211b;
  --phone-card-bg: rgba(242, 177, 94, 0.1);
  --phone-card-border: rgba(242, 177, 94, 0.32);
  --phone-composer-fg: rgba(196, 181, 162, 0.82);
  --phone-home-bar: rgba(243, 230, 208, 0.42);
  --phone-app-head-bg: linear-gradient(180deg, rgba(242, 177, 94, 0.16), transparent 85%);
  --phone-sim-bg: #171310;
  --phone-sim-head-bg: linear-gradient(180deg, rgba(242, 177, 94, 0.14), rgba(23, 19, 16, 0.96));
  --phone-sim-plaque-bg: linear-gradient(180deg, rgba(242, 177, 94, 0.1), rgba(44, 38, 31, 0.65));
  --phone-sim-arch-ring: rgba(242, 177, 94, 0.45);
  --phone-sim-bar-bg: #14100d;
  --phone-sim-input-bg: #221c17;
  --phone-sim-mem-bg: #231d18;
  --phone-sim-tog-bg: #1b1511;
  --phone-sim-nd-bg: #26201a;
  --phone-sim-nd-hit: #3d2c19;
  --phone-sim-link: rgba(243, 230, 208, 0.24);
  --phone-sim-node-ring: rgba(243, 230, 208, 0.28);
  --phone-private: #6cc4b4;
  --phone-private-text: #bceae0;
  --phone-private-keep: #7ee0ce;
  --phone-private-bg: rgba(108, 196, 180, 0.06);
  --phone-private-tint: rgba(108, 196, 180, 0.12);
  --phone-private-border: rgba(108, 196, 180, 0.55);
  --phone-private-border-soft: rgba(108, 196, 180, 0.32);
  --phone-conflict: #e58a8a;
  --phone-conflict-bg: rgba(229, 138, 138, 0.1);
  --phone-conflict-border: rgba(229, 138, 138, 0.5);
  --phone-ember-tint-xs: rgba(242, 177, 94, 0.08);
  --phone-ember-tint-sm: rgba(242, 177, 94, 0.12);
  --phone-ember-tint-md: rgba(242, 177, 94, 0.2);
  --phone-ember-tint-lg: rgba(242, 177, 94, 0.22);
  --phone-ember-border: rgba(242, 177, 94, 0.48);
  --phone-ember-border-hi: rgba(242, 177, 94, 0.7);
  --phone-paper-tint-xs: rgba(243, 230, 208, 0.04);
  --phone-paper-tint-sm: rgba(243, 230, 208, 0.05);
  --phone-paper-border-xs: rgba(243, 230, 208, 0.1);
  --phone-paper-border-sm: rgba(243, 230, 208, 0.12);
  --phone-paper-border-md: rgba(243, 230, 208, 0.16);
  --phone-paper-border-lg: rgba(243, 230, 208, 0.18);
  --phone-paper-border-xl: rgba(243, 230, 208, 0.35);
  --phone-scroll-sim: rgba(242, 177, 94, 0.38);

  /* Sizing and typography tokens */
  --phone-h: clamp(480px, 64svh, 620px);
  --phone-w: max(320px, calc(var(--phone-h) * 9 / 19.5));
  --q-open: "\201C";
  --q-close: "\201D";
}

html[data-theme="dawn"] {
  color-scheme: light;
  --bg: var(--dawn-bg);
  --fg: var(--dawn-fg);
  --muted: var(--dawn-muted);
  --accent: var(--dawn-accent);
  --line: var(--dawn-line);
  --accent-hover: var(--dawn-accent-hover);
  --accent-active: var(--dawn-accent-active);
  --accent-text: var(--dawn-accent-text);
  --accent-tint: var(--dawn-accent-tint);
  --accent-tint-strong: var(--dawn-accent-tint-strong);
  --surface: var(--dawn-surface);
  --surface-card: var(--dawn-surface-card);
  --input-bg: var(--dawn-input-bg);
  --input-border: var(--dawn-input-border);
  --focus-ring: var(--dawn-focus-ring);
  --btn-primary-fg: var(--dawn-btn-primary-fg);
  --card-shadow: var(--dawn-shadow);
  --tap-highlight: var(--dawn-accent-tint-strong);
}

html:not(.js) .reframe,
html:not(.js) .became,
html:not(.js) .reply,
html:not(.js) .source,
html:not(.js) .how,
html:not(.js) .talk,
html:not(.js) footer {
  --bg: var(--dawn-bg);
  --fg: var(--dawn-fg);
  --muted: var(--dawn-muted);
  --accent: var(--dawn-accent);
  --line: var(--dawn-line);
  --accent-hover: var(--dawn-accent-hover);
  --accent-active: var(--dawn-accent-active);
  --accent-text: var(--dawn-accent-text);
  --accent-tint: var(--dawn-accent-tint);
  --accent-tint-strong: var(--dawn-accent-tint-strong);
  --surface: var(--dawn-surface);
  --surface-card: var(--dawn-surface-card);
  --input-bg: var(--dawn-input-bg);
  --input-border: var(--dawn-input-border);
  --focus-ring: var(--dawn-focus-ring);
  --btn-primary-fg: var(--dawn-btn-primary-fg);
  --card-shadow: var(--dawn-shadow);
  background: var(--bg);
  color: var(--fg);
}

html[lang="fa"] {
  --q-open: "\00AB";
  --q-close: "\00BB";
}

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

html {
  background: var(--bg);
  color: var(--fg);
  color-scheme: dark;
  transition: color 0.22s ease;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  transition: color 0.22s ease;
  font-family: "Source Sans 3", "Avenir Next", "Segoe UI", sans-serif;
  font-size: 1.125rem;
  font-weight: 400;
  line-height: 1.5;
  font-variant-numeric: lining-nums;
  padding:
    0
    max(clamp(1.25rem, 4vw, 3rem), env(safe-area-inset-right))
    max(2.5rem, env(safe-area-inset-bottom))
    max(clamp(1.25rem, 4vw, 3rem), env(safe-area-inset-left));
}

img,
svg,
video {
  max-width: 100%;
}

h1,
h2,
h3,
p {
  overflow-wrap: break-word;
}

:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

::selection {
  background: var(--accent);
  color: var(--btn-primary-fg);
}

[hidden] {
  display: none !important;
}

.skip {
  position: absolute;
  inset-inline-start: 1rem;
  top: -4rem;
  z-index: 5;
  background: var(--accent);
  color: var(--btn-primary-fg);
  padding: 0.55rem 0.8rem;
  text-decoration: none;
}

.skip:focus {
  top: 1rem;
}

.book {
  position: relative;
  width: min(76rem, 100%);
  margin-inline: auto;
}

.measure {
  width: min(42rem, 100%);
  margin-inline: auto;
}

.running {
  position: relative;
  z-index: 4;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  padding-top: max(1.15rem, env(safe-area-inset-top));
  padding-bottom: 0.75rem;
  font-size: 0.95rem;
}

.brand-wordmark {
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 560;
  font-size: 1.1rem;
  color: var(--fg);
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}

.running-mid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1.75rem;
}

.section-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.25rem;
}

.section-nav a {
  white-space: nowrap;
  flex-shrink: 0;
}

.langs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.9rem;
  font-size: 0.9rem;
  padding-inline-start: 1rem;
  border-inline-start: 1px solid var(--line);
}

.langs [aria-current] {
  color: var(--fg);
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-underline-offset: 0.3em;
}

.langs a {
  text-decoration: none;
  white-space: nowrap;
}

.running a {
  color: var(--muted);
  text-decoration: none;
}

.running a.brand-wordmark {
  color: var(--fg);
}

.running a:hover {
  color: var(--fg);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.running a.nav-cta {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0.45rem 1rem;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--btn-primary-fg);
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background-color 0.18s ease, border-color 0.18s ease, transform 0.1s ease;
}

.running a.nav-cta:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: var(--btn-primary-fg);
  text-decoration: none;
}

.running a.nav-cta:active {
  background: var(--accent-active);
  border-color: var(--accent-active);
  transform: translateY(1px);
}

.running a.nav-cta:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

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

.opening {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.5rem;
  align-items: center;
  align-content: center;
  align-content: safe center;
  justify-items: stretch;
  box-sizing: border-box;
  min-height: calc(100svh - 4rem);
  padding-top: 1.25rem;
  padding-bottom: 2rem;
}

.opening::before {
  content: "";
  position: absolute;
  z-index: 0;
  width: min(26rem, 78vw);
  height: min(26rem, 78vw);
  left: -5rem;
  top: 6%;
  background: var(--hero-lamp-glow);
  opacity: calc(1 - var(--dawn-progress, 0));
  pointer-events: none;
}

.opening > * {
  position: relative;
  z-index: 1;
}

.device {
  position: relative;
  flex: none;
  width: var(--phone-w);
  max-width: 100%;
  height: var(--phone-h);
  margin-inline: auto;
  direction: ltr;
  font-size: 15px;
  line-height: 1.35;
  color: var(--phone-paper);
  font-family: "Source Sans 3", "Avenir Next", "Segoe UI", sans-serif;
  filter: var(--device-shadow);
}

.device::before,
.device::after {
  content: "";
  position: absolute;
  width: 3px;
  background: var(--phone-hw);
  z-index: 2;
}

.device::before {
  left: -3px;
  top: 108px;
  height: 26px;
  border-radius: 2px 0 0 2px;
  box-shadow: 0 42px 0 var(--phone-hw), 0 74px 0 var(--phone-hw);
}

.device::after {
  right: -3px;
  top: 146px;
  height: 62px;
  border-radius: 0 2px 2px 0;
}

.device-frame {
  height: 100%;
  display: flex;
  flex-direction: column;
  border-radius: 42px;
  padding: 10px;
  background: var(--phone-bezel);
  box-shadow: inset 0 0 0 1px var(--phone-bezel-ring);
}

.device-screen {
  flex: 1 1 auto;
  min-height: 0;
  border-radius: 32px;
  overflow: hidden;
  background: var(--phone-screen-bg);
  display: flex;
  flex-direction: column;
  box-shadow: inset 0 0 0 2px var(--phone-screen-ring);
}

.device p {
  margin: 0;
}

.ear,
.status,
.chat-head,
.app-head,
.composer,
.home {
  flex: none;
}

.ear {
  width: 3.4em;
  height: 0.28em;
  margin: 0.55em auto 0.15em;
  border-radius: 1em;
  background: var(--phone-screen-ring);
}

.status {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.15em 0.95em 0.2em;
  font-size: 0.72em;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--phone-paper);
}

.status-icons {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
}

.chat-head {
  display: flex;
  align-items: center;
  gap: 0.55em;
  padding: 0.2em 0.75em 0.6em;
  background: var(--phone-chat-head-bg);
  border-bottom: 1px solid var(--phone-hairline);
}

.back {
  color: var(--phone-ash);
  flex: none;
}

.avatar {
  position: relative;
  overflow: hidden;
  width: 2.15em;
  height: 2.15em;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--phone-avatar-bg);
  color: var(--phone-paper);
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 1.05em;
  flex: none;
}

.avatar-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.chat-id {
  min-width: 0;
}

.who-name {
  font-size: 0.98em;
  font-weight: 650;
  font-weight: 600;
  line-height: 1.15;
}

.who-status {
  margin-top: 0.05em;
  color: var(--phone-ash);
  font-size: 0.75em;
  font-weight: 400;
  line-height: 1.2;
}

.thread {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  overflow-anchor: none;
  padding: 0.45em 0.55em 0.4em;
  scrollbar-width: none;
}

.thread::-webkit-scrollbar {
  display: none;
}

.thread-fill {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0.32em;
}

.app-wall .thread-fill {
  justify-content: flex-start;
  padding-top: 0.5em;
  padding-bottom: 0.9em;
  gap: 0.42em;
}

.thread:focus-visible {
  outline-offset: -3px;
}

.chat-wall {
  background-color: var(--phone-chat-wall-bg);
  background-image: var(--phone-chat-wall-img);
  background-size: auto, 72px 72px;
}

.app-wall {
  scrollbar-width: thin;
  scrollbar-color: var(--phone-scroll-thumb) transparent;
  background: var(--phone-app-wall-bg);
}

.app-wall::-webkit-scrollbar {
  display: block;
  width: 4px;
}

.app-wall::-webkit-scrollbar-thumb {
  background: var(--phone-scroll-thumb);
  border-radius: 4px;
}

.day {
  align-self: center;
  margin: 0.12em 0;
  padding: 0.1em 0.55em;
  border-radius: 0.7em;
  background: var(--phone-day-bg);
  color: var(--phone-ash);
  font-size: 0.72em;
  line-height: 1.45;
}

.bubble {
  max-width: 88%;
  padding: 0.42em 0.62em 0.36em;
  box-shadow: 0 1px 0 var(--phone-bubble-shadow);
}

.bubble.out {
  align-self: flex-end;
  background: var(--phone-paper);
  color: var(--phone-ink);
  border-radius: 0.95em 0.95em 0.26em 0.95em;
}

.bubble.in {
  align-self: flex-start;
  background: var(--phone-bubble-in);
  color: var(--phone-paper);
  border-radius: 0.95em 0.95em 0.95em 0.26em;
}

.msg {
  font-size: 0.92em;
  line-height: 1.35;
}

.meta {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin-top: 0.12em;
}

.ticks {
  width: 1.05em;
  height: 0.72em;
  color: var(--phone-tick);
  display: block;
}

.bubble.voice {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  column-gap: 0.4em;
  row-gap: 0.18em;
  align-items: center;
  min-width: 12.4em;
  padding: 0.45em 0.58em 0.38em;
}

.play-icon {
  grid-column: 1;
  grid-row: 1;
  display: flex;
}

.voice .pause {
  display: none;
}

.voice.is-playing .tri {
  display: none;
}

.voice.is-playing .pause {
  display: block;
}

.wave {
  grid-column: 2;
  grid-row: 1;
  width: 100%;
  height: 1.65em;
  display: block;
}

.voice.no-dur {
  min-width: 15.5em;
}

.voice.no-dur .wave {
  grid-column: 2 / -1;
}

.bubble.voice[role="button"] {
  cursor: pointer;
}

.dur {
  grid-column: 3;
  grid-row: 1;
  font-size: 0.74em;
  font-variant-numeric: tabular-nums;
  color: var(--phone-tick);
}

.bubble.in .dur {
  color: var(--phone-ash);
}

.playhead {
  grid-column: 1 / -1;
  grid-row: 2;
  height: 2px;
  background: var(--phone-playhead-out);
  border-radius: 2px;
  overflow: hidden;
}

.bubble.in .playhead {
  background: var(--phone-playhead-in);
}

.playhead-bar {
  display: block;
  height: 100%;
  width: 0;
  background: currentColor;
  opacity: 0.75;
}

.has-played .playhead-bar {
  width: 100%;
}

.bubble.voice .meta,
.bubble.voice .said {
  grid-column: 1 / -1;
}

.said {
  grid-row: 4;
  margin-top: 0.22em;
  font-size: 0.86em;
  line-height: 1.35;
}

.bubble.photo {
  padding: 0.2em 0.2em 0.28em;
}

.bubble.photo img {
  display: block;
  width: 12.4em;
  height: auto;
  border-radius: 0.65em;
  background: var(--phone-photo-bg);
}

.bubble.photo.in .caption {
  margin: 0.34em 0.38em 0.15em;
  font-size: 0.85em;
  line-height: 1.35;
  color: var(--phone-paper);
}

.bubble .speaker {
  grid-column: 1 / -1;
  grid-row: 1;
  align-self: start;
  justify-self: start;
  margin: 0 0 0.12em;
  color: var(--phone-tick);
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 0.78em;
}

.bubble.in .speaker {
  color: var(--phone-ember);
}

.bubble.voice:has(.speaker) .play-icon,
.bubble.voice:has(.speaker) .wave,
.bubble.voice:has(.speaker) .dur {
  grid-row: 2;
}

.bubble.voice:has(.speaker) .playhead {
  grid-row: 3;
}

.bubble.voice:has(.speaker) .said {
  grid-row: 4;
}

.phone-card {
  align-self: stretch;
  margin: 0.22em 0;
  padding: 0.52em 0.68em;
  background: var(--phone-card-bg);
  border: 1px solid var(--phone-card-border);
  border-radius: 0.75em;
}

.phone-card-title {
  font-size: 0.78em;
  font-weight: 600;
  color: var(--phone-ember-hot);
}

.phone-card-note {
  margin-top: 0.18em;
  font-size: 0.78em;
  line-height: 1.35;
  color: var(--phone-ash);
}

.composer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6em;
  margin: 0.15em 0.55em 0.1em;
  padding: 0.42em 0.7em;
  border-radius: 999px;
  background: var(--phone-hairline);
  color: var(--phone-composer-fg);
  font-size: 0.82em;
}

.home {
  width: 32%;
  height: 0.28em;
  margin: 0.4em auto 0.48em;
  border-radius: 1em;
  background: var(--phone-home-bar);
}

.app-head {
  display: flex;
  align-items: center;
  gap: 0.7em;
  padding: 0.15em 0.9em 0.7em;
  background: var(--phone-app-head-bg);
}

.app-id {
  min-width: 0;
}

.app-head .avatar {
  width: 2.9em;
  height: 2.9em;
  font-size: 1em;
}

.app-mark {
  color: var(--phone-ash);
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 0.75em;
}

.app-title {
  margin-top: 0.12em;
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 560;
  font-size: 1.22em;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.chip {
  display: inline-block;
  margin-top: 0.45em;
  padding: 0.16em 0.42em 0.18em;
  background: var(--phone-ember);
  color: var(--phone-ink);
  font-size: 0.68em;
  font-weight: 650;
  font-weight: 600;
  line-height: 1.3;
}

.source-card {
  align-self: flex-start;
  max-width: 94%;
  margin: 0.15em 0 0.1em;
  padding: 0.12em 0 0.12em 0.5em;
  border-left: 2px solid var(--phone-ember);
  color: var(--phone-ember-hot);
  font-size: 0.75em;
  line-height: 1.35;
}

.source-card p + p {
  margin-top: 0.35em;
}

.mem {
  display: grid;
  gap: 0.32em;
}

.mem p {
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 0.98em;
  line-height: 1.3;
}

.year {
  color: var(--phone-ember);
}

.rule {
  align-self: center;
  max-width: 12em;
  margin-top: 0.45em;
  text-align: center;
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 0.95em;
  line-height: 1.3;
  color: var(--phone-ember);
}

.wave rect {
  transform-box: fill-box;
  transform-origin: center;
}

.is-playing .wave rect {
  animation: speak 0.85s ease-in-out infinite;
}

.is-playing .wave rect:nth-child(odd) {
  animation-delay: 0.12s;
}

.is-playing .wave rect:nth-child(3n) {
  animation-delay: 0.24s;
}

.is-playing .wave rect:nth-child(4n) {
  animation-delay: 0.06s;
}

.voice.is-gentle.is-playing .wave rect {
  animation-duration: 1.45s;
}

.is-playing .playhead-bar {
  width: 0;
  animation: draw 2s linear forwards;
}

.voice.is-gentle.is-playing .playhead-bar {
  animation-duration: 2.6s;
}

@keyframes speak {
  0%,
  100% {
    transform: scaleY(0.4);
  }

  50% {
    transform: scaleY(1);
  }
}

@keyframes draw {
  from {
    width: 0;
  }

  to {
    width: 100%;
  }
}

@keyframes arrive {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.hero-copy {
  max-width: 38rem;
}

.payoff {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.85rem;
}

.sent,
.unanswered {
  margin: 0;
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 460;
  font-size: clamp(1.25rem, 1.8vw, 1.55rem);
  line-height: 1.2;
}

.sent {
  color: var(--muted);
}

.unanswered {
  color: var(--accent-text);
}

h1 {
  margin: 0;
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 560;
  font-size: clamp(2.35rem, 4.6vw, 3.85rem);
  line-height: 1.04;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

.tagline {
  margin: 0.85rem 0 0;
  max-width: 24em;
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-size: clamp(1.25rem, 1.9vw, 1.55rem);
  line-height: 1.3;
  color: var(--accent-text);
}

.pitch {
  margin: 1rem 0 0;
  max-width: 34em;
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--muted);
  text-wrap: pretty;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-top: 1.6rem;
}

.cue {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  width: fit-content;
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  text-decoration: none;
  transition: color 0.18s ease;
}

.cue:hover {
  color: var(--fg);
}

.cue-stem {
  width: 1px;
  height: 1.75rem;
  background: linear-gradient(var(--accent), transparent);
}

.js .title-block {
  animation: arrive 0.65s ease both;
}

.js .opening .device {
  animation: arrive 0.8s ease both;
}

.demo {
  width: min(56rem, 100%);
  margin: clamp(2rem, 5vw, 4rem) auto 0;
}

.demo video {
  display: block;
  width: 100%;
  height: auto;
  background: var(--surface);
  border-radius: 1rem;
  box-shadow: 0 0 0 1px var(--line), 0 18px 40px var(--card-shadow);
}

.demo figcaption {
  margin-top: 0.55rem;
  color: var(--muted);
  font-size: 1rem;
}

.kicker {
  margin: 0 0 0.65rem;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--accent-text);
}

.section-lead {
  margin: 0.75rem 0 0;
  max-width: 38em;
  font-size: 1.08rem;
  line-height: 1.55;
  color: var(--muted);
  text-wrap: pretty;
}

.problem-intro {
  margin-top: clamp(3.5rem, 8vw, 6rem);
  padding-top: clamp(2.5rem, 5vw, 3.5rem);
  border-top: 1px solid var(--line);
  scroll-margin-top: 1.5rem;
}

.reframe {
  margin-top: clamp(3rem, 7vw, 5.5rem);
  padding: clamp(2rem, 4vw, 3rem) 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 1.5rem;
}

.chapters {
  margin-top: clamp(1.5rem, 4vw, 3rem);
}

.chapter {
  position: relative;
  scroll-margin-top: 1.25rem;
  padding: clamp(2.5rem, 6vw, 4.5rem) 0;
}

.chapter + .chapter {
  border-top: 1px solid var(--line);
}

.chapter-stage {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: start;
  align-items: center;
  gap: 1.75rem;
}

.num {
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 400;
  color: var(--accent-text);
  font-variant-numeric: lining-nums;
}

.chapter .num {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin: 0 0 1rem;
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  line-height: 1;
  letter-spacing: 0.08em;
}

.chapter .num::after {
  content: "";
  width: 3rem;
  height: 1px;
  background: var(--accent);
  opacity: 0.75;
}

.chapter-copy {
  grid-area: copy;
  max-width: 30rem;
}

.chapter-copy h2 {
  margin: 0;
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 560;
  font-size: clamp(2.2rem, 5vw, 4.25rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.chapter-copy p {
  margin: 1rem 0 0;
  max-width: 20em;
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 460;
  font-size: clamp(1.25rem, 1.6vw, 1.5rem);
  line-height: 1.4;
  color: var(--muted);
  text-wrap: pretty;
}

.chapter-copy p.num {
  margin: 0 0 1rem;
  color: var(--accent-text);
  max-width: none;
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  line-height: 1;
}

.plate {
  grid-area: plate;
  position: relative;
  margin: 0;
  width: min(100%, 26rem);
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 1.15rem;
  background: var(--surface);
  box-shadow:
    0 0 0 1px var(--line),
    0 18px 40px var(--card-shadow);
}

.plate img {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: var(--surface);
  filter:
    blur(calc((1 - var(--reveal, 1)) * 8px))
    brightness(calc(0.92 + var(--reveal, 1) * 0.16))
    saturate(calc(0.88 + var(--reveal, 1) * 0.18));
  transform: scale(calc(1.03 - var(--reveal, 1) * 0.03));
  transform-origin: center;
}

.plate::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0;
  background: var(--plate-veil);
  opacity: calc(1 - var(--reveal, 1));
  pointer-events: none;
}

#pain-slot .plate img { object-position: center 64%; }
#pain-unsaid .plate img { object-position: center 46%; }
#pain-grief .plate img { object-position: center 30%; }
#pain-pieces .plate img { object-position: center 68%; }
#pain-grave .plate img { object-position: center 58%; }

.became,
.how,
.source,
.talk,
.reply {
  margin-top: clamp(4rem, 9vw, 7rem);
}

.became {
  width: min(56rem, 100%);
}

h2 {
  margin: 0 0 1rem;
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 560;
  font-size: clamp(1.85rem, 3vw, 2.45rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.map {
  list-style: none;
  margin: 1.5rem 0 0;
  padding: 0;
}

.map li {
  display: grid;
  grid-template-columns: 5.5rem minmax(0, 1fr);
  gap: 0.35rem 1.1rem;
  align-items: center;
  padding: 1rem 0;
  border-top: 1px solid var(--line);
}

.map li:last-child {
  border-bottom: 1px solid var(--line);
}

.map .thumb {
  width: 5.5rem;
  height: 7.25rem;
  border-radius: 0.6rem;
  object-fit: cover;
  display: block;
  background: var(--surface);
}

.map-slot .thumb { object-position: center 64%; }
.map-unsaid .thumb { object-position: center 46%; }
.map-grief .thumb { object-position: center 30%; }
.map-pieces .thumb { object-position: center 70%; }
.map-grave .thumb { object-position: center 60%; }

.map-pain {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
}

.map .num {
  margin-inline-end: 0.4rem;
  font-size: 1.02rem;
}

.map h3 {
  margin: 0.12rem 0 0.2rem;
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 560;
  font-size: 1.65rem;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.map h3 + p {
  margin: 0;
  max-width: 36em;
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 460;
  font-size: 1.12rem;
  line-height: 1.4;
}

.grave-qr {
  display: block;
  width: 7rem;
  height: auto;
  margin-top: 0.75rem;
  padding: 0.35rem;
  background: var(--surface-card);
  border: 1px solid var(--line);
}

.how ol {
  margin: 0.2rem 0 0;
  padding-inline-start: 1.35rem;
}

.how li {
  margin-top: 1.55rem;
  padding-inline-start: 0.35rem;
}

.how li::marker {
  color: var(--accent-text);
  font-family: Newsreader, Palatino, Georgia, serif;
}

.how li p,
blockquote p {
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 460;
  font-size: 1.2rem;
  line-height: 1.5;
  text-wrap: pretty;
}

.how li p {
  margin: 0;
}

blockquote {
  margin: 1rem 0 0;
  padding: 0;
}

.how blockquote {
  padding-inline-start: 1rem;
  border-inline-start: 2px solid var(--sage);
}

blockquote p {
  margin: 0;
  font-weight: 560;
  font-size: clamp(1.45rem, 2.6vw, 1.9rem);
  line-height: 1.25;
}

.graph {
  margin: 1.6rem 0 0;
}

.graph img {
  display: block;
  width: 100%;
  height: auto;
  background: transparent;
}

.graph figcaption {
  margin-top: 0.55rem;
  max-width: 36em;
  color: var(--muted);
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 1.05rem;
  line-height: 1.4;
}

.fictional,
.family,
.lead,
.beside,
.source > p:not(.ask):not(.stack) {
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 460;
  font-size: 1.15rem;
  line-height: 1.45;
}

.fictional,
.family,
.lead {
  margin: 0;
}

.family,
.lead {
  margin-top: 0.35rem;
}

.ask {
  margin: 1.6rem 0 0.35rem;
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 560;
  font-size: 1.45rem;
  line-height: 1.25;
}

.conflict {
  width: min(62rem, 100%);
  margin: 2.75rem auto 0;
  scroll-margin-top: 1.25rem;
}

.conflict h3 {
  margin: 0 0 0.55rem;
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 560;
  font-size: clamp(1.85rem, 3.2vw, 2.6rem);
  line-height: 1.12;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.conflict-intro,
.conflict-takeaway {
  margin: 0;
  max-width: 40em;
  font-family: Newsreader, Palatino, "Palatino Linotype", Georgia, serif;
  font-weight: 460;
  font-size: 1.2rem;
  line-height: 1.45;
}

.conflict-takeaway {
  margin-top: 1.15rem;
}

.memory-pair {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
  margin-top: 1.1rem;
}

.memory-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  margin: 0;
  padding: 1rem 1.05rem 0.95rem;
  background: var(--surface-card);
  color: var(--fg);
  border: 1px solid var(--line);
  border-top: 4px solid var(--clay);
}

.memory-card + .memory-card {
  border-top-color: var(--sage);
}

.memory-card p,
.memory-card blockquote {
  margin: 0;
}

.memory-card .who {
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 1.6rem;
  font-weight: 560;
  line-height: 1.1;
}

.memory-card .relation {
  margin-top: 0.2rem;
  font-family: "Source Sans 3", "Avenir Next", sans-serif;
  font-size: 1rem;
  line-height: 1.3;
  color: var(--muted);
}

.memory-card blockquote {
  margin-top: 0.85rem;
}

.memory-card blockquote p {
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 460;
  font-size: 1.18rem;
  line-height: 1.35;
}

.memory-card blockquote p::before {
  content: var(--q-open);
}

.memory-card blockquote p::after {
  content: var(--q-close);
}

.memory-card .origin {
  margin-top: auto;
  padding-top: 0.8rem;
  border-top: 1px solid var(--line);
  font-family: "Source Sans 3", "Avenir Next", sans-serif;
  font-size: 0.95rem;
  line-height: 1.35;
  color: var(--muted);
}

.keeper-reply {
  width: fit-content;
  max-width: min(36em, 100%);
  margin: 1.2rem 0 0;
  padding: 0.9rem 1.1rem 1rem;
  background: var(--surface);
  color: var(--fg);
  border: 1px solid var(--line);
  border-inline-start: 3px solid var(--sage);
  border-radius: 1.15rem;
  border-end-start-radius: 0.28rem;
  box-shadow: 0 2px 10px var(--card-shadow);
}

.keeper-reply p {
  margin: 0;
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 460;
  font-size: 1.22rem;
  line-height: 1.4;
}

.source > p:last-of-type:not(.stack) {
  margin-top: 0.4rem;
  max-width: 36em;
}

.stack {
  margin: 2.75rem 0 0;
  max-width: 40em;
  font-family: "IBM Plex Mono", "Courier New", monospace;
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--muted);
}

.reply {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 2rem;
  align-items: start;
  text-align: center;
}

.reply .device {
  filter: var(--sim-device-shadow);
}

.reply-copy-wrap {
  max-width: 26rem;
}

.reply-copy {
  margin: 0 auto;
  max-width: 12em;
  font-size: clamp(1.9rem, 3.6vw, 2.95rem);
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.reply-hint {
  margin: 0.9rem auto 0;
  max-width: 28em;
  color: var(--muted);
  font-size: 0.98rem;
  line-height: 1.5;
}

.sim-deck {
  display: grid;
  gap: 0.55rem;
  margin-top: 1.35rem;
  text-align: start;
}

.sim-deck-title {
  margin: 0 0 0.15rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-text);
}

.sim-deck-btn {
  display: grid;
  gap: 0.16rem;
  width: 100%;
  padding: 0.72rem 0.9rem;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--fg);
  text-align: start;
  cursor: pointer;
  transition: border-color 0.16s ease, background-color 0.16s ease, transform 0.1s ease;
}

.sim-deck-btn:hover {
  border-color: var(--accent);
  background: var(--accent-tint);
}

.sim-deck-btn:active {
  background: var(--accent-tint-strong);
  transform: translateY(1px);
}

.sim-deck-btn:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

.sim-deck-btn:disabled {
  opacity: 0.48;
  cursor: not-allowed;
  transform: none;
}

.sim-deck-btn.is-active {
  border-color: var(--accent);
  border-inline-start: 3px solid var(--accent);
  background: var(--accent-tint);
}

.sim-deck-btn strong {
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 560;
  font-size: 1.05rem;
  line-height: 1.25;
  color: var(--fg);
}

.sim-deck-btn span {
  font-size: 0.86rem;
  line-height: 1.35;
  color: var(--muted);
}

.sim-phone {
  width: min(376px, 100%);
  height: clamp(580px, 76svh, 740px);
}

.sim-phone .device-screen {
  position: relative;
  background: var(--phone-sim-bg);
}

.sim-head {
  flex: none;
  display: flex;
  align-items: center;
  gap: 0.55em;
  padding: 0.25em 0.85em 0.6em;
  background: var(--phone-sim-head-bg);
  border-bottom: 1px solid var(--phone-paper-border-xs);
}

.sim-head .avatar {
  width: 2.35em;
  height: 2.35em;
}

.sim-id {
  min-width: 0;
  flex: 1 1 auto;
}

.sim-title {
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 560;
  font-size: 0.98em;
  line-height: 1.15;
  color: var(--phone-paper);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sim-sub {
  margin-top: 0.1em;
  font-size: 0.68em;
  color: var(--phone-ash);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sim-me {
  flex: none;
  padding: 0.34em 0.68em;
  border: 1px solid var(--phone-ember-border);
  border-radius: 999px;
  background: var(--phone-ember-tint-sm);
  color: var(--phone-ember-hot);
  font-size: 0.72em;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.sim-me:hover {
  background: var(--phone-ember-tint-lg);
}

.sim-viewport {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sim-screen {
  display: none;
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 0.75em 0.8em 0.9em;
  flex-direction: column;
  gap: 0.75em;
  scrollbar-width: thin;
  scrollbar-color: var(--phone-scroll-sim) transparent;
}

.sim-screen > * {
  flex: none;
}

.sim-screen.is-on {
  display: flex;
}

.sim-screen::-webkit-scrollbar {
  width: 4px;
}

.sim-screen::-webkit-scrollbar-thumb {
  background: var(--phone-scroll-sim);
  border-radius: 4px;
}

.sim-note {
  font-size: 0.76em;
  line-height: 1.4;
  color: var(--phone-ash);
}

.sim-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  margin-inline-end: 0.42em;
  vertical-align: 0.05em;
}

.sim-dot.is-shared {
  background: var(--phone-ember);
}

.sim-dot.is-private {
  background: var(--phone-private);
}

.sim-dot.is-conflict {
  background: var(--phone-conflict);
}

.sim-plaque {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.42em;
  padding: 1.25em 0.95em 1em;
  border: 1px solid var(--phone-card-border);
  border-radius: 120px 120px 16px 16px;
  background: var(--phone-sim-plaque-bg);
  text-align: center;
}

.sim-arch {
  display: grid;
  place-items: center;
  width: 4.1em;
  height: 5em;
  border-radius: 50% 50% 6px 6px / 42% 42% 6px 6px;
  background: var(--phone-paper);
  color: var(--phone-ink);
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 1.15em;
  font-weight: 600;
  box-shadow: 0 0 0 3px var(--phone-sim-bg), 0 0 0 4px var(--phone-sim-arch-ring);
}

.sim-plaque-name {
  margin: 0.35em 0 0;
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 1.32em;
  font-weight: 560;
  color: var(--phone-paper);
}

.sim-plaque-dates {
  font-size: 0.74em;
  color: var(--phone-ember);
}

.sim-plaque-bio {
  max-width: 24ch;
  font-family: Newsreader, Palatino, Georgia, serif;
  font-style: italic;
  font-size: 0.88em;
  line-height: 1.4;
  color: var(--phone-paper);
}

.sim-qr-btn {
  display: inline-flex;
  padding: 0;
  margin: 0.3em 0 0.1em;
  border: 0;
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.sim-qr-btn:hover {
  transform: scale(1.03);
  box-shadow: 0 0 0 2px var(--phone-ember-border-hi);
}

.sim-qr-btn:focus-visible {
  outline: 2px solid var(--phone-ember);
  outline-offset: 2px;
}

.sim-qr {
  display: block;
  width: 5.2em;
  height: 5.2em;
  margin: 0;
  padding: 0.3em;
  background: var(--phone-paper);
  border-radius: 4px;
}

.sim-lock {
  display: flex;
  flex-direction: column;
  gap: 0.5em;
  padding: 0.8em 0.85em;
  border: 1px dashed var(--phone-private-border);
  border-radius: 12px;
  background: var(--phone-private-bg);
}

.sim-lock-title {
  font-size: 0.84em;
  font-weight: 600;
  color: var(--phone-paper);
}

.sim-row {
  display: flex;
  gap: 0.45em;
}

.sim-btn {
  flex: 1 1 0;
  min-height: 34px;
  padding: 0.42em 0.65em;
  border: 1px solid var(--phone-hairline-xl);
  border-radius: 9px;
  background: transparent;
  color: var(--phone-paper);
  font-size: 0.78em;
  font-weight: 600;
  cursor: pointer;
}

.sim-btn:hover {
  border-color: var(--phone-ember);
}

.sim-btn.is-fill {
  background: var(--phone-ember);
  border-color: var(--phone-ember);
  color: var(--phone-ink);
}

.sim-btn:disabled {
  opacity: 0.72;
  border-color: var(--phone-sim-arch-ring);
  color: var(--phone-private-text);
  cursor: default;
}

.sim-reset-btn {
  flex: none;
  width: 100%;
  margin-top: 0.25em;
  border-style: dashed;
  border-color: var(--phone-sim-arch-ring);
  color: var(--phone-ember-hot);
}

.sim-modes {
  flex: none;
  display: flex;
  border: 1px solid var(--phone-hairline-lg);
  border-radius: 10px;
  overflow: hidden;
  background: var(--phone-paper-tint-xs);
}

.sim-modes button {
  flex: 1 1 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.35em;
  padding: 0.42em 0.35em;
  border: 0;
  background: transparent;
  color: var(--phone-ash);
  font-size: 0.74em;
  font-weight: 500;
  line-height: 1.2;
  cursor: pointer;
}

.sim-modes button.is-on {
  background: var(--phone-ember);
  color: var(--phone-ink);
  font-weight: 600;
}

.sim-scope-banner {
  flex: none;
  font-size: 0.72em;
}

.sim-scope-banner strong {
  color: var(--phone-ember-hot);
}

.sim-chat {
  display: flex;
  flex-direction: column;
  gap: 0.55em;
}

.sim-baba {
  align-self: flex-start;
  max-width: 92%;
  padding-inline-start: 0.72em;
  border-inline-start: 2.5px solid var(--phone-ember);
  display: flex;
  flex-direction: column;
  gap: 0.42em;
}

.sim-baba.is-private {
  border-color: var(--phone-private);
}

.sim-baba-text {
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 0.98em;
  line-height: 1.42;
  color: var(--phone-paper);
}

.sim-wall {
  align-self: flex-start;
  max-width: 94%;
  padding: 0.65em 0.75em;
  border: 1px solid var(--phone-conflict-border);
  border-radius: 10px;
  background: var(--phone-conflict-bg);
  color: var(--phone-paper);
  font-size: 0.8em;
  line-height: 1.4;
  display: flex;
  flex-direction: column;
  gap: 0.5em;
}

.sim-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.32em;
}

.sim-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.2em 0.58em;
  border: 1px solid var(--phone-paper-border-lg);
  border-radius: 999px;
  background: var(--phone-paper-tint-sm);
  color: var(--phone-ember-hot);
  font-size: 0.69em;
  line-height: 1.3;
}

.sim-how-btn {
  align-self: flex-start;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--phone-ash);
  font-size: 0.72em;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  cursor: pointer;
}

.sim-how-btn:hover {
  color: var(--phone-ember-hot);
}

.sim-trace {
  display: none;
  padding: 0.45em 0.6em;
  border-radius: 8px;
  background: var(--phone-paper-tint-sm);
  border: 1px solid var(--phone-paper-border-sm);
  font-size: 0.72em;
  line-height: 1.45;
}

.sim-trace.is-on {
  display: grid;
  gap: 0.2em;
}

.sim-trace-row {
  display: flex;
  justify-content: space-between;
  gap: 0.6em;
}

.sim-trace-row span:first-child {
  color: var(--phone-ash);
}

.sim-trace-row span:last-child {
  color: var(--phone-paper);
  text-align: end;
}

.sim-ask {
  display: flex;
  flex-wrap: wrap;
  gap: 0.36em;
  padding-top: 0.25em;
}

.sim-ask button {
  padding: 0.38em 0.68em;
  border: 1px solid var(--phone-ember-border);
  border-radius: 999px;
  background: var(--phone-ember-tint-xs);
  color: var(--phone-paper);
  font-size: 0.74em;
  line-height: 1.25;
  text-align: start;
  cursor: pointer;
}

.sim-ask button:hover {
  background: var(--phone-ember-tint-md);
  border-color: var(--phone-ember);
}

form.sim-send {
  flex: none;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.42em;
  max-width: none;
  margin-top: 0;
  padding: 0.48em 0.65em;
  border-top: 1px solid var(--phone-paper-border-sm);
  background: var(--phone-sim-bar-bg);
}

.sim-send input {
  flex: 1 1 auto;
  min-width: 0;
  width: auto;
  padding: 0.42em 0.72em;
  border: 1px solid var(--phone-hairline-lg);
  border-radius: 999px;
  background: var(--phone-sim-input-bg);
  color: var(--phone-paper);
  font-size: 0.78em;
}

.sim-send-btn {
  flex: none;
  padding: 0.42em 0.8em;
  border: 0;
  border-radius: 999px;
  background: var(--phone-ember);
  color: var(--phone-ink);
  font-size: 0.76em;
  font-weight: 600;
  cursor: pointer;
}

.sim-tabs {
  flex: none;
  display: flex;
  border-top: 1px solid var(--phone-hairline-md);
  background: var(--phone-sim-bar-bg);
}

.sim-tabs button {
  position: relative;
  flex: 1 1 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.22em;
  min-height: 2.85em;
  padding: 0.55em 0.2em 0.5em;
  border: 0;
  background: transparent;
  color: var(--phone-ash);
  font-size: 0.74em;
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
}

.sim-tabs button.is-on {
  color: var(--phone-ember-hot);
  font-weight: 600;
}

.sim-tabs button.is-on::before {
  content: "";
  position: absolute;
  top: 0;
  left: 24%;
  right: 24%;
  height: 2.5px;
  background: var(--phone-ember);
  border-radius: 0 0 3px 3px;
}

.sim-badge {
  display: inline-grid;
  place-items: center;
  min-width: 1.4em;
  padding: 0.06em 0.35em;
  margin-inline-start: 0.2em;
  border-radius: 999px;
  background: var(--phone-ember);
  color: var(--phone-ink);
  font-size: 0.82em;
  font-weight: 700;
}

.sim-section-head h3 {
  margin: 0 0 0.18em;
  font-family: Newsreader, Palatino, Georgia, serif;
  font-weight: 560;
  font-size: 1.25em;
  color: var(--phone-paper);
}

.sim-merge {
  padding: 0.55em 0.7em;
  border-radius: 9px;
  background: var(--phone-private-tint);
  border: 1px solid var(--phone-private-border-soft);
  color: var(--phone-private-text);
  font-size: 0.75em;
  line-height: 1.38;
}

.sim-inbox-list {
  display: flex;
  flex-direction: column;
  gap: 0.55em;
}

.sim-mem {
  padding: 0.65em 0.72em;
  border: 1px solid var(--phone-paper-border-md);
  border-radius: 6px 12px 12px 6px;
  border-inline-start: 4px solid var(--phone-paper-border-xl);
  background: var(--phone-sim-mem-bg);
  display: flex;
  flex-direction: column;
  gap: 0.4em;
}

.sim-mem.is-shared {
  border-inline-start-color: var(--phone-ember);
}

.sim-mem.is-private {
  border-inline-start-color: var(--phone-private);
}

.sim-mem.is-conflict {
  border-inline-start-color: var(--phone-conflict);
}

.sim-mem.is-skipped {
  opacity: 0.52;
}

.sim-mem-q {
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 0.9em;
  line-height: 1.35;
  color: var(--phone-paper);
}

.sim-mem-meta {
  font-size: 0.69em;
  line-height: 1.3;
  color: var(--phone-ash);
}

.sim-acts {
  display: flex;
  gap: 0.32em;
}

.sim-acts button {
  flex: 1 1 0;
  padding: 0.38em 0.25em;
  border: 1px solid var(--phone-hairline-lg);
  border-radius: 7px;
  background: transparent;
  color: var(--phone-ash);
  font-size: 0.7em;
  font-weight: 600;
  cursor: pointer;
}

.sim-acts button.is-keep {
  color: var(--phone-private-keep);
  border-color: var(--phone-private-border);
}

.sim-acts button.is-share {
  color: var(--phone-ember-hot);
  border-color: var(--phone-ember-border);
}

.sim-conflict-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.42em;
}

.sim-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45em;
}

.sim-pair .sim-mem {
  padding: 0.55em;
}

.sim-pair .sim-mem-q {
  font-size: 0.8em;
}

.sim-tog {
  flex: none;
  display: flex;
  border: 1px solid var(--phone-sim-arch-ring);
  border-radius: 9px;
  overflow: hidden;
  background: var(--phone-sim-tog-bg);
}

.sim-tog button {
  flex: 1 1 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.4em;
  padding: 0.42em 0.45em;
  border: 0;
  background: transparent;
  color: var(--phone-ash);
  font-size: 0.74em;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
}

.sim-tog button.is-on {
  background: var(--phone-ember);
  color: var(--phone-ink);
}

.sim-svg {
  flex: none;
  width: 100%;
  height: auto;
  display: block;
}

.sim-svg text {
  font-family: "Source Sans 3", "Avenir Next", sans-serif;
  font-size: 10.5px;
  fill: var(--phone-paper);
}

.sim-nd[data-sim-n] {
  cursor: pointer;
}

.sim-nd[data-sim-n]:hover circle,
.sim-nd[data-sim-n]:hover rect {
  stroke: var(--phone-ember-hot);
}

.sim-nd circle,
.sim-nd rect {
  fill: var(--phone-sim-nd-bg);
  stroke: var(--phone-sim-node-ring);
  stroke-width: 1.4;
  transition: fill 0.2s ease, stroke 0.2s ease, opacity 0.2s ease;
}

.sim-nd.is-hit circle,
.sim-nd.is-hit rect {
  fill: var(--phone-sim-nd-hit);
  stroke: var(--phone-ember);
  stroke-width: 2.2;
}

.sim-nd.is-off {
  opacity: 0.34;
}

.sim-lk {
  stroke: var(--phone-sim-link);
  stroke-width: 1.3;
}

.sim-lk.is-dashed {
  stroke: var(--phone-conflict);
  stroke-dasharray: 4 3;
}

.sim-toast {
  position: absolute;
  left: 50%;
  bottom: 4.9em;
  transform: translateX(-50%) translateY(6px);
  padding: 0.42em 0.85em;
  border-radius: 999px;
  background: var(--phone-paper);
  color: var(--phone-ink);
  font-size: 0.74em;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
  z-index: 4;
}

.sim-toast.is-on {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.sim-label {
  display: block;
  margin: 0 0 0.5rem;
  font-size: 0.88rem;
  color: var(--muted);
}

.segmented {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  padding: 0.25rem;
  background: var(--surface);
  border: 1px solid var(--line);
}

.seg-btn {
  min-height: 40px;
  padding: 0.45rem 0.9rem;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.16s ease, color 0.16s ease, border-color 0.16s ease, transform 0.1s ease;
}

.seg-btn:hover {
  color: var(--fg);
  background: var(--accent-tint);
}

.seg-btn:active {
  background: var(--accent-tint-strong);
  transform: translateY(1px);
}

.seg-btn:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

.seg-btn:disabled {
  opacity: 0.48;
  cursor: not-allowed;
  transform: none;
}

.seg-btn.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--btn-primary-fg);
  font-weight: 600;
}

.seg-btn.is-active:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}

.talk {
  padding-top: clamp(2.5rem, 5vw, 3.5rem);
  border-top: 1px solid var(--line);
  scroll-margin-top: 1.5rem;
}

.talk h2 {
  max-width: 18em;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.6rem 1.25rem;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--btn-primary-fg);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.18s ease, border-color 0.18s ease, transform 0.1s ease;
}

.button:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}

.button:active {
  background: var(--accent-active);
  border-color: var(--accent-active);
  transform: translateY(1px);
}

.button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.button:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

.button-secondary,
.captcha-refresh {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 0.95rem;
  border: 1px solid var(--accent);
  background: transparent;
  color: var(--fg);
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease, transform 0.1s ease;
}

.button-secondary:hover,
.captcha-refresh:hover {
  background: var(--accent-tint);
  border-color: var(--accent-hover);
  color: var(--fg);
}

.button-secondary:active,
.captcha-refresh:active {
  background: var(--accent-tint-strong);
  border-color: var(--accent-active);
  transform: translateY(1px);
}

.button-secondary:focus-visible,
.captcha-refresh:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

.button-secondary:disabled,
.captcha-refresh:disabled {
  opacity: 0.48;
  cursor: not-allowed;
  transform: none;
}

button,
input,
textarea {
  font: inherit;
}

form {
  display: grid;
  gap: 0.45rem;
  max-width: 32rem;
  margin-top: 1.75rem;
}

.form-field {
  margin-bottom: 0.5rem;
}

form label {
  margin-top: 0.65rem;
  font-size: 0.95rem;
  color: var(--fg);
}

input,
textarea {
  width: 100%;
  padding: 0.72rem 0.85rem;
  border: 1px solid var(--input-border);
  border-radius: 0;
  background: var(--input-bg);
  color: var(--fg);
  font-size: 1rem;
}

input:focus,
textarea:focus {
  border-color: var(--accent);
}

textarea {
  min-height: 6.5rem;
  resize: vertical;
}

.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.captcha-row {
  display: grid;
  gap: 0.4rem;
  margin-top: 0.4rem;
}

.captcha-q {
  display: inline-block;
  margin-inline-start: 0.35rem;
  padding: 0.1rem 0.45rem;
  background: var(--accent-tint);
  border: 1px solid var(--accent);
  color: var(--fg);
  font-weight: 600;
}

.captcha-controls {
  display: flex;
  align-items: stretch;
  gap: 0.6rem;
}

.captcha-controls input {
  width: 7.5rem;
  flex: none;
}

.form-submit-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.9rem 1.4rem;
  margin-top: 1rem;
}

.direct-link {
  color: var(--muted);
  text-underline-offset: 0.22em;
  font-size: 0.95rem;
  white-space: nowrap;
}

.direct-link:hover {
  color: var(--fg);
}

.form-feedback {
  margin: 0.85rem 0 0;
  padding: 0.75rem 1rem;
  border: 1px solid var(--sage);
  background: var(--sage-tint);
  color: var(--fg);
  font-size: 0.95rem;
  line-height: 1.45;
}

.form-feedback.is-error {
  border-color: var(--clay);
  background: var(--clay-tint);
}

footer {
  margin-top: 4.5rem;
  padding-top: 1.75rem;
  padding-bottom: 0.5rem;
  border-top: 1px solid var(--line);
}

.made {
  margin: 0;
  font-family: Newsreader, Palatino, Georgia, serif;
  font-size: 1.3rem;
  font-weight: 560;
  line-height: 1.25;
}

.footer-promise {
  margin: 0.35rem 0 0.75rem;
  color: var(--muted);
  font-size: 0.95rem;
}

footer a {
  color: var(--fg);
  text-underline-offset: 0.18em;
}

.footer-langs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.2rem;
  margin: 1.4rem 0 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
}

.footer-langs [aria-current] {
  color: var(--fg);
}

.footer-langs a {
  color: var(--muted);
}

.footer-langs a:hover {
  color: var(--fg);
}

button,
a {
  -webkit-tap-highlight-color: var(--tap-highlight);
}

.js .copy-beat {
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
}

.js .copy-beat.is-in {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.9s ease, transform 0.9s ease;
}

.js .chat-beat {
  display: none;
}

.js .chat-beat.is-in {
  display: contents;
}

.js .reply .chat-beat {
  display: flex;
  flex-direction: column;
  width: 100%;
  opacity: 0;
}

.js .reply .chat-beat.is-in {
  display: flex;
  opacity: 1;
  transition: opacity 0.5s ease;
}

.js .chat-beat.is-in .bubble,
.js .chat-beat.is-in .day,
.js .chat-beat.is-in .source-card,
.js .chat-beat.is-in .phone-card,
.js .chat-beat.is-in .rule,
.js .chat-beat.is-in .speaker {
  animation: arrive 0.45s ease both;
}

.js .chapter {
  --reveal: 0;
}

html[dir="rtl"] *,
html[dir="rtl"] *::before,
html[dir="rtl"] *::after {
  letter-spacing: normal !important;
}

html[dir="rtl"] body {
  line-height: 1.7;
}

html[dir="rtl"] h1,
html[dir="rtl"] h2,
html[dir="rtl"] h3,
html[dir="rtl"] .sent,
html[dir="rtl"] .unanswered,
html[dir="rtl"] .chapter-copy h2,
html[dir="rtl"] .app-title {
  line-height: 1.3;
}

html[dir="rtl"] .chapter-copy p,
html[dir="rtl"] .pitch,
html[dir="rtl"] .map h3 + p,
html[dir="rtl"] .how li p,
html[dir="rtl"] blockquote p {
  line-height: 1.75;
}

html[dir="rtl"] .device .msg,
html[dir="rtl"] .device .said,
html[dir="rtl"] .device .caption,
html[dir="rtl"] .device .speaker,
html[dir="rtl"] .device .phone-card-title,
html[dir="rtl"] .device .phone-card-note,
html[dir="rtl"] .device .who-name,
html[dir="rtl"] .device .who-status,
html[dir="rtl"] .device .day,
html[dir="rtl"] .device .source-card p,
html[dir="rtl"] .device .rule,
html[dir="rtl"] .device .app-mark,
html[dir="rtl"] .device .app-title,
html[dir="rtl"] .device .chip,
html[dir="rtl"] .device .composer span,
html[dir="rtl"] .sim-head,
html[dir="rtl"] .sim-viewport,
html[dir="rtl"] .sim-send,
html[dir="rtl"] .sim-tabs,
html[dir="rtl"] .sim-toast {
  direction: rtl;
  line-height: 1.55;
}

@media (min-width: 720px) {
  .memory-pair {
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    align-items: stretch;
  }
}

@media (min-width: 860px) {
  :root {
    --phone-h: clamp(560px, 78vh, 760px);
  }

  .opening {
    grid-template-columns: var(--phone-w) minmax(0, 34rem);
    justify-content: center;
    column-gap: clamp(2rem, 5vw, 5rem);
    align-items: center;
  }

  .opening .device {
    margin-inline: 0;
  }

  .hero-copy {
    max-width: 34rem;
  }

  .chapter {
    display: flex;
    align-items: center;
  }

  .chapter-stage {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-areas: "copy plate";
    gap: clamp(2rem, 7vw, 7rem);
  }

  .chapter:nth-child(even) .chapter-stage {
    grid-template-areas: "plate copy";
  }

  .chapter-copy {
    justify-self: start;
  }

  .plate {
    justify-self: center;
    width: auto;
    height: min(78vh, 40rem);
    max-width: 100%;
  }

  .reply {
    grid-template-columns: minmax(0, 24rem) min(376px, 100%);
    justify-content: center;
    column-gap: clamp(2rem, 5vw, 5rem);
    align-items: center;
    text-align: start;
  }

  .reply-copy {
    margin: 0;
  }

  .reply-hint {
    margin: 0.9rem 0 0;
  }

  .reply .device {
    margin-inline: 0;
  }
}

@media (min-width: 1100px) {
  html {
    font-size: 21px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html,
  body,
  .button,
  .button-secondary,
  .captcha-refresh,
  .seg-btn,
  .sim-deck-btn,
  .running a.nav-cta,
  .js .copy-beat,
  .js .copy-beat.is-in,
  .js .title-block h1,
  .js .title-block > :not(h1) {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition: none;
    animation: none;
  }

  .js .opening .device {
    animation: none;
  }

  .js .chat-beat,
  .js .chat-beat.is-in {
    display: contents;
  }

  .js .reply .chat-beat,
  .js .reply .chat-beat.is-in {
    display: flex;
    opacity: 1;
    transition: none;
  }

  .js .chat-beat.is-in .bubble,
  .js .chat-beat.is-in .day,
  .js .chat-beat.is-in .source-card,
  .js .chat-beat.is-in .rule,
  .js .chat-beat.is-in .speaker,
  .wave rect,
  .playhead-bar {
    animation: none;
    transform: none;
  }

  .js .chapter {
    --reveal: 1;
  }

  .plate img {
    opacity: 1;
    filter: none;
    transform: none;
  }
}

@media (forced-colors: active) {
  .device-frame,
  .bubble,
  .chip,
  .button,
  .memory-card,
  .plate {
    border: 1px solid CanvasText;
  }
}
