/* CineFlix public site - "Noir Neon" theme.
   Pure black stage, condensed display type, a serif whisper, and light that follows the poster on screen. */
:root {
  --ink: #050507;
  --surface: #0d0e13;
  --surface-2: #15161d;
  --line: rgba(255, 255, 255, 0.08);
  --accent: #ff2d55;
  --accent-2: #ffb020;
  --glow: 255, 45, 85; /* r,g,b - the hero and player re-tint this from the poster */
  --plyr-color-main: #ff2d55;
}
html { color-scheme: dark; scroll-behavior: smooth; }
body { background: var(--ink); color: #b8bcc8; font-family: Inter, system-ui, sans-serif; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
::selection { background: rgba(var(--glow), 0.4); color: #fff; }

/* film grain over everything */
body::after {
  content: ''; position: fixed; inset: 0; z-index: 90; pointer-events: none; opacity: 0.07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .9 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* scrollbars */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.14); border-radius: 8px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-track { background: transparent; }
.hide-scrollbar { scrollbar-width: none; }
.hide-scrollbar::-webkit-scrollbar { display: none; }

/* type */
.font-display { font-family: 'Bricolage Grotesque', Inter, system-ui, sans-serif; font-weight: 800; letter-spacing: -0.035em; font-variation-settings: 'opsz' 96; }
.font-serif-italic { font-family: 'Instrument Serif', Georgia, serif; font-style: italic; font-weight: 400; }
.outline-text { color: transparent; -webkit-text-stroke: 1.5px rgba(255, 255, 255, 0.28); }
.gradient-text { background: linear-gradient(95deg, #fff 0%, #ffd2d9 40%, var(--accent) 100%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.shimmer-text { background: linear-gradient(100deg, #fff 30%, rgba(var(--glow), 1) 50%, #fff 70%); background-size: 250% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; animation: shimmer-x 6s linear infinite; }
@keyframes shimmer-x { from { background-position: 150% 0; } to { background-position: -100% 0; } }
.eyebrow { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent-2); }

/* surfaces */
.glass { background: rgba(8, 8, 12, 0.62); -webkit-backdrop-filter: blur(18px) saturate(1.5); backdrop-filter: blur(18px) saturate(1.5); border: 1px solid rgba(255, 255, 255, 0.09); }
.glass-card { background: rgba(255, 255, 255, 0.045); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border: 1px solid rgba(255, 255, 255, 0.1); }
.card-dark { background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.015)); border: 1px solid var(--line); border-radius: 1.5rem; }

/* call to action: pill with a white arrow dot, like the reference */
.cta { position: relative; isolation: isolate; display: inline-flex; align-items: center; gap: 0.9rem; padding: 1.05rem 1.9rem; background: var(--accent); color: #fff; font-family: 'Bricolage Grotesque', Inter, sans-serif; letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.95rem; line-height: 1; white-space: nowrap; overflow: hidden; clip-path: polygon(0 0, calc(100% - 16px) 0, 100% 16px, 100% 100%, 16px 100%, 0 calc(100% - 16px)); transition: background 0.3s, color 0.3s, transform 0.2s; }
.cta::before { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, 0.55) 50%, transparent 65%); transform: translateX(-120%); }
.cta:hover { background: #fff; color: #050507; }
.cta:hover::before { transform: translateX(120%); transition: transform 0.7s ease; }
.cta:active { transform: scale(0.97); }
.cta-dot { display: inline-grid; place-items: center; color: inherit; transition: transform 0.3s; }
.cta-dot svg { width: 1.15rem; height: 1.15rem; }
.cta:hover .cta-dot { transform: translateX(6px); }
.cta-ghost { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem; padding: 0.6rem 0.2rem; color: #fff; font-family: 'Bricolage Grotesque', Inter, sans-serif; letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.95rem; line-height: 1; white-space: nowrap; transition: color 0.25s; }
.cta-ghost::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: linear-gradient(90deg, var(--accent) 35%, rgba(255, 255, 255, 0.35) 35%); background-size: 300% 100%; background-position: 100% 0; transition: background-position 0.5s ease; }
.cta-ghost:hover { color: var(--accent-2); }
.cta-ghost:hover::after { background-position: 0 0; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; border-radius: 9999px; padding: 0.75rem 1.4rem; font-weight: 600; font-size: 0.9rem; transition: transform 0.2s, background 0.2s, border-color 0.2s; white-space: nowrap; }
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { filter: brightness(1.12); }
.btn-ghost { background: rgba(255, 255, 255, 0.07); color: #fff; border: 1px solid rgba(255, 255, 255, 0.14); }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.14); }

/* chips */
.chip { display: inline-flex; align-items: center; gap: 0.4rem; border-radius: 9999px; padding: 0.4rem 1rem; font-size: 0.8rem; font-weight: 500; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); color: #d4d7e0; transition: all 0.2s; white-space: nowrap; }
a.chip:hover, button.chip:hover { background: rgba(var(--glow), 0.15); border-color: rgba(var(--glow), 0.55); color: #fff; }
.chip.is-on { background: var(--accent); border-color: var(--accent); color: #fff; }

/* form controls */
.field { width: 100%; border-radius: 0.9rem; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); padding: 0.75rem 1rem; color: #f1f5f9; font-size: 0.9rem; transition: border-color 0.2s, box-shadow 0.2s, background 0.2s; }
.field::placeholder { color: #6b7080; }
.field:focus { outline: none; border-color: rgba(var(--glow), 0.7); box-shadow: 0 0 0 4px rgba(var(--glow), 0.15); background: rgba(255, 255, 255, 0.08); }
select.field { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%239aa0b0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 0.8rem center; padding-right: 2.3rem; }
select.field option { background: #0d0e13; color: #f1f5f9; }

/* skeletons */
.skeleton { background: linear-gradient(90deg, #0d0e13 25%, #1b1c26 37%, #0d0e13 63%); background-size: 400% 100%; animation: shimmer 1.4s ease infinite; }
@keyframes shimmer { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }

/* reveal on scroll */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.8s cubic-bezier(0.2, 0.7, 0.2, 1), transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1); transition-delay: var(--d, 0ms); }
.js .reveal.in { opacity: 1; transform: none; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.fade-up { animation: fadeUp 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.fade-up.d1 { animation-delay: 0.1s; } .fade-up.d2 { animation-delay: 0.2s; } .fade-up.d3 { animation-delay: 0.3s; } .fade-up.d4 { animation-delay: 0.42s; }
@keyframes pulseDot { 0%, 100% { box-shadow: 0 0 0 0 rgba(var(--glow), 0.6); } 50% { box-shadow: 0 0 0 8px rgba(var(--glow), 0); } }
.pulse-dot { animation: pulseDot 2s ease-in-out infinite; }

/* scroll progress bar */
#scroll-progress { position: fixed; top: 0; left: 0; height: 3px; width: 100%; transform-origin: left; transform: scaleX(0); z-index: 95; background: linear-gradient(90deg, var(--accent), var(--accent-2)); box-shadow: 0 0 12px rgba(var(--glow), 0.8); }

/* floating header */
#site-header { transition: transform 0.4s cubic-bezier(0.2, 0.7, 0.2, 1); }
#site-header.is-hidden { transform: translateY(-140%); }

/* cursor spotlight (hero) */
.spotlight { position: absolute; inset: 0; pointer-events: none; background: radial-gradient(520px circle at var(--mx, 50%) var(--my, 35%), rgba(var(--glow), 0.16), transparent 62%); transition: background 0.2s; }

/* ambient floor glow under the carousel */
.ambient { position: absolute; left: 50%; width: min(1100px, 130%); height: 340px; transform: translateX(-50%); background: radial-gradient(50% 50% at 50% 50%, rgba(var(--glow), 0.55), rgba(var(--glow), 0.12) 55%, transparent 75%); filter: blur(34px); opacity: 0.9; transition: background 1.2s ease; pointer-events: none; }
.orb { position: absolute; border-radius: 9999px; filter: blur(80px); opacity: 0.35; pointer-events: none; animation: drift 18s ease-in-out infinite alternate; }
@keyframes drift { from { transform: translate3d(0, 0, 0) scale(1); } to { transform: translate3d(40px, -30px, 0) scale(1.15); } }

/* hero: tilted rivers of posters */
.hero-collage { position: absolute; inset: -20% -6% -20% 44%; z-index: -5; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; transform: rotate(-9deg); pointer-events: none; -webkit-mask-image: linear-gradient(90deg, transparent, #000 22%); mask-image: linear-gradient(90deg, transparent, #000 22%); opacity: 0.95; }
.river { overflow: hidden; }
.river-track { display: flex; flex-direction: column; gap: 1rem; animation: river var(--speed, 50s) linear infinite; }
.river.reverse .river-track { animation-direction: reverse; }
.river a { display: block; flex-shrink: 0; }
.river img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 1.1rem; box-shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(255, 255, 255, 0.08); }
@keyframes river { to { transform: translateY(-50%); } }
@media (max-width: 1023px) { .hero-collage { inset: -10% -30% -10% -10%; opacity: 0.22; -webkit-mask-image: none; mask-image: none; } }
@media (prefers-reduced-motion: reduce) { .river-track { animation: none; } }

/* poster cards with tilt + glare */
.poster-card { display: block; perspective: 900px; }
.poster-card .poster-frame { position: relative; transform-style: preserve-3d; transition: transform 0.25s ease-out, box-shadow 0.35s ease; will-change: transform; }
.poster-card:hover .poster-frame { box-shadow: 0 26px 50px -18px rgba(var(--glow), 0.55), 0 0 0 1px rgba(255, 255, 255, 0.22); }
.poster-card img { transition: transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1); }
.poster-card:hover img { transform: scale(1.08); }
.poster-glare { position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.3s; background: radial-gradient(240px circle at var(--gx, 50%) var(--gy, 0%), rgba(255, 255, 255, 0.28), transparent 60%); mix-blend-mode: overlay; }
.poster-card:hover .poster-glare { opacity: 1; }
.play-fab { transition: opacity 0.3s ease, transform 0.3s ease; }

/* Top 10 numerals */
.rank-card { position: relative; display: flex; align-items: flex-end; flex-shrink: 0; width: 15.5rem; }
.rank-num { font-family: 'Bricolage Grotesque', Inter, sans-serif; font-size: 11rem; line-height: 0.78; color: #050507; -webkit-text-stroke: 3px rgba(255, 255, 255, 0.5); margin-right: -1.6rem; position: relative; z-index: 1; letter-spacing: -0.04em; transition: -webkit-text-stroke-color 0.3s; }
.rank-card:hover .rank-num { -webkit-text-stroke-color: var(--accent); }

/* rail scroll buttons */
.rail-arrow { position: absolute; top: 40%; z-index: 10; display: none; width: 2.9rem; height: 2.9rem; align-items: center; justify-content: center; border-radius: 9999px; border: 1px solid rgba(255, 255, 255, 0.16); background: rgba(8, 8, 12, 0.85); color: #fff; font-size: 1.4rem; backdrop-filter: blur(10px); transition: background 0.2s, opacity 0.2s; }
.rail-arrow:hover { background: var(--accent); }
@media (min-width: 768px) { .rail-arrow { display: flex; } }

/* marquee */
.marquee { display: flex; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.marquee-track { display: flex; flex-shrink: 0; min-width: 100%; align-items: center; gap: 1.5rem; padding-right: 1.5rem; animation: marquee 38s linear infinite; }
.marquee.reverse .marquee-track { animation-direction: reverse; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-100%); } }
@media (prefers-reduced-motion: reduce) { .marquee-track { animation: none; } }

/* vertical poster columns (app promo) */
.v-marquee { overflow: hidden; -webkit-mask-image: linear-gradient(180deg, transparent, #000 15%, #000 85%, transparent); mask-image: linear-gradient(180deg, transparent, #000 15%, #000 85%, transparent); }
.v-track { display: flex; flex-direction: column; gap: 1rem; animation: vmarquee 30s linear infinite; }
.v-marquee.reverse .v-track { animation-direction: reverse; animation-duration: 36s; }
@keyframes vmarquee { to { transform: translateY(-50%); } }

/* rating ring */
.rating-ring { --p: 70; --c: #ffb020; display: grid; place-items: center; width: 3.4rem; height: 3.4rem; border-radius: 9999px; background: radial-gradient(closest-side, #050507 77%, transparent 79% 100%), conic-gradient(from 0deg, var(--c) calc(var(--p) * 1%), rgba(255, 255, 255, 0.12) 0); font-weight: 800; font-size: 0.95rem; color: #fff; }

/* theatre player frame: the room lights come from the poster */
.theatre { position: relative; border-radius: 1.5rem; padding: 3px; background: linear-gradient(135deg, rgba(var(--glow), 0.9), rgba(255, 255, 255, 0.08) 40%, rgba(var(--glow), 0.5)); box-shadow: 0 0 140px -20px rgba(var(--glow), 0.55); }
.theatre > .theatre-inner { overflow: hidden; border-radius: calc(1.5rem - 3px); background: #000; }

/* legal pages */
.prose-cine h2 { color: #fff; font-family: 'Bricolage Grotesque', Inter, sans-serif; text-transform: uppercase; letter-spacing: 0.02em; font-size: 1.5rem; margin: 2.5rem 0 0.75rem; font-weight: 400; }
.prose-cine h2::before { content: ''; display: inline-block; width: 28px; height: 4px; border-radius: 4px; background: var(--accent); margin-right: 0.8rem; vertical-align: middle; }
.prose-cine p { color: #9aa0b0; line-height: 1.85; margin-bottom: 1rem; }
.prose-cine a { color: var(--accent-2); text-decoration: underline; text-underline-offset: 3px; }

/* video player */
.plyr { border-radius: 1.2rem; --plyr-control-radius: 8px; }
.plyr ::cue { font-size: 1.5rem !important; }
.plyr--video .plyr__control--overlaid { background: rgba(var(--glow), 0.95); }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .fade-up, .pulse-dot, .shimmer-text, .orb { animation: none !important; }
  html { scroll-behavior: auto; }
}
