/* =========================================================
   Интернет-магазин «Важен каждый» — отдельный сайт
   ========================================================= */

.store-body { background: #fbfbf9; }

.store-header .header-main { min-height: 78px; }
.store-header .header-logo { width: 190px; }
.store-badge {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--ok);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.store-nav { margin-left: 8px; }
.store-nav ul { display: flex; gap: 22px; }
.store-nav a { font-size: 14px; }
.store-header .header-actions { margin-left: auto; }

.store-hero {
  padding: 44px 0 54px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.store-hero__grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: center; }
.store-hero h1 { max-width: 720px; }
.store-hero .lead { max-width: 600px; margin-top: 16px; }
.store-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--ok);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.store-hero__note {
  justify-self: end;
  max-width: 330px;
  padding: 24px;
  border-radius: 24px;
  background: var(--navy);
  color: #fff;
}
.store-hero__note h2 { color: #fff; font-size: 18px; }
.store-hero__note p { margin-top: 8px; color: rgba(255,255,255,.78); font-size: 13px; font-weight: 300; }
.store-hero__note a { display: inline-block; margin-top: 14px; color: #d7f0e9; font-size: 13px; font-weight: 600; }

.store-catalog { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 40px; align-items: start; padding: 54px 0 80px; }
.store-sidebar { position: sticky; top: 104px; }
.filter-block { padding: 20px 0; border-bottom: 1px solid var(--line); }
.filter-block:first-child { padding-top: 0; }
.filter-block h3 { margin-bottom: 12px; font-size: 15px; }
.filter-list { display: flex; flex-direction: column; gap: 8px; }
.filter-list label { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 300; cursor: pointer; }
.filter-list input { width: 16px; height: 16px; accent-color: var(--navy); }
.price-row { display: flex; align-items: center; gap: 8px; }
.price-row input {
  width: 100%;
  height: 38px;
  padding: 0 10px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  font-size: 13px;
  outline: 0;
}
.price-row input:focus { border-color: var(--navy); }
.store-toolbar { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.store-toolbar p { color: var(--muted); font-size: 13px; }
.store-toolbar .select { margin-left: auto; }
.store-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }

.product-card { display: flex; flex-direction: column; overflow: hidden; border-radius: 22px; background: #fff; border: 1px solid var(--line); transition: .25s; }
.product-card:hover { box-shadow: 0 16px 40px rgba(34,34,33,.09); transform: translateY(-2px); }
.product-card__media { position: relative; aspect-ratio: 1 / 1; overflow: hidden; background: var(--soft); }
.product-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.product-card:hover .product-card__media img { transform: scale(1.035); }
.product-card__badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--navy);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.product-card__body { display: flex; flex-direction: column; flex: 1; gap: 8px; padding: 16px 18px 20px; }
.product-card__category { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .05em; }
.product-card h3 { font-size: 16px; }
.product-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 10px; }
.product-card__price { font-size: 18px; font-weight: 700; color: var(--navy); }
.product-card__price s { display: block; color: var(--muted); font-size: 12px; font-weight: 300; }
.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1.5px solid var(--line);
  border-radius: 50%;
  background: #fff;
  transition: .2s;
}
.icon-btn:hover { background: var(--navy); border-color: var(--navy); color: #fff; }
.icon-btn svg { width: 18px; height: 18px; }

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

.product-detail { display: grid; grid-template-columns: 1.05fr 1fr; gap: 54px; align-items: start; padding: 46px 0 76px; }
.product-gallery { display: grid; grid-template-columns: 82px minmax(0, 1fr); gap: 12px; }
.product-thumbs { display: flex; flex-direction: column; gap: 10px; }
.product-thumb { overflow: hidden; border: 1.5px solid transparent; border-radius: 14px; background: var(--soft); aspect-ratio: 1; }
.product-thumb.is-active { border-color: var(--navy); }
.product-thumb img { width: 100%; height: 100%; object-fit: cover; }
.product-main-img { overflow: hidden; border-radius: 26px; background: var(--soft); aspect-ratio: 1 / 1; }
.product-main-img img { width: 100%; height: 100%; object-fit: cover; }
.product-info h1 { font-family: var(--font-display); font-size: clamp(38px, 4vw, 56px); font-weight: 400; line-height: 1; }
.product-info__category { margin-bottom: 8px; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.product-price { margin-top: 16px; font-size: 30px; font-weight: 700; color: var(--navy); }
.product-price s { margin-left: 8px; color: var(--muted); font-size: 16px; font-weight: 300; }
.product-desc { margin-top: 16px; font-weight: 300; color: #4a4a47; }
.product-option { margin-top: 22px; }
.product-option > span { display: block; margin-bottom: 8px; font-size: 13px; font-weight: 600; }
.option-row { display: flex; flex-wrap: wrap; gap: 8px; }
.option-btn {
  min-width: 48px;
  height: 40px;
  padding: 0 14px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: #fff;
  font-size: 13px;
}
.option-btn.is-active { border-color: var(--navy); background: var(--navy); color: #fff; }
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 999px; overflow: hidden; }
.qty button { width: 40px; height: 42px; border: 0; background: #fff; font-size: 18px; }
.qty input { width: 46px; height: 42px; border: 0; text-align: center; font-size: 14px; outline: 0; }
.product-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.product-actions .btn { flex: 1; min-width: 180px; }
.product-meta { display: grid; gap: 8px; margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--muted); }
.product-meta span { display: flex; gap: 8px; }
.product-meta b { color: var(--ink); font-weight: 600; }

/* ---------- Корзина ---------- */

.cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 40px; align-items: start; padding: 44px 0 76px; }
.cart-list { border-top: 1px solid var(--line); }
.cart-item { display: grid; grid-template-columns: 92px minmax(0, 1fr) 120px 110px 44px; gap: 14px; align-items: center; padding: 18px 0; border-bottom: 1px solid var(--line); }
.cart-item__img { width: 92px; height: 92px; border-radius: 14px; object-fit: cover; background: var(--soft); }
.cart-item h3 { font-size: 15px; }
.cart-item p { margin-top: 3px; color: var(--muted); font-size: 12px; }
.cart-item .qty { justify-self: start; }
.cart-item__sum { justify-self: end; font-weight: 700; }
.cart-item__remove { width: 36px; height: 36px; border: 0; border-radius: 50%; background: var(--soft); font-size: 16px; }
.cart-item__remove:hover { background: #f6dede; color: var(--danger); }
.cart-aside { position: sticky; top: 104px; padding: 24px; border: 1px solid var(--line); border-radius: 24px; background: #fff; }
.cart-aside h2 { font-size: 20px; }
.summary-row { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; font-size: 14px; }
.summary-row--total { margin-top: 6px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 20px; font-weight: 700; color: var(--navy); }
.cart-aside .btn { margin-top: 16px; }
.cart-note { margin-top: 12px; color: var(--muted); font-size: 11.5px; }

/* ---------- Оформление ---------- */

.checkout-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 44px; align-items: start; padding: 44px 0 76px; }
.checkout-section { padding: 26px; border: 1px solid var(--line); border-radius: 24px; background: #fff; }
.checkout-section + .checkout-section { margin-top: 18px; }
.checkout-section h2 { margin-bottom: 18px; font-family: var(--font-display); font-size: 32px; font-weight: 400; }
.delivery-list, .payment-list { display: grid; gap: 10px; }
.delivery-option, .payment-option { display: flex; align-items: flex-start; gap: 10px; padding: 14px; border: 1.5px solid var(--line); border-radius: 14px; font-size: 14px; cursor: pointer; }
.delivery-option:has(input:checked), .payment-option:has(input:checked) { border-color: var(--navy); background: var(--green-soft); }
.delivery-option input, .payment-option input { width: 17px; height: 17px; margin-top: 2px; accent-color: var(--navy); }
.delivery-option small, .payment-option small { display: block; margin-top: 3px; color: var(--muted); font-size: 11.5px; font-weight: 300; }
.checkout-summary { position: sticky; top: 104px; padding: 24px; border: 1px solid var(--line); border-radius: 24px; background: #fff; }
.checkout-item { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.checkout-item:last-of-type { border-bottom: 0; }
.checkout-item img { width: 56px; height: 56px; border-radius: 10px; object-fit: cover; background: var(--soft); }
.checkout-item small { display: block; color: var(--muted); font-size: 11px; }

/* ---------- Успех ---------- */

.success-box { max-width: 680px; margin: 56px auto 80px; padding: 44px; border: 1px solid var(--line); border-radius: 30px; background: #fff; text-align: center; }
.success-box__icon { display: inline-grid; place-items: center; width: 86px; height: 86px; margin-bottom: 18px; border-radius: 50%; background: var(--green-soft); color: var(--ok); font-size: 38px; }
.success-box h1 { margin-bottom: 12px; }
.success-box p { color: var(--muted); font-weight: 300; }
.success-box .btn { margin-top: 22px; }

.store-footer { background: var(--navy); color: #fff; padding: 42px 0 26px; margin-top: 30px; }
.store-footer__top { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.store-footer h3 { color: #fff; font-size: 14px; margin-bottom: 10px; }
.store-footer p, .store-footer a { color: rgba(255,255,255,.72); font-size: 13px; font-weight: 300; }
.store-footer a:hover { color: #fff; }
.store-footer__cols { display: flex; gap: 60px; flex-wrap: wrap; }
.store-footer__cols p { margin: 0 0 1px; }
.store-footer__cols a { display: inline-block; padding: 3px 0; }
.store-footer__bottom { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-top: 30px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.16); font-size: 11.5px; color: rgba(255,255,255,.78); }

.store-breadcrumbs { margin: 22px 0 0; }

@media (max-width: 1120px) {
  .store-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .store-catalog { grid-template-columns: 220px minmax(0, 1fr); gap: 28px; }
  .product-detail { gap: 34px; }
  .cart-layout, .checkout-layout { grid-template-columns: minmax(0, 1fr) 330px; gap: 28px; }
}

@media (max-width: 980px) {
  .store-header .header-actions .btn--ghost { display: none; }
  .store-header .cart-link > span:not(.cart-count) { display: none; }
  .store-header .header-actions { gap: 6px; }
  .store-nav { display: none; }
  .store-hero__grid { grid-template-columns: 1fr; }
  .store-hero__note { justify-self: start; }
  .store-catalog { grid-template-columns: 1fr; }
  .store-sidebar { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; padding: 18px; border-radius: 18px; background: #fff; border: 1px solid var(--line); }
  .filter-block { padding: 12px 0; border-bottom: 0; }
  .product-detail { grid-template-columns: 1fr; }
  .cart-layout, .checkout-layout { grid-template-columns: 1fr; }
  .cart-aside, .checkout-summary { position: static; }
}

@media (max-width: 680px) {
  .store-badge { display: none; }
  .store-header .header-logo { width: 160px; }
  .store-hero { padding: 28px 0 38px; }
  .store-catalog { padding: 34px 0 54px; }
  .store-sidebar { grid-template-columns: 1fr; }
  .store-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .product-card__body { padding: 12px 12px 14px; }
  .product-card h3 { font-size: 14px; }
  .product-card__price { font-size: 15px; }
  .product-card .icon-btn { width: 36px; height: 36px; }
  .store-toolbar { flex-wrap: wrap; }
  .store-toolbar .select { margin-left: 0; width: 100%; }
  .product-gallery { grid-template-columns: 1fr; }
  .product-thumbs { flex-direction: row; order: 2; }
  .product-thumb { width: 70px; }
  .product-main-img { order: 1; }
  .cart-item { grid-template-columns: 72px minmax(0, 1fr) auto; }
  .cart-item__img { width: 72px; height: 72px; }
  .cart-item .qty { grid-column: 2; }
  .cart-item__sum { grid-column: 3; grid-row: 1; }
  .cart-item__remove { grid-column: 3; grid-row: 2; justify-self: end; }
  .checkout-section { padding: 20px; }
  .success-box { margin: 28px auto 50px; padding: 28px 20px; }
  .store-footer__cols { gap: 28px; }
}

@media (max-width: 460px) {
  .store-grid { grid-template-columns: 1fr; }
}
