/* ===== Учёт заявок — оформление в духе Битрикс24 ===== */
:root {
  --b24-blue: #2fc6f6;
  --b24-blue-dark: #11a9d9;
  --b24-green: #3bc35a;
  --b24-green-dark: #2ea94b;
  --b24-red: #ff5752;
  --text: #333;
  --text-2: #525c69;
  --text-3: #959ca4;
  --line: #edeef0;
  --panel-bg: #eef2f4;
  --activity-bg: #eef8fd;
  --sidebar-w: 236px;
  --font: "Open Sans", "Segoe UI", -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}

html, body { height: 100%; }
body {
  font-family: var(--font);
  font-size: 14px;
  color: var(--text);
  background-color: #2b2f78;
  background-image:
    radial-gradient(1100px 650px at 88% 6%, rgba(72, 196, 255, .55), transparent 62%),
    radial-gradient(900px 700px at 4% 96%, rgba(178, 76, 255, .38), transparent 60%),
    radial-gradient(700px 500px at 55% 55%, rgba(99, 90, 255, .25), transparent 70%),
    linear-gradient(135deg, #20276b 0%, #3a2d8f 42%, #27509f 100%);
  background-attachment: fixed;
}
a { color: #2067b0; text-decoration: none; }
a:hover { color: #11a9d9; }

/* ---------- каркас ---------- */
.app { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-w); flex-shrink: 0; padding: 14px 12px;
  position: sticky; top: 0; height: 100vh; overflow-y: auto; color: #fff;
}
.sidebar .brand {
  display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 700;
  font-size: 20px; padding: 4px 10px 16px; letter-spacing: -.3px;
}
.sidebar .brand i { font-size: 22px; opacity: .9; }
.sidebar .brand small { font-size: 11px; font-weight: 600; opacity: .6; vertical-align: super; }
.nav-group {
  background: rgba(255, 255, 255, .09); border-radius: 14px; padding: 6px; margin-bottom: 12px;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.nav-group-title { font-size: 12px; opacity: .55; padding: 6px 10px 4px; }
.side-link {
  display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 10px;
  color: #fff; font-size: 15px; position: relative; transition: background .15s;
}
.side-link i { font-size: 18px; width: 22px; text-align: center; opacity: .85; }
.side-link:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.side-link.active { background: rgba(255, 255, 255, .24); }
.side-link .cnt {
  margin-left: auto; background: var(--b24-red); color: #fff; font-size: 11px; font-weight: 700;
  min-width: 20px; height: 20px; border-radius: 10px; display: inline-flex; align-items: center;
  justify-content: center; padding: 0 6px;
}
.side-link .cnt.cnt-soft { background: rgba(255, 255, 255, .25); }

.main { flex: 1; min-width: 0; padding: 0 22px 30px 8px; }
.topbar { display: flex; align-items: center; gap: 10px; height: 60px; color: #fff; }
.topbar .spacer { flex: 1; }
.top-btn {
  width: 38px; height: 38px; border-radius: 50%; display: inline-flex; align-items: center;
  justify-content: center; color: #fff; background: rgba(255, 255, 255, .13); position: relative;
  border: 0; font-size: 17px;
}
.top-btn:hover { background: rgba(255, 255, 255, .25); color: #fff; }
.top-btn .badge-dot {
  position: absolute; top: -3px; right: -3px; background: var(--b24-red); color: #fff;
  font-size: 10px; font-weight: 700; min-width: 18px; height: 18px; border-radius: 9px;
  display: inline-flex; align-items: center; justify-content: center; padding: 0 4px;
}
.user-pill {
  display: inline-flex; align-items: center; gap: 8px; padding: 3px 12px 3px 3px; border-radius: 22px;
  background: rgba(255, 255, 255, .13); color: #fff; font-weight: 600; border: 0;
}
.user-pill:hover { background: rgba(255, 255, 255, .25); }
.burger { display: none; }

/* ---------- заголовок страницы и фильтры ---------- */
.page-head { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 6px 0 14px; }
.page-head h1 { color: #fff; font-size: 26px; font-weight: 700; margin: 0; letter-spacing: -.4px; }
.btn-b24 {
  display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 18px; border-radius: 10px;
  border: 0; font-weight: 700; font-size: 13px; text-transform: none; color: #fff; white-space: nowrap;
}
.btn-create { background: var(--b24-green); }
.btn-create:hover { background: var(--b24-green-dark); color: #fff; }
.btn-blue { background: var(--b24-blue); }
.btn-blue:hover { background: var(--b24-blue-dark); color: #fff; }
.btn-light-b24 { background: #fff; color: var(--text-2); border: 1px solid #c6cdd3; }
.btn-light-b24:hover { border-color: #a8adb4; color: var(--text); }
.btn-glass { background: rgba(255, 255, 255, .16); color: #fff; }
.btn-glass:hover, .btn-glass.show { background: rgba(255, 255, 255, .28); color: #fff; }
.btn-glass .cnt { background: var(--b24-red); border-radius: 10px; font-size: 11px; padding: 1px 7px; }

.filter-box {
  flex: 1; min-width: 260px; max-width: 560px; display: flex; align-items: center; gap: 6px;
  background: rgba(255, 255, 255, .16); border-radius: 10px; height: 38px; padding: 0 6px 0 4px;
}
.filter-box:focus-within { background: rgba(255, 255, 255, .26); }
.chip {
  display: inline-flex; align-items: center; gap: 6px; background: rgba(255, 255, 255, .9); color: #2a5d9f;
  border-radius: 7px; padding: 4px 6px 4px 10px; font-size: 13px; font-weight: 600; white-space: nowrap;
}
.chip a { color: #8f9aa6; }
.chip a:hover { color: var(--b24-red); }
.filter-box input {
  flex: 1; min-width: 60px; background: none; border: 0; outline: none; color: #fff; font-size: 14px;
}
.filter-box input::placeholder { color: rgba(255, 255, 255, .7); }
.filter-box button { background: none; border: 0; color: #fff; opacity: .8; }

.toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; align-items: center; }
.seg { display: inline-flex; background: rgba(255, 255, 255, .12); border-radius: 9px; padding: 3px; }
.seg a {
  color: #fff; padding: 5px 12px; border-radius: 7px; font-size: 13px; opacity: .9; white-space: nowrap;
}
.seg a.active { background: rgba(255, 255, 255, .3); opacity: 1; font-weight: 600; }
.seg a:hover { color: #fff; background: rgba(255, 255, 255, .2); }
.counter-pill {
  display: inline-flex; align-items: center; gap: 8px; color: #fff; font-size: 13px; padding: 5px 12px;
  border-radius: 9px; background: rgba(255, 255, 255, .12); white-space: nowrap; border: 0;
}
.counter-pill:hover, .counter-pill.active { background: rgba(255, 255, 255, .26); color: #fff; }
.counter-pill .n {
  min-width: 20px; height: 20px; border-radius: 10px; display: inline-flex; align-items: center;
  justify-content: center; font-size: 11px; font-weight: 700; background: rgba(255, 255, 255, .25); padding: 0 6px;
}
.counter-pill .n.hot { background: var(--b24-red); }
.counter-pill .n.green { background: var(--b24-green); }

/* ---------- таблица задач ---------- */
.grid-card { background: #fff; border-radius: 14px; overflow: hidden; box-shadow: 0 6px 30px rgba(10, 20, 70, .18); }
.grid { width: 100%; border-collapse: collapse; }
.grid th {
  font-weight: 400; color: var(--text-2); font-size: 14px; padding: 16px 14px; border-bottom: 1px solid var(--line);
  white-space: nowrap; background: #fff;
}
.grid td { padding: 0 14px; height: 52px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.grid tbody tr { cursor: pointer; transition: background .1s; }
.grid tbody tr:hover td { background: #f6faff; }
.grid tbody tr:hover td.col-activity { background: #e3f3fc; }
.grid .col-activity { background: var(--activity-bg); text-align: center; color: var(--text-2); white-space: nowrap; width: 230px; }
.grid th.col-activity { background: var(--activity-bg); }
.grid .col-num { color: var(--text-3); width: 64px; font-size: 13px; }
.grid .title { color: var(--text); font-size: 14px; }
.grid tr.is-closed .title { color: var(--text-3); text-decoration: line-through; }
.grid .title .prio { color: var(--b24-red); margin-left: 4px; }
.grid .title .prio.high { color: #ff9a00; }
.grid .person { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; color: var(--text); }
.grid .person.any { color: var(--text-3); font-style: italic; }
.grid .co { color: var(--text-3); font-size: 12px; margin-left: 4px; }
.unread-dot {
  display: inline-flex; align-items: center; justify-content: center; min-width: 19px; height: 19px;
  border-radius: 10px; background: var(--b24-red); color: #fff; font-size: 11px; font-weight: 700;
  padding: 0 5px; margin-right: 8px; vertical-align: 1px;
}
.st { font-size: 12px; padding: 3px 9px; border-radius: 12px; white-space: nowrap; font-weight: 600; }
.st-new { background: #e5f9ff; color: #0b8fbf; }
.st-in_progress { background: #e6f7e0; color: #3b8a1e; }
.st-waiting { background: #fff4d6; color: #b07900; }
.st-resolved { background: #ede8ff; color: #6a4fd6; }
.st-closed { background: #eef0f2; color: #7b838c; }
.st-cancelled { background: #f4e9e9; color: #a05252; }

.dl { display: inline-block; padding: 3px 10px; border-radius: 13px; font-size: 13px; white-space: nowrap; border: 1px solid transparent; }
.dl-none { border-color: #e1e6ea; color: var(--text-2); background: #fff; }
.dl-overdue { background: #ffe5e3; color: var(--b24-red); }
.dl-soon { background: #fff3d1; color: #b07400; }
.dl-future { background: #e9f6fd; color: #1a77b5; }

.ava {
  display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; color: #fff;
  font-weight: 700; flex-shrink: 0; letter-spacing: .3px; line-height: 1;
}
.ava-any { background: #dfe3e8; color: #8f99a3; }

.empty { text-align: center; color: var(--text-3); padding: 60px 20px; }
.empty i { font-size: 44px; display: block; margin-bottom: 8px; opacity: .5; }

.cards-mobile { display: none; }
.task-card { display: block; background: #fff; border-radius: 12px; padding: 12px 14px; margin-bottom: 8px; color: var(--text); }
.task-card .t { font-weight: 600; font-size: 15px; }
.task-card .meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 8px; color: var(--text-2); font-size: 13px; }

.pager { display: flex; justify-content: center; gap: 6px; margin-top: 14px; }
.pager a, .pager span { color: #fff; padding: 6px 12px; border-radius: 8px; background: rgba(255, 255, 255, .14); }
.pager span { background: rgba(255, 255, 255, .3); }

/* ---------- слайдер (карточка поверх списка, как в Б24) ---------- */
.slider-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, .35); z-index: 1050; opacity: 0; transition: opacity .25s; }
.slider-overlay.open { opacity: 1; }
.slider-panel {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(1440px, calc(100vw - 70px)); background: var(--panel-bg);
  z-index: 1051; transform: translateX(100%); transition: transform .3s cubic-bezier(.2, .8, .2, 1);
  box-shadow: -10px 0 40px rgba(0, 0, 0, .25);
}
.slider-panel.open { transform: translateX(0); }
.slider-panel iframe { width: 100%; height: 100%; border: 0; display: block; }
.slider-close {
  position: absolute; left: -50px; top: 16px; width: 40px; height: 40px; border-radius: 50%; border: 0;
  background: rgba(47, 198, 246, .95); color: #fff; font-size: 18px; display: flex; align-items: center; justify-content: center;
}
.slider-close:hover { background: var(--b24-blue-dark); }
.slider-loading { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--text-3); }

/* ---------- страница внутри слайдера ---------- */
body.in-slider { background: var(--panel-bg); background-image: none; }

/* ---------- карточка заявки ---------- */
.task-view { display: flex; height: 100vh; }
.app .task-view { height: calc(100vh - 80px); border-radius: 14px; overflow: hidden; box-shadow: 0 6px 30px rgba(10, 20, 70, .18); }
.task-side { width: 42%; min-width: 380px; max-width: 640px; background: var(--panel-bg); display: flex; flex-direction: column; }
.task-side-scroll { flex: 1; overflow-y: auto; padding: 20px 22px; }
.task-title { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 16px; }
.task-title h2 { font-size: 22px; font-weight: 700; margin: 0; flex: 1; line-height: 1.25; word-break: break-word; }
.task-title .num { color: var(--text-3); font-weight: 400; }
.icon-btn {
  width: 34px; height: 34px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center;
  color: var(--text-3); background: transparent; border: 0; font-size: 17px;
}
.icon-btn:hover { background: #fff; color: var(--text); }
.box { background: #fff; border-radius: 12px; padding: 14px 18px; margin-bottom: 12px; }
.desc { color: var(--text); white-space: pre-wrap; word-break: break-word; }
.desc.empty-desc { color: var(--text-3); }
.props { width: 100%; }
.props td { padding: 8px 0; vertical-align: top; }
.props td.k { color: var(--text-3); width: 130px; padding-right: 10px; }
.props .person { display: inline-flex; align-items: center; gap: 8px; margin: 0 10px 4px 0; }
.props hr { margin: 6px 0; border-color: var(--line); opacity: 1; }
.link-add { color: var(--text-3); font-size: 13px; border: 0; background: none; padding: 0; }
.link-add:hover { color: var(--b24-blue-dark); }
.chips-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.chip-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 9px; background: #fff;
  border: 0; color: var(--text-2); font-size: 13px;
}
.chip-btn:hover { color: var(--b24-blue-dark); box-shadow: 0 0 0 1px #d5e9f5; }
.chip-btn .n { color: var(--text-3); }
.history-list { list-style: none; padding: 0; margin: 0; font-size: 13px; }
.history-list li { padding: 7px 0; border-bottom: 1px solid var(--line); display: flex; gap: 10px; }
.history-list li:last-child { border-bottom: 0; }
.history-list .time { color: var(--text-3); white-space: nowrap; width: 105px; flex-shrink: 0; }
.task-footer {
  display: flex; align-items: center; gap: 10px; padding: 14px 22px; background: #fff;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, .05);
}
.task-footer .views { margin-left: auto; color: var(--text-3); font-size: 13px; }

/* ---------- чат ---------- */
.chat { flex: 1; display: flex; flex-direction: column; min-width: 0; position: relative;
  background-color: #8fb3dc;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.13' stroke-width='1.6'%3E%3Ccircle cx='20' cy='22' r='7'/%3E%3Cpath d='M70 15h18v12H70zM95 70l8 8-8 8M15 80c6-8 14-8 20 0M60 95h14m-7-7v14M45 50l6-6 6 6M100 30a6 6 0 1 0 0 .1'/%3E%3C/g%3E%3C/svg%3E"),
    linear-gradient(160deg, #9bbde4 0%, #7fa6d6 100%);
}
.chat-head {
  display: flex; align-items: center; gap: 12px; padding: 10px 18px; background: #fff; min-height: 62px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .06); z-index: 2;
}
.chat-head .ic { width: 40px; height: 40px; border-radius: 50%; background: #e5f5fd; color: var(--b24-blue-dark);
  display: flex; align-items: center; justify-content: center; font-size: 19px; }
.chat-head .t { font-weight: 700; font-size: 15px; }
.chat-head .s { color: var(--text-3); font-size: 13px; }
.chat-head .avas { margin-left: auto; display: flex; }
.chat-head .avas .ava { margin-left: -6px; border: 2px solid #fff; }
.chat-scroll { flex: 1; overflow-y: auto; padding: 16px 6% 10px; }
.chat-empty { text-align: center; color: #fff; margin-top: 18vh; opacity: .9; }
.chat-empty i { font-size: 42px; display: block; margin-bottom: 6px; }

.day-sep { text-align: center; margin: 14px 0; }
.day-sep span { background: rgba(82, 92, 105, .38); color: #fff; font-size: 13px; padding: 4px 14px; border-radius: 14px; }
.sys { text-align: center; margin: 8px 0; }
.sys span { display: inline-block; background: rgba(255, 255, 255, .55); color: #3e4c5c; font-size: 12.5px; padding: 4px 12px; border-radius: 12px; max-width: 90%; }
.sys b { font-weight: 600; }

.m { display: flex; align-items: flex-start; gap: 8px; margin: 3px 0; }
.m.mine { justify-content: flex-end; }
.m .ava-slot { width: 34px; flex-shrink: 0; }
.bubble {
  background: #fff; border-radius: 14px 14px 14px 4px; padding: 7px 12px 6px; max-width: min(560px, 78%);
  position: relative; box-shadow: 0 1px 1px rgba(0, 0, 0, .06); word-break: break-word;
}
.m.mine .bubble { background: #e3f7cf; border-radius: 14px 14px 4px 14px; }
.m.cont .bubble { border-radius: 14px; }
.bubble .who { font-weight: 600; font-size: 13px; color: #1f88c7; margin-bottom: 2px; }
.bubble .txt { white-space: pre-wrap; font-size: 14.5px; line-height: 1.42; }
.bubble .tm { float: right; font-size: 11px; color: #9aa4ad; margin: 6px 0 -3px 12px; white-space: nowrap; }
.m.mine .bubble .tm { color: #7fa36a; }
.bubble.has-img { padding: 4px; }
.bubble.img-only { background: transparent !important; box-shadow: none; padding: 0; }
.bubble.img-only .who { display: inline-block; background: #fff; border-radius: 10px; padding: 2px 10px; margin-bottom: 4px; }
.bubble.img-only .img-wrap img { box-shadow: 0 1px 3px rgba(0, 0, 0, .15); }
.bubble.has-img .who { padding: 3px 8px 2px; }
.bubble.has-img .txt { padding: 4px 8px 2px; }
.bubble .img-wrap { position: relative; display: block; }
.bubble .img-wrap img { display: block; max-width: 100%; width: auto; max-height: 380px; border-radius: 11px; cursor: zoom-in; background: #eef2f4; min-width: 120px; min-height: 80px; object-fit: cover; }
.bubble .img-wrap .tm-over { position: absolute; right: 8px; bottom: 8px; background: rgba(0, 0, 0, .45); color: #fff; font-size: 11px; padding: 2px 7px; border-radius: 10px; }
.bubble .file { display: flex; align-items: center; gap: 10px; padding: 4px 0; color: var(--text); min-width: 200px; }
.bubble .file i { font-size: 30px; color: var(--b24-blue-dark); }
.bubble .file .fn { font-weight: 600; font-size: 13.5px; word-break: break-all; }
.bubble .file .fs { color: var(--text-3); font-size: 12px; }

.composer { padding: 10px 6% 16px; }
.composer-box {
  background: #fff; border-radius: 16px; padding: 8px 8px 8px 14px; display: flex; align-items: flex-end; gap: 6px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .08);
}
.composer-box.drag { box-shadow: 0 0 0 3px var(--b24-blue); }
.composer textarea {
  flex: 1; border: 0; outline: none; resize: none; font-size: 14.5px; line-height: 1.4; padding: 7px 0;
  max-height: 160px; min-height: 22px; font-family: inherit;
}
.composer .tool { width: 36px; height: 36px; border-radius: 50%; border: 0; background: none; color: #a1a9b2; font-size: 19px; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.composer .tool:hover { color: var(--b24-blue-dark); background: #f0f7fb; }
.composer .send { width: 38px; height: 38px; border-radius: 50%; border: 0; background: #c9d1d8; color: #fff; font-size: 17px; display: inline-flex; align-items: center; justify-content: center; transition: background .15s; }
.composer .send.ready { background: var(--b24-blue); }
.composer .send.ready:hover { background: var(--b24-blue-dark); }
.attach-preview { display: none; align-items: center; gap: 10px; background: #fff; border-radius: 12px; padding: 8px 12px; margin-bottom: 8px; font-size: 13px; }
.attach-preview.show { display: flex; }
.attach-preview img { width: 44px; height: 44px; object-fit: cover; border-radius: 8px; }
.attach-preview .x { margin-left: auto; color: var(--text-3); border: 0; background: none; font-size: 18px; }
.attach-preview .progress { height: 4px; flex: 1; max-width: 160px; display: none; }
.chat-error { color: #fff; background: rgba(255, 87, 82, .9); border-radius: 10px; padding: 6px 12px; margin-bottom: 8px; font-size: 13px; display: none; }
.chat-readonly { text-align: center; color: #fff; padding: 14px; font-size: 13px; }

/* просмотр фото */
.lightbox { position: fixed; inset: 0; background: rgba(10, 14, 20, .9); z-index: 2000; display: none; align-items: center; justify-content: center; }
.lightbox.show { display: flex; }
.lightbox img { max-width: 94vw; max-height: 88vh; border-radius: 6px; }
.lightbox .lb-bar { position: absolute; top: 14px; right: 18px; display: flex; gap: 10px; }
.lightbox .lb-bar a, .lightbox .lb-bar button { color: #fff; background: rgba(255, 255, 255, .15); border: 0; width: 42px; height: 42px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 19px; }

/* ---------- формы ---------- */
.form-page { background: #fff; border-radius: 14px; padding: 24px 28px; max-width: 980px; box-shadow: 0 6px 30px rgba(10, 20, 70, .18); }
body.in-slider .form-page { box-shadow: none; max-width: none; border-radius: 0; min-height: 100vh; }
.title-input { font-size: 22px !important; font-weight: 600; border: 0 !important; border-bottom: 1px solid var(--line) !important; border-radius: 0 !important; padding-left: 0 !important; box-shadow: none !important; }
.form-label { color: var(--text-3); font-size: 13px; margin-bottom: 4px; }
.form-control, .form-select { border-color: #d5dbe0; border-radius: 8px; }
.form-control:focus, .form-select:focus { border-color: var(--b24-blue); box-shadow: 0 0 0 3px rgba(47, 198, 246, .18); }
.prop-row { display: grid; grid-template-columns: 170px 1fr; gap: 12px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); }
.prop-row:last-child { border-bottom: 0; }
.prop-row > label { color: var(--text-2); margin: 0; }
.ts-wrapper.multi .ts-control > div { background: #e5f5fd; color: #1a77b5; border-radius: 6px; }
.ts-control { border-color: #d5dbe0 !important; border-radius: 8px !important; }

/* ---------- вход ---------- */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-card { background: #fff; border-radius: 18px; padding: 36px 34px; width: 100%; max-width: 400px; box-shadow: 0 20px 60px rgba(10, 20, 70, .35); }
.login-card .logo { font-size: 24px; font-weight: 700; display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.login-card .logo i { color: var(--b24-blue); }

/* ---------- уведомления ---------- */
.notif-menu { width: 380px; max-height: 470px; overflow-y: auto; padding: 0; border: 0; border-radius: 14px; box-shadow: 0 10px 40px rgba(0, 0, 0, .25); }
.notif-menu .nh { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); font-weight: 700; position: sticky; top: 0; background: #fff; }
.notif-item { display: flex; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--line); color: var(--text); font-size: 13px; }
.notif-item:hover { background: #f6faff; color: var(--text); }
.notif-item.unread { background: #f0f9fe; }
.notif-item .when { color: var(--text-3); font-size: 12px; margin-top: 2px; }

.flash { position: fixed; top: 16px; left: 50%; transform: translateX(-50%); z-index: 3000; min-width: 280px; }

/* ---------- адаптив ---------- */
@media (max-width: 991.98px) {
  .sidebar { position: fixed; left: 0; top: 0; z-index: 1100; transform: translateX(-100%); transition: transform .25s;
    background: linear-gradient(160deg, #262d78, #3b2f93); box-shadow: 10px 0 30px rgba(0, 0, 0, .3); }
  .sidebar.open { transform: none; }
  .burger { display: inline-flex; }
  .main { padding: 0 12px 24px; }
  .task-view, .app .task-view { flex-direction: column; height: calc(100dvh - 64px); border-radius: 14px 14px 0 0; }
  body.in-slider .task-view { height: 100dvh; border-radius: 0; }
  .task-side { width: 100%; min-width: 0; max-width: none; flex: 1; min-height: 0; }
  .mobile-tabs { display: flex !important; }
  .task-view[data-tab="chat"] .task-side { display: none; }
  .task-view[data-tab="info"] .chat { display: none; }
  .chat { min-height: 0; }
  .chat-head { min-height: 52px; padding: 6px 12px; }
  .chat-scroll { padding: 12px 10px; }
  .composer { padding: 8px 8px calc(10px + env(safe-area-inset-bottom)); }
  .bubble { max-width: 86%; }
  .main { padding-bottom: 0; }
  .task-side-scroll { padding: 14px; }
  .task-footer { position: sticky; bottom: 0; flex-wrap: wrap; }
}
@media (max-width: 767.98px) {
  .grid-card { display: none; }
  .cards-mobile { display: block; }
  .page-head h1 { font-size: 22px; }
  .filter-box { order: 5; min-width: 100%; }
  .prop-row { grid-template-columns: 1fr; gap: 4px; }
  .form-page { padding: 16px; }
  .notif-menu { width: 92vw; }
  .history-list .time { width: 80px; }
}
.mobile-tabs { display: none; background: #fff; padding: 6px; gap: 6px; position: sticky; top: 0; z-index: 5; }
.mobile-tabs button { flex: 1; border: 0; background: var(--panel-bg); border-radius: 9px; padding: 8px; font-weight: 600; color: var(--text-2); }
.mobile-tabs button.active { background: var(--b24-blue); color: #fff; }

/* ---------- профиль / мессенджеры ---------- */
.profile-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 16px; align-items: start; max-width: 1200px; }
.profile-grid .form-page { max-width: none; }
.msgr-card { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; margin-bottom: 12px; }
.msgr-card.linked { border-color: #cdeccf; background: #fbfffb; }
.msgr-head { display: flex; align-items: center; gap: 12px; }
.msgr-ic { width: 42px; height: 42px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: 20px; flex-shrink: 0; }
.msgr-tg { background: #2aabee; }
.msgr-max { background: linear-gradient(135deg, #2b6cff, #a24bff); }
.link-box { background: #f3f9fd; border-radius: 10px; padding: 14px; }
.link-code { font: 700 28px/1.2 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: 4px; color: var(--text); margin: 6px 0 8px; user-select: all; }
.src-ic { font-size: 11px; opacity: .7; margin-right: 2px; }
@media (max-width: 991.98px) { .profile-grid { grid-template-columns: 1fr; } }
