/* X - Développement — Boutique (v3 pro) */

.shop-body {
  background: var(--paper);
}

.shop-body .site-foot {
  margin-top: 0;
}

/* ——— Layout ——— */
.shop-page {
  padding-bottom: 4rem;
}

/* ——— En-tête ——— */
.shop-top {
  padding: 2.5rem 0 1.75rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.6) 0%, transparent 100%);
}

.shop-top-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem 2rem;
}

.shop-top-copy {
  max-width: 34rem;
}

.shop-eyebrow {
  margin: 0 0 0.65rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.shop-top h1 {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.6rem);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.05;
}

.shop-subtitle {
  margin: 0;
  color: var(--mute);
  font-size: 0.98rem;
  line-height: 1.55;
}

.shop-top-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
}

.shop-user-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}

.shop-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.75rem;
  border: 1px solid rgba(18, 18, 18, 0.08);
  border-radius: 999px;
  background: #fff;
  font-size: 0.82rem;
  line-height: 1.2;
  box-shadow: 0 2px 10px rgba(18, 18, 18, 0.04);
}

.shop-badge-kicker {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mute);
}

.shop-badge--balance strong {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}

.shop-badge--tier {
  font-weight: 600;
  color: var(--accent-ink);
  background: rgba(194, 74, 46, 0.07);
  border-color: rgba(194, 74, 46, 0.16);
}

.shop-badge--action {
  text-decoration: none;
  font-weight: 500;
  color: var(--ink-soft);
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.shop-badge--action:hover {
  color: var(--ink);
  border-color: rgba(18, 18, 18, 0.14);
  background: #faf8f4;
}

.shop-balance {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.9rem 1.15rem;
  min-width: 11.5rem;
  border: 1px solid rgba(18, 18, 18, 0.08);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset, 0 8px 24px rgba(18, 18, 18, 0.04);
}

.shop-balance-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mute);
}

.shop-balance-value {
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.shop-balance-value small {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--mute);
}

.shop-balance-tier {
  display: inline-flex;
  align-self: flex-start;
  margin-top: 0.15rem;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  background: rgba(194, 74, 46, 0.08);
  color: var(--accent-ink);
}

.shop-link-quiet {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--mute);
  text-decoration: none;
  transition: color 0.2s;
}

.shop-link-quiet:hover {
  color: var(--ink);
}

.shop-alert {
  margin-top: 1.25rem;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  border: 1px solid rgba(154, 91, 18, 0.25);
  background: rgba(154, 91, 18, 0.06);
  font-size: 0.92rem;
}

.shop-alert a {
  color: var(--accent-ink);
  font-weight: 600;
}

/* ——— Barre filtres ——— */
.shop-filters {
  position: sticky;
  top: var(--nav-h);
  z-index: 15;
  padding: 0.75rem 0 1rem;
  background: rgba(250, 248, 244, 0.92);
  backdrop-filter: blur(16px);
}

.shop-filters-panel {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.85rem 1.25rem;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(18, 18, 18, 0.08);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 4px 20px rgba(18, 18, 18, 0.04);
}

.shop-filters-inner {
  display: grid;
  grid-template-columns: minmax(200px, 1.5fr) repeat(2, minmax(140px, 1fr));
  gap: 0.65rem;
  flex: 1 1 520px;
  align-items: end;
}

.shop-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.shop-field-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mute);
}

.shop-input-wrap {
  position: relative;
}

.shop-input-icon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--mute);
  pointer-events: none;
}

.shop-field select,
.shop-field .catalog-select {
  width: 100%;
  min-width: 0;
}

.shop-input {
  width: 100%;
  border: 1px solid rgba(18, 18, 18, 0.1);
  border-radius: 10px;
  padding: 0.62rem 0.8rem;
  font-family: var(--font-body);
  font-size: 0.88rem;
  color: var(--ink);
  background: #faf8f4;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.shop-input--icon {
  padding-left: 2.25rem;
}

.shop-input:hover {
  border-color: rgba(18, 18, 18, 0.16);
}

.shop-input:focus {
  border-color: rgba(18, 18, 18, 0.22);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(18, 18, 18, 0.06);
}

.shop-result-count {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--mute);
  white-space: nowrap;
  padding: 0.35rem 0.15rem;
}

/* Select custom styles live in form-controls.css (.x-select) */

/* ——— Checkout global ——— */
.shop-checkout {
  margin: 1.35rem 0 0;
  padding: 1rem 1.15rem;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  border: 1px solid rgba(18, 18, 18, 0.08);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 4px 20px rgba(18, 18, 18, 0.04);
}

.shop-checkout-main {
  flex: 1 1 220px;
  max-width: 320px;
}

.shop-checkout-aside {
  flex: 0 0 auto;
}

.shop-checkout .promo-field {
  margin: 0;
}

.shop-checkout .promo-field span,
.shop-checkout-aside .shop-field-label {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mute);
}

.shop-checkout .promo-field input {
  width: 100%;
  border: 1px solid rgba(18, 18, 18, 0.1);
  border-radius: 10px;
  padding: 0.62rem 0.8rem;
  font-family: var(--font-body);
  font-size: 0.88rem;
  background: #faf8f4;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.shop-checkout .promo-field input:focus {
  outline: none;
  border-color: rgba(18, 18, 18, 0.22);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(18, 18, 18, 0.06);
}

.shop-turnstile {
  margin: 0;
}

/* ——— Grille produits ——— */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
  margin-top: 1.75rem;
}

.shop-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.shop-card:hover {
  border-color: rgba(18, 18, 18, 0.16);
  box-shadow: 0 8px 28px rgba(18, 18, 18, 0.06);
}

.shop-card[hidden] {
  display: none !important;
}

.shop-card-link {
  display: flex;
  flex-direction: column;
  flex: 1;
  text-decoration: none;
  color: inherit;
}

.shop-card-visual {
  position: relative;
  aspect-ratio: 1;
  background: #f5f1ea;
  border-bottom: 1px solid var(--line);
}

.shop-card-visual img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 1rem;
  transition: transform 0.4s var(--ease);
}

.shop-card:hover .shop-card-visual img {
  transform: scale(1.02);
}

.shop-card-visual--empty {
  background:
    linear-gradient(145deg, #f8f4ed 0%, #ece6db 100%);
}

.shop-card-flag {
  position: absolute;
  top: 0.6rem;
  left: 0.6rem;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink-soft);
}

.shop-card-flag--owned {
  background: #ecfdf5;
  border-color: rgba(16, 185, 129, 0.3);
  color: #047857;
}

.shop-card-flag--shield {
  left: auto;
  right: 0.6rem;
  background: rgba(194, 74, 46, 0.08);
  border-color: rgba(194, 74, 46, 0.18);
  color: var(--accent-ink);
}

.shop-card-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 0.95rem 1rem 1rem;
  gap: 0.35rem;
}

.shop-card-category {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--mute);
}

.shop-card-name {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.shop-card-rating {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin: 0.15rem 0 0;
  font-size: 0.78rem;
  color: var(--mute);
}

.shop-card-rating strong {
  color: var(--ink);
  font-weight: 600;
}

.shop-card-rating-stars {
  color: var(--accent);
  letter-spacing: -0.06em;
}

.shop-card-price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: 0.65rem;
}

.shop-card-price {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
}

.shop-card-price--yours {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent-ink);
  text-align: right;
}

.shop-card-foot {
  padding: 0 1rem 1rem;
}

.shop-card-foot .btn {
  width: 100%;
  padding: 0.62rem 0.85rem;
  font-size: 0.86rem;
  border-radius: 8px;
}

.shop-empty {
  grid-column: 1 / -1;
  padding: 4rem 1.5rem;
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: 12px;
  color: var(--mute);
  background: rgba(255, 255, 255, 0.5);
}

/* ——— Fiche produit ——— */
.shop-body--product .shop-top {
  padding-bottom: 1.25rem;
}

.shop-crumb {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 1rem;
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--mute);
  text-decoration: none;
  transition: color 0.2s;
}

.shop-crumb:hover {
  color: var(--ink);
}

.shop-detail {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 2.5rem;
  align-items: start;
  padding: 1.5rem 0 2.5rem;
}

.shop-detail-main {
  min-width: 0;
}

.shop-detail-sidebar {
  position: sticky;
  top: calc(var(--nav-h) + 1rem);
}

.shop-gallery-frame {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  overflow: hidden;
}

.shop-gallery-main {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  padding: 1.25rem;
  background: #f5f1ea;
}

.shop-gallery-main--empty {
  display: block;
  min-height: 280px;
  background: linear-gradient(145deg, #f8f4ed 0%, #ece6db 100%);
}

.shop-gallery-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0.75rem;
  border-top: 1px solid var(--line);
  background: #fff;
}

.shop-gallery-thumb {
  width: 3.75rem;
  height: 3.75rem;
  padding: 0.2rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f5f1ea;
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.2s;
}

.shop-gallery-thumb.is-active {
  border-color: var(--ink);
}

.shop-gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.shop-detail-head {
  margin-top: 1.75rem;
}

.shop-detail-head h1 {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.shop-detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
}

.shop-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.28rem 0.6rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-soft);
}

.shop-pill--accent {
  background: rgba(194, 74, 46, 0.07);
  border-color: rgba(194, 74, 46, 0.18);
  color: var(--accent-ink);
}

.shop-detail-desc {
  margin: 1.25rem 0 0;
  color: var(--ink-soft);
  line-height: 1.7;
  font-size: 0.98rem;
  white-space: pre-wrap;
}

/* Panneau achat */
.shop-order {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  overflow: hidden;
}

.shop-order-head {
  padding: 1.1rem 1.2rem;
  border-bottom: 1px solid var(--line);
  background: #faf8f4;
}

.shop-order-head h2 {
  margin: 0;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mute);
}

.shop-order-body {
  padding: 1.15rem 1.2rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.shop-order-balance {
  margin: 0;
  font-size: 0.88rem;
  color: var(--mute);
}

.shop-order-balance strong {
  color: var(--ink);
}

.shop-order-price {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1;
}

.shop-order-price-note {
  margin: -0.35rem 0 0;
  font-size: 0.82rem;
  color: var(--accent-ink);
  font-weight: 500;
}

.shop-order .promo-field {
  margin: 0;
}

.shop-order .promo-field span {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--mute);
}

.shop-order .promo-field input {
  border-radius: 8px;
  color: #121212;
  background: #fff;
}

.shop-order .promo-field input::placeholder {
  color: rgba(18, 18, 18, 0.38);
}

.shop-promo-feedback {
  margin: -0.15rem 0 0;
  font-size: 0.82rem;
  font-weight: 500;
}

.shop-promo-feedback.is-ok {
  color: #1a6b3a;
}

.shop-promo-feedback.is-error {
  color: #b42318;
}

.shop-product-video {
  margin-top: 0.85rem;
}

.shop-product-video-label {
  margin: 0 0 0.4rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--mute);
}

.shop-product-video video {
  width: 100%;
  border-radius: 10px;
  background: #0e1218;
  border: 1px solid rgba(18, 18, 18, 0.08);
}

.shop-order .btn-primary {
  width: 100%;
  border-radius: 8px;
  padding: 0.75rem 1rem;
}

.shop-order-footnote {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.45;
  color: var(--mute);
}

.shop-order-footnote a {
  color: var(--accent-ink);
  font-weight: 500;
}

/* Grille tarifs produit */
.shop-tiers {
  margin-top: 1.75rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}

.shop-tiers-title {
  margin: 0;
  padding: 0.85rem 1rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mute);
  border-bottom: 1px solid var(--line);
  background: #faf8f4;
}

.shop-tiers .price-tiers {
  margin: 0;
  padding: 0.35rem 0;
  border: none;
  border-radius: 0;
  background: transparent;
}

.shop-tiers .price-tier {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.65rem 1rem;
  border: none;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
}

.shop-tiers .price-tier:last-child {
  border-bottom: none;
}

.shop-tiers .price-tier-label {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--mute);
  letter-spacing: 0;
  text-transform: none;
}

.shop-tiers .price-tier-value {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
}

.shop-tiers .price-cgv {
  margin: 0;
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--line);
  font-size: 0.78rem;
}

/* Avis */
.shop-reviews {
  padding: 2.5rem 0 0;
  margin-top: 0.5rem;
  border-top: 1px solid var(--line);
}

.shop-reviews-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.shop-reviews-top h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.shop-reviews-score {
  margin: 0 0 1.25rem;
  font-size: 0.92rem;
  color: var(--mute);
}

.shop-reviews-score strong {
  color: var(--ink);
}

.shop-review-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.shop-review {
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.shop-review-stars {
  color: var(--accent);
  font-size: 0.85rem;
  margin-bottom: 0.4rem;
  letter-spacing: -0.04em;
}

.shop-review p {
  margin: 0;
  line-height: 1.55;
  font-size: 0.92rem;
}

.shop-review time,
.shop-review .shop-review-date {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.78rem;
  color: var(--mute);
}

.shop-review-sort select {
  border: 1px solid rgba(18, 18, 18, 0.1);
  border-radius: 10px;
  padding: 0.45rem 0.65rem;
  font-size: 0.85rem;
  background: #faf8f4;
}

@media (max-width: 960px) {
  .shop-filters-inner {
    grid-template-columns: 1fr 1fr;
  }

  .shop-field--search {
    grid-column: 1 / -1;
  }

  .shop-filters-panel {
    flex-direction: column;
    align-items: stretch;
  }

  .shop-result-count {
    text-align: right;
  }

  .shop-detail {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .shop-detail-sidebar {
    position: static;
  }

  .shop-detail-head {
    margin-top: 1.25rem;
  }
}

@media (max-width: 640px) {
  .shop-top-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .shop-user-bar {
    width: 100%;
  }

  .shop-filters-inner {
    grid-template-columns: 1fr;
  }

  .shop-grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .shop-card:hover .shop-card-visual img {
    transform: none;
  }
}
