/* =========================================
   Каталог закладів — стилі v2
   Файл: assets/css/business.css
   ========================================= */

/* =========================================
   АРХІВ: Фільтр категорій
   ========================================= */

.business-filter-section {
  padding: 0 0 20px;
}

.business-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 16px 0 24px;
}

.business-filter__btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  border-radius: 90px;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.5;
  color: var(--inactive-color);
  border: 1.5px solid var(--gray-brand-color);
  background: transparent;
  transition: all var(--bs-transition);
  cursor: pointer;
}

.business-filter__btn:hover {
  border-color: var(--green-brand-color);
  color: var(--green-brand-color);
}

.business-filter__btn--active {
  background-color: var(--green-brand-color);
  border-color: var(--green-brand-color);
  color: var(--white-color);
  font-weight: 600;
}

.business-filter__btn--active:hover {
  color: var(--white-color);
}

.business-filter__count {
  font-size: 11px;
  opacity: 0.65;
}

/* --- Заголовок архіву --- */
.biz-archive-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.biz-archive-count {
  font-size: 14px;
  color: var(--timestamp-color);
  white-space: nowrap;
}

/* =========================================
   АРХІВ: Сітка закладів — 2 колонки
   ========================================= */

.business-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 48px;
  list-style: none;
  padding: 0;
}

@media (max-width: 48em) {
  .business-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* =========================================
   АРХІВ: Картка закладу
   ========================================= */

.business__card {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--white-color);
  border-radius: var(--bs-radius);
  overflow: hidden;
  color: var(--bs-font-color);
  transition: box-shadow var(--bs-transition), transform var(--bs-transition);
}

.business__card:hover {
  box-shadow: 0 6px 20px rgba(0, 0, 0, .09);
  transform: translateY(-2px);
}

/* Фото — 16:9 */
.business__image-box {
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  background-color: var(--bg-color);
  flex-shrink: 0;
}

.business__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.35s ease;
}

.business__card:hover .business__image {
  transform: scale(1.05);
}

.business__image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--gray-brand-color);
  background: #EAEDED;
  font-size: 12px;
}

/* Контент картки */
.business__header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px 16px 8px;
  flex: 1;
}

.business__cat-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--green-brand-color);
  background: #EEF2F2;
  border-radius: 12px;
  padding: 2px 10px;
  align-self: flex-start;
}

.business__name {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--black-color);
  margin: 0;
}

.business__card:hover .business__name {
  color: var(--primary-color);
}

.business__address {
  display: flex;
  align-items: flex-start;
  gap: 5px;
  font-size: 12.5px;
  line-height: 1.4;
  color: var(--timestamp-color);
  margin: 0;
}

.business__icon {
  flex-shrink: 0;
  margin-top: 1px;
  color: var(--inactive-color);
}

/* Футер картки: рейтинг + стрілка */
.business__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px 14px;
  border-top: 1px solid var(--bg-color);
  margin-top: auto;
}

.business__rating {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
}

.business__star {
  color: var(--primary-color);
  font-size: 14px;
  line-height: 1;
}

.business__rating-val {
  font-weight: 700;
  color: var(--black-color);
}

.business__reviews {
  color: var(--timestamp-color);
}

.business__no-rating {
  font-size: 12.5px;
  color: var(--timestamp-color);
  font-style: italic;
}

.business__arrow {
  color: var(--primary-color);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

/* =========================================
   SINGLE: Кнопка редагування (floating)
   ========================================= */

.biz-edit-btn {
  position: fixed;
  top: 80px;
  right: 20px;
  z-index: 999;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--green-brand-color);
  color: var(--white-color);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
  transition: background var(--bs-transition);
}

.biz-edit-btn:hover {
  background: #344a4b;
  color: var(--white-color);
}

/* =========================================
   SINGLE: Заголовок + рейтинг-бейдж
   ========================================= */

.biz-header-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: start;
  gap: 16px;
  margin-bottom: 20px;
}

.biz-header-left {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.biz-cat-badge {
  display: inline-block;
  background: #EEF2F2;
  border: 1px solid #C8D5D5;
  color: var(--green-brand-color);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  align-self: flex-start;
  text-decoration: none;
  letter-spacing: .2px;
}

.business-single__title {
  font-size: clamp(1.25rem, 1.1rem + 0.75vw, 1.75rem);
  font-weight: 700;
  line-height: 1.3;
  color: var(--black-color);
  margin: 0;
}

.biz-rating-line {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--inactive-color);
  flex-wrap: wrap;
}

.biz-stars {
  color: var(--primary-color);
  font-size: 16px;
  letter-spacing: 2px;
}

.biz-score {
  font-weight: 700;
  color: var(--black-color);
  font-size: 16px;
}

.biz-sep {
  opacity: .4;
}

.biz-reviews-text {
  font-size: 13.5px;
}

/* Рейтинг-бейдж справа */
.biz-rating-badge {
  background: var(--white-color);
  border-radius: var(--bs-radius);
  border: 1px solid var(--gray-brand-color);
  padding: 14px 18px;
  text-align: center;
  flex-shrink: 0;
  min-width: 90px;
}

.biz-rating-badge__score {
  font-size: 30px;
  font-weight: 700;
  color: var(--primary-color);
  line-height: 1;
}

.biz-rating-badge__stars {
  color: var(--primary-color);
  font-size: 13px;
  letter-spacing: 2px;
  margin: 4px 0;
}

.biz-rating-badge__count {
  font-size: 11px;
  color: var(--timestamp-color);
  line-height: 1.3;
}

@media (max-width: 48em) {
  .biz-header-row {
    grid-template-columns: 1fr;
  }
  .biz-rating-badge {
    display: none;
  }
}

/* =========================================
   SINGLE: Інфо-чіпи
   ========================================= */

.biz-chips {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.biz-chip {
  background: var(--white-color);
  border-radius: var(--bs-radius);
  padding: 14px 16px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.biz-chip__icon {
  color: var(--primary-color);
  flex-shrink: 0;
  margin-top: 1px;
}

.biz-chip__label {
  font-size: 10.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--timestamp-color);
  margin-bottom: 3px;
}

.biz-chip__val {
  font-size: 13.5px;
  color: var(--black-color);
  line-height: 1.4;
}

.biz-chip__val a {
  color: var(--primary-color);
  text-decoration: none;
}

.biz-chip__val a:hover {
  text-decoration: underline;
}

.biz-empty {
  color: var(--timestamp-color);
  font-style: italic;
  font-size: 13px;
}

@media (max-width: 64em) {
  .biz-chips {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 48em) {
  .biz-chips {
    grid-template-columns: 1fr;
  }
}

/* =========================================
   SINGLE: Середній блок — фото | години + опис
   ========================================= */

.biz-middle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
  align-items: start;
}

@media (max-width: 64em) {
  .biz-middle {
    grid-template-columns: 1fr;
  }
}

/* Фото (1:1) */
.biz-photo-wrap {
  aspect-ratio: 1/1;
  border-radius: var(--bs-radius);
  overflow: hidden;
  background: var(--bg-color);
}

.biz-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.biz-photo-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--gray-brand-color);
  background: #EAEDED;
  font-size: 13px;
  text-align: center;
  padding: 20px;
}

/* Бічна колонка */
.biz-side-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Картка годин роботи */
.biz-hours-card {
  background: var(--white-color);
  border-radius: var(--bs-radius);
  padding: 18px 20px;
}

.biz-hours-card__title {
  font-size: 10.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: var(--timestamp-color);
  margin-bottom: 12px;
}

.biz-hours-list {
  display: flex;
  flex-direction: column;
}

.biz-hours-item {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  font-size: 13.5px;
  padding: 7px 0;
  border-bottom: 1px solid var(--bg-color);
}

.biz-hours-item:last-child {
  border-bottom: none;
}

.biz-hours-item__day {
  color: var(--inactive-color);
}

.biz-hours-item__time {
  font-weight: 500;
  color: var(--black-color);
  text-align: right;
}

/* Картка опису */
.biz-desc-card {
  background: var(--white-color);
  border-radius: var(--bs-radius);
  padding: 16px 18px;
  flex: 1;
}

.biz-desc-card__title {
  font-size: 10.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: var(--timestamp-color);
  margin-bottom: 8px;
}

.biz-desc-card__text {
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--inactive-color);
  margin: 0;
}

/* =========================================
   SINGLE: Карта
   ========================================= */

.biz-map-wrap {
  width: 100%;
  height: 360px;
  border-radius: var(--bs-radius);
  overflow: hidden;
  margin-bottom: 16px;
}

.biz-map-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* =========================================
   SINGLE: Кнопки CTA
   ========================================= */

.biz-cta-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 15px 24px;
  border-radius: var(--bs-radius);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  transition: background var(--bs-transition);
  letter-spacing: .2px;
  text-align: center;
  margin-bottom: 0;
}

.biz-cta-btn--primary {
  background: var(--primary-color);
  color: var(--white-color);
  margin-bottom: 28px;
}

.biz-cta-btn--primary:hover {
  background: var(--primary-hover-color);
  color: var(--white-color);
}

.biz-cta-btn--green {
  background: var(--green-brand-color);
  color: var(--white-color);
  margin-top: 16px;
}

.biz-cta-btn--green:hover {
  background: #344a4b;
  color: var(--white-color);
}

/* =========================================
   SINGLE: Схожі об'єкти
   ========================================= */

.biz-related {
  margin-bottom: 40px;
}

.biz-related__title {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 14px;
  color: var(--black-color);
}

.biz-related-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

@media (max-width: 48em) {
  .biz-related-grid {
    grid-template-columns: 1fr;
  }
}

.biz-related-card {
  background: var(--white-color);
  border-radius: var(--bs-radius);
  overflow: hidden;
  text-decoration: none;
  color: var(--black-color);
  display: flex;
  flex-direction: column;
  transition: box-shadow var(--bs-transition), transform var(--bs-transition);
}

.biz-related-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,.1);
  transform: translateY(-2px);
}

.biz-related-card__photo {
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--bg-color);
}

.biz-related-card__photo--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #EAEDED;
  color: var(--gray-brand-color);
}

.biz-related-card__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform .3s ease;
}

.biz-related-card:hover .biz-related-card__photo img {
  transform: scale(1.05);
}

.biz-related-card__body {
  padding: 12px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.biz-related-card__cat {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--green-brand-color);
  background: #EEF2F2;
  border-radius: 12px;
  padding: 2px 9px;
  align-self: flex-start;
}

.biz-related-card__name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--black-color);
}

.biz-related-card:hover .biz-related-card__name {
  color: var(--primary-color);
}

.biz-related-card__addr {
  font-size: 12.5px;
  color: var(--timestamp-color);
}

/* ============================================
   WEATHER STRIP - Homepage widget
   ============================================ */

.weather-strip {
    background: transparent;
    padding: 0 0 24px;
    margin: 0;
}

.weather-strip .container {
    display: flex;
    align-items: center;
    gap: 12px;
}

.weather-strip__link {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    color: var(--black-color);
    text-decoration: none;
    font-size: 15px;
    line-height: 1.4;
    min-width: 0;
}

.weather-strip__link:hover .weather-strip__title,
.weather-strip__link:focus .weather-strip__title {
    text-decoration-line: underline;
    text-decoration-style: solid;
    text-decoration-skip-ink: auto;
    text-decoration-color: #CE5B4A;
    text-decoration-thickness: 6.5%;
}

.weather-strip__icon {
    font-size: 16px;
    flex-shrink: 0;
    line-height: 1;
}

.weather-strip__badge {
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    background: var(--red-brand-color);
    color: var(--white-color);
    padding: 3px 10px;
    border-radius: 90px;
    flex-shrink: 0;
    white-space: nowrap;
}

.weather-strip__divider {
    color: var(--gray-brand-color);
    flex-shrink: 0;
}

.weather-strip__title {
    flex: 1;
    font-weight: 600;
    color: var(--black-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.weather-strip__date {
    font-size: 13px;
    color: var(--timestamp-color);
    flex-shrink: 0;
    white-space: nowrap;
}

.weather-strip__more {
    font-size: 13px;
    color: var(--primary-color);
    flex-shrink: 0;
    white-space: nowrap;
    font-weight: 500;
    transition: color var(--bs-transition);
}

.weather-strip__category-link {
    font-size: 13px;
    color: var(--inactive-color);
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    border-left: 1px solid var(--gray-brand-color);
    padding-left: 12px;
    transition: color var(--bs-transition);
}

.weather-strip__category-link:hover {
    color: var(--primary-color);
}

@media (max-width: 768px) {
    .weather-strip__date,
    .weather-strip__divider,
    .weather-strip__category-link {
        display: none;
    }

    .weather-strip__more {
        display: none;
    }

    .weather-strip__title {
        font-size: 14px;
    }
}

/* =========================================
   HOMEPAGE: Блок довідника на головній
   ========================================= */

.biz-home-section {
  padding-bottom: 24px;
}

.business-grid--home {
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

@media (max-width: 64em) {
  .business-grid--home {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 48em) {
  .business-grid--home {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

/* =========================================
   HOMEPAGE: Блок довідника на головній
   ========================================= */

.biz-home-section {
  padding-bottom: 24px;
}

.business-grid--home {
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

@media (max-width: 48em) {
  .business-grid--home {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

/* =========================================
   SIDEBAR: Довідник громади widget
   ========================================= */

.biz-sidebar-widget {
  margin-top: 28px;
}

.biz-sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.biz-sidebar-item {
  padding-bottom: 16px;
  border-bottom: 1px solid var(--bg-color);
}

.biz-sidebar-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.biz-sidebar-card {
  display: flex;
  flex-direction: row;
  gap: 14px;
  align-items: flex-start;
  text-decoration: none;
  color: var(--bs-font-color);
}

.biz-sidebar-card:hover .biz-sidebar-name {
  color: var(--primary-color);
}

.biz-sidebar-img-box {
  width: 90px;
  height: 68px;
  flex-shrink: 0;
  border-radius: var(--bs-radius);
  overflow: hidden;
  background: var(--bg-color);
}

.biz-sidebar-img-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.biz-sidebar-img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #EAEDED;
  color: var(--gray-brand-color);
}

.biz-sidebar-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.biz-sidebar-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.biz-sidebar-rating {
  font-size: 12px;
  color: var(--primary-color);
  font-weight: 600;
}

.biz-sidebar-name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--black-color);
  transition: color var(--bs-transition);
}

/* SEO: intro text on archive */
.biz-intro-text {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
    margin: 8px 0 0;
    max-width: 680px;
}

/* SEO: summary preview on card */
.business__summary {
    font-size: 13px;
    color: #888;
    line-height: 1.4;
    margin: 4px 0 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* SVG placeholder — fill container */
.business__image-placeholder--svg,
.biz-photo-placeholder--svg {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
}
.business__image-placeholder--svg svg,
.biz-photo-placeholder--svg svg {
    width: 100%;
    height: 100%;
    display: block;
}
.biz-related-card__photo svg {
    width: 100%;
    height: 100%;
    display: block;
}

/* Category sidebar widget */
.biz-cats-widget { margin-top: 16px; }
.biz-cats-widget .editorial__title { font-size: 14px; }
.biz-cats-list { list-style: none; padding: 0; margin: 0; }
.biz-cats-item { border-bottom: 1px solid #f0f0f0; }
.biz-cats-item:last-child { border-bottom: none; }
.biz-cats-link { display: flex; justify-content: space-between; align-items: center; padding: 8px 16px; text-decoration: none; color: #333; font-size: 14px; transition: background .15s; }
.biz-cats-link:hover { background: #f8f8f8; color: #111; }
.biz-cats-count { background: #f0f0f0; color: #666; font-size: 12px; padding: 2px 8px; border-radius: 10px; }
