/* ═══════════════════════════════════════════
   ОБЁРТКА
═══════════════════════════════════════════ */

.kk-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
}


/* ═══════════════════════════════════════════
   ШАГ 1 — Выбор формы
═══════════════════════════════════════════ */

.kk-step1__title {
  font-size: 18px;
  font-weight: 600;
  color: #2c2c2c;
  margin-bottom: 20px;
}

.kk-step1__shapes {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.kk-shape {
  flex: 1 1 0;
  border: 1px solid #c4c4c4;
  border-radius: 12px;
  padding: 20px 16px;
  cursor: pointer;
  text-align: center;
  background: #fff;
  transition: border-color 1s, box-shadow 1s;
}

.kk-shape:hover,
.kk-shape.is-active {
  border-color: #000;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.kk-shape__icon {
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 15px;
  max-width: 130px;
}

.kk-shape__icon img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.kk-shape__name {
  font-size: 15px;
  font-weight: 600;
  color: #2c2c2c;
  margin-bottom: 6px;
}

.kk-shape__desc {
  font-size: 13px;
  color: #989898;
  line-height: 1.4;
  transition: color 1s;
}

.kk-shape:hover .kk-shape__desc {
  color: #000;
}


/* ═══════════════════════════════════════════
   БЛОКИ РАЗМЕРОВ
═══════════════════════════════════════════ */

.kk-dims {
  display: flex;
  align-items: center;
  gap: 32px;
  margin-top: 24px;
  border: 1px solid #c4c4c4;
  border-radius: 12px;
  padding: 24px;
}

.kk-dims__pic {
  flex-shrink: 0;
  width: 200px;
}

.kk-dims__pic img {
  width: 100%;
  height: auto;
  display: block;
}

.kk-dims__fields {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
}


/* ═══════════════════════════════════════════
   ПОЛЯ ВВОДА
═══════════════════════════════════════════ */

.kk-field__label {
  display: block;
  font-size: 13px;
  color: #555;
  margin-bottom: 6px;
}

.kk-field__input-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.kk-field__input {
  width: 160px;
  padding: 9px 12px;
  border: 1px solid #c4c4c4;
  border-radius: 8px;
  font-size: 13px;
  font-family: inherit;
  color: #2c2c2c;
  outline: none;
  transition: border-color 1s;
}

.kk-field__input:focus {
  border-color: #000;
}

.kk-field__input:focus::placeholder {
  color: transparent;
}

.kk-field__input::-webkit-outer-spin-button,
.kk-field__input::-webkit-inner-spin-button { -webkit-appearance: none; }
.kk-field__input[type=number] { -moz-appearance: textfield; }

.kk-field__unit {
  font-size: 13px;
  color: #989898;
}

/* Подсказка под чекбоксом «выше 280 см» */
.kk-field__hint {
  margin-top: 4px;
  font-size: 12px;
  color: #989898;
  line-height: 1.45;
  max-width: 520px;
}


/* ═══════════════════════════════════════════
   КНОПКА ДАЛЕЕ
═══════════════════════════════════════════ */

.kk-next {
  margin-top: 32px;
  text-align: center;
}

.kk-next__btn {
  padding: 16px 48px;
  background: #000;
  color: #fff;
  font-size: 16px;
  font-family: inherit;
  font-weight: 600;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.3s;
}

.kk-next__btn:hover {
  background: #333;
}


/* ═══════════════════════════════════════════
   АДАПТИВ
═══════════════════════════════════════════ */

@media (max-width: 600px) {
  .kk-step1__shapes {
    flex-direction: column;
  }

  .kk-dims {
    flex-direction: column;
    align-items: flex-start;
  }

  .kk-dims__pic {
    width: 100%;
  }
}


/* Неактивная кнопка */
.kk-next .he-button.disabled {
  opacity: 0.4;
  pointer-events: none;
}


/* ═══════════════════════════════════════════
   ШАГ 3 — Выбор материалов
═══════════════════════════════════════════ */

.kk-materials {
  margin-top: 32px;
}

.kk-materials__layout {
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

/* Левая колонка — 75% */
.kk-materials__left {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Секция (Каркас / Фасад / ...) */
.kk-mat-section__options {
  background: #fff;
  background-color: var(--color-light-gray);
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

/* Заголовок секции */
.kk-mat-section__title {
  font-size: 16px;
  font-weight: 700;
  color: #2c2c2c;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.kk-mat-section__num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #2c2c2c;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.kk-mat-section__cards {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* Ссылка «Подробнее …» → статья в блоге */
.kk-mat-section__more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 16px;
  font-size: 13px;
  font-weight: 600;
  color: #2c2c2c;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.kk-mat-section__more:hover {
  color: #000;
  border-color: #000;
}

.kk-mat-section__more-arrow {
  display: inline-block;
  transition: transform 0.2s;
}

.kk-mat-section__more:hover .kk-mat-section__more-arrow {
  transform: translateX(3px);
}

/* Карточка материала */
.kk-mat-card {
  flex: 0 0 auto;
  width: 135px;
  border: 1px solid #c4c4c4;
  border-radius: 12px;
  padding: 10px;
  cursor: pointer;
  text-align: center;
  background: #fff;
  position: relative;
  transition: border-color 0.2s;
}

.kk-mat-card:hover {
  border-color: #989898;
}

.kk-mat-card.is-active {
  border-color: var(--color-dark-gray);
  border-width: 1px;
}
/* Галочка на активной карточке */
.kk-mat-card::after {
  content: '';
  position: absolute;
  top: 6px;
  right: 6px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #2c2c2c url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 6l3 3 5-5' stroke='%23fff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round' fill='none'/%3E%3C/svg%3E") center/12px no-repeat;
  opacity: 0;
  transition: opacity 0.2s;
}

.kk-mat-card.is-active::after {
  opacity: 1;
}



.kk-mat-card__img {
  width: 52px;
  height: 52px;
  border-radius: 8px;
  margin: 0 auto 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-light-gray, #f5f5f5);
  overflow: hidden;
}

.kk-mat-card__img img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.kk-mat-card__name {
  font-size: 12px;
  font-weight: 700;
  color: #2c2c2c;
  line-height: 1.3;
  margin-bottom: 3px;
}

.kk-mat-card__desc {
  font-size: 10px;
  color: #989898;
  line-height: 1.4;
}


/* ═══════════════════════════════════════════
   ПАНЕЛЬ ЦЕНЫ (sticky)
═══════════════════════════════════════════ */

.kk-price-panel {
  flex: 0 0 280px;
  position: sticky;
  top: 80px;
}

.kk-price-panel__inner {
  background-color: var(--color-light-gray);
  border-radius: 12px;
  padding: 24px;
}

.kk-price-panel__label {
  font-size: 13px;
  color: #989898;
  margin-bottom: 6px;
}

.kk-price-panel__amount {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 8px;
}

.kk-price-panel__num {
  font-size: 28px;
  font-weight: 700;
  color: #2c2c2c;
}

.kk-price-panel__currency {
  font-size: 14px;
  color: #989898;
}

/* CTA «Вызвать замерщика» (нижняя панель, десктоп) */
.kk-price-panel__cta {
  margin-top: 16px;
}

.kk-price-panel__cta {
	border: none;
}

.kk-price-panel__note {
  font-size: 12px;
  color: #989898;
  line-height: 1.4;
  margin-top: 16px;
}

.kk-price-panel__divider {
  height: 1px;
  background: #e8e8e8;
  margin: 16px 0;
}

.kk-price-params {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.kk-price-param {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.kk-price-param__key {
  font-size: 13px;
  color: #989898;
}

.kk-price-param__val {
  font-size: 13px;
  color: #2c2c2c;
  text-align: right;
}


/* ═══════════════════════════════════════════
   ДОПОЛНИТЕЛЬНЫЕ ОПЦИИ
═══════════════════════════════════════════ */

.kk-extras__options {
  background-color: var(--color-light-gray);
  border-radius: 12px;
  padding: 24px;
}

.kk-extras__title {
  font-size: 16px;
  font-weight: 700;
  color: #2c2c2c;
  margin-bottom: 18px;
}

.kk-extra-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 0;
  border-bottom: 1px solid var(--color-dark-gray);
}

.kk-extra-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.kk-extra-row:first-of-type {
  padding-top: 0;
}

.kk-extra-row__info {
  flex: 1;
}

.kk-extra-row__name {
  font-size: 14px;
  font-weight: 600;
  color: #2c2c2c;
  margin-bottom: 4px;
}

.kk-extra-row__desc {
  font-size: 12px;
  color: #989898;
  line-height: 1.4;
}

.kk-extra-toggle {
  display: flex;
  flex-shrink: 0;
  border: 1px solid #c4c4c4;
  border-radius: 8px;
  overflow: hidden;
}

.kk-extra-btn {
  padding: 8px 20px;
  font-size: 13px;
  font-family: inherit;
  font-weight: 600;
  background: #fff;
  color: #989898;
  border: none;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.kk-extra-btn + .kk-extra-btn {
  border-left: 1px solid #c4c4c4;
}

.kk-extra-btn.is-active {
  background: #2c2c2c;
  color: #fff;
}

@media (max-width: 600px) {
  .kk-extra-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}


/* ═══════════════════════════════════════════
   ВЕРХНЯЯ ПАНЕЛЬ ЦЕНЫ (kk-price-bar) — только моб.
═══════════════════════════════════════════ */

/* На десктопе верхняя панель скрыта полностью */
.kk-price-bar {
  display: none;
}

@media (max-width: 768px) {

  .kk-price-bar {
    display: block;
    position: sticky;
    /* Если у сайта есть фиксированная мобильная шапка —
       поменяйте 0 на её высоту, например top: 56px; */
    top: 0;
    z-index: 60;
    /* во всю ширину экрана, компенсируя padding .kk-wrap (40px сверху / 20px по бокам) */
    margin: -40px -20px 16px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.12);
    padding: 12px 16px;
  }

  .kk-price-bar__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
  }

  .kk-price-bar__main {
    display: flex;
    align-items: baseline;
    gap: 6px;
    flex-wrap: wrap;
  }

  .kk-price-bar__label {
    display: none;
  }

  .kk-price-bar__num {
    font-size: 22px;
    font-weight: 700;
    color: #2c2c2c;
  }

  .kk-price-bar__currency {
    font-size: 13px;
    color: #989898;
  }

  .kk-price-bar__toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    padding: 0;
    background: transparent;
    border: none;
    cursor: pointer;
    color: #2c2c2c;
  }

  .kk-price-bar__toggle svg {
    transition: transform 0.25s;
  }

  .kk-price-bar.is-open .kk-price-bar__toggle svg {
    transform: rotate(180deg);
  }

  .kk-price-bar__cta {
    margin-top: 12px;
  }

  .kk-price-bar__cta .he-button {
    display: flex;
    width: 100%;
    text-align: center;
    padding: 13px 20px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
  }

  .kk-price-bar__collapse {
    display: none;
    margin-top: 14px;
  }

  .kk-price-bar.is-open .kk-price-bar__collapse {
    display: block;
  }
}


/* ═══════════════════════════════════════════
   АДАПТИВ — шаг 3 (нижняя панель — как была)
═══════════════════════════════════════════ */

@media (max-width: 768px) {

  .kk-materials__layout {
    flex-direction: column;
  }

  .kk-materials__left {
    flex: 1 1 auto;
    width: 100%;
  }

  /* Нижняя панель: статична, остаётся под списком как в исходнике */
  .kk-price-panel {
    position: static;
    width: 100%;
  }

  /* font-size 16px = iOS/Android не зумят экран при фокусе на поле */
  .kk-field__input {
    font-size: 16px;
    width: 100%;
  }
}


/* ═══════════════════════════════════════════
   МОДАЛКА — форма вызова замерщика
═══════════════════════════════════════════ */

.kk-modal[hidden] {
  display: none;
}

.kk-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.kk-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  cursor: pointer;
}

.kk-modal__dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 460px;
  max-height: 90vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 14px;
  padding: 32px 28px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}

.kk-modal__close {
  position: absolute;
  top: 14px;
  right: 16px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  line-height: 1;
  color: #989898;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: color 0.2s;
}

.kk-modal__close:hover {
  color: #2c2c2c;
}

.kk-modal__title {
  font-size: 20px;
  font-weight: 700;
  color: #2c2c2c;
  margin-bottom: 6px;
  padding-right: 30px;
}

.kk-modal__subtitle {
  font-size: 13px;
  color: #989898;
  line-height: 1.45;
  margin-bottom: 20px;
}

/* блокировка прокрутки страницы под модалкой */
body.kk-modal-open {
  overflow: hidden;
}

@media (max-width: 600px) {
  .kk-modal {
    padding: 0;
    align-items: flex-end;
  }

  .kk-modal__dialog {
    max-width: 100%;
    max-height: 92vh;
    border-radius: 14px 14px 0 0;
    padding: 28px 20px;
  }
}