/* Roboto (OFL, fonts.google.com/specimen/Roboto) — шрифт Android. Лицензия: fonts/Roboto-LICENSE.txt */
/* font-display: swap — пока шрифт грузится, текст виден системным, а не пропадает на 1–2 с (RITM-1); снимок ждёт настоящий (TGR.tga.fonts) */
@font-face { font-family: 'RobotoTG'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(fonts/roboto-cyrillic-ext-wght-normal.woff2) format('woff2-variations'); unicode-range: U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F; }
@font-face { font-family: 'RobotoTG'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(fonts/roboto-cyrillic-wght-normal.woff2) format('woff2-variations'); unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family: 'RobotoTG'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(fonts/roboto-greek-wght-normal.woff2) format('woff2-variations'); unicode-range: U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF; }
@font-face { font-family: 'RobotoTG'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(fonts/roboto-vietnamese-wght-normal.woff2) format('woff2-variations'); 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: 'RobotoTG'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(fonts/roboto-latin-ext-wght-normal.woff2) format('woff2-variations'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'RobotoTG'; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url(fonts/roboto-latin-wght-normal.woff2) format('woff2-variations'); 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; }

/* Экран Telegram для Android (render-tga.js): Pixel 9, Android 16, Telegram 12.10. Корень — .tg-screen.tga: лента та же,
   что у Telegram на iPhone (messagesHtml из render.js), вид — Android. Все размеры в dp.
   Сверено: шапка, поле ввода и пузыри — со скрином эмулятора (08.10.2026); шрифт 16, радиус пузыря 17, время 12 и цвета
   светлой темы — из исходников (SharedConfig, Theme, ThemeColors). «≈» — пока без сверки: тёмная тема, хвост пузыря. */
/* .and — экраны WhatsApp и Instagram на Android (render-wa.js, render-ig.js): тот же шрифт и системные части */
.tg-screen.tga, .tg-screen.and { font-family: "TGArabic", "RobotoTG", Roboto, system-ui, sans-serif, "Apple Color Emoji"; }

/* строка состояния Android 16: часы слева, справа Wi-Fi, сеть, батарея */
.tg-screen:is(.tga, .and) .a-sb { position: absolute; top: 0; left: 0; right: 0; z-index: 7; color: var(--a-sb); }
.tg-screen:is(.tga, .and) .a-clock { position: absolute; left: 16.4px; top: 17.5px; font-size: 14px; font-weight: 500; line-height: 19px; letter-spacing: .1px; }
.tg-screen:is(.tga, .and) .a-sbi { position: absolute; right: 28.6px; top: 19.5px; height: 15px; display: flex; align-items: center; gap: 4.6px; }
.tg-screen:is(.tga, .and) .a-sbi svg { display: block; }

/* шапка: три «пилюли» 46 dp — назад, собеседник, звонок с меню */
.tg-screen.tga .a-nav { position: absolute; left: 6px; right: 6.5px; z-index: 6; height: 46px; display: flex; gap: 6.2px; color: var(--a-ic); }
.tg-screen.tga .a-pill { height: 46px; border-radius: 23px; background: var(--a-pill); box-shadow: 0 .5px 2.5px rgba(0,0,0,.16), 0 0 0 .33px rgba(0,0,0,.05); display: flex; align-items: center; }
.tg-screen.tga .a-back { flex: none; width: 46px; justify-content: center; }
.tg-screen.tga .a-who { flex: 1; min-width: 0; padding: 0 14px 0 2.4px; }
.tg-screen.tga .a-who .ava { flex: none; border-radius: 50%; overflow: hidden; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 500; }
.tg-screen.tga .a-who .ava img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tg-screen.tga .a-ttl { flex: 1; min-width: 0; margin-left: 8.6px; }
.tg-screen.tga .a-name { display: flex; align-items: center; gap: 4px; font-size: 18px; font-weight: 500; line-height: 22px; letter-spacing: -.1px; color: var(--a-fg); white-space: nowrap; overflow: hidden; }
.tg-screen.tga .a-name > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.tg-screen.tga .a-name > svg { flex: none; }
.tg-screen.tga .a-st { margin-top: -1px; font-size: 14px; line-height: 17px; color: var(--a-sub); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tg-screen.tga .a-st.acc { color: var(--a-acc); }
.tg-screen.tga .a-acts { flex: none; padding: 0 2px; }
.tg-screen.tga .a-acts span { width: 39.3px; height: 46px; display: flex; align-items: center; justify-content: center; }
.tg-screen.tga .a-nav svg { display: block; }
/* звезда Premium у имени — 12 dp, цвет ссылок темы (замер эмулятора: #5db2f8 ночью, #229af0 днём) */
.tg-screen.tga .a-name .emo-st.star { --acc: var(--a-star); width: 16.4px; height: 16.4px; flex: none; }

/* лента: пузыри в 11.4 dp от краёв, текст 16/18.75, время 12 */
.tg-screen.tga .msgs { padding: 0 11.4px; }
.tg-screen.tga .bub { padding: 6.4px 9.5px 6.8px 11.5px; font-size: 16px; line-height: 18.75px; letter-spacing: 0; }
/* фото, альбом и фото с подписью — во весь пузырь с полями 2, как у iPhone: отступы текстового пузыря сдвигали медиа вправо за край (RADIUS-01) */
.tg-screen.tga .bub.media { padding: 2px; }
.tg-screen.tga .meta, .tg-screen.tga .ghost { font-size: 12px; line-height: 14px; letter-spacing: 0; gap: 3.5px; }
.tg-screen.tga .meta { bottom: 5px; inset-inline-end: 9.5px; }
.tg-screen.tga .out .meta { inset-inline-end: 8px; }
.tg-screen.tga .txt b { font-weight: 500; }
.tg-screen.tga .reply .rn, .tg-screen.tga .fwd, .tg-screen.tga .fwd b { font-weight: 500; }
/* «Переслано от» — две строки обычным начертанием, без кружка-аватара; время отделено от текста на 8 dp */
.tg-screen.tga .fwd, .tg-screen.tga .fwd b, .tg-screen.tga .fwd-n, .tg-screen.tga .fwd-n span { font-weight: 400; font-size: 14.6px; line-height: 19.5px; }
.tg-screen.tga .fwd .mini-ava { display: none; }
.tg-screen.tga .ghost { margin-inline-start: 8px; }
.tg-screen.tga .svc { margin: 8.5px 0 6.7px; }   /* плашка даты: над ней 8.7 dp, под ней 13.7 dp до пузыря (замер 25.10.2026) */
.tg-screen.tga .svc span { font-size: 14px; font-weight: 500; line-height: 18px; letter-spacing: 0; padding: 2.2px 9px; border-radius: 12px; }

/* поле ввода: одна белая «пилюля» 44 dp во всю ширину, справа в ней синий круг 37.3 dp */
.tg-screen.tga .a-inp { position: absolute; left: 7.2px; right: 7.2px; z-index: 6; min-height: 44px; border-radius: 22px; background: var(--a-inp-bg, var(--a-pill)); box-shadow: 0 .5px 2.5px rgba(0,0,0,.16), 0 0 0 .33px rgba(0,0,0,.05);
  display: flex; align-items: flex-end; color: var(--a-ico); }
.tg-screen.tga .a-inp > span { flex: none; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; }
.tg-screen.tga .a-inp > .a-emo { margin-left: 3px; }
.tg-screen.tga .a-txt { flex: 1; min-width: 0; align-self: center; margin-left: 3.2px; padding: 11px 0; font-size: 18px; line-height: 22px; color: var(--a-fg); white-space: pre-wrap; overflow-wrap: anywhere; }
.tg-screen.tga .a-txt.ph { color: var(--a-hint); white-space: nowrap; overflow: hidden; }
.tg-screen.tga .a-caret { display: inline-block; width: 2px; height: 22px; margin: 0 0 -4px 1px; border-radius: 1px; background: var(--a-acc); }
.tg-screen.tga .a-inp > .a-mic { width: 37.3px; height: 37.3px; margin: 0 3.35px 3.35px 3px; border-radius: 50%; background: var(--a-send); color: #fff; }
.tg-screen.tga .a-inp svg { display: block; }

/* режим выделения (замер эмулятора 25.10.2026): кружок 22.8 dp с белой обводкой 1.5 dp, центр в 18.5 dp от края экрана
   и в 16 dp над низом пузыря; выбранный — зелёный с галочкой; полоса выбранной строки — на всю ширину, 3.4 dp над пузырём
   и 2 dp под ним; входящие отъезжают на 35 dp */
.tg-screen.tga .msgs.a-selm > .row.in > .col, .tg-screen.tga .msgs.a-selm > .row.in.free > .col { margin-left: 35px; }
.tg-screen.tga .a-ck { position: absolute; left: -4.3px; bottom: 4.6px; width: 22.8px; height: 22.8px; box-sizing: border-box; border-radius: 50%;
  border: 1.5px solid #fff; background: rgba(0,0,0,.1); }
.tg-screen.tga .a-ck.on { background: #5ec245 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m5.6 10.4 3 3 5.9-6.2' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 100% no-repeat; }
.tg-screen.tga .row.a-sel::before { content: ''; position: absolute; left: -11.4px; right: -11.4px; top: -3.4px; bottom: -2px; z-index: -1; background: rgba(32,52,74,.5); }
.tg-screen.tga.theme-light .row.a-sel::before { background: rgba(10,144,240,.16); }
.tg-screen.tga .a-selt { flex: 1; min-width: 0; padding: 1.5px 12px 0 16.5px; font-size: 18.3px; font-weight: 500; line-height: 22px; color: var(--a-fg); white-space: nowrap; overflow: hidden; }
.tg-screen.tga .a-selt span { display: block; overflow: hidden; text-overflow: ellipsis; }
.tg-screen.tga .a-nav .a-sela { padding: 0 3.8px; margin-left: .7px; }
.tg-screen.tga .a-nav .a-sela span { width: 37.4px; }
.tg-screen.tga .a-selb { position: absolute; left: 8.4px; right: 8.4px; z-index: 6; display: flex; gap: 12.6px; }
.tg-screen.tga .a-selbtn { flex: 1; min-width: 0; height: 42.7px; border-radius: 21.4px; background: var(--a-inp-bg, var(--a-pill)); box-shadow: 0 .5px 2.5px rgba(0,0,0,.16), 0 0 0 .33px rgba(0,0,0,.05);
  display: flex; align-items: center; justify-content: center; gap: 8.5px; padding-top: .8px; font-size: 15px; font-weight: 500; color: #ababac; white-space: nowrap; }
.tg-screen.tga.theme-light .a-selbtn { color: var(--a-sub); }
.tg-screen.tga .a-selbtn svg { display: block; flex: none; }

/* голосовое (ChatMessageCell, замер эмулятора 25.10.2026): пузырь 72 dp, кружок 43.8 dp в (11.8, 9.9), волна — столбики 2 dp
   через 3 dp по центру полосы 14 dp (SeekBarWaveform), линия на 25.3 dp от верха; «00:04» 12 sp под волной, время — в углу */
.tg-screen.tga .vbub.avb { height: 72px; padding: 0; position: relative; }
.tg-screen.tga .av { position: absolute; inset: 0; display: block; }
.tg-screen.tga .av .play { position: absolute; left: 11.8px; top: 9.9px; width: 43.8px; height: 43.8px; color: var(--in-bg); }
.tg-screen.tga .out .av .play { color: var(--out-bg); }
.tg-screen.tga .av .play svg { margin-inline-start: 2.5px; }
.tg-screen.tga .av .vr { position: absolute; left: 68.6px; top: 17.3px; width: 161px; padding: 0; display: block; }
.tg-screen.tga .av .wave { height: 16px; align-items: center; gap: 1px; }
.tg-screen.tga .av .vd { position: absolute; left: 66.3px; top: 40.2px; font-size: 12px; line-height: 16px; display: flex; align-items: center; gap: 4px; color: var(--in-meta); }
.tg-screen.tga .out .av .vd { color: var(--out-meta); }
.tg-screen.tga .av .vd .dot { width: 4px; height: 4px; border-radius: 50%; }
.tg-screen.tga .avb .meta { bottom: 2.7px; }

/* реакция в пузыре (ReactionsLayoutInBubble, замер 25.10.2026): плашка 26 dp, аватар 20.3 dp — ниже и уже, чем на iPhone */
.tg-screen.tga .rpill { height: 26px; border-radius: 13px; padding-inline: 8px 3px; gap: 4px; }
.tg-screen.tga .reacts { margin: 7.2px 0 1.5px; }   /* плашка на 32.4 dp от верха пузыря, под ней 8.3 dp */
.tg-screen.tga .rpill .ava { width: 20.3px !important; height: 20.3px !important; font-size: 9px !important; }

/* меню по нажатию (render-hold.js, htmlA): строка реакций 303.6×48, карточка 200.8; тёмное #282829, светлое — белое */
.tg-screen.tga .ah { position: absolute; inset: 0; z-index: 9; pointer-events: none; --ah-bg: #ffffff; --ah-gap: #f2f2f2; --ah-fg: #1a1d21; --ah-xbg: #babbbc; --ah-x: #ffffff; }
.tg-screen.tga .ah::before { content: ''; position: absolute; inset: 0; background: rgba(0,0,0,.2); }   /* экран под меню темнее на 20 % (замер) */
.tg-screen.tga.theme-dark .ah { --ah-bg: #282829; --ah-gap: #353536; --ah-fg: #ffffff; --ah-xbg: #616161; --ah-x: #1e1e1e; }
.tg-screen.tga .ah-front { position: absolute; inset: 0; }
.tg-screen.tga .ah-front .lp-msgs { position: absolute; left: 0; right: 0; top: 0; bottom: auto; transform: none; padding: 0 11.4px; }
.tg-screen.tga .ah-bar { position: absolute; width: 303.6px; height: 48px; border-radius: 24px; background: var(--ah-bg); display: flex; align-items: center; padding-left: 12.6px; box-sizing: border-box;
  box-shadow: 0 2px 8px rgba(0,0,0,.18); }
.tg-screen.tga .ah-r { width: 35.6px; height: 48px; display: flex; align-items: center; justify-content: center; flex: none; }
.tg-screen.tga .ah-r img { width: 28px; height: 28px; }
.tg-screen.tga .ah-r .tg-react { width: 39px; height: 39px; margin: -1.7px; }   /* рисунок реакции ≈ 30 dp (файл с полями, как .lp-r) */
.tg-screen.tga .ah-x { position: absolute; left: 261.2px; top: 8.75px; width: 30.5px; height: 30.5px; border-radius: 50%; background: var(--ah-xbg); color: var(--ah-x); display: flex; align-items: center; justify-content: center; }
.tg-screen.tga .ah-c1, .tg-screen.tga .ah-c2 { position: absolute; border-radius: 50%; background: var(--ah-bg); }
.tg-screen.tga .ah-c1 { width: 9px; height: 9px; }
.tg-screen.tga .ah-c2 { width: 5.2px; height: 5.2px; }
.tg-screen.tga .ah-menu { position: absolute; width: 200.8px; border-radius: 8px; background: var(--ah-bg); color: var(--ah-fg); overflow: hidden; box-shadow: 0 2px 10px rgba(0,0,0,.2); }
.tg-screen.tga .ah-info { height: 36.2px; display: flex; align-items: center; gap: 0; padding-left: 21px; font-size: 14px; letter-spacing: -.1px; }
.tg-screen.tga .ah-info svg { flex: none; width: 16px; height: 16px; margin-right: 1.2px; }
.tg-screen.tga .ah-info span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 4px; }
.tg-screen.tga .ah-gap { height: 7.6px; background: var(--ah-gap); }
.tg-screen.tga .ah-row { height: 48px; display: flex; align-items: center; padding-left: 21px; font-size: 16px; letter-spacing: 0; }
.tg-screen.tga .ah-row svg { flex: none; margin-right: 16.8px; }
.tg-screen.tga .ah svg { display: block; }

/* профиль собеседника (render-profile.js, renderA; замер эмулятора 25.10.2026) */
.tg-screen.tga.pa-on .pa-page { position: absolute; inset: 0; }
.tg-screen.tga.pa-on .pa-top { position: absolute; left: 0; right: 0; top: 0; height: 335px; }
.tg-screen.tga.pa-on .pa-back, .tg-screen.tga.pa-on .pa-more { position: absolute; top: 69px; display: flex; z-index: 2; }
.tg-screen.tga.pa-on .pa-back { left: 16px; }
.tg-screen.tga.pa-on .pa-more { right: 18.4px; }
.tg-screen.tga.pa-on .pa-ava { position: absolute; left: 157.7px; top: 88px; width: 96px; height: 96px; }
.tg-screen.tga.pa-on .pa-ava .ava { border-radius: 50%; overflow: hidden; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 500; font-size: 40px !important; }
.tg-screen.tga.pa-on .pa-ava .ava img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tg-screen.tga.pa-on .pa-name { position: absolute; left: 20px; right: 20px; top: 200.5px; height: 27px; display: flex; align-items: center; justify-content: center; gap: 4px; font-size: 22px; font-weight: 500; line-height: 27px; white-space: nowrap; }
.tg-screen.tga.pa-on .pa-name .nm-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.tg-screen.tga.pa-on .pa-name .emo-st.star { --acc: var(--a-star); width: 19px; height: 19px; flex: none; }
.tg-screen.tga.pa-on .pa-name > svg, .tg-screen.tga.pa-on .pa-name .emo-st { flex: none; }
.tg-screen.tga.pa-on .pa-st { position: absolute; left: 20px; right: 20px; top: 226px; text-align: center; font-size: 15px; line-height: 18px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tg-screen.tga.pa-on .pa-btn { position: absolute; top: 271px; width: 89.8px; height: 52px; border-radius: 12px; display: flex; flex-direction: column; align-items: center; padding-top: 4.6px; box-sizing: border-box; }
.tg-screen.tga.pa-on .pa-btn svg { display: block; flex: none; }
.tg-screen.tga.pa-on .pa-btn span { margin-top: 3px; font-size: 12px; font-weight: 500; line-height: 14px; letter-spacing: .1px; white-space: nowrap; }
.tg-screen.tga.pa-on .pa-card { position: absolute; left: 12.7px; right: 12.7px; border-radius: 16px; box-sizing: border-box; }
.tg-screen.tga.pa-on .pa-user { height: 60.6px; padding: 9.5px 56px 0 17.3px; }
.tg-screen.tga.pa-on .pa-v { font-size: 17px; line-height: 21px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tg-screen.tga.pa-on .pa-l { margin-top: 3px; font-size: 14px; line-height: 17px; }
.tg-screen.tga.pa-on .pa-qr { position: absolute; right: 17px; top: 15.3px; width: 30px; height: 30px; }
.tg-screen.tga.pa-on .pa-qri { width: 30px; height: 30px; fill: currentColor; display: block; }
.tg-screen.tga.pa-on .pa-add { height: 49.4px; display: flex; align-items: center; font-size: 17px; }
.tg-screen.tga.pa-on .pa-ai { width: 24px; margin: 0 22.6px 0 15px; display: flex; }
.tg-screen.tga.pa-on .pa-ai svg { display: block; }
.tg-screen.tga.pa-on .pa-tab { position: absolute; left: 50%; transform: translateX(-50%); height: 36px; padding: 3px; border-radius: 18px; box-sizing: border-box; }
.tg-screen.tga.pa-on .pa-tab span { display: block; height: 30px; padding: 0 14px; border-radius: 15px; font-size: 16px; font-weight: 500; line-height: 30px; }
.tg-screen.tga.pa-on .pa-vl { padding: 0; overflow: hidden; }
.tg-screen.tga.pa-on .pa-vr { height: 56px; display: flex; align-items: center; }
.tg-screen.tga.pa-on .pa-vp { flex: none; width: 44px; height: 44px; margin: 0 16.4px 0 11.4px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; }
.tg-screen.tga.pa-on .pa-vp svg { display: block; fill: currentColor; }
.tg-screen.tga.pa-on .pa-vt { flex: 1; min-width: 0; padding-right: 12px; }
.tg-screen.tga.pa-on .pa-vw { font-size: 15.3px; font-weight: 500; line-height: 20px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tg-screen.tga.pa-on .pa-vs { margin-top: -.9px; font-size: 13.4px; line-height: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* плашка «играет голосовое» под шапкой */
.tg-screen.tga .a-mp { position: absolute; left: 7.2px; right: 7.6px; z-index: 6; height: 35px; border-radius: 17.5px; background: var(--a-pill); overflow: hidden; display: flex; align-items: center;
  box-shadow: 0 .5px 2.5px rgba(0,0,0,.16), 0 0 0 .33px rgba(0,0,0,.05); }
.tg-screen.tga .a-mp-pp { position: absolute; left: 20.4px; top: 9.5px; color: var(--a-send); display: flex; }
.tg-screen.tga .a-mp-pp svg { display: block; }
.tg-screen.tga .a-mp-t { position: absolute; left: 37.8px; right: 80px; top: 8px; font-size: 15px; line-height: 19px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--a-fg); }
.tg-screen.tga .a-mp-t b { font-weight: 500; }
.tg-screen.tga .a-mp-t span { color: var(--a-sub); }
.tg-screen.tga .a-mp-rate { position: absolute; right: 42px; top: 9px; height: 15px; padding: 0 2.5px; border: 1.6px solid var(--a-ico); border-radius: 4px; color: var(--a-ico); font-size: 11px; font-weight: 700; line-height: 15px; box-sizing: content-box; }
.tg-screen.tga .a-mp-x { position: absolute; right: 16px; top: 11.5px; color: var(--a-ico); display: flex; }
.tg-screen.tga .a-mp .mp-line { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; }
.tg-screen.tga .a-mp .mp-line i { display: block; height: 100%; background: var(--a-send); }

/* цвет значков — стилем: Mini App сбрасывает fill и stroke у svg внутри телефона (значки на плитках профиля выходили чёрными) */
.tg-screen.tga .pa-btn svg, .tg-screen.tga .pa-more svg { fill: currentColor; }
.tg-screen.tga .ah svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* хвост пузыря Android: выступает на 6 dp, высота 8.5 dp */
.tg-screen.tga .in .tail { left: -6px; }
.tg-screen.tga .out .tail { right: -6px; }

/* Gboard */
.tg-screen:is(.tga, .and) .a-kb { position: absolute; left: 0; right: 0; bottom: 0; z-index: 7; background: var(--k-bg); color: var(--k-fg); font-family: "RobotoTG", Roboto, sans-serif; }
.tg-screen:is(.tga, .and) .a-kb .k { position: absolute; height: 46.5px; border-radius: 6px; background: var(--k-key); display: flex; align-items: center; justify-content: center; font-size: 22px; line-height: 1; }
.tg-screen:is(.tga, .and) .a-kb .k.fn { background: var(--k-fn); }
.tg-screen:is(.tga, .and) .a-kb .k.pill { height: 46.9px; border-radius: 23.45px; font-size: 16px; font-weight: 500; letter-spacing: .1px; }   /* овал во всю высоту клавиши — замер Gboard */
.tg-screen:is(.tga, .and) .a-kb .k.ce { flex-direction: column; justify-content: flex-end; padding-bottom: 6px; box-sizing: border-box; line-height: .8; }
.tg-screen:is(.tga, .and) .a-kb .k-ce { display: block; margin-bottom: 5px; opacity: .85; }
.tg-screen:is(.tga, .and) .a-kb .k-lang { font-size: 14.5px; font-weight: 400; letter-spacing: .1px; color: var(--k-fg); }
.tg-screen:is(.tga, .and) .a-kb .k i { position: absolute; top: 3.2px; right: 4.6px; font-style: normal; font-size: 10px; line-height: 12px; color: var(--k-hint); }
.tg-screen:is(.tga, .and) .a-kb svg { display: block; }
.tg-screen:is(.tga, .and) .k-ti { position: absolute; top: 5px; width: 33.5px; height: 33.5px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.tg-screen:is(.tga, .and) .k-ti b { font-size: 13px; font-weight: 800; letter-spacing: .2px; }
.tg-screen:is(.tga, .and) .k-ti.mic { background: var(--k-key); }
.tg-screen:is(.tga, .and) .k-sugg { position: absolute; left: 45px; right: 45px; top: 5px; height: 33.5px; display: flex; align-items: center; font-size: 17px; }
.tg-screen:is(.tga, .and) .k-sugg span { flex: 1; min-width: 0; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tg-screen:is(.tga, .and) .k-sugg i { flex: none; width: 1px; height: 20px; background: color-mix(in srgb, var(--k-fg) 28%, transparent); }
.tg-screen:is(.tga, .and) .k-down { position: absolute; left: 35.7px; color: var(--k-fg); }

/* баннер-уведомление Android 16 */
.tg-screen:is(.tga, .and) .a-app { display: flex; align-items: center; gap: 7px; left: 9px; font-weight: 400; }
.tg-screen:is(.tga, .and) .a-nt { position: absolute; left: 16px; right: 16.4px; top: 62.5px; z-index: 9; height: 122.7px; border-radius: 28px; background: var(--n-bg); color: var(--n-fg);
  box-shadow: 0 2px 8px rgba(0,0,0,.18); font-family: "RobotoTG", Roboto, sans-serif; }
.tg-screen:is(.tga, .and) .nt-ava { position: absolute; left: 16px; top: 24px; width: 40px; height: 40px; }
.tg-screen:is(.tga, .and) .nt-ava .ava { border-radius: 50%; overflow: hidden; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 500; }
.tg-screen:is(.tga, .and) .nt-ava .ava img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tg-screen:is(.tga, .and) .nt-bdg { position: absolute; right: -4px; bottom: -4px; width: 18px; height: 18px; border-radius: 50%; background: var(--n-bg); color: var(--n-app, #1e96e0); display: flex; align-items: center; justify-content: center; }
.tg-screen:is(.tga, .and) .nt-bdg svg { width: 10.5px; height: 9.5px; }
.tg-screen:is(.tga, .and) .nt-app { width: 40px; height: 40px; border-radius: 50%; background: var(--n-app, #1e96e0); color: #fff; display: flex; align-items: center; justify-content: center; }
.tg-screen:is(.tga, .and) .nt-app svg { width: 21px; height: 19px; margin-left: -2px; }
/* значки WhatsApp и Instagram — квадратные, без сдвига под самолётик */
.tg-screen:is(.tga, .and) .nt-bdg.sq svg { width: 11.5px; height: 11.5px; }
.tg-screen:is(.tga, .and) .nt-app.sq svg { width: 23px; height: 23px; margin-left: 0; }
.tg-screen:is(.tga, .and) .nt-h { position: absolute; left: 81px; right: 56px; top: 24.6px; display: flex; align-items: center; gap: 4.5px; font-size: 12.5px; line-height: 16px; white-space: nowrap; overflow: hidden; }
.tg-screen:is(.tga, .and) .nt-h b { font-weight: 400; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.tg-screen:is(.tga, .and) .nt-h svg { flex: none; margin-left: 1px; }
.tg-screen:is(.tga, .and) .nt-t { position: absolute; left: 81px; right: 56px; top: 44.5px; font-size: 14px; line-height: 19px; color: var(--n-fg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tg-screen:is(.tga, .and) .nt-x { position: absolute; right: 16px; top: 31.6px; width: 23.6px; height: 23.6px; border-radius: 50%; background: var(--n-chev); color: var(--n-strong); display: flex; align-items: center; justify-content: center; }
.tg-screen:is(.tga, .and) .nt-a { position: absolute; left: 81px; right: 18px; top: 84px; height: 20px; display: flex; align-items: center; gap: 28px; font-size: 14px; font-weight: 450; letter-spacing: .1px; color: var(--n-act); }
.tg-screen:is(.tga, .and) .nt-a svg { margin-left: auto; }
.tg-screen:is(.tga, .and) .nt-a span { white-space: nowrap; flex: none; }   /* длинные подписи («Als gelesen markieren») — в одну строку */
.tg-screen:is(.tga, .and) .a-nt svg { display: block; }

/* полоса жестов */
.tg-screen:is(.tga, .and) .a-home { position: absolute; left: 50%; bottom: 10.1px; z-index: 8; width: 108px; height: 3.8px; margin-left: -54px; border-radius: 2px; background: var(--a-home); }

/* карточка «Не в контактах» — по UserInfoCell из исходников Telegram для Android: скругление 16 dp, поля 14 / 16 dp,
   имя и подпись 14 sp, строки 12 sp высотой 14 dp через 7 dp, между ключом и значением 7.66 dp, сноска 12 sp */
.tg-screen.tga .nc-card-w { margin: 8px 0; }
.tg-screen.tga .nc-card { padding: 14px 16px; border-radius: 16px; font-family: inherit; }
.tg-screen.tga .nc-name { font-size: 14px; font-weight: 500; line-height: 16.4px; letter-spacing: 0; }
.tg-screen.tga .nc-sub { font-size: 14px; line-height: 16.4px; margin-top: 3px; opacity: .7; }
.tg-screen.tga .nc-rows { margin-top: 11px; gap: 7px 7.66px; }
.tg-screen.tga .nc-key { font-size: 12px; line-height: 14px; opacity: .7; }
.tg-screen.tga .nc-value { font-size: 12px; line-height: 14px; font-weight: 500; }
.tg-screen.tga .nc-warn { margin: 12px 0 1.33px; gap: 5px; font-size: 12px; line-height: 14px; opacity: .7; }
.tg-screen.tga .nc-i { width: 13.2px; height: 13.2px; font-size: 9.5px; }
.tg-screen.tga .nc-card-w { transform: none !important; }   /* на Android карточка — обычная строка ленты, над первой датой; вверх, как в iOS, не поднимается */

/* полоса нового чата «Добавить · Заблокировать» (topChatPanelView): плашка 44 dp под шапкой */
.tg-screen.tga .a-nc { position: absolute; left: 6.9px; right: 6.9px; z-index: 6; height: 44px; border-radius: 22px; background: var(--a-pill); display: flex; align-items: center;
  box-shadow: 0 .5px 2.5px rgba(0,0,0,.16), 0 0 0 .33px rgba(0,0,0,.05); padding: 0 31px 0 0; box-sizing: border-box; }
.tg-screen.tga .a-nc-b { flex: 1; min-width: 0; height: 36px; margin: 0 4px; border-radius: 18px; display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tg-screen.tga .a-nc-b.add { color: var(--a-acc); background: color-mix(in srgb, var(--a-acc) 10%, transparent); }
.tg-screen.tga .a-nc-b.blk { color: #cc4747; background: rgba(204,71,71,.1); margin-left: 0; }
.tg-screen.tga.theme-dark .a-nc-b.blk { color: #e86a6a; background: rgba(232,106,106,.12); }
.tg-screen.tga .a-nc-x { position: absolute; right: 11px; top: 50%; margin-top: -7px; color: var(--a-ico, var(--a-sub)); display: flex; }
/* закреп (pinnedMessageView): плашка 48 dp, как полоса нового чата; размеры и цвета — из исходников и darkblue.attheme */
.tg-screen.tga .a-pin { position: absolute; left: 6.9px; right: 6.9px; z-index: 6; height: 48px; border-radius: 24px; background: var(--a-pill);
  box-shadow: 0 .5px 2.5px rgba(0,0,0,.16), 0 0 0 .33px rgba(0,0,0,.05); overflow: hidden; }
.tg-screen.tga .a-pin-l { position: absolute; left: 13.5px; top: 8px; bottom: 8px; width: 2px; border-radius: 1px; background: #3fa8ef; }
.tg-screen.tga .a-pin-t, .tg-screen.tga .a-pin-s { position: absolute; left: 23px; right: 44px; height: 18px; font-size: 14px; line-height: 18px; letter-spacing: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tg-screen.tga .a-pin-t { top: 7.3px; font-weight: 500; color: var(--a-acc); }
.tg-screen.tga .a-pin-s { top: 25.3px; color: #767e7c; }
.tg-screen.tga .a-pin-x { position: absolute; right: 2px; top: 0; width: 36px; height: 48px; display: flex; align-items: center; justify-content: center; color: #818786; }
.tg-screen.tga.theme-dark .a-pin-l { background: #5e9dd4; }
.tg-screen.tga.theme-dark .a-pin-s, .tg-screen.tga.theme-dark .a-pin-x { color: rgba(220,234,255,.43); }
/* кнопка «вниз»: кружок 44 dp того же стекла, что плашки шапки; счётчик — на его верхнем крае */
.tg-screen.tga .down-btn.a-down { right: 7px; width: 44px; height: 44px; background: var(--a-pill); color: var(--a-ico); -webkit-backdrop-filter: none; backdrop-filter: none;
  box-shadow: 0 .5px 2.5px rgba(0,0,0,.16), 0 0 0 .33px rgba(0,0,0,.05); }
.tg-screen.tga .down-btn.a-down svg { margin-top: 2px; }
.tg-screen.tga .a-down-n { position: absolute; left: 50%; top: -11.5px; transform: translateX(-50%); min-width: 23px; height: 23px; padding: 0 5.5px; box-sizing: border-box; border-radius: 11.5px;
  background: #229af0; color: #fff; font-size: 13px; font-weight: 500; line-height: 23px; text-align: center; white-space: nowrap; }
.tg-screen.tga.theme-dark .a-down-n { background: #51aaee; }
