/* Кабинет Геша: подсказка и мобильная раскладка. */
.cabinet-page { overflow-x: clip; }
.cabinet-page .admin-header { display: flex; align-items: center; justify-content: space-between; min-width: 0; }
.cabinet-page .admin-header > .brand { flex: none; }
.cabinet-page .admin-nav { min-width: 0; }
.cabinet-page .cabinet-menu { display: none; }
.cabinet-page .cabinet-header-back { font-size: 13px; font-weight: 800; white-space: nowrap; }
.cabinet-page .cabinet-top > div,
.cabinet-page .cabinet-list-head,
.cabinet-page .item-main,
.cabinet-page .inbox-item { min-width: 0; }
.cabinet-page .cabinet-top h1,
.cabinet-page .inbox-head strong,
.cabinet-page .item-main h3 { overflow-wrap: anywhere; }

.gesh-helper {
  position: relative;
  display: grid;
  grid-template-columns: 145px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  margin: 30px 0 0;
  padding: 21px 24px 20px 10px;
  border: 1px solid #c8e0dd;
  border-radius: 22px;
  background: linear-gradient(120deg, #ecf8f8 0%, #f9fcf5 75%);
  box-shadow: 0 12px 28px #123e3b0a;
}
.gesh-helper-character { display: block; width: 145px; height: 132px; object-fit: contain; object-position: center bottom; align-self: end; }
.gesh-helper-copy { min-width: 0; }
.gesh-helper-kicker { margin: 0 0 6px; color: #38716c; font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.gesh-helper h2 { margin: 0 0 7px; color: #123c39; font: 800 clamp(19px, 2vw, 25px)/1.2 Unbounded, Manrope, sans-serif; letter-spacing: -.05em; }
.gesh-helper-copy > p:not(.gesh-helper-kicker) { margin: 0; max-width: 62ch; color: #496b69; font-size: 13px; line-height: 1.55; }
.gesh-helper-answers { margin-top: 12px; color: #173d3a; font-size: 13px; }
.gesh-helper-answers summary { display: inline-flex; align-items: center; gap: 9px; min-height: 39px; padding: 8px 12px; border: 1px solid #a5c5bf; border-radius: 999px; background: #fff; font-weight: 800; cursor: pointer; list-style: none; }
.gesh-helper-answers summary::-webkit-details-marker { display: none; }
.gesh-helper-answers summary span { font-size: 20px; line-height: 0; }
.gesh-helper-answers[open] summary span { transform: rotate(180deg); }
.gesh-helper-answers > div { max-width: 58ch; padding: 13px 2px 0; }
.gesh-helper-answers strong { display: block; margin-top: 9px; }
.gesh-helper-answers p { margin: 4px 0 10px; color: #496b69; line-height: 1.55; }
.form-wrap > .gesh-helper { margin: 0 0 25px; }

@media (max-width: 1100px) {
  .cabinet-page .admin-nav { display: none; }
  .cabinet-page .cabinet-menu { display: block; position: relative; z-index: 20; margin-left: auto; }
  .cabinet-page .cabinet-menu summary { display: flex; align-items: center; gap: 8px; min-height: 42px; padding: 10px 13px; border: 1px solid #ffffffa8; border-radius: 999px; color: #fff; font-size: 13px; font-weight: 800; cursor: pointer; list-style: none; }
  .cabinet-page .cabinet-menu summary::-webkit-details-marker { display: none; }
  .cabinet-page .cabinet-menu[open] summary span { transform: rotate(180deg); }
  .cabinet-page .cabinet-menu nav { position: absolute; right: 0; top: calc(100% + 9px); display: grid; width: min(305px, calc(100vw - 32px)); padding: 9px; border: 1px solid #bdd5d0; border-radius: 17px; background: #fff; box-shadow: 0 16px 38px #0b302d38; color: #143c3b; }
  .cabinet-page .cabinet-menu nav a,
  .cabinet-page .cabinet-menu nav button { display: block; width: 100%; padding: 12px 13px; border: 0; border-radius: 9px; background: transparent; color: inherit; font-size: 14px; font-weight: 700; text-align: left; }
  .cabinet-page .cabinet-menu nav a:hover,
  .cabinet-page .cabinet-menu nav button:hover { background: #eaf5f2; }
  .cabinet-page .cabinet-menu nav form { margin: 0; border-top: 1px solid #d8e7e3; padding-top: 5px; }
}

@media (max-width: 760px) {
  .cabinet-page .admin-header { height: 68px; padding-inline: 16px; gap: 12px; }
  .cabinet-page .admin-header .brand { width: 145px; }
  .cabinet-page .admin-header .brand-mark { width: 145px; height: auto; }
  .cabinet-page .admin-header .brand-mark img { width: 100%; height: auto; }
  .cabinet-page .cabinet-header-back { margin-left: auto; padding: 9px 11px; border: 1px solid #ffffffaa; border-radius: 999px; font-size: 12px; }
  .cabinet-page .cabinet-wrap,
  .cabinet-page .form-wrap { width: min(100% - 32px, 560px); padding-top: 28px; padding-bottom: 78px; }
  .cabinet-page .cabinet-top h1,
  .cabinet-page .form-wrap h1 { font-size: clamp(27px, 7.2vw, 38px); line-height: 1.17; letter-spacing: -.06em; }
  .cabinet-page .cabinet-top p:last-child,
  .cabinet-page .form-lead { font-size: 14px; line-height: 1.55; }
  .cabinet-page .cabinet-top .button { width: 100%; margin-top: 20px; }
  .cabinet-page .back-link { margin-bottom: 24px; }
  .cabinet-page .form-lead { margin-bottom: 23px; }
  .gesh-helper { grid-template-columns: 81px minmax(0, 1fr); gap: 5px; margin-top: 22px; padding: 13px 14px 15px 5px; border-radius: 18px; }
  .gesh-helper-character { width: 82px; height: 106px; }
  .gesh-helper h2 { font-size: 16px; }
  .gesh-helper-copy > p:not(.gesh-helper-kicker) { font-size: 12px; }
  .gesh-helper-answers { margin-top: 9px; }
  .gesh-helper-answers summary { min-height: 36px; padding: 7px 11px; font-size: 12px; }
  .cabinet-page .moderation-panel { margin-top: 24px; padding: 22px 18px; }
  .cabinet-page .moderation-head { align-items: start; flex-direction: column; gap: 11px; }
  .cabinet-page .moderation-head h2,
  .cabinet-page .cabinet-list-head h2 { font-size: 22px; line-height: 1.25; overflow-wrap: anywhere; }
  .cabinet-page .cabinet-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 27px 0 38px; border-radius: 12px; }
  .cabinet-page .cabinet-summary > div { display: grid; gap: 5px; padding: 13px 8px; text-align: center; }
  .cabinet-page .cabinet-summary span { font-size: 10px; line-height: 1.25; }
  .cabinet-page .cabinet-summary strong { font-size: 21px; }
  .cabinet-page .inbox-panel { margin-bottom: 40px; }
  .cabinet-page .inbox-item { padding: 17px; border-radius: 13px; }
  .cabinet-page .inbox-head { display: grid; gap: 6px; }
  .cabinet-page .inbox-head strong { font-size: 15px; line-height: 1.4; }
  .cabinet-page .inbox-question { overflow-wrap: anywhere; }
  .cabinet-page .cabinet-item { display: grid; grid-template-columns: 50px minmax(0, 1fr); gap: 8px 13px; align-items: start; }
  .cabinet-page .item-icon { width: 50px; height: 50px; font-size: 29px; grid-row: span 2; }
  .cabinet-page .status { margin: 0; justify-self: start; grid-column: 2; }
  .cabinet-page .edit-link { margin: 0; grid-column: 2; }
  .cabinet-page .object-form { padding: 20px 17px 22px; border-radius: 16px; }
  .cabinet-page .object-form fieldset { min-width: 0; margin-bottom: 28px; }
  .cabinet-page .object-form legend { max-width: 100%; margin-bottom: 17px; font-size: 18px; line-height: 1.3; overflow-wrap: anywhere; }
  .cabinet-page .object-form label { min-width: 0; }
  .cabinet-page .object-form input:not([type=checkbox]),
  .cabinet-page .object-form textarea,
  .cabinet-page .object-form select { width: 100%; min-width: 0; font-size: 16px; }
  .cabinet-page .object-form label > span { display: inline; }
  .cabinet-page .field-grid { grid-template-columns: minmax(0, 1fr); }
  .cabinet-page .form-actions { flex-direction: column; align-items: stretch; gap: 15px; }
  .cabinet-page .form-actions .button { width: 100%; }
  .cabinet-page .form-actions > a { text-align: center; }
}

@media (max-width: 350px) {
  .cabinet-page .admin-header .brand,
  .cabinet-page .admin-header .brand-mark { width: 119px; }
  .gesh-helper { grid-template-columns: 68px minmax(0, 1fr); }
  .gesh-helper-character { width: 68px; height: 94px; }
}

/* Обновление рабочего чата сохраняет формы и набранный ответ. */
.case-connection-status,
.case-refresh-notice { margin: 0 0 16px; padding: 14px 17px; border-radius: 13px; line-height: 1.5; font-size: 14px; }
.case-connection-status { color: #704c20; background: #fff5df; border: 1px solid #e9d6ad; }
.case-refresh-notice { color: #214c48; background: #e7f2ef; border: 1px solid #bcd8d0; }
.case-refresh-notice p { margin: 0 0 10px; }
.case-refresh-notice > span { display: block; margin-top: 10px; font-size: 12px; }
.case-refresh-notice .button { min-height: 42px; padding: 10px 15px; }
.case-connection-status[hidden],
.case-refresh-notice[hidden] { display: none; }
.case-chat--unified .case-chat-feed { max-height: min(68vh, 720px); overflow-y: auto; overscroll-behavior: contain; overflow-anchor: none; }
.case-chat--unified .case-bubble { overflow-wrap: anywhere; }
.inquiry-actions .inquiry-action-form select { width: 100%; min-width: 0; border: 1px solid #cadbd5; border-radius: 9px; padding: 11px; background: #fff; color: #143c3b; font: inherit; }
@media (max-width: 650px) {
  .case-connection-status, .case-refresh-notice { padding: 12px 14px; font-size: 13px; }
  .case-refresh-notice .button { width: 100%; justify-content: center; }
  .case-chat--unified .case-chat-feed { max-height: 64vh; }
}
