/* v3-копия static/css/cheese_select.css (2026-11-26): шаблоны v3 берут стили только из static/v3/ (docs/site-v3/README.md, «Пауза и текущий приоритет»). Скрипт общий — static/js/cheese_select.js. */
/* Выпадающий список в оформлении конспектов (cheese_select.js).
   Цвета — токены страницы, поэтому тёмная тема получается сама.
   Без скриптов виден обычный <select>: .cs__native прячется только
   тогда, когда рядом появилась наша кнопка. */

.cs { position: relative; display: block; }
.cs .cs__native {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.cs__head {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 8px 12px; cursor: pointer; text-align: left;
  color: var(--text); background: var(--surface);
  border: 1px solid var(--line); border-radius: 10px;
  font: 14px/1.4 var(--ui, "Segoe UI", -apple-system, Arial, sans-serif);
}
.cs__head:hover { border-color: var(--purple); }
.cs__head:focus-visible { outline: 2px solid var(--purple); outline-offset: 1px; }
.cs__text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cs__arrow { color: var(--subtle); font-size: 11px; transition: transform .12s; }
.cs.is-open .cs__head { border-color: var(--purple); }
.cs.is-open .cs__arrow { transform: rotate(180deg); }
.cs.is-off .cs__head { opacity: .5; cursor: default; }

.cs__list {
  position: absolute; z-index: 40; top: calc(100% + 5px); left: 0; min-width: 100%;
  display: none; flex-direction: column; gap: 2px; max-height: 320px; overflow-y: auto;
  padding: 5px; background: var(--paper); border: 1px solid var(--line);
  border-radius: 12px; box-shadow: 0 18px 46px rgba(0, 0, 0, .18);
}
.cs.is-open .cs__list { display: flex; }

.cs__item {
  display: block; width: 100%; padding: 7px 10px; cursor: pointer; text-align: left;
  color: var(--text); background: none; border: 0; border-radius: 8px;
  font: 14px/1.35 var(--ui, "Segoe UI", -apple-system, Arial, sans-serif);
}
.cs__item b { display: block; font-weight: 600; }
.cs__item small { display: block; color: var(--muted); font-size: 12px; }
.cs__item:hover, .cs__item:focus-visible {
  background: var(--purple-soft); outline: none;
}
.cs__item:hover small, .cs__item:focus-visible small { color: var(--purple-deep); }
.cs__item.is-on { color: var(--purple-deep); background: var(--purple-soft); }

.cs__item:disabled { opacity: .4; cursor: default; }
.cs.is-invalid .cs__head { border-color: var(--error-line, #c0392b); }
