/* BONGO FRESH — MODERN MOBILE-FIRST OTT STREAMING STYLES */
:root {
  --bg-primary: #0a0c10;
  --bg-secondary: #131720;
  --bg-card: #181d28;
  --bg-card-hover: #222938;
  --accent-gold: #ffb800;
  --accent-gold-hover: #ffa500;
  --accent-red: #e50914;
  --accent-emerald: #00d26a;
  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --text-dim: #6b7280;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-focus: rgba(255, 184, 0, 0.4);
  --font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.4);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-main);
  font-family: var(--font-family);
  overflow-x: hidden;
  padding-bottom: 70px; /* Space for mobile bottom nav */
}

/* TOP NAVBAR */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  padding: 0 20px;
  background: rgba(10, 12, 16, 0.92);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
}

.brand-logo {
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
}

.logo-badge {
  background: var(--accent-red);
  color: #fff;
  font-weight: 800;
  font-size: 13px;
  padding: 3px 6px;
  border-radius: 4px;
  letter-spacing: 1px;
}

.logo-fresh {
  color: var(--accent-gold);
  font-weight: 800;
  font-size: 19px;
  letter-spacing: 0.5px;
}

.search-bar-desktop {
  flex: 1;
  max-width: 480px;
  margin: 0 24px;
}

.search-input-wrap {
  position: relative;
  width: 100%;
}

.icon-search {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  stroke: var(--text-dim);
}

.search-input-wrap input {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  padding: 10px 16px 10px 42px;
  color: var(--text-main);
  font-size: 14px;
  outline: none;
  transition: all 0.2s ease;
}

.search-input-wrap input:focus {
  border-color: var(--border-focus);
  background: var(--bg-card);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-icon {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  font-weight: 700;
  font-size: 12px;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.btn-data-saver {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-data-saver.active {
  background: rgba(0, 210, 106, 0.15);
  border-color: var(--accent-emerald);
  color: #fff;
}

.data-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-dim);
}

.btn-data-saver.active .data-indicator {
  background: var(--accent-emerald);
  box-shadow: 0 0 8px var(--accent-emerald);
}

.btn-primary-gradient {
  background: linear-gradient(135deg, var(--accent-gold) 0%, #ff8800 100%);
  color: #000;
  font-weight: 700;
  font-size: 13px;
  padding: 9px 18px;
  border-radius: 20px;
  border: none;
  cursor: pointer;
  transition: transform 0.15s, opacity 0.15s;
}

.btn-primary-gradient:active {
  transform: scale(0.97);
}

/* HERO SPOTLIGHT */
.hero-section {
  position: relative;
  min-height: 480px;
  display: flex;
  align-items: flex-end;
  padding: 40px 30px;
  background-size: cover;
  background-position: center top;
  overflow: hidden;
}

.hero-backdrop {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: opacity 0.5s ease;
  z-index: 1;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, var(--bg-primary) 10%, rgba(10, 12, 16, 0.7) 60%, rgba(10, 12, 16, 0.4) 100%);
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 3;
  max-width: 640px;
}

.hero-tags {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.badge-tag {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
}

.badge-category {
  background: rgba(255, 184, 0, 0.2);
  color: var(--accent-gold);
}

.badge-rating {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.badge-quality {
  background: rgba(0, 210, 106, 0.2);
  color: var(--accent-emerald);
}

.hero-title {
  font-size: 34px;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 10px;
  color: #fff;
}

.hero-synopsis {
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-muted);
  margin-bottom: 20px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-actions {
  display: flex;
  gap: 12px;
}

.btn-play-hero {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  color: #000;
  font-weight: 700;
  font-size: 14px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: transform 0.15s;
}

.btn-play-hero:active {
  transform: scale(0.97);
}

.play-icon {
  width: 18px;
  height: 18px;
}

.btn-details-hero {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-weight: 600;
  font-size: 14px;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  backdrop-filter: blur(8px);
}

/* CONTENT RAILS */
.content-container {
  padding: 24px 20px;
}

.rail-section {
  margin-bottom: 34px;
}

.rail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.rail-title {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.2px;
}

.rail-scroller {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding-bottom: 12px;
  scrollbar-width: thin;
}

.rail-scroller::-webkit-scrollbar {
  height: 6px;
}

.rail-scroller::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

/* MEDIA CARD */
.media-card {
  flex: 0 0 160px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-card);
}

.media-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card);
}

.card-poster-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 2/3;
  overflow: hidden;
  background: var(--bg-secondary);
}

.card-poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.media-card:hover .card-poster {
  transform: scale(1.05);
}

.card-badge-top {
  position: absolute;
  top: 8px;
  right: 8px;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
  text-transform: uppercase;
}

.badge-free {
  background: var(--accent-emerald);
  color: #000;
}

.badge-sub {
  background: var(--accent-gold);
  color: #000;
}

.card-info {
  padding: 10px;
}

.card-title {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 4px;
}

.card-meta {
  font-size: 11px;
  color: var(--text-dim);
  display: flex;
  gap: 6px;
}

/* MODALS */
.details-modal, .checkout-modal, .player-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal-card, .checkout-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  max-width: 580px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.7);
}

.modal-close-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 10;
  background: rgba(0, 0, 0, 0.5);
  border: none;
  color: #fff;
  font-size: 24px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-banner {
  position: relative;
  height: 220px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: flex-end;
  padding: 20px;
}

.modal-banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, var(--bg-card) 5%, transparent 100%);
}

.modal-title {
  position: relative;
  font-size: 24px;
  font-weight: 800;
  color: #fff;
}

.modal-body {
  padding: 20px;
}

.modal-meta-row {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.meta-tag {
  background: var(--bg-secondary);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 4px;
}

.modal-desc {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--text-muted);
  margin-bottom: 20px;
}

/* CHECKOUT MODAL */
.checkout-card {
  padding: 24px;
}

.checkout-header {
  text-align: center;
  margin-bottom: 20px;
}

.checkout-brand {
  font-size: 11px;
  font-weight: 800;
  color: var(--accent-gold);
  letter-spacing: 1px;
}

.checkout-title {
  font-size: 20px;
  font-weight: 800;
  margin: 6px 0;
}

.checkout-subtitle {
  font-size: 12px;
  color: var(--text-muted);
}

.package-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.pkg-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.pkg-card.active {
  border-color: var(--accent-gold);
  background: rgba(255, 184, 0, 0.08);
}

.radio-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--text-dim);
  display: inline-block;
  margin-right: 12px;
}

.pkg-card.active .radio-dot {
  border-color: var(--accent-gold);
  background: var(--accent-gold);
}

.pkg-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.pkg-name {
  font-weight: 700;
  font-size: 14px;
  color: #fff;
}

.pkg-desc {
  font-size: 11px;
  color: var(--text-dim);
}

.pkg-price {
  font-weight: 800;
  font-size: 15px;
  color: var(--accent-gold);
}

.phone-entry-box {
  margin-bottom: 20px;
}

.input-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.phone-input-row {
  display: flex;
  align-items: center;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.phone-prefix {
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.05);
  font-weight: 700;
  font-size: 14px;
  color: var(--text-muted);
}

.phone-input-row input {
  flex: 1;
  background: transparent;
  border: none;
  padding: 12px;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  outline: none;
}

.btn-full {
  width: 100%;
  padding: 14px;
  font-size: 14px;
}

.payment-status-box {
  text-align: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-md);
  margin-top: 14px;
}

.spinner-pulse {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--accent-gold);
  margin: 0 auto 10px;
  animation: pulse 1s infinite alternate;
}

@keyframes pulse {
  0% { transform: scale(0.8); opacity: 0.5; }
  100% { transform: scale(1.2); opacity: 1; }
}

/* FULLSCREEN PLAYER */
.player-modal {
  padding: 0;
  background: #000;
}

.player-container {
  position: relative;
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: #000;
}

.player-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.8) 0%, transparent 100%);
}

.btn-back {
  background: transparent;
  border: none;
  color: #fff;
  cursor: pointer;
  width: 32px;
  height: 32px;
}

.player-titles {
  display: flex;
  flex-direction: column;
  text-align: center;
}

.player-program-title {
  font-weight: 700;
  font-size: 15px;
  color: #fff;
}

.player-episode-title {
  font-size: 12px;
  color: var(--text-muted);
}

.quality-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  color: #fff;
}

#videoElement {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* AI CONCIERGE WIDGET */
.ai-floating-widget {
  position: fixed;
  bottom: 84px;
  right: 20px;
  z-index: 150;
}

.btn-ai-bubble {
  display: flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #fff;
  border: none;
  padding: 10px 16px;
  border-radius: 30px;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.4);
}

.btn-ai-bubble svg {
  width: 18px;
  height: 18px;
}

.ai-chat-drawer {
  position: fixed;
  bottom: 80px;
  right: 20px;
  width: 320px;
  max-width: calc(100vw - 40px);
  height: 420px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.ai-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
}

.ai-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ai-avatar-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent-emerald);
}

.ai-drawer-title {
  font-weight: 700;
  font-size: 13px;
}

.ai-close-btn {
  background: none;
  border: none;
  color: #fff;
  font-size: 20px;
  cursor: pointer;
}

.ai-drawer-messages {
  flex: 1;
  padding: 14px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ai-bubble-msg {
  max-width: 85%;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  font-size: 12.5px;
  line-height: 1.45;
}

.ai-bubble-msg.ai {
  background: var(--bg-secondary);
  color: var(--text-main);
  align-self: flex-start;
  border-left: 3px solid var(--accent-emerald);
}

.ai-bubble-msg.user {
  background: var(--accent-gold);
  color: #000;
  align-self: flex-end;
  font-weight: 500;
}

.ai-drawer-input-row {
  display: flex;
  padding: 10px;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-subtle);
  gap: 6px;
}

.ai-drawer-input-row input {
  flex: 1;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  padding: 8px 12px;
  color: #fff;
  font-size: 12px;
  outline: none;
}

.btn-ai-send {
  background: var(--accent-emerald);
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #fff;
}

.btn-ai-send svg {
  width: 14px;
  height: 14px;
}

/* MOBILE BOTTOM BAR */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: rgba(10, 12, 16, 0.95);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--border-subtle);
  z-index: 90;
  justify-content: space-around;
  align-items: center;
}

.mobile-bottom-nav .nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  color: var(--text-dim);
  font-size: 10px;
  gap: 4px;
}

.mobile-bottom-nav .nav-item.active {
  color: var(--accent-gold);
}

.mobile-bottom-nav svg {
  width: 20px;
  height: 20px;
}

/* RESPONSIVE MEDIA QUERIES */
@media (max-width: 768px) {
  .search-bar-desktop {
    display: none;
  }

  .mobile-bottom-nav {
    display: flex;
  }

  .hero-section {
    min-height: 400px;
    padding: 24px 16px;
  }

  .hero-title {
    font-size: 26px;
  }

  .media-card {
    flex: 0 0 130px;
  }
}
