:root {
  /* Navy background of the logo; sampled from static/img/logo.png. */
  --brand-navy: #0f1b3b;

  /* Brand accent replacing Bootstrap's default blue (c100m78y0k54). */
  --brand-blue: #001a75;
  --brand-blue-hover: #00155e;
  --brand-blue-active: #001350;

  --bs-primary: var(--brand-blue);
  --bs-primary-rgb: 0, 26, 117;
  --bs-link-color: var(--brand-blue);
  --bs-link-color-rgb: 0, 26, 117;
  --bs-link-hover-color: var(--brand-blue-active);
  --bs-link-hover-color-rgb: 0, 19, 80;
}

/* Filled primary buttons: Применить, Добавить в корзину, Войти … */
.btn-primary {
  --bs-btn-bg: var(--brand-blue);
  --bs-btn-border-color: var(--brand-blue);
  --bs-btn-hover-bg: var(--brand-blue-hover);
  --bs-btn-hover-border-color: var(--brand-blue-active);
  --bs-btn-active-bg: var(--brand-blue-active);
  --bs-btn-active-border-color: var(--brand-blue-active);
  --bs-btn-disabled-bg: var(--brand-blue);
  --bs-btn-disabled-border-color: var(--brand-blue);
}

/* Outline primary buttons: catalog card "В корзину", variant chips … */
.btn-outline-primary {
  --bs-btn-color: var(--brand-blue);
  --bs-btn-border-color: var(--brand-blue);
  --bs-btn-hover-bg: var(--brand-blue);
  --bs-btn-hover-border-color: var(--brand-blue);
  --bs-btn-active-bg: var(--brand-blue);
  --bs-btn-active-border-color: var(--brand-blue);
  --bs-btn-disabled-color: var(--brand-blue);
  --bs-btn-disabled-border-color: var(--brand-blue);
}

/* Link-style buttons: Сбросить фильтры … */
.btn-link {
  --bs-btn-color: var(--brand-blue);
  --bs-btn-hover-color: var(--brand-blue-active);
  --bs-btn-active-color: var(--brand-blue-active);
}

/* Pagination: Назад / Следующая */
.pagination {
  --bs-pagination-color: var(--brand-blue);
  --bs-pagination-hover-color: var(--brand-blue-active);
  --bs-pagination-focus-color: var(--brand-blue-active);
  --bs-pagination-active-bg: var(--brand-blue);
  --bs-pagination-active-border-color: var(--brand-blue);
}

.brand-navbar {
  background-color: var(--brand-navy);
}

.brand-logo-img {
  display: block;
  width: auto;
  height: auto;
  /* Wide wordmark (~7.5:1): cap height on desktop, but shrink to fit the
     viewport on narrow screens so it never overflows the navbar. */
  max-height: 36px;
  max-width: min(70vw, 280px);
}

.product-thumb {
  height: 180px;
  object-fit: contain;
  background: #fff;
}

.product-thumb-placeholder {
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f3f5;
  color: #ced4da;
  font-size: 3rem;
}

.product-detail-img {
  max-height: 380px;
  object-fit: contain;
}

.auth-card {
  max-width: 460px;
  margin: 2rem auto;
}

.banner-img {
  /* Slides are all 1920×648; show the whole image (no top/bottom crop). */
  display: block;
  width: 100%;
  height: auto;
}

/* Navbar search autocomplete dropdown */
.search-suggest {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 1050;
  margin-top: 0.25rem;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 0.375rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.175);
  max-height: 65vh;
  overflow-y: auto;
  display: none;
}
.search-suggest.show {
  display: block;
}
.search-suggest-item {
  display: block;
  padding: 0.4rem 0.75rem;
  font-size: 0.9rem;
  line-height: 1.3;
  color: #212529;
  text-decoration: none;
  white-space: normal;
  border-bottom: 1px solid #f1f3f5;
}
.search-suggest-item:last-child {
  border-bottom: 0;
}
.search-suggest-item:hover,
.search-suggest-item.active {
  background: #eef1f6;
  color: #212529;
}
.search-suggest-item strong {
  color: #0f1b3b; /* brand in navy */
}

.warehouse-img {
  height: 200px;
  object-fit: cover;
}

.warehouse-img-placeholder {
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f3f5;
  color: #ced4da;
  font-size: 3rem;
}

.manager-photo {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 50%;
  flex: 0 0 auto;
}

.manager-photo-placeholder {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e9ecef;
  color: #adb5bd;
  font-size: 1.75rem;
}
