/* Общие стили инструментов сервисных сайтов nopobig.
   Правятся только здесь и раскатываются на все проекты (ops\deploy_engines.py).
   Пастельная гамма, без эмодзи, светлая и тёмная схемы. */

.np-tool {
  --np-bg: #fbfaf8;
  --np-card: #ffffff;
  --np-line: #e6e2db;
  --np-text: #2f2c28;
  --np-muted: #7a736a;
  --np-accent: #6f8f7d;
  --np-accent-soft: #eef3ef;
  --np-warn: #a8784f;
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--np-text);
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  border-radius: 12px;
  padding: 20px;
  margin: 0 0 28px;
}

@media (prefers-color-scheme: dark) {
  .np-tool {
    --np-bg: #1e1d1b;
    --np-card: #262523;
    --np-line: #3a3835;
    --np-text: #ece8e2;
    --np-muted: #a49c92;
    --np-accent: #8fb09c;
    --np-accent-soft: #2b332e;
  }
}

.np-tool__head { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.np-tool__title { font-size: 18px; font-weight: 600; margin: 0; }
.np-tool__note { color: var(--np-muted); font-size: 13px; margin: 0; }

.np-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.np-field { display: flex; flex-direction: column; gap: 4px; }
.np-field label { font-size: 14px; font-weight: 500; }
.np-field input, .np-field select, .np-field textarea {
  font: inherit; padding: 9px 11px; border: 1px solid var(--np-line);
  border-radius: 8px; background: var(--np-card); color: inherit; width: 100%;
}
.np-field input:focus, .np-field select:focus { outline: 2px solid var(--np-accent); outline-offset: 1px; }
.np-field__hint { font-size: 12px; color: var(--np-muted); }
.np-field__err { font-size: 12px; color: var(--np-warn); }

.np-result { margin-top: 18px; background: var(--np-card); border: 1px solid var(--np-line); border-radius: 10px; padding: 16px; }
.np-result__main { display: flex; flex-wrap: wrap; gap: 22px; }
.np-result__item { min-width: 150px; }
.np-result__label { font-size: 13px; color: var(--np-muted); }
.np-result__value { font-size: 24px; font-weight: 600; letter-spacing: -0.01em; }
.np-result__value--small { font-size: 18px; font-weight: 500; }

.np-steps { margin: 16px 0 0; border-top: 1px solid var(--np-line); padding-top: 12px; }
.np-steps summary { cursor: pointer; font-size: 14px; color: var(--np-accent); }
.np-steps table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 14px; }
.np-steps th, .np-steps td { text-align: left; padding: 6px 8px; border-bottom: 1px solid var(--np-line); }
.np-steps td:last-child, .np-steps th:last-child { text-align: right; white-space: nowrap; }

.np-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.np-actions button {
  font: inherit; font-size: 14px; padding: 8px 14px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--np-line); background: var(--np-card); color: inherit;
}
.np-actions button:hover { background: var(--np-accent-soft); border-color: var(--np-accent); }
.np-actions button:focus-visible { outline: 2px solid var(--np-accent); outline-offset: 1px; }

.np-source { margin-top: 12px; font-size: 13px; color: var(--np-muted); }
.np-source a { color: inherit; }

.np-notes { margin: 12px 0 0; padding: 0 0 0 18px; font-size: 13px; color: var(--np-muted); }

/* Таблица-фильтр (E2) */
.np-table__controls { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.np-table__controls input, .np-table__controls select {
  font: inherit; padding: 8px 10px; border: 1px solid var(--np-line);
  border-radius: 8px; background: var(--np-card); color: inherit;
}
.np-table__wrap { overflow-x: auto; }
.np-table table { width: 100%; border-collapse: collapse; font-size: 15px; background: var(--np-card); }
.np-table th, .np-table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--np-line); }
.np-table th { cursor: pointer; white-space: nowrap; font-weight: 600; }
.np-table tr:target, .np-table tr.is-hit { background: var(--np-accent-soft); }
.np-table__empty { padding: 14px; color: var(--np-muted); font-size: 14px; }

/* Определитель (E3) */
.np-lookup__answer { margin-top: 16px; }
.np-lookup__card { background: var(--np-card); border: 1px solid var(--np-line); border-radius: 10px; padding: 14px; }
.np-lookup__card dl { display: grid; grid-template-columns: minmax(120px, 30%) 1fr; gap: 6px 14px; margin: 0; font-size: 15px; }
.np-lookup__card dt { color: var(--np-muted); }
.np-lookup__card dd { margin: 0; }

.np-table__controls input[type="search"] { min-width: 240px; flex: 1 1 240px; }
/* 🔴🔴 Выпадающий список тянется по САМОМУ ДЛИННОМУ варианту. У фильтра разделов
   ОКВЭД подписи вроде «A — Сельское, лесное хозяйство, охота…» распёрли страницу
   на 757 px вбок. Ширину режем здесь, а не подписями: подписи нужны читателю. */
.np-table__controls select { max-width: 100%; }
@media (min-width: 640px) { .np-table__controls select { max-width: 320px; } }
.np-table__controls button, .np-table__more button {
  font: inherit; font-size: 14px; padding: 8px 14px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--np-line); background: var(--np-card); color: inherit;
}
.np-table__controls button:hover, .np-table__more button:hover { background: var(--np-accent-soft); border-color: var(--np-accent); }
.np-table__more { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.np-table th[aria-sort="ascending"], .np-table th[aria-sort="descending"] { color: var(--np-accent); }

/* Определитель (E3): список похожих и подбор по модели */
.np-lookup__list { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.np-lookup__hit {
  font: inherit; text-align: left; display: flex; gap: 12px; align-items: baseline;
  padding: 9px 12px; border: 1px solid var(--np-line); border-radius: 8px;
  background: var(--np-card); color: inherit; cursor: pointer;
}
.np-lookup__hit:hover { background: var(--np-accent-soft); border-color: var(--np-accent); }
.np-lookup__hit-code { font-weight: 600; min-width: 72px; font-variant-numeric: tabular-nums; }

/* Календарь (E4) */
.np-cal { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; margin-top: 18px; }
.np-cal__month { background: var(--np-card); border: 1px solid var(--np-line); border-radius: 10px; padding: 12px; }
.np-cal__name { margin: 0 0 8px; font-weight: 600; font-size: 15px; text-transform: capitalize; }
/* 🔴 minmax(0,1fr), а не 1fr: иначе широкая ячейка распирает сетку вбок */
.np-cal__grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 2px; font-size: 13px; }
.np-cal__wd { text-align: center; color: var(--np-muted); font-size: 11px; padding: 2px 0; }
.np-cal__day, .np-cal__pad { text-align: center; padding: 5px 0; border-radius: 6px; font-variant-numeric: tabular-nums; }
.np-cal__day.is-off { background: var(--np-accent-soft); color: var(--np-warn); }
.np-cal__day.is-short { box-shadow: inset 0 -2px 0 var(--np-accent); }
.np-cal__sum { margin: 8px 0 0; font-size: 12px; color: var(--np-muted); }
/* 20.10.2026: календарь с номерами недель (cfg.wn) — узкий столбец слева */
.np-cal__grid--wn { grid-template-columns: 26px repeat(7, minmax(0, 1fr)); }
.np-cal__wn { text-align: center; padding: 5px 0; font-size: 11px; color: var(--np-muted); font-variant-numeric: tabular-nums; border-right: 1px solid var(--np-line); }
/* 13.10.2026: режим month — один месяц, два года рядом */
.np-cal--month { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.np-cal__col { min-width: 0; }
.np-cal__year { margin: 0 0 8px; font-weight: 700; font-size: 17px; text-transform: capitalize; }
.np-cal--month .np-cal__month { margin-bottom: 12px; }
.np-cal--month .np-cal__name { display: none; }
.np-cal--month .np-cal__day, .np-cal--month .np-cal__pad { padding: 8px 0; font-size: 15px; }
.np-cal--month .np-result__main { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 16px; }
.np-cal__special { list-style: none; margin: 12px 0 0; padding: 0; font-size: 14px; }
.np-cal__special li { padding: 5px 0 5px 12px; border-left: 3px solid var(--np-line); margin-bottom: 4px; }
.np-cal__special li.is-off { border-left-color: var(--np-warn); }
.np-cal__special li.is-work { border-left-color: var(--np-accent); }
.np-cal__table { width: 100%; border-collapse: collapse; margin-top: 18px; font-size: 14px; }
.np-cal__table th, .np-cal__table td { text-align: right; padding: 6px 8px; border-bottom: 1px solid var(--np-line); }
.np-cal__table th:first-child, .np-cal__table td:first-child { text-align: left; text-transform: capitalize; }

/* Сборщик текста (E5) */
.np-build__out { margin-top: 18px; }
.np-build__text {
  background: var(--np-card); border: 1px solid var(--np-line); border-radius: 10px;
  padding: 16px 18px; font-size: 16px; line-height: 1.7;
}
.np-build__text p { margin: 0 0 12px; }
.np-build__text p:last-child { margin-bottom: 0; }

/* Опросник (E6) — блок внутри статьи, поэтому уже и спокойнее остальных инструментов */
.np-poll { max-width: 640px; padding: 18px 20px; }
.np-poll__q { margin: 0; font-size: 17px; font-weight: 600; line-height: 1.4; }
.np-poll__head { margin-bottom: 14px; }
.np-poll__head .np-tool__note { margin-top: 6px; }

.np-poll__opts { display: flex; flex-direction: column; gap: 8px; }
.np-poll__opt {
  display: flex; align-items: flex-start; gap: 10px; cursor: pointer;
  padding: 10px 12px; border: 1px solid var(--np-line); border-radius: 8px;
  background: var(--np-card); font-size: 15px; line-height: 1.4;
}
.np-poll__opt:hover { background: var(--np-accent-soft); border-color: var(--np-accent); }
.np-poll__opt input { margin: 2px 0 0; flex: none; accent-color: var(--np-accent); }
.np-poll__opt:focus-within { outline: 2px solid var(--np-accent); outline-offset: 1px; }

.np-poll__res { display: flex; flex-direction: column; gap: 8px; }
/* Полоса лежит ПОД текстом отдельным слоем: цветной фон под буквами всегда
   проигрывает по контрасту, а так текст читается при любой длине полосы. */
.np-poll__row {
  position: relative; border: 1px solid var(--np-line); border-radius: 8px;
  background: var(--np-card); overflow: hidden;
}
.np-poll__bar {
  position: absolute; inset: 0 auto 0 0; background: var(--np-accent-soft);
  transition: width .35s ease;
}
.np-poll__row-in {
  position: relative; display: flex; justify-content: space-between; gap: 14px;
  padding: 10px 12px; font-size: 15px; line-height: 1.4;
}
.np-poll__row.is-mine { border-color: var(--np-accent); }
.np-poll__row.is-mine .np-poll__text { font-weight: 600; }
.np-poll__pct { font-variant-numeric: tabular-nums; color: var(--np-muted); white-space: nowrap; }
.np-poll__row.is-mine .np-poll__pct { color: var(--np-accent); }

.np-poll__foot { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 12px; }
.np-poll__sum { margin: 0; font-size: 13px; color: var(--np-muted); }
.np-poll__send {
  font: inherit; font-size: 14px; padding: 8px 16px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--np-accent); background: var(--np-accent-soft); color: inherit;
}
.np-poll__link {
  font: inherit; font-size: 13px; padding: 0; border: none; background: none;
  color: var(--np-accent); cursor: pointer; text-decoration: underline;
}
.np-poll__link:hover { text-decoration: none; }
.np-poll__send:focus-visible, .np-poll__link:focus-visible { outline: 2px solid var(--np-accent); outline-offset: 2px; }

@media print {
  .np-actions, .np-tool__note, .np-table__controls, .np-table__more, .np-poll { display: none; }
  .np-tool { border: none; padding: 0; background: none; }
  .np-cal { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* 18.09.2026: многострочное поле и кнопка «ещё раз» у генераторов */
.np-field textarea { font: inherit; resize: vertical; min-height: 120px; }
.np-again { margin: 4px 0 14px; padding: 12px 22px; border: 0; border-radius: 10px; background: var(--np-accent); color: #fff; font: inherit; font-weight: 700; cursor: pointer; }
.np-again:hover { filter: brightness(1.08); }
.np-again:focus-visible { outline: 2px solid var(--np-accent); outline-offset: 2px; }
.np-result__value.np-mono { font-family: ui-monospace, "JetBrains Mono", Consolas, monospace; word-break: break-all; }

/* 22.09.2026: поле по режиму (f.when) и картинка результата — QR-код */
.np-field[hidden] { display: none; }
.np-figure { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 18px; margin: 0 0 18px; }
.np-figure svg { width: min(100%, 260px); height: auto; border: 1px solid var(--np-line); border-radius: 8px; }
.np-figure__actions { display: flex; flex-direction: column; gap: 10px; }
.np-figure__actions .np-again { margin: 0; }
.np-again--ghost { background: transparent; color: var(--np-accent); box-shadow: inset 0 0 0 2px var(--np-accent); }
.np-figure__actions--row { flex-direction: row; flex-wrap: wrap; }  /* 04.10.2026: звук азбуки Морзе */

/* 23.09.2026: результат-матрица (калькулятор матриц) */
.np-matrix-wrap { overflow-x: auto; max-width: 100%; }
.np-matrix { border-collapse: separate; border-spacing: 0; margin: 4px 0 2px; border-left: 2px solid currentColor; border-right: 2px solid currentColor; border-radius: 6px; font-family: ui-monospace, "JetBrains Mono", Consolas, monospace; font-size: 1.15rem; }
.np-matrix td { padding: 4px 12px; text-align: right; white-space: nowrap; }
.np-matrix--small { font-size: .95rem; }
.np-grid { border-collapse: collapse; margin: 6px 0 2px; font-family: ui-monospace, "JetBrains Mono", Consolas, monospace; font-size: 1.1rem; background-image: linear-gradient(var(--np-grid-line, rgba(120,140,170,.18)) 1px, transparent 1px), linear-gradient(90deg, var(--np-grid-line, rgba(120,140,170,.18)) 1px, transparent 1px); background-size: 1.5em 1.7em; }
.np-grid td { width: 1.5em; min-width: 1.5em; height: 1.7em; padding: 0; text-align: center; position: relative; line-height: 1.7em; }
.np-grid td.u { border-bottom: 2px solid currentColor; }
.np-grid td.l { border-left: 2px solid currentColor; }
.np-grid td.c::after { content: ","; position: absolute; right: -.2em; bottom: 0; line-height: 1.2em; }
@media (max-width: 480px) { .np-grid { font-size: .95rem; } }
@media (max-width: 480px) { .np-matrix td { padding: 4px 8px; } .np-matrix--small { font-size: .88rem; } }

/* 04.10.2026: колесо фортуны и копирование строки результата */
.np-wheel { display: flex; justify-content: center; margin: 0 0 16px; }
.np-wheel svg { width: min(100%, 340px); height: auto; overflow: visible; }
.np-wheel g { transform-origin: 0 0; }
.np-result--spin .np-result__main, .np-result--spin .np-steps, .np-result--spin .np-notes { visibility: hidden; }
.np-result__item--copy { flex: 1 1 100%; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.np-result__item--copy .np-result__label { flex: 1 1 100%; }
.np-result__item--copy .np-result__value { overflow-wrap: anywhere; min-width: 0; }
.np-copy { font: inherit; font-size: 13px; padding: 4px 10px; border: 1px solid var(--np-line); border-radius: 6px; background: var(--np-card); color: var(--np-accent); cursor: pointer; }
.np-copy:hover { border-color: var(--np-accent); }

/* 05.10.2026: монетка «орёл или решка» */
.np-coin { display: flex; justify-content: center; margin: 0 0 16px; perspective: 800px; }
.np-coin__in { position: relative; width: 132px; height: 132px; transform-style: preserve-3d; }
.np-coin__face { position: absolute; inset: 0; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center;
  backface-visibility: hidden; -webkit-backface-visibility: hidden; color: #4a4134;
  background: radial-gradient(circle at 35% 30%, #f6ecd2, #e2cf9f 70%, #cdb57d); box-shadow: inset 0 0 0 6px #d8c38f, inset 0 0 0 8px #efe2bd; }
.np-coin__face--reshka { transform: rotateY(180deg); background: radial-gradient(circle at 35% 30%, #eef0f2, #cfd5da 70%, #b4bcc3); box-shadow: inset 0 0 0 6px #c3cad0, inset 0 0 0 8px #e6e9ec; }
.np-coin__big { font-size: 28px; font-weight: 700; line-height: 1; }
.np-coin__small { font-size: 13px; margin-top: 4px; letter-spacing: .04em; }
@media (prefers-reduced-motion: reduce) { .np-coin__in { transition: none !important; } }
/* 05.10.2026: формула шага с длинным числом (диагональ бруса 123 456 789) распирала таблицу на 400 px */
.np-steps td:not(:last-child) { overflow-wrap: anywhere; }

/* 07.10.2026: штрих-код (широкий, кнопки под картинкой) и резистор с цветными полосами */
.np-figure--barcode { flex-direction: column; }
.np-figure--barcode svg { width: min(100%, 440px); border-radius: 4px; }
.np-figure--resistor svg { width: min(100%, 320px); border: 0; border-radius: 0; }

/* 12.10.2026: кнопки частых дат у календаря «сколько прошло» */
.np-presets { display: flex; gap: 8px; flex-wrap: wrap; align-self: end; }
.np-presets button {
  font: inherit; font-size: 14px; padding: 8px 12px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--np-line); background: var(--np-card); color: inherit;
}
.np-presets button:hover { background: var(--np-accent-soft); border-color: var(--np-accent); }
.np-presets button:focus-visible { outline: 2px solid var(--np-accent); outline-offset: 1px; }

/* 13.10.2026: многострочный результат (Lorem ipsum, названия, вопросы кроссворда) */
.np-result__value--pre { white-space: pre-line; font-size: 16px; font-weight: 400; line-height: 1.6; letter-spacing: 0; overflow-wrap: anywhere; max-height: 440px; overflow-y: auto; }

/* 13.10.2026: кубики */
.np-dice { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin: 0 0 16px; }
.np-die { width: 64px; height: 64px; border-radius: 14px; background: var(--np-card); border: 2px solid var(--np-line); box-shadow: 0 2px 0 var(--np-line);
  display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--np-text); }
.np-die--pips { display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(3, 1fr); padding: 9px; box-sizing: border-box; }
.np-die__pip, .np-die__nop { width: 11px; height: 11px; border-radius: 50%; place-self: center; }
.np-die__pip { background: var(--np-text); }
.np-die__num { font-size: 24px; font-weight: 700; line-height: 1; }
.np-die__g { font-size: 11px; color: var(--np-muted); margin-top: 3px; }
.np-dice--roll .np-die { animation: np-die-roll .3s ease-in-out infinite alternate; }
.np-dice--roll .np-die:nth-child(2n) { animation-direction: alternate-reverse; }
@keyframes np-die-roll { from { transform: rotate(-14deg) translateY(-4px); } to { transform: rotate(14deg) translateY(2px); } }
@media (max-width: 480px) { .np-die { width: 54px; height: 54px; } .np-die__pip, .np-die__nop { width: 9px; height: 9px; } .np-die--pips { padding: 8px; } }
@media (prefers-reduced-motion: reduce) { .np-dice--roll .np-die { animation: none; } }

/* 13.10.2026: сравнение текстов */
.np-tool { --np-del-bg: #f6dcd8; --np-del: #8a3b30; --np-ins-bg: #dcebdc; --np-ins: #2f5d3a; }
@media (prefers-color-scheme: dark) { .np-tool { --np-del-bg: #4a2b27; --np-del: #f0c2ba; --np-ins-bg: #26402c; --np-ins: #bfe0c4; } }
.np-diff-wrap { margin: 0 0 16px; max-height: 520px; overflow: auto; border: 1px solid var(--np-line); border-radius: 8px; background: var(--np-card); }
.np-diff { padding: 12px 14px; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.65; }
.np-diff__del { background: var(--np-del-bg); color: var(--np-del); text-decoration: line-through; border-radius: 3px; }
.np-diff__ins { background: var(--np-ins-bg); color: var(--np-ins); text-decoration: none; border-radius: 3px; }
.np-diff-lines { width: 100%; border-collapse: collapse; font-family: ui-monospace, "JetBrains Mono", Consolas, monospace; font-size: 13.5px; line-height: 1.5; }
.np-diff-lines td { padding: 1px 6px; vertical-align: top; }
.np-diff-lines__n { width: 1%; color: var(--np-muted); text-align: right; white-space: nowrap; user-select: none; }
.np-diff-lines__s { width: 1%; user-select: none; }
.np-diff-lines__t { white-space: pre-wrap; overflow-wrap: anywhere; }
.np-diff-lines__del { background: var(--np-del-bg); }
.np-diff-lines__ins { background: var(--np-ins-bg); }
.np-diff-lines__del .np-diff-lines__t > span, .np-diff-lines__ins .np-diff-lines__t > span { opacity: .8; }
.np-diff-lines__del .np-diff__del { background: rgba(160, 60, 50, .22); }
.np-diff-lines__ins .np-diff__ins { background: rgba(50, 120, 70, .22); }
.np-diff-lines__gap { text-align: center; color: var(--np-muted); background: var(--np-accent-soft); font-family: inherit; }
@media (max-width: 480px) { .np-diff-lines { font-size: 12.5px; } .np-diff-lines td { padding: 1px 3px; } }

/* 13.10.2026: кроссворд */
.np-figure--cw { flex-direction: column; align-items: stretch; }
.np-cw { overflow-x: auto; }
.np-cw svg { display: block; width: min(100%, 600px); height: auto; margin: 0 auto; }
.np-cw__cell { fill: var(--np-card); stroke: var(--np-text); stroke-width: .4; }
.np-cw__num { font-size: 2.6px; fill: var(--np-muted); font-family: system-ui, sans-serif; }
.np-cw__ans { font-size: 6px; fill: var(--np-text); text-anchor: middle; font-family: system-ui, sans-serif; font-weight: 600; }
.np-cw--empty .np-cw__ans { display: none; }

/* 13.10.2026: график функций и картинка из Base64 */
.np-figure--plot { flex-direction: column; align-items: stretch; }
.np-plot svg { display: block; width: 100%; height: auto; }
.np-plot__grid { stroke: var(--np-line); }
.np-plot__axis { stroke: var(--np-muted); }
.np-plot__frame { stroke: var(--np-line); }
.np-plot__t { fill: var(--np-muted); }
.np-plot__legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 14px; }
.np-plot__key { display: inline-flex; align-items: center; gap: 6px; overflow-wrap: anywhere; }
.np-plot__sw { display: inline-block; width: 18px; height: 3px; border-radius: 2px; flex: none; }
.np-figure--img { flex-direction: column; }
.np-figure--img img { max-width: 100%; max-height: 360px; border: 1px solid var(--np-line); border-radius: 6px; background: repeating-conic-gradient(#eee 0 25%, #fff 0 50%) 0 0 / 16px 16px; image-rendering: auto; }

/* 14.10.2026: образцы цвета (генератор цвета) */
.np-swatch { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 8px; }
.np-swatch__item { min-height: 84px; border: 1px solid var(--np-line); border-radius: 8px; cursor: pointer; display: flex; align-items: flex-end; justify-content: center; padding: 6px; font: inherit; }
.np-swatch__cap { font-family: ui-monospace, Consolas, monospace; font-size: 13px; background: rgba(255, 255, 255, .85); color: #222; border-radius: 4px; padding: 1px 6px; }
.np-swatch__item--text { grid-column: 1 / -1; min-height: 96px; align-items: center; }
.np-swatch__item--text .np-swatch__cap { background: none; color: inherit; font-family: inherit; font-size: 20px; }


/* 14.10.2026: волна 10 topcalendar — смены, стаж, срок службы */
.np-cal__day.is-shift { background: var(--np-accent); color: var(--np-card); font-weight: 600; }
.np-cal__day.is-today { outline: 2px solid var(--np-text); outline-offset: -2px; }
.np-stazh { display: grid; gap: 10px; grid-column: 1 / -1; }
.np-stazh__row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; gap: 10px; align-items: end; }
.np-stazh__row .np-field__hint { margin: 2px 0 0; }
.np-stazh__add, .np-stazh__del {
  font: inherit; font-size: 14px; padding: 8px 12px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--np-line); background: var(--np-card); color: inherit;
}
.np-stazh__row .np-stazh__del { margin-bottom: 22px; }
.np-stazh__add { justify-self: start; }
.np-stazh__add:hover, .np-stazh__del:hover { background: var(--np-accent-soft); border-color: var(--np-accent); }
.np-progress { height: 10px; border-radius: 6px; background: var(--np-accent-soft); margin-top: 14px; overflow: hidden; }
.np-progress__fill { height: 100%; background: var(--np-accent); }
@media (max-width: 520px) {
  .np-stazh__row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .np-stazh__row .np-stazh__del { grid-column: 1 / -1; margin-bottom: 0; justify-self: start; }
}

/* 15.10.2026: волна 11 topcalendar — сокращённые дни: прошедшие бледнее */
.np-cal__special li.is-short { border-left-color: var(--np-accent); }
.np-cal__special li.is-past { opacity: .55; }

/* 15.10.2026 (волна 47): кнопка «ещё раз» скрывается в неслучайных режимах (cfg.againWhen) */
.np-again[hidden] { display: none; }

/* 19.10.2026: волна 12 topcalendar — часы, секундомер, будильник */
.np-clock { font-size: clamp(44px, 13vw, 96px); font-weight: 700; line-height: 1.1; text-align: center; font-variant-numeric: tabular-nums; letter-spacing: .02em; margin: 6px 0 4px; overflow-wrap: anywhere; }
.np-clock--small { font-size: clamp(32px, 9vw, 56px); }
.np-clock__date, .np-clock__dev { text-align: center; margin: 4px 0; }
.np-clock__dev { font-size: 14px; opacity: .8; }
.np-sw { justify-content: center; margin: 12px 0; }
.np-sw button { min-width: 110px; padding: 10px 16px; font-size: 16px; }
.np-sw .np-sw__main { background: var(--np-accent); border-color: var(--np-accent); color: var(--np-card); font-weight: 600; }
.np-sw button:disabled { opacity: .45; cursor: default; }
.np-cal__table--plain th:first-child, .np-cal__table--plain td:first-child { text-transform: none; }
.np-scroll { overflow-x: auto; max-width: 100%; }
@media (max-width: 520px) {
  .np-cal__table--plain { font-size: 13px; }
  .np-cal__table--plain th, .np-cal__table--plain td { padding: 5px 4px; }
}
