/* ==========================================================================
   ФОРМА · партнёрский портал — дизайн-система
   ========================================================================== */

:root {
  --ink: #171410;
  --ink-2: #403A33;
  --muted: #7B7266;
  --line: #E5DED2;
  --line-strong: #D2C7B6;
  --paper: #F7F4EE;
  --card: #FFFFFF;
  --sand: #EFE7DA;
  --sand-2: #E7DCCB;
  --accent: #B4632C;
  --accent-2: #8F4A1C;
  --accent-soft: #F4E4D6;
  --green: #3E5C45;
  --green-soft: #E6EDE7;
  --amber: #8A6418;
  --amber-soft: #F6ECD5;
  --red: #A03A2E;
  --red-soft: #F7E3DF;
  --blue: #35566E;
  --blue-soft: #E4ECF2;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 1px 2px rgba(23, 20, 16, 0.04), 0 18px 40px -24px rgba(23, 20, 16, 0.35);
  --shadow-lg: 0 30px 70px -30px rgba(23, 20, 16, 0.45);
  --font-body: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --font-display: Georgia, "Times New Roman", serif;
  --container: 1240px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.no-scroll {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  cursor: pointer;
}

input,
select,
textarea {
  font: inherit;
  color: inherit;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.015em;
}

p {
  margin: 0;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

::selection {
  background: var(--accent-soft);
}

/* --------------------------------------------------------------------------
   Каркас
   -------------------------------------------------------------------------- */

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 28px;
}

.view {
  min-height: 60vh;
}

.section {
  padding: 58px 0;
}

.section--tight {
  padding: 34px 0;
}

.section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

.section__title {
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.1;
}

.eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
}

.lead {
  font-size: 16.5px;
  color: var(--ink-2);
  max-width: 560px;
}

.muted {
  color: var(--muted);
}

.small {
  font-size: 12.5px;
}

.nowrap {
  white-space: nowrap;
}

.mt-0 { margin-top: 0; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mb-0 { margin-bottom: 0; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }

.row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.wrap {
  flex-wrap: wrap;
}

.grow {
  flex: 1;
}

.divider {
  height: 1px;
  background: var(--line);
  border: 0;
  margin: 24px 0;
}

/* --------------------------------------------------------------------------
   Кнопки
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.btn svg {
  flex-shrink: 0;
}

.btn:active {
  transform: translateY(1px);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn--accent {
  background: var(--accent);
  color: #fff;
}

.btn--accent:hover:not(:disabled) {
  background: var(--accent-2);
}

.btn--dark {
  background: var(--ink);
  color: #fff;
}

.btn--dark:hover:not(:disabled) {
  background: #2A251F;
}

.btn--ghost {
  border-color: var(--line-strong);
  background: transparent;
  color: var(--ink);
}

.btn--ghost:hover:not(:disabled) {
  border-color: var(--ink);
  background: #fff;
}

.btn--soft {
  background: var(--sand);
  color: var(--ink);
}

.btn--soft:hover:not(:disabled) {
  background: var(--sand-2);
}

.btn--light {
  background: #fff;
  color: var(--ink);
}

.btn--danger-ghost {
  border-color: var(--red);
  color: var(--red);
  background: transparent;
}

.btn--danger-ghost:hover:not(:disabled) {
  background: var(--red-soft);
}

.btn--sm {
  padding: 8px 14px;
  font-size: 13px;
}

.btn--lg {
  padding: 15px 28px;
  font-size: 15px;
}

.btn--block {
  width: 100%;
}

.btn--link {
  border: 0;
  background: none;
  padding: 0;
  color: var(--accent);
  font-weight: 600;
}

.btn--link:hover {
  color: var(--accent-2);
}

/* --------------------------------------------------------------------------
   Шапка
   -------------------------------------------------------------------------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 244, 238, 0.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.topbar__inner {
  display: flex;
  align-items: center;
  gap: 30px;
  height: 78px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.brand__mark {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--ink);
  display: grid;
  place-items: center;
}

.brand__name {
  display: block;
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: 0.16em;
  line-height: 1;
}

.brand__sub {
  display: block;
  margin-top: 5px;
  font-size: 9.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.mainnav {
  display: flex;
  align-items: center;
  gap: 26px;
  font-size: 14px;
}

.mainnav a {
  color: var(--ink-2);
  padding: 6px 0;
  position: relative;
}

.mainnav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}

.mainnav a:hover {
  color: var(--ink);
}

.mainnav a:hover::after {
  transform: scaleX(1);
}

.mainnav a.is-active {
  color: var(--ink);
  font-weight: 600;
}

.topbar__actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 232px;
  height: 42px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
}

.search:focus-within {
  border-color: var(--line-strong);
}

.search input {
  width: 100%;
  border: 0;
  outline: none;
  background: none;
  font-size: 13px;
  color: var(--ink);
}

.search input::placeholder {
  color: var(--muted);
}

.iconbtn {
  position: relative;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink);
  transition: background 0.15s ease, border-color 0.15s ease;
}

.iconbtn:hover {
  background: #fff;
  border-color: var(--line);
}

.cart-count {
  position: absolute;
  top: -1px;
  right: -1px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  font-size: 10.5px;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.usermenu {
  position: relative;
}

.menu__panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 236px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 10px;
  display: none;
  z-index: 60;
}

.usermenu.is-open .menu__panel,
.menu__panel.is-open {
  display: block;
}

.menu__head {
  padding: 8px 10px 10px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 6px;
}

.menu__head b {
  display: block;
  font-size: 13.5px;
}

.menu__head span {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.menu__item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 10px;
  border: 0;
  border-radius: 8px;
  background: none;
  font-size: 13.5px;
  text-align: left;
  color: var(--ink-2);
}

.menu__item:hover {
  background: var(--paper);
  color: var(--ink);
}

.burger {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
}

.burger span {
  display: block;
  width: 16px;
  height: 1.5px;
  background: var(--ink);
  margin: 3px auto;
}

/* --------------------------------------------------------------------------
   Главная
   -------------------------------------------------------------------------- */

.hero {
  padding: 54px 0 30px;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.02fr 0.98fr;
  gap: 52px;
  align-items: center;
}

.hero h1 {
  margin: 18px 0 22px;
  font-size: clamp(38px, 4.5vw, 62px);
  line-height: 1.02;
}

.hero h1 em {
  font-style: italic;
  color: var(--accent);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.hero__stats {
  display: flex;
  flex-wrap: wrap;
  gap: 38px;
  margin-top: 42px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.stat b {
  display: block;
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 400;
  line-height: 1;
}

.stat span {
  display: block;
  margin-top: 7px;
  font-size: 12px;
  color: var(--muted);
}

.hero__art {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  background: var(--sand);
  box-shadow: var(--shadow);
}

.hero__art img {
  width: 100%;
  aspect-ratio: 900 / 720;
  object-fit: cover;
}

.hero__tag {
  position: absolute;
  left: 18px;
  bottom: 18px;
  padding: 12px 16px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(6px);
  box-shadow: var(--shadow);
  font-size: 12px;
  line-height: 1.35;
}

.hero__tag b {
  display: block;
  font-size: 15px;
  margin-bottom: 2px;
}

.discount-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 18px 28px;
  margin: 10px 0 20px;
  padding: 20px 26px;
  border-radius: 18px;
  background: var(--ink);
  color: #F4EFE6;
}

.discount-banner b {
  color: #E9BC92;
  font-family: var(--font-display);
  font-size: 25px;
  font-weight: 400;
}

.discount-banner .small {
  color: rgba(244, 239, 230, 0.65);
}

/* Категории */

.cat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.cat-card {
  display: block;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cat-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.cat-card__media {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--sand);
}

.cat-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.cat-card:hover .cat-card__media img {
  transform: scale(1.035);
}

.cat-card__body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 18px 17px;
}

.cat-card__name {
  font-weight: 600;
  font-size: 15px;
}

.cat-card__count {
  font-size: 12px;
  color: var(--muted);
}

/* Преимущества */

.features {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.feature {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.feature__icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--sand);
  color: var(--accent-2);
  margin-bottom: 16px;
}

.feature h3 {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 7px;
}

.feature p {
  font-size: 13.5px;
  color: var(--muted);
}

/* CTA */

.cta {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 40px;
  padding: 42px;
  border-radius: 24px;
  background: var(--sand);
  border: 1px solid var(--sand-2);
}

.cta h2 {
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.08;
  margin-bottom: 14px;
}

.cta__steps {
  display: grid;
  gap: 12px;
  counter-reset: step;
}

.cta__step {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 14px;
  color: var(--ink-2);
}

.cta__step::before {
  counter-increment: step;
  content: counter(step);
  flex: 0 0 26px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--sand-2);
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-2);
}

/* --------------------------------------------------------------------------
   Карточки товаров
   -------------------------------------------------------------------------- */

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.product-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.product-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.product-card__media {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--sand);
}

.product-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.product-card:hover .product-card__media img {
  transform: scale(1.035);
}

.badge-hit {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.badge-discount {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
}

.product-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 5px;
  padding: 14px 16px 16px;
}

.product-card__cat {
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.product-card__name {
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.35;
  min-height: 39px;
}

.product-card__sku {
  font-size: 11.5px;
  color: var(--muted);
}

.price {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
  padding-top: 9px;
}

.price__value {
  font-family: var(--font-display);
  font-size: 22px;
  line-height: 1;
}

.price__old {
  font-size: 12.5px;
  color: var(--muted);
  text-decoration: line-through;
}

.price__discount {
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent-2);
  font-size: 11px;
  font-weight: 600;
}

.price__login {
  font-size: 13px;
  color: var(--accent-2);
  font-weight: 600;
}

.stock {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  color: var(--green);
}

.stock::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.stock--out {
  color: var(--muted);
}

.product-card__actions {
  margin-top: 12px;
}

/* --------------------------------------------------------------------------
   Каталог
   -------------------------------------------------------------------------- */

.page-head {
  padding: 34px 0 8px;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  font-size: 12.5px;
  color: var(--muted);
  margin-bottom: 10px;
}

.breadcrumbs a:hover {
  color: var(--ink);
}

.breadcrumbs span {
  opacity: 0.5;
}

.catalog {
  display: grid;
  grid-template-columns: 252px 1fr;
  gap: 36px;
  align-items: start;
  padding: 26px 0 64px;
}

.filters {
  position: sticky;
  top: 98px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.filter-group h4 {
  margin: 0 0 10px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
}

.filter-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0;
  font-size: 14px;
  color: var(--ink-2);
}

.filter-link span {
  font-size: 11.5px;
  color: var(--muted);
}

.filter-link:hover,
.filter-link.is-active {
  color: var(--accent-2);
}

.filter-link.is-active {
  font-weight: 600;
}

.filter-reset {
  border: 0;
  background: none;
  padding: 0;
  font-size: 12.5px;
  color: var(--accent-2);
  text-align: left;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.toolbar__count {
  font-size: 13.5px;
  color: var(--muted);
}

.toolbar__right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.select--compact {
  width: auto;
  padding: 9px 34px 9px 12px;
  font-size: 13px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: #fff;
  font-size: 12.5px;
  color: var(--ink-2);
}

.chip:hover {
  border-color: var(--ink);
}

.chip.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

.chip button {
  border: 0;
  background: none;
  padding: 0;
  font-size: 15px;
  line-height: 1;
  color: inherit;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 34px;
}

.pagination button {
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  font-size: 13.5px;
}

.pagination button:hover:not(:disabled) {
  border-color: var(--ink);
}

.pagination button.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

.pagination button:disabled {
  opacity: 0.4;
  cursor: default;
}

/* --------------------------------------------------------------------------
   Карточка товара
   -------------------------------------------------------------------------- */

.pdp {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 52px;
  align-items: start;
  padding: 30px 0 70px;
}

.pdp__media {
  position: sticky;
  top: 98px;
  border: 1px solid var(--line);
  border-radius: 22px;
  overflow: hidden;
  background: var(--sand);
}

.pdp__media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.pdp__title {
  margin: 8px 0 12px;
  font-size: clamp(26px, 3.2vw, 38px);
  line-height: 1.1;
}

.pdp__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 20px;
  font-size: 12.5px;
  color: var(--muted);
  margin-bottom: 18px;
}

.pdp__desc {
  color: var(--ink-2);
  font-size: 14.5px;
}

.specs {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0 6px;
  font-size: 13.5px;
}

.specs tr {
  border-bottom: 1px solid var(--line);
}

.specs tr:last-child {
  border-bottom: 0;
}

.specs td {
  padding: 9px 0;
  vertical-align: top;
}

.specs td:first-child {
  width: 46%;
  color: var(--muted);
}

.buybox {
  margin: 22px 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
}

.buybox__price {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 10px;
}

.buybox__value {
  font-family: var(--font-display);
  font-size: 34px;
  line-height: 1;
}

.buybox__old {
  font-size: 14px;
  color: var(--muted);
  text-decoration: line-through;
}

.buybox__controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.qty button {
  width: 38px;
  height: 44px;
  border: 0;
  background: #fff;
  font-size: 17px;
  color: var(--ink-2);
}

.qty button:hover {
  background: var(--paper);
}

.qty input {
  width: 58px;
  height: 44px;
  border: 0;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  text-align: center;
  outline: none;
  font-size: 14px;
}

.buybox__note {
  margin-top: 14px;
  font-size: 12.5px;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.manager-card {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--paper);
}

.manager-card__avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--sand);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 17px;
  color: var(--accent-2);
}

/* --------------------------------------------------------------------------
   Корзина и оформление
   -------------------------------------------------------------------------- */

.cart-layout {
  display: grid;
  grid-template-columns: 1fr 372px;
  gap: 40px;
  align-items: start;
  padding: 26px 0 68px;
}

.cart-row {
  display: grid;
  grid-template-columns: 96px 1fr 128px 132px 116px 34px;
  gap: 16px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.cart-row__img {
  width: 96px;
  height: 76px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--sand);
}

.cart-row__name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
}

.cart-row__meta {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 3px;
}

.cart-row__price {
  font-size: 14px;
  font-weight: 600;
}

.cart-row__sum {
  font-size: 15px;
  font-weight: 600;
  text-align: right;
}

.cart-remove {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: none;
  color: var(--muted);
  display: grid;
  place-items: center;
}

.cart-remove:hover {
  background: var(--red-soft);
  color: var(--red);
}

.cart-head {
  display: grid;
  grid-template-columns: 96px 1fr 128px 132px 116px 34px;
  gap: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.summary {
  position: sticky;
  top: 98px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.summary h3 {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 14px;
}

.summary__row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 0;
  font-size: 13.5px;
  color: var(--ink-2);
}

.summary__row--discount {
  color: var(--accent-2);
}

.summary__total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 17px;
  font-weight: 600;
}

.summary__total b {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 400;
}

.summary__note {
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
}

.minorder {
  margin-top: 14px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--amber-soft);
  color: var(--amber);
  font-size: 12.5px;
}

.progress {
  height: 4px;
  border-radius: 2px;
  background: var(--sand-2);
  overflow: hidden;
  margin-top: 8px;
}

.progress span {
  display: block;
  height: 100%;
  background: var(--accent);
}

.checkout-grid {
  display: grid;
  grid-template-columns: 1fr 372px;
  gap: 40px;
  align-items: start;
}

.panel {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.panel h2,
.panel h3 {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 16px;
}

.panel + .panel {
  margin-top: 18px;
}

.order-lines {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 320px;
  overflow: auto;
}

.order-line {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 12px;
  align-items: center;
  font-size: 13px;
}

.order-line img {
  width: 48px;
  height: 40px;
  border-radius: 7px;
  object-fit: cover;
  background: var(--sand);
}

/* --------------------------------------------------------------------------
   Формы
   -------------------------------------------------------------------------- */

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.field > label {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-2);
}

.field__hint {
  font-size: 11.5px;
  color: var(--muted);
}

.input,
.select,
.textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #fff;
  outline: none;
  font-size: 14px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.input:focus,
.select:focus,
.textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(180, 99, 44, 0.12);
}

.input:disabled {
  background: var(--paper);
  color: var(--muted);
}

.textarea {
  min-height: 96px;
  resize: vertical;
}

.select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 34px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 16px;
}

.form-grid .field--full {
  grid-column: 1 / -1;
}

.checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--ink-2);
  cursor: pointer;
}

.checkbox input {
  width: 17px;
  height: 17px;
  margin-top: 2px;
  accent-color: var(--accent);
}

.form-error {
  padding: 10px 14px;
  margin-bottom: 14px;
  border-radius: 10px;
  background: var(--red-soft);
  color: var(--red);
  font-size: 13px;
}

.form-success {
  padding: 10px 14px;
  margin-bottom: 14px;
  border-radius: 10px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 13px;
}

/* --------------------------------------------------------------------------
   Вход и регистрация
   -------------------------------------------------------------------------- */

body.is-auth .topbar,
body.is-auth .footer {
  display: none;
}

.auth {
  display: grid;
  grid-template-columns: 1.02fr 0.98fr;
  min-height: 100vh;
}

.auth__brand {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 44px 52px;
  background: var(--ink);
  color: #F4EFE6;
  overflow: hidden;
}

.auth__brand::after {
  content: "";
  position: absolute;
  right: -160px;
  top: -140px;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  border: 1px solid rgba(233, 188, 146, 0.28);
}

.auth__brand::before {
  content: "";
  position: absolute;
  right: -60px;
  bottom: -220px;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  border: 1px solid rgba(233, 188, 146, 0.16);
}

.auth__logo {
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  z-index: 1;
}

.auth__logo .brand__mark {
  background: #F4EFE6;
}

.auth__logo .brand__name {
  color: #F4EFE6;
}

.auth__logo .brand__sub {
  color: rgba(244, 239, 230, 0.55);
}

.auth__quote {
  position: relative;
  z-index: 1;
  max-width: 460px;
}

.auth__quote h1 {
  font-size: clamp(30px, 3.2vw, 46px);
  line-height: 1.08;
  margin-bottom: 18px;
}

.auth__quote h1 em {
  color: #E9BC92;
  font-style: italic;
}

.auth__quote p {
  color: rgba(244, 239, 230, 0.66);
  font-size: 14px;
  max-width: 380px;
}

.auth__points {
  display: grid;
  gap: 10px;
  margin-top: 28px;
  font-size: 13.5px;
  color: rgba(244, 239, 230, 0.8);
}

.auth__points li {
  display: flex;
  gap: 10px;
  align-items: center;
}

.auth__points li::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #E9BC92;
}

.auth__panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 44px 28px;
  background: var(--paper);
}

.auth__card {
  width: 100%;
  max-width: 404px;
}

.auth__card h2 {
  font-size: 32px;
  margin-bottom: 8px;
}

.auth__card > p {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 26px;
}

.auth__tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  background: var(--sand);
  border-radius: 12px;
  margin-bottom: 22px;
}

.auth__tab {
  padding: 9px;
  border: 0;
  border-radius: 9px;
  background: none;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--ink-2);
}

.auth__tab.is-active {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 1px 3px rgba(23, 20, 16, 0.12);
}

.auth__alt {
  margin-top: 22px;
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}

.auth__alt a {
  color: var(--accent-2);
  font-weight: 600;
}

.auth__demo {
  margin-top: 24px;
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--sand);
  font-size: 12px;
  color: var(--ink-2);
  line-height: 1.5;
}

.auth__demo code {
  font-size: 11.5px;
}

.code-hint {
  margin-top: 8px;
  padding: 10px 12px;
  border: 1px dashed var(--accent);
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent-2);
  font-size: 12.5px;
}

/* --------------------------------------------------------------------------
   Заказы
   -------------------------------------------------------------------------- */

.orders-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.order-card {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 20px;
  align-items: center;
  padding: 18px 22px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.order-card:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow);
}

.order-card__number {
  font-weight: 600;
  font-size: 14.5px;
}

.order-card__meta {
  font-size: 12px;
  color: var(--muted);
  margin-top: 3px;
}

.order-card__sum {
  font-family: var(--font-display);
  font-size: 20px;
  text-align: right;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  background: var(--sand);
  color: var(--ink-2);
  white-space: nowrap;
}

.badge--new {
  background: var(--blue-soft);
  color: var(--blue);
}

.badge--confirmed {
  background: var(--accent-soft);
  color: var(--accent-2);
}

.badge--processing {
  background: var(--amber-soft);
  color: var(--amber);
}

.badge--shipped {
  background: var(--green-soft);
  color: var(--green);
}

.badge--done {
  background: var(--green);
  color: #fff;
}

.badge--canceled {
  background: var(--red-soft);
  color: var(--red);
}

.badge--pending {
  background: var(--amber-soft);
  color: var(--amber);
}

.badge--active {
  background: var(--green-soft);
  color: var(--green);
}

.badge--blocked {
  background: var(--red-soft);
  color: var(--red);
}

.badge--soft {
  background: var(--paper);
  color: var(--muted);
}

.order-detail__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.order-detail__number {
  font-size: clamp(26px, 3vw, 36px);
  margin-bottom: 4px;
}

.timeline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  font-size: 12.5px;
  color: var(--muted);
  margin-top: 10px;
}

/* --------------------------------------------------------------------------
   Личный кабинет
   -------------------------------------------------------------------------- */

.profile-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
  padding: 10px 0 64px;
}

.discount-card {
  position: relative;
  padding: 26px;
  border-radius: var(--radius);
  background: var(--ink);
  color: #F4EFE6;
  overflow: hidden;
}

.discount-card::after {
  content: "";
  position: absolute;
  right: -70px;
  top: -80px;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  border: 1px solid rgba(233, 188, 146, 0.3);
}

.discount-card__value {
  font-family: var(--font-display);
  font-size: 56px;
  line-height: 1;
  color: #E9BC92;
}

.discount-card__label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: rgba(244, 239, 230, 0.6);
  margin-bottom: 10px;
}

.discount-card p {
  margin-top: 14px;
  font-size: 13px;
  color: rgba(244, 239, 230, 0.72);
  max-width: 320px;
}

.info-list {
  display: grid;
  gap: 12px;
}

.info-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 13.5px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.info-row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.info-row span:first-child {
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Админ-панель
   -------------------------------------------------------------------------- */

.admin {
  padding: 30px 0 70px;
}

.admin-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.admin-head h1 {
  font-size: clamp(28px, 3vw, 38px);
}

.admin-tabs {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 26px;
  overflow-x: auto;
}

.admin-tab {
  padding: 10px 16px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: none;
  font-size: 13.5px;
  color: var(--muted);
  white-space: nowrap;
}

.admin-tab:hover {
  color: var(--ink);
}

.admin-tab.is-active {
  color: var(--ink);
  border-bottom-color: var(--accent);
  font-weight: 600;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 22px;
}

.kpi {
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}

.kpi__label {
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.kpi__value {
  margin-top: 8px;
  font-family: var(--font-display);
  font-size: 30px;
  line-height: 1;
}

.kpi__note {
  margin-top: 8px;
  font-size: 11.5px;
  color: var(--muted);
}

.kpi__note--up {
  color: var(--green);
}

.kpi__note--down {
  color: var(--red);
}

.admin-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 18px;
  align-items: start;
}

.tablewrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.table th {
  padding: 11px 14px;
  text-align: left;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

.table tr:last-child td {
  border-bottom: 0;
}

.table tbody tr:hover {
  background: #FCFAF6;
}

.table tr.is-clickable {
  cursor: pointer;
}

.table .num {
  text-align: right;
  white-space: nowrap;
}

.table__name {
  font-weight: 600;
}

.table__sub {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 2px;
}

.filtersbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.filtersbar .search {
  width: 280px;
}

.tabsline {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.tabsline .chip {
  cursor: pointer;
}

.sync-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.sync-entities {
  display: grid;
  gap: 8px;
  font-size: 12.5px;
}

.sync-entities div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 0;
  border-bottom: 1px dashed var(--line);
}

.sync-entities code,
code {
  font-family: "Cascadia Code", Consolas, monospace;
  font-size: 11.5px;
  background: var(--paper);
  padding: 2px 5px;
  border-radius: 5px;
}

.logline {
  display: grid;
  grid-template-columns: 92px 1fr 86px 70px 70px;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  align-items: center;
}

.logline:last-child {
  border-bottom: 0;
}

/* --------------------------------------------------------------------------
   Модальные окна и тосты
   -------------------------------------------------------------------------- */

.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(23, 20, 16, 0.45);
  backdrop-filter: blur(3px);
  animation: fade 0.16s ease;
}

.modal__dialog {
  width: 100%;
  max-width: 660px;
  max-height: 90vh;
  overflow: auto;
  padding: 26px;
  border-radius: 20px;
  background: var(--paper);
  box-shadow: var(--shadow-lg);
  animation: pop 0.18s ease;
}

.modal__dialog--wide {
  max-width: 900px;
}

.modal__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.modal__head h2 {
  font-size: 24px;
}

.modal__close {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: var(--sand);
  font-size: 18px;
  line-height: 1;
  color: var(--ink-2);
  flex-shrink: 0;
}

.modal__close:hover {
  background: var(--sand-2);
}

@keyframes fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes pop {
  from { opacity: 0; transform: translateY(8px) scale(0.99); }
  to { opacity: 1; transform: none; }
}

.toasts {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 380px;
}

.toast {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 13px 16px;
  border-radius: 12px;
  background: var(--ink);
  color: #F4EFE6;
  font-size: 13px;
  box-shadow: var(--shadow-lg);
  animation: pop 0.2s ease;
}

.toast--success {
  background: var(--green);
}

.toast--error {
  background: var(--red);
}

.toast--info {
  background: var(--ink);
}

/* --------------------------------------------------------------------------
   Пустые состояния, скелетоны
   -------------------------------------------------------------------------- */

.empty {
  padding: 64px 24px;
  text-align: center;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.5);
}

.empty__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: var(--sand);
  display: grid;
  place-items: center;
  color: var(--accent-2);
}

.empty h3 {
  font-size: 22px;
  margin-bottom: 8px;
}

.empty p {
  color: var(--muted);
  font-size: 13.5px;
  max-width: 420px;
  margin: 0 auto 20px;
}

.skeleton {
  border-radius: var(--radius);
  background: linear-gradient(90deg, var(--sand) 25%, #F5EFE5 37%, var(--sand) 63%);
  background-size: 400% 100%;
  animation: shimmer 1.3s ease infinite;
}

@keyframes shimmer {
  0% { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}

/* --------------------------------------------------------------------------
   Подвал
   -------------------------------------------------------------------------- */

.footer {
  margin-top: 20px;
  padding: 48px 0 26px;
  background: var(--ink);
  color: #F4EFE6;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 36px;
}

.footer .brand__mark {
  background: #F4EFE6;
}

.footer .brand__name {
  color: #F4EFE6;
}

.footer .brand__sub {
  color: rgba(244, 239, 230, 0.5);
}

.footer__about {
  margin-top: 16px;
  max-width: 300px;
  font-size: 12.5px;
  color: rgba(244, 239, 230, 0.6);
  line-height: 1.6;
}

.footer h4 {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(244, 239, 230, 0.45);
  margin-bottom: 14px;
}

.footer__col a,
.footer__col span {
  display: block;
  font-size: 13px;
  color: rgba(244, 239, 230, 0.78);
  padding: 4px 0;
}

.footer__col a:hover {
  color: #fff;
}

.footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid rgba(244, 239, 230, 0.12);
  font-size: 11.5px;
  color: rgba(244, 239, 230, 0.45);
}

/* --------------------------------------------------------------------------
   Адаптив
   -------------------------------------------------------------------------- */

@media (max-width: 1120px) {
  .mainnav {
    gap: 18px;
    font-size: 13.5px;
  }

  .search {
    width: 180px;
  }

  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .admin-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .hero__grid {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .hero__art {
    max-width: 620px;
  }

  .cat-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .features {
    grid-template-columns: repeat(2, 1fr);
  }

  .pdp {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .pdp__media {
    position: static;
  }

  .cart-layout,
  .checkout-grid {
    grid-template-columns: 1fr;
  }

  .summary {
    position: static;
  }

  .catalog {
    grid-template-columns: 1fr;
  }

  .filters {
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 16px 28px;
  }

  .filter-group {
    min-width: 190px;
  }

  .profile-grid {
    grid-template-columns: 1fr;
  }

  .cta {
    grid-template-columns: 1fr;
    padding: 30px;
  }

  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 820px) {
  .mainnav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 78px;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 14px 28px 20px;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
  }

  .mainnav.is-open {
    display: flex;
  }

  .mainnav a {
    padding: 9px 0;
    font-size: 15px;
  }

  .burger {
    display: block;
  }

  .search {
    display: none;
  }

  .topbar__inner {
    height: 70px;
    gap: 16px;
  }

  .auth {
    grid-template-columns: 1fr;
  }

  .auth__brand {
    display: none;
  }

  .auth__panel {
    min-height: 100vh;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .sync-grid {
    grid-template-columns: 1fr;
  }

  .cart-head {
    display: none;
  }

  .cart-row {
    grid-template-columns: 76px 1fr auto;
    grid-template-areas:
      "img name remove"
      "img qty sum";
    row-gap: 10px;
  }

  .cart-row__img {
    grid-area: img;
    width: 76px;
    height: 64px;
  }

  .cart-row__name {
    grid-area: name;
  }

  .cart-row__price {
    display: none;
  }

  .cart-row__qty {
    grid-area: qty;
  }

  .cart-row__sum {
    grid-area: sum;
  }

  .cart-remove {
    grid-area: remove;
  }

  .order-card {
    grid-template-columns: 1fr auto;
    gap: 10px 16px;
  }

  .order-card__sum {
    text-align: left;
  }

  .logline {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 600px) {
  .container {
    padding: 0 18px;
  }

  .section {
    padding: 40px 0;
  }

  .hero {
    padding-top: 34px;
  }

  .hero__stats {
    gap: 20px 28px;
  }

  .stat b {
    font-size: 24px;
  }

  .section__head {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .product-card__body {
    padding: 11px 12px 13px;
    gap: 4px;
  }

  .product-card__name {
    font-size: 13.5px;
    min-height: 36px;
  }

  .product-card__sku {
    font-size: 10.5px;
  }

  .price__value {
    font-size: 19px;
  }

  .price__old {
    font-size: 11px;
  }

  .product-card .btn--sm {
    padding: 7px 8px;
    font-size: 12px;
  }

  .cat-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .cat-card__body {
    padding: 11px 12px 13px;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }

  .cat-card__name {
    font-size: 13.5px;
  }

  .features {
    grid-template-columns: 1fr;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .footer__grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .kpi-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .kpi {
    padding: 14px;
  }

  .kpi__value {
    font-size: 24px;
  }

  .admin-tabs {
    gap: 0;
  }

  .admin-tab {
    padding: 9px 10px;
    font-size: 12.5px;
  }

  .modal__dialog {
    padding: 20px;
  }

  .buybox__value {
    font-size: 28px;
  }

  .discount-banner b {
    font-size: 21px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

/* --------------------------------------------------------------------------
   Дополнения: шапка, админ-табы, таблицы
   -------------------------------------------------------------------------- */

.header__auth {
  display: flex;
  align-items: center;
  gap: 8px;
}

.admin-tabs a.admin-tab {
  display: inline-flex;
  align-items: center;
}

.tablewrap .table {
  min-width: 560px;
}

.admin-grid .tablewrap .table {
  min-width: 460px;
}

.empty .btn + .btn {
  margin-left: 8px;
}

.auth__demo code {
  white-space: nowrap;
}

.auth__demo b {
  color: var(--ink);
}

.panel h4 {
  font-family: var(--font-body);
}

.modal__content .tablewrap {
  border-radius: 12px;
}

.form-success,
.form-error {
  line-height: 1.45;
}

@media (max-width: 700px) {
  .hide-sm {
    display: none !important;
  }

  .topbar__actions {
    gap: 4px;
  }
}
