/* Restart Creative — Reels feed
   Self-contained styles. Brand: green #3ab54b, charcoal #4a4849. */

:root {
  --rc-green: #3ab54b;
  --rc-char: #2e2c2d;
  --rc-char-2: #3a3839;
  --rc-paper: #f5f4f2;
  --rc-muted: #b9b6b4;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  background: #1c1b1b;
  color: var(--rc-paper);
  font-family: "Public Sans", system-ui, sans-serif;
  overscroll-behavior-y: contain;
}

.rl-display { font-family: "Yanone Kaffeesatz", sans-serif; }

/* ---------- top bar ---------- */
.rl-topbar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  padding: 0 16px;
  background: linear-gradient(to bottom, rgba(28,27,27,0.85), rgba(28,27,27,0));
  pointer-events: none;
}
.rl-topbar a, .rl-topbar button { pointer-events: auto; }
.rl-logo img { height: 32px; width: auto; display: block; }
.rl-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--rc-paper);
  text-decoration: none;
  font-size: 14px;
  padding: 8px 14px;
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 999px;
  background: rgba(28,27,27,0.45);
  backdrop-filter: blur(6px);
  transition: border-color 0.2s, color 0.2s;
}
.rl-back:hover { border-color: var(--rc-green); color: var(--rc-green); }

/* ---------- feed ---------- */
.rl-feed {
  height: 100dvh;
  overflow-y: scroll;
  scroll-snap-type: y mandatory;
  scrollbar-width: none;
}
.rl-feed::-webkit-scrollbar { display: none; }

.rl-slide {
  position: relative;
  height: 100dvh;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* the 9:16 stage — full-bleed on mobile, phone frame on desktop */
.rl-stage {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #000;
}
.rl-stage video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (min-width: 768px) {
  .rl-stage {
    height: min(92dvh, 900px);
    aspect-ratio: 9 / 16;
    width: auto;
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,0.14);
    box-shadow: 0 24px 80px rgba(0,0,0,0.6);
  }
}

/* ---------- per-slide overlay ---------- */
.rl-meta {
  position: absolute;
  left: 16px;
  right: 72px;
  bottom: 20px;
  z-index: 5;
  text-shadow: 0 1px 8px rgba(0,0,0,0.7);
}
.rl-meta .rl-client {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--rc-green);
  margin-bottom: 6px;
}
.rl-meta h2 {
  font-family: "Yanone Kaffeesatz", sans-serif;
  font-weight: 600;
  font-size: 26px;
  line-height: 1.05;
}

.rl-sound {
  position: absolute;
  right: 14px;
  bottom: 20px;
  z-index: 6;
  width: 46px;
  height: 46px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.3);
  background: rgba(28,27,27,0.55);
  backdrop-filter: blur(6px);
  color: var(--rc-paper);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s, transform 0.15s;
}
.rl-sound:hover { border-color: var(--rc-green); transform: scale(1.06); }

/* progress bar */
.rl-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  z-index: 6;
  background: rgba(255,255,255,0.18);
}
.rl-progress span {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--rc-green);
}

/* paused indicator */
.rl-pauseflag {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: none;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}
.rl-slide.is-paused .rl-pauseflag { display: flex; }
.rl-pauseflag span {
  width: 74px;
  height: 74px;
  border-radius: 999px;
  background: rgba(28,27,27,0.55);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
  color: var(--rc-paper);
}

/* tap-for-sound hint on the first slide */
.rl-hint {
  position: absolute;
  top: 72px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  font-size: 13px;
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(28,27,27,0.65);
  border: 1px solid rgba(255,255,255,0.2);
  backdrop-filter: blur(6px);
  white-space: nowrap;
  animation: rl-hint-fade 5s forwards;
  pointer-events: none;
}
@keyframes rl-hint-fade {
  0%, 75% { opacity: 1; }
  100% { opacity: 0; visibility: hidden; }
}

/* ---------- desktop arrows ---------- */
.rl-arrows {
  position: fixed;
  right: 26px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 40;
  display: none;
  flex-direction: column;
  gap: 12px;
}
@media (min-width: 768px) { .rl-arrows { display: flex; } }
.rl-arrows button {
  width: 48px;
  height: 48px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(58,56,57,0.6);
  color: var(--rc-paper);
  font-size: 18px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, transform 0.15s;
}
.rl-arrows button:hover {
  border-color: var(--rc-green);
  color: var(--rc-green);
  transform: scale(1.08);
}

/* slide counter */
.rl-counter {
  position: fixed;
  left: 26px;
  bottom: 26px;
  z-index: 40;
  display: none;
  font-size: 13px;
  letter-spacing: 0.12em;
  color: var(--rc-muted);
}
@media (min-width: 768px) { .rl-counter { display: block; } }
.rl-counter b { color: var(--rc-green); font-weight: 600; }

/* end card */
.rl-endcard {
  text-align: center;
  padding: 0 24px;
  max-width: 520px;
}
.rl-endcard h2 {
  font-family: "Yanone Kaffeesatz", sans-serif;
  font-weight: 700;
  font-size: clamp(38px, 6vw, 60px);
  line-height: 1;
}
.rl-endcard p { margin-top: 14px; color: var(--rc-muted); line-height: 1.6; }
.rl-endcard .rl-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 28px;
  padding: 14px 26px;
  background: var(--rc-green);
  color: #10240f;
  font-weight: 600;
  text-decoration: none;
  border-radius: 6px;
  font-size: 16px;
  transition: transform 0.15s, box-shadow 0.2s;
}
.rl-endcard .rl-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(58,181,75,0.35);
}

@media (prefers-reduced-motion: reduce) {
  .rl-hint { animation: none; }
  * { transition: none !important; }
}
