:root {
  --tg-bg: #f7f9fb;
  --tg-surface: #ffffff;
  --tg-text: #17212b;
  --tg-muted: #74808d;
  --tg-blue: #2aabee;
  --tg-blue-dark: #178dcc;
  --tg-green: #30c775;
  --tg-yellow: #d59b18;
  --tg-red: #d95656;
  --tg-border: #dfe7ef;
  --shadow: 0 18px 45px rgba(39, 75, 112, 0.14);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-top: env(safe-area-inset-top, 0px);
  --content-safe-bottom: 0px;
  --bottom-overlay-inset: 0px;
  --keyboard-inset: 0px;
  --font-text:
    "SF Pro Text",
    -apple-system,
    BlinkMacSystemFont,
    system-ui,
    "Segoe UI",
    sans-serif;
  --font-display:
    "SF Pro Display",
    "SF Pro Text",
    -apple-system,
    BlinkMacSystemFont,
    system-ui,
    "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  touch-action: manipulation;
}

button,
input,
select,
textarea,
a,
label,
[role="button"] {
  touch-action: manipulation;
}

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--tg-bg);
  color: var(--tg-text);
  font-family: var(--font-text);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.45;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
.topbar__title span,
.catalog-intro h1,
.section-title h2,
.product-sheet__header h2,
.ask-confirm__header h2,
.order-confirm__header h2 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
}

button {
  border: 0;
  font: inherit;
  cursor: pointer;
}

.app-shell {
  width: min(100%, 520px);
  margin: 0 auto;
  padding: 12px 14px 112px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: 40px 1fr 40px;
  align-items: center;
  gap: 10px;
  padding: 8px 4px 12px;
  background: color-mix(in srgb, var(--tg-bg) 88%, transparent);
  backdrop-filter: blur(18px);
}

.topbar__title {
  display: grid;
  justify-items: center;
  line-height: 1.1;
}

.topbar__title span {
  font-size: 15px;
  font-weight: 700;
}

.topbar__title small {
  margin-top: 3px;
  color: var(--tg-muted);
  font-size: 11px;
  font-weight: 600;
}

.catalog-intro {
  padding: 12px 4px 2px;
}

.catalog-intro span {
  color: var(--tg-blue-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.catalog-intro h1 {
  margin: 7px 0 8px;
}

.catalog-intro p {
  margin: 0;
  color: var(--tg-muted);
  font-size: 14px;
  line-height: 1.45;
}

.icon-button {
  position: relative;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--tg-surface);
  color: var(--tg-blue);
  box-shadow: 0 8px 20px rgba(39, 75, 112, 0.08);
}

.icon-button svg {
  width: 19px;
  height: 19px;
  fill: currentColor;
}

.theme-toggle {
  overflow: hidden;
}

.theme-toggle__icon {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  opacity: 0;
  transform: scale(0.55) rotate(-28deg);
  transition:
    opacity 220ms cubic-bezier(0.4, 0, 0.2, 1),
    transform 340ms cubic-bezier(0.34, 1.2, 0.64, 1);
  pointer-events: none;
}

.theme-toggle__icon.is-active {
  opacity: 1;
  transform: scale(1) rotate(0deg);
}

.theme-toggle__icon svg {
  width: 19px;
  height: 19px;
  fill: currentColor;
}

.theme-toggle__icon svg circle,
.theme-toggle__icon svg rect {
  fill: currentColor;
}

.cart-shortcut {
  color: var(--tg-blue-dark);
}

.cart-shortcut__badge {
  position: absolute;
  top: -2px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  padding: 0 5px;
  border: 2px solid var(--tg-bg);
  border-radius: 999px;
  background: var(--tg-red);
  color: #ffffff;
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
}

.cart-shortcut__badge[hidden] {
  display: none;
}

.chevron {
  width: 11px;
  height: 11px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-left: 4px;
}

.product-detail-card {
  overflow: hidden;
  min-height: 490px;
  display: grid;
  align-content: end;
  position: relative;
  padding: 22px;
  border-radius: 30px;
  background:
    radial-gradient(circle at 18% 22%, rgba(48, 199, 117, 0.24), transparent 30%),
    radial-gradient(circle at 84% 10%, rgba(42, 171, 238, 0.24), transparent 34%),
    linear-gradient(160deg, #ffffff 0%, #edf7ff 54%, #e7fff3 100%);
  box-shadow: var(--shadow);
}

.detail-product-photo {
  position: absolute;
  top: 54px;
  left: 50%;
  width: 230px;
  aspect-ratio: 1;
  transform: translateX(-50%);
}

.detail-product-photo__image {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  border-radius: 26px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 92px;
  font-weight: 900;
}

img.detail-product-photo__image {
  display: block;
  object-fit: contain;
  border-radius: 0;
  background: transparent;
  filter:
    drop-shadow(0 18px 18px rgba(46, 62, 74, 0.18))
    drop-shadow(0 5px 7px rgba(46, 62, 74, 0.12));
}

.detail-product-photo__image--placeholder {
  box-shadow: 0 24px 60px rgba(72, 82, 91, 0.18);
}

.detail-product-photo__image--red {
  background: linear-gradient(135deg, #c55d6d, #873042);
}

.detail-product-photo__image--blue {
  background: linear-gradient(135deg, #64c6f8, #177fbb);
}

.detail-product-photo__image--mint {
  background: linear-gradient(135deg, #6ae0a4, #1b9460);
}

.product-detail-card__content {
  position: relative;
  z-index: 1;
}

.status-line {
  --status-color: var(--tg-green);
  --status-halo: rgba(48, 199, 117, 0.15);
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.78);
  color: #148750;
  font-size: 13px;
  font-weight: 700;
}

.status-dot {
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--status-color);
  box-shadow: 0 0 0 4px var(--status-halo);
  animation: status-dot-live 2.8s ease-in-out infinite;
}

@keyframes status-dot-live {
  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 0 3px var(--status-halo);
  }

  50% {
    opacity: 0.68;
    box-shadow: 0 0 0 5px var(--status-halo);
  }
}

h1 {
  margin: 14px 0 8px;
  max-width: 390px;
  font-size: clamp(28px, 7.5vw, 40px);
  line-height: 1.04;
}

.product-detail-card p {
  margin: 0;
  color: #526170;
  font-size: 15px;
  line-height: 1.5;
}

.price-panel {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 14px;
  margin-top: 18px;
  padding: 16px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: inset 0 0 0 1px rgba(42, 171, 238, 0.1);
}

.price-panel small,
.section-title span,
.info-card span,
.order-box label {
  color: var(--tg-muted);
  font-size: 12px;
  font-weight: 700;
}

.price-panel > div {
  min-width: 0;
  flex: 1 1 auto;
}

.price-panel strong {
  display: block;
  margin-top: 4px;
  font-size: clamp(24px, 7vw, 30px);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  word-break: keep-all;
  overflow-wrap: normal;
}

.price-panel > span {
  flex: 0 0 auto;
  align-self: end;
  color: var(--tg-blue-dark);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
  text-align: right;
}

.quick-actions {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 10px;
  margin-top: 14px;
}

.detail-cart-action {
  min-width: 0;
  width: 100%;
  display: flex;
}

.detail-cart-action > .action-chip--primary,
.detail-cart-action > .quantity-controls {
  width: 100%;
  flex: 1 1 auto;
}

.detail-cart-action .action-chip--primary {
  display: flex;
}

.quantity-controls {
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 0 10px;
  border-radius: 18px;
  background: var(--tg-surface);
  box-shadow: 0 8px 20px rgba(39, 75, 112, 0.08);
}

.quantity-controls strong {
  flex: 1 1 auto;
  min-width: 28px;
  text-align: center;
  color: var(--tg-text);
  font-size: 16px;
  font-weight: 800;
}

.quantity-controls button {
  position: relative;
  overflow: visible;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: #e5f4fd;
  color: var(--tg-blue-dark);
  font-size: 20px;
  font-weight: 800;
  transition:
    color 160ms ease,
    background-color 160ms ease;
}

.quantity-controls button.is-plus-animated,
.quantity-controls button.is-minus-animated {
  transition: none;
}

.quantity-controls button.is-plus-animated {
  animation: qty-contour-pulse-plus 0.58s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.quantity-controls button.is-minus-animated {
  animation: qty-contour-pulse-minus 0.58s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.action-chip {
  height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border-radius: 18px;
  background: var(--tg-surface);
  color: var(--tg-text);
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(39, 75, 112, 0.08);
}

.action-chip--primary {
  background: var(--tg-blue);
  color: #ffffff;
}

.action-chip svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 14px;
}

.info-card,
.content-band {
  background: var(--tg-surface);
  border: 1px solid rgba(223, 231, 239, 0.75);
  box-shadow: 0 8px 22px rgba(39, 75, 112, 0.07);
}

.info-card {
  min-height: 82px;
  display: grid;
  align-content: center;
  gap: 8px;
  padding: 14px;
  border-radius: 20px;
}

.info-card strong {
  font-size: 15px;
}

.content-band {
  margin-top: 14px;
  padding: 18px;
  border-radius: 24px;
}

.catalog-band {
  padding-inline: 14px;
}

.catalog-grid,
.cart-list {
  display: grid;
  gap: 10px;
}

.catalog-grid {
  grid-template-columns: minmax(0, 1fr);
}

.catalog-search {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  padding: 0 14px;
  border-radius: 15px;
  background: #f2f7fb;
}

.catalog-search:focus-within {
  box-shadow: 0 0 0 2px rgba(42, 171, 238, 0.18);
}

.catalog-search__icon {
  width: 15px;
  height: 15px;
  position: relative;
  flex: 0 0 auto;
  border: 2px solid var(--tg-muted);
  border-radius: 50%;
}

.catalog-search__icon::after {
  content: "";
  width: 7px;
  height: 2px;
  position: absolute;
  right: -6px;
  bottom: -3px;
  border-radius: 99px;
  background: var(--tg-muted);
  transform: rotate(45deg);
}

.catalog-search input {
  min-width: 0;
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--tg-text);
  font: inherit;
  font-size: 16px;
  font-weight: 700;
  outline: none;
}

.catalog-search input::placeholder {
  color: #9aa8b6;
}

.catalog-filters {
  display: flex;
  gap: 8px;
  min-width: 0;
  margin: -2px -2px 12px;
  padding: 2px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  white-space: nowrap;
}

.catalog-filters::-webkit-scrollbar {
  display: none;
}

.catalog-filter {
  flex: 0 0 auto;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--tg-border);
  border-radius: 999px;
  background: var(--tg-surface);
  color: var(--tg-muted);
  font-size: 13px;
  font-weight: 700;
  transition: color 160ms ease, background-color 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.catalog-filter.is-active {
  border-color: var(--tg-blue);
  background: var(--tg-blue);
  color: #ffffff;
  box-shadow: 0 5px 12px rgba(42, 171, 238, 0.22);
}

.catalog-filter:focus-visible {
  outline: 2px solid var(--tg-blue-dark);
  outline-offset: 2px;
}

.catalog-card {
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--tg-border);
  border-radius: 20px;
  background: #f8fbfd;
}

.catalog-card.is-active {
  border-color: rgba(42, 171, 238, 0.58);
  box-shadow: 0 0 0 2px rgba(42, 171, 238, 0.1);
}

.catalog-card--preorder {
  border-color: rgba(217, 86, 86, 0.3);
  background:
    linear-gradient(140deg, rgba(217, 86, 86, 0.045), transparent 52%),
    #f8fbfd;
}

.catalog-card__main {
  position: relative;
  min-width: 0;
  display: grid;
  grid-template-columns: 106px minmax(0, 1fr);
  align-items: center;
  gap: 13px;
  padding: 0;
  background: transparent;
  text-align: left;
}

.catalog-card__media {
  position: relative;
  display: block;
  min-width: 0;
}

.catalog-card__visual {
  width: 106px;
  height: 106px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 15px;
  color: #ffffff;
  font-size: 38px;
  font-weight: 900;
}

img.catalog-card__visual {
  display: block;
  object-fit: contain;
  border-radius: 0;
  background: transparent;
  filter:
    drop-shadow(0 8px 8px rgba(46, 62, 74, 0.16))
    drop-shadow(0 2px 3px rgba(46, 62, 74, 0.1));
}

.availability-badge {
  --status-color: var(--tg-green);
  --status-halo: rgba(48, 199, 117, 0.15);
  max-width: calc(100% - 8px);
  position: absolute;
  left: 4px;
  bottom: 4px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 6px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: #148750;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.01em;
  box-shadow: 0 3px 10px rgba(23, 33, 43, 0.08);
  backdrop-filter: blur(8px);
}

.availability-badge .status-dot {
  width: 6px;
  height: 6px;
}

.availability-badge span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.catalog-card__visual--red {
  background: linear-gradient(135deg, #b84457, #873042);
}

.catalog-card__visual--blue {
  background: linear-gradient(135deg, #2aabee, #177fbb);
}

.catalog-card__visual--mint {
  background: linear-gradient(135deg, #36c981, #1b9460);
}

.catalog-card__copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.availability--low-stock {
  --status-color: var(--tg-yellow);
  --status-halo: rgba(213, 155, 24, 0.2);
}

.availability--preorder {
  --status-color: var(--tg-red);
  --status-halo: rgba(217, 86, 86, 0.2);
}

.status-line.availability--low-stock,
.availability-badge.availability--low-stock {
  color: #966300;
}

.status-line.availability--preorder,
.availability-badge.availability--preorder {
  color: #b33e3e;
}

.catalog-card__copy strong {
  font-family: var(--font-display);
  display: -webkit-box;
  overflow: hidden;
  padding-right: 32px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.25;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.catalog-card__open {
  position: absolute;
  top: 0;
  right: 0;
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(42, 171, 238, 0.2);
  border-radius: 50%;
  background: rgba(42, 171, 238, 0.07);
  color: var(--tg-blue-dark);
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.catalog-card__open svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media (hover: hover) {
  .catalog-card__main:hover .catalog-card__open {
    border-color: rgba(42, 171, 238, 0.38);
    background: rgba(42, 171, 238, 0.13);
    transform: translateX(1px);
  }
}

.catalog-card__main:active .catalog-card__open {
  transform: scale(0.94);
}

.catalog-card__main:focus-visible {
  outline: 2px solid var(--tg-blue-dark);
  outline-offset: 3px;
  border-radius: 14px;
}

.catalog-card__copy small {
  color: var(--tg-muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.3;
}

.catalog-card__copy b {
  color: var(--tg-text);
  font-size: 18px;
  font-variant-numeric: tabular-nums;
}

.catalog-card__details {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 8px;
  margin-top: 3px;
  padding-top: 8px;
  border-top: 1px solid var(--tg-border);
}

.catalog-card__details > span {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.catalog-card__details small {
  color: var(--tg-muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.catalog-card__details b {
  overflow-wrap: anywhere;
  color: var(--tg-text);
  font-size: 11px;
  font-weight: 750;
  line-height: 1.25;
}

.catalog-card__footer {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--tg-border);
}

.catalog-card__question {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 11px;
  border-radius: 13px;
  background: transparent;
  color: var(--tg-blue-dark);
  font-size: 12px;
  font-weight: 800;
}

.catalog-card__question > span {
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-size: 12px;
}

.catalog-card__question:focus-visible,
.catalog-card__controls button:focus-visible {
  outline: 2px solid var(--tg-blue-dark);
  outline-offset: 2px;
}

.catalog-card__controls,
.cart-item__controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.catalog-card__controls {
  justify-content: flex-end;
}

.catalog-card__controls strong {
  flex: 0 0 24px;
  width: 24px;
  text-align: center;
  color: var(--tg-text);
  font-size: 14px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 44px;
}

.catalog-card__controls button,
.cart-item__controls button {
  position: relative;
  overflow: visible;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #e5f4fd;
  color: var(--tg-blue-dark);
  font-size: 20px;
  font-weight: 800;
  transition:
    color 160ms ease,
    background-color 160ms ease;
}

.catalog-card__controls button.is-plus-animated,
.catalog-card__controls button.is-minus-animated,
.cart-item__controls button.is-plus-animated,
.cart-item__controls button.is-minus-animated {
  transition: none;
}

.catalog-card__controls button.is-plus-animated,
.cart-item__controls button.is-plus-animated {
  animation: qty-contour-pulse-plus 0.58s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.catalog-card__controls button.is-minus-animated,
.cart-item__controls button.is-minus-animated {
  animation: qty-contour-pulse-minus 0.58s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes qty-contour-pulse-plus {
  0% {
    transform: scale(0.96);
    box-shadow: 0 0 0 2px rgba(48, 199, 117, 0.55);
    background-color: #e8fff3;
    color: #149457;
  }

  28% {
    transform: scale(1);
    box-shadow: 0 0 0 3px rgba(48, 199, 117, 0.78);
    background-color: #e8fff3;
    color: #149457;
  }

  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 transparent;
    background-color: #e5f4fd;
    color: #178dcc;
  }
}

@keyframes qty-contour-pulse-minus {
  0% {
    transform: scale(0.96);
    box-shadow: 0 0 0 2px rgba(217, 86, 86, 0.55);
    background-color: #fff0f0;
    color: #b33e3e;
  }

  28% {
    transform: scale(1);
    box-shadow: 0 0 0 3px rgba(217, 86, 86, 0.78);
    background-color: #fff0f0;
    color: #b33e3e;
  }

  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 transparent;
    background-color: #e5f4fd;
    color: #178dcc;
  }
}

@keyframes qty-contour-pulse-plus-dark {
  0% {
    transform: scale(0.96);
    box-shadow: 0 0 0 2px rgba(48, 199, 117, 0.55);
    background-color: rgba(48, 199, 117, 0.22);
    color: #4dd68a;
  }

  28% {
    transform: scale(1);
    box-shadow: 0 0 0 3px rgba(48, 199, 117, 0.78);
    background-color: rgba(48, 199, 117, 0.22);
    color: #4dd68a;
  }

  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 transparent;
    background-color: rgba(42, 171, 238, 0.15);
    color: #64b5ef;
  }
}

@keyframes qty-contour-pulse-minus-dark {
  0% {
    transform: scale(0.96);
    box-shadow: 0 0 0 2px rgba(217, 86, 86, 0.55);
    background-color: rgba(217, 86, 86, 0.22);
    color: #e87a7a;
  }

  28% {
    transform: scale(1);
    box-shadow: 0 0 0 3px rgba(217, 86, 86, 0.78);
    background-color: rgba(217, 86, 86, 0.22);
    color: #e87a7a;
  }

  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 transparent;
    background-color: rgba(42, 171, 238, 0.15);
    color: #64b5ef;
  }
}

.cart-item__quantity {
  width: 38px;
  height: 34px;
  border: 0;
  border-radius: 12px;
  background: #ffffff;
  color: var(--tg-text);
  font: inherit;
  font-size: 16px;
  font-weight: 800;
  text-align: center;
  outline: none;
  box-shadow: inset 0 0 0 1px rgba(42, 171, 238, 0.12);
  appearance: textfield;
}

.cart-item__quantity:focus {
  box-shadow:
    inset 0 0 0 1px rgba(42, 171, 238, 0.2),
    0 0 0 2px rgba(42, 171, 238, 0.18);
}

.cart-item__quantity::-webkit-outer-spin-button,
.cart-item__quantity::-webkit-inner-spin-button {
  margin: 0;
  appearance: none;
}

.catalog-empty {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 20px 12px 8px;
  color: var(--tg-muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
  text-align: center;
}

.catalog-empty[hidden] {
  display: none;
}

.catalog-empty button {
  min-height: 44px;
  max-width: 100%;
  padding: 0 18px;
  border-radius: 16px;
  background: var(--tg-blue);
  color: #ffffff;
  font-size: 14px;
  font-weight: 800;
  box-shadow: 0 10px 22px rgba(42, 171, 238, 0.22);
}

.cart-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 16px;
  background: #f2f7fb;
}

.cart-item div:first-child {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.cart-item span {
  color: var(--tg-muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
}

.empty-cart {
  display: grid;
  gap: 8px;
  justify-items: start;
  padding: 16px;
  border-radius: 16px;
  background:
    radial-gradient(circle at 100% 0%, rgba(42, 171, 238, 0.12), transparent 36%),
    #f2f7fb;
}

.empty-cart strong {
  font-size: 15px;
}

.empty-cart span {
  color: var(--tg-muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
}

.empty-cart button {
  min-height: 40px;
  padding: 0 13px;
  border-radius: 14px;
  background: #e5f4fd;
  color: var(--tg-blue-dark);
  font-weight: 800;
}

.order-submit {
  min-height: 52px;
  border-radius: 17px;
  background: var(--tg-blue);
  color: #ffffff;
  font-weight: 800;
}

.section-title {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 14px;
}

.section-title h2 {
  margin: 0;
  font-size: 20px;
}

.clear-cart {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 7px 9px 7px 7px;
  border-radius: 14px;
  background: #e5f4fd;
  color: var(--tg-blue-dark);
  font-size: 12px;
  font-weight: 800;
}

.clear-cart__icon {
  font-size: 18px;
  line-height: 0.75;
}

.clear-cart:disabled {
  cursor: default;
  opacity: 0.46;
}

.product-description {
  display: grid;
  gap: 10px;
}

.product-summary {
  display: grid;
  gap: 14px;
}

.product-desc-section {
  display: grid;
  gap: 7px;
  padding-top: 2px;
}

.product-desc-section + .product-desc-section {
  padding-top: 12px;
  border-top: 1px solid rgba(223, 231, 239, 0.9);
}

.product-desc-section__title {
  margin: 0;
  color: var(--tg-muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.product-summary p,
.product-desc-list {
  margin: 0;
  color: #526170;
  font-size: 14px;
  line-height: 1.5;
}

.product-desc-list {
  padding-left: 18px;
}

.product-desc-list li + li {
  margin-top: 6px;
}

.order-box {
  display: grid;
  gap: 13px;
}

.notice {
  padding: 12px 13px;
  border-radius: 16px;
  background: #fff8e8;
  color: #7a5a13;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
  box-shadow: inset 0 0 0 1px rgba(211, 154, 31, 0.14);
}

.text-field {
  width: 100%;
  min-height: 50px;
  border: 0;
  border-radius: 17px;
  background: #f2f7fb;
  color: var(--tg-text);
  font: inherit;
  font-size: 16px;
  font-weight: 700;
  outline: none;
  padding: 0 15px;
}

.text-field::placeholder {
  color: #9aa8b6;
  font-weight: 600;
}

.text-field:focus {
  box-shadow: 0 0 0 2px rgba(42, 171, 238, 0.18);
}

.text-field.is-invalid,
.text-field.is-invalid:focus {
  background: #fff4f4;
  box-shadow:
    inset 0 0 0 1px rgba(217, 86, 86, 0.28),
    0 0 0 3px rgba(217, 86, 86, 0.16);
  animation: invalid-field-pulse 0.72s ease both;
}

@keyframes invalid-field-pulse {
  0%,
  100% {
    transform: translateX(0);
  }

  24% {
    transform: translateX(-2px);
  }

  48% {
    transform: translateX(2px);
  }
}

.field-note {
  margin: -4px 0 0;
  color: var(--tg-muted);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.45;
}

.total-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 2px;
}

.total-row span {
  color: var(--tg-muted);
  font-weight: 700;
}

.total-row strong {
  font-size: 22px;
}

.product-sheet[hidden] {
  display: none;
}

.product-sheet {
  position: fixed;
  inset: 0;
  z-index: 19;
  display: grid;
  align-items: end;
  padding: 16px 16px calc(88px + var(--safe-bottom));
}

.product-sheet__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(23, 33, 43, 0.35);
}

.product-sheet.is-opening .product-sheet__panel {
  animation: product-sheet-open 0.52s cubic-bezier(0.32, 0.72, 0, 1) both;
}

.product-sheet.is-closing .product-sheet__panel {
  animation: product-sheet-close 0.38s cubic-bezier(0.4, 0, 0.85, 0.6) both;
}

.product-sheet.is-opening .product-sheet__backdrop {
  animation: product-sheet-backdrop-in 0.38s cubic-bezier(0.32, 0.72, 0, 1) both;
}

@keyframes product-sheet-open {
  from {
    transform: translate3d(0, 100%, 0);
    opacity: 0.94;
  }

  to {
    transform: translate3d(0, 0, 0);
    opacity: 1;
  }
}

@keyframes product-sheet-close {
  from {
    transform: translate3d(0, 0, 0);
    opacity: 1;
  }

  to {
    transform: translate3d(0, 100%, 0);
    opacity: 0.94;
  }
}

@keyframes product-sheet-backdrop-in {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.product-sheet__panel {
  position: relative;
  width: min(100%, 492px);
  max-height: min(88vh, 820px);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 28px;
  background: var(--tg-surface);
  border: 1px solid var(--tg-border);
  box-shadow: var(--shadow);
  transform: translate3d(0, 0, 0);
  will-change: transform;
}

.product-sheet__header-wrap {
  flex: 0 0 auto;
  padding: 16px 18px 0;
}

.product-sheet__scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overflow-anchor: none;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  padding: 0 18px calc(18px + var(--safe-bottom));
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.product-sheet__scroll > * {
  flex: 0 0 auto;
}

.product-sheet__header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
}

.product-sheet__header span {
  color: var(--tg-blue-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.product-sheet__header h2 {
  margin: 4px 0 0;
  font-size: 20px;
  line-height: 1.15;
}

.product-sheet__close {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 13px;
  background: #e5f4fd;
  color: var(--tg-blue-dark);
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
}

.product-sheet .product-detail-card {
  --detail-photo-size: min(230px, 52vw);
  --detail-photo-overlap: calc(var(--detail-photo-size) * 0.2);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-height: auto;
  padding: 18px;
}

.product-sheet .detail-product-photo {
  position: relative;
  top: auto;
  left: auto;
  transform: none;
  width: 100%;
  max-width: var(--detail-photo-size);
  margin: 0 auto;
  flex: 0 0 auto;
  z-index: 1;
}

.product-sheet .product-detail-card__status {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 3;
  max-width: calc(100% - 28px);
  padding: 6px 10px;
  gap: 5px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: -0.01em;
  box-shadow: 0 4px 14px rgba(23, 33, 43, 0.08);
}

.product-sheet .product-detail-card__status .status-dot {
  width: 6px;
  height: 6px;
}

.product-sheet .product-detail-card__status span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-sheet .product-detail-card__content {
  margin-top: calc(-1 * var(--detail-photo-overlap));
  position: relative;
  z-index: 2;
}

.product-sheet .product-detail-card h1 {
  margin-top: 0;
  max-width: 100%;
  font-size: clamp(20px, 5.2vw, 27px);
  line-height: 1.14;
  font-weight: 600;
  letter-spacing: -0.03em;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
  word-break: break-word;
}

.product-sheet .product-detail-card p {
  overflow: visible;
  word-break: break-word;
}

.product-sheet .price-panel {
  align-items: flex-start;
  flex-direction: column;
  gap: 8px;
}

.product-sheet .price-panel > span {
  align-self: flex-start;
  white-space: normal;
  text-align: left;
}

.product-sheet .quick-actions {
  margin-top: 0;
}

.product-sheet .info-grid {
  margin-top: 0;
  grid-template-columns: 1fr;
  gap: 8px;
}

.product-sheet .info-card {
  min-height: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 14px;
}

.product-sheet .info-card span {
  flex: 0 0 auto;
}

.product-sheet .info-card strong {
  flex: 1 1 auto;
  min-width: 0;
  text-align: right;
  word-break: break-word;
  line-height: 1.35;
}

.product-sheet .content-band {
  margin-top: 0;
}

.ask-confirm[hidden] {
  display: none;
}

.ask-confirm {
  position: fixed;
  inset: 0;
  z-index: 21;
  display: grid;
  place-items: center;
  padding: 16px;
}

.ask-confirm__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(23, 33, 43, 0.42);
  backdrop-filter: blur(8px);
}

.ask-confirm__panel {
  position: relative;
  width: min(100%, 380px);
  display: grid;
  gap: 12px;
  padding: 18px;
  border-radius: 24px;
  background:
    radial-gradient(circle at 92% 0%, rgba(42, 171, 238, 0.14), transparent 32%),
    var(--tg-surface);
  border: 1px solid var(--tg-border);
  box-shadow: var(--shadow);
}

.ask-confirm__header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.ask-confirm__header span {
  color: var(--tg-blue-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.ask-confirm__header h2 {
  margin: 4px 0 0;
  font-size: 20px;
  line-height: 1.15;
}

.ask-confirm__close {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 13px;
  background: #e5f4fd;
  color: var(--tg-blue-dark);
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
}

.ask-confirm__text {
  margin: 0;
  color: var(--tg-muted);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45;
}

.ask-confirm__product {
  padding: 12px 14px;
  border-radius: 16px;
  background: #f2f7fb;
  color: var(--tg-text);
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.35;
  word-break: break-word;
}

.ask-confirm__submit,
.ask-confirm__cancel {
  min-height: 50px;
  border-radius: 17px;
  font-weight: 800;
}

.ask-confirm__submit {
  background: var(--tg-blue);
  color: #ffffff;
  box-shadow: 0 10px 22px rgba(42, 171, 238, 0.22);
}

.ask-confirm__cancel {
  background: #e5f4fd;
  color: var(--tg-blue-dark);
}

.order-confirm[hidden] {
  display: none;
}

.order-confirm {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  align-items: end;
  padding: 16px;
}

.order-confirm__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(23, 33, 43, 0.42);
  backdrop-filter: blur(8px);
}

.order-confirm__panel {
  position: relative;
  width: min(100%, 492px);
  max-height: min(82vh, 680px);
  margin: 0 auto;
  display: grid;
  gap: 12px;
  overflow: auto;
  padding: 18px;
  border-radius: 26px;
  background:
    radial-gradient(circle at 92% 0%, rgba(42, 171, 238, 0.14), transparent 32%),
    var(--tg-surface);
  box-shadow: 0 24px 70px rgba(23, 33, 43, 0.24);
}

.order-confirm__header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.order-confirm__header span {
  color: var(--tg-blue-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.order-confirm__header h2 {
  margin: 4px 0 0;
  font-size: 22px;
}

.order-confirm__close {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 13px;
  background: #e5f4fd;
  color: var(--tg-blue-dark);
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
}

.order-confirm__list {
  display: grid;
  gap: 8px;
}

.order-confirm-item,
.order-confirm__meta,
.order-confirm__total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 16px;
  background: #f2f7fb;
}

.order-confirm-item div {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.order-confirm-item strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.order-confirm-item span,
.order-confirm__meta span,
.order-confirm__total span,
.order-confirm__panel p {
  color: var(--tg-muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
}

.order-confirm-item b,
.order-confirm__meta strong,
.order-confirm__total strong {
  flex: 0 0 auto;
  color: var(--tg-text);
  font-size: 15px;
}

.order-confirm__total {
  background: #eaf7ff;
}

.order-confirm__total strong {
  color: var(--tg-blue-dark);
  font-size: 22px;
}

.order-confirm__panel p {
  margin: 0;
}

.order-confirm__submit,
.order-confirm__edit {
  min-height: 50px;
  border-radius: 17px;
  font-weight: 800;
}

.order-confirm__submit {
  background: var(--tg-blue);
  color: #ffffff;
}

.order-confirm__edit {
  background: #e5f4fd;
  color: var(--tg-blue-dark);
}

.bottom-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  padding: 10px 12px calc(10px + var(--safe-bottom));
  background: color-mix(in srgb, var(--tg-bg) 88%, transparent);
  backdrop-filter: blur(18px);
}

.primary-cta {
  width: min(100%, 492px);
  min-height: 64px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto 36px;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--tg-blue), #1c91d2);
  color: #ffffff;
  box-shadow: 0 14px 30px rgba(42, 171, 238, 0.32);
}

.primary-cta__icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.18);
}

.primary-cta__icon svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.primary-cta__copy,
.primary-cta__total {
  min-width: 0;
  display: grid;
  gap: 1px;
  text-align: left;
}

.primary-cta__copy > span {
  overflow: hidden;
  font-size: 14px;
  font-weight: 850;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.primary-cta small {
  color: rgba(255, 255, 255, 0.78);
  font-size: 11px;
  font-weight: 700;
}

.primary-cta__total {
  justify-items: end;
  text-align: right;
}

.primary-cta__total strong {
  font-size: 16px;
  line-height: 1.15;
  white-space: nowrap;
}

.primary-cta__next {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.18);
  font-size: 20px;
  font-weight: 900;
}

.primary-cta [hidden] {
  display: none;
}

.bottom-bar.is-empty {
  background: linear-gradient(to top, color-mix(in srgb, var(--tg-bg) 96%, transparent), transparent);
  backdrop-filter: none;
  pointer-events: none;
}

.bottom-bar.is-empty .primary-cta {
  width: auto;
  min-height: 50px;
  grid-template-columns: 34px auto;
  padding: 6px 14px 6px 8px;
  border-radius: 17px;
  background: color-mix(in srgb, var(--tg-text) 78%, var(--tg-surface));
  box-shadow: 0 10px 24px rgba(23, 33, 43, 0.18);
  pointer-events: auto;
}

.bottom-bar.is-empty .primary-cta__icon {
  width: 34px;
  height: 34px;
  border-radius: 11px;
}

.primary-cta:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--tg-blue) 50%, white);
  outline-offset: 3px;
}

.is-telegram-webapp .topbar {
  top: var(--safe-top);
}

.is-telegram-webapp .app-shell {
  padding-top: calc(12px + var(--safe-top));
  padding-bottom: 12px;
}

.is-telegram-webapp.is-keyboard-open .app-shell {
  padding-bottom: calc(12px + var(--keyboard-inset));
}

.is-keyboard-open .bottom-bar {
  display: none;
}

.is-telegram-webapp .bottom-bar {
  display: none;
}

.is-telegram-webapp .product-sheet,
.is-telegram-webapp .order-confirm {
  padding: calc(16px + var(--safe-top)) 16px calc(8px + var(--bottom-overlay-inset, 12px));
}

.is-telegram-webapp .product-sheet__scroll {
  padding-bottom: 18px;
}

.is-telegram-webapp .toast {
  bottom: calc(8px + var(--bottom-overlay-inset, 12px));
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(86px + var(--safe-bottom));
  z-index: 12;
  width: max-content;
  max-width: 80%;
  padding: 12px 16px;
  border-radius: 16px;
  background: rgba(23, 33, 43, 0.92);
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
  opacity: 0;
  transform: translate(-50%, 12px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

:root[data-theme-resolved="dark"] {
  --tg-bg: #0e1621;
  --tg-surface: #17212b;
  --tg-text: #f5f5f7;
  --tg-muted: rgba(235, 235, 245, 0.62);
  --tg-blue: #2aabee;
  --tg-blue-dark: #64b5ef;
  --tg-green: #30c775;
  --tg-yellow: #e8b84a;
  --tg-red: #e87a7a;
  --tg-border: rgba(255, 255, 255, 0.08);
  --shadow: 0 18px 45px rgba(0, 0, 0, 0.35);
}

:root[data-theme-resolved="dark"] .icon-button,
:root[data-theme-resolved="dark"] .quantity-controls,
:root[data-theme-resolved="dark"] .action-chip:not(.action-chip--primary) {
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.22);
}

:root[data-theme-resolved="dark"] .product-detail-card {
  background:
    radial-gradient(circle at 18% 22%, rgba(48, 199, 117, 0.12), transparent 30%),
    radial-gradient(circle at 84% 10%, rgba(42, 171, 238, 0.12), transparent 34%),
    linear-gradient(160deg, #1a2634 0%, #17212b 54%, #152232 100%);
}

:root[data-theme-resolved="dark"] .product-detail-card p,
:root[data-theme-resolved="dark"] .product-summary p,
:root[data-theme-resolved="dark"] .product-desc-list {
  color: rgba(235, 235, 245, 0.72);
}

:root[data-theme-resolved="dark"] .status-line,
:root[data-theme-resolved="dark"] .availability-badge {
  background: rgba(23, 33, 43, 0.72);
  border-color: rgba(255, 255, 255, 0.1);
  color: #4dd68a;
}

:root[data-theme-resolved="dark"] .status-line.availability--low-stock,
:root[data-theme-resolved="dark"] .availability-badge.availability--low-stock {
  color: #e8b84a;
}

:root[data-theme-resolved="dark"] .status-line.availability--preorder,
:root[data-theme-resolved="dark"] .availability-badge.availability--preorder {
  color: #e87a7a;
}

:root[data-theme-resolved="dark"] .price-panel {
  background: rgba(23, 33, 43, 0.82);
  box-shadow: inset 0 0 0 1px rgba(42, 171, 238, 0.16);
}

:root[data-theme-resolved="dark"] .info-card,
:root[data-theme-resolved="dark"] .content-band {
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.28);
}

:root[data-theme-resolved="dark"] .catalog-search {
  background: #1a2634;
}

:root[data-theme-resolved="dark"] .catalog-filter {
  border-color: rgba(255, 255, 255, 0.12);
  background: #1a2634;
  color: rgba(235, 235, 245, 0.7);
}

:root[data-theme-resolved="dark"] .catalog-filter.is-active {
  border-color: var(--tg-blue);
  background: var(--tg-blue);
  color: #ffffff;
}

:root[data-theme-resolved="dark"] .catalog-search input::placeholder,
:root[data-theme-resolved="dark"] .text-field::placeholder {
  color: rgba(235, 235, 245, 0.45);
}

:root[data-theme-resolved="dark"] .catalog-card {
  background: #1a2634;
}

:root[data-theme-resolved="dark"] .catalog-card--preorder {
  background:
    linear-gradient(140deg, rgba(232, 122, 122, 0.08), transparent 52%),
    #1a2634;
}

:root[data-theme-resolved="dark"] .catalog-card__details,
:root[data-theme-resolved="dark"] .catalog-card__footer {
  border-color: rgba(255, 255, 255, 0.08);
}

:root[data-theme-resolved="dark"] .catalog-card__controls button,
:root[data-theme-resolved="dark"] .cart-item__controls button,
:root[data-theme-resolved="dark"] .quantity-controls button {
  background: rgba(42, 171, 238, 0.15);
}

:root[data-theme-resolved="dark"] .catalog-card__controls button.is-plus-animated,
:root[data-theme-resolved="dark"] .cart-item__controls button.is-plus-animated,
:root[data-theme-resolved="dark"] .quantity-controls button.is-plus-animated {
  animation-name: qty-contour-pulse-plus-dark;
}

:root[data-theme-resolved="dark"] .catalog-card__controls button.is-minus-animated,
:root[data-theme-resolved="dark"] .cart-item__controls button.is-minus-animated,
:root[data-theme-resolved="dark"] .quantity-controls button.is-minus-animated {
  animation-name: qty-contour-pulse-minus-dark;
}

:root[data-theme-resolved="dark"] .cart-item__quantity {
  background: #17212b;
  box-shadow: inset 0 0 0 1px rgba(42, 171, 238, 0.18);
}

:root[data-theme-resolved="dark"] .cart-item__quantity:focus {
  box-shadow:
    inset 0 0 0 1px rgba(42, 171, 238, 0.28),
    0 0 0 2px rgba(42, 171, 238, 0.22);
}

:root[data-theme-resolved="dark"] .cart-item,
:root[data-theme-resolved="dark"] .empty-cart,
:root[data-theme-resolved="dark"] .text-field,
:root[data-theme-resolved="dark"] .ask-confirm__product,
:root[data-theme-resolved="dark"] .order-confirm-item,
:root[data-theme-resolved="dark"] .order-confirm__meta {
  background: #1a2634;
}

:root[data-theme-resolved="dark"] .empty-cart {
  background:
    radial-gradient(circle at 100% 0%, rgba(42, 171, 238, 0.12), transparent 36%),
    #1a2634;
}

:root[data-theme-resolved="dark"] .empty-cart button,
:root[data-theme-resolved="dark"] .clear-cart,
:root[data-theme-resolved="dark"] .ask-confirm__cancel,
:root[data-theme-resolved="dark"] .order-confirm__edit,
:root[data-theme-resolved="dark"] .product-sheet__close,
:root[data-theme-resolved="dark"] .ask-confirm__close,
:root[data-theme-resolved="dark"] .order-confirm__close {
  background: rgba(42, 171, 238, 0.15);
}

:root[data-theme-resolved="dark"] .notice {
  background: rgba(213, 155, 24, 0.12);
  color: #e8b84a;
  box-shadow: inset 0 0 0 1px rgba(213, 155, 24, 0.18);
}

:root[data-theme-resolved="dark"] .text-field.is-invalid,
:root[data-theme-resolved="dark"] .text-field.is-invalid:focus {
  background: rgba(217, 86, 86, 0.12);
}

:root[data-theme-resolved="dark"] .product-desc-section + .product-desc-section {
  border-top-color: rgba(255, 255, 255, 0.08);
}

:root[data-theme-resolved="dark"] .product-sheet__backdrop,
:root[data-theme-resolved="dark"] .ask-confirm__backdrop,
:root[data-theme-resolved="dark"] .order-confirm__backdrop {
  background: rgba(0, 0, 0, 0.55);
}

:root[data-theme-resolved="dark"] .order-confirm__panel {
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}

:root[data-theme-resolved="dark"] .order-confirm__total {
  background: rgba(42, 171, 238, 0.18);
}

:root[data-theme-resolved="dark"] .toast {
  background: rgba(245, 245, 247, 0.92);
  color: #17212b;
}

@media (prefers-reduced-motion: reduce) {
  .theme-toggle__icon {
    transition: none;
  }

  .status-dot {
    animation: none;
  }

  .product-sheet__panel {
    will-change: auto;
  }

  .product-sheet.is-opening .product-sheet__panel,
  .product-sheet.is-closing .product-sheet__panel,
  .product-sheet.is-opening .product-sheet__backdrop {
    animation: none;
  }

  .catalog-card__controls button.is-plus-animated,
  .catalog-card__controls button.is-minus-animated,
  .quantity-controls button.is-plus-animated,
  .quantity-controls button.is-minus-animated,
  .cart-item__controls button.is-plus-animated,
  .cart-item__controls button.is-minus-animated {
    animation: none;
    transform: none;
    box-shadow: none;
  }
}

@media (max-width: 380px) {
  .app-shell {
    padding-inline: 10px;
  }

  .product-detail-card {
    min-height: 468px;
    padding: 18px;
    border-radius: 26px;
  }

  .product-sheet .product-detail-card {
    --detail-photo-size: min(200px, 56vw);
  }

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

  .price-panel {
    align-items: start;
    flex-direction: column;
  }

  .catalog-card__main {
    grid-template-columns: 94px minmax(0, 1fr);
    gap: 10px;
  }

  .catalog-card__visual {
    width: 94px;
    height: 94px;
  }

  .catalog-card__question {
    padding-inline: 8px;
  }

  .primary-cta {
    grid-template-columns: 34px minmax(0, 1fr) auto 32px;
    gap: 7px;
    padding-inline: 8px;
  }

  .primary-cta__icon,
  .primary-cta__next {
    width: 32px;
    height: 32px;
  }

  .primary-cta__copy > span {
    font-size: 13px;
  }

  .primary-cta__total strong {
    font-size: 14px;
  }
}
.seo-catalog-item { padding: 1rem; border: 1px solid var(--border, #dce5eb); border-radius: 1rem; background: var(--surface, #fff); }
.seo-catalog-item h3 { margin: 0 0 .5rem; font-size: 1rem; }
.seo-catalog-item p { margin: .3rem 0; }
.handoff-summary { margin: 1.5rem 0; padding: 1rem; border: 1px solid #b5d9eb; border-radius: 1rem; background: #eef8fd; }
