:root {
  color-scheme: light dark;
  font: 16px/1.45 system-ui, sans-serif;
  color: var(--tg-theme-text-color, light-dark(#181724, #f4f1ff));
  background: var(--tg-theme-bg-color, light-dark(#faf8ff, #171421));
  --muted: var(--tg-theme-hint-color, light-dark(#645e76, #afa7c0));
  --surface: var(--tg-theme-secondary-bg-color, light-dark(#eeeaf7, #242031));
  --accent: var(--tg-theme-button-color, light-dark(#6636d2, #8b61ef));
  --accent-text: var(--tg-theme-button-text-color, white);
}
* { box-sizing: border-box; }
body { margin: 0; }
main { max-width: 640px; margin: auto; padding: max(26px, env(safe-area-inset-top)) 20px max(36px, env(safe-area-inset-bottom)); }
header { display: flex; gap: 16px; align-items: center; margin-bottom: 20px; }
.badge { width: 54px; height: 54px; border-radius: 18px; background: var(--accent); display: flex; align-items: center; justify-content: center; gap: 3px; }
.badge i { width: 3px; height: 11px; background: var(--accent-text); border-radius: 4px; }
.badge i:nth-child(even) { height: 19px; }
.badge i:nth-child(3) { height: 27px; }
h1, h2, p { margin: 0; }
h1 { font-size: 27px; letter-spacing: -.04em; }
h2 { font-size: 20px; }
.eyebrow { font-size: 10px; font-weight: 800; letter-spacing: .19em; color: var(--muted); }
#status { color: var(--muted); margin-bottom: 14px; }
#status:empty { display: none; }
nav { display: flex; gap: 4px; border-radius: 15px; padding: 4px; background: var(--surface); margin-bottom: 22px; }
button, input, select, textarea { font: inherit; color: inherit; }
button { min-height: 42px; padding: 8px 13px; border: 0; border-radius: 11px; background: transparent; cursor: pointer; }
button:disabled { opacity: .55; cursor: default; }
nav button { flex: 1; }
nav button[aria-pressed="true"], .primary { background: var(--accent); color: var(--accent-text); font-weight: 650; }
.section-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.quiet, time { color: var(--muted); font-size: 13px; }
article { margin: 10px 0; padding: 14px; border-radius: 15px; background: var(--surface); }
article p { white-space: pre-wrap; overflow-wrap: anywhere; margin-top: 7px; }
article .question { font-weight: 650; }
.empty { color: var(--muted); }
form { display: grid; gap: 14px; margin-top: 15px; }
label { display: grid; gap: 5px; font-size: 13px; font-weight: 650; }
input, select, textarea { width: 100%; background: var(--surface); border: 1px solid transparent; border-radius: 11px; padding: 10px; font-size: 16px; font-weight: 400; }
textarea { resize: vertical; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
