:root {
  color-scheme: light;
  --bg: #f4f7fb;
  --paper: #ffffff;
  --ink: #1b3048;
  --muted: #5d6f86;
  --blue: #176bc5;
  --blue-dark: #1763b7;
  --blue-pale: #e8f2ff;
  --on-accent: #ffffff;
  --line: #e2e9f2;
  --control-line: #ccd9e8;
  --shadow: 0 8px 32px #233e6010;
  --focus: #246ebf;
  --focus-ring: #b7d5f555;
  --icon: #4d7399;
  --warning-bg: #fff0d7;
  --warning-ink: #795629;
  --notice-bg: #fff9ee;
  --notice-border: #ead7b6;
  --orbit-center: #ffffff;
  --orbit-edge: #e7f1fd99;
  --orbit-ring: #eaf1f966;
  --gold: #ba8b43;
  --user-bg: #e4effe;
  --user-border: #cfdef2;
  --user-ink: #204c7b;
  --placeholder: #61748c;
  --disabled-fill: #cbd9e9;
  --record-bg: #fff0ed;
  --danger: #a34e45;
  --nav-bg: #f9fbfdf5;
  --subtle-bg: #edf3fa;
  --symbol-bg: #ffffff99;
  --switch-track: #bdcadb;
  --thumb: #ffffff;
  --field-bg: #f9fbfe;
  --sheet-bg: #f9fbfe;
  --backdrop: #142d4e55;
  --toast-bg: #213b55f5;
  --toast-ink: #ffffff;
  --desktop-bg: #eaf0f7;
  --rail-bg: #edf3fa;
  --attachment-bg: #e7eff9;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d1522;
  --paper: #162235;
  --ink: #e6edf7;
  --muted: #a8b8cd;
  --blue: #76b7ff;
  --blue-dark: #91c5ff;
  --blue-pale: #1b3452;
  --on-accent: #0b223d;
  --line: #2a3a50;
  --control-line: #425772;
  --shadow: 0 8px 32px #00000033;
  --focus: #99cdff;
  --focus-ring: #76b7ff30;
  --icon: #a2bbd6;
  --warning-bg: #3c2e1b;
  --warning-ink: #f3cc8b;
  --notice-bg: #2b261e;
  --notice-border: #645035;
  --orbit-center: #1f334d;
  --orbit-edge: #14253b;
  --orbit-ring: #1a2b4244;
  --gold: #e1bb78;
  --user-bg: #203c5c;
  --user-border: #355777;
  --user-ink: #e2efff;
  --placeholder: #a1b2c8;
  --disabled-fill: #32465e;
  --record-bg: #442a2b;
  --danger: #ffb0a6;
  --nav-bg: #101c2df5;
  --subtle-bg: #1c2c42;
  --symbol-bg: #294664;
  --switch-track: #52657d;
  --thumb: #eef5ff;
  --field-bg: #101c2d;
  --sheet-bg: #162235;
  --backdrop: #020711b3;
  --toast-bg: #dceaff;
  --toast-ink: #172c45;
  --desktop-bg: #080f19;
  --rail-bg: #101c2d;
  --attachment-bg: #20344e;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}
button,
input,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
button:disabled {
  cursor: default;
  opacity: 0.45;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}
button {
  color: inherit;
}
button,
a,
input,
textarea {
  touch-action: manipulation;
}
[hidden] {
  display: none !important;
}
h1,
h2,
h3,
p {
  margin: 0;
}
.app-shell {
  min-height: 100dvh;
  max-width: 1240px;
  margin: auto;
}
.desktop-rail {
  display: none;
}
.app-main {
  position: relative;
  min-height: 100dvh;
}
.app-header {
  height: calc(88px + env(safe-area-inset-top));
  padding: calc(19px + env(safe-area-inset-top)) 24px 17px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 5;
}
.brand {
  display: flex;
  gap: 12px;
  align-items: center;
}
.brand img {
  border-radius: 15px;
}
.brand h1 {
  font-size: 22px;
  font-weight: 730;
  letter-spacing: -0.6px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.brand-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #68bca5;
}
.brand p {
  font-size: 11px;
  color: var(--muted);
  margin-top: 3px;
}
.icon-button {
  width: 44px;
  height: 44px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
  flex-shrink: 0;
}
.icon-button svg,
.send-button svg {
  width: 22px;
  height: 22px;
}
.avatar {
  background: var(--paper);
  border: 1px solid var(--line);
  font-size: 11px;
  font-weight: 650;
  color: var(--muted);
  box-shadow: 0 2px 6px #203e5510;
}
.connection-banner {
  background: var(--warning-bg);
  color: var(--warning-ink);
  text-align: center;
  padding: 10px 18px;
  font-size: 12px;
  line-height: 1.5;
}
.tab-panel {
  animation: arrive 0.2s ease;
}
.chat-panel {
  height: calc(
    100dvh - 166px - env(safe-area-inset-top) - env(safe-area-inset-bottom)
  );
  position: relative;
  display: flex;
  flex-direction: column;
}
.welcome {
  padding: 25px 24px 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 240px;
  overflow: auto;
}
.welcome-orbit {
  width: 108px;
  height: 108px;
  border: 1px solid var(--line);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  margin: 0 0 22px;
  background: radial-gradient(
    circle,
    var(--orbit-center) 45%,
    var(--orbit-edge)
  );
  box-shadow: 0 0 0 14px var(--orbit-ring);
}
.welcome-orbit img {
  border-radius: 24px;
}
.orbit-star {
  position: absolute;
  top: 1px;
  right: 1px;
  color: var(--gold);
  font-size: 23px;
}
.eyebrow {
  font-size: 9px;
  letter-spacing: 2px;
  font-weight: 700;
  color: var(--icon);
}
.welcome h2,
.pair-screen h2 {
  font-size: 30px;
  line-height: 1.16;
  letter-spacing: -1.1px;
  font-weight: 650;
  margin: 12px 0;
}
.welcome > p:last-of-type {
  font-size: 14px;
  line-height: 1.65;
  color: var(--muted);
}
.suggestion-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: 100%;
  max-width: 420px;
  margin-top: 28px;
}
.suggestion-grid button {
  border: 1px solid var(--line);
  background: var(--paper);
  padding: 15px 14px;
  text-align: left;
  border-radius: 17px;
  min-height: 110px;
  box-shadow: 0 3px 12px #203e5503;
}
.suggestion-grid button > span {
  font-size: 24px;
  color: var(--icon);
  display: block;
  margin-bottom: 10px;
  line-height: 1;
}
.suggestion-grid strong {
  font-size: 12px;
  display: block;
  font-weight: 650;
  letter-spacing: -0.15px;
}
.suggestion-grid small {
  font-size: 10px;
  display: block;
  margin-top: 5px;
  color: var(--muted);
  line-height: 1.4;
}
.messages {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 18px 22px 12px;
  overscroll-behavior: contain;
  scroll-behavior: smooth;
  scroll-padding-bottom: 20px;
}
.welcome:not([hidden]) + .messages {
  flex: 0;
  padding: 0;
}
.message {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-bottom: 22px;
  animation: arrive 0.2s ease;
}
.message.user {
  align-items: flex-end;
}
.message-label {
  font-size: 10px;
  color: var(--muted);
  margin: 0 3px 7px;
  display: flex;
  gap: 8px;
  align-items: center;
}
.message-label img {
  width: 18px;
  height: 18px;
  border-radius: 7px;
}
.message-bubble {
  padding: 14px 16px;
  border-radius: 19px 19px 19px 5px;
  background: var(--paper);
  max-width: 94%;
  font-size: 14px;
  line-height: 1.7;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
  border: 1px solid var(--line);
  box-shadow: 0 3px 12px #203e5504;
}
.user .message-bubble {
  background: var(--user-bg);
  border-color: var(--user-border);
  border-radius: 19px 19px 5px 19px;
  color: var(--user-ink);
}
.notice .message-bubble {
  background: var(--notice-bg);
  border-color: var(--notice-border);
  font-size: 13px;
}
.message-bubble a {
  color: var(--blue-dark);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.message-meta {
  font-size: 10px;
  line-height: 1.5;
  color: var(--muted);
  margin: 7px 3px 0;
  display: flex;
  gap: 10px;
  align-items: center;
}
.retry-button {
  font-size: 11px;
  border: 0;
  background: transparent;
  color: var(--blue);
  padding: 4px 0;
  font-weight: 600;
}
.thinking {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: var(--muted);
  padding: 5px 25px 12px;
}
.thinking .text-button {
  margin-left: auto;
  padding: 4px 8px;
}
.thinking-dots {
  display: flex;
  gap: 3px;
}
.thinking-dots i {
  width: 4px;
  height: 4px;
  background: var(--icon);
  border-radius: 50%;
  animation: pulse 1s ease-in-out infinite;
}
.thinking-dots i:nth-child(2) {
  animation-delay: 0.15s;
}
.thinking-dots i:nth-child(3) {
  animation-delay: 0.3s;
}
.composer-area {
  padding: 10px 20px 8px;
  background: linear-gradient(0deg, var(--bg) 84%, transparent);
}
.composer {
  display: flex;
  align-items: flex-end;
  background: var(--paper);
  border: 1px solid var(--control-line);
  border-radius: 23px;
  padding: 7px 8px 7px 17px;
  box-shadow: 0 6px 24px #27486808;
  min-height: 58px;
}
.composer:focus-within {
  border-color: var(--focus);
  box-shadow: 0 0 0 3px var(--focus-ring);
}
.composer textarea {
  flex: 1;
  min-width: 0;
  max-height: 140px;
  resize: none;
  border: 0;
  outline: none !important;
  box-shadow: none;
  background: transparent;
  padding: 12px 2px 9px 0;
  font-size: 16px;
  color: var(--ink);
  line-height: 1.4;
}
.composer textarea::placeholder {
  color: var(--placeholder);
}
.composer-actions {
  display: flex;
  align-items: center;
  gap: 2px;
}
.composer .icon-button {
  color: var(--icon);
  width: 38px;
  height: 42px;
}
.send-button {
  border: 0;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  background: var(--blue);
  color: var(--on-accent);
  display: grid;
  place-items: center;
  transition: background 0.15s;
}
.send-button:disabled {
  background: var(--disabled-fill);
  opacity: 1;
}
.composer-hint {
  text-align: center;
  font-size: 9px;
  letter-spacing: 0.25px;
  color: var(--muted);
  padding-top: 9px;
}
.dictation-status {
  font-size: 12px;
  color: var(--blue-dark);
  background: var(--user-bg);
  border-radius: 13px;
  padding: 10px 12px;
  margin-bottom: 8px;
  line-height: 1.5;
}
.recording {
  background: var(--record-bg) !important;
  color: var(--danger) !important;
  animation: pulse 1.6s infinite;
}
.tab-bar {
  height: calc(78px + env(safe-area-inset-bottom));
  padding: 10px 18px calc(9px + env(safe-area-inset-bottom));
  display: flex;
  justify-content: space-around;
  align-items: center;
  border-top: 1px solid var(--line);
  background: var(--nav-bg);
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10;
  backdrop-filter: blur(20px);
}
.tab-button {
  border: 0;
  background: transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  color: var(--muted);
  min-width: 80px;
  min-height: 50px;
  font-size: 10px;
  position: relative;
}
.tab-button svg {
  width: 23px;
  height: 23px;
}
.tab-button.active {
  color: var(--blue-dark);
  font-weight: 650;
}
.tab-button.active::before {
  content: "";
  position: absolute;
  top: -11px;
  width: 25px;
  height: 3px;
  border-radius: 0 0 4px 4px;
  background: var(--blue);
}
.tab-count {
  position: absolute;
  top: 0;
  right: 15px;
  background: var(--blue-pale);
  border-radius: 8px;
  min-width: 16px;
  font-size: 9px;
  padding: 2px 4px;
}
.content-panel {
  padding: 23px 22px calc(110px + env(safe-area-inset-bottom));
  max-width: 680px;
  margin: auto;
}
.section-heading {
  margin: 7px 0 29px;
}
.section-heading h2 {
  font-size: 29px;
  letter-spacing: -1px;
  line-height: 1.3;
  font-weight: 650;
  margin: 9px 0;
}
.section-heading > p:last-child {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.6;
}
.add-card {
  width: 100%;
  padding: 17px;
  display: flex;
  align-items: center;
  gap: 13px;
  border: 1px solid var(--control-line);
  border-radius: 19px;
  background: var(--blue-pale);
  text-align: left;
  margin-bottom: 24px;
  color: var(--blue-dark);
}
.add-card strong,
.settings-row strong {
  font-size: 13px;
  display: block;
  font-weight: 600;
}
.add-card small,
.settings-row small {
  font-size: 11px;
  line-height: 1.5;
  display: block;
  color: var(--muted);
  margin-top: 4px;
}
.add-card > span:last-child {
  margin-left: auto;
  font-size: 20px;
}
.plus-circle {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--symbol-bg);
  font-size: 23px;
  font-weight: 300;
}
.tasks-list {
  display: grid;
  gap: 12px;
}
.task-card {
  border-radius: 18px;
  padding: 17px;
  background: var(--paper);
  border: 1px solid var(--line);
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.task-icon {
  width: 33px;
  height: 33px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  border-radius: 11px;
  background: var(--subtle-bg);
  color: var(--icon);
  font-size: 19px;
}
.task-copy {
  min-width: 0;
  flex: 1;
}
.task-copy h3 {
  font-size: 13px;
  line-height: 1.5;
  font-weight: 600;
  overflow-wrap: anywhere;
}
.task-copy p {
  font-size: 11px;
  line-height: 1.5;
  color: var(--muted);
  margin-top: 7px;
}
.task-copy .task-due {
  color: var(--blue-dark);
}
.task-actions {
  display: flex;
  gap: 15px;
  margin-top: 12px;
}
.task-actions button {
  border: 0;
  background: transparent;
  font-size: 11px;
  padding: 6px 0;
  color: var(--muted);
  min-height: 32px;
}
.task-actions button:last-child {
  color: var(--danger);
}
.empty-state {
  text-align: center;
  padding: 38px 20px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}
.empty-state .empty-symbol {
  font-size: 35px;
  color: var(--icon);
  margin-bottom: 13px;
}
.empty-state strong {
  display: block;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 6px;
}
.settings-group {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 20px;
  margin-bottom: 20px;
  overflow: hidden;
}
.settings-group h3 {
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 650;
  padding: 19px 18px 7px;
}
.settings-row {
  padding: 16px 17px;
  display: flex;
  width: 100%;
  align-items: center;
  gap: 13px;
  border: 0;
  text-align: left;
  background: transparent;
  min-height: 75px;
}
.settings-row + .settings-row {
  border-top: 1px solid var(--line);
}
.settings-row > span:nth-child(2) {
  flex: 1;
  min-width: 0;
}
.settings-row > span:last-child:not(:nth-child(2)) {
  color: var(--icon);
  font-size: 24px;
}
.setting-symbol {
  width: 28px;
  text-align: center;
  font-size: 23px;
  color: var(--icon);
  flex-shrink: 0;
}
.switch {
  appearance: none;
  -webkit-appearance: none;
  width: 42px;
  height: 26px;
  border-radius: 15px;
  background: var(--switch-track);
  position: relative;
  flex-shrink: 0;
  margin: 0;
  transition: background 0.15s;
}
.switch::after {
  content: "";
  width: 20px;
  height: 20px;
  position: absolute;
  left: 3px;
  top: 3px;
  border-radius: 50%;
  background: var(--thumb);
  box-shadow: 0 1px 3px #0002;
  transition: transform 0.15s;
}
.switch:checked {
  background: var(--blue);
}
.switch:checked::after {
  transform: translateX(16px);
}
.settings-footer {
  text-align: center;
  font-size: 11px;
  color: var(--muted);
  line-height: 1.8;
  margin-top: 28px;
}
.settings-footer span {
  font-size: 10px;
}
.pair-screen {
  padding: 25px 26px 30px;
  text-align: center;
  max-width: 440px;
  margin: auto;
}
.hero-mark {
  margin: 0 auto 28px;
}
.hero-mark img {
  border-radius: 30px;
  box-shadow: 0 12px 40px #3c78ba20;
}
.pair-screen h2 {
  font-size: 36px;
  margin: 14px 0 18px;
}
.intro-copy {
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
  max-width: 300px;
  margin: auto;
}
.pair-card {
  margin: 28px 0 18px;
  padding: 22px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 22px;
  text-align: left;
  box-shadow: var(--shadow);
}
.pair-card label {
  font-size: 15px;
  font-weight: 650;
}
.pair-card p {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
  margin-top: 9px;
}
.pair-card input,
.sheet input {
  width: 100%;
  margin: 17px 0 12px;
  border: 1px solid var(--control-line);
  border-radius: 12px;
  padding: 14px;
  font-size: 16px;
  background: var(--field-bg);
  color: var(--ink);
}
.primary-button {
  background: var(--blue);
  border: 0;
  border-radius: 13px;
  padding: 14px 18px;
  color: var(--on-accent);
  font-weight: 600;
  font-size: 14px;
  min-height: 48px;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.text-button {
  background: none;
  border: 0;
  color: var(--blue-dark);
  font-size: 12px;
  padding: 10px;
  font-weight: 500;
}
.privacy-note {
  font-size: 10px;
  color: var(--muted);
  line-height: 1.6;
  margin-top: 12px;
}
.pair-card .form-error {
  color: var(--danger);
  min-height: 0;
}
.form-error:empty {
  display: none;
}
.sheet {
  position: fixed;
  inset: auto 0 0;
  margin: 0 auto;
  width: 100%;
  max-width: 560px;
  max-height: 85dvh;
  background: var(--sheet-bg);
  border: 0;
  border-radius: 26px 26px 0 0;
  padding: 11px 24px calc(30px + env(safe-area-inset-bottom));
  color: var(--ink);
  box-shadow: 0 -10px 60px #173d6220;
  overflow-y: auto;
}
.sheet::backdrop {
  background: var(--backdrop);
  backdrop-filter: blur(4px);
}
.sheet-handle {
  width: 34px;
  height: 4px;
  border-radius: 3px;
  background: var(--control-line);
  margin: 0 auto 17px;
}
.sheet-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.sheet-heading h2 {
  font-size: 22px;
  letter-spacing: -0.6px;
  font-weight: 650;
}
.sheet-heading .icon-button {
  background: var(--subtle-bg);
  font-size: 25px;
  width: 32px;
  height: 32px;
  color: var(--muted);
}
.sheet p,
.sheet li {
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
}
.sheet p + p {
  margin-top: 12px;
}
.sheet ol {
  padding-left: 22px;
}
.sheet li {
  padding: 5px 0;
}
.sheet pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font:
    12px/1.7 ui-monospace,
    monospace;
  background: var(--subtle-bg);
  padding: 14px;
  border-radius: 12px;
  max-height: 280px;
  overflow: auto;
}
.sheet .primary-button {
  margin-top: 20px;
}
.sheet .secondary-button {
  margin-top: 10px;
}
.secondary-button {
  border: 1px solid var(--control-line);
  background: var(--paper);
  padding: 13px 18px;
  border-radius: 13px;
  min-height: 46px;
  color: var(--muted);
  width: 100%;
  font-size: 13px;
}
.memory-item {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.memory-item p {
  font-size: 13px;
}
.memory-item button {
  margin-top: 7px;
  padding: 5px 0;
  border: 0;
  background: transparent;
  color: var(--danger);
  font-size: 12px;
}
.approval-card {
  border: 1px solid var(--notice-border);
  background: var(--notice-bg);
  border-radius: 16px;
  margin: 0 0 18px;
  padding: 16px;
}
.approval-card h3 {
  font-size: 13px;
}
.approval-card p {
  font-size: 12px;
  color: var(--warning-ink);
  line-height: 1.6;
  margin-top: 7px;
}
.approval-card button {
  margin-top: 12px;
}
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(100px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  padding: 13px 18px;
  border-radius: 14px;
  background: var(--toast-bg);
  box-shadow: 0 4px 22px #17334f25;
  color: var(--toast-ink);
  font-size: 12px;
  line-height: 1.5;
  max-width: calc(100% - 32px);
  width: max-content;
  z-index: 30;
}
.new-message-button {
  position: absolute;
  bottom: 112px;
  left: 50%;
  transform: translateX(-50%);
  border: 1px solid var(--control-line);
  border-radius: 20px;
  background: var(--paper);
  color: var(--blue-dark);
  padding: 9px 16px;
  font-size: 12px;
  box-shadow: var(--shadow);
  z-index: 2;
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
@keyframes pulse {
  50% {
    opacity: 0.35;
  }
}
@keyframes arrive {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@media (min-width: 760px) {
  body {
    background: var(--desktop-bg);
  }
  .app-shell {
    display: flex;
    max-width: 1100px;
    box-shadow: 0 0 80px #36577508;
  }
  .desktop-rail {
    display: flex;
    width: 260px;
    flex-shrink: 0;
    padding: 50px 35px;
    flex-direction: column;
    background: var(--rail-bg);
    position: sticky;
    top: 0;
    height: 100dvh;
  }
  .desktop-rail img {
    border-radius: 19px;
    margin-bottom: 20px;
  }
  .desktop-rail strong {
    font-size: 28px;
    letter-spacing: -1px;
  }
  .desktop-rail > span {
    font-size: 14px;
    color: var(--muted);
    line-height: 1.8;
    margin-top: 12px;
  }
  .rail-footer {
    margin-top: auto;
    font-size: 8px;
    letter-spacing: 1.7px;
    color: var(--muted);
  }
  .app-main {
    flex: 1;
    background: var(--bg);
    min-width: 0;
    border-left: 1px solid var(--line);
    border-right: 1px solid var(--line);
  }
  .app-header {
    padding-left: 35px;
    padding-right: 35px;
  }
  .tab-bar {
    left: auto;
    right: auto;
    width: calc(min(100vw, 1100px) - 260px);
    max-width: 840px;
  }
  .welcome {
    padding: 35px;
  }
  .welcome h2 {
    font-size: 37px;
  }
  .welcome-orbit {
    margin-bottom: 30px;
  }
  .suggestion-grid {
    margin-top: 37px;
    gap: 14px;
  }
  .suggestion-grid button {
    padding: 20px;
    min-height: 125px;
  }
  .suggestion-grid strong {
    font-size: 14px;
  }
  .suggestion-grid small {
    font-size: 11px;
  }
  .messages {
    padding: 22px 35px;
  }
  .message-bubble {
    max-width: 86%;
    font-size: 15px;
  }
  .composer-area {
    padding-left: 35px;
    padding-right: 35px;
  }
  .content-panel {
    padding: 30px 35px 115px;
  }
  .pair-screen {
    padding-top: 45px;
  }
  .sheet {
    inset: 50% auto auto 50%;
    transform: translate(-50%, -50%);
    border-radius: 26px;
    padding-bottom: 28px;
    max-height: 80dvh;
  }
  .sheet-handle {
    display: none;
  }
  .sheet-heading {
    margin-top: 12px;
  }
}
@media (max-height: 730px) and (max-width: 759px) {
  .welcome {
    padding-top: 15px;
  }
  .welcome-orbit {
    width: 76px;
    height: 76px;
    margin-bottom: 18px;
    box-shadow: 0 0 0 8px var(--orbit-ring);
  }
  .welcome-orbit img {
    width: 53px;
    height: 53px;
    border-radius: 18px;
  }
  .welcome h2 {
    font-size: 27px;
  }
  .suggestion-grid {
    margin-top: 17px;
  }
  .suggestion-grid button {
    min-height: 85px;
    padding: 12px;
  }
  .suggestion-grid button > span {
    margin-bottom: 7px;
    font-size: 20px;
  }
  .composer-hint {
    display: none;
  }
  .pair-screen {
    padding-top: 10px;
  }
  .hero-mark {
    margin-bottom: 15px;
  }
  .hero-mark img {
    width: 70px;
    height: 70px;
  }
  .pair-screen h2 {
    font-size: 30px;
  }
  .pair-card {
    margin-top: 20px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
.attachment-chip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 4px 6px 4px 13px;
  background: var(--attachment-bg);
  border: 1px solid var(--control-line);
  border-radius: 13px;
  margin-bottom: 8px;
  font-size: 12px;
  color: var(--blue-dark);
}
.attachment-chip > span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.attachment-chip .icon-button {
  width: 30px;
  height: 30px;
  font-size: 20px;
}
.composer #attach-button {
  font-size: 25px;
}

/* One tap per appearance choice, with native radio keyboard and screen-reader behavior. */
.appearance-settings {
  margin: 12px 17px 2px;
  padding: 0 0 17px;
  border: 0;
  border-bottom: 1px solid var(--line);
  min-width: 0;
}
.appearance-settings legend {
  padding: 0;
  margin-bottom: 12px;
  font-size: 13px;
  font-weight: 600;
}
.appearance-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--subtle-bg);
}
.appearance-options label {
  position: relative;
  min-width: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.appearance-options input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}
.appearance-options span {
  display: grid;
  place-items: center;
  min-height: 44px;
  padding: 8px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 550;
}
.appearance-options input:checked + span {
  background: var(--paper);
  color: var(--blue-dark);
  border-color: var(--control-line);
  box-shadow: var(--shadow);
  font-weight: 700;
}
.appearance-options input:focus-visible + span {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
.appearance-settings p {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
  margin-top: 10px;
}
::selection {
  background: var(--blue-pale);
  color: var(--ink);
}
