/* ===== West-Gourmet — базовые стили (mobile-first) ===== */
:root {
  --turquoise: #6DCED5;
  --turquoise-dark: #4FB3BA;
  --chocolate: #5A3A22;
  --cream: #FAF3E7;
  --white: #ffffff;
  --text: #5A3A22;
  --muted: rgba(90, 58, 34, 0.65);
  --line: rgba(90, 58, 34, 0.12);
  --placeholder: #EFE7D9; /* кремово-серая заливка для фото-плейсхолдера */
  --shadow: 0 10px 30px rgba(90, 58, 34, 0.12);
  --radius: 16px;
  --max-width: 1100px;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  background-color: var(--cream);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
    Ubuntu, Cantarell, sans-serif;
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: inherit; text-decoration: none; }

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 16px;
}

main.container {
  flex: 1 0 auto;
  padding-top: 24px;
  padding-bottom: 48px;
}

/* ===== Шапка ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  box-shadow: 0 2px 10px rgba(90, 58, 34, 0.06);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 12px;
  padding-bottom: 12px;
}
.logo {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-right: auto;
}
.logo-dot { color: var(--turquoise); }

.nav-toggle {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 40px;
  height: 40px;
  border: none;
  background: transparent;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 22px;
  margin: 0 auto;
  background: var(--chocolate);
  border-radius: 2px;
}

.main-nav {
  display: none;
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  flex-direction: column;
  background: var(--white);
  padding: 8px 16px 16px;
  box-shadow: var(--shadow);
}
.main-nav.open { display: flex; }
.main-nav a {
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
  font-weight: 500;
}
.main-nav a:last-child { border-bottom: none; }
.nav-login { color: var(--turquoise-dark); }
.nav-admin { color: var(--chocolate); font-weight: 700; }

.cart-link {
  position: relative;
  font-size: 22px;
  line-height: 1;
}
.cart-badge {
  position: absolute;
  top: -8px;
  right: -10px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--turquoise);
  color: var(--white);
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ===== Кнопки ===== */
.btn {
  display: inline-block;
  padding: 12px 22px;
  border: none;
  border-radius: 999px;
  background: var(--turquoise);
  color: var(--white);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}
.btn:hover { background: var(--turquoise-dark); }
.btn-outline {
  background: transparent;
  border: 2px solid var(--turquoise);
  color: var(--turquoise-dark);
}

/* ===== Hero / приветствие ===== */
.hero {
  display: flex;
  justify-content: center;
  padding: 24px 0;
}
.hero-card {
  background: var(--white);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: 40px 28px;
  text-align: center;
  max-width: 520px;
}
.hero-card h1 { margin: 0 0 12px; font-size: 32px; }
.hero-card p { margin: 0 0 8px; font-size: 17px; color: var(--muted); }
.hero-note { font-size: 14px !important; }

/* ===== Flash-сообщения ===== */
.flash-list { margin-bottom: 16px; display: grid; gap: 8px; }
.flash {
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 14px;
  background: var(--white);
  border-left: 4px solid var(--turquoise);
}
.flash-success { border-left-color: #3FB984; }
.flash-error, .flash-danger { border-left-color: #E0564E; }
.flash-warning { border-left-color: #E0A24E; }

/* ===== Подвал ===== */
.site-footer {
  background: var(--chocolate);
  color: var(--cream);
  padding: 28px 0;
  flex-shrink: 0;
}
.site-footer .footer-brand { font-size: 20px; font-weight: 700; margin: 0 0 8px; }
.site-footer p { margin: 0 0 6px; font-size: 14px; opacity: 0.9; }
.site-footer .footer-meta { opacity: 0.7; font-size: 13px; margin-top: 12px; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 12px 0 0; }
.footer-nav a { color: var(--cream); font-size: 14px; opacity: 0.9; }
.footer-nav a:hover { color: var(--turquoise); opacity: 1; }

/* ===== Десктоп ===== */
@media (min-width: 768px) {
  .nav-toggle { display: none; }
  .main-nav {
    display: flex;
    position: static;
    flex-direction: row;
    align-items: center;
    gap: 22px;
    background: transparent;
    box-shadow: none;
    padding: 0;
    margin-right: 22px;
  }
  .main-nav a { padding: 4px 0; border-bottom: none; }
  .hero-card { padding: 56px 48px; }
  .hero-card h1 { font-size: 40px; }
}

/* ===== Строка поиска в шапке ===== */
.header-search-wrap { padding-bottom: 12px; }
.header-search {
  display: flex;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
}
.header-search__input {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  padding: 11px 16px;
  font-size: 15px;
  color: var(--text);
  outline: none;
}
.header-search__input::placeholder { color: var(--muted); }
.header-search__btn {
  border: none;
  background: var(--turquoise);
  color: var(--white);
  padding: 0 18px;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.15s ease;
}
.header-search__btn:hover { background: var(--turquoise-dark); }

/* ===== Заголовки страниц, хлебные крошки ===== */
.page-title { font-size: 24px; margin: 8px 0 16px; }
.page-lead { color: var(--muted); margin: -8px 0 16px; }
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 8px;
}
.breadcrumbs a { color: var(--turquoise-dark); }
.breadcrumbs__sep { opacity: 0.6; }

/* ===== Чипы категорий ===== */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.chip {
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--white);
  border: 1px solid var(--line);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  white-space: nowrap;
  transition: border-color 0.15s ease;
}
.chip:hover { border-color: var(--turquoise); }
.chip.is-active {
  background: var(--turquoise);
  border-color: var(--turquoise);
  color: var(--white);
}

/* ===== Панель сортировки ===== */
.sort-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  margin-bottom: 20px;
  font-size: 14px;
}
.sort-bar__label { color: var(--muted); }
.sort-bar__item {
  color: var(--muted);
  padding: 4px 2px;
  border-bottom: 2px solid transparent;
}
.sort-bar__item:hover { color: var(--text); }
.sort-bar__item.is-active {
  color: var(--chocolate);
  font-weight: 600;
  border-bottom-color: var(--turquoise);
}

/* ===== Сетка и карточка товара ===== */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.product-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 36px rgba(90, 58, 34, 0.16);
}
.product-card__media {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;          /* крупное квадратное фото (по образцу auchan.ru) */
  background: var(--placeholder);
}
.product-card__media img { width: 100%; height: 100%; object-fit: cover; }
.product-card__body {
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
  padding: 10px;
}
.product-card__brand {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--turquoise-dark);
}
.product-card__name {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.3;
  min-height: 2.6em;            /* резерв под 2 строки — единая высота карточек */
  color: var(--text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.product-card__name:hover { color: var(--turquoise-dark); }
.product-card__prices {
  display: flex;
  flex-direction: column;       /* текущая цена + строка старой цены */
  margin-top: auto;
}
.product-card__prices .price { line-height: 1.2; }
.product-card__prices .price--old { min-height: 1.25em; line-height: 1.25; }
/* Заглушка без скидки: место зарезервировано, но ничего не видно. */
.price--old-empty { visibility: hidden; }
.cart-control--card { margin-top: 2px; }
.cart-control--card .cart-control__add { width: 100%; padding: 8px; font-size: 13px; }
.cart-control--card .cart-control__stepper { width: 100%; }
.cart-control--card .cart-control__stepper .qty__btn { width: 34px; height: 34px; }
.cart-control--card .cart-control__count { flex: 1; font-size: 13px; }

/* Нейтральный плейсхолдер фото (без эмодзи продуктов). */
.photo-ph {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: rgba(90, 58, 34, 0.4);
}
.photo-ph__text {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ===== Бейджи (угловые) ===== */
.badge {
  position: absolute;
  top: 8px;
  z-index: 2;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: var(--white);
}
.badge--new { left: 8px; background: var(--turquoise); }
.badge--sale { right: 8px; background: #E0564E; }

/* ===== Цены ===== */
.price { font-size: 18px; font-weight: 700; color: var(--chocolate); white-space: nowrap; }
.price--old {
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: line-through;
}
.price--lg { font-size: 28px; }

.btn--lg { padding: 14px 28px; font-size: 16px; }

/* ===== Пагинация ===== */
.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-top: 28px;
}
.pagination__link {
  min-width: 40px;
  padding: 8px 12px;
  text-align: center;
  border-radius: 10px;
  background: var(--white);
  border: 1px solid var(--line);
  font-weight: 600;
  color: var(--text);
  transition: border-color 0.15s ease;
}
.pagination__link:hover { border-color: var(--turquoise); }
.pagination__link.is-active {
  background: var(--turquoise);
  border-color: var(--turquoise);
  color: var(--white);
}
.pagination__gap { padding: 8px 4px; color: var(--muted); }

/* ===== Пустое состояние ===== */
.empty-state { text-align: center; color: var(--muted); padding: 40px 16px; }
.empty-state a { color: var(--turquoise-dark); font-weight: 600; }

/* ===== Секции витрины ===== */
.hero-card .btn { margin-top: 16px; }
.block { margin: 28px 0; }
.block__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 14px;
}
.block__title { font-size: 20px; margin: 0; }
.block__more { font-size: 14px; font-weight: 600; color: var(--turquoise-dark); }

.category-tiles {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.category-tile {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 16px;
  text-align: center;
  font-weight: 600;
  transition: transform 0.15s ease, color 0.15s ease;
}
.category-tile:hover { transform: translateY(-3px); color: var(--turquoise-dark); }

/* ===== Страница товара ===== */
.product-page {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin: 12px 0 8px;
}
.product-page__media {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 460px;             /* крупное квадратное фото (по образцу auchan.ru) */
  margin: 0 auto;
  aspect-ratio: 1 / 1;
  background: var(--placeholder);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.product-page__media img { width: 100%; height: 100%; object-fit: cover; }
.product-page__name { font-size: 24px; margin: 6px 0 14px; }
.product-page__prices {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}
.product-page__prices .badge { position: static; }
.product-page__desc { color: var(--muted); margin-bottom: 20px; }
.product-page__desc p { margin: 0 0 10px; }
.product-page__desc p:last-child { margin-bottom: 0; }
.cart-control--page { margin-bottom: 12px; }
.cart-control--page .cart-control__add { padding: 14px 28px; font-size: 16px; }
.cart-control--page .cart-control__stepper { width: max-content; }
.cart-control--page .cart-control__stepper .qty__btn { width: 48px; height: 48px; font-size: 22px; }
.cart-control--page .cart-control__count { min-width: 56px; font-size: 16px; }
.product-page__delivery { font-size: 14px; color: var(--muted); margin: 0; }

/* ===== Страница ошибки ===== */
.error-page { display: flex; justify-content: center; padding: 32px 0; }
.error-card {
  background: var(--white);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: 40px 28px;
  text-align: center;
  max-width: 460px;
}
.error-card__code { font-size: 64px; font-weight: 800; line-height: 1; color: var(--turquoise); }
.error-card h1 { margin: 8px 0 10px; font-size: 24px; }
.error-card p { margin: 0 0 20px; color: var(--muted); }

/* ===== Каталог: десктоп ===== */
@media (min-width: 768px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .category-tiles { grid-template-columns: repeat(3, 1fr); }
  .product-card__name { font-size: 15px; }
  .page-title { font-size: 28px; }
  .product-page { grid-template-columns: minmax(0, 460px) 1fr; gap: 32px; align-items: start; }
  .product-page__media { margin: 0; }
  .product-page__name { font-size: 28px; }
}

@media (min-width: 1024px) {
  .product-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ===== Корзина ===== */
.cart { display: grid; grid-template-columns: 1fr; gap: 20px; align-items: start; }
.cart-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.cart-item {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 12px;
}
.cart-item__media {
  width: 72px;
  height: 72px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--placeholder);
  display: flex;
  align-items: center;
  justify-content: center;
}
.cart-item__media img { width: 100%; height: 100%; object-fit: cover; }
.cart-item__media .photo-ph__text { display: none; }  /* в мини-превью только иконка */
.cart-item__info { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cart-item__name { font-size: 14px; font-weight: 500; color: var(--text); }
.cart-item__name:hover { color: var(--turquoise-dark); }
.cart-item__price { font-size: 13px; color: var(--muted); }
.cart-item__controls {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
}
.qty__btn {
  width: 32px;
  height: 32px;
  border: none;
  background: transparent;
  border-radius: 999px;
  font-size: 18px;
  color: var(--chocolate);
  cursor: pointer;
}
.qty__btn:hover { background: var(--cream); }
.qty__value { min-width: 30px; text-align: center; font-weight: 600; }

.cart-item__subtotal {
  font-size: 16px;
  font-weight: 700;
  color: var(--chocolate);
  white-space: nowrap;
  margin-left: auto;
}
.cart-item__remove {
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 16px;
  padding: 4px;
  cursor: pointer;
}
.cart-item__remove:hover { color: #E0564E; }

.cart-summary {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cart-summary__row { display: flex; justify-content: space-between; font-size: 15px; }
.cart-summary__row--total {
  font-size: 20px;
  font-weight: 700;
  color: var(--chocolate);
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.cart-summary__checkout { width: 100%; margin-top: 4px; text-align: center; }
.cart-summary__checkout:disabled { opacity: 0.5; cursor: not-allowed; }
.cart-summary__checkout:disabled:hover { background: var(--turquoise); }
.cart-summary__note { margin: 0; font-size: 12px; color: var(--muted); text-align: center; }

/* ===== Контрол «В корзину» / степпер (по образцу auchan.ru) ===== */
/* Кнопка-заглушка «В корзину» (вид как у .btn, но самодостаточная). */
.cart-control__add {
  border: none;
  border-radius: 999px;
  background: var(--turquoise);
  color: var(--white);
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}
.cart-control__add:hover { background: var(--turquoise-dark); }

/* Переключение состояний: по умолчанию — кнопка, .is-active — степпер. */
.cart-control__stepper { display: none; }
.cart-control.is-active .cart-control__add { display: none; }
.cart-control.is-active .cart-control__stepper { display: flex; }

/* Степпер занимает место кнопки: бирюзовый pill «− N шт +». */
.cart-control__stepper {
  align-items: center;
  justify-content: space-between;
  background: var(--turquoise);
  border-radius: 999px;
}
.cart-control__stepper .qty__btn { color: var(--white); flex: 0 0 auto; }
.cart-control__stepper .qty__btn:hover { background: rgba(255, 255, 255, 0.18); }
.cart-control__count {
  text-align: center;
  font-weight: 700;
  color: var(--white);
  white-space: nowrap;
}

/* ===== Тост ===== */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translate(-50%, 20px);
  z-index: 100;
  padding: 12px 20px;
  border-radius: 999px;
  background: var(--chocolate);
  color: var(--cream);
  font-size: 14px;
  font-weight: 600;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.toast--visible { opacity: 1; transform: translate(-50%, 0); }

@media (min-width: 768px) {
  .cart { grid-template-columns: 1fr 320px; }
  .cart-item { grid-template-columns: 88px 1fr auto; align-items: center; }
  .cart-item__media { width: 88px; height: 88px; }
  .cart-item__controls {
    grid-column: auto;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
  }
  .cart-item__subtotal { margin-left: 0; }
}

/* ===== Оформление заказа (checkout) ===== */
.checkout { display: grid; gap: 20px; }
.checkout__block {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  margin-bottom: 16px;
}
.checkout__block:last-child { margin-bottom: 0; }
.checkout__block-title { font-size: 18px; margin: 0 0 14px; color: var(--chocolate); }
.checkout__summary { align-self: start; }
.checkout__items {
  list-style: none;
  margin: 0 0 12px;
  padding: 0 0 12px;
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 8px;
}
.checkout__item { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.checkout__item-qty { color: var(--muted); }
.checkout__item-sum { white-space: nowrap; font-weight: 600; }

/* ===== Поля формы ===== */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field:last-child { margin-bottom: 0; }
.field label { font-size: 14px; font-weight: 600; color: var(--chocolate); }
.field__input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  color: var(--text);
  font-size: 15px;
  font-family: inherit;
}
.field__input:focus {
  outline: none;
  border-color: var(--turquoise);
  box-shadow: 0 0 0 3px rgba(109, 206, 213, 0.25);
}
.field__input:disabled { background: var(--cream); color: var(--muted); cursor: not-allowed; }
.field__textarea { resize: vertical; }
.field__hint { font-size: 12px; color: var(--muted); }
.field__error { font-size: 12px; color: #E0564E; font-weight: 600; }

/* ===== Страница заказа / подтверждение ===== */
.order-thanks {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  margin-bottom: 20px;
  text-align: center;
}
.order-thanks__title { margin: 0 0 12px; color: var(--chocolate); }
.order-thanks__text { margin: 0 0 8px; }
.order-thanks__link { margin-top: 12px; word-break: break-all; }
.order-thanks__link a { color: var(--turquoise-dark); font-weight: 600; }

.order { display: grid; gap: 20px; }
.order__main, .order__info {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}
.order__info { align-self: start; }
.order__status-row { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.order__status {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--turquoise);
  color: var(--white);
  font-size: 13px;
  font-weight: 700;
}
.order__date { color: var(--muted); font-size: 14px; }
.order__items { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.order__item { display: flex; justify-content: space-between; gap: 12px; }
.order__item-qty { color: var(--muted); }
.order__item-sum { white-space: nowrap; font-weight: 600; }
.order__total {
  display: flex;
  justify-content: space-between;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 20px;
  font-weight: 700;
  color: var(--chocolate);
}
.order__details { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 14px; }
.order__details dt { color: var(--muted); }
.order__details dd { margin: 0; }
.order__back { margin-top: 20px; }
.order__back a { color: var(--turquoise-dark); font-weight: 600; }

@media (min-width: 768px) {
  .checkout { grid-template-columns: 1fr 320px; align-items: start; }
  .order { grid-template-columns: 1fr 320px; align-items: start; }
}

/* ===== Вход / регистрация ===== */
.auth { max-width: 440px; margin: 0 auto; }
.auth__submit { width: 100%; margin-top: 6px; text-align: center; }
.auth__alt { text-align: center; margin-top: 16px; color: var(--muted); }
.auth__alt a { color: var(--turquoise-dark); font-weight: 600; }
.checkbox { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; font-size: 14px; cursor: pointer; }
.checkbox input { width: 16px; height: 16px; accent-color: var(--turquoise); }

/* Кнопка «Выйти» в шапке — выглядит как ссылка nav-login. */
.nav-logout { margin: 0; }
.nav-logout__btn {
  border: none;
  background: none;
  padding: 0;
  font: inherit;
  color: var(--muted);
  cursor: pointer;
}
.nav-logout__btn:hover { color: var(--turquoise-dark); }

/* ===== Личный кабинет ===== */
.account { display: grid; gap: 20px; }
.account__profile { align-self: start; }
.account__logout { width: 100%; margin-top: 14px; text-align: center; }
.account__order-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.account__order {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px 18px;
  color: var(--text);
  transition: transform 0.15s ease;
}
.account__order:hover { transform: translateY(-2px); }
.account__order-id { font-weight: 700; }
.account__order-date { color: var(--muted); font-size: 14px; }
.account__order-sum { margin-left: auto; font-weight: 700; color: var(--chocolate); white-space: nowrap; }

@media (min-width: 768px) {
  .account { grid-template-columns: 280px 1fr; align-items: start; }
}

/* Статические страницы: «О магазине», «Контакты». */
.static-page { max-width: 640px; }
.static-page .checkout__block { font-size: 15px; line-height: 1.6; }
.static-page p { margin: 0 0 12px; }
.static-page p:last-child { margin-bottom: 0; }
.static-page__cta { margin-top: 18px; }
.static-page__contacts { font-size: 15px; }
.static-page__contacts a { color: var(--turquoise-dark); font-weight: 600; }

/* ===== Нижняя панель навигации (только мобильная ≤768px, по образцу auchan.ru) ===== */
.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  background: var(--white);
  border-top: 1px solid var(--line);
  box-shadow: 0 -2px 12px rgba(90, 58, 34, 0.08);
  padding-bottom: env(safe-area-inset-bottom);   /* запас под home-indicator iOS */
}
/* Та же центральная ширина, что у контента (.container): на широком мониторе
   пункты сгруппированы по центру под контентом, а не размазаны по краям экрана.
   На узких экранах max-width > ширины вьюпорта → пункты занимают всю ширину. */
.bottom-nav__inner {
  display: flex;
  max-width: var(--max-width);
  margin: 0 auto;
}
.bottom-nav__item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 8px 4px 7px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  transition: color 0.15s ease;
}
.bottom-nav__item.is-active { color: var(--turquoise-dark); }
.bottom-nav__icon { position: relative; display: inline-flex; }
.bottom-nav__icon svg { width: 24px; height: 24px; display: block; }
.bottom-nav__label { white-space: nowrap; }
.bottom-nav__badge {
  position: absolute;
  top: -6px;
  right: -9px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 8px;
  background: var(--turquoise);
  color: var(--white);
  font-size: 10px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Резерв снизу страницы под фиксированную панель, чтобы футер/кнопки
   не прятались под ней (высота панели ≈ 57px + safe-area). */
body { padding-bottom: calc(57px + env(safe-area-inset-bottom)); }

/* На десктопе панель скрыта — работает обычная верхняя шапка (как на auchan.ru).
   Резерв снизу там не нужен, поэтому сбрасываем его. */
@media (min-width: 768px) {
  .bottom-nav { display: none; }
  body { padding-bottom: 0; }
}
