.search { position: relative; display: flex; gap: 8px; margin: 2px 0 14px; }
.search .icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: #9aa2af; width: 18px; height: 18px; }
.search input {
  border: 0;
  background: #f4f6f9;
  box-shadow: inset 0 0 0 1px #eef1f5;
  color: var(--text);
  padding-left: 42px;
}
.promo {
  min-height: 148px;
  padding: 18px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(111,174,164,.88), rgba(111,174,164,.28)),
    linear-gradient(135deg, #dbeee9, #f6eee0);
  color: white;
}
.promo strong { display: block; max-width: 230px; font-size: 24px; line-height: 1.08; letter-spacing: 0; }
.promo span { display: block; margin-top: 10px; max-width: 210px; font-weight: 650; opacity: .93; }
.section-head { display: flex; align-items: center; gap: 8px; margin: 18px 0 10px; }
.section-head h2 { margin: 0; flex: 1; font-size: 20px; letter-spacing: 0; }
.link-button { min-height: auto; padding: 0; background: transparent; color: var(--blue-dark); box-shadow: none; font-size: 13px; }
.products-head { position: relative; z-index: 3; }
.sort-menu { position: relative; }
.sort-toggle { width: 38px; min-width: 38px; min-height: 38px; padding: 0; border-radius: 14px; background: #f5f7f8; color: #687080; box-shadow: none; }
.sort-toggle .icon { width: 19px; height: 19px; }
.sort-options { position: absolute; top: 44px; right: 0; width: 178px; padding: 6px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: 0 14px 32px rgba(69,76,95,.16); }
.sort-options button { width: 100%; min-height: 38px; padding: 8px 10px; border-radius: 12px; background: transparent; color: var(--text); box-shadow: none; text-align: left; font-size: 13px; font-weight: 760; }
.sort-options button:hover { background: #f6f7f9; }
.category-scroll { position: relative; overflow: hidden; }
.category-scroll::after { content: ""; position: absolute; top: 0; right: 0; bottom: 0; width: 28px; pointer-events: none; background: linear-gradient(90deg, rgba(255,255,255,0), var(--screen)); }
.category-strip { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(72px, 1fr); gap: 10px; overflow-x: auto; padding: 1px 18px 4px 1px; scrollbar-width: none; -ms-overflow-style: none; }
.category-strip::-webkit-scrollbar { display: none; }
.category-chip { min-height: 86px; padding: 0; background: transparent; color: var(--text); box-shadow: none; border-radius: 0; display: grid; justify-items: center; align-content: start; gap: 7px; font-size: 12px; font-weight: 760; }
.category-chip span { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; background: #edf7f4; color: var(--accent-dark); border: 2px solid transparent; }
.category-chip:nth-child(2n) span { background: #f5eeed; color: #c48d98; }
.category-chip:nth-child(3n) span { background: #eef0fb; color: var(--blue-dark); }
.category-chip.active span { border-color: currentColor; }
.category-chip .icon { width: 27px; height: 27px; }
.category-chip img { width: 34px; height: 34px; object-fit: contain; }
.category-chip strong { max-width: 78px; line-height: 1.15; overflow-wrap: anywhere; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.product-card {
  position: relative;
  overflow: hidden;
  display: grid;
  border: 0;
  box-shadow: none;
  background: transparent;
}
.product-edit-link {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,.92);
  color: #586071;
  box-shadow: 0 8px 18px rgba(69,76,95,.16);
}
.product-edit-link .icon { width: 17px; height: 17px; }
.gallery-wrap { position: relative; }
.detail-edit-link { top: 12px; right: 12px; width: 40px; height: 40px; }
.product-card img, .product-card .placeholder {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  border-radius: 20px;
  box-shadow: 0 9px 20px rgba(69,76,95,.10);
}
.product-card-body { padding: 9px 4px 2px; display: grid; gap: 7px; }
.product-title { font-weight: 760; line-height: 1.22; min-height: 38px; font-size: 14px; }
.product-card .price { font-size: 16px; }
.product-card .muted { font-size: 12px; }
.product-buy-row { display: flex; align-items: center; gap: 8px; min-height: 42px; }
.product-price { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 5px; flex-wrap: wrap; }
.product-card button {
  flex: 0 0 38px;
  width: 42px;
  min-width: 38px;
  min-height: 38px;
  padding: 0;
  border-radius: 50%;
  font-size: 0;
  background: var(--accent);
  box-shadow: 0 8px 16px rgba(95,167,157,.22);
}
.product-card button::after { content: ""; }
.product-card button .icon { width: 22px; height: 22px; }
.product-card button.is-added { background: var(--blue); }
.product-card button.is-added .icon { display: none; }
.product-card button.is-added::after { content: "✓"; font-size: 22px; }
.product-detail { gap: 12px; }
.page.product-detail { padding-bottom: 184px; }
.gallery-main {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  border-radius: 24px;
  background: #eef1f5;
  box-shadow: 0 12px 30px rgba(69,76,95,.12);
  touch-action: pan-y;
  user-select: none;
  -webkit-user-drag: none;
}
.thumbs { display: flex; gap: 8px; overflow: auto; padding: 2px; }
.thumbs img { width: 58px; height: 58px; object-fit: cover; border-radius: 15px; border: 2px solid transparent; }
.thumbs img.active { border-color: var(--accent); }
.detail-panel { padding: 16px; display: grid; gap: 10px; box-shadow: none; }
.detail-panel h1 { margin: 0; font-size: 23px; line-height: 1.18; letter-spacing: 0; }
.detail-panel p { margin: 0; color: #687080; line-height: 1.45; }
#description { white-space: pre-wrap; }
.product-action {
  position: fixed;
  left: 50%;
  bottom: 68px;
  transform: translateX(-50%);
  width: min(100%, 430px);
  padding: 10px 14px;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(12px);
  z-index: 9;
}
.product-action button { width: 100%; }
.product-action button, .icon-text { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.product-action button .icon, .icon-text .icon { width: 19px; height: 19px; }
.cart-notice { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 750; }
.cart-list { display: grid; }
.cart-line {
  display: grid;
  grid-template-columns: 82px 1fr auto;
  grid-template-areas:
    "image info remove"
    "image info qty";
  align-items: center;
  column-gap: 12px;
  row-gap: 8px;
  padding: 12px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  box-shadow: none;
}
.cart-line img, .cart-line .placeholder { grid-area: image; width: 82px; height: 82px; object-fit: cover; border-radius: 16px; }
.cart-info { grid-area: info; align-self: stretch; display: grid; align-content: start; gap: 5px; min-width: 0; }
.cart-info strong { font-size: 14px; line-height: 1.25; }
.cart-info .price { font-size: 18px; }
.cart-remove { grid-area: remove; align-self: start; width: 36px; min-width: 36px; min-height: 36px; padding: 0; border-radius: 50%; background: transparent; color: #7d8491; box-shadow: none; }
.cart-remove .icon { width: 18px; height: 18px; }
.qty { grid-area: qty; justify-self: end; display: inline-grid; grid-template-columns: 32px 36px 32px; align-items: center; text-align: center; background: #f6f7f9; border-radius: 15px; overflow: hidden; }
.qty button { border-radius: 0; min-height: 34px; padding: 0; background: transparent; color: var(--text); box-shadow: none; }
.qty .icon { width: 16px; height: 16px; }
.checkout-bar {
  position: sticky;
  bottom: 76px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 14px;
  display: grid;
  gap: 12px;
  align-self: start;
  height: fit-content;
  box-shadow: 0 12px 30px rgba(69,76,95,.13);
}
.checkout-bar a, .checkout-bar button { width: 100%; }
.cart-total-row { display: flex; align-items: start; justify-content: space-between; gap: 12px; }
.cart-total-row strong, .cart-total-row .muted { display: block; }
.cart-total-row .price { white-space: nowrap; }
.checkout-form { padding: 16px; }
.profile-card { padding: 16px; }
.avatar-picker { place-items: center; text-align: center; cursor: pointer; }
.avatar {
  width: 108px;
  height: 108px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: linear-gradient(135deg, #e8f4f1, #eef1fb);
  color: var(--accent-dark);
  box-shadow: 0 12px 28px rgba(69,76,95,.12);
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar .icon { width: 42px; height: 42px; }
.avatar-action { display: inline-flex; align-items: center; gap: 7px; color: var(--blue-dark); font-weight: 800; }
.avatar-action .icon { width: 18px; height: 18px; }
@media (min-width: 700px) { .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
