/* Uses the existing app palette. No inline CSS under the app's strict CSP. */
.has-ankihu-modal .app-screen { overflow: hidden; }
.ankihu-modal {
  width: min(100% - 24px, 480px); max-height: calc(100dvh - 32px);
  margin: auto; padding: 0; border: 1px solid var(--line); border-radius: 22px;
  color: var(--text); background: var(--bg); box-shadow: 0 16px 56px #0008;
  overscroll-behavior: contain;
}
.ankihu-modal::backdrop { background: #0009; }
.ankihu-modal__header {
  position: sticky; top: 0; z-index: 1; display: flex; align-items: center;
  justify-content: space-between; gap: 12px; padding: 8px 12px 8px 20px;
  background: var(--bg); border-bottom: 1px solid var(--line);
}
.ankihu-modal__header h2 { margin: 0; font-size: 20px; overflow-wrap: anywhere; }
.ankihu-modal__close { flex: none; width: 48px; height: 48px; display: grid; place-items: center; }
.ankihu-modal__body { padding: 16px 20px calc(20px + var(--safe-bottom)); }
.chat-entry__notice { margin: 0 0 16px; color: var(--muted); font-size: 13px; }
.chat-entry__empty { min-height: 120px; display: grid; place-items: center; text-align: center; color: var(--muted); }
.chat-entry label { display: block; color: var(--muted); font-size: 13px; }
.chat-entry textarea { display: block; width: 100%; margin-top: 8px; padding: 12px; resize: vertical; min-height: 112px; max-height: 40dvh; font-size: 16px; color: var(--text); background: var(--panel); border: 1px solid var(--line); border-radius: var(--field-radius); }
.chat-entry textarea:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 2px; }
.chat-entry__controls { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.chat-entry__primary, .chat-entry__secondary { min-height: 48px; padding: 10px 16px; border-radius: var(--field-radius); }
.chat-entry__primary { background: var(--gold); color: var(--bg); font-weight: 600; }
.chat-entry__primary:disabled { opacity: .55; cursor: not-allowed; }
.chat-entry__secondary { border: 1px solid var(--line); color: var(--gold-light); }
.chat-plan { margin: 12px 0; padding: 16px; background: var(--panel); border: 1px solid var(--line); border-radius: 17px; }
.chat-plan h3 { margin: 0; font-size: 17px; }
.chat-plan p { margin: 8px 0; font-size: 14px; color: var(--muted); }
.chat-plan strong { display: block; margin: 12px 0; color: var(--gold-light); }
.chat-plan button { width: 100%; }
.chat-messages { max-height: 40dvh; min-height: 120px; overflow: auto; padding: 8px 0; overscroll-behavior: contain; }
.chat-bubble { margin: 8px 24px 8px 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--field-radius); background: var(--panel); }
.chat-bubble--own { margin: 8px 0 8px 24px; border-color: var(--gold); }
.chat-bubble p { white-space: pre-wrap; overflow-wrap: anywhere; margin: 6px 0 0; }
/* Таблица в ответе помощника (история ключей): компактно, при нехватке ширины прокручивается внутри пузыря. */
.chat-rich-table { margin: 8px 0 0; max-width: 100%; overflow-x: auto; }
.chat-rich-table table { border-collapse: collapse; font-size: 13px; line-height: 1.3; }
.chat-rich-table th, .chat-rich-table td { padding: 5px 8px; border-bottom: 1px solid rgba(255,255,255,.12); text-align: left; vertical-align: top; }
.chat-rich-table th { color: var(--gold-light); font-weight: 600; white-space: nowrap; }
.chat-rich-table td:first-child { white-space: nowrap; }
.chat-bubble small { color: var(--muted); }
.chat-entry details { padding: 8px 0; border-bottom: 1px solid var(--line); }
.chat-entry summary { min-height: 48px; padding: 12px 0; cursor: pointer; color: var(--gold-light); }
.chat-members__divider { border: 0; border-top: 1px solid var(--line); margin: var(--ankihu-space-3,12px) 0; }
.chat-entry input, .chat-entry select { width: 100%; min-height: 48px; padding: 10px; margin: 6px 0 12px; font-size: 16px; color: var(--text); background: var(--panel); border: 1px solid var(--line); border-radius: var(--field-radius); }
.chat-entry [hidden] { display: none !important; }
.chat-invitation { padding: 12px 0; border-bottom: 1px solid var(--line); }
.chat-invitation button { margin: 4px; }
.chat-entry > .ankihu-modal__header { display: grid; grid-template-columns: 48px minmax(0,1fr) 48px; padding: var(--ankihu-space-2,8px); }
.chat-entry > .ankihu-modal__header .ankihu-modal__close { grid-column: 1; grid-row: 1; }
.chat-entry > .ankihu-modal__header h2 { grid-column: 2; grid-row: 1; }
.chat-header-menu { grid-column: 3; grid-row: 1; width: 48px; height: 48px; display: grid; place-items: center; color: var(--text); }
.chat-header-menu--pending { color: var(--gold-light); }
.chat-invitation-name { display: flex; align-items: center; gap: var(--ankihu-space-2,8px); }
.chat-invitation-status { width: 10px; height: 10px; border-radius: 50%; background: var(--ankihu-color-danger,#ff8a7d); flex: none; }
.chat-invitation-status--active { background: var(--ankihu-color-emerald,#245f4c); }
.chat-list { display: grid; gap: 8px; padding: 12px 0; }
.chat-list__row { width: 100%; text-align: left; }
.chat-list__row { display: grid; gap: var(--ankihu-space-1, 4px); color: var(--text); }
.chat-list__row span, .chat-list__row small { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.conversation-invite { margin: var(--ankihu-space-4, 16px) 0; padding: var(--ankihu-space-4, 16px); border: 1px solid var(--line); border-radius: var(--ankihu-radius-panel, 22px); background: var(--panel); }
.conversation-invite--new { border-color: var(--gold); box-shadow: 0 0 24px color-mix(in srgb, var(--gold) 10%, transparent); }
.conversation-invite__badge { color: var(--gold-light); font-size: 12px; }
.conversation-invite h3 { font-size: 16px; line-height: 1.5; }
.conversation-invite p { margin: var(--ankihu-space-2, 8px) 0; }
.conversation-invite small { display: block; color: var(--muted); margin-bottom: var(--ankihu-space-3, 12px); }
.conversation-invite button { width: 100%; }
.app-bottom-nav--invited .app-bottom-nav__capsule { grid-template-columns: repeat(2,minmax(0,1fr)); }
.conversation-profile__avatar { width: 80px; height: 80px; border-radius: 50%; position: relative; overflow: hidden; display: grid; place-items: center; background: var(--panel); color: var(--gold-light); font-size: 28px; }
.conversation-profile__avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.chat-list__row--unread { border-color: var(--gold); }
.chat-unread-badge { display: inline-grid; place-items: center; flex: none; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: var(--gold); color: var(--bg); font-size: 12px; font-weight: 700; }
.chat-unread-badge[hidden] { display: none; }
.app-bottom-nav__item { position: relative; }
.chat-nav-badge { position: absolute; top: 0; right: 4px; }
.chat-system-event { margin: var(--ankihu-space-3,12px) 0; padding: var(--ankihu-space-4,16px); border: 1px solid var(--line); border-radius: var(--field-radius); background: var(--panel); text-align: center; }
.chat-system-event p { overflow-wrap: anywhere; }
.chat-event-logo { display: block; font-size: 36px; margin: var(--ankihu-space-3,12px) auto; animation: none; opacity: 1; }
.chat-list__row .chat-unread-badge { color: var(--bg); }
.chat-event-warning, .chat-event-time { display: block; color: var(--muted); font-size: 12px; line-height: 1.5; }
.chat-system-event .chat-entry__controls { justify-content: center; }
.chat-list__row--compact { display: flex; align-items: center; gap: var(--ankihu-space-3,12px); padding: var(--ankihu-space-3,12px); background: var(--panel); }
.chat-list__photo { position: relative; flex: 0 0 56px; width: 56px; height: 64px; display: grid; place-items: center; border-radius: var(--ankihu-radius-sm,12px); background: var(--bg); color: var(--gold-light); overflow: hidden; }
.chat-list__photo img { position: absolute; width: 100%; height: 100%; inset: 0; object-fit: cover; }
.chat-list__content { display: grid; gap: var(--ankihu-space-1,4px); min-width: 0; flex: 1; }
.chat-list__content strong { color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-list__row .chat-list__unread { color: var(--gold-light); flex: none; }
.chat-list + [hidden], .chat-entry__notice:empty { display: none; }
.chat-list__row--unread .conversation-invite__badge { color: var(--gold-light); }
.notification-settings { display: grid; gap: var(--ankihu-space-3,12px); }
.notification-settings__row { display: flex; align-items: center; gap: var(--ankihu-space-3,12px); min-height: var(--control-h); padding: var(--ankihu-space-3,12px); border: 1px solid var(--line); border-radius: var(--field-radius); }
.notification-settings__row input { width: 22px; height: 22px; accent-color: var(--gold); }
@media (max-width: 560px) { .ankihu-modal { margin: auto auto 0; width: 100%; max-height: calc(100dvh - 16px); border-radius: 22px 22px 0 0; } }

/* Messenger layout; invitation controls use an anchored top-layer popover. */
.chat-messenger[open] {
  /* Owner 2026-10-25: отдельный слой на весь экран, колонка высотой 100dvh: строка ввода всегда над клавиатурой. */
  position: fixed; inset: 0;
  width: min(100%,760px); height: 100vh; height: 100dvh;
  max-height: 100vh; max-height: 100dvh; max-width: 100%;
  margin: 0 auto; border: 0; border-radius: 0; overflow: hidden;
  display: flex; flex-direction: column;
}
.chat-messenger > .ankihu-modal__header {
  flex: none; grid-template-columns: 48px minmax(0,1fr) 48px 48px;
  gap: var(--ankihu-space-1,4px); padding: calc(var(--ankihu-space-1,4px) + var(--safe-top)) var(--ankihu-space-2,8px) var(--ankihu-space-1,4px);
}
.chat-messenger > .ankihu-modal__header h2 { font-size: 17px; line-height: 1.3; max-height: 2.6em; overflow: hidden; }
.chat-header-reload { grid-column: 3; grid-row: 1; display: grid; place-items: center; width: 48px; height: 48px; }
.chat-messenger .chat-header-menu { grid-column: 4; }
.chat-messenger.chat-native-back > .ankihu-modal__header { grid-template-columns: minmax(0,1fr) 48px 48px; }
.chat-messenger.chat-native-back > .ankihu-modal__header .ankihu-modal__close { display: none; }
.chat-messenger.chat-native-back > .ankihu-modal__header h2 { grid-column: 1; }
.chat-messenger.chat-native-back .chat-header-reload { grid-column: 2; }
.chat-messenger.chat-native-back .chat-header-menu { grid-column: 3; }
.chat-messenger > .ankihu-modal__body {
  position: relative; display: flex; flex-direction: column; flex: 1; min-height: 0;
  padding: 0; overflow: hidden;
}
.chat-messenger > .ankihu-modal__body > .chat-entry__notice { flex: none; margin: 0; padding: var(--ankihu-space-2,8px) var(--ankihu-space-3,12px); }
.chat-messenger .chat-members { flex: none; position: relative; z-index: 2; padding: 0 var(--ankihu-space-3,12px); border: 0; }
.chat-messenger .chat-members summary { display: flex; align-items: center; gap: var(--ankihu-space-2,8px); padding: var(--ankihu-space-2,8px) 0; min-height: 48px; font-size: 13px; list-style: none; }
.chat-messenger .chat-members summary::-webkit-details-marker { display: none; }
.chat-messenger .chat-members summary::before { content: ''; flex: none; width: 7px; height: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); transition: transform .15s; }
.chat-messenger .chat-members[open] summary::before { transform: rotate(45deg) translate(-2px,-2px); }
.chat-messenger .chat-members > div {
  position: absolute; top: 100%; left: var(--ankihu-space-2,8px); right: var(--ankihu-space-2,8px);
  max-height: min(72dvh,560px); overflow-y: auto; overscroll-behavior: contain;
  padding: var(--ankihu-space-3,12px); border: 1px solid var(--line); border-radius: var(--field-radius);
  background: color-mix(in srgb,var(--panel) 88%,transparent); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
}
.chat-member-row { display: flex; align-items: center; gap: var(--ankihu-space-2,8px); overflow-wrap: anywhere; margin: var(--ankihu-space-2,8px) 0; }
.chat-messenger .chat-messages {
  flex: 1; min-height: 0; max-height: none; padding: var(--ankihu-space-2,8px) var(--ankihu-space-3,12px);
  display: flex; flex-direction: column; gap: var(--ankihu-space-2,8px); border: 0; background: none;
}
/* Короткая переписка стоит внизу, у строки ввода, как в Telegram. */
.chat-messenger .chat-messages > :first-child { margin-top: auto; }
.chat-message-row { display: flex; flex: none; align-items: flex-end; gap: var(--ankihu-space-2,8px); justify-content: flex-start; }
.chat-message-row--own { justify-content: flex-end; }
.chat-messenger .chat-bubble { min-width: 0; max-width: 82%; margin: 0; border: 0; border-radius: var(--field-radius); }
.chat-messenger .chat-bubble--own { background: color-mix(in srgb,var(--gold) 14%,var(--panel)); }
.chat-messenger .chat-bubble small { display: block; font-size: 11px; overflow-wrap: anywhere; }
.chat-messenger .chat-system-event { flex: none; align-self: center; max-width: 92%; margin: var(--ankihu-space-2,8px) 0; padding: var(--ankihu-space-3,12px); border: 0; background: color-mix(in srgb,var(--panel) 55%,transparent); }
.chat-messenger .chat-system-event p { margin: 0 0 var(--ankihu-space-2,8px); font-size: 13px; color: var(--muted); }
.chat-messenger .chat-system-event--quran-reminder { width: min(92%,520px); max-width: 520px; padding: var(--ankihu-space-4,16px); border: 1px solid color-mix(in srgb,var(--gold) 24%,var(--line)); text-align: left; }
.chat-system-event--quran-reminder h3 { display: flex; align-items: center; justify-content: center; gap: var(--ankihu-space-2,8px); margin: 0 0 var(--ankihu-space-3,12px); color: var(--gold-light); font-size: 15px; line-height: 1.4; text-align: center; }
.chat-quran-reminder__icon { flex: none; width: 22px; height: 22px; display: grid; place-items: center; }
.chat-quran-reminder__icon svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.chat-messenger .chat-system-event--quran-reminder .chat-quran-reminder__arabic { margin: 0; padding: var(--ankihu-space-3,12px) 0; color: var(--text); font-family: 'Reem Kufi',Georgia,'Times New Roman',serif; font-size: 20px; line-height: 1.9; text-align: right; direction: rtl; unicode-bidi: plaintext; overflow-wrap: normal; word-break: normal; }
.chat-quran-reminder__meaning { padding: var(--ankihu-space-3,12px) 0 0; border-top: 1px solid var(--line); }
.chat-quran-reminder__label { display: block; margin-bottom: var(--ankihu-space-1,4px); color: var(--text); font-size: 12px; font-weight: 650; }
.chat-messenger .chat-system-event--quran-reminder .chat-quran-reminder__meaning p,
.chat-messenger .chat-system-event--quran-reminder .chat-quran-reminder__wish p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.chat-quran-reminder__source { display: block; margin-top: var(--ankihu-space-2,8px); color: color-mix(in srgb,var(--gold-light) 64%,var(--muted)); font-size: 12px; line-height: 1.5; font-style: normal; }
.chat-quran-reminder__wish { margin-top: var(--ankihu-space-3,12px); padding-top: var(--ankihu-space-3,12px); border-top: 1px solid var(--line); }
.chat-system-event--quran-reminder .chat-event-time { margin-top: var(--ankihu-space-3,12px); text-align: center; }
.chat-messenger .chat-system-event--payment-notice { width: min(92%,420px); max-width: 420px; padding: var(--ankihu-space-4,16px); border: 1px solid color-mix(in srgb,var(--gold) 28%,var(--line)); background: color-mix(in srgb,var(--panel) 82%,transparent); text-align: left; }
.chat-system-event--payment-notice h3 { display: flex; align-items: center; justify-content: center; gap: var(--ankihu-space-2,8px); margin: 0 0 var(--ankihu-space-3,12px); color: var(--gold-light); font-size: 15px; line-height: 1.4; text-align: center; }
.chat-payment-notice__icon { display: grid; flex: none; width: 22px; height: 22px; place-items: center; }
.chat-payment-notice__icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.chat-payment-notice__details { display: grid; gap: var(--ankihu-space-2,8px); margin: 0; }
.chat-payment-notice__details div { display: grid; grid-template-columns: minmax(76px,.7fr) minmax(0,1.6fr); gap: var(--ankihu-space-2,8px); align-items: baseline; }
.chat-payment-notice__details dt { color: var(--muted); font-size: 12px; }
.chat-payment-notice__details dd { min-width: 0; margin: 0; color: var(--text); font-size: 13px; line-height: 1.45; overflow-wrap: anywhere; }
.chat-messenger .chat-system-event--payment-notice .chat-payment-notice__status { margin: var(--ankihu-space-3,12px) 0 0; padding-top: var(--ankihu-space-3,12px); border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; line-height: 1.5; text-align: center; }
.chat-system-event--payment-notice .chat-event-time { margin-top: var(--ankihu-space-2,8px); text-align: center; }
.chat-messenger .chat-event-group { flex: none; align-self: center; width: min(92%,420px); margin: var(--ankihu-space-2,8px) 0; }
.chat-event-group > summary { display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 14px; border-radius: 999px; font-size: 13px; color: var(--muted); background: color-mix(in srgb,var(--panel) 55%,transparent); cursor: pointer; list-style: none; }
.chat-event-group > summary::-webkit-details-marker { display: none; }
.chat-event-group > summary::after { content: ''; width: 7px; height: 7px; margin-left: 10px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translateY(-2px); transition: transform .15s; }
.chat-event-group[open] > summary::after { transform: rotate(-135deg) translate(-2px,-2px); }
.chat-event-group > .chat-system-event { max-width: 100%; }
@media (prefers-reduced-motion: reduce) { .chat-event-group > summary::after { transition: none; } }
@media (max-width: 420px) {
  .chat-messenger .chat-system-event--quran-reminder { width: 94%; max-width: 94%; padding: var(--ankihu-space-3,12px); }
  .chat-messenger .chat-system-event--quran-reminder .chat-quran-reminder__arabic { font-size: 18px; line-height: 1.85; }
}
.chat-avatar { position: relative; flex: 0 0 32px; width: 32px; height: 32px; border-radius: 50%; overflow: hidden; display: inline-grid; place-items: center; background: var(--panel); }
.chat-avatar .app-loading-mark { font-size: 12px; line-height: 1; animation: none; opacity: 1; margin: 0; }
.chat-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.chat-avatar--ai { background: color-mix(in srgb,var(--gold) 16%,var(--panel)); font-size: 19px; }
.chat-support-mode { position: relative; flex: none; display: flex; align-items: center; gap: 10px; margin: 0 12px 8px; padding: 8px 8px 8px 12px; border: 1px solid var(--line); border-radius: var(--field-radius); font-size: 12px; }
.chat-support-mode[hidden] { display: none; }
.chat-support-mode__status { flex: 1 1 auto; min-width: 0; color: var(--muted); }
.chat-staff-support > .ankihu-modal__header { grid-template-columns: 48px minmax(0,1fr); }
.chat-staff-support > .ankihu-modal__header h2 { max-height: none; }
.chat-staff-support > .ankihu-modal__header .ankihu-modal__close { border: 0; background: transparent; box-shadow: none; }
.chat-peer-profile { display: flex; align-items: center; gap: var(--ankihu-space-2,8px); width: 100%; min-width: 0; min-height: 48px; padding: 0; border: 0; border-radius: 12px; background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.chat-peer-profile__name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-peer-profile__chevron { flex: none; color: var(--gold-light); opacity: .72; }
.chat-peer-profile:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 2px; }
.chat-peer-profile:active { background: color-mix(in srgb,var(--gold) 9%,transparent); }

/* Полная анкета из чата: тот же feed-card, но поверх беседы в общем стеке
   openModal. Поэтому Telegram Back закрывает сначала анкету, затем чат. */
.chat-peer-profile-view[open] {
  position: fixed; inset: 0; display: flex; flex-direction: column;
  width: 100%; height: 100%; max-width: none; max-height: none; margin: 0;
  border: 0; border-radius: 0; overflow: hidden; background: var(--bg);
}
.chat-peer-profile-view::backdrop { background: var(--bg); }
.chat-peer-profile-view > .ankihu-modal__header { flex: none; padding: calc(8px + var(--safe-top)) 12px 8px; }
.chat-peer-profile-view.chat-native-back > .ankihu-modal__header .ankihu-modal__close { display: none; }
.chat-peer-profile-view.chat-native-back > .ankihu-modal__header { justify-content: flex-start; padding-inline: 18px; }
.chat-peer-profile-view > .ankihu-modal__body { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 0 18px calc(24px + var(--safe-bottom)); }
.chat-peer-profile-view .chat-peer-actions { position: static; grid-template-columns: minmax(0,1fr); margin-bottom: calc(12px + var(--safe-bottom)); }
.chat-peer-profile-view .chat-peer-actions .feed-action.like { min-height: 48px; }
.chat-composer { position: relative; flex: none; margin: var(--ankihu-space-2,8px) var(--ankihu-space-3,12px) calc(var(--ankihu-space-2,8px) + var(--safe-bottom)); }
.chat-messenger .chat-composer textarea { margin: 0; min-height: 54px; max-height: 120px; resize: none; padding: 15px 64px 15px 14px; line-height: 24px; border-radius: var(--ankihu-radius-panel,22px); }
.chat-composer .chat-send { position: absolute; right: 3px; bottom: 3px; display: grid; place-items: center; width: 48px; height: 48px; min-height: 48px; padding: 0; border-radius: 50%; }
.chat-messenger .chat-composer { display: grid; grid-template-columns: auto minmax(0,1fr); align-items: end; gap: var(--ankihu-space-1,4px); }
.chat-composer-input { position: relative; min-width: 0; }
.chat-media-tools { display: flex; align-items: center; }
.chat-list-header { display:flex; align-items:center; justify-content:space-between; gap:var(--ankihu-space-3); }
.chat-support-button { position:relative; display:grid; place-items:center; min-width:var(--ankihu-touch-target,48px); min-height:var(--ankihu-touch-target,48px); padding:var(--ankihu-space-2); background:transparent; border:0; color:var(--gold-light); }
.chat-support-button .chat-unread-badge { position:absolute; top:0; right:0; }
.chat-support-notice { border-color:var(--gold-light); margin-bottom:var(--ankihu-space-3); }
.chat-support-notice[hidden] { display:none; }
.chat-support-notice__photo .app-loading-mark { font-size: 18px; line-height: 1; animation: none; opacity: 1; margin: 0; }
.chat-official-label { display:block; color:var(--gold-light); font-size:12px; font-weight:500; margin-top:var(--ankihu-space-1); }
.chat-attach { width: 48px; height: 54px; display: grid; place-items: center; padding: 0; color: var(--gold-light); background: transparent; border: 0; }
.chat-attach:disabled { opacity: .35; }
.chat-messenger .chat-composer .chat-send { border: 0; border-radius: 0; background: transparent; box-shadow: none; color: var(--gold-light); }
.chat-messenger .chat-composer .chat-send:disabled { opacity: .3; }
.chat-messenger .chat-composer .chat-send:not(:disabled):active { transform: scale(.94); }
.chat-media-preview { grid-column: 1 / -1; padding: var(--ankihu-space-2,8px); border: 1px solid var(--line); border-radius: var(--field-radius); max-height: 35dvh; overflow: auto; }
.chat-media-preview p { margin: 0 0 var(--ankihu-space-2,8px); color: var(--muted); font-size: 13px; }
.chat-media-preview img { display: block; max-width: 100%; max-height: 120px; border-radius: var(--ankihu-radius-sm,12px); }
.chat-media-preview audio,.chat-message-media audio { display: block; max-width: 100%; width: 260px; height: 44px; }
.chat-media-preview--ready { display: grid; grid-template-columns: 48px minmax(0,1fr); align-items: center; gap: 4px; }
.chat-media-preview--ready[hidden] { display: none; }
.chat-media-preview--ready p { grid-column: 1 / -1; }
.chat-media-preview p:empty { display: none; }
.chat-media-preview--ready .chat-media-preview__content { grid-column: 2; grid-row: 2; min-width: 0; }
.chat-media-preview--ready .chat-entry__controls { grid-column: 1; grid-row: 2; margin: 0; }
.chat-media-preview--ready .chat-attach { height: 48px; }
.chat-media-preview--ready audio { width: 100%; }
.chat-media-preview--ready img { max-height: 72px; }
.chat-message-media { max-width: 100%; }
.chat-message-media img { display: block; max-width: 100%; max-height: 320px; border-radius: var(--ankihu-radius-sm,12px); margin-top: var(--ankihu-space-2,8px); }
@media (prefers-reduced-transparency: reduce) { .chat-messenger .chat-members > div { background: var(--panel); backdrop-filter: none; } }

.chat-invitation-window[open] {
  position: fixed; inset: auto; left: var(--chat-menu-left); top: var(--chat-menu-top);
  width: var(--chat-menu-width); max-width: calc(100% - 16px);
  max-height: var(--chat-menu-height); margin: 0; padding: 0;
  display: flex; flex-direction: column; overflow: hidden;
  border: 1px solid var(--line); border-radius: var(--ankihu-radius-panel,22px);
  background: color-mix(in srgb,var(--bg) 90%,transparent);
  box-shadow: var(--ankihu-shadow-card,0 16px 56px #0008);
  backdrop-filter: blur(16px) saturate(118%); -webkit-backdrop-filter: blur(16px) saturate(118%);
}
.chat-invitation-window::backdrop { background: #0002; }
.chat-invitation-window > .ankihu-modal__header {
  display: flex; flex: none; padding: var(--ankihu-space-2,8px) var(--ankihu-space-3,12px);
  background: transparent;
}
.chat-invitation-window > .ankihu-modal__header h2 { font-size: 16px; }
.chat-invitation-window .ankihu-modal__close {
  width: 48px; height: 48px; border: 0; background: transparent; box-shadow: none;
  border-radius: var(--ankihu-radius-sm,12px); color: var(--muted); outline: none;
}
.chat-invitation-window .ankihu-modal__close:focus-visible { outline: none; color: var(--gold-light); }
.chat-invitation-window > .ankihu-modal__body {
  min-height: 0; overflow-y: auto; overscroll-behavior: contain;
  padding: var(--ankihu-space-3,12px); font-size: 14px;
}
.chat-invitation-window .chat-entry__secondary {
  min-height: 48px; text-align: left; padding: var(--ankihu-space-3,12px);
  border-color: transparent; background: transparent;
}
.chat-invitation-window .chat-invite-management > details:last-child > button { display: flex; align-items: center; gap: var(--ankihu-space-3,12px); width: 100%; margin: 0; }
.chat-invitation-window .chat-invite-management > details:last-child > button svg { flex: none; color: var(--gold-light); }
.chat-invitation-window button:active { background: color-mix(in srgb,var(--gold) 12%,transparent); }
@media (hover:hover) and (pointer:fine) {
  .chat-invitation-window .chat-entry__secondary:hover,
  .chat-invitation-window .ankihu-modal__close:hover { background: color-mix(in srgb,var(--gold) 8%,transparent); color: var(--gold-light); }
}
@media (prefers-reduced-transparency: reduce) {
  .chat-invitation-window[open] { background: var(--bg); backdrop-filter: none; -webkit-backdrop-filter: none; }
}
/* Approved payment artwork is isolated in its own same-origin document. */
.billing-shell{width:100vw!important;max-width:none!important;height:100dvh!important;max-height:none!important;inset:0!important;margin:0!important;padding:0!important;border:0!important;background:transparent!important;box-shadow:none!important}
.billing-shell>.ankihu-modal__header{display:none}
.billing-shell>.ankihu-modal__body{height:100%;padding:0;overflow:hidden}
.billing-frame{display:block;width:100%;height:100%;border:0;background:transparent}
.billing-overlay{display:block;position:fixed;inset:0;margin:0;padding:0;border:0;width:100%;height:100%;max-width:none;max-height:none;z-index:1000;visibility:hidden;pointer-events:none;background:transparent;transition:visibility 0s .24s}
/* Tariff reference: the app behind the arch is blurred, desaturated and dimmed. */
.billing-overlay::backdrop{background:rgba(0,6,4,.36);-webkit-backdrop-filter:blur(2px) saturate(.6);backdrop-filter:blur(2px) saturate(.6)}
.billing-overlay.is-open{visibility:visible;pointer-events:auto;transition-delay:0s}
.billing-overlay>.billing-frame{transform:translateY(100%);transition:transform .24s cubic-bezier(.22,1,.36,1)}
.billing-overlay.is-open>.billing-frame{transform:translateY(0)}
.has-billing-overlay .app-screen{overflow:hidden}
@media(prefers-reduced-motion:reduce){.billing-overlay,.billing-overlay>.billing-frame{transition:none}}

/* Sister wrote first, brother without VIP: her messages are hidden server-side.
   The bubble shows only a blurred stand-in; there is no real text behind it. */
.chat-bubble--hidden { position: relative; overflow: hidden; }
.chat-hidden-text {
  margin: 4px 0 0; padding: 8px 12px; border-radius: 12px; font-size: 13px; color: #f3dc9b;
  background: repeating-linear-gradient(90deg, rgba(243,220,155,.16) 0 34px, rgba(243,220,155,.06) 34px 48px);
  text-shadow: 0 0 6px rgba(243,220,155,.55); letter-spacing: .01em;
}
.chat-unlock {
  margin: 6px 12px; padding: 12px 14px; border-radius: 16px; border: 1px solid rgba(217,175,89,.5);
  background: radial-gradient(ellipse at 20% 0, rgba(246,224,150,.14), transparent 70%), rgba(7,33,23,.7);
  display: grid; gap: 10px;
}
.chat-unlock p { margin: 0; font-size: 13px; line-height: 1.5; color: var(--text, #efe7cf); }
.chat-unlock button { min-height: 44px; border-radius: 14px; font-weight: 700; }

/* «Уведомления» (VS-036B): заголовок страницы — общий с «Моей анкетой» (.anketa-page-head
   из anketa.css), карточки и переключатели — та же палитра зелёного стекла и золота. */
.notify-page { display: grid; gap: 12px; }
.notify-card { display: grid; gap: 4px; padding: 14px 16px; border: 1px solid rgba(198, 174, 99, .38); border-radius: 21px; background: linear-gradient(128deg, #143a28, #08251b); box-shadow: inset 0 1px 0 rgba(223, 231, 181, .07), 0 6px 18px rgba(0, 0, 0, .22); }
.notify-card__title { margin: 0 0 4px; font: 400 17px/1.25 Georgia, 'Times New Roman', serif; color: #ffedc0; letter-spacing: -.015em; }
.notify-row { display: flex; align-items: center; gap: 14px; min-height: 56px; padding: 8px 0; cursor: pointer; }
.notify-row + .notify-row { border-top: 1px solid rgba(201, 185, 120, .16); }
.notify-row__copy { flex: 1; min-width: 0; display: grid; gap: 3px; }
.notify-row__copy strong { font-size: 15px; font-weight: 500; color: #f4ecd5; }
.notify-row__copy small { font-size: 12px; line-height: 1.45; color: #a9bea8; }
.notify-switch { appearance: none; -webkit-appearance: none; flex: none; position: relative; width: 46px; height: 28px; margin: 0; border-radius: 999px; border: 1px solid #b6ab6359; background: #0a2c1f; cursor: pointer; transition: background .2s, border-color .2s; }
.notify-switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #9fb3a4; box-shadow: 0 1px 3px #0006; transition: transform .2s, background .2s; }
.notify-switch:checked { background: linear-gradient(125deg, #ffe6a3, #d2a64e 85%, #bb903d); border-color: #f5d58b; }
.notify-switch:checked::after { transform: translateX(18px); background: #14261a; }
.notify-switch:disabled { opacity: .5; cursor: default; }
.notify-switch:focus-visible { outline: 2px solid #f5d58b; outline-offset: 2px; }
.notify-quiet { display: grid; gap: 8px; padding: 4px 0 6px; }
.notify-quiet[hidden] { display: none; }
.notify-times { display: flex; align-items: center; gap: 10px; color: #d3c59b; font-size: 14px; }
.notify-time { flex: 1; min-width: 0; min-height: 44px; padding: 8px 10px; border-radius: 13px; border: 1px solid #b6ab6359; background: #08281c; color: #f4ecd5; font-size: 16px; color-scheme: dark; }
.notify-time:focus { border-color: rgba(231, 202, 137, .75); outline: 0; }
.notify-zone, .notify-note { margin: 0; font-size: 12px; line-height: 1.5; color: #86a08d; }
.notify-note { padding: 0 4px; }
.notify-status { margin: 0; min-height: 18px; padding: 0 4px; font-size: 12.5px; color: #d7c794; }
@media (prefers-reduced-motion: reduce) { .notify-switch, .notify-switch::after { transition: none; } }
/* «Пригласить участника» внутри «Участников» (владелец 2026-09-25): под своим именем. */
.chat-members--pending { color: var(--gold-light); font-weight: 600; }
.chat-structured-action{display:flex;flex-wrap:wrap;gap:8px;margin-top:10px;padding-top:10px;border-top:1px solid rgba(201,185,120,.18)}
.chat-structured-action button{min-height:44px}.chat-structured-action .chat-entry__primary{background:#7b302a;border-color:#bd746b;color:#fff3ef}.chat-structured-action .chat-entry__secondary{background:transparent}
.chat-entry .chat-invite-form { margin: var(--ankihu-space-2,8px) 0 0; padding: 0; border: 0; }
.chat-entry .chat-invite-form > summary { display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 14px; border: 1px solid #d7b76d8c; border-radius: var(--field-radius); color: var(--gold-light); font-weight: 600; list-style: none; }
.chat-entry .chat-invite-form > summary::-webkit-details-marker { display: none; }
.chat-entry .chat-invite-form[open] > summary { margin-bottom: var(--ankihu-space-2,8px); background: color-mix(in srgb,var(--gold) 10%,transparent); }
.chat-members .chat-invitation { padding: 8px 0; border-bottom: 0; }
.chat-members .chat-invitation small { color: var(--muted); }
.chat-invite-kind { display: block; margin: -6px 2px 10px; font-size: 12.5px; color: var(--gold-light); }

/* Меню действий чата: сразу список из четырёх-пяти действий в стиле меню ленты, без заголовка окна и вложенного «Действия». */
.chat-invitation-window[open] {
  border: 1px solid rgba(239,209,139,.3); border-radius: 19px; color: #edf2ee;
  background: linear-gradient(145deg,rgba(255,255,255,.07),rgba(0,0,0,.12)),rgba(7,39,29,.96);
  box-shadow: 0 18px 42px rgba(0,0,0,.4), inset 0 1px 0 rgba(255,255,255,.14);
  animation: chat-action-menu-in .17s ease-out both; transform-origin: top right;
}
.chat-invitation-window > .ankihu-modal__header { display: none; }
.chat-invitation-window > .ankihu-modal__body { padding: 0; }
.chat-invitation-window .chat-invite-management { margin: 0; }
.chat-action-menu { display: flex; flex-direction: column; }
.chat-action-item {
  width: 100%; min-height: 62px; margin: 0; padding: 10px 13px; border: 0; border-radius: 0;
  display: grid; grid-template-columns: 34px minmax(0,1fr); align-items: center; gap: 10px;
  color: inherit; background: transparent; text-align: left; font: inherit;
}
.chat-action-item + .chat-action-item { border-top: 1px solid rgba(255,255,255,.09); }
.chat-action-item:active { background: rgba(255,255,255,.07); }
.chat-action-item:disabled { opacity: .45; }
.chat-action-icon { width: 32px; height: 32px; display: grid; place-items: center; color: #f0d18a; }
.chat-action-text strong, .chat-action-text small { display: block; }
.chat-action-text strong { font-size: 13px; line-height: 1.25; font-weight: 700; }
.chat-action-text small { margin-top: 3px; color: #9eb0a6; font-size: 10px; line-height: 1.3; font-weight: 400; }
.chat-action-item.chat-report-participant .chat-action-icon { color: #ff746d; background: rgba(224,67,61,.12); }
.chat-action-item.chat-report-participant strong { color: #ff9a94; }
@keyframes chat-action-menu-in { from { opacity: 0; transform: translateY(-5px) scale(.975); } }
@media (prefers-reduced-motion: reduce) { .chat-invitation-window[open] { animation: none; } }

/* Само окно не получает декоративную системную обводку; интерактивные пункты сохраняют заметный фокус. */
.chat-invitation-window:focus, .chat-invitation-window:focus-visible { outline: none; }
.chat-invitation-window .chat-action-item:focus-visible { outline: 2px solid var(--gold-light); outline-offset: -3px; }
.chat-invitation-window[open]:focus-visible { box-shadow: 0 18px 42px rgba(0,0,0,.4), inset 0 1px 0 rgba(255,255,255,.14); }

/* Меню действий сотрудника в диалоге поддержки: тот же стеклянный стиль, что у меню анкеты в ленте */
.chat-menu-button { flex: none; width: 48px; height: 48px; padding: 0; border-radius: 15px; background: rgba(7,33,23,.6); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid rgba(255,255,255,.2); box-shadow: inset 0 1px 0 rgba(255,255,255,.14), 0 4px 12px rgba(0,0,0,.32); display: grid; place-items: center; color: #f2ecdd; -webkit-appearance: none; appearance: none; transition: transform .15s ease; }
.chat-menu-button:active { transform: scale(.92); }
.chat-menu-button[aria-expanded="true"] { color: #f2d58c; border-color: rgba(239,202,119,.55); background: linear-gradient(145deg,rgba(237,194,99,.2),rgba(255,255,255,.025) 52%,rgba(0,0,0,.16)),rgba(7,33,23,.76); box-shadow: inset 0 1px 0 rgba(255,255,255,.18),0 5px 16px rgba(0,0,0,.34),0 0 15px rgba(217,175,89,.2); }
.chat-menu-panel { position: absolute; top: 62px; right: 0; z-index: 8; width: min(285px, calc(100vw - 32px)); max-height: 70vh; overflow-y: auto; border: 1px solid rgba(239,209,139,.3); border-radius: 19px; color: #edf2ee; background: linear-gradient(145deg,rgba(255,255,255,.07),rgba(0,0,0,.12)),rgba(7,39,29,.96); backdrop-filter: blur(18px) saturate(1.15); -webkit-backdrop-filter: blur(18px) saturate(1.15); box-shadow: 0 18px 42px rgba(0,0,0,.4), inset 0 1px 0 rgba(255,255,255,.14); transform-origin: top right; animation: chat-menu-in .17s ease-out both; }
.chat-menu-panel[hidden], .chat-menu-sub[hidden], .chat-menu-item[hidden] { display: none; }
.chat-menu-item { width: 100%; min-height: 62px; padding: 10px 13px; border: 0; border-radius: 0; display: grid; grid-template-columns: 34px minmax(0,1fr); align-items: center; gap: 10px; color: inherit; background: transparent; text-align: left; font: inherit; }
.chat-menu-item + .chat-menu-item, .chat-menu-sub + .chat-menu-item { border-top: 1px solid rgba(255,255,255,.09); }
.chat-menu-item:active, .chat-menu-sub-item:active { background: rgba(255,255,255,.07); }
.chat-menu-icon { width: 32px; height: 32px; display: grid; place-items: center; color: #f0d18a; }
.chat-menu-item strong, .chat-menu-item small, .chat-menu-sub-item strong, .chat-menu-sub-item small { display: block; }
.chat-menu-item strong { font-size: 13px; line-height: 1.25; font-weight: 700; }
.chat-menu-item small, .chat-menu-sub-item small { margin-top: 3px; color: #9eb0a6; font-size: 10px; line-height: 1.3; }
.chat-menu-sub { background: rgba(0,0,0,.18); border-top: 1px solid rgba(255,255,255,.09); }
.chat-menu-sub-item { width: 100%; padding: 10px 13px 10px 57px; border: 0; border-radius: 0; color: inherit; background: transparent; text-align: left; font: inherit; }
.chat-menu-sub-item + .chat-menu-sub-item { border-top: 1px solid rgba(255,255,255,.06); }
.chat-menu-sub-item strong { font-size: 12.5px; font-weight: 600; color: #f0d18a; }
.chat-menu-note { display: block; padding: 10px 13px; color: #9eb0a6; }
@keyframes chat-menu-in { from { opacity: 0; transform: translateY(-5px) scale(.975); } }
@media (prefers-reduced-motion: reduce) { .chat-menu-panel { animation: none; } .chat-menu-button { transition: none; } }
/* Ответ помощника на зажатое сообщение пользователя (для сотрудника) */
.chat-bubble--holdable { -webkit-touch-callout: none; }
.chat-reply-menu { position: fixed; left: 12px; right: 12px; z-index: 20; max-height: 60vh; overflow-y: auto; border: 1px solid rgba(239,209,139,.3); border-radius: 19px; color: #edf2ee; background: linear-gradient(145deg,rgba(255,255,255,.07),rgba(0,0,0,.12)),rgba(7,39,29,.97); backdrop-filter: blur(18px) saturate(1.15); -webkit-backdrop-filter: blur(18px) saturate(1.15); box-shadow: 0 18px 42px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.14); animation: chat-menu-in .17s ease-out both; }
.chat-reply-menu[hidden] { display: none; }
.chat-reply-menu__title { display: block; padding: 11px 14px; color: #9eb0a6; font-size: 11px; line-height: 1.35; border-bottom: 1px solid rgba(255,255,255,.09); }
.chat-reply-menu__item { display: block; width: 100%; padding: 11px 14px; border: 0; border-radius: 0; background: transparent; color: inherit; text-align: left; font: inherit; }
.chat-reply-menu__item + .chat-reply-menu__item { border-top: 1px solid rgba(255,255,255,.07); }
.chat-reply-menu__item:active { background: rgba(255,255,255,.07); }
.chat-reply-menu__item strong { display: block; font-size: 13px; color: #f0d18a; }
.chat-reply-menu__item small { display: block; margin-top: 3px; color: #9eb0a6; font-size: 10px; line-height: 1.3; }
/* В диалоге поддержки (для сотрудника) текст не выделяется: при долгом нажатии выделение мешало закрыть меню */
.chat-staff-support .chat-bubble, .chat-reply-menu, .chat-menu-panel { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }

/* Компактный однострочный composer сохраняет проектный touch-target 48×48 px. */
.chat-messenger .chat-composer textarea{min-height:48px;padding:12px 52px 12px 14px;line-height:22px;border-radius:24px}
.chat-messenger .chat-composer .chat-send{width:48px;height:48px;min-height:48px;right:0;bottom:0}
.chat-messenger .chat-attach{height:48px;width:48px}
.chat-messenger :is(.ankihu-modal__close,.chat-header-reload,.chat-header-menu,.chat-attach,.chat-send,.chat-menu-button):focus-visible,
.chat-menu-panel :is(.chat-menu-item,.chat-menu-sub-item):focus-visible,
.chat-reply-menu__item:focus-visible { outline: 2px solid var(--gold-light); outline-offset: -3px; }
.chat-reply-menu { width: min(560px, calc(100vw - 24px)); left: 0; right: 0; margin-inline: auto; overscroll-behavior: contain; }
.chat-reply-menu__item { min-height: 48px; }
.chat-reply-menu__title, .chat-reply-menu__item small { font-size: 12px; line-height: 1.45; }
.chat-scenario-review { flex: 0 1 auto; max-height: 30vh; overflow: auto; padding: 10px 14px; border: 1px solid rgba(239,209,139,.3); border-radius: 12px; font-size: 13px; line-height: 1.5; }
.chat-scenario-review p { white-space: pre-line; }
.chat-scenario-review[hidden] { display: none; }

@media (prefers-reduced-motion: reduce) {
  .chat-messenger .chat-members summary::before { transition: none; }
}

/* Помощники Ankihu: каталог для переписки */
.chat-invite-or{margin:10px 0 6px;text-align:center;color:var(--muted,#9eb0a6);font-size:12px}
.chat-invite-helper{width:100%}
.helper-catalog__filters{display:flex;flex-wrap:wrap;gap:6px;margin:8px 0 10px}
.helper-catalog__filters input{flex:1 1 140px;min-width:0}
.helper-chip{min-height:44px;padding:0 14px;border-radius:999px;border:1px solid rgba(224,193,124,.35);background:transparent;color:inherit;font-size:13px}
.helper-chip.is-on{background:linear-gradient(180deg,#f4de9a,#dcb865 52%,#b98f42);color:#1f1806;border-color:transparent;font-weight:600}
.helper-catalog__list{display:grid;gap:10px}
.helper-catalog [hidden]{display:none!important}
/* Список представителей: аватар, имя, должности, город; подробности — в карточке по нажатию */
.helper-avatar{flex:none;display:inline-grid;place-items:center;width:48px;height:48px;border-radius:50%;border:1px solid rgba(224,193,124,.35);background:hsl(var(--h,150) 30% 28%);color:#f6e9c4;font-size:20px;font-weight:700;line-height:1}
.helper-avatar--big{width:80px;height:80px}
.helper-avatar svg{width:56%;height:56%}
/* Кнопки-пиктограммы в «Участниках»: удалить и заменить */
.chat-invitation-tools{display:flex;gap:8px;margin-top:6px}
.chat-icon-button{display:inline-grid;place-items:center;width:44px;height:44px;padding:0;border:1px solid var(--line);border-radius:12px;background:transparent;color:var(--gold-light);cursor:pointer}
.chat-icon-button svg{width:22px;height:22px}
.chat-icon-button:active{background:color-mix(in srgb,var(--gold) 12%,transparent)}
.chat-icon-button:focus-visible{outline:2px solid var(--gold-light);outline-offset:2px}
.helper-row{display:flex;align-items:center;gap:12px;width:100%;min-height:68px;padding:10px 12px;border:1px solid rgba(224,193,124,.25);border-radius:16px;background:rgba(255,255,255,.03);color:inherit;font:inherit;text-align:left;cursor:pointer}
.helper-row:active:not(:disabled){background:color-mix(in srgb,var(--gold) 12%,transparent)}
.helper-row:focus-visible,.helper-detail button:focus-visible{outline:2px solid var(--gold-light);outline-offset:2px}
.helper-row__copy{flex:1;min-width:0;display:grid;gap:2px}
.helper-row__copy b{font-size:16px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.helper-row__copy small{font-size:13px;line-height:1.35;color:var(--muted,#9eb0a6);overflow-wrap:anywhere}
.helper-row__copy .helper-row__roles{color:var(--gold-light)}
.helper-row__copy .helper-card__pending{color:#e8c979}
.helper-row__chev{flex:none;font-size:24px;line-height:1;color:var(--muted,#9eb0a6)}
.helper-row:disabled{cursor:default}
.helper-row.is-unavailable .helper-avatar{opacity:.5}
.helper-detail{display:grid;gap:12px}
.helper-detail__back{justify-self:start;min-height:44px}
.helper-detail__top{display:grid;justify-items:center;gap:4px;text-align:center}
.helper-detail__top h3{margin:6px 0 0;font-size:20px}
.helper-detail__roles{margin:0;color:var(--gold-light)}
.helper-detail__facts{display:grid;grid-template-columns:auto 1fr;gap:6px 14px;margin:0;padding:12px 14px;border:1px solid rgba(224,193,124,.2);border-radius:14px}
.helper-detail__facts dt{font-size:13px;color:var(--muted,#9eb0a6)}
.helper-detail__facts dd{margin:0;font-size:14px;overflow-wrap:anywhere}
.helper-detail__about{margin:0;font-size:14px;line-height:1.5;overflow-wrap:anywhere}
.helper-detail__actions{display:grid;gap:10px;position:sticky;bottom:0;padding:8px 0}
.helper-detail__invite{min-height:50px;font-weight:700}
.helper-card{padding:12px 14px;border-radius:16px;border:1px solid rgba(224,193,124,.25);background:rgba(255,255,255,.03);display:grid;gap:4px}
.helper-card small{color:var(--muted,#9eb0a6)}
.helper-card p{margin:2px 0;line-height:1.4;font-size:14px}
.helper-card__facts{font-size:12.5px!important;color:#cfd9cd}
.helper-card__badge{justify-self:start;font-size:11px;padding:2px 8px;border-radius:999px;background:rgba(91,214,168,.12);color:#7fe0bb}
.helper-card__actions{display:flex;flex-wrap:wrap;gap:6px;margin-top:4px}
.helper-card__pending{font-size:13px;color:#e8c979}
.helper-card.is-unavailable{opacity:.5}
.helper-card__unavailable{font-size:13px;color:#a9bea8}

/* Кнопка «Помощник» в «Чатах» (вариант 17): золотая, плоская, компактная */
.chat-support-button.chat-support-button--labelled{display:inline-flex;align-items:center;gap:6px;min-width:0;min-height:36px;height:36px;margin:6px 0;padding:0 13px;border-radius:999px;color:#102318;background:linear-gradient(180deg,#e7ca72,#b58e36);box-shadow:inset 0 1px rgba(255,255,255,.5);font:700 13px/1 var(--ankihu-font-ui,-apple-system,"Segoe UI",Arial,sans-serif);-webkit-tap-highlight-color:transparent;transition:transform .13s ease}
.chat-support-button--labelled:active{transform:translateY(1px) scale(.97)}
.chat-support-button--labelled svg{flex:none}
.chat-support-button--labelled .chat-unread-badge{top:-5px;right:-5px}

/* Отзыв о помощнике и рейтинг в каталоге */
.helper-card__badge.is-rated{background:rgba(224,193,124,.14);color:#f0d18a}
.chat-reviews{margin-top:10px}
.chat-reviews:empty{display:none}
.chat-review__title{margin:10px 0 6px;font-weight:600;color:#e8c979}
.chat-review{display:grid;gap:6px;padding:10px 0;border-top:1px solid rgba(255,255,255,.08)}
.chat-review__stars{display:flex;gap:4px}
.chat-review__stars button{min-width:44px;min-height:44px;border:0;background:transparent;color:#5d6e63;font-size:22px;padding:0}
.chat-review__stars button.is-on{color:#f0c75e}

/* Помощь в никахе: переписки помощника -- изумрудно-золотой градиент и два фото «кольцами» */
.chat-list__row--helper{background:linear-gradient(120deg,rgba(214,175,92,.20),rgba(23,110,82,.30) 55%,rgba(8,46,34,.6));border-color:rgba(232,196,110,.45)!important}
.chat-list__pair{position:relative;background:none!important;overflow:visible!important;width:58px}
.chat-list__ring{position:absolute;top:50%;width:38px;height:38px;margin-top:-19px;border-radius:50%;overflow:hidden;border:2px solid #e3c06f;background:#0a2a1f;box-shadow:0 2px 6px rgba(0,0,0,.4)}
.chat-list__ring:first-child{left:0;z-index:2}
.chat-list__ring:last-child{left:20px;border-color:#7fe0bb}
.chat-list__ring img{width:100%;height:100%;object-fit:cover;display:block}
.chat-list__helper-role{color:#f0d18a!important}
.helper-invite{background:linear-gradient(120deg,rgba(214,175,92,.18),rgba(23,110,82,.28));border-color:rgba(232,196,110,.5)!important}
.helper-invite__actions{display:flex;gap:8px;margin-top:8px}
.helper-invite__actions button{flex:1}

/* Приглашение помощнику: два кружка с инициалами пары, один выше, другой ниже */
.chat-list__pair--stack .chat-list__ring{display:grid;place-items:center;font:700 15px/1 Georgia,serif;color:#fbf0d4;width:34px;height:34px;margin-top:0}
.chat-list__pair--stack .chat-list__ring--female{top:2px;left:0;background:linear-gradient(160deg,#5a4a1f,#1f2a17)}
.chat-list__pair--stack .chat-list__ring--male{top:auto;bottom:2px;left:20px;background:linear-gradient(160deg,#1d5a45,#0b2a1f)}
.helper-invite__title{margin:4px 0 12px;line-height:1.35}
.helper-invite-modal strong{display:block;margin:12px 0 4px;color:#e8c979}
.helper-invite-modal p{margin:4px 0;line-height:1.45}
.helper-invite__list{margin:4px 0 8px;padding-left:20px;line-height:1.5}
.helper-invite__waiting{padding:10px 12px;border-radius:12px;background:rgba(224,193,124,.1);color:#f0d18a}
.chat-list__row--holdable,.chat-list__row--holdable *{-webkit-user-select:none;user-select:none;-webkit-touch-callout:none}
.chat-list__row--holdable img{pointer-events:none;-webkit-user-drag:none}
.chat-list__row--holdable.is-holding{transition:transform 5s linear,filter 5s linear;transform:scale(.97);filter:brightness(.8)}
.chat-list__row--ended{filter:saturate(.62);border-style:dashed!important}
.chat-list__inactive-status{color:var(--muted);font-size:12px;line-height:1.35}
.chat-member-leave{margin:4px 0 8px;min-height:36px;font-size:13px;color:#ff9a94;border-color:rgba(255,120,110,.45)}

/* Цвета переписок (владелец 2026-10-06): сестра -- лёгкий розовый, брат -- голубой, с помощником -- золотой, у самого помощника -- фиолетово-терракотовый */
.chat-list__row--sister{background:linear-gradient(120deg,rgba(236,134,170,.20),rgba(120,52,86,.18) 55%,rgba(8,40,30,.55));border-color:rgba(240,160,190,.38)!important}
.chat-list__row--brother{background:linear-gradient(120deg,rgba(96,170,236,.20),rgba(40,82,140,.18) 55%,rgba(8,40,30,.55));border-color:rgba(130,190,240,.38)!important}
.chat-list__row--with-helper{background:linear-gradient(120deg,rgba(232,196,110,.26),rgba(150,112,40,.18) 55%,rgba(8,40,30,.55));border-color:rgba(232,196,110,.5)!important}
.chat-list__row--helper{background:linear-gradient(120deg,rgba(150,98,210,.26),rgba(196,104,72,.20) 55%,rgba(30,20,30,.55))!important;border-color:rgba(205,140,120,.5)!important}
.helper-invite,.chat-list__row--helper .chat-list__helper-role{color:inherit}

/* Owner 2026-10-18: помощник «печатает» -- три точки, затем фраза «Сейчас узнаю…», точки под ней до ответа GPT. */
.chat-bubble--thinking p{margin:0 0 4px}
.chat-bubble--thinking p[hidden]{display:none}
.chat-typing{display:inline-flex;gap:4px;align-items:center;height:16px;padding:2px 0}
.chat-typing i{width:7px;height:7px;border-radius:50%;background:currentColor;opacity:.3;animation:chat-typing 1.2s infinite ease-in-out}
.chat-typing i:nth-child(2){animation-delay:.15s}.chat-typing i:nth-child(3){animation-delay:.3s}
@keyframes chat-typing{0%,60%,100%{opacity:.25;transform:translateY(0)}30%{opacity:.9;transform:translateY(-3px)}}
@media(prefers-reduced-motion:reduce){.chat-typing i{animation:none;opacity:.6}}
/* Owner 2026-10-19: какая кнопка уйдёт человеку -- метка в меню команд и под сообщением у администратора. */
.chat-cmd-buttons { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.chat-cmd-chip { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border: 1px solid rgba(255,140,130,.55); border-radius: 999px; background: rgba(255,120,110,.12); color: #ffb3ab; font-size: 11.5px; font-weight: 600; line-height: 1.5; }
.chat-cmd-chip::before { content: ""; width: 7px; height: 7px; border-radius: 2px; background: currentColor; opacity: .85; }
.chat-cmd-chip--maybe { border-style: dashed; background: transparent; color: #f0b9b3; font-weight: 500; }
.chat-staff-button { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(255,255,255,.08); }
.chat-staff-button__hint { font-size: 11.5px; color: rgba(255,255,255,.55); }
/* Плашка даты между днями переписки, как в Telegram (владелец 2026-10-28) */
.chat-day-separator { flex: none; align-self: center; margin: var(--ankihu-space-2,8px) 0; padding: 4px 12px; border-radius: 999px; font-size: 12px; font-weight: 600; line-height: 18px; color: var(--muted); background: color-mix(in srgb,var(--panel) 60%,transparent); }
/* Owner 2026-10-28: «Обращения» у сотрудника поддержки -- кнопка рядом с «Помощником» и список диалогов в стиле чатов */
.chat-list-header__buttons { display:flex; align-items:center; gap:8px; }
.chat-staff-inbox-button.chat-support-button--labelled { color:var(--gold-light,#f0d18a); background:rgba(217,175,89,.12); box-shadow:inset 0 0 0 1px rgba(239,209,139,.38); }
.staff-inbox .ankihu-modal__body { padding-inline:0; }
.staff-inbox__list { display:flex; flex-direction:column; }
.staff-inbox__row { display:grid; grid-template-columns:52px minmax(0,1fr); gap:12px; align-items:center; width:100%; min-height:72px; padding:10px 16px; border:0; background:transparent; color:inherit; text-align:left; -webkit-tap-highlight-color:transparent; }
.staff-inbox__row + .staff-inbox__row { box-shadow:inset 0 1px rgba(255,255,255,.06); }
.staff-inbox__row:active { background:rgba(255,255,255,.05); }
.staff-inbox__row--unread { background:linear-gradient(90deg,rgba(217,175,89,.10),transparent 70%); }
.staff-inbox__photo { position:relative; display:grid; place-items:center; width:52px; height:52px; overflow:hidden; border-radius:50%; font-weight:700; font-size:20px; color:var(--gold-light,#f0d18a); background:rgba(217,175,89,.14); }
.staff-inbox__photo img { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; }
.staff-inbox__content { display:flex; flex-direction:column; gap:3px; min-width:0; }
.staff-inbox__top,.staff-inbox__bottom { display:flex; align-items:center; gap:8px; min-width:0; }
.staff-inbox__name { flex:1; min-width:0; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; font-size:15px; }
.staff-inbox__time { flex:none; font-size:12px; color:var(--muted,#9eb0a6); }
.staff-inbox__row--unread .staff-inbox__time { color:var(--gold-light,#f0d18a); }
.staff-inbox__preview { flex:1; min-width:0; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; font-size:13px; line-height:1.35; color:var(--muted,#9eb0a6); }
.staff-inbox__bottom .chat-unread-badge { position:static; flex:none; }
.staff-inbox__flag { align-self:flex-start; padding:2px 8px; border-radius:999px; font-size:11px; font-weight:700; color:#f0d18a; background:rgba(217,175,89,.14); }

.profile-sheet {
  --ankihu-content-width: 560px;
  --ankihu-space-6: 24px;
  --ankihu-space-8: 32px;
  --ankihu-space-3: 12px;
  --ankihu-radius-card: 32px;
  --ankihu-space-5: 20px;
  --ankihu-space-4: 16px;
  --ankihu-space-1: 4px;
  --ankihu-font-size-meta: 12px;
  --ankihu-font-size-display: clamp(28px, 7.4vw, 36px);
  --ankihu-space-2: 8px;
  --ankihu-radius-round: 999px;
  --ankihu-touch-target: 48px;
  --ankihu-font-size-body: 16px;
  --ankihu-font-size-help: 13px;
  --ankihu-radius-control: 17px;
  --ankihu-font-size-title: 22px;
}
/* Owner-approved source: reference/AnkiHub_Premium_Profile.html .sheet/.state-choice.
   Palette and light are taken from that reference, scoped to profile sheets. */
.ankihu-modal.profile-sheet {
 --profile-sheet-base:#062318; --profile-sheet-ink:#f4ecd5;
 --profile-sheet-muted:#b3c3b6; --profile-sheet-gold:#d7b76d;
 --profile-sheet-line:rgba(201,185,120,.19);
 width:min(var(--ankihu-content-width),calc(100% - var(--ankihu-space-6)));
 max-height:calc(100dvh - var(--safe-top,0px) - var(--ankihu-space-8));
 margin:auto auto max(var(--ankihu-space-3),env(safe-area-inset-bottom));
 padding:0; overflow:hidden; border-radius:var(--ankihu-radius-card);
 border:1px solid #c6ae638c; color:var(--profile-sheet-ink);
 background:radial-gradient(ellipse at 20% 0%,#24463170,transparent 60%),var(--profile-sheet-base);
 box-shadow:0 -12px 50px #0006,inset 0 1px 0 #f5dda324;
}
.profile-sheet[open]{display:flex;flex-direction:column}
.profile-sheet::backdrop{background:#00100bb3;backdrop-filter:blur(5px)}
.profile-sheet > .ankihu-modal__header {
 position:relative; flex:none; padding:var(--ankihu-space-6) var(--ankihu-space-5) var(--ankihu-space-4);
 background:transparent; border-bottom:1px solid var(--profile-sheet-line); touch-action:none; user-select:none;
}
.profile-sheet__heading{flex:1;min-width:0}
.profile-sheet p.profile-sheet__kicker{margin:0 0 var(--ankihu-space-1);color:var(--profile-sheet-gold);font-size:var(--ankihu-font-size-meta);letter-spacing:.13em;text-transform:uppercase}
.profile-sheet .ankihu-modal__header h2{font-family:Georgia,'Times New Roman',serif;font-size:var(--ankihu-font-size-display);line-height:1.2;font-weight:500;color:#f5e7c0;letter-spacing:-.025em}
.profile-sheet__grip{position:absolute;top:var(--ankihu-space-2);left:50%;transform:translateX(-50%);width:var(--ankihu-space-8);height:var(--ankihu-space-1);border-radius:var(--ankihu-radius-round);background:var(--profile-sheet-muted);opacity:.45;pointer-events:none}
.profile-sheet > .ankihu-modal__body{overflow:auto;min-height:0;overscroll-behavior:contain;padding:var(--ankihu-space-5) var(--ankihu-space-5) var(--ankihu-space-6)}
.profile-sheet .ankihu-modal__close{margin:0;width:var(--ankihu-touch-target);height:var(--ankihu-touch-target);border:0;background:none;box-shadow:none;color:var(--profile-sheet-gold)}
.profile-sheet button:focus-visible{outline:none;text-decoration:underline;text-underline-offset:var(--ankihu-space-1)}
.profile-sheet p{font-size:var(--ankihu-font-size-body);line-height:1.6}
.profile-sheet .profile-sheet__intro{margin:0 0 var(--ankihu-space-5);color:var(--profile-sheet-muted)}
.profile-sheet p.profile-sheet__note,.profile-sheet .cabinet-note{margin:var(--ankihu-space-4) 0 0;color:var(--profile-sheet-muted);font-size:var(--ankihu-font-size-help)}
.profile-sheet .ankihu-modal__body button:not(.profile-state-choice){width:100%;min-height:var(--ankihu-touch-target);padding:var(--ankihu-space-3) var(--ankihu-space-4);border:1px solid #b9ab6259;border-radius:var(--ankihu-radius-control);background:#05251a;color:#d9cb9c;text-align:center}
.profile-sheet .ankihu-modal__body button.profile-sheet__primary{color:#14261a;background:linear-gradient(125deg,#ffe6a3,#d2a64e 85%,#bb903d);border-color:#f5d58b;box-shadow:inset 0 1px 0 #ffefc2,0 5px 17px #d4b4641a}
.profile-search-choices{display:grid;gap:var(--ankihu-space-3)}
.profile-sheet button.profile-state-choice{display:flex;align-items:center;gap:var(--ankihu-space-3);width:100%;padding:var(--ankihu-space-4);margin:0;min-height:var(--ankihu-touch-target);text-align:left;border:1px solid #acaa593b;border-radius:var(--ankihu-radius-control);background:transparent;color:var(--profile-sheet-ink)}
.profile-state-choice[aria-pressed="true"]{border-color:#d5b86d!important;background:#708d3c12!important}
.profile-choice-radio{width:var(--ankihu-space-5);height:var(--ankihu-space-5);border-radius:50%;border:1px solid #a59b66;display:grid;place-items:center;flex:none}
.profile-state-choice[aria-pressed="true"] .profile-choice-radio::after{content:'';width:var(--ankihu-space-3);height:var(--ankihu-space-3);border-radius:50%;background:#e7cd89}
.profile-state-choice strong{display:block;font-size:var(--ankihu-font-size-body);font-weight:600;line-height:1.4}
.profile-state-choice small{display:block;margin-top:var(--ankihu-space-1);font-size:var(--ankihu-font-size-help);line-height:1.5;color:var(--profile-sheet-muted)}
.profile-sheet dl{padding:var(--ankihu-space-4);border:1px solid var(--profile-sheet-line);border-radius:var(--ankihu-radius-control);background:#11302266}
.profile-sheet button:disabled{opacity:.5;cursor:wait}
/* «Скрыть возраст» в «Состоянии анкеты»: одна строка-галочка под выбором видимости. */
.profile-age-choice{display:flex;align-items:center;gap:var(--ankihu-space-3);margin-top:var(--ankihu-space-3);padding:var(--ankihu-space-4);min-height:var(--ankihu-touch-target);border:1px solid #acaa593b;border-radius:var(--ankihu-radius-control);cursor:pointer}
.profile-age-choice input{appearance:none;-webkit-appearance:none;flex:none;display:grid;place-items:center;width:var(--ankihu-space-5);height:var(--ankihu-space-5);margin:0;border:1px solid #a59b66;border-radius:6px;background:transparent;cursor:pointer}
.profile-age-choice input::after{content:'';width:10px;height:6px;border-left:2px solid #14261a;border-bottom:2px solid #14261a;transform:translateY(-1px) rotate(-45deg);opacity:0}
.profile-age-choice input:checked{background:linear-gradient(125deg,#ffe6a3,#d2a64e 85%,#bb903d);border-color:#f5d58b}
.profile-age-choice input:checked::after{opacity:1}
.profile-age-choice input:focus-visible{outline:2px solid #f5d58b;outline-offset:2px}
.profile-age-choice input:disabled{cursor:wait}
.profile-age-choice strong{display:block;font-size:var(--ankihu-font-size-body);font-weight:600;line-height:1.4}
.profile-age-choice small{display:block;margin-top:var(--ankihu-space-1);font-size:var(--ankihu-font-size-help);line-height:1.5;color:var(--profile-sheet-muted)}/* VIP-статус (кабинет → корона): золотая карточка по образцу «VIP на год» из окна тарифов. */
.vip-card{margin:0 0 var(--ankihu-space-4);padding:var(--ankihu-space-4);border:1px solid #f3d27a;border-radius:var(--ankihu-radius-card);background:radial-gradient(ellipse at 15% 0,#f6d77d45,transparent 70%),linear-gradient(128deg,#6a5420,#3a3214 46%,#14261a);box-shadow:inset 0 1px 0 #fff0c255,inset 0 0 18px #f3d27a26,0 0 6px #e8c35a40,0 5px 14px #0004}
.vip-card__head{display:flex;align-items:center;gap:var(--ankihu-space-4);padding-bottom:var(--ankihu-space-4);border-bottom:1px solid #f3d27a40}
.vip-card__art{flex:none;display:grid;place-items:center;width:56px;height:56px;border-radius:14px;border:1px solid #e6c67e8c;background:linear-gradient(145deg,#1d3a2a,#07231a);box-shadow:inset 0 1px 0 #ffedc340,0 4px 10px #0005}
.vip-card__art img{width:40px;height:40px;object-fit:contain}
.vip-card__state{display:grid;gap:2px;min-width:0}
.vip-card__state strong{font-family:Georgia,'Times New Roman',serif;font-size:var(--ankihu-font-size-display);font-weight:500;line-height:1.2;color:#fff2cf;letter-spacing:-.02em}
.vip-card__state span{color:#e9d8a6;font-size:var(--ankihu-font-size-help)}
.vip-card.is-active .vip-card__state span{color:#ffe39a}
.profile-sheet p.vip-card__lead{margin:var(--ankihu-space-4) 0 var(--ankihu-space-2);font-family:Georgia,'Times New Roman',serif;font-size:var(--ankihu-font-size-body);color:#f5e7c0}
.profile-sheet p.vip-card__lead.is-soon{margin-top:var(--ankihu-space-3);color:#cdbf95}
.vip-card__list{list-style:none;margin:0;padding:0;display:grid;gap:var(--ankihu-space-2)}
.vip-card__list li{position:relative;padding-left:26px;font-size:var(--ankihu-font-size-body);line-height:1.45;color:#f4ecd5}
.vip-card__list li::before{content:'\2713';position:absolute;left:2px;top:0;color:#f2d991}
.vip-card__list.is-soon li{color:#cdbf95}
.vip-card__list.is-soon li::before{content:'\00B7';left:6px;color:#cdbf95}
.profile-sheet .ankihu-modal__body .vip-card + .cabinet-note{margin:0 0 var(--ankihu-space-2)}
.profile-sheet .ankihu-modal__body .vip-card ~ button + button{margin-top:var(--ankihu-space-3)}
/* История покупок (кабинет → «Ключи»): баланс сверху, строки «дата · что · откуда». */
.purchase-balance{display:grid;grid-template-columns:auto 1fr;gap:var(--ankihu-space-2) var(--ankihu-space-4);margin:0 0 var(--ankihu-space-5)}
.purchase-balance dt{color:var(--profile-sheet-muted)}
.purchase-balance dd{margin:0;text-align:right;color:var(--profile-sheet-ink);font-variant-numeric:tabular-nums}
.purchase-history{list-style:none;margin:0 0 var(--ankihu-space-5);padding:0}
.purchase-history li{padding:var(--ankihu-space-3) 0;border-bottom:1px solid var(--profile-sheet-line);font-size:var(--ankihu-font-size-body);line-height:1.5;overflow-wrap:anywhere}
.purchase-history li:last-child{border-bottom:0}
.purchase-history time{color:var(--profile-sheet-muted)}
.purchase-history .is-plus{color:var(--profile-sheet-gold)}
@media(hover:hover) and (pointer:fine){.profile-state-choice:hover{background:#e1d7a206}}
.profile-privacy-blocked{margin-top:var(--ankihu-space-6);padding-top:var(--ankihu-space-5);border-top:1px solid var(--line)}
.profile-privacy-blocked h2{margin:0;font-size:var(--ankihu-font-size-title);color:var(--profile-sheet-ink)}
/* Name/date on the left, bounded action on the right; neither may cover the other. */
.profile-sheet .profile-privacy-blocked .cabinet-blocked-list li{display:grid;grid-template-columns:minmax(0,1fr) fit-content(60%);align-items:center;gap:var(--ankihu-space-2)}
.profile-sheet .cabinet-blocked-list li>span{min-width:0;line-height:1.5}
.profile-sheet .ankihu-modal__body .cabinet-blocked-list button{width:auto;max-width:100%;justify-self:end;margin:0;white-space:normal;overflow-wrap:anywhere}
.profile-sheet .ankihu-modal__body .cabinet-blocked-list button.cabinet-blocked-name{width:100%;justify-self:stretch;padding:0;border:0;background:transparent;text-align:left;font-weight:600;line-height:1.4;color:var(--profile-sheet-ink);text-decoration:underline;text-decoration-color:var(--profile-sheet-gold);text-underline-offset:var(--ankihu-space-1)}
.profile-sheet .cabinet-blocked-list .cabinet-note{margin:0;grid-column:1/-1}
.profile-privacy-danger{margin-top:var(--ankihu-space-6);padding-top:var(--ankihu-space-3);border-top:1px solid var(--line)}
.profile-sheet .ankihu-modal__body button.profile-delete-row{display:flex;align-items:center;justify-content:flex-start;gap:var(--ankihu-space-2);min-height:44px;margin:0;padding:0 var(--ankihu-space-2);border:0;background:transparent;color:var(--danger);font-size:var(--ankihu-font-size-help);text-align:left}
.profile-delete-row svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.profile-delete-confirm-actions{display:grid;grid-template-columns:1fr 1fr;gap:var(--ankihu-space-3)}
.profile-sheet .ankihu-modal__body button.profile-delete-confirm{color:#fff;background:color-mix(in srgb,var(--danger) 72%,#35100d);border-color:var(--danger)}
@media(prefers-reduced-motion:reduce){.profile-sheet{animation:none;transition:none}}

/* Окно раздела анкеты («Религия» и т.д.): тело обязано прокручиваться. Стили .section-reader.ahf
   из «Избранного» подгружаются позже и при равном приоритете отключали прокрутку. */
.profile-sheet > .ankihu-modal__body.section-reader{overflow-y:auto;overflow-x:hidden;min-height:0;-webkit-overflow-scrolling:touch;touch-action:pan-y}

.chat-welcome {
  --ankihu-space-6: 24px;
  --ankihu-space-4: 16px;
  --ankihu-space-2: 8px;
  --ankihu-font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Inter, ui-sans-serif, system-ui, sans-serif;
  --ankihu-color-text: #f2ede1;
  --ankihu-font-size-body: 16px;
  --ankihu-space-3: 12px;
  --ankihu-space-12: 48px;
  --ankihu-color-muted: #aaa89f;
  --ankihu-font-size-help: 13px;
}
.chat-welcome {
  flex: 0 0 auto; min-width: 0; width: 100%; box-sizing: border-box;
  padding: var(--ankihu-space-6) var(--ankihu-space-4);
  margin: var(--ankihu-space-2) 0 var(--ankihu-space-6);
  text-align: center; font-family: var(--ankihu-font-family);
  color: var(--ankihu-color-text); overflow-wrap: anywhere;
  align-self: center; max-width: 92%;
  background: color-mix(in srgb, var(--panel) 55%, transparent);
  border-radius: var(--field-radius);
  /* Same surface as chat-system-event; no participant bubble or nested scroller. */
}
.chat-welcome__title {
  margin: 0; font-size: var(--ankihu-font-size-body); line-height: 1.4; font-weight: 500;
}
.chat-welcome .chat-welcome__logo {
  display: block; margin: var(--ankihu-space-3) auto var(--ankihu-space-4);
  font-size: var(--ankihu-space-12); animation: none; opacity: 1; transform: none; filter: none;
}
.chat-welcome__description {
  margin: 0; font-size: var(--ankihu-font-size-body); line-height: 1.5; white-space: pre-line;
}
.chat-welcome__note {
  margin: var(--ankihu-space-4) 0 0; color: var(--ankihu-color-muted);
  font-size: var(--ankihu-font-size-help); line-height: 1.4;
}

.report-dialog .modal-body{padding:16px}.report-form{display:grid;gap:16px}.report-form label{display:grid;gap:7px;color:var(--text,#f5f0df)}.report-form select,.report-form textarea{width:100%;box-sizing:border-box;border:1px solid var(--line,#456b55);border-radius:12px;background:var(--surface,#0b3021);color:inherit;padding:12px;font:inherit;font-size:16px}.report-form small{text-align:right;opacity:.7}.report-form .report-block{display:flex;align-items:center;gap:10px}.report-block input{width:20px;height:20px}.report-actions{display:flex;gap:10px;justify-content:flex-end}.report-actions button{min-height:44px;border-radius:12px;border:1px solid var(--line,#456b55);padding:0 16px;background:transparent;color:inherit}.report-actions .report-submit{background:var(--gold,#d8b657);color:#122118;font-weight:700}.report-error{margin:0;color:#ff9d91}.chat-report-message{display:block;margin:7px 0 0 auto;border:0;background:transparent;color:inherit;opacity:.68;font-size:12px;text-decoration:underline}.chat-report-participant{color:#ffb8ae!important}
