/* ─── Page shell ─── */

.stores-page-main {
  background-color: #f8f7f4;
}

.stores-page-container {
  max-width: 1140px;
}

.stores-page-wrapper {
  min-height: 320px;
}

/* ─── Hero (shared with legacy store pages) ─── */

.header-pages {
  background-size: cover;
  width: 100%;
  height: 100%;
  background-position: center;
  padding-top: 73px;
  padding-bottom: 100px;
}

.header-pages::after {
  content: "";
  position: absolute;
  inset: 0;
  background: transparent;
  width: 100%;
}

.breadcrumb .breadcrumb-item,
.breadcrumb .breadcrumb-item a {
  color: #666 !important;
}

.breadcrumb-item + .breadcrumb-item::before {
  color: #666 !important;
}

/* ─── City toolbar ─── */

.stores-toolbar {
  background: #fff;
  border: 1px solid rgba(141, 15, 39, 0.12);
  border-radius: 20px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.25rem;
  box-shadow: 0 10px 32px rgba(141, 15, 39, 0.06);
  width: 100%;
}

.stores-toolbar__label {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
  color: #600e1d;
  margin-bottom: 0.65rem;
}

.stores-city-select__control {
  position: relative;
}

.stores-city-select__icon {
  position: absolute;
  top: 50%;
  inset-inline-start: auto;
  inset-inline-end: 1rem;
  transform: translateY(-50%);
  color: #8d0f27;
  pointer-events: none;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stores-city-select__input {
  width: 100%;
  border: 1px solid #e8e4e0;
  border-radius: 14px;
  padding-block: 0.85rem;
  padding-inline-start: 1rem;
  padding-inline-end: 2.85rem;
  font-size: 1rem;
  background-color: #faf9f7;
  color: #333;
  text-align: start;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

/* جلوگیری از آیکن پیش‌فرض مرورگر روی type=search */
.stores-city-select__input::-webkit-search-decoration,
.stores-city-select__input::-webkit-search-cancel-button {
  -webkit-appearance: none;
  appearance: none;
}

.stores-city-select__input::placeholder {
  color: #999;
}

.stores-city-select__input:hover {
  border-color: rgba(141, 15, 39, 0.35);
  background-color: #fff;
}

.stores-city-select__input:focus {
  outline: none;
  border-color: #8d0f27;
  background-color: #fff;
  box-shadow: 0 0 0 3px rgba(141, 15, 39, 0.12);
}

.stores-city-select__dropdown {
  top: calc(100% + 6px);
  z-index: 40;
  max-height: 260px;
  overflow-y: auto;
  background: #fff;
  border: 1px solid rgba(141, 15, 39, 0.15);
  border-radius: 14px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.1);
}

.stores-city-select__option {
  background: transparent;
  padding: 0.7rem 1rem;
  font-size: 0.95rem;
  color: #333;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.stores-city-select__option:hover,
.stores-city-select__option.active {
  background: #f8ecef;
  color: #8d0f27;
}

.stores-city-select__empty {
  position: absolute;
  top: calc(100% + 6px);
  z-index: 40;
  width: 100%;
  background: #fff;
  border: 1px solid #e8e4e0;
  border-radius: 14px;
  padding: 0.85rem 1rem;
  font-size: 0.9rem;
  color: #777;
}

.stores-empty-message {
  text-align: center;
  color: #777;
  padding: 2rem 1rem;
  font-size: 1rem;
}

/* ─── Sidebar (head office) ─── */

.stores-sidebar-card {
  background: #fff;
  border: 1px solid rgba(141, 15, 39, 0.1);
  border-radius: 20px;
  padding: 1.5rem 1.35rem;
  box-shadow: 0 10px 32px rgba(141, 15, 39, 0.05);
  position: relative;
  overflow: hidden;
  height: 100%;
}

.stores-sidebar-card::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 4px;
  background: linear-gradient(90deg, #8d0f27 0%, #600e1d 100%);
}

.stores-sidebar-card--solo {
  padding: 1.75rem 1.5rem;
}

@media (min-width: 992px) {
  .stores-page__sidebar {
    position: sticky;
    top: 1.5rem;
    align-self: flex-start;
    z-index: 2;
  }

  .stores-page__sidebar .stores-sidebar-card {
    height: auto;
  }
}

.office-contact-block__title {
  font-size: 1.2rem;
  font-weight: 700;
  color: #600e1d;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #f0ebe8;
}

.office-contact-block__item {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding-bottom: 1rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid #f5f1ee;
}

.office-contact-block__item:last-child,
.office-contact-block__item--social {
  border-bottom: 0;
  margin-bottom: 0;
  padding-bottom: 0;
}

.office-contact-block__icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.office-contact-block__label {
  display: block;
  font-size: 0.8rem;
  color: #8d0f27;
  margin-bottom: 0.25rem;
  font-weight: 600;
}

.office-contact-block__value {
  font-size: 0.95rem;
  color: #333;
  line-height: 1.6;
  word-break: break-word;
}

a.office-contact-block__value:hover {
  color: #8d0f27;
}

.office-contact-block__social {
  flex-wrap: nowrap;
  gap: 0.35rem;
}

.office-contact-block__social-link {
  flex-shrink: 0;
  padding: 0.28rem;
  border-radius: 10px;
  background: #faf9f7;
  border: 1px solid #f0ebe8;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.office-contact-block__social-link img {
  display: block;
  width: 32px;
  height: 32px;
}

.office-contact-block__social-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(141, 15, 39, 0.12);
}

/* ─── Outlet card ─── */

.stores-outlet-card {
  background: #fff;
  border: 1px solid rgba(141, 15, 39, 0.1);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(141, 15, 39, 0.07);
}

.stores-outlet-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem 0;
}

.stores-outlet-card__title {
  margin: 0;
  font-size: 1.45rem;
  font-weight: 700;
  background: linear-gradient(180deg, #8d0f27 0%, #600e1d 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.35;
}

.stores-outlet-card__nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.stores-outlet-card__nav-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid #e8e4e0;
  border-radius: 50%;
  background: #faf9f7;
  padding: 0;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.stores-outlet-card__nav-btn:hover {
  border-color: rgba(141, 15, 39, 0.4);
  background: #f8ecef;
}

.stores-outlet-card__nav-count {
  min-width: 3rem;
  text-align: center;
  user-select: none;
}

.stores-outlet-card__nav-icon {
  display: block;
  width: 1.1rem;
  height: 1.1rem;
  background-color: #8d0f27;
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  -webkit-mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
}

.stores-outlet-card__nav-icon--prev {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3E%3Cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3E%3Cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z'/%3E%3C/svg%3E");
}

.stores-outlet-card__nav-icon--next {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3E%3Cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3E%3Cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
}

/* LTR: prev = ←, next = → (default classes above). RTL: swap chevron direction per action. */
[dir="rtl"] .stores-outlet-card__nav-icon--prev {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3E%3Cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3E%3Cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
}

[dir="rtl"] .stores-outlet-card__nav-icon--next {
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3E%3Cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3E%3Cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z'/%3E%3C/svg%3E");
}

.stores-outlet-card__carousel {
  margin: 1rem 1.5rem 0;
  border-radius: 16px;
  overflow: hidden;
  background: #f0ebe8;
  position: relative;
}

.stores-outlet-card__media {
  /* aspect-ratio: 16 / 9; */
  width: 100%;
}

.stores-outlet-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.stores-outlet-card__body {
  padding: 1.25rem 1.5rem 1.5rem;
}

.stores-detail-row {
  padding: 1rem 0;
  border-bottom: 1px solid #f5f1ee;
}

.stores-detail-row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.stores-detail-row--action {
  padding-top: 1.25rem;
}

.stores-detail-row__label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: #8d0f27;
  margin-bottom: 0.35rem;
}

.stores-detail-row__value {
  font-size: 0.95rem;
  color: #444;
  line-height: 1.7;
}

.stores-detail-row__phones {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}

.stores-detail-row__phone {
  font-size: 1rem;
  font-weight: 700;
  color: #333;
  direction: ltr;
  unicode-bidi: plaintext;
}

.stores-detail-row__phone:hover {
  color: #8d0f27;
}

.stores-outlet-social__link {
  display: flex;
  padding: 0.35rem;
  border-radius: 10px;
  background: #faf9f7;
  border: 1px solid #f0ebe8;
  transition: transform 0.15s ease;
}

.stores-outlet-social__link:hover {
  transform: translateY(-2px);
}

.stores-outlet-card__route-btn {
  min-width: 140px;
  border-radius: 30px;
  padding: 0.55rem 1.5rem;
  font-size: 0.95rem;
}

.stores-outlet-empty {
  text-align: center;
  padding: 3rem 1.5rem;
  background: #fff;
  border: 1px dashed rgba(141, 15, 39, 0.25);
  border-radius: 20px;
  color: #777;
  font-size: 1rem;
}

/* ─── Loading ─── */

.stores-page__outlets {
  position: relative;
  z-index: 1;
}

.stores-page-loading {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 20;
  align-items: center;
  justify-content: center;
  background: rgba(248, 247, 244, 0.75);
  border-radius: 20px;
}

.stores-page-app--booting .stores-page-loading {
  display: flex;
}

.stores-page-app--booting .stores-outlet-card {
  visibility: hidden;
}

.stores-page-spinner {
  width: 2.5rem;
  height: 2.5rem;
  color: #8d0f27 !important;
}

/* ─── Transitions ─── */

.stores-fade-enter-active,
.stores-fade-leave-active {
  transition: opacity 0.2s ease;
}

.stores-fade-enter,
.stores-fade-leave-to {
  opacity: 0;
}

.stores-outlet-slide-enter-active,
.stores-outlet-slide-leave-active {
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.stores-outlet-slide-enter {
  opacity: 0;
  transform: translateX(12px);
}

.stores-outlet-slide-leave-to {
  opacity: 0;
  transform: translateX(-12px);
}

[dir="rtl"] .stores-outlet-slide-enter {
  transform: translateX(-12px);
}

[dir="rtl"] .stores-outlet-slide-leave-to {
  transform: translateX(12px);
}

/* ─── Offcanvas / misc ─── */

.link-social {
  background: #faf9f7;
  padding: 0.5rem;
  border-radius: 12px;
  border: 1px solid #f0ebe8;
}

.offcanvas-bottom {
  height: unset !important;
}

/* ─── Legacy map-sisib (carousel fallbacks) ─── */

.map-sisib .carousel-control-next,
.map-sisib .carousel-control-prev {
  position: unset !important;
}

/* ─── Responsive ─── */

@media (max-width: 991.98px) {
  .stores-toolbar {
    margin-bottom: 1.25rem;
  }

  .stores-sidebar-card {
    margin-bottom: 0.5rem;
  }

  .stores-outlet-card__header {
    flex-wrap: wrap;
  }

  .stores-outlet-card__title {
    font-size: 1.25rem;
  }

  .stores-outlet-card__media {
    margin-inline: 1rem;
    /* aspect-ratio: 4 / 3; */
  }

  .stores-outlet-card__body {
    padding-inline: 1rem;
  }
}

@media (max-width: 576px) {
  .header-pages {
    padding-top: 0px;
    padding-bottom: 65px;
  }

  .breadcrumb .breadcrumb-item,
  .breadcrumb .breadcrumb-item a {
    font-size: 14px !important;
  }

  .stores-toolbar {
    padding: 1rem;
    border-radius: 16px;
  }

  .stores-sidebar-card,
  .stores-outlet-card {
    border-radius: 16px;
  }

  .stores-outlet-card__media {
    border-radius: 12px;
  }
}

@media (min-width: 768px) and (max-width: 992px) {
  .header-pages {
    padding-top: 100px;
  }
}
