/* LUXEFURN — Engagement: quiz, preview, scroll CTA, social proof, hotspots */

/* Social proof ticker */
.social-ticker {
  background: var(--charcoal);
  color: rgba(255,255,255,0.9);
  font-size: 0.75rem;
  padding: 0.45rem 0;
  overflow: hidden;
  white-space: nowrap;
}

.social-ticker__track {
  display: inline-flex;
  animation: ticker 28s linear infinite;
  gap: 3rem;
  padding-left: 100%;
}

.social-ticker__item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

.social-ticker__dot {
  width: 6px;
  height: 6px;
  background: var(--sage);
  border-radius: 50%;
  animation: pulse 2s ease infinite;
}

@keyframes ticker {
  0% { transform: translateX(0); }
  100% { transform: translateX(-100%); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* Quiz trigger pill */
.quiz-pill {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(120%);
  z-index: 90;
  background: var(--white);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  border-radius: 100px;
  padding: 0.65rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  max-width: 92vw;
}

.quiz-pill.visible { transform: translateX(-50%) translateY(0); }

.quiz-pill__icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--coral), var(--gold));
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--white);
  font-size: 0.875rem;
  flex-shrink: 0;
}

.quiz-pill__text {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--charcoal);
  white-space: nowrap;
}

.quiz-pill__arrow { color: var(--coral); font-size: 1rem; }

/* Quiz modal */
.quiz-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(44, 42, 38, 0.55);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.quiz-overlay.open { opacity: 1; visibility: visible; }

.quiz-modal {
  background: var(--white);
  border-radius: var(--radius-lg);
  width: min(520px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  transform: scale(0.92) translateY(20px);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.quiz-overlay.open .quiz-modal { transform: scale(1) translateY(0); }

.quiz-modal__header {
  padding: 1.75rem 1.75rem 0;
  position: relative;
}

.quiz-modal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 32px;
  height: 32px;
  border: none;
  background: var(--sand);
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.125rem;
  line-height: 1;
  color: var(--slate);
}

.quiz-modal__progress {
  height: 4px;
  background: var(--sand);
  border-radius: 100px;
  margin: 1rem 1.75rem 0;
  overflow: hidden;
}

.quiz-modal__progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--coral), var(--gold));
  border-radius: 100px;
  transition: width 0.4s ease;
  width: 33%;
}

.quiz-modal__body { padding: 1.5rem 1.75rem 1.75rem; }

.quiz-modal__step { display: none; }
.quiz-modal__step.active { display: block; animation: fadeUp 0.35s ease; }

.quiz-modal__title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.quiz-modal__desc {
  font-size: 0.875rem;
  color: var(--slate);
  margin-bottom: 1.25rem;
}

.quiz-options {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.quiz-option {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  background: var(--cream);
  cursor: pointer;
  transition: all var(--transition);
  text-align: start;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  color: var(--charcoal);
  width: 100%;
}

.quiz-option:hover {
  border-color: var(--coral);
  background: var(--coral-light);
  transform: translateX(4px);
}

body[dir="rtl"] .quiz-option:hover { transform: translateX(-4px); }

.quiz-option__emoji { font-size: 1.5rem; line-height: 1; }

.quiz-option__label { font-weight: 500; }

.quiz-results__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin: 1rem 0;
}

.quiz-results__item {
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  color: inherit;
}

.quiz-results__item:hover {
  border-color: var(--coral);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.quiz-results__item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.quiz-results__item span {
  display: block;
  padding: 0.5rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.3;
}

/* Product quick preview */
.preview-overlay {
  position: fixed;
  inset: 0;
  z-index: 180;
  background: rgba(44, 42, 38, 0.5);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  visibility: hidden;
  transition: all 0.25s ease;
}

.preview-overlay.open { opacity: 1; visibility: visible; }

.preview-modal {
  background: var(--white);
  border-radius: var(--radius-lg);
  width: min(720px, 100%);
  display: grid;
  grid-template-columns: 1fr 1fr;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  transform: translateY(16px);
  transition: transform 0.3s ease;
}

.preview-overlay.open .preview-modal { transform: translateY(0); }

.preview-modal__image {
  aspect-ratio: 1;
  background: var(--sand);
}

.preview-modal__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.preview-modal__body {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
}

.preview-modal__cat {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.35rem;
}

.preview-modal__title {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

.preview-modal__price {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--coral);
  margin-bottom: 0.75rem;
}

.preview-modal__desc {
  font-size: 0.8125rem;
  color: var(--slate);
  line-height: 1.6;
  flex: 1;
  margin-bottom: 1.25rem;
}

.preview-modal__actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.preview-modal__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 32px;
  height: 32px;
  border: none;
  background: var(--white);
  border-radius: 50%;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  z-index: 2;
}

.preview-modal { position: relative; }

/* Scroll offer bar */
.scroll-offer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 85;
  background: linear-gradient(135deg, var(--coral) 0%, #FF8A7A 100%);
  color: var(--white);
  padding: 0.85rem 1rem;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.34, 1.2, 0.64, 1);
  box-shadow: 0 -4px 24px rgba(255, 107, 91, 0.3);
}

.scroll-offer.visible { transform: translateY(0); }

.scroll-offer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 1200px;
  margin: 0 auto;
  flex-wrap: wrap;
}

.scroll-offer__text {
  font-size: 0.875rem;
  font-weight: 600;
}

.scroll-offer__text em {
  font-style: normal;
  opacity: 0.85;
  font-weight: 400;
  display: block;
  font-size: 0.75rem;
  margin-top: 0.15rem;
}

.scroll-offer .btn {
  background: var(--white);
  color: var(--coral);
  font-weight: 700;
  flex-shrink: 0;
}

.scroll-offer .btn:hover {
  background: var(--charcoal);
  color: var(--white);
}

/* Room explorer hotspots */
.room-explorer {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16/9;
  box-shadow: var(--shadow-lg);
  background: var(--sand);
}

.room-explorer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hotspot {
  position: absolute;
  width: 36px;
  height: 36px;
  border: none;
  background: rgba(255,255,255,0.95);
  border-radius: 50%;
  cursor: pointer;
  transform: translate(-50%, -50%);
  box-shadow: 0 2px 12px rgba(0,0,0,0.2);
  transition: transform 0.25s ease;
  z-index: 2;
}

.hotspot::before {
  content: '';
  position: absolute;
  inset: -6px;
  border: 2px solid var(--white);
  border-radius: 50%;
  animation: hotspotRing 2s ease infinite;
}

.hotspot::after {
  content: '+';
  font-size: 1.25rem;
  font-weight: 300;
  color: var(--coral);
  line-height: 36px;
}

.hotspot:hover { transform: translate(-50%, -50%) scale(1.15); }

@keyframes hotspotRing {
  0%, 100% { transform: scale(1); opacity: 0.8; }
  50% { transform: scale(1.3); opacity: 0; }
}

.hotspot-tooltip {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  background: var(--white);
  border-radius: 10px;
  padding: 0.65rem 0.85rem;
  box-shadow: var(--shadow-md);
  white-space: nowrap;
  font-size: 0.75rem;
  font-weight: 600;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
  pointer-events: none;
  z-index: 3;
}

.hotspot-tooltip strong { color: var(--coral); display: block; font-size: 0.8125rem; }

.hotspot:hover .hotspot-tooltip,
.hotspot.active .hotspot-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* Viewers badge */
.viewers-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--sage-light);
  color: var(--charcoal);
  font-size: 0.8125rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 100px;
  margin-top: 0.75rem;
}

.viewers-badge__pulse {
  width: 8px;
  height: 8px;
  background: var(--sage);
  border-radius: 50%;
  animation: pulse 1.5s ease infinite;
}

.product-card--preview { cursor: pointer; }

.product-card__quick {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  background: var(--white);
  color: var(--charcoal);
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 0.35rem 0.7rem;
  border-radius: 100px;
  opacity: 0;
  transform: translateY(4px);
  transition: all 0.25s ease;
  pointer-events: none;
}

body[dir="rtl"] .product-card__quick { right: auto; left: 1rem; }

.product-card:hover .product-card__quick {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 768px) {
  .preview-modal { grid-template-columns: 1fr; }
  .preview-modal__image { aspect-ratio: 4/3; }
  .quiz-results__grid { grid-template-columns: 1fr; }
  .quiz-pill__text { font-size: 0.75rem; }
  .scroll-offer__inner { justify-content: center; text-align: center; }
  .purchased-stats__inner { grid-template-columns: 1fr; gap: 2rem; }
  .purchased-stats__grid { grid-template-columns: 1fr; }
  .purchased-stats__number { font-size: 2.75rem; }
}

/* Purchased stats */
.purchased-stats {
  background: linear-gradient(135deg, var(--white) 0%, var(--gold-light) 40%, var(--sage-light) 100%);
  padding: 3.5rem 0;
  border-bottom: 1px solid var(--border);
}

.purchased-stats__inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: center;
}

.purchased-stats__eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 0.75rem;
}

.purchased-stats__number-row {
  display: flex;
  align-items: baseline;
  gap: 0.25rem;
  margin-bottom: 0.5rem;
}

.purchased-stats__number {
  font-family: var(--font-display);
  font-size: clamp(3rem, 6vw, 4.5rem);
  font-weight: 700;
  line-height: 1;
  color: var(--coral);
  font-variant-numeric: tabular-nums;
}

.purchased-stats__suffix {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--coral);
  opacity: 0.7;
}

.purchased-stats__title {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  font-weight: 600;
  margin-bottom: 0.65rem;
  line-height: 1.2;
}

.purchased-stats__desc {
  font-size: 0.9375rem;
  color: var(--slate);
  line-height: 1.65;
  max-width: 480px;
  margin-bottom: 0.75rem;
}

.purchased-stats__region {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--charcoal);
  padding: 0.5rem 0.85rem;
  background: rgba(255,255,255,0.7);
  border-radius: 100px;
  display: inline-block;
  border: 1px solid var(--border);
}

.purchased-stats__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.purchased-stats__card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.35rem 1rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  transition: transform var(--transition);
}

.purchased-stats__card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.purchased-stats__card strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--charcoal);
  margin-bottom: 0.35rem;
  font-variant-numeric: tabular-nums;
}

.purchased-stats__card span {
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 500;
  line-height: 1.35;
}

.purchased-stats--compact {
  padding: 2rem 0;
}

.purchased-stats--compact .purchased-stats__inner {
  grid-template-columns: 1fr;
  text-align: center;
}

.purchased-stats--compact .purchased-stats__desc,
.purchased-stats--compact .purchased-stats__region {
  margin-inline: auto;
}

.purchased-stats--compact .purchased-stats__grid {
  max-width: 560px;
  margin-inline: auto;
}
