/* mebledim: сторінки магазину (каталог, товар, конфігуратори, кошик, оформлення, оплата).
   Дизайн 1b «Світлий редакційний». Підключається в base.html після main.css.
   Усе, крім картки товару (.shop-card, вона є і на головній), живе всередині обгортки .shop. */

/* ---------- Токени (фолбеки; основні значення задає main.css на :root) ---------- */
:where(:root) {
  --bg: #F3EFE9;
  --ink: #1C1B1A;
  --mute: #5E574F;
  --acc: #A94F31;
  --line: #CFC7BB;
  --rule: #1C1B1A;
  --stripe: repeating-linear-gradient(135deg, #E5DED4 0 14px, #EBE5DC 14px 28px);
  --display: "Forum", Georgia, "Times New Roman", serif;
  --body: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
}

.shop {
  --shop-paper: #FAF8F4;        /* поля вводу, випадні списки */
  --shop-tint: #EBE5DC;         /* підкладка під фото */
  --shop-soft: #E9E3DA;         /* виділення вибраного варіанта */
  --shop-ok: #3D6B48;
  --shop-err: #A3322A;
  --shop-gap: 56px;
  /* старі змінні, на які спираються правила main.css і JS (повзунки стільців) */
  --accent: var(--acc);
  --accent-dark: var(--acc);
  --accent-light: var(--shop-soft);
  --radius: 0;
  --radius-sm: 0;
  --shadow: none;
  --shadow-sm: none;
  --surface: var(--shop-paper);
  --bg-alt: var(--shop-tint);
  --sand: var(--line);
  --ink-2: var(--mute);
  --ink-3: var(--mute);
  font-family: var(--body);
  color: var(--ink);
  padding: 0 0 96px;
}
.shop *, .shop *::before, .shop *::after { border-radius: 0; }
:where(.shop) a { color: inherit; }
.shop h1, .shop h2, .shop h3, .shop h4 { color: var(--ink); }
.shop [hidden] { display: none !important; }
.shop :focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }

/* ---------- Типографіка й дрібні елементи ---------- */
.shop-eyebrow {
  display: block; margin: 0 0 16px;
  font: 700 13px/1.35 var(--body); letter-spacing: .16em; text-transform: uppercase; color: var(--acc);
}
.shop-eyebrow a { color: inherit; }
.shop-eyebrow a:hover { color: var(--ink); }
.shop-title {
  margin: 0; font-family: var(--display); font-weight: 400;
  font-size: clamp(42px, 6.2vw, 84px); line-height: .96; letter-spacing: -.02em; overflow-wrap: anywhere;
}
.shop-h2 { margin: 0; font: 400 clamp(32px, 4vw, 52px)/1 var(--display); letter-spacing: -.01em; }
.shop-h3 { margin: 0 0 14px; font: 400 26px/1.15 var(--display); }
.shop-lead { margin: 0; font-size: 17px; line-height: 1.65; color: var(--mute); max-width: 640px; }
.shop-muted { color: var(--mute); }
.shop-note { font-size: 13px; line-height: 1.65; color: var(--mute); margin: 12px 0 0; }
.shop-link {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px;
  padding: 0; border: 0; background: none; cursor: pointer;
  font: 600 15px/1.2 var(--body); color: var(--ink);
}
.shop-link > span:first-child, .shop-link__text { border-bottom: 1px solid currentColor; padding-bottom: 3px; }
.shop-link:hover { color: var(--acc); }
.shop-link--acc { color: var(--acc); }
.shop-link--acc:hover { color: var(--ink); }
.shop-link[disabled] { opacity: .45; cursor: default; }

/* Кнопки: базові .btn від main.css, тут лише гарантія мови 1b на сторінках магазину */
.shop .btn { border-radius: 0; box-shadow: none; transform: none; letter-spacing: 0; }
.shop .btn--primary { background: var(--ink); border-color: var(--ink); color: var(--bg); font-weight: 700; }
.shop .btn--primary:hover, .shop .btn--primary:focus-visible { background: var(--acc); border-color: var(--acc); color: #fff; }
.shop .btn--outline { background: transparent; border: 1px solid var(--ink); color: var(--ink); font-weight: 700; }
.shop .btn--outline:hover { background: var(--ink); color: var(--bg); }
.shop .btn--lg { min-height: 56px; padding: 16px 30px; font-size: 16px; }
.shop .btn[disabled], .shop .btn[aria-disabled="true"] { opacity: .45; cursor: default; background: var(--ink); color: var(--bg); }

/* Поля форм у магазині */
.shop-form input[type="text"], .shop-form input[type="tel"], .shop-form input[type="email"],
.shop-form input[type="number"], .shop-form input[type="search"], .shop-form select, .shop-form textarea,
.shop .input, .shop .select, .shop-input {
  width: 100%; min-height: 48px; padding: 12px 14px;
  background: var(--shop-paper); border: 1px solid var(--line); border-radius: 0;
  font: 500 15px/1.4 var(--body); color: var(--ink); box-shadow: none; appearance: none; -webkit-appearance: none;
}
.shop-form select, .shop .select, .shop select.shop-input {
  padding-right: 40px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%231C1B1A' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.shop-form textarea, .shop textarea.input { min-height: 112px; resize: vertical; }
.shop-form input:focus, .shop-form select:focus, .shop-form textarea:focus, .shop .input:focus, .shop .select:focus, .shop-input:focus {
  outline: none; border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink);
}
.shop-form input::placeholder, .shop-form textarea::placeholder, .shop .input::placeholder { color: #8A8178; opacity: 1; }
.shop-form [aria-invalid="true"] { border-color: var(--shop-err); box-shadow: inset 0 0 0 1px var(--shop-err); }
.shop-form .form__row > label, .shop-label { display: block; margin: 0 0 8px; font: 600 14px/1.4 var(--body); color: var(--ink); }
.shop .form__row { margin: 0 0 20px; min-width: 0; }
.shop .form__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 20px; }
.shop .form__hint { margin: 8px 0 0; font-size: 13px; line-height: 1.6; color: var(--mute); }
.shop .form__error { margin: 8px 0 0; font-size: 14px; font-weight: 600; line-height: 1.5; color: var(--shop-err); }
.shop .form__error:empty { display: none; }
.shop .form__success { padding: 18px 20px; border-left: 3px solid var(--shop-ok); background: #E7EDE4; font-size: 15px; line-height: 1.6; }
.shop .alert { margin: 0 0 24px; padding: 16px 20px; border: 0; border-left: 3px solid var(--ink); background: var(--shop-tint); font-size: 15px; line-height: 1.6; border-radius: 0; }
.shop .alert--error { border-left-color: var(--shop-err); background: #F4E3DE; color: var(--ink); }
.shop .alert ul.errorlist { margin: 0; padding: 0; list-style: none; }
.shop-check { display: flex; align-items: flex-start; gap: 12px; min-height: 36px; padding: 6px 0; cursor: pointer; font-size: 15px; line-height: 1.45; }
.shop-check input { flex: none; width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--ink); cursor: pointer; }
.shop-check small { margin-left: auto; padding-left: 8px; font-size: 12px; color: var(--mute); }

/* ---------- Шапка сторінки ---------- */
.shop-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin: 0; padding: 28px 0 0; font-size: 13px; line-height: 1.5; color: var(--mute); }
.shop-crumbs a { color: var(--mute); border-bottom: 1px solid transparent; }
.shop-crumbs a:hover { color: var(--ink); border-bottom-color: var(--ink); }
.shop-crumbs span[aria-hidden] { color: var(--line); }
.shop-crumbs [aria-current] { color: var(--ink); }
.shop-head { padding: 48px 0 56px; }
.shop-head__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 32px 56px; align-items: end; }
.shop-head__side { display: grid; gap: 18px; justify-items: start; }
.shop-head__count { font-size: 15px; font-weight: 600; color: var(--mute); }
.shop-head--compact { padding: 40px 0 40px; }
.shop-head--compact .shop-title { font-size: clamp(40px, 5vw, 64px); }

.shop-rule { border: 0; border-top: 1px solid var(--rule); margin: 0; }
.shop-block { border-top: 1px solid var(--rule); padding: 56px 0 0; margin-top: 72px; }
.shop-block__head { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; margin: 0 0 32px; }

/* Нумерований список-індекс (підкатегорії, категорії) */
.shop-index { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 40px; border-top: 1px solid var(--rule); }
.shop-index--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.shop-index__link { display: flex; align-items: baseline; gap: 16px; min-height: 64px; padding: 16px 0; border-bottom: 1px solid var(--line); color: var(--ink); transition: color .15s, border-color .15s; }
.shop-index__link:hover, .shop-index__link:focus-visible { color: var(--acc); border-bottom-color: var(--acc); }
.shop-index__num { flex: none; width: 24px; font-size: 13px; font-weight: 600; color: var(--mute); }
.shop-index__name { flex: 1; min-width: 0; font: 400 24px/1.12 var(--display); overflow-wrap: anywhere; }
.shop-index__count { flex: none; font-size: 13px; color: var(--mute); }
.shop-index__arrow { flex: none; font-size: 18px; }
.shop-subcats { padding: 0 0 56px; }

/* ---------- Картка товару (каталог, головна, схожі товари) ---------- */
.shop-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px 24px; }
.shop-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.shop-card { position: relative; display: flex; flex-direction: column; min-width: 0; color: var(--ink); background: none; border: 0; border-radius: 0; box-shadow: none; }
.shop-card__media { position: relative; display: block; aspect-ratio: 11 / 12; overflow: hidden; background: #EBE5DC; }
/* фото товару завжди повністю в кадрі: широкі дивани й кутові не обрізаються */
.shop-card__media img { width: 100%; height: 100%; object-fit: contain; padding: 5%; mix-blend-mode: multiply; transition: transform .5s ease; }
.shop-card__media--contain img { object-fit: contain; padding: 6%; }
.shop-card__media--empty { background: var(--stripe); }
.shop-card__media--empty img { opacity: 0; }
.shop-card:hover .shop-card__media img { transform: scale(1.03); }
.shop-card__badges { position: absolute; left: 0; top: 0; display: flex; flex-wrap: wrap; gap: 0; z-index: 1; }
.shop-badge { display: inline-block; padding: 6px 10px; font: 700 11px/1.2 var(--body); letter-spacing: .12em; text-transform: uppercase; background: var(--ink); color: var(--bg); }
.shop-badge--hit { background: var(--acc); color: #fff; }
.shop-badge--sale { background: var(--bg); color: var(--acc); box-shadow: inset 0 0 0 1px var(--acc); }
.shop-card__cat { margin: 14px 0 6px; font: 700 12px/1.35 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); overflow-wrap: anywhere; }
.shop-card__title { margin: 0; min-height: 2.3em; font: 400 24px/1.15 var(--display); letter-spacing: 0; overflow-wrap: anywhere; }
.shop-card__title a { color: var(--ink); }
.shop-card__title a::after { content: ""; position: absolute; inset: 0; z-index: 0; }
.shop-card__title a:hover { color: var(--acc); }
.shop-card__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin: 10px 0 0; font-size: 13px; color: var(--mute); }
.shop-card__dots { display: inline-flex; gap: 5px; }
.shop-dot { display: inline-block; width: 12px; height: 12px; border-radius: 50% !important; box-shadow: inset 0 0 0 1px rgba(28, 27, 26, .25); }
.shop-card__foot { position: relative; z-index: 1; display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); }
.shop-card__body { display: flex; flex-direction: column; flex: 1; }
.shop-card__body > .shop-card__meta { margin-bottom: 16px; }
.shop-card__title + .shop-card__foot { margin-top: 16px; }
.shop-card__price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; min-width: 0; }
.shop-card__price strong { font: 700 18px/1.3 var(--body); white-space: nowrap; }
.shop-card__price s { font-size: 14px; color: var(--mute); white-space: nowrap; }
.shop-card__price--ask strong { font-size: 15px; }
.shop-card__buy { margin: 0; flex: none; }
.shop-card__action {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0; border: 0; background: none; cursor: pointer;
  font: 700 14px/1.2 var(--body); color: var(--acc); white-space: nowrap;
}
.shop-card__action:hover { color: var(--ink); }
.shop-card__action[aria-busy="true"], .shop-card__buy[aria-busy="true"] .shop-card__action { opacity: .55; }
.shop-card__note { margin: 8px 0 0; font-size: 12px; color: var(--mute); }

/* ---------- Каталог ---------- */
.shop-catalog__body { display: grid; grid-template-columns: 264px minmax(0, 1fr); gap: 0 48px; align-items: start; border-top: 1px solid var(--rule); }
.shop-catalog__body--full { grid-template-columns: minmax(0, 1fr); }
.shop-catalog__main { padding-top: 24px; min-width: 0; }
.shop-toolbar { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px 24px; padding: 0 0 20px; margin: 0 0 32px; border-bottom: 1px solid var(--line); }
.shop-toolbar__count { font-size: 15px; color: var(--mute); }
.shop-toolbar__count strong { color: var(--ink); }
.shop-toolbar__sort { display: flex; align-items: center; gap: 12px; margin: 0; }
.shop-toolbar__sort label { margin: 0; font-size: 14px; font-weight: 600; white-space: nowrap; }
.shop-toolbar__sort select { width: auto; min-width: 220px; min-height: 44px; }
.shop-filter-toggle { display: none; }
.shop-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: -12px 0 32px; }
.shop-chips:empty { display: none; }
.shop-chip { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 6px 12px; border: 1px solid var(--ink); font-size: 13px; font-weight: 600; color: var(--ink); background: none; }
.shop-chip:hover { background: var(--ink); color: var(--bg); }
.shop-chip--reset { border-color: transparent; text-decoration: underline; text-underline-offset: 4px; }
.shop-chip--reset:hover { background: none; color: var(--acc); }

/* Фільтри */
.shop-filters { padding: 24px 0 0; min-width: 0; }
.shop-filters__head { display: none; }
.shop-filters__title { margin: 0 0 8px; font: 400 28px/1.1 var(--display); }
.shop-filters form { margin: 0; }
.shop .shop-fgroup { margin: 0; padding: 18px 0; border: 0; border-bottom: 1px solid var(--line); min-width: 0; }
.shop .shop-fgroup:first-of-type { padding-top: 8px; }
.shop .shop-fgroup > legend, .shop .shop-fgroup__title, .shop .shop-fgroup > summary {
  display: block; width: 100%; padding: 0; margin: 0 0 12px;
  font: 700 12px/1.4 var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--ink);
}
.shop .shop-fgroup > legend { float: left; }
.shop-fgroup > legend + *, .shop-fgroup > summary + * { clear: both; }
details.shop-fgroup > summary { float: none; position: relative; margin: 0; padding: 4px 28px 4px 0; cursor: pointer; list-style: none; min-height: 28px; }
details.shop-fgroup > summary::-webkit-details-marker { display: none; }
details.shop-fgroup > summary::after { content: "+"; position: absolute; right: 0; top: 0; font: 400 20px/1 var(--body); letter-spacing: 0; }
details.shop-fgroup[open] > summary::after { content: "–"; }
details.shop-fgroup[open] > summary { margin-bottom: 10px; }
.shop-fgroup__options { display: grid; gap: 0; max-height: 300px; overflow: auto; overscroll-behavior: contain; }
.shop-range { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 8px; align-items: center; }
.shop-range--apply { grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto; }
.shop-range .shop-input { min-height: 44px; padding: 10px 10px; font-size: 14px; -moz-appearance: textfield; }
.shop-range__apply { min-width: 44px; min-height: 44px; border: 1px solid var(--ink); background: none; font: 700 12px/1 var(--body); cursor: pointer; }
.shop-range__apply:hover { background: var(--ink); color: var(--bg); }
.shop-filters__actions { display: grid; gap: 4px; padding: 24px 0 8px; }
.shop-filters__actions .btn { width: 100%; }
.shop-filters__actions .shop-link { justify-content: center; }
.shop-selected { display: flex; flex-wrap: wrap; gap: 8px; padding: 8px 0 18px; border-bottom: 1px solid var(--line); }
.shop-selected strong { flex-basis: 100%; font: 700 12px/1.4 var(--body); letter-spacing: .14em; text-transform: uppercase; }
.shop-selected a { display: inline-flex; gap: 6px; padding: 6px 10px; border: 1px solid var(--ink); font-size: 13px; line-height: 1.3; }
.shop-selected a:hover { background: var(--ink); color: var(--bg); }
.shop-selected a.shop-selected__reset { border-color: transparent; text-decoration: underline; padding-left: 0; }
.shop-selected a.shop-selected__reset:hover { background: none; color: var(--acc); }

/* Повзунки діапазонів (шафи-купе, стільці) */
.shop-slider, .chair-range__sliders { position: relative; height: 2px; margin: 22px 8px 10px; background: var(--line); }
.shop-slider input, .chair-range__sliders input {
  position: absolute; left: -8px; top: -9px; width: calc(100% + 16px); height: 20px; margin: 0;
  background: none; pointer-events: none; -webkit-appearance: none; appearance: none;
}
.shop-slider input::-webkit-slider-thumb, .chair-range__sliders input::-webkit-slider-thumb {
  -webkit-appearance: none; width: 18px; height: 18px; border-radius: 50%; background: var(--bg); border: 2px solid var(--ink); pointer-events: auto; cursor: pointer;
}
.shop-slider input::-moz-range-thumb, .chair-range__sliders input::-moz-range-thumb {
  width: 14px; height: 14px; border-radius: 50%; background: var(--bg); border: 2px solid var(--ink); pointer-events: auto; cursor: pointer;
}
.shop-slider input::-webkit-slider-runnable-track, .chair-range__sliders input::-webkit-slider-runnable-track { background: none; }
.shop-slider__labels { display: flex; justify-content: space-between; font-size: 12px; color: var(--mute); }

/* Плитки шаф-купе */
.shop-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.shop-tile { position: relative; display: block; cursor: pointer; }
.shop-tile input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.shop-tile span { display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px; border: 1px solid var(--line); font-size: 13px; font-weight: 600; text-align: center; line-height: 1.3; }
.shop-tile:hover span { border-color: var(--ink); }
.shop-tile input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.shop-tile input:focus-visible + span { outline: 2px solid var(--acc); outline-offset: 2px; }
.shop-fgroup__options--compact { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 12px; }

.shop-facet-search { min-height: 40px !important; margin: 0 0 8px; font-size: 14px !important; }
.shop-facet-more { min-height: 40px; padding: 0; border: 0; background: none; font: 600 13px/1.3 var(--body); color: var(--acc); text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }

/* Пагінація */
.shop-pager { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 4px; margin: 64px 0 0; padding-top: 24px; border-top: 1px solid var(--line); }
.shop-pager a, .shop-pager span { display: inline-grid; place-items: center; min-width: 44px; height: 44px; padding: 0 10px; font-size: 15px; font-weight: 600; color: var(--ink); }
.shop-pager a:hover { color: var(--acc); }
.shop-pager [aria-current] { background: var(--ink); color: var(--bg); }
.shop-pager__gap { color: var(--mute) !important; }
.shop-pager__step { font-size: 18px !important; }

/* Порожній стан */
.shop-empty { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 32px 56px; padding: 56px 0; border-top: 1px solid var(--rule); }
.shop-empty p { margin: 0 0 24px; font-size: 17px; line-height: 1.65; color: var(--mute); max-width: 520px; }
.shop-empty__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; }
.shop-catalog__main .shop-empty { grid-template-columns: 1fr; padding-top: 32px; border-top: 0; }

/* ---------- Сторінка товару ---------- */
.shop-product { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.shop-product__media { padding: 40px 48px 48px 0; border-right: 1px solid var(--rule); min-width: 0; }
.shop-product .product__info { grid-column: auto; grid-row: auto; position: static; padding: 40px 0 48px 48px; min-width: 0; }
.shop-gallery { position: sticky; top: 104px; outline: none; }
.shop-gallery .gallery__main { position: relative; aspect-ratio: 1 / 1; overflow: hidden; background: #EBE5DC; border: 0; border-radius: 0; }
.shop-gallery .gallery__main img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.shop-gallery--cover .gallery__main img { object-fit: cover; }
.shop-gallery .gallery__arrow {
  position: absolute; top: 50%; z-index: 2; width: 48px; height: 48px; margin-top: -24px; display: grid; place-items: center;
  border: 0; border-radius: 0; background: var(--bg); color: var(--ink); font-size: 26px; line-height: 1; cursor: pointer; box-shadow: none;
}
.shop-gallery .gallery__arrow:hover { background: var(--ink); color: var(--bg); }
.shop-gallery .gallery__arrow--prev { left: 0; }
.shop-gallery .gallery__arrow--next { right: 0; }
.shop-gallery .shop-card__badges { z-index: 1; }
.shop-thumbs { display: flex; gap: 8px; margin: 12px 0 0; padding: 0 0 4px; overflow-x: auto; scrollbar-width: thin; }
.shop-thumbs .gallery__thumb { flex: 0 0 84px; width: 84px; height: 84px; opacity: 1; padding: 0; border: 1px solid transparent; background: #EBE5DC; cursor: pointer; border-radius: 0; overflow: hidden; }
.shop-thumbs .gallery__thumb img { width: 100%; height: 100%; object-fit: cover; mix-blend-mode: multiply; }
.shop-gallery--contain .shop-thumbs .gallery__thumb img { object-fit: contain; }
.shop-thumbs .gallery__thumb:hover { border-color: var(--line); }
.shop-thumbs .gallery__thumb.is-active { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.shop-gallery__note { margin: 16px 0 0; font-size: 13px; line-height: 1.65; color: var(--mute); max-width: 640px; }
.shop-gallery__more { margin: 16px 0 0; border-top: 1px solid var(--line); }
.shop-gallery__more summary { padding: 14px 0 6px; font-weight: 700; font-size: 14px; cursor: pointer; }

.shop-product .product__title { margin: 0 0 16px; font: 400 clamp(36px, 3.6vw, 52px)/1.02 var(--display); letter-spacing: -.01em; overflow-wrap: anywhere; }
.shop-product__meta { display: flex; flex-wrap: wrap; gap: 6px 20px; margin: 0 0 28px; font-size: 13px; color: var(--mute); }
.shop-stock { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--ink); }
.shop-stock::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--shop-ok); }
.shop-stock--order::before { background: var(--acc); }
.shop-product .product__price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; padding: 20px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 0 0 24px; }
.shop-product .product__price .price__current { font: 400 44px/1 var(--display); letter-spacing: -.01em; color: var(--ink); }
.shop-product .product__price .price__old { font-size: 17px; color: var(--mute); text-decoration: line-through; }
.shop-product .product__price .shop-badge { align-self: center; }
.shop-product__lead { margin: 0 0 24px; font-size: 16px; line-height: 1.7; color: var(--mute); }
.shop-product__note { margin: -8px 0 24px; font-size: 13px; line-height: 1.6; color: var(--mute); }
.shop-option-label { margin: 0 0 10px; font-size: 14px; color: var(--mute); }
.shop-option-label strong { color: var(--ink); font-weight: 700; }

/* Кольорові варіанти */
.shop-variants { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; margin: 0 0 24px; }
.shop-variant { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 6px 4px 8px; border: 1px solid transparent; font-size: 11px; line-height: 1.3; text-align: center; color: var(--ink); min-width: 0; }
.shop-variant img { width: 100%; aspect-ratio: 1; height: auto; object-fit: cover; background: #EBE5DC; mix-blend-mode: multiply; }
.shop-variant span { overflow-wrap: anywhere; }
.shop-variant:hover { border-color: var(--line); }
.shop-variant.is-active { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.shop-variants--text { display: flex; flex-wrap: wrap; }
.shop-variants--text .shop-variant { flex-direction: row; min-height: 44px; padding: 10px 14px; border-color: var(--line); font-size: 13px; font-weight: 600; }
.shop-variants--text .shop-variant.is-active { background: var(--ink); color: var(--bg); box-shadow: none; }

/* Розміри та комплектація */
.shop-config { display: grid; gap: 20px; margin: 0 0 24px; }
.shop-config__values { display: flex; flex-wrap: wrap; gap: 6px; }
.shop-choice { display: inline-flex; align-items: center; min-height: 44px; padding: 10px 14px; border: 1px solid var(--line); font-size: 14px; font-weight: 600; color: var(--ink); }
.shop-choice:hover { border-color: var(--ink); }
.shop-choice.is-active { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.shop-choice.is-unavailable { color: #A39A90; border-style: dashed; cursor: not-allowed; }

/* Короткі властивості */
.shop-facts { display: grid; grid-template-columns: minmax(110px, auto) minmax(0, 1fr); gap: 0; margin: 0 0 28px; font-size: 14px; line-height: 1.5; }
.shop-facts dt, .shop-facts dd { margin: 0; padding: 11px 0; border-bottom: 1px solid var(--line); }
.shop-facts dt { padding-right: 16px; color: var(--mute); }
.shop-facts dd { font-weight: 600; overflow-wrap: anywhere; }
.shop-facts .shop-dot { margin-right: 6px; vertical-align: -1px; }
.shop-facts__colors span + span { margin-left: 0; }
.shop-facts--stack { grid-template-columns: minmax(0, 1fr); border-top: 1px solid var(--rule); }
.shop-facts--stack dt { padding: 14px 0 2px; border: 0; font: 700 12px/1.4 var(--body); letter-spacing: .14em; text-transform: uppercase; }
.shop-facts--stack dd { padding: 0 0 14px; }

/* Купівля */
.shop-product .product__buy { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin: 0 0 24px; }
.shop-qty { display: inline-flex; align-items: stretch; height: 56px; border: 1px solid var(--ink); }
.shop-qty button { width: 48px; border: 0; background: none; font-size: 20px; color: var(--ink); cursor: pointer; }
.shop-qty button:hover { background: var(--ink); color: var(--bg); }
.shop-qty input { width: 48px; border: 0; background: none; text-align: center; font: 700 16px/1 var(--body); color: var(--ink); -moz-appearance: textfield; }
.shop-qty input::-webkit-outer-spin-button, .shop-qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.shop-qty input:focus { outline: 2px solid var(--acc); outline-offset: -2px; }
.shop-product .product__buy .btn--primary { flex: 1 1 200px; }
.shop-buy-row { display: flex; flex-wrap: wrap; gap: 4px 28px; margin: 0 0 28px; }
.shop-pay-note { margin: 0 0 28px; padding: 16px 0 0; border-top: 1px solid var(--line); font-size: 14px; line-height: 1.7; color: var(--mute); }
.shop-pay-note strong { color: var(--ink); }
.shop-perks { list-style: none; margin: 0; padding: 0; counter-reset: perk; border-top: 1px solid var(--rule); }
.shop-perks li { display: flex; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 14px; line-height: 1.55; counter-increment: perk; }
.shop-perks li::before { content: counter(perk, decimal-leading-zero); flex: none; width: 24px; font-size: 13px; font-weight: 600; color: var(--mute); }

/* Диван: ключові факти */
.sofa-price-note { margin: 0 0 20px; font-size: 14px; line-height: 1.65; color: var(--mute); }
.shop .sofa-quote { margin: 0 0 24px; }
.shop .sofa-keyfacts { display: grid; grid-template-columns: 1fr; margin: 0 0 24px; padding: 0; font-size: 14px; }
.shop .sofa-keyfacts div { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.shop .sofa-keyfacts dt { color: var(--mute); margin: 0; }
.shop .sofa-keyfacts dd { margin: 0; font-weight: 600; }

/* Розділи під товаром: 01 Опис, 02 Характеристики… */
.shop-sections { margin: 0; }
.shop-section { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 24px 56px; padding: 56px 0; border-bottom: 1px solid var(--line); scroll-margin-top: 96px; }
.shop-section:last-child { border-bottom: 0; }
.shop-section__head { display: flex; align-items: baseline; gap: 18px; align-self: start; }
.shop-section__num { flex: none; width: 24px; font-size: 13px; font-weight: 600; color: var(--mute); }
.shop-section__title { margin: 0; font: 400 clamp(30px, 3vw, 44px)/1.05 var(--display); }
.shop-section__body { min-width: 0; }
.shop-specs { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.5; border-top: 1px solid var(--rule); }
.shop-specs th, .shop-specs td { padding: 13px 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.shop-specs th { width: 44%; padding-right: 24px; font-weight: 500; color: var(--mute); }
.shop-specs td { font-weight: 600; overflow-wrap: anywhere; }
.shop-specs tfoot th, .shop-specs tfoot td, .shop-specs .is-total th, .shop-specs .is-total td { border-top: 1px solid var(--rule); border-bottom: 0; font-weight: 700; color: var(--ink); padding-top: 18px; }
.shop-specs .is-total td { font: 400 30px/1.1 var(--display); }

.shop-prose { max-width: 720px; font-size: 16px; line-height: 1.75; color: var(--ink); overflow-wrap: anywhere; }
.shop-prose > :first-child { margin-top: 0; }
.shop-prose > :last-child { margin-bottom: 0; }
.shop-prose p, .shop-prose ul, .shop-prose ol { margin: 0 0 1.1em; }
.shop-prose ul, .shop-prose ol { padding-left: 1.2em; }
.shop-prose li { margin: 0 0 .45em; }
.shop-prose h2, .shop-prose h3, .shop-prose h4 { margin: 1.6em 0 .55em; font: 400 26px/1.15 var(--display); }
.shop-prose h3 { font-size: 23px; }
.shop-prose strong { font-weight: 700; }
.shop-prose a { color: var(--acc); text-decoration: underline; text-underline-offset: 3px; }
.shop-prose img { max-width: 100%; height: auto; margin: 1.2em 0; }
.shop-prose table { width: 100%; border-collapse: collapse; margin: 1.2em 0; font-size: 14px; }
.shop-prose th, .shop-prose td { padding: 10px 12px 10px 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.shop-prose dl { display: grid; grid-template-columns: minmax(0, 1fr) auto; margin: 1.2em 0; border-top: 1px solid var(--line); font-size: 15px; }
.shop-prose dt, .shop-prose dd { margin: 0; padding: 10px 0; border-bottom: 1px solid var(--line); }
.shop-prose dt { padding-right: 16px; color: var(--mute); }
.shop-prose dd { font-weight: 600; text-align: right; }
.shop-prose blockquote { margin: 1.2em 0; padding: 0 0 0 20px; border-left: 2px solid var(--acc); font: 400 22px/1.4 var(--display); }

/* Відгуки */
.shop-reviews { list-style: none; margin: 0 0 40px; padding: 0; border-top: 1px solid var(--rule); }
.shop-review { padding: 20px 0; border-bottom: 1px solid var(--line); }
.shop-review__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; margin: 0 0 8px; }
.shop-review__name { font: 400 22px/1.2 var(--display); }
.shop-review__stars { color: var(--acc); letter-spacing: .1em; font-size: 14px; }
.shop-review__date { margin-left: auto; font-size: 13px; color: var(--mute); }
.shop-review p { margin: 0; font-size: 15px; line-height: 1.7; }
.shop-reviews-empty { margin: 0 0 32px; font-size: 16px; color: var(--mute); }
.shop-review-form { max-width: 560px; padding: 28px 0 0; border-top: 1px solid var(--rule); }
.shop-review-form .form__grid { margin: 0; }

/* ---------- Кошик ---------- */
.shop-cart { display: grid; grid-template-columns: minmax(0, 8fr) minmax(300px, 4fr); gap: 0 56px; align-items: start; border-top: 1px solid var(--rule); }
.shop-cart__list { min-width: 0; }
.shop-cart-table { width: 100%; border-collapse: collapse; border-top: 0; }
.shop-cart-table thead th { padding: 16px 0; border-bottom: 1px solid var(--line); font: 700 12px/1.4 var(--body); letter-spacing: .14em; text-transform: uppercase; text-align: left; color: var(--mute); }
.shop-cart-table thead th:not(:first-child) { padding-left: 16px; }
.shop-cart-table td { padding: 24px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.shop-cart-table td:not(:first-child) { padding-left: 16px; }
.shop-cart-table .is-num { white-space: nowrap; font-weight: 600; padding-top: 34px; }
.shop-cart-table .is-qty { padding-top: 22px; }
.shop-cart-table .is-remove { width: 48px; text-align: right; padding-top: 22px; }
.shop-cart-item { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 20px; align-items: start; }
.shop-cart-item__img { display: block; aspect-ratio: 1; background: #EBE5DC; overflow: hidden; }
.shop-cart-item__img img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.shop-cart-item__cat { display: block; margin: 4px 0 6px; font: 700 11px/1.4 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }
.shop-cart-item__name { display: block; font: 400 22px/1.2 var(--display); color: var(--ink); overflow-wrap: anywhere; }
.shop-cart-item__name:hover { color: var(--acc); }
.shop-cart-item__config { margin: 10px 0 0; font-size: 13px; line-height: 1.6; color: var(--mute); }
.shop-cart .shop-qty { height: 44px; }
.shop-cart .shop-qty button { width: 40px; }
.shop-cart .shop-qty input { width: 40px; }
.shop-cart [aria-busy="true"] { opacity: .55; }
.shop-remove { display: inline-grid; place-items: center; width: 44px; height: 44px; border: 0; background: none; font-size: 26px; line-height: 1; color: var(--mute); cursor: pointer; }
.shop-remove:hover { color: var(--acc); background: none; }
.shop-cart-table td[data-label]::before { content: none !important; display: none !important; }
.shop-cart__after { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; padding: 24px 0 0; }

.shop-summary { align-self: start; position: sticky; top: 104px; margin: 0; padding: 24px 0 0; min-width: 0; background: none; border: 0; box-shadow: none; }
.shop-summary__title { margin: 0 0 16px; font: 400 32px/1.1 var(--display); }
.shop-summary__row { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.shop-summary__row > :first-child { color: var(--mute); }
.shop-summary__row > :last-child { text-align: right; font-weight: 600; }
.shop-summary__row:has(+ .shop-summary__row--total) { border-bottom: 0; }
.shop-summary__row--total { padding: 20px 0; border-top: 1px solid var(--rule); border-bottom: 0; margin-top: 8px; }
.shop-summary__row--total > :first-child { color: var(--ink); font-weight: 700; }
.shop-summary__row--total > :last-child { font: 400 36px/1 var(--display); white-space: nowrap; }
.shop-summary .btn { width: 100%; margin: 4px 0 20px; }
.shop-summary__terms { margin: 0 0 8px; font-size: 13px; line-height: 1.65; color: var(--mute); }
.shop-summary__terms strong { color: var(--ink); }
.shop-summary__items { list-style: none; margin: 0 0 8px; padding: 0; border-top: 1px solid var(--rule); }
.shop-summary__item { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 14px; line-height: 1.45; }
.shop-summary__item img { width: 64px; height: 64px; object-fit: contain; background: #EBE5DC; mix-blend-mode: multiply; }
.shop-summary__item-name { min-width: 0; overflow-wrap: anywhere; font-weight: 600; }
.shop-summary__item-name small { display: block; margin-top: 4px; font-size: 12px; font-weight: 400; color: var(--mute); }
.shop-summary__item-price { font-weight: 700; white-space: nowrap; }

/* ---------- Оформлення ---------- */
.shop-checkout { display: grid; grid-template-columns: minmax(0, 7fr) minmax(300px, 5fr); gap: 0 56px; align-items: start; border-top: 1px solid var(--rule); }
.shop-checkout .checkout__form { padding: 8px 0 0; min-width: 0; }
.shop-checkout .shop-summary { border-left: 1px solid var(--rule); padding: 32px 0 0 40px; }
.shop-step { margin: 0; padding: 32px 0 16px; border: 0; border-bottom: 1px solid var(--line); min-width: 0; }
.shop-step__legend { display: flex; align-items: baseline; gap: 16px; float: left; width: 100%; margin: 0 0 24px; padding: 0; font: 400 32px/1.1 var(--display); }
.shop-step__legend span { font: 600 13px/1 var(--body); color: var(--mute); width: 24px; flex: none; }
.shop-step__legend + * { clear: both; }
.shop-options { display: grid; gap: 8px; margin: 0 0 20px; }
.shop-option { position: relative; display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; border: 1px solid var(--line); cursor: pointer; background: transparent; }
.shop-option:hover { border-color: var(--ink); }
.shop-option:has(input:checked) { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); background: var(--shop-paper); }
.shop-option input { flex: none; width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--ink); }
.shop-option__title { display: block; font-weight: 700; font-size: 15px; line-height: 1.4; }
.shop-option small { display: block; margin-top: 4px; font-size: 13px; line-height: 1.6; color: var(--mute); }
.shop-checkout__submit { padding: 32px 0 0; }
.shop-checkout__submit .btn { min-width: 280px; }
#directory-status { margin: 0 0 12px; }
#directory-status:empty { display: none; }
#directory-status.is-error { color: var(--shop-err); font-weight: 600; }
#directory-retry { margin: 0 0 16px; }
.delivery-combo { position: relative; }
.delivery-combo input { padding-right: 40px !important; }
.delivery-combo::after { content: ""; position: absolute; right: 16px; top: 20px; width: 8px; height: 8px; border-right: 1.5px solid var(--ink); border-bottom: 1.5px solid var(--ink); transform: rotate(45deg); pointer-events: none; }
.delivery-combo__list { position: absolute; top: calc(100% + 4px); left: 0; right: 0; z-index: 30; max-height: 280px; overflow: auto; padding: 4px 0; background: var(--shop-paper); border: 1px solid var(--ink); box-shadow: 0 12px 28px rgba(28, 27, 26, .12); }
.delivery-combo__option { display: block; width: 100%; padding: 11px 14px; border: 0; background: none; font: 500 14px/1.45 var(--body); color: var(--ink); text-align: left; white-space: normal; cursor: pointer; }
.delivery-combo__option:hover, .delivery-combo__option.is-active { background: var(--shop-soft); }
.delivery-combo__empty { padding: 12px 14px; font-size: 14px; color: var(--mute); }
.shop-checkout select { width: 100%; min-width: 0; max-width: 100%; }

/* ---------- Оплата й успіх ---------- */
.shop-narrow { max-width: 880px; }
.shop-pay { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 0 56px; border-top: 1px solid var(--rule); }
.shop-pay__main { padding: 40px 0 0; min-width: 0; }
.shop-pay__aside { padding: 40px 0 0 40px; border-left: 1px solid var(--rule); min-width: 0; }
.shop-pay__amount { display: block; margin: 8px 0 24px; font: 400 clamp(44px, 6vw, 72px)/1 var(--display); letter-spacing: -.01em; }
.shop-pay__methods { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 28px; padding: 0; list-style: none; }
.shop-pay__methods li { padding: 8px 12px; border: 1px solid var(--line); font-size: 13px; font-weight: 600; }
.shop-pay form { margin: 0; }
.shop-pay .btn { width: 100%; }
.shop-pay p { font-size: 15px; line-height: 1.7; }

.shop-success { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 0 56px; border-top: 1px solid var(--rule); }
.shop-success__main { padding: 40px 0 0; min-width: 0; }
.shop-success__aside { padding: 40px 0 0 40px; border-left: 1px solid var(--rule); min-width: 0; }
.shop-success__number { display: block; margin: 4px 0 20px; font: 400 44px/1 var(--display); }
.shop-success__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; margin: 32px 0 0; }
.shop-success__aside p { font-size: 15px; line-height: 1.7; margin: 0 0 16px; }
.shop-success__aside a { color: var(--acc); }

/* ---------- Адаптив ---------- */
@media (max-width: 1100px) {
  .shop-grid--4 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .shop-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shop-catalog__body--full .shop-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .shop-catalog__body { grid-template-columns: 232px minmax(0, 1fr); gap: 0 32px; }
  .shop-index { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shop-product__media { padding-right: 32px; }
  .shop-product .product__info { padding-left: 32px; }
  .shop-cart { grid-template-columns: minmax(0, 1fr); }
  .shop-summary { position: static; max-width: 520px; margin-left: auto; width: 100%; }
}

@media (max-width: 900px) {
  .shop { --shop-gap: 20px; padding-bottom: 64px; }
  .shop-head { padding: 28px 0 32px; }
  .shop-head__grid { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .shop-crumbs { padding-top: 18px; font-size: 12px; }
  .shop-subcats { padding-bottom: 32px; }
  .shop-index__name { font-size: 22px; }
  .shop-index__link { min-height: 56px; padding: 14px 0; }

  /* Фільтри: висувна панель */
  .shop-catalog__body { grid-template-columns: minmax(0, 1fr); }
  .shop-filter-toggle { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 18px; border: 1px solid var(--ink); background: none; font: 700 15px/1 var(--body); color: var(--ink); cursor: pointer; }
  .shop-filter-toggle:hover { background: var(--ink); color: var(--bg); }
  .shop-toolbar { align-items: stretch; }
  .shop-toolbar__count { order: 3; flex-basis: 100%; }
  .shop-toolbar__sort { flex: 1; }
  .shop-toolbar__sort label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .shop-toolbar__sort select { min-width: 0; width: 100%; min-height: 48px; }
  .js .shop-filters {
    position: fixed; z-index: 1200; top: 0; bottom: 0; left: 0; width: min(420px, 100%);
    padding: 0 20px 24px; background: var(--bg); overflow-y: auto; overscroll-behavior: contain;
    transform: translateX(-102%); visibility: hidden; transition: transform .25s ease, visibility 0s linear .25s;
  }
  .js .shop-filters.is-open { transform: none; visibility: visible; transition: transform .25s ease; box-shadow: 0 0 0 100vmax rgba(28, 27, 26, .45); }
  .shop-filters__head { position: sticky; top: 0; z-index: 2; display: flex; justify-content: space-between; align-items: center; margin: 0 -20px 8px; padding: 12px 20px; background: var(--bg); border-bottom: 1px solid var(--rule); }
  .shop-filters__head .shop-filters__title { margin: 0; }
  .shop-filters__close { width: 48px; height: 48px; border: 0; background: none; font-size: 30px; line-height: 1; color: var(--ink); cursor: pointer; }
  .shop-filters > .shop-filters__title, .shop-filters form > .shop-filters__title { display: none; }
  .shop-filters__actions { position: sticky; bottom: -24px; margin: 0 -20px; padding: 16px 20px 24px; background: var(--bg); border-top: 1px solid var(--line); }
  body.shop-filters-open { overflow: hidden; }
  .shop-check { min-height: 44px; padding: 10px 0; }
  .shop-chips { margin-top: -8px; }

  .shop-product { grid-template-columns: minmax(0, 1fr); border-bottom: 0; }
  .shop-product__media { padding: 0 0 24px; border-right: 0; margin: 0 calc(-1 * var(--gutter, 20px)); }
  .shop-product__media .shop-thumbs, .shop-product__media .shop-gallery__note, .shop-product__media .shop-gallery__more { margin-left: var(--gutter, 20px); margin-right: var(--gutter, 20px); }
  .shop-gallery { position: static; }
  .shop-product .product__info { padding: 8px 0 40px; border-top: 0; }
  .shop-product .product__title { font-size: clamp(32px, 8.4vw, 44px); }
  .shop-product .product__price .price__current { font-size: 38px; }
  .shop-section { grid-template-columns: minmax(0, 1fr); gap: 20px; padding: 40px 0; }
  .shop-section__title { font-size: 32px; }
  .shop-block { margin-top: 48px; padding-top: 40px; }
  .shop-grid, .shop-grid--4, .shop-catalog__body--full .shop-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 36px 16px; }

  .shop-checkout { grid-template-columns: minmax(0, 1fr); }
  .shop-checkout .shop-summary { order: -1; border-left: 0; padding: 24px 0 8px; position: static; border-bottom: 1px solid var(--rule); }
  .shop-pay, .shop-success { grid-template-columns: minmax(0, 1fr); }
  .shop-pay__aside, .shop-success__aside { border-left: 0; padding: 32px 0 0; margin-top: 40px; border-top: 1px solid var(--rule); }
  .shop-empty { grid-template-columns: minmax(0, 1fr); padding: 40px 0; }
}

@media (max-width: 640px) {
  .shop-index, .shop-index--2 { grid-template-columns: minmax(0, 1fr); }
  .shop-grid, .shop-grid--4, .shop-catalog__body--full .shop-grid { gap: 32px 12px; }
  .shop-card__title { font-size: 19px; min-height: 0; }
  .shop-card__cat { font-size: 10px; letter-spacing: .1em; margin-top: 10px; }
  .shop-card__foot { flex-direction: column; align-items: flex-start; gap: 0; }
  .shop-card__price strong { font-size: 16px; }
  .shop-card__action { min-height: 40px; }
  .shop-card__badges .shop-badge { padding: 5px 7px; font-size: 10px; letter-spacing: .08em; }
  .shop .form__grid { grid-template-columns: minmax(0, 1fr); }
  .shop-product .product__buy { gap: 12px; }
  .shop-product .product__buy .btn--primary { flex-basis: 100%; order: 2; }
  .shop-qty { order: 1; }
  .shop-thumbs .gallery__thumb { flex-basis: 68px; height: 68px; }
  .shop-gallery .gallery__arrow { width: 44px; height: 44px; margin-top: -22px; }
  .shop-specs th { width: 46%; padding-right: 12px; }
  .shop-specs, .shop-prose { font-size: 15px; }

  /* Кошик: рядки таблиці стають картками */
  .shop-cart-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .shop-cart-table, .shop-cart-table tbody, .shop-cart-table tr { display: block; }
  .shop-cart-table tr { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; padding: 20px 0; border-bottom: 1px solid var(--line); }
  .shop-cart-table td { display: block; padding: 0 !important; border: 0; }
  .shop-cart-table td.is-product { grid-column: 1; grid-row: 1; }
  .shop-cart-table td.is-price { display: none; }
  .shop-cart-table td.is-qty { grid-column: 1; grid-row: 2; margin-top: 16px !important; }
  .shop-cart-table td.is-sum { grid-column: 2; grid-row: 2; align-self: center; justify-self: end; margin-top: 16px !important; font-size: 17px; }
  .shop-cart-table td.is-remove { grid-column: 2; grid-row: 1; position: static; width: auto; margin: -10px -10px 0 8px !important; }
  .shop-cart-item { grid-template-columns: 88px minmax(0, 1fr); gap: 14px; }
  .shop-cart-item__name { font-size: 19px; }
  .shop-summary__row--total > :last-child { font-size: 30px; }
  .shop-step__legend { font-size: 26px; }
  .shop-checkout__submit .btn { width: 100%; min-width: 0; }
  .shop-summary__item { grid-template-columns: 52px minmax(0, 1fr); }
  .shop-summary__item img { width: 52px; height: 52px; }
  .shop-summary__item-price { grid-column: 2; }
  .shop-option { padding: 14px; }
  .shop-success__number { font-size: 36px; }
}

@media (max-width: 380px) {
  .shop-grid, .shop-grid--4, .shop-catalog__body--full .shop-grid { gap: 28px 10px; }
  .shop-card__title { font-size: 17px; }
}

@media (prefers-reduced-motion: reduce) {
  .shop-card__media img, .js .shop-filters { transition: none !important; }
}
