/* ============================================
   PACKS.CSS — Rahiq Bio
   Covers: packs.html page + index.html packs strip
   ============================================ */

/* ── Savings Strip ── */
.packs-savings-strip {
  background: linear-gradient(135deg, var(--olive), var(--olive-dark));
  padding: 14px 20px;
}

.savings-strip-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.savings-item {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  font-size: 0.92rem;
  font-weight: 600;
}

.savings-item strong { color: var(--gold-light); font-size: 1rem; }
.savings-icon        { font-size: 1.1rem; }
.savings-sep         { color: rgba(255, 255, 255, 0.3); font-size: 1.2rem; }

/* ── Loading Skeletons ── */
.packs-loading { padding: 20px 0; }

.packs-skeleton-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 28px;
}

.pack-skeleton {
  height: 440px;
  border-radius: var(--radius-xl);
  background: var(--cream-dark);
  position: relative;
  overflow: hidden;
}

/* FIX: Shimmer keyframe name aligns with single canonical definition in animations.css */
.pack-skeleton::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.55),
    transparent
  );
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
}

/* ── Empty State ── */
.packs-empty {
  text-align: center;
  padding: 80px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

/* FIX: Removed duplicate .empty-state-icon — already defined in style.css.
   Only override what differs here (opacity). */
.packs-empty .empty-state-icon {
  opacity: 0.5;
  margin-bottom: 8px;
}

/* ── Packs Grid ── */
.packs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 28px;
}

/* ── Pack Card ── */
.pack-card {
  position: relative;
  border-radius: var(--radius-xl);
  background: var(--white);
  border: 2px solid rgba(212, 175, 55, 0.15);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: var(--transition);
  cursor: pointer;
  opacity: 0;
  transform: translateY(20px);
}

.pack-card.visible {
  opacity: 1;
  transform: translateY(0);
  /* FIX: transition preserved so entrance animation completes smoothly */
  transition: opacity 0.4s ease, transform 0.4s ease;
}

/* FIX: Removed !important from hover — it was overriding the entrance animation
   mid-flight. Now uses specificity naturally; visible state uses a short
   transition so hover still works after card has appeared. */
.pack-card.visible:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(212, 175, 55, 0.4);
  transition: var(--transition);
}

.pack-card--featured {
  border-color: rgba(212, 175, 55, 0.45);
  box-shadow: 0 4px 24px rgba(212, 175, 55, 0.18);
}

.pack-card--featured::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--gold), var(--gold-light), var(--olive));
  z-index: 2;
}

/* ── Featured Ribbon ── */
/* FIX: Unified ribbon using inset-inline-end and logical rotation.
   RTL default: ribbon sits on the right shoulder.
   LTR (lang-fr): ribbon sits on the right shoulder (same visual convention). */
.pack-featured-ribbon {
  position: absolute;
  top: 18px;
  inset-inline-end: -32px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  color: var(--umber);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 5px 44px;
  z-index: 3;
  box-shadow: var(--shadow-sm);
  font-family: 'Lato', sans-serif;
  letter-spacing: 0.5px;
  white-space: nowrap;
  /* FIX: direction-specific rotation handled by separate rules below */
}

/* RTL (default): ribbon rotates clockwise to sit on the top-right corner */
body[dir="rtl"] .pack-featured-ribbon {
  transform: rotate(45deg);
  transform-origin: center;
}

/* LTF: ribbon also sits top-right, same visual — no change needed */
body.lang-fr .pack-featured-ribbon {
  inset-inline-end: -32px;
  inset-inline-start: auto;
  transform: rotate(45deg);
  transform-origin: center;
}

.pack-card-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* ── Card Visual ── */
.pack-card-visual {
  position: relative;
  height: 180px;
  background: linear-gradient(135deg, var(--cream) 0%, var(--cream-dark) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.pack-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.pack-card.visible:hover .pack-card-img { transform: scale(1.06); }

.pack-card-placeholder {
  font-size: 3rem;
  letter-spacing: 8px;
  opacity: 0.75;
  filter: drop-shadow(0 4px 12px rgba(212, 175, 55, 0.25));
  transition: transform 0.4s ease;
}

.pack-card.visible:hover .pack-card-placeholder { transform: scale(1.1); }

/* ── Badges ── */
/* FIX: Replaced left/right with inset-inline-start; removed redundant body[dir] overrides */
.pack-badge {
  position: absolute;
  top: 14px;
  inset-inline-start: 14px;
  padding: 4px 12px;
  border-radius: var(--radius-xl);
  font-size: 0.75rem;
  font-weight: 700;
  font-family: 'Lato', sans-serif;
  letter-spacing: 0.3px;
  z-index: 2;
  white-space: nowrap;
}

/* FIX: Removed body[dir="rtl"] and body.lang-fr overrides — inset-inline-start handles both */

.pack-badge-gold  {
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  color: var(--umber);
}

.pack-badge-olive {
  background: linear-gradient(135deg, var(--olive), var(--olive-dark));
  color: white;
}

.pack-badge-umber {
  background: linear-gradient(135deg, var(--umber), var(--umber-light));
  color: var(--gold);
}

/* Savings tag on visual */
/* FIX: Replaced right/left with inset-inline-end; removed redundant body[dir] override */
.pack-savings-tag {
  position: absolute;
  bottom: 14px;
  inset-inline-end: 14px;
  background: #e74c3c;
  color: white;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-xl);
  font-family: 'Lato', sans-serif;
  z-index: 2;
}

/* FIX: Removed body[dir="rtl"] and body.lang-fr overrides — inset-inline-end handles both */

/* ── Card Body ── */
.pack-card-body {
  padding: 22px 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1;
}

.pack-card-name {
  font-family: 'Scheherazade New', serif;
  font-size: 1.25rem;
  color: var(--umber);
  font-weight: 700;
  line-height: 1.3;
  margin: 0;
}

body.lang-fr .pack-card-name {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
}

.pack-card-desc {
  font-size: 0.88rem;
  color: var(--text-light);
  line-height: 1.6;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── Product Tags ── */
.pack-products-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.pack-products-label {
  font-size: 0.78rem;
  font-family: 'Lato', sans-serif;
  font-weight: 700;
  color: var(--text-light);
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin: 0;
}

.pack-products-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.pack-product-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--cream);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: var(--radius-xl);
  padding: 3px 10px;
  font-size: 0.78rem;
  color: var(--text-mid);
  font-weight: 600;
  white-space: nowrap;
}

/* ── Price Row ── */
.pack-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px dashed rgba(212, 175, 55, 0.25);
  margin-top: auto;
}

.pack-price-wrap {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}

.pack-price {
  font-family: 'Lato', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold-dark);
}

.pack-price small {
  font-size: 0.85rem;
  color: var(--text-light);
  font-weight: 400;
}

.pack-original-price {
  font-size: 0.9rem;
  color: var(--text-light);
  text-decoration: line-through;
  font-family: 'Lato', sans-serif;
}

/* ── Card Actions ── */
.pack-card-actions {
  display: flex;
  gap: 10px;
}

.pack-add-btn {
  flex: 1;
  justify-content: center;
  font-size: 0.92rem;
  padding: 11px 16px;
}

/* ============================================
   PACK DETAIL MODAL
   ============================================ */
.modal-pack {
  max-width: 860px;
  padding: 0;
  overflow: hidden;
  border-radius: var(--radius-xl);
}

/* FIX: Modal close uses inset-inline-end so it stays on the correct corner in both
   RTL (top-left visually = inline-start) and LTR (top-right = inline-end).
   Since packs modal is visually positioned at top-right in all layouts, we
   use inset-inline-end and remove the redundant body[dir]/lang-fr overrides. */
.modal-pack .modal-close {
  position: absolute;
  top: 16px;
  inset-inline-end: 16px;
  z-index: 10;
  background: rgba(75, 54, 33, 0.15);
  border: none;
  color: var(--umber);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

/* FIX: Removed body[dir="rtl"] and body.lang-fr overrides — inset-inline-end handles both */

.modal-pack .modal-close:hover {
  background: rgba(75, 54, 33, 0.3);
}

.pack-modal-inner {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  min-height: 500px;
}

/* ── Modal Visual Panel ── */
.pack-modal-visual {
  background: linear-gradient(135deg, var(--cream), var(--cream-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  min-height: 300px;
}

.pack-modal-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pack-modal-placeholder {
  font-size: 4.5rem;
  letter-spacing: 10px;
  filter: drop-shadow(0 6px 20px rgba(212, 175, 55, 0.3));
  animation: float 3s ease-in-out infinite;
  text-align: center;
  padding: 20px;
}

.pack-savings-big {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: #e74c3c;
  color: white;
  font-size: 1rem;
  font-weight: 700;
  padding: 8px 20px;
  border-radius: var(--radius-xl);
  font-family: 'Lato', sans-serif;
  white-space: nowrap;
  box-shadow: var(--shadow-md);
}

/* ── Modal Info Panel ── */
.pack-modal-info {
  padding: 36px 32px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  overflow-y: auto;
  max-height: 80vh;
}

.pack-modal-name {
  font-family: 'Scheherazade New', serif;
  font-size: 1.7rem;
  color: var(--umber);
  line-height: 1.3;
  margin: 0;
}

body.lang-fr .pack-modal-name {
  font-family: 'Playfair Display', serif;
}

.pack-modal-desc {
  color: var(--text-mid);
  font-size: 0.96rem;
  line-height: 1.8;
  margin: 0;
}

/* ── Product Breakdown ── */
.pack-modal-products h4 {
  font-family: 'Scheherazade New', serif;
  font-size: 1rem;
  color: var(--umber);
  margin-bottom: 12px;
}

.pack-modal-product-list {
  background: var(--cream);
  border-radius: var(--radius-md);
  padding: 14px;
  border: 1px solid rgba(212, 175, 55, 0.2);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pack-modal-product-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--text-mid);
  padding: 4px 0;
}

.pmpr-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pmpr-icon { font-size: 1.1rem; }
.pmpr-name { font-weight: 600; color: var(--text-dark); }

.pmpr-price {
  font-family: 'Lato', sans-serif;
  font-weight: 700;
  color: var(--text-mid);
}

.pmpr-price small {
  font-size: 0.75rem;
  font-weight: 400;
}

.pack-modal-divider {
  height: 1px;
  background: rgba(212, 175, 55, 0.25);
  margin: 4px 0;
}

.pack-modal-total-row { font-weight: 600; color: var(--text-mid); }

.pmpr-original {
  font-family: 'Lato', sans-serif;
  font-weight: 700;
  text-decoration: line-through;
  color: var(--text-light);
}

.pack-modal-savings-row { font-weight: 700; }

.pmpr-saving {
  color: var(--olive);
  font-family: 'Lato', sans-serif;
  font-weight: 700;
}

/* ── Modal Footer ── */
.pack-modal-footer {
  padding-top: 16px;
  border-top: 1px solid rgba(212, 175, 55, 0.2);
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: auto;
}

.pack-modal-price-wrap {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.pack-modal-price {
  font-family: 'Lato', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--gold-dark);
}

.pack-modal-price small {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-light);
}

.pack-modal-original {
  font-size: 1rem;
  text-decoration: line-through;
  color: var(--text-light);
  font-family: 'Lato', sans-serif;
}

.pack-modal-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pack-modal-actions .btn {
  width: 100%;
  justify-content: center;
}

/* FIX: Removed duplicate .btn-whatsapp definition — fully defined in style.css.
   Any packs-specific WhatsApp button overrides belong here only if they
   visually differ from the global definition. Currently they do not. */

/* ============================================
   CUSTOM PACK CTA SECTION
   ============================================ */
.custom-pack-section { background: var(--cream-dark); }

.custom-pack-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 36px 48px;
  border: 2px solid rgba(212, 175, 55, 0.2);
  box-shadow: var(--shadow-md);
  flex-wrap: wrap;
}

.custom-pack-icon {
  font-size: 3rem;
  animation: float 3s ease-in-out infinite;
  flex-shrink: 0;
}

.custom-pack-text {
  flex: 1;
  min-width: 200px;
}

.custom-pack-text h3 {
  font-family: 'Scheherazade New', serif;
  font-size: 1.4rem;
  color: var(--umber);
  margin-bottom: 6px;
}

body.lang-fr .custom-pack-text h3 {
  font-family: 'Playfair Display', serif;
}

.custom-pack-text p {
  color: var(--text-light);
  font-size: 0.96rem;
  margin: 0;
}

/* ============================================
   INDEX.HTML — PACKS STRIP SECTION
   ============================================ */
.packs-strip-section {
  background: var(--cream-dark);
}

/* Skeleton grid for strip */
.packs-strip-skeleton {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 22px;
  margin-bottom: 0;
}

.strip-pack-skeleton {
  height: 280px;
  border-radius: var(--radius-xl);
  background: var(--cream);
  position: relative;
  overflow: hidden;
}

.strip-pack-skeleton::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.6),
    transparent
  );
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
}

/* Strip Grid */
.packs-strip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 22px;
}

/* ── Strip Pack Card ── */
.strip-pack-card {
  position: relative;
  background: var(--white);
  border-radius: var(--radius-xl);
  border: 2px solid rgba(212, 175, 55, 0.15);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  cursor: pointer;
}

.strip-pack-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(212, 175, 55, 0.35);
}

.strip-pack-card--featured {
  border-color: rgba(212, 175, 55, 0.4);
}

.strip-pack-card--featured::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--gold), var(--gold-light), var(--olive));
  z-index: 2;
}

/* Strip card visual */
.strip-pack-visual {
  height: 140px;
  background: linear-gradient(135deg, var(--cream), var(--cream-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.strip-pack-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.strip-pack-card:hover .strip-pack-visual img { transform: scale(1.06); }

.strip-pack-placeholder {
  font-size: 2.8rem;
  letter-spacing: 6px;
  opacity: 0.75;
  filter: drop-shadow(0 3px 8px rgba(212, 175, 55, 0.2));
  transition: transform 0.4s ease;
}

.strip-pack-card:hover .strip-pack-placeholder { transform: scale(1.1); }

/* FIX: Savings tag uses inset-inline-start; removed body[dir="rtl"] override.
   Tag sits on the "start" side of the visual (right in RTL, left in LTR). */
.strip-pack-savings-tag {
  position: absolute;
  bottom: 10px;
  inset-inline-start: 10px;
  background: #e74c3c;
  color: white;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: var(--radius-xl);
  font-family: 'Lato', sans-serif;
  z-index: 2;
}

/* FIX: Removed body[dir="rtl"] override — inset-inline-start handles both directions.
   NOTE: In the original the RTL override moved it to right:10px, which is
   inset-inline-end in LTR. To keep it at the visual "start" (right in RTL),
   inset-inline-start is the correct logical property. */

/* FIX: Added lang-fr restore — LTR mode should place tag at left (inline-start = left) */
body.lang-fr .strip-pack-savings-tag {
  inset-inline-start: 10px;
}

/* Strip card body */
.strip-pack-body {
  padding: 16px 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.strip-pack-name {
  font-family: 'Scheherazade New', serif;
  font-size: 1.05rem;
  color: var(--umber);
  font-weight: 700;
  line-height: 1.3;
  margin: 0;
}

body.lang-fr .strip-pack-name {
  font-family: 'Playfair Display', serif;
  font-size: 0.93rem;
}

.strip-pack-products {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.strip-pack-tag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: var(--cream);
  border: 1px solid rgba(212, 175, 55, 0.18);
  border-radius: var(--radius-xl);
  padding: 2px 8px;
  font-size: 0.72rem;
  color: var(--text-mid);
  font-weight: 600;
  white-space: nowrap;
}

.strip-pack-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px dashed rgba(212, 175, 55, 0.22);
  margin-top: auto;
  gap: 8px;
}

.strip-pack-price {
  font-family: 'Lato', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--gold-dark);
}

.strip-pack-price small {
  font-size: 0.78rem;
  font-weight: 400;
  color: var(--text-light);
}

.strip-pack-original {
  font-size: 0.82rem;
  color: var(--text-light);
  text-decoration: line-through;
  font-family: 'Lato', sans-serif;
  margin-top: 2px;
}

.strip-pack-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  color: var(--umber);
  border: none;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  box-shadow: 0 2px 10px rgba(212, 175, 55, 0.28);
  flex-shrink: 0;
  line-height: 1;
}

.strip-pack-btn:hover {
  transform: scale(1.14) rotate(8deg);
  box-shadow: 0 4px 16px rgba(212, 175, 55, 0.42);
}

/* CTA below strip grid */
.packs-strip-cta {
  text-align: center;
}

/* ============================================
   ADMIN — PACKS MANAGEMENT STYLES
   NOTE: These styles apply only within admin.html.
   Consider moving to admin.css if admin panel is
   ever split into a separate stylesheet.
   ============================================ */

/* Stats row */
.packs-admin-stats {
  display: flex;
  gap: 16px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.pack-stat-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 18px 24px;
  border: 1px solid rgba(212, 175, 55, 0.15);
  box-shadow: var(--shadow-sm);
  flex: 1;
  min-width: 140px;
}

.psk-icon { font-size: 1.8rem; }

.pack-stat-card div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.pack-stat-card strong {
  font-size: 1.5rem;
  font-family: 'Lato', sans-serif;
  color: var(--gold-dark);
  font-weight: 700;
}

.pack-stat-card small {
  font-size: 0.78rem;
  color: var(--text-light);
  font-family: 'Lato', sans-serif;
}

/* Table cells */
.pack-table-name {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pack-table-icon { font-size: 1.5rem; }

.pack-table-name strong {
  display: block;
  color: var(--umber);
  font-size: 0.95rem;
}

.pack-table-name small {
  display: block;
  color: var(--text-light);
  font-size: 0.78rem;
}

.pack-table-products {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-width: 220px;
}

.mini-product-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--cream);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: var(--radius-xl);
  padding: 2px 8px;
  font-size: 0.72rem;
  color: var(--text-mid);
  font-weight: 600;
  white-space: nowrap;
}

.pack-table-price strong {
  display: block;
  color: var(--gold-dark);
  font-size: 0.95rem;
}

.pack-table-price s {
  display: block;
  color: var(--text-light);
  font-size: 0.8rem;
}

.savings-chip {
  display: inline-block;
  background: rgba(107, 142, 35, 0.12);
  color: var(--olive);
  border: 1px solid rgba(107, 142, 35, 0.25);
  border-radius: var(--radius-xl);
  padding: 3px 10px;
  font-size: 0.8rem;
  font-weight: 700;
  font-family: 'Lato', sans-serif;
}

.row-inactive { opacity: 0.55; }

/* ── Toggle Switch ── */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 42px;
  height: 22px;
  cursor: pointer;
}

.toggle-switch input { opacity: 0; width: 0; height: 0; }

.toggle-slider {
  position: absolute;
  inset: 0;
  background: #ccc;
  border-radius: 22px;
  transition: background 0.3s;
}

/* FIX: Thumb ::before must target .toggle-slider::before, not .toggle-slider-gold::before.
   The original used a broken adjacent sibling selector that never matched. */
.toggle-slider::before {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  left: 3px;
  bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: transform 0.3s;
}

/* Checked state — olive variant */
.toggle-switch input:checked + .toggle-slider {
  background: var(--olive);
}

/* FIX: Gold slider — separate element, same structure */
.toggle-slider-gold {
  position: absolute;
  inset: 0;
  background: #ccc;
  border-radius: 22px;
  transition: background 0.3s;
}

.toggle-slider-gold::before {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  left: 3px;
  bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: transform 0.3s;
}

/* FIX: Gold slider checked state — now correctly targets the element */
.toggle-switch input:checked + .toggle-slider-gold {
  background: var(--gold-dark);
}

/* FIX: Thumb movement applies to both slider variants */
.toggle-switch input:checked + .toggle-slider::before,
.toggle-switch input:checked + .toggle-slider-gold::before {
  transform: translateX(20px);
}

/* ── Admin Pack Form Modal ── */
.modal-pack-form {
  max-width: 780px;
  max-height: 90vh;
  overflow-y: auto;
}

.pack-form-body { padding: 24px 28px; }

.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-row-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
}

.form-hint {
  font-size: 0.82rem;
  color: var(--text-light);
  margin-bottom: 10px;
}

/* Savings preview */
.savings-preview {
  padding: 12px 16px;
  background: var(--cream);
  border: 2px solid rgba(212, 175, 55, 0.2);
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-light);
  height: 48px;
  display: flex;
  align-items: center;
}

/* ── Products Picker ── */
.pack-products-picker {
  border: 2px solid rgba(212, 175, 55, 0.2);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--cream);
  margin-bottom: 12px;
}

.picker-cat-group {
  border-bottom: 1px solid rgba(212, 175, 55, 0.15);
}

.picker-cat-group:last-child { border-bottom: none; }

.picker-cat-label {
  padding: 8px 14px;
  background: rgba(212, 175, 55, 0.08);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--gold-dark);
  letter-spacing: 1px;
  text-transform: uppercase;
  font-family: 'Lato', sans-serif;
  border-bottom: 1px solid rgba(212, 175, 55, 0.1);
}

.picker-cat-products {
  display: flex;
  flex-direction: column;
}

.picker-product {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  cursor: pointer;
  transition: background 0.2s;
  border-bottom: 1px solid rgba(212, 175, 55, 0.08);
}

.picker-product:last-child { border-bottom: none; }
.picker-product:hover      { background: rgba(212, 175, 55, 0.06); }
.picker-product.selected   { background: rgba(212, 175, 55, 0.12); }

.picker-product input[type="checkbox"] {
  accent-color: var(--gold-dark);
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.picker-product-icon { font-size: 1.1rem; }

.picker-product-name {
  flex: 1;
  font-size: 0.9rem;
  color: var(--text-dark);
  font-weight: 600;
}

.picker-product-price {
  font-family: 'Lato', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--gold-dark);
}

/* Picker summary */
.pack-picker-summary {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--white);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  color: var(--text-mid);
  flex-wrap: wrap;
}

.pack-picker-summary strong {
  color: var(--gold-dark);
  font-family: 'Lato', sans-serif;
  font-size: 1rem;
}

.picker-savings {
  color: var(--olive);
  font-weight: 700;
  font-size: 0.88rem;
  font-family: 'Lato', sans-serif;
}

/* Pack Form Actions */
.pack-form-actions {
  display: flex;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid rgba(212, 175, 55, 0.15);
  margin-top: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.pack-form-actions .btn {
  min-width: 140px;
  justify-content: center;
}

/* ============================================
   RESPONSIVE — packs.css
   ============================================ */

/* Tablet */
@media (max-width: 900px) {
  .pack-modal-inner {
    grid-template-columns: 1fr;
  }

  .pack-modal-visual { min-height: 220px; }
  .pack-modal-info   { max-height: none; }

  .pack-form-body { padding: 20px; }

  .form-row-2,
  .form-row-3 {
    grid-template-columns: 1fr;
  }

  .packs-admin-stats { gap: 10px; }
}

/* Mobile */
@media (max-width: 768px) {
  /* FIX: packs-grid on mobile allows 2 columns on medium-small phones
     instead of forcing 1fr which was too restrictive for 500-768px range. */
  .packs-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    max-width: 100%;
  }

  .packs-strip-grid,
  .packs-strip-skeleton {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }

  .savings-strip-inner { gap: 12px; }
  .savings-sep         { display: none; }

  .custom-pack-inner {
    flex-direction: column;
    text-align: center;
    padding: 28px 24px;
  }

  .pack-stat-card {
    min-width: 120px;
    padding: 14px 16px;
  }

  .pack-form-actions {
    flex-direction: column;
  }

  .pack-form-actions .btn {
    width: 100%;
    min-width: unset;
  }
}

/* Narrow mobile — single column */
@media (max-width: 560px) {
  /* FIX: Collapse packs grid to 1 column only on genuinely small screens */
  .packs-grid {
    grid-template-columns: 1fr;
    max-width: 480px;
    margin: 0 auto;
  }
}

/* Small mobile */
@media (max-width: 480px) {
  .pack-card-actions { flex-direction: column; }
  .pack-card-visual  { height: 150px; }

  .packs-strip-grid,
  .packs-strip-skeleton {
    grid-template-columns: 1fr;
    max-width: 340px;
    margin: 0 auto;
  }

  .strip-pack-visual { height: 120px; }

  .strip-pack-placeholder {
    font-size: 2rem;
    letter-spacing: 4px;
  }

  .pack-modal-price { font-size: 1.6rem; }
  .pack-modal-info  { padding: 24px 18px; }
}
