@font-face {
  font-family: Vazir;
  src: url('/assets/vazirmatn-arabic-400-normal.woff2');
}
@font-face {
  font-family: Vazir;
  src: url('/assets/vazirmatn-arabic-700-normal.woff2');
  font-weight: 700;
}
:root {
  color-scheme: light;
  --bg: #e8eae3;
  --surface: #f5f5ee;
  --soft: #e8eae1;
  --line: #d0d6cb;
  --ink: #212924;
  --muted: #505c54;
  --accent: #465f32;
  --tint: #dce6d0;
  --primary: #28352b;
  --primary-ink: #f7f7ee;
  --ok: #416a36;
  --danger: #a13a47;
  --shadow: 0 18px 58px #23322b17;
  --radius: 24px;
  --ease: cubic-bezier(0.22, 0.72, 0.25, 1);
  --font: 15px;
}
:root[data-dark='true'] {
  color-scheme: dark;
  --bg: #181e1d;
  --surface: #252e2b;
  --soft: #303935;
  --line: #454f48;
  --ink: #f2f2e8;
  --muted: #bdc6bc;
  --accent: #c4d49f;
  --tint: #394638;
  --primary: #eff0e7;
  --primary-ink: #252e26;
  --ok: #c5d6a0;
  --danger: #ffc0c2;
  --shadow: 0 20px 56px #0c120f55;
}
:root[data-accent='blue'] { --accent: #345c86; --tint: #dae5eb; }
:root[data-dark='true'][data-accent='blue'] { --accent: #b3c9dc; --tint: #32404b; }
:root[data-accent='teal'] { --accent: #32655b; --tint: #d5e9df; }
:root[data-dark='true'][data-accent='teal'] { --accent: #b2d4c9; --tint: #304943; }
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  height: 100%;
  overflow: hidden;
}
body {
  background: var(--bg);
  color: var(--ink);
  font:
    var(--font)/1.65 Vazir,
    system-ui,
    sans-serif;
}
button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  border: 0;
  background: none;
  touch-action: manipulation;
}
button:disabled {
  opacity: 0.45;
  cursor: default;
}
button:not(:disabled):active {
  transform: scale(0.97);
}
button,
a,
input,
select,
textarea {
  outline-offset: 3px;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent);
}
a {
  color: var(--accent);
}
svg {
  width: 21px;
  height: 21px;
  flex: none;
  vertical-align: middle;
}
p,
h1,
h2,
h3 {
  margin: 0;
}
p {
  line-height: 1.85;
}
small,
.muted {
  color: var(--muted);
}
[hidden] {
  display: none !important;
}
.stack {
  display: grid;
  gap: 13px;
}
.push {
  flex: 1;
}
.ib,
.primary,
.secondary,
.danger,
.chip,
.row,
.tab {
  transition:
    background 0.16s,
    color 0.16s,
    transform 0.16s var(--ease);
}
.ib {
  display: inline-grid;
  place-items: center;
  width: 43px;
  height: 43px;
  border-radius: 14px;
  background: var(--soft);
  color: var(--ink);
  flex: none;
}
.primary,
.secondary,
.danger {
  border-radius: 14px;
  font-weight: 700;
  padding: 11px 17px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
}
.primary {
  background: var(--primary);
  color: var(--primary-ink);
}
.ib.primary {
  padding: 0;
}
.secondary {
  background: var(--soft);
  color: var(--accent);
}
.danger {
  background: color-mix(in srgb, var(--danger) 12%, var(--surface));
  color: var(--danger);
}
.primary[aria-busy='true']:after {
  content: '';
  width: 13px;
  height: 13px;
  border: 2px solid currentColor;
  border-left-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.field {
  display: grid;
  gap: 5px;
  font-size: 0.92em;
  font-weight: 700;
}
input:not([type='checkbox']),
textarea,
select {
  border: 1px solid var(--line);
  background: var(--soft);
  border-radius: 12px;
  padding: 10px 13px;
  min-width: 0;
  width: 100%;
}
input[type='checkbox'] {
  accent-color: var(--accent);
  width: 19px;
  height: 19px;
}
.mark {
  display: block;
  width: 43px;
  height: 43px;
  border-radius: 14px;
  box-shadow: 0 6px 15px #001c4938;
}
.gate {
  display: grid;
  grid-template-columns: 1fr 1fr;
  max-width: 1080px;
  margin: auto;
  min-height: min(740px, 88dvh);
  position: relative;
  top: 50%;
  transform: translateY(-50%);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 34px;
  box-shadow: var(--shadow);
  overflow: auto;
  max-height: 96dvh;
}
.splash {
  overflow: hidden;
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(24px, 5vw, 60px);
  background:
    radial-gradient(ellipse at 22% 10%, #5364597a, transparent 60%),
    radial-gradient(ellipse at 90% 100%, #554a3866, transparent 56%),
    linear-gradient(151deg, #313e39, #232b2a 63%, #252a25);
  color: #f4f3ea;
}
.splash h1 {
  font-size: clamp(27px, 3.1vw, 46px);
  letter-spacing: -1.5px;
}
.splash p:not(.eyebrow) {
  color: #d2d7cc;
  max-width: 310px;
}
.lockup {
  display: flex;
  align-items: center;
  gap: 8px;
  align-self: flex-end;
  font: 16px system-ui;
}
.lockup span:last-child {
  font-weight: 300;
  color: #c5d0c0;
}
.orbit,
.illustration {
  position: relative;
  display: grid;
  place-items: center;
  isolation: isolate;
}
.orbit {
  height: 260px;
}
.orbit i,
.illustration i {
  position: absolute;
  width: 200px;
  height: 200px;
  transform: rotate(-33deg);
  border: 1px solid #b3c7a84a;
  border-radius: 50% 50% 50% 24%;
  background: linear-gradient(125deg, #a4b69c24, #8191800a);
  box-shadow:
    inset 0 2px 12px #cbd5c416,
    0 15px 38px #0c131f21;
}
.orbit i:nth-child(2) {
  scale: 0.78;
}
.orbit img {
  z-index: 1;
  filter: drop-shadow(0 14px 26px #001c495c);
}
.gate-form {
  padding: clamp(28px, 6vw, 78px);
  align-self: center;
}
.gate-form > p {
  margin: 8px 0 23px;
}
.gate-form > .secondary {
  margin-top: 12px;
  width: 100%;
}
.gate-form h2 {
  font-size: 29px;
}
.gate-form .tile {
  margin: 0 0 14px;
}
.shell {
  height: 100dvh;
  display: grid;
  grid-template-columns: 78px clamp(282px, 29vw, 370px) minmax(0, 1fr);
}
.rail {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--soft);
  border-inline-end: 1px solid var(--line);
  padding: 24px 6px 18px;
  gap: 32px;
}
.rail > div:nth-child(2) {
  display: grid;
  gap: 9px;
}
.rail-lock {
  margin-top: auto;
}
.tab {
  display: grid;
  gap: 3px;
  justify-items: center;
  min-height: 54px;
  width: 62px;
  color: var(--muted);
  font-size: 10px;
  border-radius: 15px;
  padding: 7px 2px;
}
.tab.active {
  background: var(--tint);
  color: var(--accent);
  font-weight: bold;
}
.sidebar {
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border-inline-end: 1px solid var(--line);
  overflow: hidden;
}
.brandline,
.sidehead,
.thread-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.brandline {
  padding: 22px 22px 13px;
}
.brandline b {
  font: 700 16px/1.2 system-ui;
  letter-spacing: -0.7px;
}
.brandline b span {
  font-weight: 400;
  color: var(--muted);
}
.sidehead {
  padding: 15px 22px 12px;
}
.sidehead h1 {
  font-size: 30px;
  letter-spacing: -1.3px;
}
.connection {
  font-size: 11px;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.connection:before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
}
.connection.live:before {
  background: var(--ok);
}
#side-tools {
  display: grid;
  gap: 9px;
  padding: 0 20px 12px;
}
.search {
  position: relative;
  display: flex;
  align-items: center;
}
.search svg {
  position: absolute;
  inset-inline-start: 12px;
  color: var(--muted);
  width: 17px;
}
.search input {
  padding-inline-start: 38px;
  background: var(--soft);
  border: 0;
}
.chips,
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
}
.chip {
  padding: 6px 13px;
  min-height: 34px;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 100px;
  font-size: 12px;
}
.chip.active {
  background: var(--tint);
  color: var(--accent);
  border-color: transparent;
}
.side-list,
.detail,
.timeline {
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  min-height: 0;
}
.side-list {
  padding: 2px 12px 20px;
}
.row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: start;
  border-radius: 15px;
  padding: 12px 10px;
  min-height: 57px;
}
.row:hover,
.row.active,
.ib:hover,
.tab:hover {
  background: var(--tint);
}
.row > svg:last-child {
  width: 15px;
  color: var(--muted);
}
.rowtext {
  display: grid;
  min-width: 0;
  flex: 1;
}
.rowtext b,
.rowtext small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.rowtext small {
  font-size: 12px;
}
.tile,
.avatar,
.emptyicon {
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 15px;
  background: var(--tint);
  color: var(--accent);
}
.avatar {
  font-weight: 700;
  background: linear-gradient(
    135deg,
    var(--tint),
    color-mix(in srgb, var(--accent) 19%, var(--soft))
  );
  position: relative;
}
.avatar.online:after {
  content: '';
  position: absolute;
  width: 9px;
  height: 9px;
  border: 2px solid var(--surface);
  border-radius: 50%;
  bottom: -1px;
  left: -1px;
  background: var(--ok);
}
.avatar.mini {
  height: 34px;
  width: 34px;
  border-radius: 50%;
  font-size: 12px;
}
.count {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  border-radius: 12px;
  background: var(--accent);
  color: var(--surface);
  font: 12px Vazir;
}
.rowmeta {
  display: grid;
  justify-items: end;
  gap: 4px;
  font-size: 10px;
  color: var(--muted);
}
.main,
.thread,
.detail {
  min-width: 0;
  min-height: 0;
  height: 100%;
  position: relative;
}
.main {
  background:
    radial-gradient(ellipse at 20% 0%, var(--tint), transparent 62%),
    var(--soft);
}
.welcome {
  height: 100%;
  display: grid;
  align-content: center;
  justify-items: center;
  padding: 26px;
  text-align: center;
  gap: 10px;
}
.welcome .illustration {
  width: 170px;
  height: 160px;
}
.illustration i {
  width: 133px;
  height: 133px;
  background: linear-gradient(140deg, #a6ba9d46, #6e867522);
  border-color: #8ea28d65;
}
.illustration i:nth-child(2) {
  scale: 0.76;
}
.illustration i:nth-child(3) {
  scale: 0.52;
  background: linear-gradient(145deg, #83977a, #506454);
}
.illustration svg {
  position: relative;
  color: white;
  width: 31px;
  height: 31px;
}
.welcome h2,
.detail h2 {
  font-size: 26px;
  letter-spacing: -1px;
}
.welcome p {
  max-width: 360px;
  color: var(--muted);
  margin-bottom: 8px;
}
.empty {
  display: grid;
  justify-items: center;
  gap: 7px;
  text-align: center;
  padding: 35px 17px;
}
.empty h3 {
  font-size: 16px;
}
.empty p {
  font-size: 13px;
  color: var(--muted);
  max-width: 350px;
}
.thread {
  display: flex;
  flex-direction: column;
}
.thread-head {
  justify-content: flex-start;
  background: var(--surface);
  padding: 14px clamp(14px, 3vw, 42px);
  border-bottom: 1px solid var(--line);
}
.peer-button {
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: start;
}
.peer-button small {
  display: block;
  font-size: 11px;
}
.timeline {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 15px clamp(14px, 4vw, 64px);
  overflow-anchor: none;
}
.day {
  align-self: center;
  border-radius: 20px;
  padding: 3px 13px;
  background: var(--surface);
  color: var(--muted);
  font-size: 11px;
  margin: 8px;
}
.bubble {
  position: relative;
  align-self: flex-end;
  max-width: min(80%, 620px);
  min-width: 80px;
  border: 1px solid var(--line);
  border-radius: 18px 18px 18px 5px;
  padding: 8px 12px;
  background: var(--surface);
  overflow-wrap: anywhere;
}
.bubble.own {
  align-self: flex-start;
  background: var(--tint);
  border-color: color-mix(in srgb, var(--accent) 14%, transparent);
  border-radius: 18px 18px 5px 18px;
}
.bubble p {
  white-space: pre-wrap;
  line-height: 1.65;
}
.bubble small {
  font-size: 10px;
  display: block;
}
.bubble blockquote {
  margin: 2px 0 6px;
  border-inline-start: 2px solid var(--accent);
  padding-inline-start: 8px;
  color: var(--muted);
  font-size: 0.86em;
}
.bubble .row {
  padding: 3px;
  min-height: 40px;
}
.bubble .secondary {
  font-size: 12px;
  padding: 5px 10px;
  min-height: 32px;
}
.bubble progress {
  width: 100%;
  accent-color: var(--accent);
}
.bubble audio {
  max-width: 100%;
  width: 240px;
}
.ghostbar,
.replystrip {
  background: var(--tint);
  color: var(--accent);
  padding: 5px 16px;
  font-size: 13px;
}
.composer-wrap {
  padding: 9px clamp(10px, 3vw, 44px) max(13px, env(safe-area-inset-bottom));
  background: var(--surface);
  border-top: 1px solid var(--line);
}
.composer {
  display: flex;
  align-items: flex-end;
  gap: 6px;
}
.composer textarea {
  resize: none;
  max-height: 112px;
  line-height: 1.6;
}
.composer .ib {
  width: 40px;
  height: 43px;
}
.jump {
  position: absolute;
  bottom: 85px;
  align-self: center;
  border-radius: 20px;
  background: var(--surface);
  color: var(--accent);
  padding: 7px 15px;
  box-shadow: var(--shadow);
}
.detail {
  overflow: auto;
  padding: clamp(16px, 4vw, 58px);
  max-width: 1000px;
  margin: auto;
}
.detail > header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  margin: 12px 0;
}
.card h3 {
  margin: 2px 8px 8px;
  font-size: 15px;
}
.card .row + .row {
  border-top: 1px solid var(--line);
}
.grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr));
}
dialog {
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: 0 24px 90px #0a1c3a35;
  width: min(460px, 94vw);
  max-height: 86dvh;
  padding: 19px 22px;
  overscroll-behavior: contain;
}
dialog[open] {
  animation: appear 0.2s var(--ease);
}
dialog::backdrop {
  background: #0b100dc2;
  backdrop-filter: blur(4px);
}
dialog header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 15px;
}
dialog h2 {
  font-size: 21px;
}
#sheet-body {
  display: grid;
  gap: 12px;
  overflow-wrap: anywhere;
}
.qr {
  width: 190px;
  max-width: 85%;
  height: auto;
  justify-self: center;
  background: white;
  padding: 12px;
  border-radius: 14px;
  image-rendering: pixelated;
}
.code {
  direction: ltr;
  text-align: center;
  user-select: all;
  overflow-wrap: anywhere;
  background: var(--soft);
  padding: 12px;
  border-radius: 10px;
  font: 13px/1.8 monospace;
}
.toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 3px;
}
.preview {
  width: 100%;
  max-height: 55dvh;
  object-fit: contain;
  border-radius: 12px;
}
.media-thumb {
  width: min(260px, 100%);
  max-height: 210px;
  object-fit: cover;
  border-radius: 12px;
  display: block;
}
.callhero {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 10px;
  padding: 28px 10px;
  background: radial-gradient(circle, var(--tint), transparent 72%);
}
.callhero .avatar {
  height: 82px;
  width: 82px;
  border-radius: 30px;
  font-size: 27px;
  box-shadow: 0 0 0 12px var(--tint);
}
#minicall,
#toast {
  position: fixed;
  z-index: 15;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: var(--surface);
  border-radius: 18px;
  padding: 10px 18px;
  max-width: 92vw;
  box-shadow: var(--shadow);
}
#minicall {
  top: 12px;
  bottom: auto;
  display: flex;
  gap: 6px;
  align-items: center;
}
#minicall button {
  color: inherit;
}
#toast {
  pointer-events: none;
  text-align: center;
  font-size: 13px;
}
.mobile {
  display: none;
}
.subhead {
  font-size: 12px;
  color: var(--muted);
  margin: 15px 8px 5px;
}
.wave {
  width: 100%;
  height: 44px;
}
.ghostbar button,
.replystrip button {
  color: inherit;
}
.ghosting .main {
  background: linear-gradient(165deg, var(--tint), var(--bg));
}
.wall-dots .main {
  background-image: radial-gradient(var(--line) 1px, transparent 1px);
  background-size: 16px 16px;
}
@keyframes appear {
  from {
    opacity: 0;
    translate: 0 8px;
  }
  to {
    opacity: 1;
    translate: none;
  }
}
.fresh {
  animation: appear 0.2s var(--ease);
}
@media (max-width: 760px) {
  .gate {
    top: 0;
    transform: none;
    display: flex;
    flex-direction: column;
    min-height: 100dvh;
    height: 100dvh;
    max-height: 100dvh;
    border: 0;
    border-radius: 0;
  }
  .splash {
    flex: 0 0 auto;
    padding: 22px 26px 20px;
  }
  .splash .orbit {
    position: absolute;
    width: 130px;
    height: 130px;
    inset-inline-end: 12px;
    bottom: -20px;
    opacity: 0.45;
    z-index: -1;
  }
  .splash .orbit i {
    width: 105px;
    height: 105px;
  }
  .splash .orbit img {
    width: 68px;
    height: 68px;
  }
  .lockup {
    align-self: flex-start;
    margin-bottom: 18px;
  }
  .splash h1 {
    font-size: 27px;
  }
  .splash p:not(.eyebrow) {
    font-size: 13px;
    max-width: 70%;
  }
  .gate-form {
    padding: 24px;
    width: 100%;
  }
  .gate-form h2 {
    font-size: 23px;
  }
  .shell {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr) auto;
  }
  .rail {
    grid-row: 2;
    border: 0;
    border-top: 1px solid var(--line);
    padding: 4px 10px max(4px, env(safe-area-inset-bottom));
    background: var(--surface);
  }
  .rail #tabs {
    display: flex;
    justify-content: space-around;
    width: 100%;
  }
  .rail-brand,
  .rail-lock {
    display: none;
  }
  .tab {
    width: 22%;
    min-height: 46px;
    padding: 4px 2px;
  }
  .sidebar {
    grid-row: 1;
    border: 0;
  }
  .main {
    display: none;
  }
  .shell.open .main {
    display: block;
    grid-row: 1;
    grid-column: 1;
  }
  .shell.open .sidebar {
    display: none;
  }
  .shell.open.chatting {
    grid-template-rows: 1fr;
  }
  .shell.open.chatting .rail {
    display: none;
  }
  .mobile {
    display: inline-grid;
  }
  .brandline {
    padding: 15px 20px 4px;
  }
  .sidehead {
    padding-top: 10px;
  }
  .thread-head {
    padding: 9px 10px;
    padding-top: max(9px, env(safe-area-inset-top));
    gap: 6px;
  }
  .thread-head .ib {
    width: 38px;
  }
  .bubble {
    max-width: 88%;
  }
  dialog {
    margin: auto auto 0;
    width: 100%;
    max-width: 100%;
    max-height: 90dvh;
    border-radius: 24px 24px 0 0;
    padding-bottom: max(22px, env(safe-area-inset-bottom));
  }
  #toast {
    bottom: 75px;
  }
  .detail {
    padding: 16px;
  }
  .composer-wrap {
    padding-inline: 6px;
  }
  .composer {
    gap: 3px;
  }
  .gate-form > .secondary {
    margin-top: 7px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
:root[data-motion='off'] * {
  animation: none !important;
  transition: none !important;
}

.pdf {
  height: 48dvh;
  border: 1px solid var(--line);
}

/* The messenger keeps its olive and parchment palette across the gate, lists, and thread. */
.splash h1 {
  font-size: clamp(2.8rem, 5.5vw, 5rem);
  font-weight: 400;
  line-height: 1.14;
  letter-spacing: -0.06em;
}
.splash h1 em {
  display: block;
  color: #c0d19a;
  font-style: normal;
}
.splash p {
  margin-top: 16px;
}
.lockup {
  align-self: flex-end;
}
.lockup .mark {
  width: 37px;
  height: 37px;
  border-radius: 12px;
}
.orbit img {
  border-radius: 29%;
  width: 104px;
  height: 104px;
  filter: drop-shadow(0 14px 26px #121a1666);
}
.gate {
  min-height: min(710px, 91dvh);
  box-shadow: var(--shadow);
}
.gate-form {
  min-width: 0;
}
.gate-form h2 {
  letter-spacing: -.045em;
  line-height: 1.35;
}
.gate-form > .quiet,
.gate-form > .secondary {
  margin-block-start: 12px;
}
.gate-form .stack > .primary {
  margin-top: 3px;
  min-height: 52px;
}
.primary:not(:disabled):hover {
  background: color-mix(in srgb, var(--primary) 91%, var(--accent));
  color: var(--primary-ink);
}
::placeholder {
  color: var(--muted);
  opacity: .8;
  font-weight: 400;
}
.ib, .primary, .secondary, .danger, .quiet {
  border-radius: 999px;
}
.quiet {
  padding: 8px 13px;
  color: var(--muted);
  min-height: 42px;
}
.quiet:hover {
  background: var(--soft);
  color: var(--ink);
}
.auth-options, .brand-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}
.auth-error {
  color: var(--danger);
  min-height: 0;
  font-size: .9em;
}
.auth-error:empty {
  margin-block-end: -13px;
}
.otp-input, .identity-input, .id-number {
  font-variant-numeric: tabular-nums;
  letter-spacing: .16em;
}
.otp-input {
  min-height: 60px;
  text-align: center;
  font-size: clamp(21px, 5vw, 32px);
  letter-spacing: .28em;
}
.id-number {
  display: block;
  text-align: center;
  line-height: 1.45;
  color: var(--accent);
  font-size: clamp(25px, 7vw, 37px);
}
.profile-card, .request-card {
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
}
.profile-card {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 7px;
  background:
    radial-gradient(ellipse at 50% 0, color-mix(in srgb, var(--profile-tone, var(--accent)) 14%, transparent), transparent 72%),
    var(--soft);
}
.profile-card .actions {
  justify-content: center;
  margin-top: 2px;
}
.profile-status, .trust-label, .request-state {
  font-size: 12px;
  color: var(--accent);
}
[data-profile-accent='olive'] { --profile-tone: #8caa6c; }
[data-profile-accent='slate'] { --profile-tone: #7894ac; }
[data-profile-accent='sand'] { --profile-tone: #ba9e6b; }
[data-profile-accent='mauve'] { --profile-tone: #b78bab; }
.avatar {
  border-radius: 50%;
  background: color-mix(in srgb, var(--profile-tone, var(--accent)) 23%, var(--soft));
  padding: 0;
}
.avatar-photo, .profile-photo {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
}
.profile-avatar {
  width: 106px;
  height: 106px;
  font-size: 41px;
  border: 4px solid color-mix(in srgb, var(--profile-tone, var(--accent)) 29%, var(--line));
  margin-inline: auto;
}
.profile-avatar:disabled { opacity: 1; }
.profile-photo {
  max-height: 65vh;
  border-radius: var(--radius);
}
.avatar-crop {
  display: block;
  margin: 0 auto 8px;
  max-width: 78%;
  border-radius: 50%;
}
input[type='range'] {
  accent-color: var(--accent);
  padding: 0;
}
.request-list {
  display: grid;
  gap: 12px;
}
.request-card {
  display: grid;
  gap: 7px;
}
.request-card .actions { margin-top: 3px; }
.request-card.selected { border-color: var(--accent); }
.request-heading {
  display: flex;
  gap: 10px;
  justify-content: space-between;
  align-items: baseline;
}
.contact-result:empty { display: none; }
.brand-actions .ib { width: 44px; height: 44px; }
.avatar.mini { width: 44px; height: 44px; }
#requests { position: relative; }
#app-update {
  position: fixed;
  z-index: 3;
  inset-inline-end: max(12px, env(safe-area-inset-left));
  bottom: calc(76px + env(safe-area-inset-bottom));
  box-shadow: var(--shadow);
}
.sheet-toast {
  margin-block: 9px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--soft);
  color: var(--ink);
  padding: 8px 12px;
  font-size: .92em;
}
#requests.has-updates::after {
  position: absolute;
  top: 8px;
  inset-inline-end: 9px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  content: '';
  box-shadow: 0 0 0 2px var(--soft);
}
.offline-actions {
  padding: 6px clamp(12px, 3vw, 38px);
  border-bottom: 1px solid var(--line);
}
.offline-actions .chip svg { width: 15px; margin-inline-end: 5px; }
.sidehead h1 {
  font-size: clamp(31px, 4vw, 43px);
  font-weight: 400;
  letter-spacing: -.055em;
}
.side-list .row.active { background: var(--tint); }
.side-list .row {
  border-radius: 20px;
  margin-block: 3px;
}
#side-tools input, .composer textarea { border-radius: 999px; }
.chip.active { background: var(--primary); color: var(--primary-ink); }
.card, .row, input:not([type='checkbox'], [type='range']), textarea, select {
  border-radius: 18px;
}
.main {
  background:
    radial-gradient(ellipse at 95% 100%, #998d6820, transparent 53%),
    radial-gradient(ellipse at 12% 0%, var(--tint), transparent 56%),
    var(--bg);
}
.thread-head, .composer-wrap {
  background: color-mix(in srgb, var(--surface) 84%, transparent);
}
.bubble {
  padding: 11px 15px;
  border-radius: 20px 20px 20px 8px;
}
.bubble.own {
  border-radius: 20px 20px 8px 20px;
}
:root[data-dark='true'] .bubble:not(.own) {
  background: #e7e9e0;
  color: #262e29;
  border-color: #e7e9e0;
}
:root[data-dark='true'] .bubble:not(.own) :is(small, blockquote) { color: #4d5b51; }
:root[data-dark='true'] .bubble:not(.own) .row:hover { background: #d4dccd; }
:root[data-dark='true'] .bubble:not(.own) .tile { background: #d2dcc8; color: #385035; }
:root[data-dark='true'] .bubble:not(.own) .secondary { background: #d6dfd0; color: #30492b; }
.composer textarea { border: 1px solid var(--line); }
.composer .ib { width: 44px; height: 44px; }
.composer #send svg { transform: scaleX(-1); }
.welcome h2 { font-weight: 400; font-size: clamp(29px, 3vw, 42px); }
dialog { box-shadow: 0 24px 90px #0b141066; }
@media (max-width: 760px) {
  .gate { min-height: 100dvh; }
  .splash {
    padding: max(22px, env(safe-area-inset-top)) 25px 26px;
    min-height: 235px;
  }
  .splash h1 { font-size: clamp(2.15rem, 9vw, 3rem); }
  .splash p:not(.eyebrow) { max-width: 80%; margin-top: 10px; }
  .splash .orbit { bottom: -22px; inset-inline-end: 10px; opacity: .24; }
  .splash .orbit img { width: 69px; height: 69px; }
  .gate-form { align-self: stretch; margin-block: auto; padding: 25px 25px 32px; }
  .gate-form h2 { font-size: 25px; }
  .rail {
    grid-column: 1;
    background: var(--surface);
    padding: 6px 14px max(8px, env(safe-area-inset-bottom));
  }
  .rail #tabs {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px;
    background: var(--bg);
  }
  .rail .tab { border-radius: 999px; min-height: 48px; }
  .shell.open .rail { z-index: 1; }
  .brandline { padding: max(14px, env(safe-area-inset-top)) 19px 4px; }
  .thread-head .ib { width: 42px; height: 42px; }
  .thread-head .peer-button { gap: 7px; padding: 0; min-width: 0; }
  .thread-head .peer-button > span:last-child { min-width: 0; }
  .thread-head .peer-button b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .thread-head .peer-button small { line-height: 1.3; }
  .composer { gap: 4px; }
}
