/* Админка, вход и страницы вне конференции: светлая и тёмная тема. Конференция живёт в meet.css и этот файл не подключает.
   Выбор темы: data-theme на <html>, без него — как в системе. Акцент --ac-l / --ac-d приходит со страницы из цвета компании. */
:root { color-scheme: light; --bg:#F6F7F9; --panel:#FFFFFF; --raised:#ECEEF2; --line:#E1E3E8; --line-2:#BFC4CE; --ink:#14161B; --ink-2:#4A4F5A; --ink-3:#5F6571;
  --ac:var(--ac-l); --ac-soft:var(--acs-l); --on-ac:#FFFFFF; --ok:#17693B; --ok-soft:#E1F2E7; --warn:#7D4E00; --warn-soft:#FAEFD9; --bad:#B3261E; --bad-soft:#FBE9E7; --shadow:rgba(20,22,27,.16);
  --mono:'IBM Plex Mono', ui-monospace, monospace; --sans:'IBM Plex Sans', system-ui, sans-serif; }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) { color-scheme: dark; --bg:#0F1116; --panel:#171A21; --raised:#232730; --line:#2A2F39; --line-2:#4A515F; --ink:#F1F2F5; --ink-2:#B9BEC9; --ink-3:#9CA2AF;
  --ac:var(--ac-d); --ac-soft:var(--acs-d); --on-ac:#14161B; --ok:#7BD8A4; --ok-soft:#163022; --warn:#EDB65F; --warn-soft:#35290F; --bad:#F49A93; --bad-soft:#3D1D1B; --shadow:rgba(0,0,0,.5); } }
:root[data-theme=dark] { color-scheme: dark; --bg:#0F1116; --panel:#171A21; --raised:#232730; --line:#2A2F39; --line-2:#4A515F; --ink:#F1F2F5; --ink-2:#B9BEC9; --ink-3:#9CA2AF;
  --ac:var(--ac-d); --ac-soft:var(--acs-d); --on-ac:#14161B; --ok:#7BD8A4; --ok-soft:#163022; --warn:#EDB65F; --warn-soft:#35290F; --bad:#F49A93; --bad-soft:#3D1D1B; --shadow:rgba(0,0,0,.5); }

* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--ink); font: 14px/1.45 var(--sans); -webkit-font-smoothing: antialiased; }
[hidden] { display: none !important; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: 24px; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; } h2 { font-size: 16px; font-weight: 600; } h3 { font-size: 13px; font-weight: 600; color: var(--ink-2); }
a { color: var(--ac); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--ac); outline-offset: 1px; }

.logo { display: inline-flex; align-items: center; gap: 10px; min-width: 0; color: inherit; text-decoration: none; }
.logo .m { height: 28px; width: auto; max-width: 120px; object-fit: contain; flex: none; } .logo .bn { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; } .logo .bn b { font-size: 16px; font-weight: 600; overflow-wrap: anywhere; } .logo small { font-size: 12.5px; color: var(--ink-3); }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 14px; border: 1px solid var(--line-2); border-radius: 6px; background: var(--panel); color: var(--ink); font-weight: 500; text-decoration: none; white-space: nowrap; cursor: pointer; }
.btn:hover { background: var(--raised); }
.btn.ac { border-color: var(--ac); background: var(--ac); color: var(--on-ac); font-weight: 600; } .btn.ac:hover { background: var(--ac); filter: brightness(.92); }
.btn.bad { border-color: var(--bad); background: var(--bad); color: var(--panel); font-weight: 600; } .btn.bad:hover { background: var(--bad); filter: brightness(.92); }
.link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 10px; border: 0; border-radius: 6px; background: none; color: var(--ink-2); text-decoration: none; white-space: nowrap; cursor: pointer; }
.link:hover { background: var(--raised); color: var(--ink); } .link.ac { color: var(--ac); font-weight: 500; } .link.del { color: var(--bad); } .link.del:hover { background: var(--bad-soft); color: var(--bad); }

input:not([type=checkbox]), select, textarea { width: 100%; min-width: 0; height: 44px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 6px; background: var(--panel); color: var(--ink); font-weight: 400; }
input::placeholder { color: var(--ink-3); } input[type=color] { padding: 4px; cursor: pointer; }
input[type=checkbox] { width: 20px; height: 20px; margin: 0; flex: none; accent-color: var(--ac); cursor: pointer; }
label { display: flex; flex-direction: column; gap: 6px; font-weight: 500; } label.sw { flex-direction: row; align-items: center; gap: 10px; min-height: 44px; font-weight: 400; cursor: pointer; }
.fine { font-size: 13px; color: var(--ink-2); line-height: 1.5; }
.msg { color: var(--bad); font-size: 13px; } .msg:empty { display: none; }

/* каркас */
.shell { display: grid; grid-template-columns: 232px minmax(0, 1fr); min-height: 100vh; }
.rail { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 20px; padding: 16px 12px; background: var(--panel); border-right: 1px solid var(--line); overflow: auto; }
.rail-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 4px 8px; } .rail-h .ver { font: 12px var(--mono); color: var(--ink-3); }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav button { min-height: 44px; padding: 0 10px; border: 0; border-radius: 6px; background: none; color: var(--ink-2); font-weight: 500; text-align: left; cursor: pointer; }
.nav button:hover { background: var(--raised); } .nav button.on { background: var(--ac-soft); color: var(--ac); font-weight: 600; }
.rail-f { margin-top: auto; display: flex; flex-direction: column; gap: 12px; }
.seg { display: flex; gap: 2px; padding: 3px; border-radius: 8px; background: var(--raised); }
.seg button { flex: 1 1 0; min-height: 38px; padding: 0 4px; border: 1px solid transparent; border-radius: 6px; background: none; color: var(--ink-2); font-size: 13px; font-weight: 500; cursor: pointer; }
.seg button.on { border-color: var(--line-2); background: var(--panel); color: var(--ink); }
.me { display: flex; align-items: center; justify-content: space-between; gap: 4px; } .me-b { min-width: 0; flex: 1; min-height: 44px; padding: 4px 8px; border: 0; border-radius: 6px; background: none; text-align: left; cursor: pointer; } .me-b:hover { background: var(--raised); }
.me-b b, .me-b small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .me-b b { font-weight: 500; } .me-b small { font-size: 12.5px; color: var(--ink-3); }
.main { min-width: 0; padding: 24px 20px 48px; }
.view, .warn-box { width: 100%; max-width: 1040px; margin: 0 auto; } .view, .stack, .pane { display: flex; flex-direction: column; gap: 20px; }
.warn-box { margin-bottom: 20px; padding: 12px 16px; border-radius: 6px; background: var(--warn-soft); color: var(--warn); }
.page-h { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; } .acts { display: flex; flex-wrap: wrap; gap: 8px; }
.card { padding: 20px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.empty { padding: 20px; color: var(--ink-2); line-height: 1.55; }

.filters { display: flex; flex-wrap: wrap; gap: 4px; }
.filters button { min-height: 44px; padding: 0 12px; border: 1px solid transparent; border-radius: 6px; background: none; color: var(--ink-2); cursor: pointer; } .filters button:hover { background: var(--raised); } .filters button.on { border-color: var(--line-2); background: var(--panel); color: var(--ink); }

/* таблицы */
.tw { border: 1px solid var(--line); border-radius: 10px; background: var(--panel); overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; }
.tbl th { padding: 12px 8px; color: var(--ink-3); font-size: 12.5px; font-weight: 500; text-align: left; white-space: nowrap; } .tbl td { padding: 8px; border-top: 1px solid var(--line); vertical-align: middle; }
.tbl th:first-child, .tbl td:first-child { padding-left: 16px; } .tbl th:last-child, .tbl td:last-child { padding-right: 16px; text-align: right; } .tbl td:last-child .acts { justify-content: flex-end; gap: 0; }
.tbl .sub { color: var(--ink-3); font-size: 12.5px; overflow-wrap: anywhere; } .tbl .soft { color: var(--ink-2); white-space: nowrap; } .tbl select { width: 160px; } .r.dim td:not(:last-child) { opacity: .6; }
.num { font: 12.5px var(--mono); color: var(--ink-2); white-space: nowrap; }
.title { display: block; max-width: 300px; padding: 0; border: 0; background: none; color: var(--ink); font-weight: 500; text-align: left; overflow-wrap: anywhere; cursor: pointer; } .title:hover { color: var(--ac); }
.st { display: inline-block; padding: 2px 8px; border-radius: 4px; background: var(--raised); color: var(--ink-2); font-size: 12.5px; font-weight: 500; white-space: nowrap; } .st.live { background: var(--ok-soft); color: var(--ok); } .st.wait { background: var(--warn-soft); color: var(--warn); }
.list { padding: 4px 20px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); }
.list .r { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 16px; min-height: 60px; padding: 8px 0; border-top: 1px solid var(--line); } .list .r:first-child { border-top: 0; }
.r-m { flex: 1 1 240px; min-width: 0; } .r-m b { display: block; font-weight: 500; overflow-wrap: anywhere; } .r-m span { color: var(--ink-2); font-size: 13px; overflow-wrap: anywhere; }

/* матрица прав и формы */
.mx { overflow-x: auto; } .mx table { width: 100%; border-collapse: collapse; } .mx th { padding: 8px; color: var(--ink-3); font-size: 12.5px; font-weight: 500; white-space: nowrap; } .mx td { padding: 0 8px; height: 44px; border-top: 1px solid var(--line); text-align: center; } .mx th:first-child, .mx td:first-child { padding-left: 0; text-align: left; min-width: 220px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px 16px; align-items: end; }
.sec { display: flex; gap: 6px; } .sec input { flex: 1; }
.logo-r { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; } .logo-r img { width: 44px; height: 44px; object-fit: contain; border: 1px solid var(--line); border-radius: 6px; } .logo-r label.btn { flex-direction: row; }
.save { position: sticky; bottom: 12px; display: flex; justify-content: flex-end; }

/* итоги встречи */
.back { align-self: flex-start; margin-left: -10px; } .det-h { display: flex; flex-direction: column; gap: 4px; }
.det { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 20px; align-items: start; }
.sum { margin: 0; font: inherit; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.55; }
.tr { display: flex; flex-direction: column; gap: 12px; max-height: 70vh; overflow: auto; margin: 0; font: inherit; line-height: 1.5; } pre.tr { display: block; white-space: pre-wrap; overflow-wrap: anywhere; }
.tr p { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 8px; } .tr p.c { display: block; } .tr .t { padding-top: 1px; font: 12.5px var(--mono); color: var(--ink-3); } .tr b { font-weight: 600; }

/* окно и уведомление */
.dlg { width: min(520px, calc(100vw - 32px)); max-height: 88vh; padding: 24px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--ink); box-shadow: 0 16px 48px var(--shadow); }
.dlg::backdrop { background: rgba(10,12,16,.5); } .dlg h3 { margin-bottom: 8px; font-size: 18px; color: var(--ink); } .dlg .col { display: flex; flex-direction: column; gap: 12px; } .dlg .row { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; margin-top: 16px; } .dlg .sub { font-weight: 500; margin-top: 4px; }
.mem { max-height: 220px; overflow: auto; border: 1px solid var(--line); border-radius: 6px; } .mem-r { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 6px 10px; border-top: 1px solid var(--line); } .mem-r:first-child { border-top: 0; } .mem-r i { color: var(--ink-3); font-style: normal; font-size: 12.5px; } .mem-r select { width: 130px; flex: none; }
.secret { display: block; margin-top: 12px; padding: 12px; border-radius: 6px; background: var(--raised); font: 13px var(--mono); overflow-wrap: anywhere; user-select: all; }
.toast { position: fixed; left: 50%; bottom: 24px; z-index: 50; max-width: calc(100vw - 32px); transform: translateX(-50%); padding: 10px 16px; border: 1px solid var(--line-2); border-radius: 6px; background: var(--panel); box-shadow: 0 8px 24px var(--shadow); }

/* вход, закрытая и завершённая встреча */
.solo { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px 16px; }
.solo-c { width: 100%; max-width: 460px; display: flex; flex-direction: column; gap: 12px; padding: 28px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); } .solo-c.login { max-width: 380px; gap: 16px; } .solo-c.wide { max-width: 1040px; } .solo-c h1 { font-size: 20px; } .solo-c > .btn { margin-top: 8px; } .solo-c p { color: var(--ink-2); }
.ended { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; align-items: start; margin-top: 12px; } .ended > section { display: flex; flex-direction: column; gap: 12px; min-width: 0; } .ended-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; }

@media (max-width: 760px) {
  .shell { display: block; } .rail { position: static; height: auto; gap: 12px; border-right: 0; border-bottom: 1px solid var(--line); }
  .nav { display: grid; grid-template-columns: repeat(auto-fit, minmax(104px, 1fr)); } .rail-f { margin-top: 0; }
  .main { padding: 20px 16px 40px; } .page-h .btn { width: 100%; } .det, .ended { grid-template-columns: minmax(0, 1fr); } .solo-c { padding: 20px; }
  .grid { grid-template-columns: minmax(0, 1fr); }
  .mx thead { display: none; } .mx tr { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); padding: 10px 0; border-top: 1px solid var(--line); } .mx td, .mx td:first-child { height: auto; padding: 0; border: 0; min-width: 0; } .mx td:first-child { grid-column: 1 / -1; padding-bottom: 8px; font-weight: 500; }
  .mx td:not(:first-child) { display: flex; flex-direction: column; align-items: center; gap: 6px; min-height: 44px; justify-content: center; } .mx td:not(:first-child)::before { content: attr(data-l); color: var(--ink-3); font-size: 12px; }
}
@media (max-width: 1100px) {
  .tbl.cards, .tbl.cards tbody, .tbl.cards tr, .tbl.cards td { display: block; } .tbl.cards thead { display: none; }
  .tbl.cards tr { padding: 12px 16px; border-top: 1px solid var(--line); } .tbl.cards tr:first-child { border-top: 0; }
  .tbl.cards td, .tbl.cards td:first-child, .tbl.cards td:last-child { padding: 3px 0; border: 0; text-align: left; } .tbl.cards td:last-child .acts { justify-content: flex-start; margin-left: -10px; } .tbl.cards select { width: 100%; } .title { max-width: none; }
}
