/* ==========================================================================
   Checkout
   ========================================================================== */

:root {
  --r: #e9332b;
  --rd: #c8241e;
  --rs: #fff0ed;

  --g: #88be21;
  --gd: #66980f;
  --gs: #eff8df;

  --o: #ffad24;

  --ink: #25211f;
  --mut: #6f6862;

  --line: #e8e1d9;
  --cream: #fffaf1;

  --shadow: 0 18px 48px #4b31231a;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;

  color: var(--ink);
  background: #fff;

  font:
    16px/1.5 Manrope,
    Arial,
    sans-serif;

  -webkit-font-smoothing: antialiased;
}

button,
input,
textarea {
  font: inherit;
}


/* ==========================================================================
   General
   ========================================================================== */

.secure {
  margin-left: auto;

  display: flex;
  align-items: center;

  gap: 10px;

  color: var(--mut);

  font-size: 13px;
}

.secure i {
  width: 38px;
  height: 38px;

  display: grid;
  place-items: center;

  border-radius: 10px;

  background: var(--gs);
  color: var(--gd);

  font-style: normal;
  font-weight: 800;
}


.page {
  min-height: calc(100vh - 122px);

  padding: 26px 0 60px;

  background:
    radial-gradient(
      circle at 85% 4%,
      #eef9d9,
      transparent 25%
    ),
    linear-gradient(
      180deg,
      #fffdf8,
      #fff 620px
    );
}


.back {
  display: inline-flex;
  align-items: center;

  gap: 7px;

  margin-bottom: 12px;

  color: var(--mut);

  font-size: 13px;

  text-decoration: none;
}


.title-row {
  display: flex;
  align-items: end;

  gap: 18px;

  margin-bottom: 25px;
}

.title-row h1 {
  margin: 0;

  font-size: 36px;
  line-height: 1.15;
  letter-spacing: -.04em;
}

.title-row span {
  padding-bottom: 4px;

  color: var(--mut);
}


/* ==========================================================================
   Layout
   ========================================================================== */

.layout {
  display: grid;

  grid-template-columns:
    minmax(0, 1fr)
    410px;

  gap: 30px;

  align-items: start;
}


.form-card,
.summary {
  border: 1px solid var(--line);
  border-radius: 17px;

  background: #fff;

  box-shadow: var(--shadow);
}


.form-card {
  padding: 28px;
}


/* ==========================================================================
   Form sections
   ========================================================================== */

.section-head {
  display: flex;
  align-items: flex-start;

  gap: 12px;

  margin-bottom: 20px;
}

.section-head i {
  width: 36px;
  height: 36px;

  flex: 0 0 36px;

  display: grid;
  place-items: center;

  border-radius: 10px;

  background: var(--rs);
  color: var(--r);

  font-style: normal;
  font-weight: 800;
}

.section-head h2 {
  margin: 0;

  font-size: 21px;
}

.section-head p {
  margin: 2px 0 0;

  color: var(--mut);

  font-size: 12px;
}


.fields {
  display: grid;

  grid-template-columns:
    1fr
    1fr;

  gap: 17px;
}


.field {
  display: grid;

  gap: 7px;
}

.field.full {
  grid-column: 1 / -1;
}


.field label {
  font-size: 13px;
  font-weight: 700;
}

.field label span {
  color: var(--r);
}


.field input,
.field textarea {
  width: 100%;

  border: 1px solid var(--line);
  border-radius: 10px;

  outline: 0;

  background: #fff;
  color: var(--ink);

  padding: 0 13px;

  transition: .18s;
}

.field input {
  height: 50px;
}

.field textarea {
  min-height: 95px;

  padding-top: 12px;

  resize: vertical;
}


.field input:focus,
.field textarea:focus {
  border-color: var(--g);

  box-shadow:
    0 0 0 3px #88be211c;
}


.field input.invalid {
  border-color: var(--r);

  background: var(--rs);
}


/* ==========================================================================
   Field errors
   ========================================================================== */

/*
 * ВАЖНО:
 * miniShop2 может добавлять класс "error" непосредственно самому input.
 * Поэтому нельзя использовать глобальное правило .error { display: none; },
 * иначе поле формы полностью исчезает после серверной валидации.
 */
.field > span.error {
  display: none;

  color: var(--r);

  font-size: 11px;
}

.field.bad > span.error {
  display: block;
}

/*
 * Защита для классов валидации miniShop2.
 * Сам контрол всегда должен оставаться видимым.
 */
.field input.error,
.field textarea.error,
.field select.error {
  display: block;
}


.section-divider {
  height: 1px;

  margin: 28px 0;

  background: var(--line);
}


/* ==========================================================================
   Confirmation
   ========================================================================== */

.delivery-note {
  display: flex;

  gap: 12px;

  padding: 15px;

  border-radius: 12px;

  background: var(--gs);
}

.delivery-note i {
  font-style: normal;
  font-size: 21px;
}

.delivery-note b,
.delivery-note small {
  display: block;
}

.delivery-note small {
  margin-top: 2px;

  color: var(--mut);
}


.payment-info {
  margin-top: 15px;
  padding: 15px;

  display: flex;

  gap: 12px;

  border: 1px solid var(--line);
  border-radius: 12px;
}

.payment-info i {
  width: 36px;
  height: 36px;

  flex: 0 0 36px;

  display: grid;
  place-items: center;

  border-radius: 9px;

  background: var(--cream);

  font-style: normal;
}

.payment-info b,
.payment-info small {
  display: block;
}

.payment-info small {
  color: var(--mut);

  font-size: 12px;
}


/* ==========================================================================
   Cart summary
   ========================================================================== */

.summary {
  position: sticky;

  top: 110px;

  padding: 23px;
}

.summary h2 {
  margin: 0;

  font-size: 21px;
}


.summary-head {
  display: flex;
  align-items: center;
  justify-content: space-between;

  gap: 15px;

  margin-bottom: 18px;
}

.summary-head a {
  color: var(--r);

  font-size: 12px;
  font-weight: 700;
}


.cart-items {
  min-width: 0;
}


/* ==========================================================================
   Cart product
   ========================================================================== */

.item {
  display: grid;

  grid-template-columns:
    72px
    minmax(0, 1fr)
    auto
    24px;

  gap: 12px;

  align-items: center;

  padding: 14px 0;

  border-top: 1px solid var(--line);
}


/* Image */

.item-image {
  width: 72px;
  height: 72px;

  display: block;

  overflow: hidden;

  border-radius: 9px;
}

.item-image img {
  display: block;

  width: 100%;
  height: 100%;

  object-fit: contain;
}


/* Product info */

.item-info {
  min-width: 0;
}

.item-title {
  min-width: 0;

  display: -webkit-box;

  overflow: hidden;

  color: var(--ink);

  font-size: 13px;
  line-height: 1.35;
  font-weight: 700;

  text-decoration: none;

  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.item-title-small {
        font-size: 11px;
    display: block;
    font-style: italic;
}

.item-title:hover,
.item-title:focus-visible {
  color: var(--r);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.item-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;

  gap: 6px 8px;

  margin-top: 7px;
}


.item-meta small {
  color: var(--mut);

  font-size: 10px;
  line-height: 1.2;

  white-space: nowrap;
}


/* ==========================================================================
   Cart quantity
   ========================================================================== */

.cart-qty {
  height: 30px;

  display: inline-grid;

  grid-template-columns:
    28px
    34px
    28px;

  overflow: hidden;

  border: 1px solid var(--line);
  border-radius: 8px;

  background: #fff;
}


.cart-qty__btn {
  width: 28px;
  height: 28px;

  padding: 0;

  display: flex;
  align-items: center;
  justify-content: center;

  border: 0;

  background: #faf8f5;
  color: var(--ink);

  font-size: 17px;
  line-height: 1;

  cursor: pointer;

  transition:
    background-color .15s ease,
    color .15s ease;
}


.cart-qty__btn:hover,
.cart-qty__btn:focus-visible {
  background: var(--gs);
  color: var(--gd);

  outline: 0;
}


.cart-qty__input {
  width: 34px;
  height: 28px;

  padding: 0;

  border: 0;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);

  outline: 0;

  background: #fff;
  color: var(--ink);

  font-size: 11px;
  line-height: 28px;
  font-weight: 700;

  text-align: center;

  -moz-appearance: textfield;
}


.cart-qty__input:focus {
  background: #fffdf8;
}


.cart-qty__input::-webkit-inner-spin-button,
.cart-qty__input::-webkit-outer-spin-button {
  margin: 0;

  -webkit-appearance: none;
}


/*
 * MiniShop2 нужен submit с cart/change,
 * визуально он нам не нужен.
 */
.cart-qty__submit {
  display: none;
}


/* ==========================================================================
   Cart product cost
   ========================================================================== */

.item-cost {
  white-space: nowrap;

  color: var(--ink);

  font-size: 13px;
  line-height: 1.2;
  font-weight: 800;

  text-align: right;
}


/* ==========================================================================
   Remove product
   ========================================================================== */

.item-remove {
  margin: 0;

  display: flex;
  align-items: center;
  justify-content: flex-end;
}


.item-remove button {
  width: 24px;
  height: 28px;

  padding: 0;

  display: flex;
  align-items: center;
  justify-content: center;

  border: 0;
  border-radius: 6px;

  background: transparent;
  color: var(--r);

  font-size: 16px;
  line-height: 1;

  cursor: pointer;

  transition:
    background-color .15s ease,
    color .15s ease;
}


.item-remove button:hover,
.item-remove button:focus-visible {
  background: var(--rs);
  color: var(--rd);

  outline: 0;
}


/* ==========================================================================
   Totals
   ========================================================================== */

.total-lines {
  padding-top: 14px;

  border-top: 1px solid var(--line);
}


.total-line {
  display: flex;
  justify-content: space-between;

  gap: 20px;

  margin-top: 9px;

  font-size: 13px;
}


.total-line.grand {
  align-items: flex-end;

  margin-top: 17px;
}

.total-line.grand span {
  font-weight: 800;
}

.total-line.grand b {
  color: var(--r);

  font-size: 27px;

  white-space: nowrap;
}


/* ==========================================================================
   Submit
   ========================================================================== */

.submit {
  width: 100%;
  height: 54px;

  margin-top: 20px;

  border: 0;
  border-radius: 11px;

  background: var(--g);
  color: #fff;

  font-weight: 800;

  cursor: pointer;

  box-shadow:
    0 10px 23px #6f9e202f;
}


.submit:hover {
  background: var(--gd);
}


.submit:disabled {
  opacity: .65;

  cursor: wait;
}


/* ==========================================================================
   Consent
   ========================================================================== */

.consent {
  display: flex;

  gap: 8px;

  margin-top: 12px;

  color: var(--mut);

  font-size: 10px;
  line-height: 1.4;
}

.consent input {
  margin-top: 2px;

  accent-color: var(--g);
}


/* ==========================================================================
   Help
   ========================================================================== */

.help {
  margin-top: 16px;
  padding-top: 15px;

  border-top: 1px solid var(--line);

  color: var(--mut);

  font-size: 11px;

  text-align: center;
}

.help a {
  color: var(--ink);

  font-weight: 800;
}


/* ==========================================================================
   Empty cart
   ========================================================================== */

.checkout-empty {
  padding: 30px 10px;

  color: var(--mut);

  font-size: 13px;

  text-align: center;
}

.checkout-empty a {
  color: var(--r);

  font-weight: 700;
}


/* ==========================================================================
   Old success block
   ========================================================================== */

.success {
  display: none;

  max-width: 720px;

  margin: 38px auto;
  padding: 44px;

  border: 1px solid var(--line);
  border-radius: 18px;

  background: #fff;

  text-align: center;

  box-shadow: var(--shadow);
}

.success.show {
  display: block;
}

.success i {
  width: 68px;
  height: 68px;

  margin: auto;

  display: grid;
  place-items: center;

  border-radius: 50%;

  background: var(--gs);
  color: var(--gd);

  font-style: normal;
  font-size: 34px;
  font-weight: 800;
}

.success h2 {
  margin: 18px 0 7px;

  font-size: 28px;
}

.success p {
  color: var(--mut);
}

.success .number {
  display: inline-block;

  padding: 8px 12px;

  border-radius: 9px;

  background: var(--cream);

  font-weight: 800;
}

.success a {
  height: 48px;

  margin-top: 20px;
  padding: 0 22px;

  display: inline-grid;
  place-items: center;

  border-radius: 10px;

  background: var(--r);
  color: #fff;

  text-decoration: none;

  font-weight: 800;
}


/* ==========================================================================
   Mobile submit position
   ========================================================================== */

.mobile-order-submit {
  display: none;
}


/* ==========================================================================
   Tablet
   ========================================================================== */

@media (max-width: 900px) {

  .wrap {
    width: calc(100% - 32px);
  }


  .layout {
    grid-template-columns: 1fr;
  }


  .summary {
    position: static;

    order: -1;

    display: grid;

    grid-template-columns:
      minmax(0, 1fr)
      280px;

    gap: 0 24px;
  }


  /*
   * ВАЖНО:
   * .item находится внутри .cart-items,
   * поэтому grid-column задаём именно cart-items.
   */
  .summary-head,
  .cart-items,
  .total-lines {
    grid-column: 1;
  }


  .summary .submit,
  .summary .consent,
  .summary .help {
    grid-column: 2;
  }


  .summary .submit {
    grid-row: 1;

    margin: 0;
  }


  .summary .consent {
    grid-row: 2;
  }


  .summary .help {
    grid-row: 3;
  }


  .fields {
    gap: 14px;
  }

}


/* ==========================================================================
   Mobile
   ========================================================================== */

@media (max-width: 620px) {

  html,
  body {
    font-size: 15px;
  }


  #msOrder {
    margin-top: 0 !important;
  }


  .secure span {
    display: none;
  }


  .page {
    padding: 16px 0 35px;
  }


  .title-row {
    display: block;

    margin-bottom: 17px;
  }

  .title-row h1 {
    font-size: 28px;
  }

  .title-row span {
    display: block;

    margin-top: 5px;
  }


  .layout {
    gap: 15px;
  }


  /*
   * На телефоне summary снова обычный блок.
   */
  .summary {
    display: block;

    padding: 17px;

    border-radius: 14px;
  }


  .form-card {
    padding: 18px 16px;

    border-radius: 14px;
  }


  .fields {
    grid-template-columns: 1fr;
  }


  .field.full {
    grid-column: auto;
  }


  .section-head h2 {
    font-size: 19px;
  }


  .section-divider {
    margin: 23px 0;
  }


  /* ------------------------------------------------------------------------
     Mobile cart product
     ------------------------------------------------------------------------ */

  .item {
    grid-template-columns:
      58px
      minmax(0, 1fr)
      auto;

    gap: 9px;

    align-items: center;

    padding: 12px 0;
  }


  .item-image {
      width: 58px;
      height: 58px;
    
      grid-column: 1;
      grid-row: 1 / span 2;
    }



  .item-info {
    grid-column: 2;
    grid-row: 1 / span 2;
  }


  .item-title {
      font-size: 12px;
    }


  .item-meta {
    gap: 5px 7px;

    margin-top: 6px;
  }


  .item-meta small {
    font-size: 9px;
  }


  /*
   * Цена справа сверху.
   */
  .item-cost {
    grid-column: 3;
    grid-row: 1;

    align-self: end;

    font-size: 12px;
  }


  /*
   * Удаление справа снизу.
   */
  .item-remove {
    grid-column: 3;
    grid-row: 2;

    align-self: start;
  }


  .item-remove button {
    width: 22px;
    height: 24px;

    margin-left: auto;

    font-size: 15px;
  }


  /* Quantity */

  .cart-qty {
    height: 28px;

    grid-template-columns:
      25px
      30px
      25px;
  }


  .cart-qty__btn {
    width: 25px;
    height: 26px;

    font-size: 15px;
  }


  .cart-qty__input {
    width: 30px;
    height: 26px;

    font-size: 10px;
    line-height: 26px;
  }


  /* Totals */

  .total-line.grand b {
    font-size: 24px;
  }


  /* Submit */

  .submit {
    height: 52px;
  }


  /*
   * Кнопка submitOrder физически переносится сюда
   * JS-ом на мобильной версии.
   */
  .mobile-order-submit {
    display: block;

    margin-top: 24px;
    padding-top: 20px;

    border-top: 1px solid var(--line);
  }


  .mobile-order-submit .submit {
    width: 100%;

    margin: 0;
  }


  /* Old success */

  .success {
    margin: 18px auto;
    padding: 30px 18px;
  }


  .success h2 {
    font-size: 24px;
  }

}


/* ==========================================================================
   Delivery methods
   ========================================================================== */

.delivery-options {
  display: grid;

  grid-template-columns: 1fr;

  gap: 10px;

  margin-bottom: 20px;
}


.delivery-option {
  min-height: 68px;

  padding: 13px 15px;

  display: flex;
  align-items: center;

  gap: 12px;

  border: 1px solid var(--line);
  border-radius: 12px;

  background: #fff;

  cursor: pointer;

  transition:
    border-color .18s,
    box-shadow .18s,
    background .18s;
}


.delivery-option:hover {
  border-color: #cfd8bd;
}


.delivery-option.active {
  border-color: var(--g);

  background: var(--gs);

  box-shadow:
    0 0 0 3px #88be2115;
}


.delivery-option > input {
  position: absolute;

  opacity: 0;

  pointer-events: none;
}


.delivery-radio {
  position: relative;

  width: 20px;
  height: 20px;

  flex: 0 0 20px;

  border: 2px solid #cfc8c1;
  border-radius: 50%;

  background: #fff;
}


.delivery-option.active .delivery-radio {
  border-color: var(--g);
}


.delivery-option.active .delivery-radio::after {
  content: "";

  position: absolute;

  width: 10px;
  height: 10px;

  left: 3px;
  top: 3px;

  border-radius: 50%;

  background: var(--g);
}


.delivery-logo {
  width: 44px;
  height: 44px;

  flex: 0 0 44px;

  display: grid;
  place-items: center;
}


.delivery-logo img {
  display: block;

  max-width: 44px;
  max-height: 44px;

  object-fit: contain;
}


.delivery-content {
  min-width: 0;

  display: block;
}


.delivery-content b {
  display: block;

  font-size: 14px;
}


.delivery-content small {
  display: block;

  margin-top: 2px;

  color: var(--mut);

  font-size: 11px;
  line-height: 1.4;
}


.delivery-address {
  margin-top: 18px;
}


.order-comment {
  margin-top: 17px;
}


/*
 * JS скрывает ненужные поля
 * выбранного способа доставки.
 */
[data-delivery-field][hidden] {
  display: none !important;
}


/* ==========================================================================
   Delivery mobile
   ========================================================================== */

@media (max-width: 620px) {

  .delivery-option {
    min-height: 62px;

    padding: 12px;
  }


  .delivery-logo {
    width: 38px;
    height: 38px;

    flex-basis: 38px;
  }


  .delivery-logo img {
    max-width: 38px;
    max-height: 38px;
  }

}


/* ==========================================================================
   Order success
   ========================================================================== */

.order-success {
  width: min(760px, 100%);

  margin: 45px auto 70px;
  padding: 45px;

  border: 1px solid var(--line);
  border-radius: 20px;

  background: var(--paper);

  box-shadow:
    0 20px 60px rgba(28, 27, 26, .08);
}


.order-success__icon {
  width: 54px;
  height: 54px;

  display: flex;
  align-items: center;
  justify-content: center;

  margin-bottom: 18px;

  border-radius: 15px;

  background: var(--green-soft);
  color: var(--green-dark);

  font-size: 25px;
  font-weight: 800;
}


.order-success__kicker {
  display: inline-flex;

  padding: 6px 10px;

  border-radius: 20px;

  background: var(--red-soft);
  color: var(--red);

  font-size: 10px;
  line-height: 1;
  font-weight: 800;
}


.order-success h1 {
  margin: 15px 0 9px;

  color: var(--ink);

  font-size: 34px;
  line-height: 1.15;
  letter-spacing: -.035em;
}


.order-success__lead {
  max-width: 600px;

  margin: 0 0 30px;

  color: var(--muted);

  font-size: 14px;
  line-height: 1.65;
}


.order-success__lead strong {
  color: var(--ink);
}


/* Data */

.order-success__grid {
  display: grid;

  grid-template-columns:
    minmax(0, 1fr)
    230px;

  gap: 15px;
}


.order-success__card {
  padding: 20px;

  border: 1px solid var(--line);
  border-radius: 13px;

  background: var(--soft);
}


.order-success__card h2 {
  margin: 0 0 12px;

  font-size: 16px;
}


.order-success__rows {
  display: grid;
}


.order-success__rows > div {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;

  gap: 20px;

  padding: 9px 0;

  border-bottom: 1px solid var(--line);
}


.order-success__rows > div:last-child {
  border-bottom: 0;
}


.order-success__rows span {
  color: var(--muted);

  font-size: 10px;
}


.order-success__rows strong {
  max-width: 60%;

  color: var(--ink);

  font-size: 11px;
  line-height: 1.45;

  text-align: right;
}


/* Total */

.order-success__total {
  display: flex;
  flex-direction: column;
  justify-content: center;

  padding: 22px;

  border: 1px solid rgba(161, 217, 39, .4);
  border-radius: 13px;

  background: var(--green-soft);
}


.order-success__total > span {
  margin-bottom: 5px;

  color: var(--green-dark);

  font-size: 10px;
  font-weight: 700;
}


.order-success__total > strong {
  color: var(--ink);

  font-size: 27px;
  line-height: 1.2;
}


.order-success__total small {
  margin-top: 8px;

  color: var(--muted);

  font-size: 9px;
  line-height: 1.5;
}


/* Notice */

.order-success__notice {
  display: flex;
  align-items: flex-start;

  gap: 13px;

  margin-top: 15px;
  padding: 17px;

  border: 1px solid #f0e4cc;
  border-radius: 12px;

  background: #fffaf1;
}


.order-success__notice > span {
  width: 35px;
  height: 35px;

  flex: 0 0 35px;

  display: flex;
  align-items: center;
  justify-content: center;

  border-radius: 9px;

  background: var(--red-soft);
}


.order-success__notice strong {
  display: block;

  margin-bottom: 3px;

  font-size: 11px;
}


.order-success__notice p {
  margin: 0;

  color: var(--muted);

  font-size: 10px;
  line-height: 1.55;
}


/* Actions */

.order-success__actions {
  display: flex;
  align-items: center;

  gap: 12px;

  margin-top: 24px;
}


.order-success__actions a {
  min-height: 46px;

  padding: 0 18px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  border-radius: 9px;

  font-size: 11px;
  font-weight: 800;

  text-decoration: none;
}


.order-success__catalog {
  gap: 9px;

  background: var(--red);
  color: #fff;
}


.order-success__catalog:hover {
  background: var(--red-dark);
}


.order-success__cabinet {
  border: 1px solid var(--line);

  background: var(--paper);
  color: var(--ink);
}


/* ==========================================================================
   Order success mobile
   ========================================================================== */

@media (max-width: 650px) {

  .order-success {
    margin: 20px auto 45px;
    padding: 24px 18px;

    border-radius: 15px;
  }


  .order-success h1 {
    font-size: 27px;
  }


  .order-success__grid {
    display: block;
  }


  .order-success__total {
    margin-top: 12px;
  }


  .order-success__rows > div {
    gap: 12px;
  }


  .order-success__rows strong {
    max-width: 55%;
  }


  .order-success__actions {
    display: grid;
  }


  .order-success__actions a {
    width: 100%;
  }

}


/* ==========================================================================
   Reduced motion
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {

  * {
    transition: none !important;
  }

}

/* ==========================================================================
   Responsive fixes
   ========================================================================== */

.layout,
.form-card,
.summary,
.fields,
.field,
.cart-items,
.item,
.item-info,
.delivery-option,
.delivery-content,
.order-success,
.order-success__card,
.order-success__rows,
.order-success__rows > div {
  min-width: 0;
}

.field input,
.field textarea,
.field select {
  max-width: 100%;
}

.item-title,
.delivery-content b,
.delivery-content small,
.order-success__rows strong {
  overflow-wrap: anywhere;
  word-break: break-word;
}

@media (max-width: 1100px) {
  .layout {
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 22px;
  }

  .summary {
    padding: 20px;
  }

  .item {
    grid-template-columns: 64px minmax(0, 1fr) auto 24px;
    gap: 10px;
  }

  .item-image {
    width: 64px;
    height: 64px;
  }
}

@media (max-width: 900px) {
  .page {
    overflow-x: hidden;
  }

  .layout {
    display: flex;
    flex-direction: column;
    width: 100%;
  }

  .form-card,
  .summary {
    width: 100%;
  }

  .summary {
    order: -1;
    grid-template-columns: minmax(0, 1fr) 240px;
    gap: 0 20px;
  }

  .summary .submit,
  .summary .consent,
  .summary .help {
    min-width: 0;
  }

  .total-line {
    gap: 12px;
  }
}

@media (max-width: 760px) {
  .summary {
    display: block;
  }

  .summary .submit {
    margin-top: 20px;
  }

  .fields {
    grid-template-columns: 1fr;
  }

  .field.full {
    grid-column: auto;
  }

  .title-row {
    align-items: flex-start;
  }

  .section-head,
  .section-head > div {
    min-width: 0;
  }

  .delivery-option {
    width: 100%;
  }
}

@media (max-width: 620px) {
  .wrap {
    width: calc(100% - 24px);
  }

  .page {
    padding: 12px 0 28px;
  }

  .back {
    margin-bottom: 9px;
  }

  .title-row {
    margin-bottom: 14px;
  }

  .title-row h1 {
    font-size: 25px;
    line-height: 1.2;
  }

  .title-row span {
    font-size: 12px;
    line-height: 1.4;
  }

  .form-card,
  .summary {
    width: 100%;
    max-width: 100%;
  }

  .form-card {
    padding: 16px 12px;
  }

  .summary {
    padding: 14px 12px;
  }

  .summary-head {
    gap: 10px;
    margin-bottom: 12px;
  }

  .summary h2 {
    font-size: 18px;
  }

  .summary-head a {
    flex: 0 0 auto;
  }

  .section-head {
    gap: 10px;
    margin-bottom: 16px;
  }

  .section-head i {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
  }

  .section-head h2 {
    font-size: 18px;
    line-height: 1.25;
  }

  .section-head p {
    font-size: 11px;
    line-height: 1.45;
  }

  .fields {
    gap: 12px;
  }

  .field {
    gap: 6px;
  }

  .field label {
    font-size: 12px;
  }

  .field input {
    height: 46px;
    padding: 0 11px;
  }

  .field textarea {
    min-height: 86px;
    padding: 11px;
  }

  .section-divider {
    margin: 20px 0;
  }

  .item {
    grid-template-columns: 52px minmax(0, 1fr) auto;
    column-gap: 8px;
    row-gap: 5px;
    padding: 11px 0;
  }

  .item-image {
    width: 52px;
    height: 52px;
  }

  .item-title {
    font-size: 11px;
    line-height: 1.3;
  }

  .item-title-small {
    font-size: 9px;
  }

  .item-meta {
    gap: 4px 6px;
    margin-top: 5px;
  }

  .item-meta small {
    font-size: 8px;
    white-space: normal;
  }

  .item-cost {
    max-width: 92px;
    font-size: 11px;
    line-height: 1.25;
    text-align: right;
    white-space: normal;
  }

  .item-remove {
    justify-content: flex-end;
  }

  .cart-qty {
    margin-top: 6px;
  }

  .total-lines {
    padding-top: 11px;
  }

  .total-line {
    gap: 10px;
    font-size: 12px;
  }

  .total-line.grand {
    margin-top: 13px;
  }

  .total-line.grand b {
    font-size: 22px;
  }

  .submit {
    height: 50px;
    margin-top: 16px;
  }

  .consent {
    font-size: 9px;
  }

  .help {
    font-size: 10px;
  }

  .delivery-options {
    gap: 8px;
    margin-bottom: 16px;
  }

  .delivery-option {
    min-height: 58px;
    padding: 10px;
    gap: 9px;
  }

  .delivery-radio {
    width: 18px;
    height: 18px;
    flex-basis: 18px;
  }

  .delivery-option.active .delivery-radio::after {
    width: 8px;
    height: 8px;
    left: 3px;
    top: 3px;
  }

  .delivery-logo {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
  }

  .delivery-logo img {
    max-width: 34px;
    max-height: 34px;
  }

  .delivery-content b {
    font-size: 13px;
    line-height: 1.3;
  }

  .delivery-content small {
    font-size: 10px;
    line-height: 1.35;
  }

  .delivery-address {
    margin-top: 14px;
  }

  .order-comment {
    margin-top: 14px;
  }

  .payment-info,
  .delivery-note {
    padding: 12px;
    gap: 10px;
  }

  .payment-info i {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
  }

  .payment-info small,
  .delivery-note small {
    font-size: 11px;
  }

  .mobile-order-submit {
    margin-top: 20px;
    padding-top: 16px;
  }

  .order-success {
    width: 100%;
    max-width: 100%;
    margin: 14px auto 35px;
    padding: 20px 14px;
  }

  .order-success h1 {
    font-size: 25px;
  }

  .order-success__lead {
    margin-bottom: 22px;
    font-size: 12px;
  }

  .order-success__card {
    padding: 15px;
  }

  .order-success__rows > div {
    display: grid;
    grid-template-columns: 90px minmax(0, 1fr);
    gap: 10px;
  }

  .order-success__rows strong {
    max-width: none;
    text-align: right;
  }

  .order-success__total {
    padding: 17px;
  }

  .order-success__total > strong {
    font-size: 24px;
  }

  .order-success__notice {
    padding: 13px;
  }

  .order-success__actions {
    gap: 9px;
    margin-top: 18px;
  }
}

@media (max-width: 420px) {
  .wrap {
    width: calc(100% - 18px);
  }

  .form-card {
    padding: 14px 10px;
  }

  .summary {
    padding: 13px 10px;
  }

  .title-row h1 {
    font-size: 23px;
  }

  .section-head i {
    width: 30px;
    height: 30px;
    flex-basis: 30px;
    font-size: 13px;
  }

  .section-head h2 {
    font-size: 17px;
  }

  .field input {
    height: 44px;
  }

  .item {
    grid-template-columns: 48px minmax(0, 1fr) 70px;
  }

  .item-image {
    width: 48px;
    height: 48px;
  }

  .item-cost {
    max-width: 70px;
    font-size: 10px;
  }

  .cart-qty {
    grid-template-columns: 24px 28px 24px;
  }

  .cart-qty__btn {
    width: 24px;
  }

  .cart-qty__input {
    width: 28px;
  }

  .delivery-option {
    align-items: flex-start;
  }

  .delivery-radio {
    margin-top: 2px;
  }

  .total-line.grand b {
    font-size: 20px;
  }

  .order-success__rows > div {
    grid-template-columns: 76px minmax(0, 1fr);
  }

  .order-success__actions a {
    min-height: 44px;
    padding: 0 12px;
  }
}

