:root {
  --shops-bg: #f7f8fa;
  --shops-surface: #ffffff;
  --shops-text: #14171f;
  --shops-muted: #667085;
  --shops-subtle: #98a2b3;
  --shops-line: #e6e8ee;
  --shops-soft: #f2f4f7;
  --shops-orange: #f36f21;
  --shops-orange-dark: #c85112;
  --shops-blue: #1f5fbf;
  --shops-green: #12805c;
  --shops-red: #c92a2a;
  --shops-shadow: 0 10px 28px rgba(20, 23, 31, .07);
}

* {
  box-sizing: border-box;
}

body {
  background: var(--shops-bg);
  color: var(--shops-text);
}

.shops-page {
  width: min(1180px, 100%);
  margin: 0 auto 78px;
  padding: 0 14px;
}

.shops-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin: 8px 0 18px;
  padding: 18px 0 16px;
  border-bottom: 1px solid var(--shops-line);
}

.shops-heading {
  min-width: 0;
}

.shops-kicker {
  display: inline-flex;
  color: var(--shops-orange-dark);
  font-size: .72rem;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.shops-hero h1 {
  margin: 4px 0 4px;
  color: var(--shops-text);
  font-size: clamp(1.35rem, 2.4vw, 2rem);
  font-weight: 900;
  line-height: 1.08;
}

.shops-hero p {
  margin: 0;
  color: var(--shops-muted);
  font-size: .95rem;
  font-weight: 600;
}

.shops-count {
  flex: 0 0 auto;
  min-width: 170px;
  padding: 12px 14px;
  border: 1px solid var(--shops-line);
  border-radius: 8px;
  background: var(--shops-surface);
}

.shops-count span {
  display: block;
  color: var(--shops-muted);
  font-size: .74rem;
  font-weight: 750;
}

.shops-count strong {
  display: block;
  margin-top: 2px;
  color: var(--shops-text);
  font-size: 1.45rem;
  font-weight: 900;
  line-height: 1;
}

.shops-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.shop-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--shops-line);
  border-radius: 8px;
  background: var(--shops-surface);
  box-shadow: 0 8px 22px rgba(20, 23, 31, .055);
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.shop-media {
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--shops-soft);
  color: inherit;
  text-decoration: none;
}

.shop-media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.shop-body {
  display: grid;
  gap: 10px;
  padding: 10px;
}

.shop-identity {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.shop-avatar {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  overflow: hidden;
  border: 2px solid #fff;
  border-radius: 8px;
  background: var(--shops-soft);
  box-shadow: 0 0 0 1px var(--shops-line);
}

.shop-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.shop-title {
  min-width: 0;
}

.shop-title h2 {
  margin: 0;
  overflow: hidden;
  color: var(--shops-text);
  font-size: .93rem;
  font-weight: 850;
  line-height: 1.18;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.shop-title h2 a {
  color: inherit;
  text-decoration: none;
}

.shop-title span {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 3px;
  overflow: hidden;
  color: var(--shops-muted);
  font-size: .76rem;
  font-weight: 650;
  line-height: 1.2;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.shop-title i {
  flex: 0 0 auto;
  color: var(--shops-orange);
  font-size: .75rem;
}

.shop-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 30px;
  padding-top: 8px;
  border-top: 1px solid var(--shops-line);
}

.shop-badge {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 7px;
  border-radius: 999px;
  color: var(--shops-blue);
  background: #eef4ff;
  font-size: .68rem;
  font-weight: 850;
  line-height: 1;
  white-space: nowrap;
}

.shop-link {
  margin-left: auto;
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: var(--shops-orange-dark);
  font-size: .78rem;
  font-weight: 850;
  text-decoration: none;
}

.shop-link i {
  font-size: .72rem;
}

.shop-link:hover,
.shop-title h2 a:hover {
  color: var(--shops-orange-dark);
}

.shop-media:focus-visible,
.shop-avatar:focus-visible,
.shop-link:focus-visible,
.shop-title h2 a:focus-visible,
.create-magasin a:focus-visible {
  outline: 3px solid rgba(243, 111, 33, .32);
  outline-offset: 2px;
}

.shops-empty {
  grid-column: 1 / -1;
  padding: 44px 18px;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: var(--shops-muted);
  text-align: center;
}

.shops-empty i {
  color: var(--shops-orange);
  font-size: 2rem;
  margin-bottom: 10px;
}

.shops-empty h2 {
  margin: 0 0 5px;
  color: var(--shops-text);
}

.shops-empty p {
  margin: 0;
}

.message-interceptor {
  position: fixed;
  top: 16px;
  right: 12px;
  left: 12px;
  z-index: 1000;
  display: grid;
  gap: 10px;
  pointer-events: none;
}

.message-interceptor .alert {
  pointer-events: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  max-width: 420px;
  margin-left: auto;
  padding: 12px 14px;
  border: 1px solid var(--shops-line);
  border-left: 4px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shops-shadow);
}

.message-interceptor .alert-success {
  border-left-color: var(--shops-green);
}

.message-interceptor .alert-error {
  border-left-color: var(--shops-red);
}

.alert-content {
  display: flex;
  align-items: center;
  gap: 10px;
}

.close-alert {
  padding: 0 0 0 8px;
  border: 0;
  background: transparent;
  color: var(--shops-muted);
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
}

.infinite-loader,
.infinite-end {
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 22px 0 0;
  color: var(--shops-muted);
  font-weight: 800;
  text-align: center;
}

.spinner {
  width: 22px;
  height: 22px;
  border: 3px solid #fed7aa;
  border-top-color: var(--shops-orange);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}

.create-magasin {
  position: fixed;
  right: 26px;
  bottom: 26px;
  z-index: 100;
  transition: transform .16s ease;
}

.create-magasin.scrolled {
  transform: translateY(-4px);
}

.create-magasin a {
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 18px;
  border-radius: 999px;
  color: #fff;
  background: var(--shops-orange);
  box-shadow: 0 14px 28px rgba(243, 111, 33, .28);
  font-weight: 850;
  text-decoration: none;
}

.create-magasin a:hover {
  color: #fff;
  background: var(--shops-orange-dark);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (hover: hover) {
  .shop-card:hover {
    transform: translateY(-2px);
    border-color: #f6c5a4;
    box-shadow: 0 14px 30px rgba(20, 23, 31, .09);
  }
}

@media (min-width: 720px) {
  .shops-page {
    padding: 0 22px;
  }

  .shops-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }

  .shop-media {
    aspect-ratio: 16 / 10;
  }

  .shop-body {
    padding: 13px;
  }
}

@media (min-width: 1080px) {
  .shops-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 719px) {
  .shops-page {
    margin-bottom: 86px;
    padding: 0 10px;
  }

  .shops-hero {
    align-items: stretch;
    flex-direction: column;
    gap: 12px;
    margin-top: 4px;
    padding-bottom: 14px;
  }

  .shops-count {
    width: 100%;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
  }

  .shops-count strong {
    font-size: 1.25rem;
  }

  .shops-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
  }

  .shop-body {
    gap: 8px;
    padding: 8px;
  }

  .shop-identity {
    gap: 7px;
  }

  .shop-avatar {
    flex-basis: 34px;
    width: 34px;
    height: 34px;
  }

  .shop-title h2 {
    font-size: .82rem;
  }

  .shop-title span {
    font-size: .68rem;
  }

  .shop-footer {
    min-height: 26px;
    padding-top: 7px;
  }

  .shop-badge {
    min-height: 21px;
    padding: 3px 6px;
    font-size: .62rem;
  }

  .shop-link {
    min-height: 24px;
    font-size: .7rem;
  }

  .create-magasin {
    right: 18px;
    bottom: calc(env(safe-area-inset-bottom) + var(--bottom-nav-h, 64px) + 14px);
  }

  .create-magasin a {
    width: 52px;
    height: 52px;
    padding: 0;
  }

  .create-magasin span {
    display: none;
  }
}

@media (max-width: 360px) {
  .shops-page {
    padding: 0 8px;
  }

  .shops-grid {
    gap: 8px;
  }

  .shop-body {
    padding: 7px;
  }

  .shop-avatar {
    display: none;
  }

  .shop-title h2 {
    font-size: .78rem;
  }

  .shop-link {
    font-size: 0;
  }

  .shop-link i {
    font-size: .78rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}
