@font-face {
  font-family: 'TT Norms Pro';
  src: url('/assets/fonts/TTNormsPro-Regular.ttf') format('truetype');
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: 'TT Norms Pro';
  src: url('/assets/fonts/TTNormsPro-Medium.ttf') format('truetype');
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
}

@font-face {
  font-family: 'TT Hoves';
  src: url('/assets/fonts/TTHoves-Regular.ttf') format('truetype');
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: 'TT Hoves';
  src: url('/assets/fonts/TTHoves-Medium.ttf') format('truetype');
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
}

/* ─────────────────────────────────────────────────────────────
   Цветочка — Telegram Mini App
   Визуальный язык взят с cvetochka.ru: белый лист, чёрный текст,
   фотография как главный герой, тонкие линии вместо рамок.
   Единственный акцент — приглушённая роза, он же цвет статуса в клубе.
   ───────────────────────────────────────────────────────────── */

:root {
  --paper: #ffffff;
  --sand: #f7f4f1;
  --ink: #14100f;
  --ink-soft: #8b8480;
  --line: #ece8e4;
  --accent: rgb(229, 39, 119);
  --accent-soft: #fff0f5;
  --brand-green: rgb(133, 176, 6);
  --ok: #2f7d5c;

  --radius: 16px;
  --gap: 14px;
  --tab-h: 68px;

  --font: 'TT Norms Pro', Arial, sans-serif;
  --font-display: 'TT Hoves', Arial, sans-serif;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  margin: 0;
  padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.45;
  overscroll-behavior-y: none;
}

button,
input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

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

/* ——— Каркас ——————————————————————————————————————————— */

.view {
  min-height: 100vh;
  padding-bottom: calc(var(--tab-h) + env(safe-area-inset-bottom, 0px) + 8px);
}

.page {
  padding: 0 var(--gap) 24px;
}

.page--flush {
  padding: 0 0 24px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--paper);
  padding: calc(env(safe-area-inset-top, 0px) + 8px) var(--gap) 0;
  box-shadow: 0 1px 0 rgba(20, 16, 15, 0.04);
}

.topbar--plain {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 18px;
}

.topbar__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
  padding-bottom: 8px;
}

.brand-logo {
  display: block;
  width: 154px;
  height: auto;
  flex: 0 0 auto;
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: 2px;
}

.title {
  margin: 0;
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0.2px;
}

.icon-btn {
  position: relative;
  border: 0;
  background: none;
  width: 38px;
  height: 38px;
  padding: 8px;
  color: var(--ink);
  cursor: pointer;
  display: grid;
  place-items: center;
}

.icon-btn__badge {
  position: absolute;
  right: 0;
  top: 1px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: #db3f79;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
}

.product-topbar {
  position: sticky;
  top: 0;
  z-index: 25;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 42px;
  align-items: center;
  min-height: calc(60px + env(safe-area-inset-top, 0px));
  padding: env(safe-area-inset-top, 0px) var(--gap) 0;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid #efefef;
  backdrop-filter: blur(14px);
}

.product-topbar .icon-btn {
  justify-self: center;
}

.brand-logo--product {
  width: 162px;
  max-width: 100%;
  justify-self: center;
}

[data-view='product'] {
  padding-bottom: calc(var(--tab-h) + env(safe-area-inset-bottom, 0px) + 18px);
}

.searchbar {
  padding: 0 0 12px;
}

.searchbar input {
  width: 100%;
  height: 44px;
  border: 1px solid #dedede;
  border-radius: 22px;
  background: #fafafa;
  padding: 0 16px;
  outline: none;
}

.searchbar input:focus {
  border-color: var(--ink);
}

/* Полоса категорий — как горизонтальные подборки на сайте */
.chips {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-top: 10px;
  padding-bottom: 10px;
  background: #f0f0f0;
  border-radius: 0;
  margin: 0 calc(var(--gap) * -1);
  padding-left: var(--gap);
  padding-right: var(--gap);
}

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

.chip {
  flex: 0 0 auto;
  min-height: 38px;
  border: 0;
  border-radius: 20px;
  background: #fff;
  padding: 9px 14px;
  color: #4a4a4a;
  font-size: 10px;
  font-weight: 500;
  line-height: 20px;
  letter-spacing: 0.28px;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.chip:first-child {
  border-color: rgb(229, 39, 119);
  background: rgb(229, 39, 119);
  color: #fff;
}

.chip:nth-child(2) {
  border-color: rgb(133, 176, 6);
  background: rgb(133, 176, 6);
  color: #fff;
}

.chip.is-active {
  box-shadow: 0 0 0 2px rgba(20, 16, 15, 0.12);
}

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

/* ——— Заголовок и управление каталогом ————————————————— */

.catalog-head {
  padding-top: 0;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  font-size: 14px;
  color: #65605d;
}

.breadcrumbs strong {
  color: var(--ink);
  font-weight: 400;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.catalog-title {
  margin: 10px 0 26px;
  font-size: 34px;
  font-weight: 400;
  line-height: 36px;
  letter-spacing: 0.6px;
}

.sortbar {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  margin: 0 calc(var(--gap) * -1);
  padding: 0 var(--gap) 2px;
  scrollbar-width: none;
}

.sortbar::-webkit-scrollbar {
  display: none;
}

.sort-pill {
  flex: 0 0 auto;
  height: 38px;
  border: 1px solid #d9d9d9;
  border-radius: 21px;
  background: #fff;
  padding: 0 13px;
  color: #222;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.28px;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
}

.sort-pill.is-active {
  border-color: #252525;
  background: #252525;
  color: #fff;
}

.sort-pill__arrow {
  display: inline-block;
  margin-left: 5px;
  font-size: 14px;
  line-height: 1;
  transform: translateY(-1px);
}

.sort-pill[data-direction='desc'] .sort-pill__arrow {
  transform: translateY(1px) rotate(180deg);
}

.catalog-tools {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 70px;
  border-bottom: 1px solid #efefef;
}

.tool-btn,
.grid-toggle {
  border: 0;
  background: none;
  color: var(--ink);
  cursor: pointer;
}

.tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 0;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.28px;
  text-transform: uppercase;
}

.tool-btn.is-active {
  color: var(--accent);
}

.grid-toggle {
  display: grid;
  grid-template-columns: repeat(2, 6px);
  grid-template-rows: repeat(2, 6px);
  gap: 4px;
  width: 38px;
  height: 38px;
  place-content: center;
  padding: 8px;
}

.grid-toggle span {
  width: 6px;
  height: 6px;
  border-radius: 1px;
  background: currentColor;
}

.grid-toggle[aria-pressed='true'] {
  grid-template-columns: repeat(2, 8px);
  grid-template-rows: repeat(2, 8px);
  gap: 2px;
}

.grid-toggle[aria-pressed='true'] span {
  width: 8px;
  height: 8px;
}

.filter-panel {
  padding: 16px 0 20px;
  border-bottom: 1px solid #efefef;
}

.filter-panel__label {
  margin-bottom: 10px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.filter-presets {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  scrollbar-width: none;
}

.filter-presets::-webkit-scrollbar {
  display: none;
}

.filter-presets button,
.filter-clear {
  flex: 0 0 auto;
  border: 1px solid #ddd;
  border-radius: 18px;
  background: #fff;
  padding: 8px 11px;
  font-size: 12px;
  cursor: pointer;
}

.filter-presets button.is-active {
  border-color: #252525;
  background: #252525;
  color: #fff;
}

.filter-clear {
  margin-top: 10px;
  border: 0;
  padding-left: 0;
  color: var(--accent);
}

/* ——— Сетка товаров ————————————————————————————————————— */

.grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 30px;
  padding-top: 24px;
}

.grid.is-compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 12px;
}

.card {
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.card__media {
  position: relative;
  aspect-ratio: 1;
  background: var(--sand);
  border-radius: 16px;
  overflow: hidden;
}

.card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.35s ease;
}

.card__media img.is-loaded {
  opacity: 1;
}

.card__badge {
  position: absolute;
  left: 12px;
  top: 12px;
  background: #db3f79;
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 9px;
  border-radius: 12px;
}

.card__heart {
  position: absolute;
  right: 12px;
  top: 12px;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  padding: 0;
  cursor: pointer;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.22));
}

.card__heart.is-active {
  background: rgba(255, 255, 255, 0.92);
  color: var(--accent);
}

.card__heart.is-active path,
.gallery-action--favorite.is-active path {
  fill: currentColor;
}

.card__info {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.card__line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.card__price {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0.36px;
  white-space: nowrap;
}

.card__price s {
  font-family: var(--font-display);
  color: var(--ink-soft);
  font-weight: 400;
  margin-left: 6px;
  font-size: 13px;
}

.card__name {
  font-size: 15px;
  line-height: 1.4;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Подпись «№ 2461 · M» — тот же приём, что в карточках на сайте */
.card__meta {
  flex: 0 0 auto;
  font-family: var(--font-display);
  font-size: 16px;
  letter-spacing: 0.24px;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.grid.is-compact .card {
  gap: 8px;
}

.grid.is-compact .card__media {
  border-radius: 12px;
}

.grid.is-compact .card__badge {
  left: 8px;
  top: 8px;
  padding: 3px 7px;
  font-size: 9px;
}

.grid.is-compact .card__heart {
  right: 7px;
  top: 7px;
  width: 28px;
  height: 28px;
}

.grid.is-compact .card__price {
  font-size: 16px;
  font-weight: 500;
}

.grid.is-compact .card__meta {
  display: none;
}

.grid.is-compact .card__name {
  font-size: 13px;
  line-height: 1.35;
}

.grid-status {
  padding: 26px 0;
  text-align: center;
  color: var(--ink-soft);
  font-size: 13px;
}

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

.product-crumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 18px var(--gap) 14px;
  overflow: hidden;
  color: #8b8178;
  font-size: 13px;
  white-space: nowrap;
}

.product-crumbs button {
  flex: 0 0 auto;
  border: 0;
  background: none;
  padding: 0;
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

.product-crumbs span:last-child {
  min-width: 0;
  overflow: hidden;
  color: var(--ink);
  text-overflow: ellipsis;
}

.product-gallery {
  position: relative;
  margin: 0 12px;
}

.gallery {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  border-radius: 16px;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  touch-action: pan-x pinch-zoom;
  overscroll-behavior-inline: contain;
}

.gallery::-webkit-scrollbar {
  display: none;
}

.gallery img {
  flex: 0 0 100%;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  scroll-snap-align: start;
  background: var(--sand);
}

.gallery-action {
  position: absolute;
  bottom: 14px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 0;
  background: transparent;
  padding: 0;
  color: #fff;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.35));
}

.gallery-action--share {
  left: 12px;
  cursor: pointer;
}

.gallery-action--favorite {
  right: 12px;
  cursor: pointer;
}

.gallery-action--favorite.is-active {
  color: #ff4f8d;
}

.gallery-nav {
  position: absolute;
  top: 50%;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.88);
  color: var(--ink);
  padding: 0;
  box-shadow: 0 2px 12px rgba(20, 16, 15, 0.12);
  transform: translateY(-50%);
  cursor: pointer;
}

.gallery-nav svg {
  width: 21px;
  height: 21px;
}

.gallery-nav--prev {
  left: 10px;
}

.gallery-nav--next {
  right: 10px;
}

.gallery-nav:disabled {
  opacity: 0.28;
}

.gallery-dots {
  position: absolute;
  left: 50%;
  bottom: 17px;
  z-index: 2;
  display: flex;
  gap: 5px;
  transform: translateX(-50%);
}

.gallery-dot {
  width: 5px;
  height: 5px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.55);
  padding: 0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.16);
}

.gallery-dot.is-active {
  background: #fff;
}

.product-body {
  padding: 26px var(--gap) 0;
}

.product-name {
  max-width: 350px;
  margin: 0 0 22px;
  font-size: 26px;
  font-weight: 500;
  line-height: 1.16;
  letter-spacing: -0.025em;
}

.product-promises {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0 0 22px;
  padding: 0;
  list-style: none;
  color: #57514d;
  font-size: 14px;
}

.product-promises li {
  display: flex;
  align-items: center;
  gap: 11px;
}

.promise-icon {
  display: grid;
  place-items: center;
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  border-radius: 50%;
}

.promise-icon--flower {
  width: 13px;
  height: 13px;
  margin: 2px;
  background: #ffd33d;
}

.promise-icon--check {
  border: 1.5px solid #918b86;
  color: #706b67;
  font-size: 11px;
  line-height: 1;
}

.product-price {
  font-family: var(--font-display);
  margin: 0 0 3px;
  font-size: 28px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.product-price s {
  font-family: var(--font-display);
  margin-left: 8px;
  color: var(--ink-soft);
  font-size: 17px;
  font-weight: 400;
}

.product-payment-note {
  margin: 0;
  color: #6f6864;
  font-size: 13px;
}

.product-payment-note span {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.product-actions {
  display: grid;
  gap: 10px;
  margin: 30px 0 38px;
}

.product-action {
  width: 100%;
  height: 54px;
  border: 0;
  border-radius: 27px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.025em;
  text-transform: uppercase;
  cursor: pointer;
}

.product-action--primary {
  background: #e02876;
  color: #fff;
}

.product-action--secondary {
  background: #f0eeec;
  color: #333;
}

.product-section {
  margin-top: 34px;
}

.product-section__title {
  margin: 0 0 18px;
  font-size: 23px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.015em;
}

.product-benefits {
  display: grid;
  gap: 13px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: #514c48;
  font-size: 14px;
}

.product-benefits li {
  display: flex;
  align-items: center;
  gap: 11px;
}

.product-benefits svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  color: #706b67;
}

.product-details {
  margin-top: 30px;
  border-top: 1px solid var(--line);
}

.product-details + .product-details {
  margin-top: 0;
}

.product-details summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  list-style: none;
}

.product-details summary::-webkit-details-marker {
  display: none;
}

.product-details summary::after {
  content: '+';
  color: #77716c;
  font-size: 22px;
  font-weight: 300;
}

.product-details[open] summary::after {
  content: '−';
}

.product-details__body {
  padding: 0 0 20px;
}

.product-desc {
  margin: 0;
  color: #4a4441;
  font-size: 14px;
  line-height: 1.6;
}

.spec {
  margin: 0;
}

.spec__row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid #f0ece9;
  font-size: 13px;
}

.spec__row dt {
  color: var(--ink-soft);
  margin: 0;
}

.spec__row dd {
  margin: 0;
  text-align: right;
}

.section-head {
  margin: 32px 0 4px;
  padding: 0 var(--gap);
  font-size: 15px;
  font-weight: 600;
}

.rail {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 14px var(--gap) 4px;
}

.rail::-webkit-scrollbar {
  display: none;
}

.rail .card {
  flex: 0 0 40vw;
  max-width: 170px;
}

[data-view='product'] .section-head {
  margin: 38px 0 4px;
  font-size: 23px;
  font-weight: 500;
  letter-spacing: -0.015em;
}

[data-view='product'] .rail {
  padding-top: 16px;
  padding-bottom: 18px;
}

.rail .card__price {
  font-size: 15px;
  font-weight: 600;
}

.rail .card__meta {
  display: none;
}

.rail .card__name {
  font-size: 13px;
}

/* ——— Корзина и формы ————————————————————————————————— */

.line {
  display: flex;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.line__img {
  width: 66px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 4px;
  background: var(--sand);
  flex: 0 0 auto;
}

.line__body {
  flex: 1;
  min-width: 0;
}

.line__name {
  font-size: 13.5px;
  line-height: 1.35;
  margin-bottom: 4px;
}

.line__price {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 14px;
}

.stepper {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: 4px;
}

.stepper button {
  width: 30px;
  height: 28px;
  border: 0;
  background: none;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  color: var(--ink);
}

.stepper span {
  min-width: 22px;
  text-align: center;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 5px;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: none;
  padding: 7px 0;
  outline: none;
  border-radius: 0;
}

.field input:focus,
.field textarea:focus {
  border-bottom-color: var(--ink);
}

.field textarea {
  resize: none;
  min-height: 48px;
}

.field--row {
  display: flex;
  gap: 14px;
}

.field--row > * {
  flex: 1;
}

.check {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  font-size: 14px;
}

.check input {
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
}

.totals {
  margin-top: 20px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.totals__row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  font-size: 14px;
  color: #4a4441;
}

.totals__row--sum {
  font-family: var(--font-display);
  margin-top: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 17px;
  font-weight: 600;
  color: var(--ink);
}

.totals__row--bonus {
  color: var(--accent);
}

/* ——— Бонусный блок ————————————————————————————————— */

.bonus-card {
  background: var(--accent-soft);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 20px;
}

.bonus-card__status {
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
}

.bonus-card__value {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 6px 0 2px;
}

.bonus-card__hint {
  font-size: 13px;
  color: #6b5b60;
}

.bonus-slider {
  margin-top: 14px;
}

.bonus-slider input[type='range'] {
  width: 100%;
  accent-color: var(--accent);
}

.progress {
  height: 3px;
  background: #fff;
  border-radius: 2px;
  overflow: hidden;
  margin-top: 12px;
}

.progress__bar {
  height: 100%;
  background: var(--accent);
}

/* ——— Кнопки, состояния ————————————————————————————— */

.btn {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 4px;
  background: var(--ink);
  color: #fff;
  padding: 14px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
}

.btn--ghost {
  background: none;
  color: var(--ink);
  border: 1px solid var(--line);
}

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

.empty {
  text-align: center;
  padding: 64px 20px;
  color: var(--ink-soft);
}

.empty__title {
  color: var(--ink);
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 6px;
}

.empty .btn {
  margin-top: 22px;
  max-width: 240px;
  margin-inline: auto;
}

.skeleton {
  background: var(--sand);
  border-radius: var(--radius);
  animation: pulse 1.4s ease-in-out infinite;
}

.skeleton--card {
  aspect-ratio: 1;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.55;
  }
}

.note {
  font-size: 12.5px;
  color: var(--ink-soft);
  line-height: 1.5;
  margin-top: 12px;
}

.order-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.order-row__status {
  color: var(--ink-soft);
  font-size: 12px;
}

/* ——— Нижняя навигация —————————————————————————————— */

.tabbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: var(--paper);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  height: calc(var(--tab-h) + env(safe-area-inset-bottom, 0px));
}

.tabbar[hidden] {
  display: none;
}

.tab {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border: 0;
  background: none;
  color: var(--ink-soft);
  padding: 5px 1px 3px;
  font-size: 9.5px;
  line-height: 1.1;
  cursor: pointer;
}

.tab.is-active {
  color: var(--ink);
  font-weight: 500;
}

.tab__icon {
  width: 23px;
  height: 23px;
}

.tab.is-active .tab__icon {
  color: var(--accent);
}

.tab__badge {
  position: absolute;
  top: 5px;
  left: 50%;
  transform: translateX(12px);
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  line-height: 16px;
  padding: 0 4px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--tab-h) + 20px);
  transform: translateX(-50%);
  z-index: 60;
  background: var(--ink);
  color: #fff;
  font-size: 13px;
  padding: 10px 16px;
  border-radius: 20px;
  max-width: 88vw;
  text-align: center;
}

/* В Telegram Desktop и при локальном просмотре сохраняем мобильную композицию. */
@media (min-width: 480px) {
  html,
  body {
    background: #f3f3f3;
  }

  #app {
    width: 100%;
    max-width: 430px;
    min-height: 100vh;
    margin: 0 auto;
    background: var(--paper);
    box-shadow: 0 0 36px rgba(20, 16, 15, 0.08);
  }

  .tabbar {
    left: 50%;
    right: auto;
    width: min(430px, 100%);
    transform: translateX(-50%);
  }
}

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

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

/* ——— Форма оформления ————————————————————————————————— */

.form-head {
  margin: 28px 0 14px;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 600;
}

.form-head:first-of-type {
  margin-top: 8px;
}

/* Выбор типа доставки: цена видна сразу, до оформления */
.picks {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 18px;
}

.pick {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 14px;
  background: var(--paper);
  cursor: pointer;
}

.pick.is-active {
  background: var(--accent-soft);
}

.pick input {
  accent-color: var(--accent);
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
}

.pick__body {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.pick__body b {
  font-size: 14.5px;
  font-weight: 500;
}

.pick__body small {
  font-size: 12px;
  color: var(--ink-soft);
  margin-top: 2px;
}

.seg {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 20px;
}

.seg__btn {
  border: 0;
  background: var(--paper);
  padding: 11px;
  font-size: 14px;
  color: var(--ink-soft);
  cursor: pointer;
}

.seg__btn.is-active {
  background: var(--ink);
  color: #fff;
  font-weight: 500;
}

.field select {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: none;
  padding: 7px 0;
  outline: none;
  border-radius: 0;
  appearance: none;
}

.field input.has-error,
.field select.has-error,
.field textarea.has-error {
  border-bottom-color: var(--accent);
}

.label--error {
  color: var(--accent) !important;
}

/* ——— Избранное ——————————————————————————————————————— */

.favorites-count {
  margin: 0 0 16px;
  color: var(--ink-soft);
  font-size: 13px;
}

.favorites-grid {
  padding-bottom: 12px;
}

.favorites-empty svg {
  margin: 0 auto 18px;
  color: #b7afaa;
}

/* ——— Профиль ————————————————————————————————————————— */

.profile-preview {
  margin-bottom: 14px;
  border-radius: 12px;
  background: #fff6da;
  color: #715f28;
  padding: 10px 12px;
  font-size: 12px;
  line-height: 1.4;
}

.profile-hero {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 4px 0 22px;
}

.profile-avatar {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 23px;
  font-weight: 600;
}

.profile-hero h2,
.profile-hero p {
  margin: 0;
}

.profile-hero h2 {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.25;
}

.profile-hero p {
  margin-top: 3px;
  color: var(--ink-soft);
  font-size: 13px;
}

.profile-form {
  margin: 0 0 28px;
  border-top: 1px solid var(--line);
}

.profile-section-title {
  margin: 26px 0 15px;
  font-size: 19px;
  font-weight: 500;
  letter-spacing: -0.015em;
}

.profile-form .profile-section-title {
  margin-top: 22px;
}

.profile-form input[readonly] {
  color: #9a938e;
}

.profile-field-note,
.profile-age,
.profile-consent {
  color: var(--ink-soft);
  font-size: 11.5px;
  line-height: 1.45;
}

.profile-field-note {
  margin: -9px 0 18px;
}

.profile-age {
  margin: -8px 0 18px;
}

.profile-save {
  height: 50px;
  border-radius: 25px;
}

.profile-save:disabled {
  opacity: 0.45;
  cursor: default;
}

.profile-consent {
  margin: 9px 10px 0;
  text-align: center;
}

.profile-consent button {
  border: 0;
  background: none;
  color: inherit;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

.profile-error {
  display: block;
  margin-top: 4px;
  color: var(--accent);
  font-size: 11px;
}

.orders-list {
  border-top: 1px solid var(--line);
}

.order-card {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.order-card > img,
.order-card__placeholder {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--sand);
}

.order-card__placeholder {
  display: grid;
  place-items: center;
  color: var(--accent);
  font-size: 22px;
}

.order-card__body {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.order-card__body b,
.order-card > strong {
  font-size: 13px;
  font-weight: 600;
}

.order-card > strong {
  font-family: var(--font-display);
}

.order-card__body span,
.order-card__body small {
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.orders-empty {
  border-radius: 14px;
  background: var(--sand);
  padding: 20px;
  color: var(--ink-soft);
  font-size: 13px;
  text-align: center;
}

.orders-empty button {
  display: block;
  margin: 12px auto 0;
  border: 0;
  background: none;
  color: var(--ink);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

/* ——— Информационные страницы ——————————————————————— */

.info-intro {
  padding: 14px 0 24px;
}

.info-intro img {
  width: 174px;
  height: auto;
}

.info-intro p {
  margin: 12px 0 0;
  color: var(--ink-soft);
  font-size: 13px;
}

.info-menu {
  border-top: 1px solid var(--line);
}

.info-menu__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 59px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: none;
  padding: 0 2px;
  font-size: 15px;
  text-align: left;
  cursor: pointer;
}

.info-menu__item svg {
  width: 19px;
  height: 19px;
  color: #8e8782;
}

.info-footer {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 28px 0 10px;
  color: var(--ink-soft);
  font-size: 11px;
}

.info-footer a {
  color: var(--ink);
  font-size: 15px;
  text-decoration: none;
}

.info-article {
  padding-bottom: 40px;
}

.info-breadcrumbs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 62px;
  color: #65605d;
  font-size: 12px;
  text-align: center;
}

.info-breadcrumbs button {
  border: 0;
  background: none;
  color: inherit;
  padding: 0;
  cursor: pointer;
}

.info-breadcrumbs strong {
  font-weight: 500;
}

.info-article__head {
  padding: 10px 0 25px;
  text-align: center;
}

.info-article__head p {
  margin: 0 0 12px;
  color: var(--ink-soft);
  font-size: 12px;
}

.info-article__head h1 {
  margin: 0 auto;
  max-width: 350px;
  font-size: 24px;
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -0.025em;
}

.info-content {
  color: #4f4946;
  font-size: 14px;
  line-height: 1.65;
}

.info-content h2 {
  margin: 29px 0 10px;
  color: var(--ink);
  font-size: 22px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.info-content p {
  margin: 0 0 16px;
}

.info-content ul,
.info-content ol {
  margin: 0 0 20px;
  padding-left: 21px;
}

.info-content li {
  margin-bottom: 9px;
}

.info-content a {
  color: var(--ink);
  text-underline-offset: 3px;
}

.contact-block {
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}

.contact-block > span {
  display: block;
  margin-bottom: 6px;
  color: var(--ink-soft);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.contact-block > a {
  font-size: 21px;
  font-weight: 500;
  text-decoration: none;
}

.contact-block p {
  margin: 7px 0 0;
  font-size: 13px;
}

.contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.contact-links a {
  border-radius: 18px;
  background: var(--sand);
  padding: 8px 13px;
  font-size: 12px;
  text-decoration: none;
}

.loyalty-levels {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-bottom: 28px;
}

.loyalty-levels div {
  display: flex;
  min-height: 100px;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 12px;
  background: var(--accent-soft);
  padding: 12px 9px;
}

.loyalty-levels strong {
  font-family: var(--font-display);
  color: var(--accent);
  font-size: 24px;
}

.loyalty-levels span {
  font-size: 10px;
  line-height: 1.25;
}

.info-original {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 34px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  padding: 17px 0;
  font-size: 12px;
  text-decoration: none;
}

.info-original svg {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
}
