/* ============================================================
   FIVEM SHOP — full-screen overlay modal
   ============================================================ */
.fivem-shop {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  opacity: 0;
  transition: opacity .25s ease-out;
}
.fivem-shop.is-open { display: block; opacity: 1; }
.fivem-shop-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.78);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.fivem-shop-container {
  position: relative;
  width: min(1200px, 94vw);
  max-height: 92vh;
  margin: 4vh auto;
  background: var(--bg-1);
  border: 1px solid var(--line-amber);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,.6);
}

.fivem-shop-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 28px;
  border-bottom: 1px solid var(--line);
}
.fivem-shop-titles h2 { font-size: 22px; margin: 0 0 4px; color: var(--ink-0); }
.fivem-shop-titles p { font-size: 14px; margin: 0; color: var(--ink-2); }
.fivem-shop-close {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink-1);
  cursor: pointer;
  font-size: 16px;
  display: grid; place-items: center;
  transition: border-color .2s, color .2s;
}
.fivem-shop-close:hover { color: var(--amber); border-color: var(--line-amber); }

.fivem-shop-view { flex: 1; overflow-y: auto; padding: 24px 28px; }
.fivem-shop-view[hidden] { display: none; }

.fivem-shop-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.filter-chip {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink-2);
  font-size: 13px;
  cursor: pointer;
  transition: all .15s;
}
.filter-chip:hover { color: var(--ink-0); border-color: var(--line-amber); }
.filter-chip.is-active { background: var(--amber); color: var(--bg-0); border-color: var(--amber); font-weight: 700; }

.fivem-shop-grid-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.shop-card {
  position: relative;
  background: var(--bg-0);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: transform .2s, border-color .2s;
  display: flex;
  flex-direction: column;
}
.shop-card:hover { transform: translateY(-4px); border-color: var(--line-amber); }
.shop-card-cover { width: 100%; aspect-ratio: 16 / 9; background: var(--bg-1); overflow: hidden; }
.shop-card-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.shop-card-badge {
  position: absolute;
  top: 12px; right: 12px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
  z-index: 2;
}
.shop-card-badge[data-badge="new"]      { background: var(--amber); color: var(--bg-0); }
.shop-card-badge[data-badge="featured"] { background: #4f8df7; color: #fff; }
.shop-card-badge[data-badge="sale"]     { background: #ff6b4a; color: #fff; }
.shop-card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.shop-card-title { font-size: 16px; font-weight: 700; color: var(--ink-0); margin: 0; }
.shop-card-tagline { font-size: 13px; color: var(--ink-2); margin: 0; line-height: 1.4; flex: 1; }
.shop-card-meta { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; }
.shop-card-price { font-size: 18px; font-weight: 800; color: var(--amber); }
.shop-card-frameworks { display: flex; gap: 4px; }
.shop-card-fw {
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--bg-1);
  color: var(--ink-2);
  font-weight: 600;
}

.shop-empty { text-align: center; padding: 60px 20px; color: var(--ink-2); }
.shop-empty h3 { color: var(--ink-0); margin: 0 0 12px; }
.shop-empty a { color: var(--amber); }

.fivem-shop-back {
  background: transparent; border: none; color: var(--ink-2);
  font-size: 14px; cursor: pointer; margin-bottom: 16px; padding: 6px 0;
}
.fivem-shop-back:hover { color: var(--amber); }
.fivem-shop-detail-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; align-items: start; }
.fivem-shop-gallery { position: relative; background: var(--bg-0); border-radius: 12px; overflow: hidden; }
.gallery-stage { aspect-ratio: 16 / 9; background: var(--bg-1); }
.gallery-stage img, .gallery-stage iframe, .gallery-stage video {
  width: 100%; height: 100%; object-fit: cover; display: block; border: 0;
}
.gallery-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(0,0,0,.6); border: 1px solid rgba(255,255,255,.2); color: #fff;
  cursor: pointer; display: grid; place-items: center;
}
.gallery-nav.prev { left: 10px; }
.gallery-nav.next { right: 10px; }
.gallery-thumbs { display: flex; gap: 8px; padding: 10px; overflow-x: auto; }
.gallery-thumb {
  width: 80px; aspect-ratio: 16 / 9; border-radius: 6px; overflow: hidden;
  border: 2px solid transparent; cursor: pointer; flex-shrink: 0;
}
.gallery-thumb.is-active { border-color: var(--amber); }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

.fivem-shop-info h3 { font-size: 24px; margin: 0 0 6px; color: var(--ink-0); }
.fivem-shop-detail-tagline { color: var(--ink-2); margin: 0 0 16px; }
.fivem-shop-meta-row {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  margin-bottom: 16px; font-size: 12px; color: var(--ink-2);
}
.fivem-shop-meta-row .shop-card-fw { font-size: 11px; }
.fivem-shop-price-block { display: flex; align-items: baseline; gap: 12px; margin-bottom: 16px; }
.fivem-shop-price { font-size: 32px; font-weight: 800; color: var(--amber); }
.fivem-shop-price-old { font-size: 18px; text-decoration: line-through; color: var(--ink-3); }
.fivem-shop-buy {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; padding: 14px 20px;
  background: var(--amber); color: var(--bg-0);
  font-weight: 800; font-size: 16px;
  border-radius: 10px; text-decoration: none;
  transition: transform .15s, filter .15s; margin-bottom: 24px;
}
.fivem-shop-buy:hover { transform: translateY(-1px); filter: brightness(1.08); }

.fivem-shop-info section { margin-bottom: 20px; }
.fivem-shop-info h4 {
  font-size: 13px; text-transform: uppercase; letter-spacing: .06em;
  color: var(--amber); margin: 0 0 10px;
}
.fivem-shop-info ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.fivem-shop-info li { font-size: 14px; color: var(--ink-1); padding-left: 20px; position: relative; }
.fivem-shop-features li::before { content: '✓'; position: absolute; left: 0; color: var(--amber); font-weight: 700; }
.fivem-shop-requirements li::before { content: '•'; position: absolute; left: 6px; color: var(--amber); }
.fivem-shop-longdesc p { font-size: 14px; line-height: 1.6; color: var(--ink-1); margin: 0 0 12px; }

@media (max-width: 1023px) {
  .fivem-shop-grid-list { grid-template-columns: repeat(2, 1fr); }
  .fivem-shop-detail-grid { grid-template-columns: 1fr; }
}
@media (max-width: 639px) {
  .fivem-shop-container {
    width: 100vw; max-height: 100vh; margin: 0;
    border-radius: 0; border: none;
  }
  .fivem-shop-grid-list { grid-template-columns: 1fr; }
  .fivem-shop-view { padding: 16px; }
  .fivem-shop-header { padding: 14px 16px; }
  .fivem-shop-buy { position: sticky; bottom: 0; z-index: 2; margin: 0; border-radius: 8px; }
  .fivem-shop-info > section:last-of-type { margin-bottom: 80px; }
}

body.fivem-shop-locked { overflow: hidden; }
