/* ===== ست کامل با این محصول — موبایل‌اول، RTL، سرمه‌ای/طلایی ===== */

.outfit-section {
  max-width: var(--max);
  margin: 4px auto 0;
  padding: 12px 16px 20px;
}
.outfit-section[hidden] {
  display: none !important;
}
/* موبایل: نوار چسبان پایین (sticky-cart-bar) روی «افزودن همه به سبد»/متن قرمز
   زیرش نیفتد — همان الگوی رزرو فضای body:has(...) .site-footer در style.css،
   اینجا مستقیماً روی خودِ بخش ست. */
@media (max-width: 899px) {
  body:has(.sticky-cart-bar:not([hidden])) .outfit-section {
    padding-bottom: calc(96px + env(safe-area-inset-bottom));
  }
}

.outfit-head {
  margin-bottom: 14px;
}
.outfit-head h2 {
  margin: 0 0 4px;
  font-size: 1.15rem;
  font-weight: 900;
  color: var(--navy);
  letter-spacing: normal;
}
.outfit-sub {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: normal;
}

.outfit-track {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 2px;
  -webkit-overflow-scrolling: touch;
  padding: 2px 2px 10px;
  scrollbar-width: thin;
  scrollbar-color: rgba(220, 185, 85, 0.55) transparent;
}
.outfit-track::-webkit-scrollbar {
  height: 4px;
}
.outfit-track::-webkit-scrollbar-thumb {
  background: rgba(220, 185, 85, 0.55);
  border-radius: 999px;
}

.outfit-card {
  flex: 0 0 158px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(26, 42, 74, 0.08);
  box-shadow:
    6px 6px 14px rgba(26, 42, 74, 0.07),
    -4px -4px 10px rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.outfit-card-media-wrap {
  position: relative;
}
.outfit-card-media {
  display: block;
  aspect-ratio: 3 / 4;
  border-radius: 14px;
  overflow: hidden;
  background: linear-gradient(145deg, #eef1f7, #dfe5f0);
}
.outfit-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.outfit-check {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 1.5px solid rgba(255, 255, 255, 0.9);
  background: rgba(26, 42, 74, 0.45);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  padding: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
  -webkit-tap-highlight-color: transparent;
}
.outfit-check svg {
  width: 14px;
  height: 14px;
  opacity: 0;
  transition: opacity 0.15s ease;
}
.outfit-check.is-on {
  background: var(--navy, #1a2a4a);
  border-color: rgba(220, 185, 85, 0.85);
}
.outfit-check.is-on svg {
  opacity: 1;
  color: #dcb955;
}

.outfit-card-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.outfit-card-name {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.35;
  letter-spacing: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-decoration: none;
}
.outfit-card-name:active {
  opacity: 0.75;
}
.outfit-card-price {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: normal;
}

.outfit-size {
  width: 100%;
  min-height: 36px;
  border-radius: 10px;
  border: 1px solid rgba(26, 42, 74, 0.14);
  background: rgba(255, 255, 255, 0.9);
  color: var(--navy);
  font-family: var(--font-main);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 6px 8px;
  letter-spacing: normal;
  -webkit-appearance: none;
  appearance: none;
}
.outfit-card.is-off {
  opacity: 0.55;
}
.outfit-card.is-off .outfit-size,
.outfit-card.is-off .outfit-size-select {
  pointer-events: none;
}

.outfit-footer {
  margin-top: 12px;
  padding: 14px 14px 12px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(26, 42, 74, 0.08);
  box-shadow:
    6px 6px 14px rgba(26, 42, 74, 0.06),
    -4px -4px 10px rgba(255, 255, 255, 0.8);
}
.outfit-total-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.outfit-total-label {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: normal;
}
.outfit-total-value {
  font-size: 1rem;
  font-weight: 900;
  color: var(--navy);
  letter-spacing: normal;
}
.outfit-add-all {
  width: 100%;
  min-height: 48px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, #1a2a4a 0%, #24365c 100%);
  color: #f5e6c8;
  font-family: var(--font-main);
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: normal;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(26, 42, 74, 0.22);
  -webkit-tap-highlight-color: transparent;
}
.outfit-add-all:active:not(:disabled) {
  transform: scale(0.98);
}
.outfit-add-all:disabled {
  opacity: 0.45;
  cursor: default;
  box-shadow: none;
}
.outfit-hint {
  margin: 8px 0 0;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--discount, #c9536a);
  letter-spacing: normal;
  text-align: center;
}
.outfit-hint[hidden] {
  display: none !important;
}

/* اسکلتون */
.outfit-skel {
  flex: 0 0 158px;
  scroll-snap-align: start;
  padding: 10px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(26, 42, 74, 0.06);
}
.outfit-skel-img {
  aspect-ratio: 3 / 4;
  border-radius: 14px;
  background: linear-gradient(90deg, #e8ecf3 25%, #f4f6fa 50%, #e8ecf3 75%);
  background-size: 200% 100%;
  animation: outfit-shimmer 1.2s ease-in-out infinite;
}
.outfit-skel-body {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.outfit-skel-line {
  height: 10px;
  border-radius: 6px;
  background: #e4e9f1;
}
.outfit-skel-line--price { width: 70%; }
.outfit-skel-line--name { width: 100%; }
.outfit-skel-line--name2 { width: 55%; }

@keyframes outfit-shimmer {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

@media (min-width: 768px) {
  .outfit-section { padding: 16px 24px 28px; }
  .outfit-head h2 { font-size: 1.3rem; }
  .outfit-track {
    overflow: visible;
    flex-wrap: wrap;
    scroll-snap-type: none;
    justify-content: center;
  }
  .outfit-card,
  .outfit-skel {
    flex: 1 1 180px;
    max-width: 220px;
  }
  .outfit-skel-img { animation: none; }
  .outfit-footer {
    display: flex;
    align-items: center;
    gap: 16px;
  }
  .outfit-total-row {
    margin: 0;
    flex: 1;
  }
  .outfit-add-all {
    width: auto;
    min-width: 220px;
    flex-shrink: 0;
  }
  .outfit-hint {
    flex-basis: 100%;
    text-align: start;
    margin-top: 0;
  }
}

/* ===== «روی مدل ببین» (Claude Code، ۲۰۲۶-۱۰-۰۸) ===== */
.outfit-tryon-btn {
  width: 100%;
  min-height: 46px;
  margin-top: 10px;
  border: 1.5px solid #dcb955;
  border-radius: 14px;
  background: transparent;
  color: #1a2a4a;
  font-family: var(--font-main);
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: normal;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.outfit-tryon-btn:active:not(:disabled) {
  transform: scale(0.98);
  background: rgba(220, 185, 85, 0.12);
}
.outfit-tryon-btn:disabled {
  opacity: 0.5;
  cursor: default;
}
.outfit-tryon-btn[hidden],
.outfit-tryon-msg[hidden] {
  display: none !important;
}
.outfit-tryon-msg {
  margin: 8px 0 0;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--discount, #c9536a);
  letter-spacing: normal;
  text-align: center;
}

.tryon-overlay {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  background: rgba(14, 22, 40, 0.72);
}
.tryon-overlay[hidden] {
  display: none !important;
}
.tryon-modal {
  position: relative;
  width: 100%;
  max-width: 420px;
  max-height: 94vh;
  overflow-y: auto;
  padding: 16px 14px 14px;
  border-radius: 20px;
  background: #fbf8f1;
  border: 1px solid rgba(220, 185, 85, 0.5);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  direction: rtl;
}
.tryon-close {
  position: absolute;
  top: 8px;
  left: 10px;
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  color: #1a2a4a;
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
}
.tryon-title {
  margin: 0 0 12px;
  padding-inline-start: 4px;
  font-size: 1rem;
  font-weight: 900;
  color: #1a2a4a;
  letter-spacing: normal;
}
.tryon-stage {
  min-height: 260px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: #fff;
  overflow: hidden;
}
.tryon-img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 70vh;
  object-fit: contain;
}
.tryon-img[hidden],
.tryon-loading[hidden],
.tryon-error[hidden],
.tryon-disclaimer[hidden] {
  display: none !important;
}
.tryon-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 36px 16px;
  text-align: center;
  color: #1a2a4a;
  letter-spacing: normal;
}
.tryon-loading p {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 800;
}
.tryon-loading small {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted, #6b7488);
}
.tryon-spinner {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 3px solid rgba(26, 42, 74, 0.15);
  border-top-color: #dcb955;
  animation: tryon-spin 0.9s linear infinite;
}
@keyframes tryon-spin {
  to { transform: rotate(360deg); }
}
.tryon-error {
  margin: 0;
  padding: 28px 18px;
  text-align: center;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.7;
  color: #1a2a4a;
  letter-spacing: normal;
}
.tryon-disclaimer {
  margin: 10px 2px 0;
  font-size: 0.74rem;
  font-weight: 600;
  line-height: 1.6;
  color: var(--muted, #6b7488);
  text-align: center;
  letter-spacing: normal;
}
body.tryon-open {
  overflow: hidden;
}
@media (min-width: 720px) {
  .outfit-tryon-btn { max-width: 220px; margin-top: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .tryon-spinner { animation-duration: 2.4s; }
}
