@import url("https://fonts.googleapis.com/css2?family=Onest:wght@300;400;500;600;700&display=swap");

/* ─── Design tokens ─────────────────────────────────────────── */
:root {
  --c-bg-page: #110c15;
  --c-bg-chat: #271a2b;
  --c-bg-surface: rgba(39, 26, 43, 0.85);
  --c-bubble-model: rgba(255, 255, 255, 0.1);
  --c-bubble-user: #4f46e5; /* bg-indigo-600, same as ChatMessage.tsx */
  --c-border: #463046;
  --c-border-sub: rgba(70, 48, 70, 0.5);
  --c-text: #ffffff;
  --c-text-muted: #9b9caa;
  --c-text-dim: rgba(255, 255, 255, 0.4);
  --c-primary: #8049f3;
  --c-secondary: #fc6896;
  --c-green: #0fe980;
  --c-dark: #322636;

  --grad-primary: linear-gradient(
    149deg,
    #de8424 0%,
    #fc658f 31%,
    #8049f3 100%
  );
  --grad-avatar: linear-gradient(135deg, #8049f3 0%, #fc6896 100%);

  --shadow-violet: 0px 10px 32px 0px rgba(104, 26, 199, 0.61);
  --shadow-pink: 0px 10px 32px 0px rgba(174, 22, 183, 0.49);
  --shadow-rose:
    0px 4px 5px 0px rgba(254, 101, 140, 0.5),
    0px 2px 8px 0px rgba(254, 101, 140, 0.07);

  /* Exact from tailwind.config.ts */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px; /* rounded-2xl in Tailwind default = 1rem = 16px */
  --r-full: 9999px;

  --blur-glass: 22px;
  --blur-bubble: 16px; /* backdrop-blur-lg */
}

/* ─── Reset ─────────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ─── Keyframes ─────────────────────────────────────────────── */

/* Typing dots — exact from tailwind.config.ts */
@keyframes typingDot {
  0%,
  60%,
  100% {
    transform: translateY(0);
    opacity: 0.6;
  }
  30% {
    transform: translateY(-8px);
    opacity: 1;
  }
}

/* fadeIn — exact from tailwind.config.ts */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Chat pattern wave — exact from globals.css */
@keyframes chat-wave-sweep {
  0% {
    background-position: 0 -10%;
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  100% {
    background-position: 0 150%;
    opacity: 1;
  }
}

/* Lock pulse */
@keyframes lockPulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(128, 73, 243, 0);
  }
  50% {
    box-shadow: 0 0 24px 4px rgba(128, 73, 243, 0.35);
  }
}

/* Hint re-entry */
@keyframes hintIn {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Page blobs */
@keyframes atmGlow {
  0%,
  100% {
    opacity: 0.7;
  }
  50% {
    opacity: 1;
  }
}

/* Sparkle stars (media generating) */
@keyframes sparklePop {
  0% {
    opacity: 0;
    transform: scale(0) rotate(0deg);
  }
  40% {
    opacity: 1;
    transform: scale(1.1) rotate(60deg);
  }
  70% {
    opacity: 1;
    transform: scale(0.9) rotate(120deg);
  }
  100% {
    opacity: 0;
    transform: scale(0) rotate(180deg);
  }
}

/* Word appear in streaming text */
@keyframes wordIn {
  from {
    opacity: 0;
    filter: blur(6px);
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    filter: blur(0px);
    transform: translateY(0);
  }
}

/* Media generating border glow */
@keyframes genBorderGlow {
  0%,
  100% {
    border-color: rgba(167, 139, 250, 0.35);
    box-shadow: 0 0 0 0 rgba(167, 139, 250, 0);
  }
  50% {
    border-color: rgba(244, 114, 182, 0.65);
    box-shadow: 0 0 16px 4px rgba(167, 139, 250, 0.2);
  }
}

/* Pulse for gen overlay + cursor */
@keyframes genPulse {
  0%,
  100% {
    opacity: 0.45;
  }
  50% {
    opacity: 0.65;
  }
}

/* ─── Page ───────────────────────────────────────────────────── */
html,
body {
  height: 100%;
}

body {
  font-family: "Onest", sans-serif;
  background: var(--c-bg-page);
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  user-select: none;
}

/* Desktop background video — hidden on mobile, full-cover behind chat */
.bg-video {
  display: none;
}

@media (min-width: 640px) {
  .bg-video {
    display: block;
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    opacity: 0.55;
  }
}

/* Page atmospheric blobs */
.page-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.page-bg::before {
  content: "";
  position: absolute;
  width: 700px;
  height: 700px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(128, 73, 243, 0.12) 0%,
    transparent 65%
  );
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  animation: atmGlow 6s ease-in-out infinite;
}

.page-bg::after {
  content: "";
  position: absolute;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(252, 104, 150, 0.08) 0%,
    transparent 65%
  );
  bottom: -100px;
  left: 50%;
  transform: translateX(-50%);
  animation: atmGlow 8s ease-in-out infinite reverse;
}

/* ─── Phone wrapper ──────────────────────────────────────────── */
#app-wrapper {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 100%; /* mobile: full width */
}

@media (min-width: 640px) {
  #app-wrapper {
    max-width: 390px;
  }
}

/* ─── App container ──────────────────────────────────────────── */
#app {
  background: var(--c-bg-chat);
  height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative; /* anchor for absolute prog-blur-bottom */
}

/* ─── Desktop: fixed-size phone mockup — never grows ────────── */
@media (min-width: 640px) {
  body {
    padding: 32px 16px;
  }

  #app-wrapper {
    filter: drop-shadow(0 0 0 1px rgba(70, 48, 70, 0.9))
      drop-shadow(0 60px 120px rgba(0, 0, 0, 0.95))
      drop-shadow(0 20px 60px rgba(0, 0, 0, 0.85))
      drop-shadow(0 6px 20px rgba(0, 0, 0, 0.7));
  }

  /* Top glow — electric-violet */
  #app-wrapper::before {
    content: "";
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    width: 120%;
    height: 180px;
    background: radial-gradient(
      ellipse at center,
      rgba(128, 73, 243, 0.55) 0%,
      transparent 70%
    );
    pointer-events: none;
    z-index: -1;
    border-radius: 50%;
  }

  /* Bottom glow — brink-pink */
  #app-wrapper::after {
    content: "";
    position: absolute;
    bottom: -60px;
    left: 50%;
    transform: translateX(-50%);
    width: 120%;
    height: 180px;
    background: radial-gradient(
      ellipse at center,
      rgba(252, 104, 150, 0.45) 0%,
      transparent 70%
    );
    pointer-events: none;
    z-index: -1;
    border-radius: 50%;
  }

  #app {
    height: min(720px, calc(100dvh - 64px));
    border-radius: 24px;
    overflow: hidden;
    box-shadow:
      0 0 0 1px rgba(128, 73, 243, 0.5),
      0 0 60px 8px rgba(128, 73, 243, 0.35),
      0 0 80px 20px rgba(252, 104, 150, 0.18),
      0 32px 80px rgba(0, 0, 0, 0.9),
      0 8px 24px rgba(0, 0, 0, 0.7);
  }
}

/* ─── Topbar — absolute, transparent, floats on top prog-blur ── */
/* Mirrors ChatLayout.tsx: header is absolutely positioned, no bg */
.topbar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: env(safe-area-inset-top, 0px) 16px 0;
  padding-top: max(env(safe-area-inset-top, 0px), 12px);
  padding-bottom: 12px;
  background: transparent;
}

/* ─── Avatar ─────────────────────────────────────────────────── */
.avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--r-full);
  background: var(--grad-avatar);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  flex-shrink: 0;
  overflow: hidden;
  position: relative;
}

/* Video inside any avatar — fills circle, top-centered */
.avatar video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.avatar.sm {
  width: 28px;
  height: 28px;
  font-size: 11px;
}

.topbar-info {
  flex: 1;
}

.topbar-name {
  font-size: 13px;
  font-family: "Zalando Sans Expanded", sans-serif;
  font-weight: 800;
  color: var(--c-text);
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.topbar-status {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  color: var(--c-green);
  letter-spacing: -0.24px;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: var(--r-full);
  background: var(--c-green);
}

/* ─── Messages wrap — full height, clips content + blur layers ── */
/* Topbar is absolutely positioned inside here, same as ChatLayout.tsx */
.messages-wrap {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
}

/* ─── Chat pattern — exact from ChatView.tsx ────────────────── */
/* mask-image data URL applied via JS (window.PATTERN_DATA_URL)  */
.chat-pattern {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: linear-gradient(to bottom, #401d28, #201639);
  /* mask-image set by initChatPattern() in script.js */
  mask-repeat: repeat;
  mask-size: 265px 288px;
  -webkit-mask-repeat: repeat;
  -webkit-mask-size: 265px 288px;
}

/* ─── Wave layer — exact from ChatView.tsx + globals.css ─────── */
/* mask-image set by initChatPattern() in script.js              */
.chat-wave {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  display: none;
  background-image: linear-gradient(
    to top,
    transparent 28%,
    rgba(137, 55, 80, 0.5) 40%,
    rgba(137, 55, 80, 0.06) 68%,
    transparent 88%
  );
  background-size: 100% 300%;
  background-repeat: no-repeat;
  background-position: 0 -50%;
  /* mask applied by JS */
  mask-repeat: repeat;
  mask-size: 265px 288px;
  -webkit-mask-repeat: repeat;
  -webkit-mask-size: 265px 288px;
}

.chat-wave.active {
  display: block;
  animation: chat-wave-sweep 3s cubic-bezier(0.3, 0.2, 0.2, 0.9) forwards;
}

/* ─── Scrollable messages ────────────────────────────────────── */
.messages {
  position: relative;
  z-index: 5;
  height: 100%;
  /* bottom: clears actions area + bottom blur */
  padding: 0 14px 280px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
  scrollbar-width: none;
}

/* ─── Intro block — big centered avatar at chat start ────────── */
/* Scrolls up naturally when model starts typing (scrollBottom()) */
.intro-block {
  padding: 64px 0 24px;
  animation: fadeIn 0.6s ease-out;
  display: flex;
  justify-content: center;
}

.intro-avatar {
  width: 52%;
  aspect-ratio: 3 / 4;
  border-radius: var(--r-lg);
  background: var(--grad-avatar);
  overflow: hidden;
  position: relative;
}

.intro-avatar video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

/* hide name + status — removed from HTML below */
.intro-name,
.intro-status {
  display: none;
}

.messages::-webkit-scrollbar {
  display: none;
}

/* ─── Progressive blur — replicates ProgressiveBlur component ── */
.prog-blur {
  position: absolute;
  left: 0;
  right: 0;
  pointer-events: none;
}

.prog-blur > div {
  position: absolute;
  inset: 0;
}

/* Top blur — inside messages-wrap, topbar floats above it (z:25) */
.prog-blur-top {
  top: 0;
  height: 100px;
  z-index: 10;
}

/* Bottom blur — back inside messages-wrap, blurs actual message content */
.prog-blur-bottom {
  bottom: 0;
  height: 260px;
  z-index: 10;
}

/* ─── Message row ────────────────────────────────────────────── */
.msg-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  animation: fadeIn 0.3s ease-out;
}

.msg-row.user {
  flex-direction: row-reverse;
}

/* ─── Bubbles — from ChatMessage.tsx ────────────────────────── */
.bubble {
  max-width: 80%;
  padding: 10px 14px;
  font-size: 16px;
  line-height: 1.55;
  letter-spacing: -0.28px;
  color: var(--c-text);
}

/* bg-white/10 + backdrop-blur-lg + rounded-2xl + rounded-tl-sm */
.bubble.model {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--r-lg);
  border-top-left-radius: var(--r-sm);
}

/* bg-indigo-600 — exact from ChatMessage.tsx */
.bubble.user {
  background: #4f46e5;
  border-radius: var(--r-lg);
  border-top-right-radius: var(--r-sm);
}

/* ─── Typing indicator — from TypingIndicator.tsx ───────────── */
/* bg-white/10 + rounded-tl-sm + rounded-2xl + backdrop-blur-lg  */
.typing {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--r-lg);
  border-top-left-radius: var(--r-sm);
  padding: 16px 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 48px;
  animation: fadeIn 0.3s ease-out;
}

.typing span {
  width: 8px;
  height: 8px;
  border-radius: var(--r-full);
  background: rgba(255, 255, 255, 0.6);
  animation: typingDot 1.4s ease-in-out infinite;
}

.typing span:nth-child(2) {
  animation-delay: 150ms;
}
.typing span:nth-child(3) {
  animation-delay: 300ms;
}

/* ─── Media block (static placeholder) ──────────────────────── */
.media-block {
  width: 200px;
  aspect-ratio: 3 / 4;
  border-radius: var(--r-lg);
  overflow: hidden;
  position: relative;
  border: 1px solid var(--c-border-sub);
  background: var(--c-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.35s ease-out;
}

.media-block::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    160deg,
    rgba(128, 73, 243, 0.06) 0%,
    rgba(252, 104, 150, 0.06) 100%
  );
  pointer-events: none;
}

.media-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  position: relative;
  z-index: 1;
}

.media-icon {
  font-size: 32px;
}
.media-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--c-text-muted);
  letter-spacing: -0.24px;
}

/* Locked variant */
.media-block.locked {
  border-color: rgba(128, 73, 243, 0.3);
}

/* Inline video media block — same size as photo, no expand */
.media-block.media-video {
  cursor: default;
}

.media-block.media-video video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  pointer-events: none; /* no controls, no click-to-expand */
}

/* Video locked — actual video with bottom blur + lock overlay */
.media-block.video-locked {
  width: 200px;
}

.media-block.video-locked video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Bottom half progressive blur — sits over the video */
.media-blur-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 55%;
  pointer-events: none;
  z-index: 2;
}

.media-blur-bottom > div {
  position: absolute;
  inset: 0;
}

/* Lock icon + label — bottom center over the blur */
.media-lock-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding-bottom: 18px;
  gap: 8px;
}

.blur-overlay {
  position: absolute;
  inset: 0;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  background: rgba(17, 12, 21, 0.55);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  z-index: 2;
}

.lock-icon-wrap {
  width: 48px;
  height: 48px;
  border-radius: var(--r-full);
  background: rgba(128, 73, 243, 0.18);
  border: 1px solid rgba(128, 73, 243, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  animation: lockPulse 2.4s ease-in-out infinite;
}

.blur-label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
  text-align: center;
  padding: 0 16px;
  letter-spacing: -0.24px;
  line-height: 1.4;
}

/* ─── Media GENERATING placeholder ──────────────────────────── */
.media-block.generating {
  border: 1px solid rgba(167, 139, 250, 0.35);
  animation:
    fadeIn 0.35s ease-out,
    genBorderGlow 2.2s ease-in-out infinite;
}

.gen-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  animation: genPulse 2s ease-in-out infinite;
  z-index: 1;
}

.sparkle {
  position: absolute;
  z-index: 3;
  font-size: 14px;
  pointer-events: none;
  animation: sparklePop var(--dur, 2s) var(--delay, 0s) ease-in-out both;
}

.gen-text-wrap {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 4;
  padding: 0 14px 20px;
  mask-image: linear-gradient(to bottom, transparent 0%, white 38%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, white 38%);
}

.gen-text-inner {
  overflow: hidden;
  position: relative;
  height: calc(0.875rem * 1.6 * 3);
}

.gen-text-p {
  font-size: 13px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.6;
  text-align: left;
  transition: transform 0.35s ease;
}

.gen-word {
  display: inline;
  animation: wordIn 0.3s ease-out both;
}

.gen-cursor {
  display: inline-block;
  width: 1.5px;
  height: 0.8em;
  background: rgba(255, 255, 255, 0.55);
  margin-left: 2px;
  vertical-align: middle;
  animation: genPulse 0.8s ease-in-out infinite;
}

/* ─── Actions bar — absolute at bottom of messages-wrap, above bottom blur ── */
.actions {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 8px 14px max(env(safe-area-inset-bottom, 0px), 18px);
  background: transparent;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 20; /* above prog-blur-bottom (z:10) */
}

#action-area {
  display: flex;
  flex-direction: column;
  gap: 8px;
  animation: fadeInUp 0.25s ease-out;
}

/* ─── Buttons ────────────────────────────────────────────────── */
.btn-row {
  display: flex;
  gap: 8px;
}

.btn-choice,
.btn-react {
  flex: 1;
  padding: 13px 14px;
  border-radius: var(--r-full);
  border: 1px solid transparent;
  color: var(--c-text);
  font-size: 13px;
  font-family: "Zalando Sans Expanded", sans-serif;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  cursor: pointer;
  transition:
    background 0.2s,
    border-color 0.2s,
    transform 0.1s,
    box-shadow 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
}

/* Choice buttons — default (gradient fallback) */
.btn-choice {
  background: linear-gradient(
    135deg,
    rgba(128, 73, 243, 0.28) 0%,
    rgba(252, 104, 150, 0.22) 100%
  );
  border-color: rgba(128, 73, 243, 0.55);
}

/* Blue variant — solid indigo */
.btn-choice.btn-blue {
  background: #4f46e5;
  border-color: #6560f0;
  box-shadow:
    0 4px 20px rgba(79, 70, 229, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
}
.btn-choice.btn-blue:hover {
  background: #5b52f0;
  border-color: #7a76ff;
  box-shadow: 0 6px 28px rgba(79, 70, 229, 0.75);
}

/* Pink variant — solid brink-pink */
.btn-choice.btn-pink {
  background: #fc6896;
  border-color: #ff82aa;
  box-shadow:
    0 4px 20px rgba(252, 104, 150, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
}
.btn-choice.btn-pink:hover {
  background: #ff7aa5;
  border-color: #ffaac5;
  box-shadow: 0 6px 28px rgba(252, 104, 150, 0.75);
}

.btn-choice:hover {
  background: linear-gradient(
    135deg,
    rgba(128, 73, 243, 0.42) 0%,
    rgba(252, 104, 150, 0.32) 100%
  );
  border-color: rgba(128, 73, 243, 0.8);
}

/* React buttons (yes/no, thumbs) — more subtle */
.btn-react {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.16);
}

.btn-react:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.28);
}

.btn-choice:active,
.btn-react:active {
  transform: scale(0.97);
}

/* Icon-only reaction buttons (thumb up/down) */
.btn-react.icon-only {
  flex: 1;
  padding: 14px;
  min-height: 52px;
  font-size: 22px;
}

.btn-unlock {
  width: 100%;
  padding: 14px;
  border-radius: var(--r-full);
  border: none;
  background: var(--grad-primary);
  color: #fff;
  font-size: 15px;
  font-family: "Zalando Sans Expanded", sans-serif;
  font-weight: 800;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: var(--shadow-rose);
  transition:
    opacity 0.2s,
    transform 0.1s,
    box-shadow 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-unlock:hover {
  opacity: 0.92;
  box-shadow: var(--shadow-violet);
}
.btn-unlock:active {
  transform: scale(0.98);
}

/* ─── Slider ─────────────────────────────────────────────────── */
.slider-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.slider-label {
  font-size: 15px;
  font-family: "Zalando Sans Expanded", sans-serif;
  font-weight: 700;
  color: #ffffff;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.slider-emojis {
  display: flex;
  justify-content: space-between;
  padding: 0 4px;
}

.slider-emoji {
  font-size: 20px;
  opacity: 0.35;
  transform: scale(1);
  transition:
    transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
    opacity 0.3s ease;
}

.slider-emoji.active {
  opacity: 1;
  transform: scale(1.4);
}

/* Range input */
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 100px;
  background: var(--c-border); /* overridden by JS */
  cursor: pointer;
  outline: none;
  padding: 12px 0;
  background-clip: content-box;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 24px;
  height: 24px;
  border-radius: var(--r-full);
  background: var(--grad-primary);
  box-shadow: 0 2px 12px rgba(128, 73, 243, 0.55);
  border: 2px solid rgba(255, 255, 255, 0.3);
  transition:
    transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1),
    box-shadow 0.2s ease;
}

input[type="range"]::-webkit-slider-thumb:active {
  transform: scale(1.25);
  box-shadow: 0 4px 20px rgba(128, 73, 243, 0.8);
}

input[type="range"]::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border-radius: var(--r-full);
  background: var(--grad-primary);
  box-shadow: 0 2px 12px rgba(128, 73, 243, 0.55);
  border: 2px solid rgba(255, 255, 255, 0.3);
  cursor: pointer;
}

input[type="range"]::-moz-range-track {
  background: var(--c-border);
  height: 4px;
  border-radius: 2px;
}

input[type="range"]::-moz-range-progress {
  background: var(--c-primary);
  height: 4px;
  border-radius: 2px;
}

.slider-hint {
  font-size: 14px;
  color: var(--c-secondary);
  text-align: center;
  letter-spacing: -0.24px;
  min-height: 18px;
  animation: hintIn 0.25s ease-out;
}

/* ─── Final CTA ──────────────────────────────────────────────── */
.cta-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 4px 0;
}

.cta-title {
  font-size: 17px;
  font-weight: 500;
  color: var(--c-text);
  letter-spacing: -0.28px;
}
.cta-sub {
  font-size: 14px;
  color: var(--c-text-muted);
  letter-spacing: -0.24px;
  margin-bottom: 10px;
}
