/* Калькулятор печати на заказ (/calculator/). Общая часть инструмента (tl-*) повторяет stl-calculator.css:
   у файлов в c.css генератора нет версии по содержимому, поэтому общий файл не выносим. */

/* ===== Карточка инструмента: ввод слева, итог справа ===== */
.tl { margin-top: 16px; }
.tl-card { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(16px, 2vw, 24px); padding: clamp(16px, 2.4vw, 28px); border-radius: var(--r); box-shadow: inset 0 0 0 1px var(--line); background: #fff; }
.tl-in { display: flex; flex-direction: column; gap: 26px; padding: clamp(4px, 1vw, 12px); }
.tl-field__top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.tl-field__top label { font-weight: 700; font-size: 17px; }
.tl-field__val { font: 800 24px/1 var(--display); color: var(--accent-strong); white-space: nowrap; letter-spacing: -0.01em; }
.tl-scale { display: flex; justify-content: space-between; margin-top: 6px; color: var(--muted); font-size: 13px; }
.tl-hint { margin-top: 8px; color: var(--muted); font-size: 14px; line-height: 1.45; }
.tl-note { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 14px; background: var(--bg-2); font-size: 15px; line-height: 1.5; }
.tl-note svg { flex: none; margin-top: 2px; color: var(--accent-strong); }

/* Ползунок: серая дорожка, зелёная заливка до бегунка (--p ставит скрипт) */
.tl-range { --p: 50%; -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 28px; margin: 0; background: transparent; cursor: pointer; accent-color: var(--accent-strong); }
.tl-range:focus { outline: none; }
.tl-range::-webkit-slider-runnable-track { height: 8px; border-radius: 999px; background: linear-gradient(to right, var(--accent-strong) 0 var(--p), var(--bg-3, #e6eae7) var(--p) 100%); }
.tl-range::-moz-range-track { height: 8px; border-radius: 999px; background: var(--bg-3, #e6eae7); }
.tl-range::-moz-range-progress { height: 8px; border-radius: 999px; background: var(--accent-strong); }
.tl-range::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 26px; margin-top: -9px; border-radius: 50%; background: #fff; border: 0; box-shadow: 0 0 0 2px var(--accent-strong), 0 2px 8px rgba(14, 36, 22, 0.2); transition: transform 120ms var(--ease); }
.tl-range::-moz-range-thumb { width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 0; box-shadow: 0 0 0 2px var(--accent-strong), 0 2px 8px rgba(14, 36, 22, 0.2); }
.tl-range:active::-webkit-slider-thumb { transform: scale(1.08); }
.tl-range:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 2px var(--accent-strong), 0 0 0 6px rgba(0, 178, 45, 0.25); }
.tl-range:focus-visible::-moz-range-thumb { box-shadow: 0 0 0 2px var(--accent-strong), 0 0 0 6px rgba(0, 178, 45, 0.25); }

/* Итог */
.tl-out { display: flex; flex-direction: column; padding: clamp(20px, 2.4vw, 32px); border-radius: 14px; background: var(--bg-2); }
.tl-out__label { color: var(--muted); font-size: 15px; font-weight: 600; }
.tl-out__big { margin-top: 6px; font: 800 clamp(44px, 5.6vw, 68px)/1 var(--display); letter-spacing: -0.03em; color: var(--accent-strong); white-space: nowrap; }
.tl-out__split { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 20px; }
.tl-out__split div { padding: 12px 14px; border-radius: 12px; background: #fff; }
.tl-out__split dt { color: var(--muted); font-size: 13px; }
.tl-out__split dd { margin: 2px 0 0; font: 700 19px/1.2 var(--display); }
.tl-out__sub { margin-top: 14px; color: var(--muted); font-size: 14px; line-height: 1.5; }
.tl-out__cta { display: flex; flex-direction: column; gap: 8px; margin-top: auto; padding-top: 22px; }
.tl-out__row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tl-out__row .btn { padding: 0 12px; }

/* ===== Мост в каталог ===== */
.cc-bridge__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 16px; align-items: start; }
.cc-col { display: flex; flex-direction: column; padding: 20px; border-radius: var(--r); background: var(--bg-2); }
.cc-col h3 { margin-bottom: 12px; font: 700 18px/1.3 var(--display); }
.cc-list { display: grid; gap: 8px; }
.cc-item { display: flex; gap: 14px; align-items: center; padding: 12px 14px; border-radius: 12px; background: #fff; color: var(--ink); text-decoration: none; transition: box-shadow 160ms ease; }
@media (hover: hover) { .cc-item:hover { box-shadow: inset 0 0 0 1.5px var(--accent); } }
.cc-item.is-tight { box-shadow: inset 0 0 0 1.5px #f0c47a; }
.cc-item img { width: 64px; height: 64px; flex: none; object-fit: contain; }
.cc-item__t { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cc-item__t b { font-size: 15px; line-height: 1.3; }
.cc-item__t small { color: var(--muted); font-size: 13px; line-height: 1.4; }
.cc-item__p { font-size: 13px; color: var(--muted); }
.cc-item__p strong { color: var(--ink); font-size: 16px; font-weight: 800; }
.cc-item__p em { color: var(--accent-strong); font-style: normal; font-weight: 700; }
.cc-warn { color: #b45309; font-weight: 700; }
.cc-more { margin-top: 8px; }
.cc-more summary { padding: 6px 0; color: var(--accent-strong); font-weight: 600; font-size: 15px; cursor: pointer; }
.cc-more .cc-list { margin-top: 8px; }
.cc-small { margin-top: 10px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.cc-consult { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.cc-consult span { flex: 1 1 240px; font-size: 15px; line-height: 1.45; }
.cc-consult b { display: block; }
.cc-bridge .sv-note a { color: var(--accent-strong); font-weight: 600; }

.tl-related .sv-card { background: #fff; box-shadow: inset 0 0 0 1px var(--line); }
.tl-hero .sv-hero__note a { color: var(--accent-strong); font-weight: 600; }

@media (max-width: 960px) {
  .tl-card, .cc-bridge__grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .tl-card { padding: 12px; }
  .tl-in { padding: 8px 4px; gap: 22px; }
  .tl-out { padding: 20px 16px; }
  .tl-out__row { grid-template-columns: 1fr; }
  .cc-col { padding: 14px; }
  .cc-item { padding: 10px 12px; gap: 12px; }
  .cc-item img { width: 52px; height: 52px; }
}
