.ch-cart { --mc-w: 460px; --mc-pad: 20px; --mc-speed: .4s; --mc-dim: color-mix(in srgb, var(--ch-paper) 65%, var(--ch-ink)); --mc-off: color-mix(in srgb, var(--ch-paper) 18%, var(--ch-ink)); position: fixed; inset: 0; z-index: 999999; font-family: var(--ch-font); color: var(--ch-ink); font-size: 14px; line-height: 1.5; }
.ch-cart[hidden] { display: none; }
html.ch-cart-lock, html.ch-cart-lock body { overflow: hidden; }
.ch-cart__overlay { position: absolute; inset: 0; background: color-mix(in srgb, var(--ch-ink) 50%, transparent); opacity: 0; transition: opacity var(--mc-speed) ease-out; cursor: pointer; }
.ch-cart.is-open .ch-cart__overlay { opacity: 1; }
.ch-cart__panel { position: absolute; top: 0; right: 0; bottom: 0; width: 100%; max-width: var(--mc-w); background: var(--ch-paper); box-shadow: -24px 0 48px color-mix(in srgb, var(--ch-ink) 18%, transparent); transform: translateX(100%); transition: transform var(--mc-speed) ease-out; outline: 0; }
.ch-cart.is-open .ch-cart__panel { transform: none; }
@media (prefers-reduced-motion: reduce) { .ch-cart__overlay, .ch-cart__panel { transition: none; } }

.ch-mc { display: flex; flex-direction: column; height: 100%; }
.ch-mc.is-busy .ch-mc__scroll, .ch-mc.is-busy .ch-mc__foot, .ch-mc.is-busy .ch-mc__offer { opacity: .55; pointer-events: none; transition: opacity .15s; }
.ch-mc a { color: inherit; }
.ch-mc ul, .ch-mc ol { list-style: none; margin: 0; padding: 0; }
.ch-mc button { min-height: 0; margin: 0; box-shadow: none; text-transform: none; letter-spacing: 0; font-family: inherit; }
.ch-mc .ch-mc__i { display: block; flex: none; }
.ch-mc .amount, .ch-mc__price, .ch-mc__sum span:last-child, .ch-mc__count, .ch-mc__spec, .ch-mc__offer-steps, .ch-mc__qty input { font-variant-numeric: tabular-nums; }

.ch-mc__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px var(--mc-pad) 14px; border-bottom: 1px solid var(--ch-line); }
.ch-mc__title { display: block; margin: 0; font-size: 20px; font-weight: var(--ch-w-display); font-stretch: 108%; line-height: 1.2; color: var(--ch-ink); }
.ch-mc__count { font-size: 14px; font-weight: var(--ch-w-medium); font-stretch: 100%; color: var(--ch-text-2); }
.ch-mc__close { flex: none; display: grid; place-items: center; width: var(--ch-target); height: var(--ch-target); padding: 0; border: 0; border-radius: var(--ch-radius-pill); background: var(--ch-ground); color: var(--ch-ink); cursor: pointer; }
.ch-mc__close:hover { background: var(--ch-line-2); color: var(--ch-ink); }

.ch-mc__bar { padding: 10px var(--mc-pad); border-bottom: 1px solid var(--ch-line); text-align: center; }
.ch-mc__bar-text { display: block; margin: 0 0 6px; font-size: var(--ch-fs-xs); color: var(--ch-text-2); }
.ch-mc__bar-track { height: 4px; border-radius: var(--ch-radius-pill); background: var(--ch-line); overflow: hidden; }
.ch-mc__bar-track span { display: block; height: 100%; background: var(--ch-ink); }
.ch-mc__bar.is-done .ch-mc__bar-track span { background: var(--ch-save); }

.ch-mc__offer { display: flex; flex-direction: column; gap: 10px; padding: 14px var(--mc-pad); background: var(--ch-ink); color: var(--ch-paper); }
.ch-mc__offer-tag { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: var(--ch-fs-xs); line-height: 1.3; color: var(--mc-dim); }
.ch-mc__offer-name { display: inline-flex; align-items: center; min-height: 20px; padding: 0 8px; border-radius: var(--ch-radius-pill); background: var(--ch-paper); color: var(--ch-ink); font-weight: var(--ch-w-display); letter-spacing: .06em; text-transform: uppercase; }
.ch-mc__offer-text { font-size: 14px; line-height: 1.45; }
.ch-mc__offer-text b { font-weight: var(--ch-w-bold); }
.ch-mc__offer-hi { color: var(--ch-accent-dark); }
.ch-mc__offer-bar { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; }
.ch-mc__offer-bar span { height: 4px; border-radius: var(--ch-radius-pill); background: var(--mc-off); }
.ch-mc__offer-bar span.is-done { background: var(--ch-accent-dark); }
.ch-mc__offer-steps { display: flex; justify-content: space-between; gap: 8px; font-size: 11px; line-height: 1.3; color: var(--mc-dim); }
.ch-mc__offer-steps li:last-child { text-align: right; }
.ch-mc__offer-steps li.is-done, .ch-mc__offer-steps li.is-now { color: var(--ch-accent-dark); }

.ch-mc__scroll { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 4px var(--mc-pad) 16px; }
.ch-mc__line { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--ch-line); }
.ch-mc__thumb img { display: block; width: 76px; height: 76px; margin: 0; border-radius: 12px; object-fit: cover; background: var(--ch-mist); }
.ch-mc__info { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ch-mc__top { display: flex; justify-content: space-between; gap: 10px; }
.ch-mc__name { font-size: 14.5px; font-weight: var(--ch-w-bold); line-height: 1.3; text-decoration: none; color: var(--ch-ink); }
.ch-mc a.ch-mc__name:hover { text-decoration: underline; text-underline-offset: 3px; }
.ch-mc__price { display: flex; flex-direction: column; align-items: flex-end; flex: none; font-size: 14.5px; font-weight: var(--ch-w-bold); line-height: 1.3; white-space: nowrap; }
.ch-mc__was { font-size: var(--ch-fs-xs); font-weight: var(--ch-w-regular); color: var(--ch-text-2); }
.ch-mc__spec { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 11px; line-height: 1.5; color: var(--ch-text-2); }
.ch-mc .ch-mc__all summary { display: inline-flex; align-items: center; min-height: var(--ch-target); margin: -12px 0; list-style: none; cursor: pointer; font-size: 12.5px; color: var(--ch-text-2); text-decoration: underline; text-underline-offset: 3px; }
.ch-mc__all summary::-webkit-details-marker { display: none; }
.ch-mc__all-text { display: block; padding-top: 6px; font-size: var(--ch-fs-xs); line-height: 1.6; color: var(--ch-text-2); }
.ch-mc__row { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 4px; }
.ch-mc__qty { display: inline-flex; align-items: center; height: 36px; border: 1px solid var(--ch-line-2); border-radius: var(--ch-radius-pill); }
.ch-mc__qty button { position: relative; display: grid; place-items: center; width: 36px; height: 34px; padding: 0; border: 0; border-radius: var(--ch-radius-pill); background: none; color: var(--ch-ink); cursor: pointer; }
.ch-mc__qty button::before { content: ""; position: absolute; inset: -5px -4px; }
.ch-mc__qty button:hover { background: var(--ch-mist); color: var(--ch-ink); }
.ch-mc__qty button:disabled { opacity: .35; cursor: default; }
.ch-mc .ch-mc__qty input { width: 28px; height: 34px; min-height: 0; padding: 0; border: 0; background: none; box-shadow: none; text-align: center; font-size: var(--ch-fs-s); color: var(--ch-ink); -moz-appearance: textfield; }
.ch-mc__qty input::-webkit-outer-spin-button, .ch-mc__qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.ch-mc__qty-fixed { font-size: var(--ch-fs-s); color: var(--ch-text-2); }
.ch-mc .ch-mc__remove { display: inline-flex; align-items: center; min-height: var(--ch-target); margin: -4px 0; padding: 0 2px; border: 0; background: none; color: var(--ch-text-2); font-size: 12.5px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ch-mc__remove:hover { background: none; color: var(--ch-ink); }
.ch-offered { display: inline-flex; flex-direction: row-reverse; align-items: baseline; gap: 6px; white-space: nowrap; }
.ch-offered del { font-size: var(--ch-fs-xs); font-weight: var(--ch-w-regular); color: var(--ch-text-2); }
.ch-offered__label { font-weight: var(--ch-w-bold); color: var(--ch-save); }

.ch-mc__addon { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 12px; align-items: center; margin-top: 16px; padding: 12px; border-radius: 12px; background: var(--ch-mist); }
.ch-mc__addon-img img { display: block; width: 48px; height: 48px; margin: 0; border-radius: 8px; object-fit: cover; background: var(--ch-paper); }
.ch-mc__addon-body { display: flex; flex-direction: column; min-width: 0; }
.ch-mc__addon-title { font-size: 14px; font-weight: var(--ch-w-bold); line-height: 1.35; text-decoration: none; color: var(--ch-ink); }
.ch-mc__addon-desc { font-size: var(--ch-fs-xs); line-height: 1.45; color: var(--ch-text-2); }
.ch-mc__addon-side { position: relative; display: flex; align-items: center; gap: 10px; }
.ch-mc__addon-price { font-size: 14px; font-weight: var(--ch-w-bold); white-space: nowrap; }
.ch-mc__addon-input { position: absolute; right: 0; top: 50%; width: 44px; height: 44px; margin: -22px -2px 0 0; opacity: 0; cursor: pointer; z-index: 1; }
.ch-mc__switch { position: relative; display: block; width: 40px; height: 24px; margin: 0; border-radius: var(--ch-radius-pill); background: var(--ch-field); cursor: pointer; transition: background .2s; }
.ch-mc__switch::before { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--ch-paper); transition: transform .25s ease; }
.ch-mc__addon-input:checked + .ch-mc__switch { background: var(--ch-ink); }
.ch-mc__addon-input:checked + .ch-mc__switch::before { transform: translateX(16px); }
.ch-mc__addon-input:focus-visible + .ch-mc__switch { outline: var(--ch-focus-width) solid var(--ch-focus-color); outline-offset: 2px; }

.ch-mc__together { display: flex; flex-direction: column; gap: 12px; padding: 18px 0 6px; }
.ch-mc__together-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.ch-mc__together-h { font-size: var(--ch-fs-ui); font-weight: var(--ch-w-bold); }
.ch-mc__together-sub { font-size: var(--ch-fs-xs); font-weight: var(--ch-w-ui); color: var(--ch-save); }
.ch-mc__cards { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 20px) / 3); gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: thin; padding-bottom: 4px; }
.ch-mc__card { display: flex; flex-direction: column; min-width: 0; border: 1px solid var(--ch-line); border-radius: 12px; overflow: hidden; scroll-snap-align: start; }
.ch-mc__card-img { position: relative; display: block; }
.ch-mc__card-img img { display: block; width: 100%; height: auto; aspect-ratio: 1 / 1; margin: 0; object-fit: cover; }
.ch-mc__card-badge { position: absolute; left: 6px; top: 6px; padding: 2px 6px; border-radius: var(--ch-radius-pill); background: var(--ch-accent); color: var(--ch-paper); font-size: 10px; font-weight: var(--ch-w-ui); line-height: 1.4; font-variant-numeric: tabular-nums; }
.ch-mc__card-body { flex: 1; display: flex; flex-direction: column; gap: 4px; padding: 8px 9px 10px; }
.ch-mc__card-name { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: var(--ch-fs-xs); font-weight: 650; line-height: 1.3; text-decoration: none; color: var(--ch-ink); }
.ch-mc__card-price { font-size: 12.5px; }
.ch-mc__card-price del { font-size: 11px; color: var(--ch-text-2); }
.ch-mc__add { position: relative; display: flex; align-items: center; justify-content: center; height: 32px; margin-top: auto; padding: 0 8px; border: 1px solid var(--ch-ink); border-radius: var(--ch-radius-pill); background: var(--ch-paper); color: var(--ch-ink); font-size: var(--ch-fs-xs); font-weight: 650; text-decoration: none; cursor: pointer; }
.ch-mc__add::before { content: ""; position: absolute; inset: -6px -4px; }
.ch-mc .ch-mc__add:hover { background: var(--ch-ink); color: var(--ch-paper); }

.ch-mc__coupon { margin-top: 14px; border-top: 1px solid var(--ch-line); }
.ch-mc__coupon summary { display: flex; align-items: center; justify-content: space-between; min-height: 48px; list-style: none; cursor: pointer; font-size: 14px; font-weight: 650; }
.ch-mc__coupon summary::-webkit-details-marker { display: none; }
.ch-mc__coupon[open] summary .ch-mc__i { transform: rotate(45deg); }
.ch-mc__coupon-form { display: flex; gap: 8px; padding-bottom: 6px; }
.ch-mc .ch-mc__coupon-form input { flex: 1; min-width: 0; height: var(--ch-target); min-height: 0; padding: 0 12px; border: 1px solid var(--ch-field); border-radius: var(--ch-radius-s); background: var(--ch-paper); font-size: var(--ch-fs-body); box-shadow: none; }
.ch-mc .ch-mc__coupon-form button { height: var(--ch-target); padding: 0 18px; border: 0; border-radius: var(--ch-radius-s); background: var(--ch-ink); color: var(--ch-paper); font-size: 14px; font-weight: 650; cursor: pointer; }
.ch-mc .ch-mc__coupon-form button:hover { background: var(--ch-ink-hover); }
.ch-mc__coupon-msg { margin: 0 0 12px; font-size: var(--ch-fs-s); color: var(--ch-save); }
.ch-mc__coupon-msg:empty { display: none; }
.ch-mc__coupon-msg.is-error { color: var(--ch-ink); font-weight: var(--ch-w-ui); }

.ch-mc__foot { display: flex; flex-direction: column; gap: 8px; padding: 16px var(--mc-pad) 18px; border-top: 1px solid var(--ch-line); background: var(--ch-paper); }
.ch-mc__summary { display: flex; flex-direction: column; gap: 8px; }
.ch-mc__sum { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 14px; }
.ch-mc__sum--sub span:first-child { color: var(--ch-text-2); }
.ch-mc__sum--off { color: var(--ch-save); }
.ch-mc__sum--total { align-items: baseline; padding-top: 6px; border-top: 1px solid var(--ch-line); font-weight: var(--ch-w-bold); }
.ch-mc__sum--total span:first-child { font-size: var(--ch-fs-body); }
.ch-mc__sum--total span:last-child { font-size: var(--ch-fs-h3); }
.ch-mc__summary .ch-mc__sum:first-child.ch-mc__sum--total { padding-top: 0; border-top: 0; }
.ch-mc__chip { display: inline-flex; align-items: center; gap: 4px; margin-left: 4px; padding: 0 2px 0 8px; border-radius: var(--ch-radius-pill); background: var(--ch-mist); color: var(--ch-ink); font-size: var(--ch-fs-xs); text-transform: uppercase; }
.ch-mc__chip button { display: grid; place-items: center; width: 24px; height: 24px; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--ch-ink); cursor: pointer; }
.ch-mc__note { display: block; font-size: var(--ch-fs-xs); color: var(--ch-text-2); }
.ch-mc__btn { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 54px; margin-top: 4px; padding: 0 24px; border-radius: var(--ch-radius-pill); background: var(--ch-ink); color: var(--ch-paper) !important; font-size: var(--ch-fs-body); font-weight: var(--ch-w-h3); line-height: 1.2; text-decoration: none; transition: background .2s; }
.ch-mc__btn:hover { background: var(--ch-ink-hover); }
.ch-mc__btn-total { font-variant-numeric: tabular-nums; }
.ch-mc .ch-marks { justify-content: center; gap: 4px; }
.ch-mc .ch-marks__item img { width: 38px; height: auto; aspect-ratio: 42 / 27; }
.ch-mc .ch-mc__continue { align-self: center; display: inline-flex; align-items: center; min-height: var(--ch-target); margin: -4px 0 -8px; padding: 0 8px; border: 0; background: none; color: var(--ch-ink); font-size: 13.5px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ch-mc__continue:hover { background: none; color: var(--ch-text-2); }

.ch-mc__empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 24px var(--mc-pad); text-align: center; }
.ch-mc__empty .ch-mc__i { margin-bottom: 6px; color: var(--ch-text-2); }
.ch-mc__empty-title { font-size: var(--ch-fs-lead); font-weight: var(--ch-w-display); font-stretch: 108%; }
.ch-mc__empty-text { font-size: 14px; color: var(--ch-text-2); }
.ch-mc__empty .ch-mc__btn { margin-top: 12px; min-height: var(--ch-btn-h-s); font-size: var(--ch-fs-ui); }

@media (max-width: 599.98px) {
  .ch-cart { --mc-pad: 16px; }
  .ch-mc__head { padding: 10px 12px 10px var(--mc-pad); }
  .ch-mc__title { font-size: var(--ch-fs-lead); }
  .ch-mc__count { font-size: var(--ch-fs-s); }
  .ch-mc__offer { gap: 8px; padding: 12px var(--mc-pad); }
  .ch-mc__offer-text { font-size: var(--ch-fs-s); }
  .ch-mc__offer-steps { display: none; }
  .ch-mc__scroll { padding: 0 var(--mc-pad) 12px; }
  .ch-mc__line { grid-template-columns: 64px minmax(0, 1fr); gap: 12px; padding: 14px 0; }
  .ch-mc__thumb img { width: 64px; height: 64px; border-radius: var(--ch-radius-s); }
  .ch-mc__name, .ch-mc__price { font-size: 13.5px; }
  .ch-mc__spec { font-size: 10.5px; }
  .ch-mc__together-head { flex-direction: column; align-items: flex-start; gap: 2px; }
  .ch-mc__cards { grid-auto-columns: 132px; margin: 0 calc(-1 * var(--mc-pad)); padding: 0 var(--mc-pad) 4px; scroll-padding-inline: var(--mc-pad); }
  .ch-mc__foot { gap: 6px; padding: 12px var(--mc-pad) 16px; box-shadow: 0 -8px 24px color-mix(in srgb, var(--ch-ink) 6%, transparent); }
  .ch-mc__sum { font-size: var(--ch-fs-s); }
  .ch-mc__sum--total span:first-child { font-size: var(--ch-fs-ui); }
  .ch-mc__sum--total span:last-child { font-size: 20px; }
  .ch-mc__btn { min-height: var(--ch-btn-h); font-size: var(--ch-fs-ui); }
}
