/* ============================================================
   Shop Page
   ============================================================ */

/* ── Hero Banner ── */

.shop-hero {
  position: relative;
  width: 100%;
  min-height: 700px;
  overflow: hidden;
  /* --shop-hero-img is overridden inline by JS per selected category.
     Defaults to the built-in desktop banner for "All" / unset categories. */
  --shop-hero-img: url("../images/shop/Desktop.jpg");
  background-image: linear-gradient(182.76deg, rgba(0, 0, 0, 0.6) 4.53%, rgba(0, 0, 0, 0) 30.8%), linear-gradient(0deg, rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.45)), var(--shop-hero-img);
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Mobile hero banner */
@media (max-width: 768px) {
  .shop-hero {
    /* --shop-hero-img-mobile is overridden inline by JS per category. */
    --shop-hero-img-mobile: url("../images/shop/Mobile.jpg");
    background-image: linear-gradient(182.76deg, rgba(0, 0, 0, 0.6) 4.53%, rgba(0, 0, 0, 0) 30.8%), linear-gradient(0deg, rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.45)), var(--shop-hero-img-mobile);
  }
}

.shop-hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: 768px;
  text-align: center;
}

.shop-hero-heading {
  position: relative;
  width: 1030px;
  min-height: 100px;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.shop-hero-heading-glow,
.shop-hero-heading-text {
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 80px;
  line-height: 100px;
  text-transform: capitalize;
  text-align: center;
}

/* in flow — this is what gives the h1 its height */
.shop-hero-heading-text {
  position: relative;
  z-index: 1;
  width: 100%;
  color: #ffffff;
}

/* out of flow — stretches to match the text copy */
.shop-hero-heading-glow {
  position: absolute;
  inset: 0;
  z-index: 0;
  color: rgba(194, 27, 181, 0.6);
  filter: blur(15px);
}

.shop-hero-subtitle {
  width: 768px;
  margin: 0;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 20px;
  line-height: 30px;
  color: #ffffff;
  text-align: center;
}

/* ── Shops Grid ── */

.shops-grid {
  background: var(--color-page-bg);
  padding: 80px 80px 0 80px;
}

.shops-grid-wrap {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 48px;
}

.shops-grid-heading {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 32px;
  line-height: 40px;
  color: var(--color-purple);
  margin: 0;
  text-transform: capitalize;
}

.shops-grid-layout {
  display: flex;
  gap: 38px;
  align-items: flex-start;
}

/* Sidebar */

.shops-sidebar {
  width: 370px;
  flex-shrink: 0;
  /* Hug the filter content instead of stretching to the results column height,
     which would leave a large empty gap below the last pill. */
  align-self: flex-start;
}

.shops-sidebar-inner {
  background: #ffffff;
  border-radius: 16px;
  padding: 40px 24px;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.shops-filter-mobile-header {
  display: none;
}
.shops-filter-mobile-body {
  display: contents;
}

.shops-filter-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* The sub-category section is toggled via the [hidden] attribute in JS. Without
   this override, .shops-filter-section's display:flex beats the UA [hidden]
   rule (equal specificity, author wins), so the empty section stays a flex item
   and its 40px gap leaves a phantom gap at the bottom of the sidebar. */
.shops-filter-section[hidden] {
  display: none;
}

/* Search */

.shops-search-label {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  height: 44px;
  background: #ffffff;
  border: 1px solid #d5d7da;
  box-shadow: 0px 1px 2px rgba(10, 13, 18, 0.05);
  border-radius: 12px;
  padding: 10px 14px;
  box-sizing: border-box;
  cursor: text;
}

.shops-search-icon {
  flex-shrink: 0;
}

.shops-search {
  flex: 1;
  border: none;
  outline: none;
  font-family: var(--font-body);
  font-size: 16px;
  color: #333333;
  background: transparent;
  appearance: none;
}

.shops-search::placeholder {
  color: #717680;
}

/* Filter headings */

.shops-filter-heading {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 24px;
  line-height: 26px;
  letter-spacing: -0.5px;
  color: #111111;
  margin: 0;
}

/* Filter pills container */

.shops-filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* Pills */

.shops-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 20px;
  height: 48px;
  border-radius: 100px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 16px;
  line-height: 20px;
  letter-spacing: -0.5px;
  cursor: pointer;
  border: 1px solid #131211;
  background: transparent;
  color: #131211;
  transition:
    background 0.2s,
    color 0.2s,
    border-color 0.2s;
  white-space: nowrap;
}

.shops-pill.shops-pill-active,
.shops-pill:hover {
  background: var(--color-purple);
  color: #ffffff;
  border-color: var(--color-purple);
}

/* Main content area */

.shops-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Top tabs */

.shops-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.shops-tab {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 20px;
  height: 48px;
  border-radius: 100px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 16px;
  line-height: 20px;
  letter-spacing: -0.5px;
  cursor: pointer;
  border: 1px solid #131211;
  background: transparent;
  color: #131211;
  transition:
    background 0.2s,
    color 0.2s,
    border-color 0.2s;
  white-space: nowrap;
}

.shops-tab.shops-tab-active,
.shops-tab:hover {
  background: var(--color-purple);
  color: #ffffff;
  border-color: var(--color-purple);
}

/* Floor plan */

.shops-floor-plan[hidden] {
  display: none;
}

.shops-floor-plan-img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
}

/* Results bar */

.shops-results-bar {
  display: flex;
  align-items: center;
  gap: 24px;
}

.shops-results-count {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 26px;
  letter-spacing: -0.5px;
  color: #000000;
  white-space: nowrap;
}

.shops-sort-wrap {
  position: relative;
  width: 213px;
  height: 44px;
  flex-shrink: 0;
}

.shops-sort {
  width: 100%;
  height: 100%;
  padding: 10px 36px 10px 14px;
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 24px;
  color: #717680;
  background: #ffffff;
  border: 1px solid #d5d7da;
  box-shadow: 0px 1px 2px rgba(10, 13, 18, 0.05);
  border-radius: 8px;
  appearance: none;
  cursor: pointer;
  box-sizing: border-box;
}

.shops-sort-chevron {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
}

/* Card grid */

.shops-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

/* Shop card */

.shops-card {
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.shops-card[hidden] {
  display: none;
}

.shops-card-img {
  width: 100%;
  height: 340px;
  border-radius: 8px;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

/* Image layer — covers tile, uses --store-img CSS var set by JS */
.shops-card-img::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: var(--store-img);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transition: transform 320ms ease-out;
}

.shops-card:hover .shops-card-img::after,
.shops-card:focus-visible .shops-card-img::after {
  transform: scale(1.04);
}

/* Gradient overlay — stays fixed on top of the zooming image */
.shops-card-img::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(331.19deg, rgba(87, 8, 150, 0.2) 24.33%, rgba(173, 20, 191, 0) 58.71%), linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.2) 77.9%);
}

/* Shop card images — set on ::after so only the image zooms */
.shops-card-img--levis::after {
  background-image: url("../images/shop/shops/Levis (1).webp");
}
.shops-card-img--odel::after {
  background-image: url("../images/shop/shops/Odel (6).webp");
}
.shops-card-img--miika::after {
  background-image: url("../images/shop/shops/Miika (1).webp");
}
.shops-card-img--miniso::after {
  background-image: url("../images/shop/shops/Miniso (2).webp");
}
.shops-card-img--abans::after {
  background-image: url("../images/shop/shops/AVR Game.webp");
}
.shops-card-img--carnage::after {
  background-image: url("../images/shop/shops/Burger King.webp");
}
.shops-card-img--mimosa::after {
  background-image: url("../images/shop/shops/KFC.webp");
}
.shops-card-img--coolplanet::after {
  background-image: url("../images/shop/shops/Taco Bell (1).webp");
}
.shops-card-img--singer::after {
  background-image: url("../images/shop/shops/PIzza Hut (4).webp");
}

.shops-card-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.shops-card-name {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 20px;
  line-height: 22px;
  color: #131211;
}

.shops-card-floor {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 11px;
  line-height: 17px;
  color: #333333;
}

/* ── Responsive ── */

@media (max-width: 1024px) {
  .shops-grid-layout {
    flex-direction: column;
    align-items: stretch;
    gap: 24px;
  }

  .shops-sidebar {
    width: 100%;
  }

  .shops-content {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .shops-grid {
    padding: 48px 24px 0 24px;
  }

  .shops-grid-wrap {
    gap: 32px;
  }

  .shops-grid-heading {
    font-size: 26px;
    line-height: 32px;
  }

  .shops-grid-layout {
    flex-direction: column;
    align-items: stretch;
    gap: 24px;
  }

  .shops-sidebar {
    width: 100%;
  }

  .shops-content {
    width: 100%;
  }

  .shops-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 4px;
  }

  .shops-tab {
    flex-shrink: 0;
  }

  /* When floor tabs are moved inside the sidebar filter on mobile they should wrap */
  .shops-sidebar-inner .shops-tabs {
    overflow-x: visible;
    flex-wrap: wrap;
    padding-bottom: 0;
  }

  .shops-floor-plan-inner {
    padding: 16px;
    gap: 12px;
  }

  .shops-results-bar {
    flex-wrap: wrap;
    gap: 4px;
  }

  .shops-sort-wrap {
    width: 213px;
    max-width: 100%;
  }

  .shops-cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .shops-card-img {
    height: 200px;
  }
}

@media (max-width: 480px) {
  .shops-cards {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .shops-card-img {
    height: 500px;
  }

  .shops-card-name {
    font-size: 18px;
  }
}

/* ── Hero Responsive ── */

@media (max-width: 768px) {
  .shop-hero {
    height: 720px;
    min-height: 720px;
    padding: 48px 24px;
  }

  .shop-hero-content {
    width: 100%;
    gap: 12px;
  }

  .shop-hero-heading {
    width: 100%;
    height: auto;
  }

  .shop-hero-heading-glow,
  .shop-hero-heading-text {
    font-size: 40px;
    line-height: 1.2;
    position: relative;
    inset: unset;
  }

  .shop-hero-heading-glow {
    position: absolute;
  }

  .shop-hero-subtitle {
    width: 100%;
    font-size: 16px;
    line-height: 24px;
  }
}

/* ── Mobile Filter Toggle ── */

@media (max-width: 768px) {
  .shops-sidebar-inner {
    gap: 16px;
    padding: 20px 16px;
  }

  .shops-filter-mobile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  .shops-filter-mobile-label {
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 24px;
    color: #111111;
  }

  .shops-filter-mobile-toggle {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #111111;
  }

  .shops-filter-mobile-toggle svg {
    transition: transform 0.25s ease;
  }

  .shops-filter-mobile-toggle[aria-expanded="false"] svg {
    transform: rotate(-90deg);
  }

  .shops-filter-mobile-body {
    display: flex;
    flex-direction: column;
    gap: 24px;
  }

  .shops-filter-mobile-body.hcm-filter-collapsed {
    display: none;
  }
}
