/* ==========================================================================
   CAMS.SEGAVIDEO.IT - Stili specifici webcam
   Estende black_orange.css caricato dal sito principale
   ========================================================================== */

/* -- LIVE badge (rosso pulsante, posizione bottom-left come .line-private) -- */
.cam-thumb .line-live {
  position: absolute;
  bottom: 5px;
  left: 5px;
  background: #e60000;
  color: #ffffff;
  font-weight: 700;
  font-size: 11px;
  line-height: 20px;
  border-radius: 5px;
  padding: 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  animation: live-pulse 2s ease-in-out infinite;
  z-index: 5;
}

@keyframes live-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.65; }
}

/* -- Badge Gruppo (giallo) -- */
.cam-thumb .line-group {
  position: absolute;
  bottom: 5px;
  left: 5px;
  background: rgba(255, 153, 0, 0.9);
  color: #ffffff;
  font-weight: 700;
  font-size: 11px;
  line-height: 20px;
  border-radius: 5px;
  padding: 0 8px;
  z-index: 5;
}

/* -- Country flag overlay (top-right) -- */
.cam-thumb .cam-country {
  position: absolute;
  top: 5px;
  right: 5px;
  z-index: 5;
  background: rgba(0, 0, 0, 0.65);
  border-radius: 3px;
  padding: 2px 5px;
  line-height: 0;
  display: flex;
  align-items: center;
}

.cam-thumb .cam-country img {
  position: static !important;
  width: 16px;
  height: 11px;
  display: block;
}

/* -- Viewer count nel badge -- */
.cam-thumb .cam-viewers {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 400;
  color: #b8b8b8;
}

.cam-thumb .cam-viewers svg {
  flex-shrink: 0;
  opacity: 0.7;
}

/* -- Goal progress bar -- */
.cam-goal {
  margin-top: 4px;
}

.cam-goal .goal-bar {
  height: 3px;
  background: #201123;
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 3px;
}

.cam-goal .goal-fill {
  height: 100%;
  background: linear-gradient(90deg, #ff00ff, #ff66ff);
  border-radius: 2px;
  transition: width 0.5s ease;
}

.cam-goal .goal-text {
  font-size: 11px;
  color: #7e5786;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

/* -- Online count indicator (heading) -- */
.online-count {
  color: #00dd00;
  font-size: 14px;
  font-weight: 400;
  display: flex;
  align-items: center;
  gap: 6px;
}

.online-count::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #00dd00;
  animation: live-pulse 2s ease-in-out infinite;
  flex-shrink: 0;
}

/* -- Hero section per cam homepage -- */
.cams-hero {
  position: relative;
  padding: 50px 20px;
  text-align: center;
  background: linear-gradient(135deg, #1a0520 0%, #0c050e 40%, #200030 100%);
  border-radius: 12px;
  margin-bottom: 30px;
  overflow: hidden;
}

.cams-hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 50%, rgba(255,0,255,0.08) 0%, transparent 50%),
              radial-gradient(circle at 70% 50%, rgba(230,0,0,0.04) 0%, transparent 50%);
  pointer-events: none;
}

.cams-hero .hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  margin: 0 auto;
}

.cams-hero .hero-title {
  font-family: 'Outfit', 'Roboto', sans-serif;
  font-size: 2.2rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 10px;
  line-height: 1.2;
}

.cams-hero .hero-title span {
  color: #ff00ff;
}

.cams-hero .hero-subtitle {
  font-family: 'Roboto', sans-serif;
  font-size: 1rem;
  color: #b8b8b8;
  margin: 0;
  line-height: 1.5;
}

/* -- Tag navigation (scroll orizzontale) -- */
.cam-tags-nav {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 8px 0 16px;
  scrollbar-width: thin;
  scrollbar-color: #201123 transparent;
  -webkit-overflow-scrolling: touch;
}

.cam-tags-nav::-webkit-scrollbar {
  height: 4px;
}

.cam-tags-nav::-webkit-scrollbar-track {
  background: transparent;
}

.cam-tags-nav::-webkit-scrollbar-thumb {
  background: #3a1a40;
  border-radius: 2px;
}

.cam-tags-nav .tag-link {
  flex-shrink: 0;
  white-space: nowrap;
  padding: 6px 14px;
  background: #201123;
  color: #b8b8b8;
  border-radius: 20px;
  font-size: 13px;
  text-decoration: none;
  transition: all 0.25s ease;
  border: 1px solid transparent;
}

.cam-tags-nav .tag-link:hover {
  background: rgba(255, 0, 255, 0.15);
  color: #ff00ff;
  border-color: rgba(255, 0, 255, 0.3);
}

.cam-tags-nav .tag-link.active {
  background: #ff00ff;
  color: #ffffff;
  font-weight: 700;
}

.cam-tags-nav .tag-count {
  font-size: 11px;
  color: #7e5786;
  margin-left: 4px;
}

.cam-tags-nav .tag-link.active .tag-count {
  color: rgba(255, 255, 255, 0.7);
}

/* -- Stream row: player + chat side by side (stile Stripchat) -- */
.stream-row {
  display: flex;
  gap: 0;
  margin-bottom: 16px;
  height: calc(100vh - 130px);
  max-height: 540px;
  border-radius: 10px;
  overflow: hidden;
  background: #000;
}

.stream-player {
  flex: 1 1 auto;
  min-width: 0;
  position: relative;
}

.stream-chat {
  flex: 0 0 320px;
  background: #1a0d1e;
  border-left: 1px solid #2a1530;
}

.stream-chat iframe,
.stream-chat > div {
  width: 100%;
  height: 100%;
  border: none;
}

/* -- Player wrapper nella pagina stream -- */
.stream-row .player-wrap {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  border-radius: 0;
}

.stream-row .player-wrap iframe,
.stream-row .player-wrap > div {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Player standalone (fuori da stream-row, es. fallback) */
.player-wrap {
  position: relative;
  padding-bottom: 56.25%;
  background: #000;
  border-radius: 10px;
  overflow: hidden;
}

.player-wrap iframe,
.player-wrap > div {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* -- Badge provider sulla thumbnail -- */
.cam-provider {
  position: absolute;
  top: 5px;
  right: 5px;
  font-size: 9px;
  font-weight: 700;
  line-height: 16px;
  padding: 0 5px;
  border-radius: 3px;
  z-index: 5;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.cam-provider-bc {
  background: #e84393;
  color: #fff;
}

/* -- BongaCams HLS player -- */
#bc-player-link {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}
#bc-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
  pointer-events: none;
}
.bc-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 12px;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s;
}
#bc-player-link:hover .bc-overlay {
  opacity: 1;
}
.bc-unmute-hint {
  color: #fff;
  font-size: 13px;
  font-weight: 600;
}
.bc-chat-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.bc-chat-inner {
  padding: 20px;
}
.bc-chat-logo {
  display: inline-block;
  width: 48px;
  height: 48px;
  line-height: 48px;
  border-radius: 50%;
  background: #e84393;
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
}
.bc-chat-inner h3 {
  color: #fff;
  font-size: 16px;
  margin: 0 0 6px;
  word-break: break-all;
}
.bc-chat-inner p {
  color: #7e5786;
  font-size: 13px;
  margin: 0 0 16px;
}
.bc-chat-inner .btn-stripchat {
  display: inline-block;
  padding: 10px 22px;
  background: #e84393;
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.3s ease;
}
.bc-chat-inner .btn-stripchat:hover {
  background: #d63384;
  transform: translateY(-2px);
}

/* -- Model info section (pagina stream) -- */
.model-info-section {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 0;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.model-info-section .model-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #ff00ff;
  flex-shrink: 0;
}

.model-info-section .model-name {
  font-family: 'Outfit', 'Roboto', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
}

.model-info-section .model-meta {
  display: flex;
  gap: 14px;
  margin-top: 4px;
  font-size: 13px;
  color: #7e5786;
  flex-wrap: wrap;
}

.model-info-section .model-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

.model-info-section .model-meta .live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #00dd00;
  animation: live-pulse 2s ease-in-out infinite;
}

/* -- Tags row sulla pagina stream -- */
.stream-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 20px;
}

.stream-tags .tag-link {
  padding: 4px 12px;
  background: #201123;
  color: #b8b8b8;
  border-radius: 15px;
  font-size: 12px;
  text-decoration: none;
  transition: all 0.25s ease;
}

.stream-tags .tag-link:hover {
  background: rgba(255, 0, 255, 0.15);
  color: #ff00ff;
}

/* -- Offline model overlay -- */
.cam-thumb.is-offline .img-holder::after {
  content: 'OFFLINE';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.7);
  color: #7e5786;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 1px;
  z-index: 6;
  border-radius: 10px;
}

/* -- Offline banner nella pagina stream -- */
.model-offline-banner {
  text-align: center;
  padding: 60px 20px;
  background: #201123;
  border-radius: 10px;
  margin-bottom: 20px;
}

.model-offline-banner h2 {
  font-family: 'Outfit', 'Roboto', sans-serif;
  font-size: 1.5rem;
  color: #fff;
  margin: 0 0 8px;
}

.model-offline-banner p {
  color: #7e5786;
  margin: 0 0 20px;
}

.model-offline-banner .btn-stripchat {
  display: inline-block;
  padding: 12px 28px;
  background: #ff00ff;
  color: #000;
  font-weight: 700;
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.model-offline-banner .btn-stripchat:hover {
  background: #cc00cc;
  transform: translateY(-2px);
}

/* -- No models message -- */
.no-models-msg {
  text-align: center;
  padding: 60px 20px;
  color: #7e5786;
  font-size: 16px;
}

/* -- Fade-in animation -- */
.fade-in {
  opacity: 0;
  transform: translateY(15px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* -- Heading con contatore -- */
.cams-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 10px;
}

.cams-heading .title {
  font-family: 'Outfit', 'Roboto', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

/* -- Paginazione -- */
.cams-pagination {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 20px 0;
  flex-wrap: wrap;
}

.cams-pagination a,
.cams-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border-radius: 8px;
  font-size: 14px;
  text-decoration: none;
  transition: all 0.25s ease;
}

.cams-pagination a {
  background: #201123;
  color: #b8b8b8;
}

.cams-pagination a:hover {
  background: rgba(255, 0, 255, 0.15);
  color: #ff00ff;
}

.cams-pagination span.current {
  background: #ff00ff;
  color: #ffffff;
  font-weight: 700;
}

.cams-pagination span.dots {
  background: none;
  color: #7e5786;
}

/* -- Footer cam -- */
.cams-footer {
  text-align: center;
  padding: 30px 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  margin-top: 30px;
}

.cams-footer p {
  color: #7e5786;
  font-size: 12px;
  margin: 4px 0;
}

.cams-footer a {
  color: #b8b8b8;
  text-decoration: none;
  transition: color 0.25s;
}

.cams-footer a:hover {
  color: #ff00ff;
}

/* -- Responsive adjustments -- */
@media (max-width: 768px) {
  .stream-row {
    flex-direction: column;
    height: auto;
    max-width: 100%;
  }
  .stream-player {
    position: relative;
    padding-bottom: 56.25%;
  }
  .bc-chat-panel {
    height: auto !important;
    min-height: 150px;
  }
  .stream-chat {
    flex: none;
    height: 350px;
    border-left: none;
    border-top: 1px solid #2a1530;
  }
  .cams-hero {
    padding: 35px 15px;
  }
  .cams-hero .hero-title {
    font-size: 1.6rem;
  }
  .model-info-section {
    flex-direction: column;
    align-items: flex-start;
  }
  .model-info-section .model-avatar {
    width: 44px;
    height: 44px;
  }
}

@media (max-width: 480px) {
  .cams-hero .hero-title {
    font-size: 1.3rem;
  }
  .cams-heading .title {
    font-size: 1.1rem;
  }
}
