:root {
  color-scheme: dark;
  --bg: #101b26;
  --base: #0d1720;
  --panel: #202e3a;
  --text: #f6f8fb;
  --muted: #bcc8d6;
  --quiet: #a0b1c2;
  --line: #253542;
  --accent: #59afff;
  --primary: #1676d6;
  --incoming: #263542;
  --outgoing: #116ecb;
  --danger: #ffacb0;
  font: 16px/1.38 -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; }
body { background: var(--bg); color: var(--text); overscroll-behavior: none; -webkit-tap-highlight-color: transparent; }
button, input, a { font: inherit; }
button, a, summary { touch-action: manipulation; }
button { color: inherit; cursor: pointer; }
button:disabled { cursor: default; }
button:focus-visible, a:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px;
}
a { color: var(--accent); }
h1, h2, p { margin: 0; }
svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.symbols { position: absolute; width: 0; height: 0; pointer-events: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.shell {
  height: 100vh; height: 100dvh;
  min-height: 0; max-width: 520px; margin: auto;
  background: linear-gradient(148deg,#0e1923,#0d1720 70%);
  padding-top: var(--app-top,0px);
  padding-bottom: max(env(safe-area-inset-bottom, 0px), var(--app-bottom,0px));
  padding-left: env(safe-area-inset-left, 0px); padding-right: env(safe-area-inset-right, 0px);
  display: flex; flex-direction: column;
}
#picker, #stage { min-height: 0; min-width: 0; flex: 1; display: flex; flex-direction: column; }
#stage { display: none; }
body[data-screen="stage"] .shell { background: var(--base); }
body[data-screen="stage"] #picker { display: none; }
body[data-screen="stage"] #stage { display: flex; }
.icon-button { width: 44px; height: 44px; flex: none; display: grid; place-items: center; padding: 0; background: transparent; border: 0; border-radius: 10px; }
.icon-button:hover { background: #ffffff0d; }
.list-head { position: relative; flex: none; display: flex; align-items: center; justify-content: space-between; min-height: 64px; padding: 8px 12px 5px 17px; }
.list-head h1 { font-size: 1.31rem; line-height: 1.2; font-weight: 720; letter-spacing: -.022em; }
.list-menu summary { list-style: none; cursor: pointer; }
.list-menu summary::-webkit-details-marker { display: none; }
.list-menu summary svg { width: 24px; }
.menu-panel { position: absolute; z-index: 2; right: 12px; top: calc(100% - 5px); width: min(240px, calc(100% - 24px)); padding: 13px 15px; border: 1px solid var(--line); border-radius: 13px; background: #1d2b37; box-shadow: 0 8px 24px #0005; font-size: .87rem; }
.menu-panel p { color: var(--muted); margin-top: 4px; }
.search-box { flex: none; display: flex; align-items: center; gap: 12px; background: #202e3a; color: var(--quiet); border: 1px solid #ffffff08; border-radius: 15px; margin: 3px 14px 16px; padding: 0 13px; min-height: 42px; }
.search-box:focus-within { border-color: var(--accent); }
.search-box input { background: none; color: var(--text); border: 0; width: 100%; min-height: 40px; min-width: 0; outline: none; }
.search-box input::placeholder { color: var(--quiet); }
.list-scroll { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.chat-choice { position: relative; }
.chat-choice::after { content: ""; position: absolute; bottom: 0; left: 90px; right: 10px; height: 1px; background: var(--line); pointer-events: none; }
.chat-choice[open], .chat-choice:focus-within { background: #132a3e; }
.chat-choice[open]::after { background: #1e384c; }
.chat-item { width: 100%; min-height: 74px; display: flex; gap: 16px; align-items: center; text-align: left; padding: 8px 13px 8px 17px; list-style: none; cursor: pointer; }
.chat-item::-webkit-details-marker { display: none; }
.chat-item:active { background: #18344b; }
@media (hover:hover) { .chat-item:hover { background: #132a3e; } }
.chat-item:focus-visible { outline-offset: -2px; }
.chat-choice[open] .chat-item > svg { transform: rotate(90deg); }
.choose-actions { padding: 0 14px 10px 90px; }
.choose-actions .primary { min-height: 36px; font-size: .85rem; padding-block: 6px; }
.chat-details { min-width: 0; flex: 1; display: flex; flex-direction: column; justify-content: center; }
.chat-name,.chat-meta { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.chat-name { font-size: 1.08rem; font-weight: 680; line-height: 1.2; }
.chat-meta { font-size: .92rem; color: var(--muted); margin-top: 3px; }
.chat-item > svg { width: 18px; color: var(--quiet); }
.avatar { flex: none; width: 56px; height: 56px; display: grid; place-items: center; border-radius: 50%; color: #fff; font-weight: 680; font-size: 1.18rem; background: linear-gradient(150deg,#ffffff3b,transparent 73%),var(--avatar,#257ac5); }
.avatar.large { width: 76px; height: 76px; margin-inline: auto; font-size: 1.7rem; }
.empty-search { text-align: center; color: var(--muted); padding: 30px 16px; }
#more-chats { display: block; margin: 7px auto; }
.result-head { display: flex; flex: none; align-items: center; gap: 9px; min-height: 65px; padding: 7px 8px 7px 6px; border-bottom: 1px solid #20313e; background: #0e1923; }
.result-head .chat-name { font-size: 1.13rem; }
.result-head .chat-meta { font-size: .87rem; color: var(--quiet); }
.result-head .avatar { width: 44px; height: 44px; margin-right: 3px; font-size: .95rem; }
.result-head > .native-back { width: 39px; }
.export { color: var(--text); }
.archive-footer { display: flex; flex: none; align-items: center; justify-content: center; gap: 10px; min-height: 46px; padding: 8px 12px; border-top: 1px solid #20303c; color: var(--muted); background: #0e1923; font-size: .91rem; }
.archive-footer svg { width: 17px; height: 17px; }
.thread { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; scrollbar-width: thin; background: #101e29 var(--wallpaper, url("/wallpaper.svg?v=light-v8")) repeat center top / 250px auto; }
.thread-content { display: flex; flex-direction: column; padding: 9px 16px 16px; }
.date-chip,.older-chip { align-self: center; margin: 4px 0 10px; padding: 4px 11px; color: var(--text); background: #22313d; border: 0; border-radius: 999px; font-size: .78rem; font-weight: 520; }
.date-chip:not(:first-child) { margin-top: 14px; }
.older-chip { min-height: 34px; color: #9ed0ff; }
.bubble { --bubble: var(--incoming); position: relative; max-width: min(86%,410px); min-width: 0; align-self: flex-start; margin: 2px 0; padding: 7px 10px 6px 12px; border-radius: 16px 16px 16px 6px; background: var(--bubble); overflow-wrap: anywhere; line-height: 1.28; font-size: .96rem; }
.bubble.out { --bubble: var(--outgoing); align-self: flex-end; border-radius: 16px 16px 6px 16px; }
.bubble.tail::after { content: ""; position: absolute; bottom: 0; width: 10px; height: 10px; pointer-events: none; background: var(--bubble); }
.bubble.in.tail::after { left: -6px; clip-path: path("M 0 10 Q 6 7 6 0 L 10 0 L 10 9 Q 6 10 0 10"); }
.bubble.out.tail::after { right: -6px; clip-path: path("M 10 10 Q 4 7 4 0 L 0 0 L 0 9 Q 4 10 10 10"); }
.bubble.break { margin-top: 8px; }
.bubble time { display: inline-block; margin-left: 9px; color: #c1ccda; font-size: .68rem; white-space: nowrap; }
.bubble.out time { color: #ecf5ff; }
.media-bubble { width: min(79%,305px); }
.media-bubble.with-media-only { padding: 0; }
.media-bubble.with-media-only time { position: absolute; z-index: 1; bottom: 5px; right: 9px; pointer-events: none; }
.media-bubble.with-media-only:has(.file-card) time { bottom: 4px; }
.media-bubble.note-bubble { width: max-content; max-width: 84%; }
.note-bubble.with-media-only { background: transparent; }
.note-bubble.tail::after, .photo-bubble.tail::after { display: none; }
.photo-bubble.with-media-only time,.note-bubble.with-media-only time { color: white; background: #0a1119d6; border-radius: 6px; padding: 2px 5px; }
.attachment { display: block; }
.attachment + .attachment { margin-top: 5px; }
.attachment-status { color: var(--muted); font-size: .76rem; padding: 6px 10px 15px; }
.media-tile { width: 100%; text-align: left; border: 0; background: #101b241a; border-radius: 15px; display: flex; gap: 11px; align-items: center; padding: 7px 10px; min-height: 57px; }
.media-tile:hover { background: #ffffff0a; }
.file-card { padding-right: 13px; }
.file-card .media-icon { background: #5e7081; border-radius: 10px; }
.file-card .media-action { width: 19px; height: 19px; margin: 0 1px 10px auto; }
.media-tile.photo-card { aspect-ratio: 1.58; background: linear-gradient(150deg,#253b4b,#1c2c3b); justify-content: center; }
.media-tile.circle, .attachment video.circle { width: clamp(114px,38vw,174px); aspect-ratio: 1; border-radius: 50%; display: grid; place-content: center; justify-items: center; text-align: center; background: #243746; }
.attachment video.circle { object-fit: cover; }
.media-tile.circle .media-title { font-size: .76rem; }
.media-icon { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; flex: none; background: #116ecb; color: #fff; }
.media-title { min-width: 0; overflow-wrap: anywhere; font-size: .9rem; }
.media-title small { display: block; color: #d2dce8; font-size: .73rem; margin-top: 2px; }
.voice-lines { display: block; width: min(100%,165px); height: 21px; color: #aebfd2; }
.voice-card .media-title { flex: 1; }
.media-img, .attachment video { display: block; width: 100%; max-height: 360px; object-fit: contain; border-radius: 15px; background: #0003; }
.attachment audio { display: block; width: 100%; max-width: 100%; }
.attachment.muted-media { padding: 4px 0 2px; font-size: .81rem; color: var(--muted); }
.media-bubble.with-media-only:has(audio) { padding: 3px 3px 19px; }
.media-bubble.with-media-only:has(video:not(.circle)) { padding-bottom: 20px; }
.bubble-copy { display: inline; }
.media-bubble .bubble-copy { display: block; margin-top: 5px; }
.panel-scroll { min-height: 0; overflow: auto; flex: 1; padding: 20px 18px 24px; }
.recovery { width: min(100%,390px); margin: 25px auto 0; text-align: center; padding: 22px 18px; border: 1px solid var(--line); border-radius: 18px; background: var(--panel); }
.hero-icon { width: 49px; height: 49px; margin: 0 auto 14px; display: grid; place-items: center; border-radius: 15px; background: #379fea29; color: var(--accent); }
.recovery h2 { font-size: 1.24rem; line-height: 1.25; overflow-wrap: anywhere; }
.subtitle { color: var(--muted); margin: 8px 0 17px; }
.primary,.secondary,.text-button { min-height: 44px; border: 0; border-radius: 12px; padding: 10px 14px; text-align: center; text-decoration: none; font-weight: 650; }
.primary { display: inline-grid; place-items: center; color: #fff; background: var(--primary); }
.primary:active:not(:disabled) { background: #176abd; }
.primary:disabled { color: #d1e3f2; background: #285472; }
.secondary { background: var(--panel); color: var(--accent); }
.text-button { color: var(--accent); background: none; }
.wide { width: 100%; }
.code-nav { flex: none; padding: clamp(7px,4dvh,46px) 8px 0; }
.code-scroll { padding: 8px 20px 28px; }
.code-page { width: min(100%,424px); margin: 0 auto; text-align: center; }
.code-person p { font-size: 1.24rem; font-weight: 650; overflow-wrap: anywhere; margin: 8px 0 25px; }
.code-page h1 { font-size: clamp(22px,6vw,30px); line-height: 1.17; letter-spacing: -.02em; }
.code-status { color: var(--muted); margin: 8px 0 23px; font-size: .95rem; min-height: 2.7em; }
.code-form { margin: 0 auto; }
.code-field { position: relative; width: 100%; }
.code-cells { display: grid; grid-template-columns: repeat(6,minmax(0,1fr)); gap: clamp(4px,1.65vw,9px); }
.code-cells span { display: grid; place-items: center; min-width: 0; height: clamp(45px,12vw,62px); border: 1px solid #41576b; border-radius: 11px; background: #1b2837; font-size: 1.48rem; font-weight: 650; }
.code-field:focus-within .code-cells span.active { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.code-field:focus-within .code-cells { outline: 2px solid #55baff55; outline-offset: 3px; border-radius: 12px; }
#restore-code { position: absolute; z-index: 1; inset: 0; width: 100%; height: 100%; border: 0; padding: 0; opacity: .02; font-size: 16px; cursor: text; }
.error { font-size: .85rem; color: var(--danger); overflow-wrap: anywhere; }
#restore-error { min-height: 1em; margin: 9px 0 11px; }
.code-page .primary { min-height: 52px; font-size: 1.03rem; }
.code-actions { display: flex; flex-direction: column; align-items: center; margin-top: 7px; }
.code-actions button { font-weight: 500; color: var(--muted); }
.code-actions button:disabled { color: var(--quiet); }
.code-actions a { display: inline-grid; place-items: center; font-size: .87rem; }
@media (max-height: 520px) { .code-person .avatar { width: 63px; height: 63px; } .code-person p { margin-bottom: 15px; } .code-status { margin-bottom: 12px; } }
.native-back { color: var(--text); text-decoration: none; font-size: 1.5rem; }
.native-code { display: block; width: 100%; padding: 12px; border-radius: 10px; margin: 8px 0 12px; color: var(--text); background: var(--base); border: 1px solid var(--line); }
[hidden] { display: none !important; }

.photo-bubble.with-media-only .media-img { aspect-ratio: 1.58; object-fit: contain; }
.voice-card .media-title { font-size: .76rem; color: #d2dce8; }
.voice-player { display: flex; align-items: center; gap: 11px; min-height: 57px; padding: 6px 11px; }
.voice-toggle { border: 0; padding: 0; }
.voice-toggle:hover { background: #187fe4; }
.voice-track { position: relative; flex: 1; min-width: 0; padding-right: 16px; }
.voice-track input[type="range"] { position: absolute; inset: 0 0 auto; width: 100%; height: 26px; margin: 0; opacity: 0; cursor: pointer; }
.voice-track:focus-within { outline: 1px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.voice-duration { display: block; color: var(--muted); font-size: .72rem; }
.media-bubble.with-media-only:has(.voice-player) { padding: 0; }

/* Archive opening: from the code field to the restored thread. */
.restore-scroll {
  display: flex; flex-direction: column; align-items: center;
  padding: clamp(8px,3.5dvh,32px) 18px 22px;
  background: radial-gradient(ellipse at 50% 20%,#123254 0%,#10202f 30%,var(--base) 70%);
}
.restore-progress { width: min(100%,350px); margin: auto 0; text-align: center; animation: restore-in .28s ease-out both; }
.restore-orbit { width: 116px; height: 116px; position: relative; display: grid; place-items: center; margin: 0 auto 16px; }
.restore-orbit i {
  position: absolute; inset: 5px; border: 1px solid #65b5ff35; border-radius: 50%;
  border-top-color: #90d0ff; border-right-color: #419ffc90; animation: restore-spin 1.85s linear infinite;
}
.restore-orbit i:nth-child(2) { inset: 0; opacity: .45; animation-duration: 2.9s; animation-direction: reverse; }
.restore-orbit i:first-child::after {
  content: ""; position: absolute; top: 3px; right: 19px; width: 7px; height: 7px; border-radius: 50%;
  background: #9bd5ff; box-shadow: 0 0 12px 1px #6abeff;
}
.restore-emblem {
  width: 75px; height: 75px; display: grid; place-items: center; border-radius: 24px;
  color: #eef8ff; background: linear-gradient(145deg,#2f91f4,#175aa9);
  border: 1px solid #a9d9ff58; box-shadow: 0 8px 36px #087bfb50,inset 0 1px 1px #e8f6ff50;
}
.restore-emblem svg { width: 34px; height: 34px; stroke-width: 1.55; }
.restore-kicker { color: #9bcdff; letter-spacing: .16em; text-transform: uppercase; font-size: .68rem; font-weight: 710; }
.restore-progress h1 { margin-top: 8px; font-size: clamp(23px,6vw,29px); line-height: 1.13; letter-spacing: -.03em; outline: none; }
.restore-name { color: var(--muted); margin: 8px 0 18px; font-size: .95rem; overflow-wrap: anywhere; }
.restore-steps {
  list-style: none; padding: 4px 10px; margin: 0; text-align: left;
  border-radius: 20px; border: 1px solid #284258; background: #162637d9;
  box-shadow: 0 10px 36px #060d163e;
}
.restore-steps li { display: flex; gap: 11px; min-height: 49px; align-items: center; padding: 6px 3px; color: #a8bbcd; font-size: .89rem; }
.restore-steps li + li { border-top: 1px solid #2a405366; }
.restore-step-icon { display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 10px; color: #9aacc0; background: #213449; }
.restore-step-icon svg { width: 17px; height: 17px; }
.restore-step-icon svg + svg { display: none; }
.restore-steps [data-state="active"] { color: #f1f7ff; font-weight: 650; }
.restore-steps [data-state="active"] .restore-step-icon { color: #c7e8ff; background: #2266a6; animation: restore-pulse 1.4s ease-in-out infinite; }
.restore-steps [data-state="done"] .restore-step-icon { color: #89e5bc; background: #193c3b; }
.restore-steps [data-state="done"] svg:first-child { display: none; }
.restore-steps [data-state="done"] svg + svg { display: block; }
.restore-track { overflow: hidden; margin: 15px 5px 10px; height: 4px; border-radius: 20px; background: #23384a; }
.restore-track span {
  position: relative; display: block; height: 100%; width: 29%; border-radius: inherit;
  background: linear-gradient(90deg,#3485e1,#80caff); transition: width .26s ease-out;
}
.restore-progress[data-step="1"] .restore-track span { width: 67%; }
.restore-progress[data-step="2"] .restore-track span { width: 100%; }
.restore-track span::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg,transparent,#d1ebff6e,transparent); animation: restore-glint 1.5s linear infinite; }
.restore-status { color: var(--muted); font-size: .81rem; min-height: 2.3em; }
.archive-enter { animation: archive-unfold .34s cubic-bezier(.19,.72,.27,1) both; }
@keyframes restore-in { from { opacity: 0; transform: translateY(9px); } to { opacity: 1; transform: translateY(0); } }
@keyframes restore-spin { to { transform: rotate(360deg); } }
@keyframes restore-pulse { 50% { box-shadow: 0 0 0 4px #55aaff25; } }
@keyframes restore-glint { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
@keyframes archive-unfold { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
@media (max-height: 570px) {
  .restore-orbit { width: 87px; height: 87px; margin-bottom: 12px; }
  .restore-emblem { width: 57px; height: 57px; border-radius: 17px; }
  .restore-emblem svg { width: 29px; height: 29px; }
  .restore-steps li { min-height: 41px; }
}
@media (prefers-reduced-motion: reduce) {
  .restore-progress,.restore-orbit i,.restore-steps [data-state="active"] .restore-step-icon,.restore-track span::after,.archive-enter { animation: none; }
  .restore-track span { transition: none; }
}

/* White and blue archive UI, shared by the Mini App and native archive pages. */
:root {
  color-scheme: light;
  --bg: #fff;
  --base: #fff;
  --panel: #f4f8fc;
  --text: #0d141c;
  --muted: #5d6b7b;
  --quiet: #647385;
  --line: #e4eaf1;
  --accent: #086dcc;
  --primary: #0876dc;
  --incoming: #fff;
  --outgoing: #dceeff;
  --danger: #ab253d;
}
.shell, body[data-screen="stage"] .shell { background: #fff; }
#stage { position: relative; }
.archive-nav {
  position: relative; z-index: 4; flex: none; display: grid; grid-template-columns: 42px 1fr 42px;
  align-items: center; gap: 8px; height: 59px; padding: 6px 17px; background: #fff;
}
.nav-title { text-align: center; font-size: 1.14rem; font-weight: 780; letter-spacing: -.03em; }
.icon-button.nav-button { width: 36px; height: 36px; background: #eaf4fd; border-radius: 50%; color: #0d141c; }
.icon-button.nav-button:hover { background: #daebfa; }
.nav-button svg { width: 20px; height: 20px; }
.archive-nav .list-menu { justify-self: end; }
.menu-panel { background: #fff; border-color: #dfebf5; box-shadow: 0 8px 24px #153b6720; right: 17px; }
.list-head { min-height: 100px; padding: 14px 17px 12px; gap: 12px; }
.list-head h1 { font-size: clamp(1.4rem,6vw,1.7rem); letter-spacing: -.035em; font-weight: 780; }
.list-head p { color: var(--muted); margin-top: 4px; font-size: .96rem; }
.list-emblem { display: grid; place-items: center; width: 54px; height: 54px; flex: none; border-radius: 50%;
  background: linear-gradient(155deg,#59befa,#1599ef 66%,#0083e9); color: #fff; }
.list-emblem svg { width: 29px; height: 29px; }
.search-box { margin: 8px 13px 13px; padding-inline: 14px; border: 1px solid transparent; border-radius: 14px; background: #edf2f8; }
.search-box:focus-within { border-color: #8ebff0; }
.search-box input::placeholder { color: #647385; }
.list-label { padding: 5px 17px 7px; font-size: .86rem; color: var(--muted); font-weight: 680; }
.list-scroll { scrollbar-color: #dae8f3 transparent; }
.chat-choice::after { left: 80px; right: 15px; }
.chat-choice[open], .chat-choice:focus-within, .chat-item:active { background: #eef7ff; }
@media (hover:hover) { .chat-item:hover { background: #f3f9ff; } }
.chat-choice[open]::after { background: #d9e8f6; }
.chat-item { min-height: 62px; gap: 13px; padding: 6px 15px 6px 17px; }
.chat-item > svg { color: var(--accent); }
.chat-meta { font-size: .88rem; }
.choose-actions { padding-left: 79px; }
.avatar {
  position: relative; overflow: hidden; width: 49px; height: 49px;
  color: #0758a9; font-size: 1.07rem; background: linear-gradient(145deg,#dcefff,#cae5fb 75%);
}
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: inherit; object-fit: cover; }
.avatar.large { width: 72px; height: 72px; font-size: 1.65rem; }
.archive-footer {
  border: 0; background: transparent; padding: 9px 12px 10px; min-height: 53px; color: var(--accent);
}
.footer-chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 18px; color: var(--accent);
  border-radius: 999px; background: #fffe; box-shadow: 0 4px 16px #153b671a; font-size: .85rem;
}
.result-head { min-height: 64px; padding: 6px 12px 9px 17px; gap: 11px; background: #fff; border-color: var(--line); }
.result-head .avatar { width: 43px; height: 43px; }
.result-head .chat-name { font-weight: 740; }
.export { color: var(--accent); }
.thread { background-color: #f5faff; }
.thread-content { padding-bottom: 64px; }
.thread-footer { position: absolute; inset: auto 0 0; pointer-events: none; margin: 0; }
.date-chip,.older-chip { color: #163656; background: #e0effd; }
.older-chip { color: var(--accent); }
.bubble { box-shadow: 0 0 0 1px #d7e3ef8c; }
.bubble.out { box-shadow: none; }
.bubble time,.bubble.out time { color: #536578; }
.photo-bubble,.note-bubble { box-shadow: none; }
.photo-bubble.with-media-only time,.note-bubble.with-media-only time { background: #fffffff0; color: #213954; }
.media-tile,.media-tile:hover { background: transparent; }
.media-tile.photo-card, .media-tile.circle { background: linear-gradient(145deg,#e5f4ff,#d9ebfd); }
.media-tile.circle .media-title { color: var(--text); }
.media-icon { background: #0874d5; }
.file-card .media-icon { background: #708497; }
.file-card .media-action { color: var(--accent); }
.media-title small,.voice-card .media-title,.voice-lines { color: #5d6b7b; }
.media-img,.attachment video { background-color: #e3effa; }
.recovery { border-color: #dceaf7; background: #f5faff; }
.hero-icon { color: #086dcc; background: #dceeff; }
.primary:active:not(:disabled) { background: #0566c4; }
.primary:disabled { background: #dbeafb; color: #426380; }
.code-scroll { padding: clamp(32px,10.5dvh,89px) 18px 25px; }
.code-page { max-width: 424px; }
.code-person p { margin: 8px 0 25px; font-weight: 740; }
.code-page h1 { font-weight: 780; }
.code-status { margin: 10px 0 20px; }
.bot-handle { color: var(--accent); }
.code-cells span { background: #ebf5ff; border-color: #b7d2eb; }
.code-field:focus-within .code-cells { outline: none; }
.code-field:focus-within .code-cells span.active { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
#restore-error { margin: 7px 0 8px; }
.code-actions { gap: 5px; }
.code-actions a { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 999px; background: #e7f3ff; margin-top: 3px; }
.code-actions a svg { width: 19px; height: 19px; }
.restore-scroll { background: radial-gradient(ellipse at 50% 22%,#e6f4ff 0%,#f7fbff 39%,#fff 74%); }
.restore-kicker { color: #245e96; }
.restore-orbit i { border-color: #9cc5ec; border-top-color: #1183e3; border-right-color: #55a8ef; }
.restore-orbit i:first-child::after { background: #1a86e6; box-shadow: 0 0 9px #83caff; }
.restore-emblem { background: linear-gradient(145deg,#55b9f9,#0875db); box-shadow: 0 7px 24px #0c77dd40; }
.restore-steps { background: #fffffff5; border-color: #d8e8f8; box-shadow: 0 8px 30px #23466611; }
.restore-steps li { color: var(--muted); }
.restore-steps li + li { border-color: #e8eff6; }
.restore-step-icon { background: #edf4fa; color: #507195; }
.restore-steps [data-state="active"] { color: #0b4f93; }
.restore-steps [data-state="active"] .restore-step-icon { color: #075fb6; background: #dceeff; }
.restore-steps [data-state="done"] .restore-step-icon { color: #21633e; background: #e1f5e8; }
.restore-track { background: #deebf7; }
@media (max-height: 570px) { .archive-nav { height: 52px; } .list-head { min-height: 78px; padding-block: 7px; } .code-scroll { padding-top: 20px; } }
.attachment.muted-media { display: grid; gap: 1px; }
.unavailable-name { color: var(--text); font-size: .92rem; }

.access-scroll { padding: 16px 18px 28px; }
.access-flow { width: min(100%,390px); margin-inline: auto; }
.access-heading { font-size: 1.12rem; font-weight: 750; margin-bottom: 16px; }
.access-hero { text-align: center; background: #f2f8fd; border: 1px solid #dceaf7; border-radius: 19px; padding: 20px 14px; }
.access-hero h1 { margin: 0; font-size: 1.36rem; line-height: 1.23; font-weight: 780; }
.access-hero p { color: var(--muted); margin-top: 9px; font-size: .94rem; }
.access-hero .hero-icon { margin-bottom: 12px; }
.access-badge { display: inline-flex; align-items: center; gap: 5px; margin-bottom: 11px; padding: 5px 10px;
  border-radius: 99px; color: #21633e; background: #e1f5e8; font-size: .78rem; font-weight: 730; }
.access-badge svg { width: 15px; height: 15px; }
.access-rows { margin: 16px 0 0; padding: 0 12px; list-style: none; border: 1px solid #dceaf7; border-radius: 15px; }
.access-rows li { display: flex; gap: 10px; align-items: center; padding: 11px 0; font-size: .91rem; }
.access-rows li + li { border-top: 1px solid var(--line); }
.access-rows li svg { width: 20px; height: 20px; color: var(--accent); }
.access-steps { counter-reset: archive-step; }
.access-steps li::before { counter-increment: archive-step; content: counter(archive-step);
  display: grid; place-items: center; width: 25px; height: 25px; flex: none; border-radius: 50%;
  background: var(--primary); color: white; font-size: .8rem; font-weight: 760; }
.access-actions { display: grid; gap: 9px; margin-top: 17px; }
.access-actions .secondary { border: 1px solid #c7e0f7; }
.access-note { text-align: center; font-size: .84rem; color: var(--muted); }
.access-time { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 5px 10px; padding: 12px; font-size: .88rem; }
.access-time span { color: var(--muted); }

/* proofx-full-chat-search-v1 */
.chat-heading { display:flex; align-items:baseline; gap:10px; min-width:0; }
.chat-heading .chat-name { flex:1; min-width:0; }
.chat-time { flex:none; color:var(--muted,#7c8796); font-size:.76rem; font-weight:400; white-space:nowrap; }
.catalog-status { margin:12px 18px; text-align:center; color:var(--muted,#7c8796); font-size:.86rem; }
#retry-catalog { display:block; margin:8px auto; }


/* proofx-web-buttons-outline-v1 */
#web-pay-stars, #web-pay-other {
  background: #ffffff;
  color: #0876dc;
  border: 1.5px solid #0876dc;
  box-shadow: none;
}
#web-pay-stars:active:not(:disabled), #web-pay-other:active:not(:disabled) {
  background: #edf6ff;
  color: #0566c4;
  border-color: #0566c4;
}
#web-pay-stars:disabled, #web-pay-other:disabled {
  background: #ffffff;
  color: #0876dc;
  border-color: #0876dc;
  opacity: .5;
}
