/* ================= 후기 슬라이더 ================= */
.rs { position: relative; }
.rs-view { overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: 0 20px; scrollbar-width: none; margin: 0 -20px; padding: 10px 20px 24px; outline: none; }
.rs-view::-webkit-scrollbar { display: none; }
.rs-track { display: flex; gap: 20px; }
.rs-card { flex: 0 0 calc((100% - 60px) / 4); scroll-snap-align: start; background: #fff; border-radius: 18px; overflow: hidden; border: 1px solid var(--line);
  display: flex; flex-direction: column; transition: transform .35s ease, box-shadow .35s ease, opacity .6s ease;
  opacity: 0; transform: translateY(26px) scale(.97); }
.rs.shown .rs-card { opacity: 1; transform: none; transition-delay: var(--d), var(--d), var(--d); }
.rs.shown .rs-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); transition-delay: 0s; }
.rs-img { position: relative; overflow: hidden; aspect-ratio: 1; }
.rs-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.rs-card:hover .rs-img img { transform: scale(1.07); }
.rs-prod { position: absolute; left: 12px; bottom: 12px; font-size: 12px; font-weight: 800; padding: 5px 10px; border-radius: 999px; color: #fff; backdrop-filter: blur(4px); }
.rs-prod.eyes { background: rgba(16,32,74,.85); }
.rs-prod.skin { background: rgba(27,53,40,.85); }
.rs-body { padding: 18px 20px 22px; position: relative; }
.rs-body::before { content: "\201C"; position: absolute; right: 16px; top: -6px; font-family: var(--serif); font-size: 64px; line-height: 1; color: var(--gold-soft); }
.rs-top { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--ink-3); margin-bottom: 8px; }
.rs-body p { font-size: 15px; line-height: 1.6; }
.rs-nav { position: absolute; top: calc(50% - 40px); width: 50px; height: 50px; border-radius: 50%; border: 0; background: #fff; color: var(--navy); font-size: 30px; line-height: 1;
  box-shadow: var(--shadow-lg); display: grid; place-items: center; z-index: 2; transition: transform .2s, opacity .2s; padding-bottom: 4px; }
.rs-nav:hover { transform: scale(1.08); }
.rs-nav:disabled { opacity: 0; pointer-events: none; }
.rs-nav.prev { left: -24px; }
.rs-nav.next { right: -24px; }
.rs-foot { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-top: 4px; }
.rs-dots { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
.rs-dots button { width: 8px; height: 8px; border-radius: 99px; border: 0; padding: 0; background: var(--line); transition: width .3s, background .3s; }
.rs-dots button[aria-selected="true"] { width: 26px; background: var(--gold); }
.rs-timer { width: 120px; height: 3px; background: var(--line); border-radius: 99px; overflow: hidden; }
.rs-timer span { display: block; height: 100%; width: 0; background: var(--navy); }
@keyframes rsTimer { from { width: 0; } to { width: 100%; } }
@media (max-width: 1080px) { .rs-card { flex-basis: calc((100% - 40px) / 3); } .rs-nav.prev { left: -8px; } .rs-nav.next { right: -8px; } }
@media (max-width: 760px) { .rs-card { flex-basis: 72%; } .rs-nav { display: none; } .rs-track { gap: 14px; } }

/* ================= 원료 플립 카드 ================= */
.ing-sec { background: radial-gradient(800px 400px at 15% 0%, rgba(217,184,115,.16), transparent 60%), linear-gradient(170deg, #0C1838, var(--navy) 60%, #13284F); color: #fff; overflow: hidden; }
.ing-sec .lead { color: rgba(255,255,255,.75); }
.fc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; perspective: 1400px; }
.fc { position: relative; height: 380px; cursor: pointer; outline: none; --rx: 0deg; --ry: 0deg;
  opacity: 0; transform: translateY(40px) rotateY(-25deg); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.8,.2,1); transition-delay: var(--d); }
.fc-grid.shown .fc { opacity: 1; transform: none; }
.fc-inner { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform .75s cubic-bezier(.3,1.3,.5,1);
  transform: rotateX(var(--rx)) rotateY(var(--ry)); }
.fc.flipped .fc-inner { transform: rotateY(180deg); }
.fc:focus-visible .fc-inner { outline: 3px solid var(--gold-2); outline-offset: 4px; border-radius: 22px; }
.fc-face { position: absolute; inset: 0; border-radius: 22px; backface-visibility: hidden; -webkit-backface-visibility: hidden; padding: 26px; display: flex; flex-direction: column; overflow: hidden; }
.fc-front { background: #fff; color: var(--ink); align-items: center; text-align: center; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
.fc-front::before { content: ""; position: absolute; width: 260px; height: 260px; border-radius: 50%; top: -120px; left: 50%; transform: translateX(-50%); background: var(--tone); opacity: .1; }
.fc-head { width: 100%; display: flex; justify-content: space-between; align-items: center; position: relative; }
.fc-no { font-family: var(--serif); color: var(--gold); font-size: 15px; font-weight: 700; }
.fc-prod { font-size: 12px; font-weight: 800; padding: 4px 10px; border-radius: 999px; color: #fff; }
.navy .fc-prod { background: var(--navy); }
.forest .fc-prod { background: var(--forest); }
.fc-orb { position: relative; width: 112px; height: 112px; margin: 18px 0 18px; border-radius: 50%; display: grid; place-items: center;
  background: radial-gradient(circle at 35% 30%, #fff, color-mix(in srgb, var(--tone) 18%, #fff)); box-shadow: 0 14px 30px color-mix(in srgb, var(--tone) 30%, transparent), inset 0 -6px 14px color-mix(in srgb, var(--tone) 15%, transparent); }
.fc-orb::after { content: ""; position: absolute; inset: -8px; border-radius: 50%; border: 1.5px dashed color-mix(in srgb, var(--tone) 45%, transparent); animation: spin 18s linear infinite; }
.fc-orb span { font-size: 52px; animation: floaty 3.2s ease-in-out infinite; animation-delay: var(--d); }
.fc h3 { font-size: 22px; font-weight: 800; }
.fc-front small { color: var(--ink-3); font-size: 13px; margin-top: 2px; }
.fc-front p { color: var(--ink-2); font-size: 15px; margin-top: 12px; }
.fc-hint { margin-top: auto; font-size: 13px; font-weight: 700; color: var(--gold); display: inline-flex; gap: 6px; align-items: center; }
.fc-hint b { display: inline-block; animation: spin 2.6s ease-in-out infinite; }
.fc-back { transform: rotateY(180deg); color: #fff; background: linear-gradient(160deg, color-mix(in srgb, var(--tone) 55%, var(--navy)), var(--navy)); box-shadow: 0 20px 50px rgba(0,0,0,.3); }
.forest .fc-back { background: linear-gradient(160deg, color-mix(in srgb, var(--tone) 50%, var(--forest)), var(--forest)); }
.fc-back .fc-no { color: var(--gold-2); font-family: var(--sans); font-size: 13px; }
.fc-back h3 { margin: 8px 0 12px; }
.fc-back p { font-size: 15px; line-height: 1.7; color: rgba(255,255,255,.88); }
.fc-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 16px; }
.fc-tags span { font-size: 12.5px; padding: 4px 10px; border-radius: 999px; background: rgba(255,255,255,.14); }
.fc-link { margin-top: auto; align-self: flex-start; font-weight: 800; font-size: 14px; color: var(--navy); background: #fff; padding: 10px 16px; border-radius: 999px; }
.fc-link:hover { background: var(--gold-2); }
@keyframes floaty { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-8px) rotate(4deg); } }
@keyframes spin { to { transform: rotate(360deg); } }
/* 가로로 넘기는 카드 줄 — 메인(6장)은 PC에서도, 상세(3장)는 모바일에서만 */
.fc-grid::-webkit-scrollbar { display: none; }
#ingredients:not([data-only]).fc-grid { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: calc((100% - 44px) / 3.25);
  overflow-x: auto; scroll-snap-type: x proximity; scroll-padding: 0 20px; scrollbar-width: none; margin: 0 -20px; padding: 16px 20px 34px; }
#ingredients:not([data-only]) .fc { scroll-snap-align: start; }
#ingredients:not([data-only]) + .swipe-hint { display: block; }
@media (max-width: 960px) {
  .fc-grid, #ingredients:not([data-only]).fc-grid { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 74%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    margin: 0 -20px; padding: 16px 20px 30px; }
  .fc, #ingredients:not([data-only]) .fc { scroll-snap-align: center; height: 370px; }
}
/* 상품 상세(밝은 배경)용 */
.bg-cream .fc-front { box-shadow: var(--shadow-lg); }
.bg-cream .fc-face { border: 1px solid var(--line); }
.swipe-hint { display: none; text-align: center; font-size: 13px; color: inherit; opacity: .7; margin-top: 2px; }
@media (max-width: 960px) { .swipe-hint { display: block; } }
@media (prefers-reduced-motion: reduce) {
  .rs-card, .fc { opacity: 1 !important; transform: none !important; transition: none; }
  .fc-orb::after, .fc-orb span, .fc-hint b { animation: none; }
}

/* 마우스 드래그 */
@media (hover: hover) and (pointer: fine) {
  .draggable { cursor: grab; }
  .draggable.dragging, .draggable.dragging * { cursor: grabbing !important; user-select: none; }
  .rs-view.dragging .rs-card, .fc-grid.dragging .fc { pointer-events: none; }
}
.draggable img { -webkit-user-drag: none; user-select: none; }
.ws-stage.dragging img { transition: opacity .8s ease !important; }

/* 움직이는 후기 표시 */
.rs-live { position: absolute; top: 12px; left: 12px; display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 800; color: #fff;
  background: rgba(0,0,0,.45); padding: 4px 10px 4px 8px; border-radius: 999px; backdrop-filter: blur(4px); opacity: 0; transition: opacity .4s; }
.rs-live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #FF4D4F; animation: livePulse 1.4s ease-in-out infinite; }
.rs-card.playing .rs-live { opacity: 1; }
@keyframes livePulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.75); } }
