.shop-category {
  margin-top: 32px;
}

.shop-category:first-child {
  margin-top: 20px;
}

.shop-category__title {
  font-size: 15px;
  font-weight: 700;
  margin: 0 0 8px;
}

.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
}

.shop-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 10px;
  background: #fff;
}

.shop-card__image {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  overflow: hidden;
  background: var(--color-secondary-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
}

.shop-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shop-card__image .icon {
  width: 28px;
  height: 28px;
  color: var(--color-muted);
}

.shop-card__title {
  font-size: 12.5px;
  font-weight: 600;
  margin: 0 0 4px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.shop-card__unit {
  font-size: 11px;
  color: var(--color-muted);
  margin: 0 0 6px;
}

.shop-card__price {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--color-primary);
  margin: 0;
}

.shop-card__price--free {
  color: #16a34a;
}

.shop-card {
  text-decoration: none;
  color: inherit;
}

.product-detail {
  max-width: 420px;
  margin-top: 4px;
}

.product-detail__image {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  overflow: hidden;
  background: var(--color-secondary-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.product-detail__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-detail__image .icon {
  width: 56px;
  height: 56px;
  color: var(--color-muted);
}

.product-detail__title {
  font-size: 20px;
  font-weight: 800;
  margin: 0 0 4px;
}

.product-detail__unit {
  font-size: 13px;
  color: var(--color-muted);
  margin: 0 0 10px;
}

.product-detail__price {
  font-size: 22px;
  font-weight: 800;
  color: var(--color-primary);
  margin: 0 0 16px;
}

.product-detail__description {
  font-size: 14.5px;
  color: var(--color-text);
  white-space: pre-wrap;
  margin: 0 0 20px;
}

.product-detail__quantity {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.product-detail__quantity-label {
  font-size: 14px;
  font-weight: 600;
}

.quantity-stepper {
  display: flex;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  padding: 6px 16px;
}

.quantity-stepper__btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: var(--color-secondary-soft);
  color: var(--color-text);
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.quantity-stepper__value {
  min-width: 20px;
  text-align: center;
  font-size: 15px;
  font-weight: 700;
}

.product-detail__added {
  text-align: center;
  color: var(--color-primary);
  font-weight: 600;
  font-size: 14px;
  margin-top: 12px;
}

.cart-floating-btn[hidden] {
  display: none;
}

.cart-floating-btn {
  position: fixed;
  left: 50%;
  bottom: calc(16px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 22px;
  height: 48px;
  border-radius: 999px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
  text-decoration: none;
  white-space: nowrap;
}

body.is-native-app .cart-floating-btn {
  bottom: calc(80px + env(safe-area-inset-bottom));
}

.cart-floating-btn__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.25);
  font-size: 12.5px;
  font-weight: 700;
}

/* Espace pour que le contenu ne soit jamais cache derriere le bouton fixe. */
.page-shell--with-floating-cart {
  padding-bottom: 88px;
}

.cart-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--color-border);
}

.cart-row__image {
  flex-shrink: 0;
  width: 60px;
  height: 60px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--color-secondary-soft);
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-row__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-row__image .icon {
  width: 24px;
  height: 24px;
  color: var(--color-muted);
}

.cart-row__info {
  flex: 1;
  min-width: 0;
}

.cart-row__title {
  font-size: 14px;
  font-weight: 600;
  margin: 0 0 2px;
}

.cart-row__meta {
  font-size: 12.5px;
  color: var(--color-muted);
  margin: 0;
}

.cart-row__line-total {
  flex-shrink: 0;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--color-primary);
}

.cart-row__remove {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 8px;
  background: none;
  color: var(--color-muted);
  cursor: pointer;
}

.cart-row__remove:hover {
  background: rgba(192, 57, 43, 0.08);
  color: #c0392b;
}

.cart-row__remove:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.cart-row__remove .icon {
  width: 18px;
  height: 18px;
}

.cart-summary {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 2px solid var(--color-border);
}

.cart-summary__total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 18px;
  font-weight: 800;
  margin-bottom: 16px;
}

.cart-summary__hint {
  text-align: center;
  font-size: 12.5px;
  color: var(--color-muted);
  margin: 10px 0 0;
}

#payment-section {
  margin-top: 16px;
}

.payment-card-element {
  padding: 14px;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  background: #fff;
  margin-top: 6px;
}

.saved-payment-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  margin-bottom: 8px;
}

.saved-payment-row:has(input:checked) {
  border-color: var(--color-primary);
  background: var(--color-secondary-soft);
}

.saved-payment-row input[type='radio'] {
  width: 18px;
  height: 18px;
  accent-color: var(--color-primary);
  flex-shrink: 0;
}

.saved-payment-row .icon {
  width: 20px;
  height: 20px;
  color: var(--color-primary);
  flex-shrink: 0;
}

.saved-payment-row__info {
  display: flex;
  flex-direction: column;
  font-size: 13.5px;
}

.saved-payment-row__info small {
  color: var(--color-muted);
}

.order-card {
  border: 1px solid var(--color-border);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 14px;
  background: #fff;
}

.order-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.order-card__number {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--color-text);
}

.order-card__date {
  font-size: 13px;
  color: var(--color-muted);
  margin-bottom: 10px;
}

.order-card__status {
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
}

.order-card__status--paid {
  background: rgba(22, 163, 74, 0.12);
  color: #15803d;
}

.order-card__status--pending {
  background: rgba(245, 158, 11, 0.15);
  color: #92400e;
}

.order-card__status--failed {
  background: rgba(239, 68, 68, 0.12);
  color: #b91c1c;
}

.order-card__item {
  display: flex;
  justify-content: space-between;
  font-size: 13.5px;
  color: var(--color-text);
  padding: 4px 0;
}

.order-card__item-name {
  color: var(--color-muted);
}

.order-card__total {
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  font-size: 14.5px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--color-border);
}
