/**
 * FilmyBazaar Android App Hub Stylesheet
 * Ultra-optimized, mobile-first, Core Web Vitals compliant (Zero CLS, LCP-optimized)
 */

:root {
  --fb-bg: #09090b;
  --fb-card-bg: #121217;
  --fb-card-hover: #181820;
  --fb-border: rgba(255, 255, 255, 0.09);
  --fb-red: #e50914;
  --fb-red-glow: rgba(229, 9, 20, 0.35);
  --fb-green: #10b981;
  --fb-gold: #f5c518;
  --fb-text: #f4f4f6;
  --fb-muted: #9ca3af;
  --fb-radius: 12px;
  --fb-radius-lg: 16px;
  --fb-font: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

body.fb-app-hub {
  background-color: var(--fb-bg);
  color: var(--fb-text);
  font-family: var(--fb-font);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Header */
.fb-hub-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(9, 9, 11, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--fb-border);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.fb-hub-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--fb-text);
  font-size: 1.25rem;
  font-weight: 700;
}

.fb-hub-brand i {
  color: var(--fb-red);
}

.fb-hub-brand-filmy {
  color: #ffffff;
}

.fb-hub-brand-bazaar {
  color: var(--fb-red);
}

.fb-hub-nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

.fb-hub-nav-link {
  color: var(--fb-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.fb-hub-nav-link:hover,
.fb-hub-nav-link.active {
  color: #ffffff;
}

.fb-hub-header-btn {
  background: var(--fb-red);
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.15s ease, background 0.2s ease;
}

.fb-hub-header-btn:hover {
  background: #f40612;
  transform: translateY(-1px);
}

/* Container */
.fb-hub-container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Breadcrumbs */
.fb-breadcrumbs {
  padding: 16px 0 8px;
  font-size: 0.85rem;
  color: var(--fb-muted);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.fb-breadcrumbs a {
  color: var(--fb-muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

.fb-breadcrumbs a:hover {
  color: #ffffff;
}

.fb-breadcrumbs span.sep {
  color: rgba(255, 255, 255, 0.25);
}

.fb-breadcrumbs span.current {
  color: #ffffff;
}

/* Hero Section */
.fb-hero {
  padding: 40px 0 32px;
  text-align: center;
}

.fb-app-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.12);
  color: var(--fb-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 20px;
}

.fb-hero h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1.2;
  margin-bottom: 16px;
  color: #ffffff;
}

.fb-hero p.lead {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  color: var(--fb-muted);
  max-width: 720px;
  margin: 0 auto 28px;
}

.fb-spec-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.88rem;
  color: var(--fb-muted);
  margin-bottom: 32px;
}

.fb-spec-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.fb-spec-item strong {
  color: #ffffff;
}

.fb-hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 20px;
}

.fb-btn-primary {
  background: linear-gradient(135deg, #e50914, #b20710);
  color: #ffffff;
  padding: 14px 28px;
  border-radius: var(--fb-radius);
  font-size: 1.05rem;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 4px 20px var(--fb-red-glow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.fb-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(229, 9, 20, 0.55);
}

.fb-btn-secondary {
  background: var(--fb-card-bg);
  color: var(--fb-text);
  border: 1px solid var(--fb-border);
  padding: 14px 24px;
  border-radius: var(--fb-radius);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.fb-btn-secondary:hover {
  background: var(--fb-card-hover);
  border-color: rgba(255, 255, 255, 0.2);
}

.fb-free-guarantee {
  font-size: 0.85rem;
  color: var(--fb-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}

.fb-free-guarantee i {
  color: var(--fb-gold);
}

/* Feature Grid */
.fb-section {
  padding: 48px 0;
  border-top: 1px solid var(--fb-border);
}

.fb-section-title {
  text-align: center;
  margin-bottom: 36px;
}

.fb-section-title h2 {
  font-size: clamp(1.5rem, 3.5vw, 2.2rem);
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 10px;
}

.fb-section-title p {
  color: var(--fb-muted);
  font-size: 0.98rem;
  max-width: 620px;
  margin: 0 auto;
}

.fb-grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.fb-grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.fb-card {
  background: var(--fb-card-bg);
  border: 1px solid var(--fb-border);
  border-radius: var(--fb-radius);
  padding: 24px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.fb-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.2);
}

.fb-card-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  margin-bottom: 18px;
}

.fb-icon-red { background: rgba(229, 9, 20, 0.15); color: var(--fb-red); }
.fb-icon-green { background: rgba(16, 185, 129, 0.15); color: var(--fb-green); }
.fb-icon-blue { background: rgba(59, 130, 246, 0.15); color: #3b82f6; }
.fb-icon-gold { background: rgba(245, 197, 24, 0.15); color: var(--fb-gold); }
.fb-icon-purple { background: rgba(168, 85, 247, 0.15); color: #a855f7; }
.fb-icon-cyan { background: rgba(6, 182, 212, 0.15); color: #06b6d4; }

.fb-card h3 {
  font-size: 1.15rem;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 8px;
}

.fb-card p {
  color: var(--fb-muted);
  font-size: 0.92rem;
  line-height: 1.55;
}

/* Steps / How-To */
.fb-step-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 800px;
  margin: 0 auto;
}

.fb-step-card {
  display: flex;
  gap: 20px;
  background: var(--fb-card-bg);
  border: 1px solid var(--fb-border);
  border-radius: var(--fb-radius);
  padding: 24px;
}

.fb-step-num {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--fb-red);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
}

.fb-step-body h3 {
  font-size: 1.15rem;
  color: #ffffff;
  margin-bottom: 6px;
}

.fb-step-body p {
  color: var(--fb-muted);
  font-size: 0.94rem;
  line-height: 1.55;
}

.fb-step-tip {
  margin-top: 10px;
  background: rgba(245, 197, 24, 0.08);
  border-left: 3px solid var(--fb-gold);
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 0.84rem;
  color: #fde047;
}

/* FAQ Accordion */
.fb-faq-list {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.fb-faq-item {
  background: var(--fb-card-bg);
  border: 1px solid var(--fb-border);
  border-radius: var(--fb-radius);
  overflow: hidden;
}

.fb-faq-item summary {
  padding: 18px 20px;
  font-size: 1.02rem;
  font-weight: 600;
  color: #ffffff;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.fb-faq-item summary::-webkit-details-marker {
  display: none;
}

.fb-faq-item summary::after {
  content: '+';
  font-size: 1.3rem;
  color: var(--fb-muted);
  transition: transform 0.2s ease;
}

.fb-faq-item[open] summary::after {
  content: '−';
  color: var(--fb-red);
}

.fb-faq-body {
  padding: 0 20px 20px;
  color: var(--fb-muted);
  font-size: 0.93rem;
  line-height: 1.6;
}

.fb-faq-body p + p {
  margin-top: 10px;
}

/* Version / Changelog Card */
.fb-changelog-card {
  background: var(--fb-card-bg);
  border: 1px solid var(--fb-border);
  border-radius: var(--fb-radius-lg);
  padding: 30px;
  margin-bottom: 24px;
}

.fb-changelog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--fb-border);
  margin-bottom: 20px;
}

.fb-version-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 1.3rem;
  font-weight: 700;
  color: #ffffff;
}

.fb-version-badge {
  background: rgba(16, 185, 129, 0.15);
  color: var(--fb-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 2px 10px;
  border-radius: 4px;
  font-size: 0.78rem;
  font-weight: 600;
}

.fb-version-date {
  color: var(--fb-muted);
  font-size: 0.88rem;
}

.fb-changelog-body h4 {
  font-size: 1rem;
  color: #ffffff;
  margin-bottom: 12px;
}

.fb-changelog-body ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.fb-changelog-body ul li {
  color: var(--fb-muted);
  font-size: 0.92rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.fb-changelog-body ul li i {
  color: var(--fb-green);
  margin-top: 4px;
  flex-shrink: 0;
}

/* Footer */
.fb-hub-footer {
  background: #050507;
  border-top: 1px solid var(--fb-border);
  padding: 40px 0 24px;
  margin-top: auto;
}

.fb-footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 30px;
  margin-bottom: 32px;
}

.fb-footer-col h4 {
  font-size: 0.95rem;
  color: #ffffff;
  margin-bottom: 16px;
  font-weight: 600;
}

.fb-footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.fb-footer-col a {
  color: var(--fb-muted);
  text-decoration: none;
  font-size: 0.88rem;
  transition: color 0.15s ease;
}

.fb-footer-col a:hover {
  color: #ffffff;
}

.fb-footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  color: #6b7280;
  font-size: 0.82rem;
}

/* ==========================================================================
   Smart Android Sticky Bottom CTA Banner
   ========================================================================== */
.fb-sticky-app-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  background: rgba(18, 18, 23, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.5);
  animation: fbSlideUp 0.3s ease-out;
}

@keyframes fbSlideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.fb-banner-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.fb-banner-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: var(--fb-red);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.fb-banner-text {
  min-width: 0;
}

.fb-banner-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fb-banner-subtitle {
  font-size: 0.78rem;
  color: var(--fb-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fb-banner-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.fb-banner-btn {
  background: var(--fb-red);
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.fb-banner-close {
  background: transparent;
  border: none;
  color: var(--fb-muted);
  font-size: 1.2rem;
  padding: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* ==========================================================================
   High-Conversion Download Interstitial Modal
   ========================================================================== */
.fb-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.fb-modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.fb-modal-card {
  background: #121217;
  border: 1px solid var(--fb-border);
  border-radius: var(--fb-radius-lg);
  max-width: 440px;
  width: 100%;
  padding: 28px 24px;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8);
  transform: scale(0.95);
  transition: transform 0.25s ease;
}

.fb-modal-overlay.active .fb-modal-card {
  transform: scale(1);
}

.fb-modal-icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: rgba(229, 9, 20, 0.15);
  color: var(--fb-red);
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

.fb-modal-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
}

.fb-modal-subtitle {
  font-size: 0.9rem;
  color: var(--fb-muted);
  margin-bottom: 20px;
}

.fb-modal-benefits {
  text-align: left;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.fb-benefit-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  color: #e4e4e7;
}

.fb-benefit-item i {
  color: var(--fb-green);
  font-size: 0.95rem;
  flex-shrink: 0;
}

.fb-modal-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.fb-modal-btn-download {
  background: linear-gradient(135deg, #e50914, #b20710);
  color: #ffffff;
  padding: 13px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 15px var(--fb-red-glow);
}

.fb-modal-btn-continue {
  background: transparent;
  border: none;
  color: var(--fb-muted);
  font-size: 0.88rem;
  font-weight: 500;
  padding: 8px;
  cursor: pointer;
  transition: color 0.15s ease;
}

.fb-modal-btn-continue:hover {
  color: #ffffff;
}

/* Mobile Responsiveness */
@media (max-width: 640px) {
  .fb-hero { padding: 24px 0; }
  .fb-hero-actions { flex-direction: column; width: 100%; }
  .fb-btn-primary, .fb-btn-secondary { width: 100%; justify-content: center; }
  .fb-step-card { flex-direction: column; gap: 12px; }
  .fb-spec-strip { flex-direction: column; gap: 8px; }
}
