/* ==========================================================================
   Worship Light: home page carousels (hero slideshow + product tour).
   Loaded only by index.html, after index.css and pro.css.
   ========================================================================== */

/* ---------- hero slideshow ---------- */
.hero-pro.hero-photo.has-slides { background: var(--bg); }
.hero-slides {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
}
.hero-slide {
  position: absolute;
  inset: -2%;
  background-position: center 35%;
  background-size: cover;
  background-repeat: no-repeat;
  opacity: 0;
  transform: scale(1.08);
  transition: opacity 1.6s ease, transform 8s ease-out;
  will-change: opacity, transform;
}
.hero-slide.is-active { opacity: 1; transform: scale(1); }
.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(900px 420px at 50% 40%, rgba(8, 8, 10, 0.25), rgba(8, 8, 10, 0.55)),
    linear-gradient(180deg, rgba(8, 8, 10, 0.72) 0%, rgba(8, 8, 10, 0.5) 45%, rgba(8, 8, 10, 0.97) 100%);
}
.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 28px;
  z-index: 2;
  display: flex;
  gap: 8px;
  transform: translateX(-50%);
}
.hero-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  transition: width 0.35s ease, background 0.35s ease;
}
.hero-dot:hover { background: rgba(255, 255, 255, 0.6); }
.hero-dot.is-active { width: 28px; background: var(--accent); }
.hero-dot:focus-visible { outline: 2px solid var(--accent-hover); outline-offset: 3px; }

/* ---------- product tour carousel ---------- */
.fcarousel { margin-top: 56px; }

.fc-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  max-width: 820px;
  margin: 0 auto 36px;
  padding: 6px;
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  background: var(--bg-alt);
}
.fc-tab {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 46px;
  padding: 0 14px;
  border: 0;
  border-radius: var(--radius-full);
  background: transparent;
  color: var(--text-secondary);
  font: 600 14.5px/1 var(--font);
  cursor: pointer;
  overflow: hidden;
  transition: background 0.3s ease, color 0.3s ease;
}
.fc-tab:hover { color: var(--text); }
.fc-tab.is-active { background: var(--surface-2); color: var(--text); box-shadow: inset 0 0 0 1px var(--accent-line); }
.fc-tab:focus-visible { outline: 2px solid var(--accent-hover); outline-offset: 2px; }
.fc-tab-ic { font-size: 16px; }
.fc-tab-bar {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 5px;
  height: 2px;
  border-radius: 2px;
  background: transparent;
  overflow: hidden;
}
.fc-tab.is-active .fc-tab-bar { background: rgba(255, 255, 255, 0.08); }
.fc-tab-bar i {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--accent-dim), var(--accent-hover));
  transform: scaleX(0);
  transform-origin: left center;
}
.fc-tab.is-active.is-running .fc-tab-bar i { animation: fc-progress var(--fc-duration, 7s) linear forwards; }
.fcarousel.is-paused .fc-tab.is-running .fc-tab-bar i { animation-play-state: paused; }
@keyframes fc-progress { from { transform: scaleX(0); } to { transform: scaleX(1); } }

.fc-viewport {
  overflow: hidden;
  border-radius: var(--radius-lg);
  touch-action: pan-y;
}
.fc-track {
  display: flex;
  transition: transform 0.7s cubic-bezier(0.22, 0.8, 0.24, 1);
  will-change: transform;
}
.fc-slide {
  flex: 0 0 100%;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  align-items: center;
  gap: 56px;
  padding: 8px 4px;
}
.fc-slide .shot-card { transition: transform 0.9s ease, opacity 0.9s ease; transform: scale(0.96); opacity: 0.5; }
.fc-slide.is-active .shot-card { transform: none; opacity: 1; }
.fc-slide .shot-card img { aspect-ratio: 3 / 2; width: 100%; height: auto; object-fit: cover; max-height: none; }
.fc-slide .showcase-copy > * { transition: opacity 0.6s ease, transform 0.6s ease; }
.fc-slide:not(.is-active) .showcase-copy > * { opacity: 0; transform: translateY(14px); }
.fc-slide.is-active .showcase-copy > :nth-child(2) { transition-delay: 0.08s; }
.fc-slide.is-active .showcase-copy > :nth-child(3) { transition-delay: 0.16s; }
.fc-slide.is-active .showcase-copy > :nth-child(4) { transition-delay: 0.24s; }

.fc-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 30px;
}
.fc-arrow {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--border-strong);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.fc-arrow:hover { background: var(--accent-soft-strong); border-color: var(--accent-line); transform: translateY(-2px); }
.fc-arrow:focus-visible { outline: 2px solid var(--accent-hover); outline-offset: 3px; }
.fc-count { min-width: 56px; color: var(--text-muted); font-size: 14px; text-align: center; font-variant-numeric: tabular-nums; }
.fc-count b { color: var(--text); }

/* keep the reveal-hover lift from pro.css off the carousel */
.fcarousel.reveal.is-visible:hover { transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 1024px) {
  .fc-slide { grid-template-columns: 1fr; gap: 28px; }
}
@media (max-width: 720px) {
  .fc-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); border-radius: 22px; }
  .fc-tab { height: 42px; font-size: 13.5px; }
  .hero-dots { bottom: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-slide, .fc-track, .fc-slide .shot-card, .fc-slide .showcase-copy > * { transition: none; }
  .hero-slide { transform: none; }
  .fc-tab-bar i { animation: none !important; }
}
