/* Olloflix inspired skin for cinelya.me. Keep the existing catalog and controls. */
:root {
  --surface-900: #09090b;
  --surface-800: #111114;
  --surface-700: #1a1a1e;
  --primary: #f59e0b;
  --primary-rgb: 245 158 11;
  --primary-contrast: #09090b;
  --primary-readable: #fbbf24;
  --accent: #facc15;
  --accent-on-dark: #facc15;
  --accent-rgb: 250 204 21;
  --accent-dim: rgb(245 158 11 / .16);
  --muted: rgb(255 255 255 / .55);
  --text: #fafafa;
  --text-secondary: rgb(255 255 255 / .72);
  --card-bg: #111114;
  --field-bg: #111114;
  --header-bg: rgb(9 9 11 / .72);
  --border-rgb: 255 255 255;
  --border: rgb(255 255 255 / .12);
  --panel-shadow: 0 18px 60px rgb(0 0 0 / .55);
  --content: 1400px;
  color-scheme: dark;
}

html { background: #09090b; }
body { background: #09090b; color: #fafafa; font-family: "Space Grotesk", system-ui, sans-serif; }

/* Floating glass navigation */
.site-header {
  position: fixed;
  z-index: 40;
  top: 8px;
  right: 0;
  left: 0;
  height: 56px;
  border: 0;
  background: transparent;
  backdrop-filter: none;
  pointer-events: none;
}
.header-inner {
  width: min(740px, calc(100% - 32px));
  max-width: 740px;
  height: 56px;
  padding: 0 16px;
  gap: 20px;
  border: 1px solid rgb(255 255 255 / .12);
  border-radius: 999px;
  background: rgb(18 18 20 / .74);
  box-shadow: 0 10px 24px rgb(0 0 0 / .22);
  backdrop-filter: blur(20px) saturate(1.3);
  pointer-events: auto;
}
.header-brand { gap: 10px; }
.logo { gap: 8px; color: #fafafa; font: 700 18px/1 "Space Grotesk", system-ui, sans-serif; letter-spacing: -.7px; }
.logo i { color: #fafafa; font-size: 18px; }
.logo span { color: rgb(255 255 255 / .68); }
.header-inner nav { gap: 2px; }
.header-inner nav a { display: inline-flex; align-items: center; gap: 7px; padding: 8px 11px; border-radius: 10px; color: rgb(255 255 255 / .58); font-size: 13px; }
.header-inner nav a:hover,
.header-inner nav a:focus-visible { background: rgb(255 255 255 / .08); color: #fff; }
.header-icon {
  width: 38px;
  height: 38px;
  border: 1px solid transparent;
  border-radius: 50%;
  background: transparent;
  color: rgb(255 255 255 / .74);
  transition: color .15s ease, background .15s ease, border-color .15s ease;
}
.header-icon:hover,
.header-icon[aria-expanded="true"] { border-color: rgb(255 255 255 / .14); background: rgb(255 255 255 / .1); color: #fff; }
.header-icon[data-telegram-link],
.header-icon[data-telegram-link]:hover { border-color: transparent; background: transparent; box-shadow: none; }
.header-panel { top: 65px; border: 1px solid rgb(255 255 255 / .12); border-radius: 18px; background: rgb(14 14 16 / .96); box-shadow: 0 24px 70px rgb(0 0 0 / .62); backdrop-filter: blur(24px); }
.color-swatch[aria-pressed="true"] { outline-color: #fff; }

/* Cinematic full-bleed featured title */
.hero { min-height: 500px; height: min(76vh, 610px); background: #09090b; }
.hero-backdrop { background-position: center 32%; transform: scale(1.025); }
.hero::after {
  background:
    linear-gradient(90deg, rgb(0 0 0 / .84) 0%, rgb(0 0 0 / .48) 42%, transparent 82%),
    linear-gradient(180deg, rgb(0 0 0 / .38) 0%, transparent 38%, #09090b 100%);
}
.hero-content {
  max-width: 1400px;
  min-height: 100%;
  height: 100%;
  padding: 86px 40px 74px;
  justify-content: center;
}
.hero-copy { max-width: 620px; }
.trend-badge {
  gap: 9px;
  padding: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: rgb(255 255 255 / .55);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .16em;
}
.trend-badge i { color: #f59e0b; }
.hero-title {
  max-width: 720px;
  min-height: 0;
  margin-top: 12px;
  font: 700 clamp(42px, 5.6vw, 72px)/.98 "Space Grotesk", system-ui, sans-serif;
  letter-spacing: -.055em;
  text-transform: none;
  text-shadow: 0 2px 12px rgb(0 0 0 / .5);
}
.hero-meta { gap: 10px; margin-top: 16px; color: rgb(255 255 255 / .8); font-size: 13px; }
.hero-meta .fa-star, .hero-meta .rating-star { color: #facc15 !important; }
.hero-meta .hd { padding: 5px 10px; border: 1px solid rgb(255 255 255 / .15); border-radius: 999px; background: rgb(255 255 255 / .1); color: #fff; font-size: 10px; letter-spacing: .04em; }
.hero .hero-meta .hd { background: rgb(255 255 255 / .1); color: #fff; }
.hero-description { max-width: 570px; min-height: 0; margin-top: 16px; color: rgb(255 255 255 / .76); font-size: 14px; line-height: 1.6; }
.hero-actions { gap: 10px; margin-top: 20px; }
.btn { min-height: 44px; padding: 0 21px; border-radius: 999px; font-family: inherit; font-size: 13px; transition: transform .18s ease, background .18s ease, border-color .18s ease; }
.btn:hover { transform: scale(1.025); }
.btn-primary { background: #fff; color: #09090b; box-shadow: 0 10px 20px rgb(0 0 0 / .18); }
.btn-primary:hover { background: rgb(255 255 255 / .86); opacity: 1; }
.btn-ghost { border-color: rgb(255 255 255 / .2); background: rgb(255 255 255 / .13); color: #fff; backdrop-filter: blur(10px); }
.btn-ghost:hover { border-color: rgb(255 255 255 / .32); background: rgb(255 255 255 / .22); }
.hero-navigation { align-items: flex-end; justify-content: flex-start; gap: 9px; padding: 0 40px 140px; }
.hero-navigation[hidden] { display: none; }
.hero-arrow { width: 34px; height: 34px; border: 1px solid rgb(255 255 255 / .15); background: rgb(255 255 255 / .1); color: #fff; }
.hero-arrow:hover:not(:disabled) { border-color: rgb(255 255 255 / .35); background: rgb(255 255 255 / .2); }

/* Content rails and headings */
.platform-section { max-width: 1400px; padding: 24px 40px 8px; margin: 0 auto; }
.platform-heading { margin-bottom: 15px; color: rgb(255 255 255 / .5); font-size: 11px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.platform-grid { gap: 18px; }
.platform-card { padding: 5px 2px 8px; }
.platform-logo { width: 62px; height: 62px; border: 1px solid rgb(255 255 255 / .12); border-radius: 18px; box-shadow: 0 8px 22px rgb(0 0 0 / .35); }
.platform-name { color: rgb(255 255 255 / .64); font-size: 11px; }
.main-content { max-width: 1400px; padding: 28px 40px 72px; }
#popular-section { position: relative; z-index: 3; max-width: 1400px; padding: 0 40px 24px; margin: -48px auto 0; border-bottom: 1px solid rgb(255 255 255 / .08); }
.popular-section { padding-bottom: 28px; margin-bottom: 25px; }
.section-heading { margin-bottom: 17px; }
.section-title { gap: 0; font-size: 24px; font-weight: 700; letter-spacing: -.035em; }
.section-title i { display: none; }
.popular-label { color: rgb(255 255 255 / .48); font-size: 11px; }
.tabs { padding: 4px; gap: 2px; border: 1px solid rgb(255 255 255 / .13); border-radius: 999px; background: rgb(255 255 255 / .07); }
.tab-btn { padding: 8px 14px; border-radius: 999px; color: rgb(255 255 255 / .68); }
.tab-btn:hover { color: #fff; }
.tab-btn.active { background: #fff; color: #09090b; box-shadow: 0 2px 9px rgb(0 0 0 / .2); }
.popular-carousel { grid-template-columns: 34px minmax(0,1fr) 34px; gap: 10px; }
.popular-carousel .popular-grid { grid-auto-columns: minmax(210px, 1fr); grid-auto-columns: min(28vw, 320px); column-gap: 16px; padding: 5px 1px 14px; mask-image: linear-gradient(to right, #000 0%, #000 94%, transparent 100%); }
.popular-arrow { width: 34px; height: 34px; border-color: rgb(255 255 255 / .15); background: rgb(255 255 255 / .08); color: #fff; }
.popular-arrow:hover:not(:disabled) { border-color: rgb(255 255 255 / .35); background: rgb(255 255 255 / .2); }
.popular-grid .card-poster { aspect-ratio: 16 / 9; border: 1px solid rgb(255 255 255 / .1); border-radius: 14px; background: #171719; }
.popular-grid .film-card { overflow: visible; background: transparent; }
.popular-grid .film-card:hover { box-shadow: none; }
.popular-grid .card-info { padding: 8px 3px 2px; }
.popular-grid .card-year { display: none; }
.popular-grid .card-title { margin-top: 0; font-size: 13px; font-weight: 600; }
.popular-grid .card-meta { margin-top: 5px; font-size: 10px; }
.film-grid { gap: 22px 16px; }
.film-card { border-radius: 14px; background: transparent; }
.card-poster { border-radius: 14px; background: #171719; }
.card-title { font-size: 13px; font-weight: 600; }
.card-meta .rating { color: #facc15; }
.play-icon { background: rgb(255 255 255 / .2); color: #fff; backdrop-filter: blur(8px); }
.category-wrap select { min-height: 38px; border-color: rgb(255 255 255 / .14); border-radius: 999px; background: rgb(255 255 255 / .07); }
.catalog-status { color: rgb(255 255 255 / .5); }
.empty-state { border-color: rgb(255 255 255 / .16); }
.empty-state i { color: #f59e0b; }
footer { border-top: 1px solid rgb(255 255 255 / .1); background: rgb(0 0 0 / .4); }

@media (max-width: 900px) {
  .header-inner { display: flex; width: calc(100% - 24px); gap: 10px; }
  .header-inner nav { gap: 0; }
  .header-inner nav a { padding-inline: 8px; font-size: 12px; }
  .hero-content { padding-inline: 28px; }
  .hero-navigation { padding-inline: 28px; }
  .platform-section, .main-content, #popular-section { padding-right: 28px; padding-left: 28px; }
  .film-grid { grid-template-columns: repeat(5, minmax(0,1fr)); }
}

@media (max-width: 560px) {
  .site-header { top: auto; bottom: 12px; height: 58px; }
  .header-inner { display: flex; width: calc(100% - 24px); height: 58px; padding: 0 13px; gap: 9px; }
  .logo { font-size: 16px; }
  .logo i { font-size: 17px; }
  .header-inner nav { display: flex; }
  .logo b, .header-brand .appearance-wrap { display: none; }
  .header-brand { flex: 0 0 auto; }
  .header-inner nav { flex: 1 1 auto; justify-content: space-evenly; }
  .header-inner nav a { display: grid; width: 34px; height: 38px; place-items: center; padding: 0; font-size: 14px; }
  .header-inner nav a .nav-label, .saved-nav-count { display: none !important; }
  .header-inner nav a { padding: 0; font-size: 14px; }
  .header-icon { width: 34px; height: 34px; flex: 0 0 34px; }
  .header-search { margin-left: auto; }
  .header-panel { top: auto; bottom: 68px; right: -2px; width: min(350px, calc(100vw - 24px)); }
  .hero { height: 76svh; min-height: 520px; max-height: 680px; }
  .hero::after { background: linear-gradient(90deg, rgb(0 0 0 / .56), transparent 100%), linear-gradient(180deg, rgb(0 0 0 / .22) 0%, transparent 30%, rgb(9 9 11 / .55) 62%, #09090b 100%); }
  .hero-content { min-height: 100%; padding: 84px 20px 104px; justify-content: flex-end; }
  .hero-copy { max-width: 100%; }
  .trend-badge { font-size: 9px; }
  .hero-title { max-width: 100%; font-size: clamp(38px, 11vw, 50px); line-height: 1; }
  .hero-meta { gap: 8px; margin-top: 12px; font-size: 12px; }
  .hero-description { max-width: 100%; margin-top: 13px; font-size: 13px; line-height: 1.55; -webkit-line-clamp: 3; }
  .hero-actions { margin-top: 16px; }
  .btn { min-height: 42px; padding-inline: 17px; font-size: 12px; }
  .hero-navigation { padding: 0 20px 145px; }
  .platform-section { padding: 18px 16px 5px; margin-top: 0; }
  #popular-section { padding: 0 16px 20px; margin-top: -42px; }
  .platform-heading { margin-bottom: 10px; font-size: 9px; }
  .platform-grid { gap: 6px; }
  .platform-card { gap: 6px; }
  .platform-logo { width: min(48px, 100%); height: auto; aspect-ratio: 1; border-radius: 13px; }
  .platform-name { font-size: 8px; }
  .main-content { padding: 25px 16px 84px; }
  .section-heading { margin-bottom: 13px; }
  .section-title { font-size: 20px; }
  .popular-label { font-size: 9px; }
  .popular-carousel { grid-template-columns: 26px minmax(0,1fr) 26px; gap: 6px; }
  .popular-carousel .popular-arrow { width: 26px; height: 34px; }
  .popular-carousel .popular-grid { grid-auto-columns: min(76vw, 300px); column-gap: 10px; padding-top: 4px; }
  .popular-grid .card-title { font-size: 12px; }
  .film-grid { grid-template-columns: repeat(4, minmax(0,1fr)); gap: 17px 8px; }
  .film-grid .card-title { font-size: 10px; }
  .film-grid .card-year, .film-grid .card-meta { font-size: 9px; }
  .tabs { max-width: 100%; overflow-x: auto; }
  .tab-btn { padding: 7px 10px; font-size: 10px; }
  .browse-controls { margin-bottom: 13px; }
  .category-wrap { font-size: 10px; }
  .category-wrap select { width: 140px; min-height: 36px; font-size: 10px; }
  footer { padding-bottom: 84px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* App destination beside the shared search and community controls. */
.header-inner > .header-icon.header-icon-link.app-download-link {
  display: grid;
  order: 3;
  flex-shrink: 0;
  place-items: center;
  border-color: transparent;
  background: transparent;
  text-decoration: none;
}
.header-icon.app-download-link svg {
  width: 21px;
  height: 21px;
  transition: transform .2s ease;
}
.header-icon.app-download-link:hover {
  border-color: transparent;
  background: transparent;
  color: #fbbf24;
}
.header-icon.app-download-link:hover svg { transform: translateY(1px); }
.header-icon.app-download-link:focus-visible { outline: 2px solid #fbbf24; outline-offset: 3px; }
@media (max-width: 560px) {
  .header-icon.app-download-link svg { width: 19px; height: 19px; }
}
@media (prefers-reduced-motion: reduce) {
  .header-icon.app-download-link svg { transition: none; }
  .header-icon.app-download-link:hover svg { transform: none; }
}
body[data-page="watch"] .header-search { order: 2; }
body[data-page="watch"] .header-inner > [data-telegram-link] { order: 4; }
body[data-page="watch"] .header-inner > .profile-link { order: 5; }
