/* Своё для страницы вакансий: каркас, компоненты и тема — в /shared/styles.css */

/* ── Страница: две колонки на десктопе ─────────────────────────────────── */
/* Список вакансий с фильтрами в узкую колонку сайта не помещается, поэтому
   страница расширяет и контейнер, и --content-w: по нему выравнивается шапка,
   иначе её содержимое останется на месте, а страница уедет шире. */
.cols { display: flex; flex-direction: column; gap: 16px; }
@media (min-width: 900px) {
  :root { --content-w: 920px; }
  .wrap { max-width: 920px; }
  .cols { display: grid; grid-template-columns: 320px minmax(0, 1fr); align-items: start; }
  /* прилипшая колонка отсчитывается от нижнего края шапки, а не от края окна */
  #side { position: sticky; top: calc(var(--header-h) + 16px); display: flex; flex-direction: column; gap: 16px; }
}
/* Очень широкий экран (1920+): контейнер шире, список занимает место */
@media (min-width: 1600px) {
  :root { --content-w: 1240px; }
  .wrap { max-width: 1240px; }
  .cols { grid-template-columns: 360px minmax(0, 1fr); }
}

/* Город и формат под шапкой: что именно сейчас показано и откуда данные */
.sub { margin: 0; padding: 0 2px; font-size: 13px; line-height: 18px; color: var(--muted-foreground); }
.foot { padding: 0 2px 4px; font-size: 12px; line-height: 16px; color: var(--muted-foreground); text-align: center; }

/* Кнопка обновления в шапке: крутиться должна иконка, а не сама кнопка —
   вращающийся фон при наведении выглядит поломкой. */
.site-header .btn.spin { animation: none; }
.site-header .btn.spin .icon { animation: spin .7s linear infinite; }

/* ── Сводка: 2×2 плитки ────────────────────────────────────────────────── */
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat .stat-v { font-size: 20px; font-weight: 600; line-height: 26px; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stat .stat-l { font-size: 12px; line-height: 16px; color: var(--muted-foreground); }

/* поиск с иконкой слева */
.input-wrap .prefix {
  position: absolute; top: 0; left: 12px; height: 36px;
  display: flex; align-items: center;
  font-size: 16px; color: var(--muted-foreground); pointer-events: none;
}
.input-wrap.has-prefix .input { padding-left: 36px; }

/* ── Список вакансий ───────────────────────────────────────────────────── */
.found { padding: 2px 4px 0; font-size: 13px; color: var(--muted-foreground); }
.list.card { padding: 0; gap: 0; }
.grp {
  display: flex; align-items: baseline; gap: 8px;
  padding: 12px 16px 6px;
  font-size: 12px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.07em; color: var(--muted-foreground);
  border-top: 1px solid var(--border);
}
.grp:first-child { border-top: none; padding-top: 14px; }
.grp-n { color: var(--muted-foreground); font-weight: 400; letter-spacing: 0; }

.row-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  column-gap: 10px;
  width: 100%; padding: 12px 16px;
  border: none; background: transparent; color: inherit;
  font-family: inherit; text-align: left; cursor: pointer;
  outline: none;
}
.row-head:focus-visible { box-shadow: inset 0 0 0 2px color-mix(in oklch, var(--primary) 60%, transparent); }
@media (hover: hover) { .row-head:hover { background: color-mix(in oklch, var(--accent) 35%, transparent); } }

.row-info { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.pos { font-size: 15px; font-weight: 600; line-height: 21px; }
.meta { display: flex; align-items: center; gap: 5px; font-size: 13px; line-height: 18px; color: var(--muted-foreground); }
.meta .icon { font-size: 13px; color: var(--muted-foreground); }

/* пилюля з/п стоит в своей колонке у правого края, а не течёт за текстом */
.pill {
  display: inline-flex; align-items: center; white-space: nowrap;
  justify-self: end;
  padding: 1px 8px; border-radius: 999px;
  font-size: 13px; font-weight: 600; line-height: 20px;
  background: color-mix(in oklch, var(--primary) 20%, transparent);
  color: color-mix(in oklch, var(--primary) 82%, white);
}
.row-chev { font-size: 16px; color: var(--muted-foreground); transition: transform .15s ease; }
.row-head[aria-expanded="true"] .row-chev { transform: rotate(180deg); }

/* списка (не ul), поэтому маркер li гасим вручную */
.list.card, .vrow { list-style: none; }
.vrow + .vrow { border-top: 1px solid var(--border); }
.row-body { padding: 2px 16px 14px; display: flex; flex-direction: column; gap: 12px; }

.sal-line { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.sal-line .icon { font-size: 15px; color: color-mix(in oklch, var(--primary) 80%, white); }
.sal-line b { font-weight: 600; }
.sal-line .suff { font-weight: 600; }
.sal-line .dim { color: var(--muted-foreground); font-weight: 400; }

.blk { display: flex; flex-direction: column; gap: 4px; }
.blk-t { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted-foreground); }
.blk-x { margin: 0; font-size: 14px; line-height: 22px; color: color-mix(in oklch, var(--card-foreground) 88%, transparent); }

.acts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.acts .btn { font-size: 14px; padding: 8px 10px; }

.empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 28px 16px; text-align: center; color: var(--muted-foreground); }
.empty .icon { font-size: 22px; opacity: .6; }
.empty p { margin: 0; font-size: 13px; }
.empty button { max-width: 220px; }

/* ── Нативный селект (регион / город / место работы) ───────────────────── */
.sel {
  height: 36px;
  width: 100%;
  min-width: 0;
  padding: 0 30px 0 12px;
  border: 1px solid var(--input);
  border-radius: calc(var(--radius) - 2px);
  background: transparent;
  color: var(--foreground);
  font-family: inherit;
  font-size: 14px;
  line-height: 20px;
  text-overflow: ellipsis;
  box-shadow: var(--shadow-xs);
  outline: none;
  cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.sel:focus-visible {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px color-mix(in oklch, var(--primary) 50%, transparent);
}
.sel option { background: var(--popover); color: var(--foreground); }

/* ── Список магазинов в раскрытой магазинной строке ────────────────────── */
.sto { display: flex; flex-direction: column; gap: 6px; }
.sto + .sto { border-top: 1px solid var(--border); padding-top: 10px; }
.sto-addr {
  display: flex; align-items: flex-start; gap: 6px;
  font-size: 14px; line-height: 20px; font-weight: 600;
}
.sto-addr .icon { flex: none; margin-top: 2px; font-size: 14px; color: var(--muted-foreground); }
.sto-met {
  display: flex; align-items: baseline; gap: 6px;
  font-size: 13px; line-height: 18px; color: var(--muted-foreground);
}
.sto-met .cap {
  text-transform: uppercase; font-size: 11px; line-height: 18px;
  letter-spacing: .06em; font-weight: 600; color: var(--muted-foreground);
}
