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

:root {
  --accent: #3B7DDD;
  --accent-rgb: 59, 125, 221;
  --accent-600: #6FA4DB;
  --accent-600-rgb: 111, 164, 219;
  --accent-300: #86B6ED;
  --accent-300-rgb: 134, 182, 237;
  --accent-200: #b9d8f3;
  --accent-200-rgb: 185, 216, 243;
  --accent-100: #dcf0f9;
  --accent-100-rgb: 220, 240, 249;
  --accent-border: #95c0ef;
  --accent-border-rgb: 149, 192, 239;
  --accent-soft-border: #e7f3fc;
  --accent-soft-border-rgb: 231, 243, 252;
  --accent-dot: #c4dff5;
  --accent-dot-rgb: 196, 223, 245;
  --bg-grad-from: #dcf0f9;
  --bg-grad-to: #89b8ee;
  --header-bg: transparent;
  --header-title-color: #0b1220;
}

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.86) 0, rgba(255, 255, 255, 0) 34%),
    linear-gradient(180deg, var(--bg-grad-from), var(--bg-grad-to));
  color: #000000;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Lock background scroll when modal is open */
html.modal-open,
body.modal-open {
  overflow: hidden;
  height: 100%;
}

#app {
  max-width: 420px;
  margin: 0 auto;
  padding: 0 0 32px;
  width: 100%;
  min-height: 100vh;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.10);
}

body.has-bottom-bar #app {
  padding-bottom: 94px;
}

.bottom-bar {
  position: fixed;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  width: calc(100% - 24px);
  max-width: 420px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(var(--accent-soft-border-rgb), 0.95);
  border-radius: 16px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.10);
  backdrop-filter: blur(10px);
  display: flex;
  gap: 10px;
  padding: 10px;
  z-index: 20;
}

.bottom-bar-btn {
  flex: 1;
  border: 1px solid rgba(var(--accent-soft-border-rgb), 0.95);
  border-radius: 14px;
  background: #ffffff;
  color: #000000;
  padding: 10px 10px;
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  font-weight: 600;
}

.bottom-bar-btn:active {
  transform: scale(0.99);
}

.bottom-bar-ic {
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}

.bottom-bar-ic svg {
  width: 20px;
  height: 20px;
}

.bottom-bar-text {
  font-size: 13px;
}

.news-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.news-item {
  background: #ffffff;
  border: 1px solid rgba(var(--accent-soft-border-rgb), 0.95);
  border-radius: 14px;
  padding: 12px;
  display: flex;
  gap: 10px;
  align-items: center;
}

.news-item:active {
  transform: scale(0.99);
}

.news-item-thumb {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: #F8FAFC;
  border: 1px solid rgba(var(--accent-soft-border-rgb), 0.95);
  object-fit: cover;
  flex: 0 0 auto;
}

.news-item-meta {
  flex: 1;
  min-width: 0;
}

.news-item-title {
  font-weight: 700;
  font-size: 13px;
  line-height: 1.25;
  word-break: break-word;
}

.news-item-date {
  margin-top: 4px;
  font-size: 12px;
  color: rgba(0, 0, 0, 0.55);
}

.app-header {
  margin-bottom: 10px;
}

.app-header-top {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  flex-wrap: nowrap;
  padding: 10px 15px 14px;
  background: var(--header-bg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.62);
  backdrop-filter: blur(14px);
  min-height: 68px;
}

.app-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  justify-content: flex-end;
  margin-left: auto;
}

/* Header icon pills (like reference) */
.btn-icon {
  position: relative;
  width: 42px;
  height: 42px;
  padding: 0;
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.78);
  color: #000000;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}
.btn-icon .icon {
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn-icon svg {
  width: 22px;
  height: 22px;
}
.btn-icon:active {
  transform: scale(0.98);
}

.btn-cart-icon {
  background: #ffffff;
  border-color: rgba(var(--accent-soft-border-rgb), 0.9);
  color: #000000;
}

.btn-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: #22c55e;
  color: #ffffff;
  border: 2px solid rgba(var(--accent-100-rgb), 1);
  font-size: 12px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.app-logo-wrap {
  display: flex;
  align-items: center;
  min-height: 40px;
  min-width: 0;
  flex: 1 1 auto;
  gap: 14px;
}

.app-logo {
  height: 48px;
  width: 48px;
  max-width: 48px;
  object-fit: contain;
  flex: 0 0 48px;
}

.app-title{
  font-weight: 700;
  font-size: 15px;
  color: var(--header-title-color);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1 1 auto;
  min-width: 0;
}

.section-title {
  font-size: 24px;
  font-weight: 700;
  margin: 15px 15px 0;
  text-align: center;
}

/* По запросу: скрыть заголовок "Меню товаров" */
#catalog-view .section-title {
  display: none;
}

.products-section {
  background: rgba(255, 255, 255, 0.92);
  border-radius: 28px 28px 0 0;
  margin-top: -10px;
  padding: 14px 15px 22px;
  overflow: visible;
  box-shadow: 0 -16px 36px rgba(15, 23, 42, 0.08);
  min-height: calc(100vh - 68px);
}

.catalog-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
  padding: 16px;
  border-radius: 24px;
  color: #ffffff;
  background:
    radial-gradient(circle at 88% 18%, rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0) 32%),
    linear-gradient(135deg, var(--accent), var(--accent-600));
  box-shadow: 0 16px 32px rgba(var(--accent-rgb), 0.24);
}

.catalog-hero-kicker {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.78;
}

.catalog-hero-title {
  margin-top: 5px;
  font-size: 20px;
  font-weight: 850;
  line-height: 1.1;
}

.catalog-hero-text {
  margin-top: 7px;
  max-width: 245px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  opacity: 0.86;
}

.catalog-hero-badge {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.32);
  font-size: 14px;
  font-weight: 900;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.top-tabs {
  display: flex;
  align-items: center;
  gap: 0;
  height: 40px;
  margin: 4px 0 0;
  padding: 4px;
  background: var(--accent-200);
  border-radius: 40px;
}

.top-tab {
  flex: 1 1 0;
  height: 34px;
  border: none;
  background: transparent;
  border-radius: 37px;
  font-family: Ubuntu, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #000000;
  cursor: pointer;
}

.top-tab--active {
  background: #ffffff;
}

.categories-strip {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  overflow-y: hidden;
  max-width: 100%;
  min-width: 0;
  padding: 10px 0 10px;
  margin-bottom: 0;
  cursor: grab;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.categories-strip::-webkit-scrollbar {
  display: none;
}

.categories-strip.categories-dragging {
  cursor: grabbing;
}

.categories-strip--secondary {
  margin-top: 4px;
}

.category-chip {
  flex: 0 0 auto;
  padding: 10px 15px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.86);
  color: #000000;
  border: 1px solid rgba(var(--accent-soft-border-rgb), 0.95);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
  white-space: nowrap;
}

.category-chip--active {
  background: var(--accent);
  color: #ffffff;
  border-color: var(--accent);
  box-shadow: 0 10px 24px rgba(var(--accent-rgb), 0.22);
}

.catalog-filters-row {
  display: flex;
  justify-content: flex-start;
  margin: 8px 0 8px;
}

.catalog-filters-btn {
  border: 1px solid rgba(var(--accent-soft-border-rgb), 0.95);
  background: rgba(255, 255, 255, 0.92);
  color: #000;
  border-radius: 999px;
  padding: 8px 12px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 13px;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.08);
}

.catalog-filters-text {
  font-weight: 600;
  font-size: 13px;
  color: #000;
}

.catalog-filters-btn:active {
  transform: scale(0.99);
}

.catalog-filters-ic {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}

.catalog-filters-ic svg {
  width: 18px;
  height: 18px;
}

.catalog-filters-badge {
  background: var(--accent);
  color: #fff;
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 12px;
  line-height: 16px;
}

.filters-group {
  margin: 12px 0 0;
}

.filters-group-title {
  font-weight: 700;
  margin-bottom: 8px;
}

.filters-checks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 10px;
}

.filters-check {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  font-size: 13px;
}

.filters-range {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.filters-range input {
  width: 100%;
}

@media (max-width: 380px) {
  .filters-checks {
    grid-template-columns: 1fr;
  }
}


.banners-wrap {
  margin-bottom: 12px;
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid var(--accent-soft-border);
}

.banners-track {
  display: flex;
  transition: transform 0.3s ease;
  touch-action: pan-y pinch-zoom;
  width: 100%;
  overflow: visible;
}

.banners-track .banner-slide {
  flex: 0 0 100%;
  min-width: 100%;
  width: 100%;
  cursor: pointer;
  border-radius: 0;
  overflow: visible;
  background: transparent;
  border: none;
}

.banners-track .banner-slide img {
  width: 100%;
  display: block;
  aspect-ratio: 2 / 1;
  object-fit: cover;
  border-radius: 12px;
}

.banners-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 8px 0 6px;
  margin-top: 0;
}

.banners-dots .dot {
  width: 20px;
  height: 6px;
  border-radius: 3px;
  background: transparent;
  border: 1px solid var(--accent-dot);
  padding: 0;
  cursor: pointer;
  transition: background 0.2s;
}

.banners-dots .dot.active {
  background: var(--accent-dot);
  border: 1px solid var(--accent-dot);
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

/* Плашка: включён фильтр каталога услуг по мастеру */
.services-specialist-filter-banner {
  grid-column: 1 / -1;
  width: 100%;
  margin-bottom: 4px;
  padding: 12px 14px;
  border-radius: 14px;
  background: linear-gradient(145deg, #ecfdf5 0%, #ffffff 55%);
  border: 1px solid #6ee7b7;
  box-sizing: border-box;
}
.services-specialist-filter-banner__kicker {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #047857;
  margin: 0 0 6px;
}
.services-specialist-filter-banner__name {
  font-size: 17px;
  font-weight: 800;
  color: #111827;
  margin: 0 0 4px;
  line-height: 1.25;
  word-break: break-word;
}
.services-specialist-filter-banner__meta {
  font-size: 13px;
  color: #374151;
  margin: 0 0 8px;
  line-height: 1.3;
}
.services-specialist-filter-banner__hint {
  font-size: 12px;
  color: #4b5563;
  line-height: 1.35;
  margin: 0 0 10px;
}
.services-specialist-filter-banner__count {
  font-size: 13px;
  font-weight: 600;
  color: #065f46;
  margin: 0 0 10px;
}
.services-specialist-filter-banner .btn {
  width: 100%;
  font-weight: 700;
}

.products-grid--promotions {
  margin-top: 10px;
}

.product-card {
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
  max-width: 240px;
  width: 100%;
  border-radius: 26px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.08);
  border: 1px solid rgba(226, 232, 240, 0.96);
  justify-self: center;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  transition: transform 0.14s ease, box-shadow 0.14s ease, border-color 0.14s ease;
}

.product-card:active {
  transform: translateY(1px) scale(0.99);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
}

.product-image {
  width: 100%;
  height: 100%;
  border-radius: 22px;
  object-fit: contain;
  background: transparent;
  display: block;
  margin-bottom: 0;
}

.product-image-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #ffffff;
  height: 132px;
  padding: 8px;
}

.product-image-badges {
  position: absolute;
  left: 10px;
  top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  z-index: 2;
  pointer-events: none;
}

.product-image-badges .product-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.22);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.product-image-badges .product-badge--hit {
  background: rgba(22, 163, 74, 0.92); /* green */
}

.product-image-badges .product-badge--new {
  background: rgba(37, 99, 235, 0.92); /* blue */
}

.product-image-badges .product-badge--vegan {
  background: rgba(14, 165, 233, 0.92); /* light blue */
}

.product-name {
  font-size: 14px;
  font-weight: 800;
  line-height: 1.3;
  height: calc(1.3em * 2);
  display: -webkit-box;
  line-clamp: 2;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
  color: #111827;
}

.service-card .product-name {
  height: auto;
  min-height: calc(1.35em * 2);
  line-height: 1.35;
  padding-top: 1px;
}

.product-card-props {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 24px;
}

.product-card-prop {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  border-radius: 999px;
  background: #f1f5f9;
  color: #475569;
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
}

.product-card-variants {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: -4px;
}

.product-card-variant-row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.product-card-variant-chip {
  border: 1px solid #d7dee9;
  background: #ffffff;
  color: #111827;
  border-radius: 7px;
  padding: 4px 7px;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.1;
  white-space: nowrap;
}

.product-card-variant-chip.is-active {
  border-color: #e07a3f;
  background: #e07a3f;
  color: #ffffff;
}

.product-preview-text {
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.45;
  display: -webkit-box;
  line-clamp: 2;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: calc(1.45em * 2);
}

.product-modal-props {
  font-size: 13px;
  opacity: 0.9;
  margin-bottom: 8px;
}

.product-card-badges {
  min-height: 0;
}

.product-modal-props .product-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #EEF2FF;
  color: var(--accent);
}

.product-footer {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: auto;
  min-width: 0;
}

.product-price {
  font-size: 16px;
  opacity: 1;
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  flex-wrap: nowrap;
  min-height: 24px;
}

.product-price-old {
  font-size: 13px;
  color: #9CA3AF;
  text-decoration: line-through;
  opacity: 1;
}

.product-price-new {
  font-size: 17px;
  font-weight: 900;
  line-height: 1.2;
  white-space: nowrap;
  color: #0f172a;
}

/* Product-card buttons only (do not affect other app buttons) */
.product-card .btn {
  height: 38px;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 800;
  padding: 0 12px;
}

.product-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.product-order-btn.btn.btn-primary {
  flex: 1 1 auto;
  min-width: 0;
  margin-top: 0;
  background: var(--accent);
  border: 1px solid var(--accent);
  color: #ffffff;
  box-shadow: 0 10px 18px rgba(var(--accent-rgb), 0.22);
}

.product-fav-icon-btn.btn.btn-small.btn-fav {
  width: 36px;
  min-width: 36px;
  height: 36px;
  padding: 0;
  margin-top: 0;
  background: transparent;
  border: 1px solid var(--accent-600);
  color: var(--accent-600);
}

.product-fav-icon-btn svg {
  width: 18px;
  height: 18px;
  display: block;
}

.product-fav-icon-btn svg path {
  fill: none;
  stroke: currentColor;
}

.product-fav-icon-btn.is-active {
  background: #fee2e2;
  color: #ef4444;
  border-color: #ef4444;
}

.product-fav-icon-btn.is-active svg path {
  fill: #ef4444;
  stroke: #ef4444;
}

/* Promotion cards buttons: show 2 buttons side-by-side without overflow. */
.promotion-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.promotion-actions .btn {
  width: auto !important;
  flex: 0 0 auto;
  margin-top: 0 !important;
  width: 100% !important;
}

.promotion-actions .btn.is-disabled {
  opacity: 0.55;
  pointer-events: none;
}

.promo-preview-description {
  min-height: calc(1.3em * 4);
  line-height: 1.3;
  display: -webkit-box;
  line-clamp: 4;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 2px solid var(--accent-border);
  padding: 14px 16px;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  background: #ffffff;
  color: #000000;
  transition: transform 0.08s ease, background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn-primary {
  background: var(--accent-300);
  border-color: var(--accent-300);
  color: #ffffff;
}

.btn-primary:active {
  transform: scale(0.97);
}

.btn-cart {
  padding-inline: 10px;
  font-size: 12px;
}

.btn-small {
  padding: 14px 16px;
  font-size: 18px;
  background: #ffffff;
  color: #000000;
  border: 2px solid var(--accent-border);
}

.products-empty {
  margin: 14px 0 0;
  padding: 22px 16px;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  color: #64748b;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 20px;
  opacity: 1;
}

.products-error {
  color: #dc2626;
}

.hidden {
  display: none !important;
}

.legal-footer {
  margin: 18px auto 6px;
  padding: 0 16px;
  text-align: center;
  color: #94a3b8;
  font-size: 11px;
  line-height: 1.5;
}

.legal-footer a,
.legal-footer-link {
  color: #64748b;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-footer-link {
  display: inline-block;
  margin-top: 4px;
  padding: 0;
  border: none;
  background: transparent;
  font: inherit;
  cursor: pointer;
}

.legal-modal-content {
  max-width: 560px;
}

.legal-modal-body {
  color: #334155;
  font-size: 13px;
  line-height: 1.55;
}

.legal-modal-body a {
  color: var(--accent);
  text-decoration: underline;
}

/* Modal */

.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 24, 39, 0.35);
}

.modal-content {
  position: relative;
  background: #ffffff;
  border-radius: 18px;
  padding: 18px 16px 16px;
  max-width: 520px;
  width: min(520px, calc(100% - 32px));
  box-shadow: 0 12px 30px rgba(15,23,42,0.12);
  border: 1px solid #E5E7EB;
  /* Allow scrolling inside modal on long content (mobile) */
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.modal-title {
  margin: 0 0 6px;
  font-size: 16px;
}

.modal-close {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  border: none;
  background: #ffffff;
  color: #111827;
  border: 1px solid #E5E7EB;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.modal-product {
  font-size: 14px;
  margin-bottom: 12px;
  opacity: 0.9;
}

/* Cart items list should expand naturally (без внутреннего скролла) */
#cart-items {
  overflow-y: visible;
  padding-right: 4px;
  max-height: none;
}

/* --- Responsive --- */

/* Extra small phones */
@media (max-width: 360px) {
  #app {
    padding: 12px 10px 24px;
  }
  .app-header-top {
    flex-wrap: wrap;
    row-gap: 10px;
  }
  .app-header-actions {
    width: 100%;
    justify-content: flex-end;
    flex-wrap: wrap;
  }
  .app-logo {
    max-width: min(180px, 70vw);
  }
  .products-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .btn {
    padding: 7px 12px;
  }
  .btn-cart {
    padding-inline: 10px;
  }
}

/* Phones */
@media (max-width: 480px) {
  #app {
    max-width: 100%;
  }
  .app-header-top {
    justify-content: flex-start;
  }
  .app-header-actions {
    width: auto;
  }
  .app-logo-wrap{
    flex: 1 1 auto;
  }
  .app-title{
    max-width: none;
  }

  /* Fullscreen modal on phone */
  .modal {
    align-items: stretch;
    justify-content: stretch;
  }
  .modal-content {
    width: 100%;
    max-width: 100%;
    max-height: 100dvh;
    border-radius: 18px 18px 0 0;
    margin-top: auto;
    padding: 16px 14px 14px;
  }
  #cart-items { max-height: none; }
}

/* Tablets / wide */
@media (min-width: 700px) {
  .products-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .app-logo {
    max-width: 260px;
  }
}

.cart-total {
  margin-top: 10px;
  padding: 12px 14px;
  border-radius: 16px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  font-weight: 900;
  color: #0f172a;
}

.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 8px;
  padding: 10px;
  border-radius: 16px;
  background: #ffffff;
  border: 1px solid #eef2f7;
}

.cart-item-title {
  font-size: 14px;
  font-weight: 800;
  color: #111827;
}

.cart-item-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
}

.cart-item-price {
  opacity: 0.85;
}

.cart-item-qty {
  opacity: 0.85;
}

.order-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.form-label {
  font-size: 13px;
  opacity: 0.9;
}

input[type="tel"] {
  border-radius: 999px;
  border: 1px solid #E5E7EB;
  background: #ffffff;
  color: #111827;
  padding: 8px 12px;
  font-size: 14px;
  outline: none;
}

input[type="tel"]:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(var(--accent-rgb), 0.15);
}

.form-helper {
  margin: 4px 0 0;
  font-size: 11px;
  opacity: 0.7;
}

.address-extras-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (min-width: 700px) {
  .address-extras-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.address-extra-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.address-extra-label {
  font-size: 11px;
  opacity: 0.75;
}

.billing-highlight {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(var(--accent-rgb), 0.18), 0 12px 30px rgba(15, 23, 42, 0.10);
  animation: billingPulse 1.2s ease-in-out 0s 3;
}

@keyframes billingPulse {
  0% { transform: translateY(0); }
  50% { transform: translateY(-1px); }
  100% { transform: translateY(0); }
}

.payment-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}

.btn-secondary {
  background: #ffffff;
  color: #000000;
  border: 1px solid var(--accent-border);
}

.btn-fav {
  background: #ffffff;
  color: #000000;
  border: 2px solid var(--accent-300);
}

.view {
  width: 100%;
}

/* --- Cabinet (match reference style) --- */
#cabinet-view .app-header {
  margin-bottom: 12px;
  padding: 15px 15px 0;
}

#favorites-view .app-header {
  margin-bottom: 12px;
  padding: 15px 15px 0;
}

#cabinet-view .cabinet-header,
#favorites-view .cabinet-header {
  margin: 0 0 12px;
  align-items: center;
}

#cabinet-view .cabinet-title,
#favorites-view .cabinet-title {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  flex: 1 1 auto;
  min-width: 0;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#cabinet-view #cabinet-back.btn.btn-small,
#favorites-view #favorites-back.btn.btn-small {
  height: 38px;
  width: auto;
  min-width: 38px;
  padding: 0 10px;
  border-radius: 12px;
  border: 1px solid rgba(149, 192, 239, 0.55);
  background: rgba(255, 255, 255, 0.9);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  white-space: nowrap;
  flex: 0 0 auto;
  font-size: 13px;
}

#cabinet-view .order-card-actions .btn.btn-small {
  width: auto;
  height: 40px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid rgba(149, 192, 239, 0.55);
  background: rgba(255, 255, 255, 0.95);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

#cabinet-view .order-card-actions {
  flex-wrap: wrap;
}

#cabinet-view .tab-btn:focus,
#cabinet-view .tab-btn:focus-visible,
#cabinet-view .btn:focus,
#cabinet-view .btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px rgba(134, 182, 237, 0.35);
}

#cabinet-view .profile-card {
  border-radius: 18px;
  border: 1px solid rgba(229, 231, 235, 1);
  padding: 14px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

#cabinet-view main {
  padding: 0 15px 18px;
}

#favorites-view main {
  padding: 0 15px 18px;
}

#favorites-view .products-section {
  margin-top: 0;
  border-radius: 20px;
}

#cabinet-view .cabinet-section {
  margin-top: 12px;
}

#cabinet-view .cabinet-subtabs {
  background: rgba(var(--accent-300-rgb), 0.25);
  border-radius: 999px;
  padding: 5px;
  display: flex;
  gap: 6px;
  border: 1px solid rgba(var(--accent-border-rgb), 0.35);
  margin-bottom: 10px;
}

#cabinet-view .subtab-btn {
  flex: 1 1 0;
  border-radius: 999px;
  height: 36px;
  border: 1px solid transparent;
  background: transparent;
  font-weight: 700;
  font-size: 13px;
  color: rgba(17, 24, 39, 0.85);
}

#cabinet-view .subtab-btn--active {
  background: #ffffff;
  border-color: rgba(255, 255, 255, 0.9);
  color: #111827;
}

#cabinet-view .orders-list,
#cabinet-view .addresses-list {
  padding-bottom: 6px;
}

#cabinet-view .orders-list {
  max-height: none;
  overflow-y: visible;
}

#cabinet-view .addresses-list {
  gap: 6px;
}

#cabinet-view .profile-row {
  grid-template-columns: 72px 1fr;
  gap: 10px;
  margin-bottom: 10px;
}

#cabinet-view .profile-label {
  font-size: 13px;
  opacity: 0.85;
}

#cabinet-view .profile-value {
  font-size: 13px;
}

#cabinet-view .profile-value input,
#cabinet-view .profile-value .input-select {
  width: 100%;
  border-radius: 999px;
  border: 1px solid rgba(var(--accent-border-rgb), 0.55);
  background: rgba(255, 255, 255, 0.95);
  padding: 10px 12px;
  font-size: 14px;
}

#cabinet-view .profile-actions {
  justify-content: stretch;
}

#cabinet-view .profile-actions .btn {
  width: 100%;
  height: 44px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 700;
  background: var(--accent-300);
  border: 1px solid var(--accent-300);
  color: #ffffff;
}

#cabinet-view .cabinet-tabs {
  background: rgba(var(--accent-300-rgb), 0.45);
  border-radius: 999px;
  padding: 6px;
  gap: 6px;
  overflow: hidden;
}

#cabinet-view .tab-btn {
  flex: 1 1 0;
  border-radius: 999px;
  height: 42px;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 700;
  border: 1px solid transparent;
  background: transparent;
}

#cabinet-view .tab-btn--active {
  background: #ffffff;
  border-color: rgba(255, 255, 255, 0.9);
  color: #111827;
}

#cabinet-view .orders-empty,
#cabinet-view .orders-error {
  text-align: center;
  padding: 14px 10px;
}

#cabinet-view .form-card {
  border-radius: 18px;
  border: 1px solid rgba(229, 231, 235, 1);
  background: #ffffff;
  padding: 14px;
}

#cabinet-view .form-card .btn.btn-primary {
  width: 100%;
  height: 44px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 700;
  background: var(--accent-300);
  border: 1px solid var(--accent-300);
  color: #ffffff;
}

#cabinet-view .address-card {
  background: #ffffff;
  border: 1px solid rgba(229, 231, 235, 1);
  border-radius: 18px;
  padding: 14px;
  font-size: 14px;
}

#cabinet-view .address-card-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  flex-wrap: wrap;
}

#cabinet-view .address-card-actions .btn {
  flex: 1 1 140px;
  height: 40px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 700;
  padding: 0 14px;
}

#cabinet-view .address-card-actions .btn.btn-small {
  background: var(--accent-300);
  border: 1px solid var(--accent-300);
  color: #ffffff;
}

#cabinet-view .address-card--active .address-card-actions .btn.btn-small {
  background: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
}

#cabinet-view .address-card-actions .btn.btn-secondary {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(var(--accent-border-rgb), 0.65);
  color: #111827;
}

#cabinet-view #address-add-form textarea {
  min-height: 92px;
  border-radius: 14px;
  border: 1px solid rgba(var(--accent-border-rgb), 0.55);
  background: rgba(255, 255, 255, 0.95);
  font-family: inherit;
  font-size: 14px;
}

#cabinet-view #address-add-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

#cabinet-view #address-add-form .form-label {
  display: none;
}

#cabinet-view .address-card--active {
  border-color: rgba(var(--accent-300-rgb), 0.9);
  box-shadow: 0 0 0 2px rgba(var(--accent-300-rgb), 0.22);
}

.cabinet-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.cabinet-title {
  font-size: 16px;
  font-weight: 600;
}

.cabinet-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
}

.tab-btn {
  flex: 0 0 auto;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 13px;
  background: #ffffff;
  color: #111827;
  border: 1px solid #E5E7EB;
  white-space: nowrap;
}

.tab-btn--active {
  background: #EEF2FF;
  color: var(--accent);
  border-color: #C7D2FE;
}

.cabinet-section {
  margin-top: 8px;
}

.addresses-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.address-card {
  background: #ffffff;
  border: 1px solid #E5E7EB;
  border-radius: 12px;
  padding: 8px 10px;
  font-size: 13px;
}

.address-card-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.order-card-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.profile-card {
  background: #ffffff;
  border: 1px solid #E5E7EB;
  border-radius: 12px;
  padding: 10px;
  margin-bottom: 10px;
}

.profile-row {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
}

.profile-label {
  font-size: 12px;
  opacity: 0.8;
}

.profile-value {
  font-size: 13px;
}

.profile-actions {
  display: flex;
  justify-content: flex-end;
}

.profile-status-success {
  color: #111827;
  font-weight: 700;
  text-align: center;
  margin-top: 10px;
}

.profile-status-error {
  color: #dc2626;
  font-weight: 700;
  text-align: center;
  margin-top: 10px;
}

.input-select {
  border-radius: 12px;
  border: 1px solid #E5E7EB;
  background: #ffffff;
  color: #111827;
  padding: 8px 12px;
  font-size: 14px;
  outline: none;
  margin-top: 6px;
}

.comment-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 6px 0 6px;
}

.chip {
  border-radius: 999px;
  border: 1px solid #E5E7EB;
  background: #ffffff;
  color: #111827;
  padding: 6px 10px;
  font-size: 12px;
  cursor: pointer;
}

.chip:active {
  transform: scale(0.98);
}

.delivery-type-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 6px 0 0;
}

.delivery-type-chip--active {
  border-color: #C7D2FE;
  background: #EEF2FF;
  color: var(--accent);
}

.order-delivery-time-message {
  margin: 6px 0 10px;
  font-size: 13px;
  color: #9ca3af;
}

textarea {
  border-radius: 12px;
  border: 1px solid #E5E7EB;
  background: #ffffff;
  color: #111827;
  padding: 8px 12px;
  font-size: 14px;
  outline: none;
}

textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(var(--accent-rgb), 0.15);
}

.order-result {
  margin-top: 10px;
  font-size: 14px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid transparent;
  line-height: 1.35;
}

.order-result--success {
  color: #065f46;
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.order-result--error {
  color: #991b1b;
  background: #fef2f2;
  border-color: #fecaca;
}

.order-form-wrap {
  margin-top: 12px;
}

.order-success-block {
  margin-top: 16px;
  text-align: center;
}

.order-success-text {
  margin: 0 0 14px;
  font-size: 15px;
  color: #16a34a;
}

#order-modal .order-success-block {
  margin-top: 8px;
  padding: 18px 14px 12px;
  border: 1px solid rgba(149, 192, 239, 0.45);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.92);
}

#order-modal .order-success-text {
  margin: 0 0 12px;
  font-size: 16px;
  line-height: 1.35;
  font-weight: 600;
  color: #111827;
}

#order-modal #order-success-close.btn.btn-primary {
  min-width: 140px;
  height: 44px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 700;
}

/* My orders list */

.orders-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
  max-height: 320px;
  overflow-y: auto;
}

.order-card {
  background: #ffffff;
  border: 1px solid #E5E7EB;
  border-radius: 12px;
  padding: 8px 10px;
  font-size: 13px;
}

.order-card-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 4px;
}

.order-card-status {
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  background: #F3F4F6;
  color: #111827;
}

.order-card-status--new {
  background: #DBEAFE;
  color: #1D4ED8;
}

.order-card-status--in_progress {
  background: #FEF3C7;
  color: #92400E;
}

.order-card-status--done {
  background: #48A74D;
  color: #FFFFFF;
}

.order-card-status--cancelled {
  background: #FFEDD5;
  color: #C2410C;
}

.order-card-products {
  margin: 6px 0 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  white-space: pre-wrap;
}

.order-item-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.order-item-thumb {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  object-fit: cover;
  flex: 0 0 28px;
  border: 1px solid rgba(149, 192, 239, 0.45);
  background: #ffffff;
}

.order-item-text {
  min-width: 0;
  word-break: break-word;
}

.order-card-meta {
  font-size: 12px;
  opacity: 0.9;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.order-card-sep {
  height: 1px;
  background: rgba(229, 231, 235, 0.9);
  margin: 8px 0;
}

.orders-empty,
.orders-error {
  margin-top: 8px;
  font-size: 13px;
}

.orders-error {
  color: #dc2626;
}

/* Product details modal */

.product-modal-gallery {
  position: relative;
  margin: 0 0 16px;
  border-radius: 24px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
}

.product-modal-track {
  display: flex;
  transition: transform 0.25s ease;
  touch-action: pan-y pinch-zoom;
}

.product-modal-track .product-modal-slide {
  flex: 0 0 100%;
  width: 100%;
  min-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  box-sizing: border-box;
}

.product-modal-track .product-modal-slide img {
  width: 100%;
  height: 320px;
  display: block;
  border-radius: 20px;
  object-fit: contain;
  max-height: 320px;
}

.product-modal-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.9);
  color: #111827;
  border: 1px solid #E5E7EB;
  font-size: 18px;
  cursor: pointer;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;
}

.product-modal-arrow:hover {
  background: #ffffff;
}

.product-modal-prev {
  left: 8px;
}

.product-modal-next {
  right: 8px;
}

#product-modal .modal-content {
  width: 100%;
  max-width: 480px;
  min-height: 100%;
  padding: 12px 16px 28px;
  border-radius: 0;
  border: 0;
  box-shadow: none;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

#product-modal .modal-close {
  display: none;
}

.product-modal-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.product-modal-back-btn,
.product-modal-top-fav,
.product-modal-share-btn {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #0f172a;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;
  transition: color 0.16s ease, background 0.16s ease, transform 0.12s ease;
}

.product-modal-back-btn svg,
.product-modal-top-fav svg,
.product-modal-share-btn svg {
  width: 22px;
  height: 22px;
  display: block;
}

.product-modal-back-btn:active,
.product-modal-top-fav:active,
.product-modal-share-btn:active {
  transform: scale(0.94);
  background: rgba(var(--accent-100-rgb), 0.65);
}

.product-modal-top-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.product-modal-top-fav {
  position: relative;
  color: var(--accent-600);
}

.product-modal-top-fav.is-active {
  color: var(--accent);
}

.product-modal-top-fav.is-active svg {
  fill: rgba(var(--accent-rgb), 0.16);
}

.product-modal-share-btn {
  color: #0f172a;
}

.product-modal-top-fav-badge {
  position: absolute;
  top: 0;
  right: 0;
  min-width: 17px;
  height: 17px;
  border-radius: 999px;
  background: var(--accent-300);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
}

.product-modal-gallery-counter {
  position: absolute;
  right: 12px;
  bottom: 12px;
  min-width: 44px;
  height: 30px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: #111827;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  font-size: 13px;
  font-weight: 900;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.14);
  z-index: 3;
}

.product-modal-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  margin: 6px 0 10px;
  color: rgba(17, 24, 39, 0.62);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
}

#product-modal .modal-title {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: 20px;
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

#product-modal #product-modal-description {
  color: #475569;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
  opacity: 1;
  margin: 0 0 12px;
}

#product-modal .product-modal-props {
  display: none !important;
}

.modal-description .rich-img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 10px 0;
}

.contacts-image {
  display: block;
  width: 100%;
  max-height: 260px;
  object-fit: cover;
  border-radius: 16px;
  margin: 0 0 14px;
}

.contacts-map {
  width: 100%;
  overflow: hidden;
  border-radius: 16px;
  margin-top: 14px;
}

.contacts-map iframe {
  display: block;
  width: 100%;
  min-height: 260px;
  border: 0;
}

.modal-product-price {
  color: #0f172a;
  font-size: 23px;
  font-weight: 900;
  line-height: 1.1;
  margin: 2px 0 14px;
}

.product-modal-section-title {
  display: none;
}

.product-modal-variants-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 14px;
}

.product-modal-variant-box {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.product-modal-variant-title {
  display: none;
}

.product-modal-variant-subtitle {
  display: none;
}

.product-modal-variant-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 0;
}

.product-modal-variant-chip {
  min-height: 48px;
  border: 1px solid rgba(var(--accent-border-rgb), 0.35);
  border-radius: 10px;
  background: rgba(var(--accent-300-rgb), 0.1);
  color: #111827;
  padding: 7px 10px;
  white-space: nowrap;
  box-shadow: none;
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 3px;
  transition: transform 0.12s ease, background 0.18s ease, border-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.product-modal-variant-chip-label {
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
}

.product-modal-variant-chip-price {
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  color: rgba(17, 24, 39, 0.62);
}

.product-modal-variant-chip:focus,
.product-modal-variant-chip:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(var(--accent-300-rgb), 0.16);
}

.product-modal-variant-chip.is-active {
  border-color: var(--accent-300);
  background: var(--accent-300);
  color: #ffffff;
  box-shadow: 0 10px 22px rgba(var(--accent-300-rgb), 0.26);
}

.product-modal-variant-chip.is-active .product-modal-variant-chip-price {
  color: rgba(255, 255, 255, 0.82);
}

.product-modal-variant-chip:active {
  transform: scale(0.97);
}

.modal-actions {
  display: flex;
  gap: 10px;
  align-items: stretch;
  margin-top: 4px;
}

.product-modal-add-wrap {
  flex: 1 1 auto;
  min-width: 0;
}

.product-modal-add-wrap .product-modal-add-btn {
  width: 100%;
  min-height: 44px;
  border-radius: 9px;
  font-size: 16px;
  font-weight: 900;
  background: var(--accent-300);
  border-color: var(--accent-300);
  color: #ffffff;
  box-shadow: 0 12px 28px rgba(var(--accent-300-rgb), 0.22);
}

.product-modal-add-wrap .product-modal-add-btn:focus,
.product-modal-add-wrap .product-modal-add-btn:focus-visible {
  outline: none;
  box-shadow: 0 12px 28px rgba(var(--accent-300-rgb), 0.22), 0 0 0 3px rgba(var(--accent-300-rgb), 0.16);
}

#product-modal #product-modal-buy.product-modal-favorite-btn {
  display: none;
}

#product-modal #product-modal-buy.product-modal-favorite-btn:focus,
#product-modal #product-modal-buy.product-modal-favorite-btn:focus-visible {
  outline: none;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06), 0 0 0 3px rgba(var(--accent-300-rgb), 0.14);
}

#product-modal #product-modal-buy.product-modal-favorite-btn:active {
  transform: scale(0.98);
}

#product-modal #product-modal-buy.product-modal-favorite-btn svg {
  width: 20px;
  height: 20px;
  display: block;
  flex: 0 0 20px;
}

#product-modal #product-modal-buy.product-modal-favorite-btn.is-active {
  background: rgba(var(--accent-300-rgb), 0.12);
  border-color: rgba(var(--accent-border-rgb), 0.75);
}

#product-modal #product-modal-buy.product-modal-favorite-btn.is-active svg {
  fill: currentColor;
}

/* Степпер количества внутри бывшей кнопки «В корзину» (как в маркетплейсах) */
.product-modal-inline-qty {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  min-height: 44px;
  padding: 6px;
  border-radius: 9px;
  background: var(--accent-300);
  color: #fff;
  box-sizing: border-box;
  box-shadow: 0 12px 28px rgba(var(--accent-300-rgb), 0.22);
}

.product-modal-inline-qty button {
  flex: 0 0 34px;
  width: 34px;
  height: 32px;
  border: none;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--accent-300);
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-modal-inline-qty button:active {
  transform: scale(0.96);
}

.product-modal-inline-qty .product-modal-inline-qty-value {
  flex: 1;
  text-align: center;
  font-size: 16px;
  font-weight: 900;
  user-select: none;
  min-width: 28px;
}

@media (max-width: 699px) {
  #product-modal .modal-content {
    width: 100%;
    max-width: 100%;
    border-radius: 0;
    padding: 12px 16px 18px;
  }

  .product-modal-gallery {
    border-radius: 22px;
    margin-bottom: 14px;
  }

  .product-modal-track .product-modal-slide {
    min-height: 300px;
    padding: 14px;
  }

  .product-modal-track .product-modal-slide img {
    height: 300px;
    max-height: 300px;
  }

  #product-modal .modal-title {
    font-size: 19px;
  }
}

.promotion-modal-section {
  margin-top: 10px;
}

.promotion-modal-section-title {
  font-size: 13px;
  font-weight: 700;
  color: #4b5563;
  margin-bottom: 6px;
}

.promotion-modal-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
}

.promotion-modal-item--gift .promotion-modal-item-text {
  color: #0f766e;
  font-weight: 600;
}

.promotion-modal-item-thumb {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: cover;
  flex: 0 0 32px;
  border: 1px solid rgba(149, 192, 239, 0.45);
  background: #ffffff;
}

.promotion-modal-item-text {
  font-size: 14px;
  line-height: 1.3;
  color: #111827;
  word-break: break-word;
}

#promotion-modal .modal-description {
  margin: 2px 0 0;
  opacity: 1;
}

#service-modal .modal-content {
  border-radius: 20px;
  padding: 16px 14px 14px;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

#service-modal .modal-title {
  font-size: 20px;
  line-height: 1.2;
  margin: 0 0 10px;
  font-weight: 800;
}

#service-modal .modal-close {
  top: 10px;
  right: 10px;
  width: 34px;
  height: 34px;
  border-radius: 999px;
}

#service-modal .order-form {
  gap: 10px;
}

#service-modal .form-label {
  display: block;
  margin-bottom: 5px;
  font-size: 15px;
  font-weight: 600;
  color: #1f2937;
}

#service-modal .order-form input[type="tel"],
#service-modal .order-form input[type="text"],
#service-modal .order-form input[type="date"],
#service-modal .order-form select,
#service-modal .order-form textarea {
  width: 100%;
  height: 40px;
  border-radius: 14px;
  border: 1px solid rgba(149, 192, 239, 0.55);
  background: rgba(255, 255, 255, 0.95);
  padding: 8px 12px;
  font-size: 14px;
  line-height: 1.2;
  font-family: inherit;
}

#service-modal .order-form textarea {
  min-height: 72px;
  height: auto;
  resize: vertical;
}

#service-specialist-info {
  margin-top: 8px;
  padding: 10px 12px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  color: #1f2937;
}

.debug-info {
  margin-top: 16px;
  padding: 8px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid #E5E7EB;
  font-size: 10px;
  white-space: pre-wrap;
  word-break: break-all;
  opacity: 0.8;
}

/* --- Cart modal alignment (same principle as cabinet) --- */
#order-modal .modal-content {
  border-radius: 20px;
  padding: 16px 14px 14px;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.35;
}

#order-modal .modal-title {
  font-size: 20px;
  line-height: 1.2;
  margin: 0 0 12px;
  font-weight: 800;
}

#order-modal .modal-close {
  top: 10px;
  right: 10px;
  width: 30px;
  height: 30px;
  border-radius: 12px;
}

#order-modal #cart-items {
  max-height: none;
  padding-right: 2px;
}

#order-modal .cart-item {
  align-items: center;
  gap: 10px;
  padding: 4px 0;
}

#order-modal .cart-item-thumb {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  object-fit: cover;
  flex: 0 0 34px;
  border: 1px solid rgba(149, 192, 239, 0.45);
  background: #ffffff;
}

#order-modal .cart-item-title {
  flex: 1 1 auto;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  min-width: 0;
  word-break: break-word;
}

#order-modal .cart-item-controls {
  gap: 6px;
  flex-wrap: nowrap;
  align-items: center;
  flex: 0 0 auto;
}

#order-modal .cart-item-price,
#order-modal .cart-item-qty {
  font-size: 14px;
  color: #374151;
}

#order-modal .cart-item-controls .btn.btn-small {
  width: 30px;
  height: 30px;
  min-width: 30px;
  border-radius: 999px;
  padding: 0;
  font-size: 20px;
  line-height: 1;
  font-weight: 700;
}

#order-modal .cart-total {
  margin-top: 10px;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.35;
  color: #6b7280;
}

#order-modal #delivery-summary,
#order-modal #promo-summary {
  margin-top: 6px;
  font-size: 10px !important;
  line-height: 1.35;
  color: #6b7280;
}

#order-modal #delivery-summary .delivery-summary-highlight {
  color: #3b7ddd;
  font-weight: 600;
}

#order-modal .order-form {
  gap: 10px;
}

#order-modal .form-label {
  display: block;
  margin-bottom: 5px;
  font-size: 15px;
  font-weight: 600;
  color: #1f2937;
  opacity: 1;
}

#order-modal .order-form input[type="tel"],
#order-modal .order-form input[type="text"],
#order-modal .order-form select,
#order-modal .order-form textarea {
  width: 100%;
  height: 40px;
  border-radius: 14px;
  border: 1px solid rgba(149, 192, 239, 0.55);
  background: rgba(255, 255, 255, 0.95);
  padding: 8px 12px;
  font-size: 14px;
  line-height: 1.2;
  font-family: inherit;
  box-sizing: border-box;
}

#order-modal .order-form textarea {
  height: auto;
  min-height: 72px;
  resize: vertical;
}

#order-modal #order-address {
  margin-top: 8px;
}

#order-modal .delivery-type-chips {
  display: flex;
  gap: 8px;
}

#order-modal .delivery-type-chip {
  height: 32px;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
}

#order-modal .order-delivery-time-message {
  margin: 2px 0 0;
  font-size: 13px;
  color: #9ca3af;
}

#order-modal .payment-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#order-modal .payment-actions .btn {
  width: 100%;
  height: 44px;
  border-radius: 16px;
  font-size: 15px;
  font-weight: 700;
}

#order-modal .payment-actions .btn.btn-primary {
  background: var(--accent-300);
  border: 1px solid var(--accent-300);
  color: #ffffff;
}

#order-modal .payment-actions .btn.btn-secondary {
  background: #ffffff;
  border: 1px solid rgba(var(--accent-border-rgb), 0.65);
  color: #111827;
}

#order-modal .form-helper {
  margin-top: 6px;
  text-align: left;
  font-size: 12px;
}

#order-modal .comment-chips {
  margin: 4px 0 6px;
}

#order-modal .comment-chips .chip {
  height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 13px;
}

#order-modal .promo-code-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

#order-modal .promo-code-row #order-promo-code {
  flex: 1 1 auto;
}

#order-modal .promo-code-row #order-promo-apply {
  flex: 0 0 auto;
  min-width: 130px;
  height: 40px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 700;
  padding: 0 14px;
}

#order-modal.checkout-modal {
  align-items: flex-end;
  justify-content: center;
  background: rgba(15, 23, 42, 0.42);
}

#order-modal.checkout-modal .modal-backdrop {
  background: rgba(15, 23, 42, 0.42);
}

#order-modal.checkout-modal .modal-content {
  width: min(430px, 100%);
  max-width: 430px;
  max-height: calc(100dvh - 34px);
  margin: 0 auto;
  padding: 18px 12px 12px;
  border-radius: 24px 24px 0 0;
  border: 0;
  box-shadow: 0 -18px 46px rgba(15, 23, 42, 0.18);
}

#order-modal.checkout-modal .modal-content::before {
  content: "";
  display: block;
  width: 38px;
  height: 4px;
  margin: -6px auto 14px;
  border-radius: 999px;
  background: #d1d5db;
}

#order-modal.checkout-modal .modal-title {
  margin: 0 38px 14px 2px;
  font-size: 18px;
  font-weight: 950;
  color: #111827;
}

#order-modal.checkout-modal .modal-close {
  top: 18px;
  right: 12px;
  width: 34px;
  height: 34px;
  border: 0;
  background: transparent;
  font-size: 24px;
}

#order-modal.checkout-modal .checkout-steps {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  margin: 0 0 14px;
  padding: 2px 0 0;
}

#order-modal.checkout-modal .checkout-step {
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 0;
  color: #9ca3af;
  font-size: 9px;
  font-weight: 800;
  text-align: center;
}

#order-modal.checkout-modal .checkout-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: #e5e7eb;
  color: #ffffff;
  font-size: 10px;
  font-weight: 900;
}

#order-modal.checkout-modal .checkout-step--active {
  color: #111827;
}

#order-modal.checkout-modal .checkout-step--active .checkout-step-num {
  background: var(--accent-300);
}

#order-modal.checkout-modal .checkout-step--done .checkout-step-num {
  background: var(--accent);
}

#order-modal.checkout-modal .checkout-step-hidden {
  display: none !important;
}

#order-modal.checkout-modal .checkout-form-cart-step {
  margin-top: 0;
}

#order-modal.checkout-modal .checkout-nav {
  display: grid;
  grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr);
  gap: 10px;
  margin-top: 14px;
}

#order-modal.checkout-modal .checkout-nav .btn {
  width: 100%;
  min-height: 48px;
  border-radius: 12px;
  font-weight: 950;
}

#order-modal.checkout-modal .checkout-nav .btn.hidden {
  display: none !important;
}

#order-modal.checkout-modal .checkout-nav .checkout-nav-next:first-child,
#order-modal.checkout-modal .checkout-nav .checkout-nav-next:last-child {
  grid-column: 1 / -1;
}

#order-modal.checkout-modal .checkout-nav-back.hidden + .checkout-nav-next {
  grid-column: 1 / -1;
}

#order-modal.checkout-modal .checkout-section-title {
  margin: 2px 0 10px;
  font-size: 13px;
  font-weight: 900;
  color: #111827;
}

#order-modal.checkout-modal .delivery-type-chips {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin: 0;
}

#order-modal.checkout-modal .delivery-type-chip {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  height: auto;
  min-height: 66px;
  padding: 13px 14px 13px 46px;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  background: #ffffff;
  color: #111827;
  font-size: 14px;
  font-weight: 900;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

#order-modal.checkout-modal .delivery-type-chip::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 50%;
  width: 16px;
  height: 16px;
  border: 2px solid #d1d5db;
  border-radius: 999px;
  transform: translateY(-50%);
  box-sizing: border-box;
}

#order-modal.checkout-modal .delivery-type-chip::after {
  content: "";
  position: absolute;
  left: 21px;
  top: 50%;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: transparent;
  transform: translateY(-50%);
}

#order-modal.checkout-modal .delivery-type-chip--active {
  border-color: var(--accent-300);
  background: rgba(var(--accent-rgb), 0.06);
  color: #111827;
}

#order-modal.checkout-modal .delivery-type-chip--active::before {
  border-color: var(--accent-300);
}

#order-modal.checkout-modal .delivery-type-chip--active::after {
  background: var(--accent-300);
}

#order-modal.checkout-modal #order-delivery-type-wrap,
#order-modal.checkout-modal #order-address-delivery-wrap,
#order-modal.checkout-modal #order-pickup-wrap,
#order-modal.checkout-modal #order-promocode-wrap,
#order-modal.checkout-modal #order-empty-bottles-wrap,
#order-modal.checkout-modal #order-delivery-datetime-field {
  padding: 0;
}

#order-modal.checkout-modal #cart-items {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#order-modal.checkout-modal .cart-item {
  margin: 0;
  padding: 10px 0;
  border: 0;
  border-bottom: 1px solid #f3f4f6;
  border-radius: 0;
  background: transparent;
}

#order-modal.checkout-modal .cart-item-thumb {
  width: 60px;
  height: 60px;
  flex-basis: 60px;
  border-radius: 12px;
  background: #f8fafc;
}

#order-modal.checkout-modal .cart-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 12px 0 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: #111827;
  font-size: 20px;
  font-weight: 950;
}

#order-modal.checkout-modal .payment-actions {
  margin-top: 0;
}

#order-modal.checkout-modal .payment-actions .btn,
#order-modal.checkout-modal #order-success-close.btn.btn-primary {
  min-height: 48px;
  border-radius: 12px;
  background: var(--accent-300);
  border-color: var(--accent-300);
  color: #ffffff;
  font-weight: 950;
}

@media (max-width: 480px) {
  #order-modal.checkout-modal .modal-content {
    width: 100%;
    max-width: 100%;
    max-height: calc(100dvh - 26px);
  }
}

/* ===== MOBILE PRODUCT CARD REDESIGN ===== */

/* Bottom Sheet Component */
.bottom-sheet-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(2px);
  z-index: 10000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.bottom-sheet-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.bottom-sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: #ffffff;
  border-radius: 24px 24px 0 0;
  z-index: 10001;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
  max-height: 85vh;
  display: flex;
  flex-direction: column;
}

.bottom-sheet.is-open {
  transform: translateY(0);
}

.bottom-sheet-handle {
  width: 36px;
  height: 4px;
  background: rgba(0, 0, 0, 0.15);
  border-radius: 2px;
  margin: 12px auto 8px;
  flex-shrink: 0;
}

.bottom-sheet-header {
  padding: 8px 20px 16px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  flex-shrink: 0;
}

.bottom-sheet-title {
  font-size: 18px;
  font-weight: 900;
  color: #0f172a;
  margin: 0;
}

.bottom-sheet-subtitle {
  font-size: 14px;
  color: #64748b;
  margin: 4px 0 0;
}

.bottom-sheet-content {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px 20px;
  -webkit-overflow-scrolling: touch;
}

.bottom-sheet-footer {
  padding: 12px 20px calc(12px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  background: #ffffff;
  flex-shrink: 0;
}

/* Variant Selection in Bottom Sheet */
.variant-sheet-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.variant-sheet-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border: 2px solid rgba(0, 0, 0, 0.08);
  border-radius: 16px;
  background: #ffffff;
  cursor: pointer;
  transition: all 0.2s ease;
}

.variant-sheet-option.is-selected {
  border-color: var(--accent-300);
  background: rgba(var(--accent-300-rgb), 0.05);
}

.variant-sheet-radio {
  width: 24px;
  height: 24px;
  border: 2px solid rgba(0, 0, 0, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.variant-sheet-option.is-selected .variant-sheet-radio {
  border-color: var(--accent-300);
  background: var(--accent-300);
}

.variant-sheet-radio::after {
  content: "";
  width: 10px;
  height: 10px;
  background: #ffffff;
  border-radius: 50%;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.variant-sheet-option.is-selected .variant-sheet-radio::after {
  opacity: 1;
}

.variant-sheet-info {
  flex: 1;
}

.variant-sheet-label {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  display: block;
}

.variant-sheet-price {
  font-size: 14px;
  font-weight: 700;
  color: #64748b;
  margin-top: 2px;
  display: block;
}

/* Quantity Stepper in Bottom Sheet */
.quantity-stepper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 16px 0;
}

.quantity-stepper button {
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 14px;
  background: #f1f5f9;
  color: #0f172a;
  font-size: 24px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.quantity-stepper button:active {
  transform: scale(0.92);
  background: #e2e8f0;
}

.quantity-stepper-value {
  font-size: 24px;
  font-weight: 900;
  color: #0f172a;
  min-width: 60px;
  text-align: center;
}

/* Gallery Dots Indicator */
.gallery-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 10px;
}

.gallery-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
}

.gallery-dot.is-active {
  width: 18px;
  border-radius: 3px;
  background: var(--accent-300);
}

/* Fullscreen Gallery */
.fullscreen-gallery {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #000000;
  z-index: 11000;
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.fullscreen-gallery.is-open {
  opacity: 1;
  visibility: visible;
}

.fullscreen-gallery-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  padding-top: calc(12px + env(safe-area-inset-top));
}

.fullscreen-gallery-close {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.fullscreen-gallery-counter {
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
}

.fullscreen-gallery-content {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.fullscreen-gallery-content img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* Sticky Product Footer */
.product-sticky-footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: #ffffff;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  z-index: 500;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
}

.product-sticky-footer-info {
  flex: 1;
}

.product-sticky-footer-price {
  font-size: 20px;
  font-weight: 900;
  color: #0f172a;
}

.product-sticky-footer-old-price {
  font-size: 14px;
  font-weight: 600;
  color: #94a3b8;
  text-decoration: line-through;
  margin-left: 8px;
}

.product-sticky-footer-btn {
  flex: 0 0 auto;
  min-width: 140px;
  height: 48px;
  border: none;
  border-radius: 14px;
  background: var(--accent-300);
  color: #ffffff;
  font-size: 15px;
  font-weight: 900;
  padding: 0 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s ease;
}

.product-sticky-footer-btn:active {
  transform: scale(0.96);
}

/* Compact quantity stepper in sticky footer */
.product-sticky-footer .quantity-stepper {
  background: #f1f5f9;
  border-radius: 12px;
  padding: 4px !important;
}

.product-sticky-footer .quantity-stepper button {
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  border: none;
  color: #0f172a;
}

.product-sticky-footer .quantity-stepper button:active {
  background: #f8fafc;
  transform: scale(0.92);
}

.product-sticky-footer .quantity-stepper .quantity-stepper-value {
  color: #0f172a;
  font-weight: 800;
}

/* Product Info Blocks */
.product-info-blocks {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 12px 0 0;
}

.product-info-block {
  background: #ffffff;
  border: 1px solid #eaded4;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 6px 18px rgba(70, 30, 8, 0.04);
}

.product-info-block-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 14px 4px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.product-info-block-header:active {
  background: rgba(0, 0, 0, 0.02);
}

.product-info-block-title {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 8px;
}

.product-info-block-arrow {
  width: 24px;
  height: 24px;
  color: #94a3b8;
  transition: transform 0.3s ease;
}

.product-info-block.is-expanded .product-info-block-arrow {
  transform: rotate(180deg);
}

.product-info-block-content {
  padding: 0 14px 14px;
  font-size: 13px;
  line-height: 1.45;
  color: #374151;
}

/* Delivery Block Specific */
.delivery-block-preview {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
}

.delivery-block-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(var(--accent-300-rgb), 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.delivery-block-text {
  flex: 1;
}

.delivery-block-date {
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
}

.delivery-block-method {
  font-size: 13px;
  color: #64748b;
  margin-top: 2px;
}

/* Description Block - Truncated */
.description-preview {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 600;
}

.description-full {
  -webkit-line-clamp: unset;
  line-clamp: unset;
}

/* Characteristics Grid */
.product-about-block {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0 6px;
}

.product-about-title {
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 900;
  color: #111827;
}

.characteristics-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.characteristic-item {
  background: transparent;
  border-radius: 0;
  padding: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
  gap: 12px;
}

.characteristic-label {
  font-size: 12px;
  font-weight: 700;
  color: #6b7280;
  text-transform: none;
  letter-spacing: 0;
}

.characteristic-value {
  font-size: 12px;
  font-weight: 900;
  color: #111827;
  margin-top: 0;
  text-align: right;
}

/* Reviews Preview Block */
.reviews-preview {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.reviews-preview-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.reviews-preview-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 18px;
  font-weight: 900;
  color: #0f172a;
}

.reviews-preview-stars {
  color: #fbbf24;
}

.reviews-preview-count {
  font-size: 14px;
  color: #64748b;
}

.reviews-preview-item {
  background: #f8fafc;
  border-radius: 12px;
  padding: 12px;
}

.reviews-preview-author {
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
}

.reviews-preview-text {
  font-size: 13px;
  color: #475569;
  margin-top: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  box-orient: vertical;
  overflow: hidden;
}

.reviews-preview-link {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent-300);
  text-align: center;
  padding: 8px;
  margin-top: 4px;
}

/* Related Products Horizontal Scroll */
.related-products-section {
  margin: 18px 0 0;
}

.related-products-title {
  font-size: 15px;
  font-weight: 900;
  color: #0f172a;
  margin: 0 0 12px 6px;
}

.related-products-scroll {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 0 0 12px 6px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.related-products-scroll::-webkit-scrollbar {
  display: none;
}

.related-product-card {
  flex: 0 0 104px;
  scroll-snap-align: start;
  background: #ffffff;
  border: 1px solid #f1e7df;
  border-radius: 13px;
  overflow: hidden;
  cursor: pointer;
}

.related-product-image {
  width: 100%;
  height: 86px;
  object-fit: cover;
}

.related-product-info {
  padding: 8px;
}

.related-product-name {
  font-size: 12px;
  font-weight: 700;
  color: #0f172a;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  box-orient: vertical;
  overflow: hidden;
  line-height: 1.3;
}

.related-product-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 8px;
}

.related-product-price {
  font-size: 13px;
  font-weight: 900;
  color: #111827;
}

.related-product-cart {
  width: 28px;
  height: 28px;
  border: 1px solid rgba(var(--accent-rgb), 0.18);
  border-radius: 10px;
  background: #ffffff;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  flex: 0 0 auto;
}

.related-product-cart svg {
  width: 16px;
  height: 16px;
}

/* Bonuses Block */
.bonuses-block {
  background: linear-gradient(135deg, rgba(var(--accent-300-rgb), 0.08) 0%, rgba(var(--accent-300-rgb), 0.02) 100%);
  border: 1px solid rgba(var(--accent-300-rgb), 0.15);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
}

.bonuses-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--accent-300);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}

.bonuses-content {
  flex: 1;
}

.bonuses-label {
  font-size: 12px;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.bonuses-value {
  font-size: 16px;
  font-weight: 900;
  color: var(--accent-300);
  margin-top: 2px;
}

.bonuses-sublabel {
  font-size: 13px;
  color: #64748b;
  margin-top: 2px;
}

/* Variant Trigger Button */
.variant-trigger-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: #f8fafc;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
  margin: 12px 0;
}

.variant-trigger-btn:active {
  background: #f1f5f9;
}

.variant-trigger-label {
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
}

.variant-trigger-value {
  font-size: 14px;
  font-weight: 800;
  color: var(--accent-300);
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Product Header Section */
.product-header {
  padding: 14px 0 8px;
}

.product-header-brand {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-300);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.product-header-title {
  font-size: 22px;
  font-weight: 900;
  color: #0f172a;
  line-height: 1.2;
  margin: 0 0 5px;
}

.product-header-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  min-width: 0;
}

.product-header-rating {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 13px;
  font-weight: 800;
  color: #0f172a;
  white-space: nowrap;
}

.product-header-rating-star {
  color: #fbbf24;
}

.product-header-article {
  min-width: 0;
  font-size: 13px;
  font-weight: 800;
  color: #64748b;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Hide old variant chips when using bottom sheet */
.product-modal-variants-list[data-style="sheet"] {
  display: none;
}

/* Variant Selector Trigger */
.variant-selector-trigger {
  display: block;
  padding: 0;
  margin: 8px 0 14px;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.variant-selector-label {
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
}

.variant-selector-chips {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
  gap: 8px;
  overflow: visible;
}

.variant-selector-chips::-webkit-scrollbar {
  display: none;
}

.variant-selector-chip {
  min-width: 0;
  min-height: 76px;
  padding: 10px 8px;
  border: 1px solid #eaded4;
  border-radius: 12px;
  background: #ffffff;
  color: #111827;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.15;
  white-space: normal;
  box-shadow: 0 4px 14px rgba(70, 30, 8, 0.03);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  text-align: left;
  transition: transform 0.12s ease, background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.variant-selector-chip:active {
  transform: scale(0.96);
}

.variant-selector-chip.is-active {
  background: rgba(var(--accent-rgb), 0.06);
  color: #111827;
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent), 0 8px 18px rgba(var(--accent-rgb), 0.12);
}

.variant-selector-chip-label {
  font-size: 13px;
  font-weight: 900;
  color: #111827;
}

.variant-selector-chip-price {
  margin-top: 8px;
  font-size: 14px;
  font-weight: 900;
  color: #111827;
}

.variant-selector-chip-unit {
  margin-top: 2px;
  font-size: 11px;
  font-weight: 700;
  color: #6b7280;
}

/* Product purchase row */
.product-purchase-row.product-sticky-footer {
  position: static !important;
  inset: auto !important;
  left: auto !important;
  right: auto !important;
  bottom: auto !important;
  z-index: auto !important;
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  margin: 4px 0 14px;
  padding: 0 2px;
  background: transparent !important;
  border-top: 0 !important;
  box-shadow: none !important;
  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
}

.product-purchase-row .product-sticky-footer-info {
  min-width: 0;
  flex: 1 1 auto;
}

.product-purchase-row .product-sticky-footer-price {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-size: 21px;
  font-weight: 900;
  color: #111827;
  white-space: nowrap;
}

.product-purchase-row .product-sticky-footer-old-price {
  font-size: 12px;
  font-weight: 700;
  color: #9ca3af;
  text-decoration: line-through;
}

.product-purchase-row .product-sticky-footer-btn {
  min-height: 48px;
  min-width: 150px;
  border: 0;
  border-radius: 12px;
  background: var(--accent);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 18px;
  font-size: 14px;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(var(--accent-rgb), 0.22);
}

.product-purchase-row .product-sticky-footer-btn svg {
  width: 21px;
  height: 21px;
}

.product-sticky-cart-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.product-card-stepper {
  height: 44px;
  border-radius: 14px;
  background: #f8fafc;
  padding: 0 8px;
  gap: 10px;
}

.product-card-stepper button {
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 10px;
  background: #ffffff;
  color: #111827;
  font-size: 16px;
  font-weight: 900;
}

.product-card-stepper .quantity-stepper-value {
  min-width: 18px;
  font-size: 15px;
  font-weight: 900;
  color: #111827;
}

.product-sticky-footer-icon-btn {
  min-width: 48px;
  width: 48px;
  padding: 0;
}

