/* ========== BN Character Profile Page ========== */
/* Uses bh-body class + bh-navbar from bn-ai-girlfriend (inline critical CSS) */
/* No bn_style.css dependency — fully standalone with bn_character-profile.css */

/* ---- Header: Back button + Navbar pill ---- */
.cp-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  padding: 16px 24px;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.cp-back-btn {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 6px;
  color: #fff;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 18px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}
.cp-back-btn:hover { border-color: rgba(255, 255, 255, 0.4); background: rgba(255, 255, 255, 0.05); }

/* Override bh-navbar — center it within the header */
.cp-navbar.bh-navbar {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 448px;
  max-width: calc(100% - 200px);
  z-index: 1;
}

/* ---- Main Layout ---- */
.cp-main {
  padding: 24px;
  max-width: 1400px;
  margin: 0 auto;
}

.cp-container {
  background: #111118;
  border: 1px solid #1a1a2e;
  border-radius: 16px;
  padding: 24px;
  overflow: hidden;
}

.cp-name {
  font-size: 28px;
  font-weight: 700;
  color: #c4b5fd;
  margin: 0 0 20px 0;
}

.cp-grid {
  display: grid;
  grid-template-columns: 380px 1fr 340px;
  gap: 24px;
  align-items: start;
}

/* ---- Left Column: Slider ---- */
.cp-left {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cp-slider {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: #1a1a2e;
}

.cp-slides {
  width: 100%;
  height: 100%;
  position: relative;
}

.cp-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.4s ease;
}
.cp-slide.active { opacity: 1; }

.cp-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cp-slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 3;
  transition: background 0.2s;
}
.cp-slider-btn:hover { background: rgba(0, 0, 0, 0.8); }
.cp-prev { left: 10px; }
.cp-next { right: 10px; }

.cp-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 2;
}

.cp-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transition: background 0.2s;
  cursor: pointer;
}
.cp-dot.active { background: #fff; }

.cp-archetype-badge {
  display: inline-block;
  align-self: flex-start;
  padding: 4px 14px;
  background: rgba(124, 58, 237, 0.2);
  color: #c4b5fd;
  border: 1px solid rgba(124, 58, 237, 0.4);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
}

.cp-cta-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  background: #fff;
  color: #000;
  font-size: 15px;
  font-weight: 700;
  border-radius: 12px;
  text-decoration: none;
  transition: all 0.2s;
}
.cp-cta-btn:hover { background: #e5e5e5; transform: translateY(-1px); }

/* ---- Center Column: About ---- */
.cp-card {
  background: #0f0f16;
  border: 1px solid #1a1a2e;
  border-radius: 12px;
  padding: 24px;
}

.cp-section-title {
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 12px 0;
}

.cp-bio {
  font-size: 14px;
  line-height: 1.6;
  color: #999;
  margin: 0;
}

.cp-divider {
  border: none;
  border-top: 1px solid #1a1a2e;
  margin: 18px 0;
}

.cp-subtitle {
  font-size: 15px;
  font-weight: 600;
  color: #c4b5fd;
  margin: 0 0 12px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.cp-dot-purple, .cp-dot-pink, .cp-dot-green, .cp-dot-blue {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}
.cp-dot-purple { background: #7c3aed; }
.cp-dot-pink { background: #ec4899; }
.cp-dot-green { background: #22c55e; }
.cp-dot-blue { background: #3b82f6; }

.cp-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.cp-info-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.cp-info-label {
  font-size: 12px;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cp-info-value {
  font-size: 14px;
  font-weight: 600;
  color: #fff;
}

.cp-tags {
  font-size: 14px;
  color: #ccc;
  line-height: 1.6;
  margin: 0;
}

/* ---- Right Column: Gallery ---- */
.cp-gallery-sub {
  font-size: 13px;
  color: #888;
  margin: 0 0 16px 0;
}

.cp-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}

.cp-gallery-thumb {
  aspect-ratio: 3 / 4;
  border-radius: 8px;
  overflow: hidden;
  background: #1a1a2e;
}

.cp-gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}
.cp-gallery-thumb:hover img { transform: scale(1.05); }

.cp-generate-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  background: #1a1a2e;
  border: 1px solid #2a2a40;
  border-radius: 10px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  width: 100%;
}
.cp-generate-btn:hover { background: #252540; border-color: #7c3aed; }

/* ---- SEO "Ready to Meet" Section ---- */
.cp-seo {
  background: #0a0a12;
  border-top: 1px solid #1a1a2e;
  padding: 64px 24px;
}

.cp-seo-inner {
  max-width: 1400px;
  margin: 0 auto;
  background: #111118;
  border: 1px solid #1a1a2e;
  border-radius: 16px;
  padding: 48px 40px;
}

.cp-seo-header {
  text-align: center;
  margin-bottom: 40px;
}

.cp-seo-heading {
  font-size: 32px;
  font-weight: 600;
  color: #c4b5fd;
  margin: 0 0 8px 0;
  line-height: 1.2;
}

.cp-seo-subtitle {
  font-size: 14px;
  color: #999;
  margin: 0;
  line-height: 1.5;
}

.cp-seo-content {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 32px;
  align-items: start;
}

.cp-seo-left {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.cp-seo-img {
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: #1a1a2e;
}
.cp-seo-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cp-seo-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 32px;
  background: rgba(196, 181, 253, 0.15);
  color: #c4b5fd;
  font-size: 15px;
  font-weight: 600;
  border-radius: 28px;
  text-decoration: none;
  transition: all 0.2s;
  align-self: flex-start;
}
.cp-seo-cta:hover {
  background: rgba(196, 181, 253, 0.25);
}
.cp-seo-cta svg {
  background: #c4b5fd;
  color: #000;
  border-radius: 50%;
  padding: 3px;
  width: 24px;
  height: 24px;
}

.cp-seo-right {
  padding-top: 4px;
}

.cp-seo-text {
  font-size: 14px;
  line-height: 1.8;
  color: #bbb;
  white-space: pre-line;
}

/* ---- Error State ---- */
.cp-error {
  text-align: center;
  padding: 120px 24px;
  color: #999;
}
.cp-error a {
  color: #c4b5fd;
  text-decoration: underline;
}

/* ---- Responsive ---- */
@media (max-width: 1100px) {
  .cp-grid {
    grid-template-columns: 1fr 1fr;
  }
  .cp-right {
    grid-column: 1 / -1;
  }
  .cp-gallery-grid {
    grid-template-columns: repeat(6, 1fr);
  }
}

@media (max-width: 768px) {
  .cp-header { padding: 10px 10px; gap: 8px; }
  .cp-back-btn { padding: 6px 10px; font-size: 12px; border-radius: 10px; }
  /* On mobile: drop absolute centering, use normal flex flow */
  .cp-navbar.bh-navbar {
    position: static;
    transform: none;
    width: auto;
    max-width: none;
    flex: 1;
    min-width: 0;
    padding: 8px 10px 8px 12px;
  }
  .cp-navbar.bh-navbar .bh-navbar__btn { font-size: 11px; padding: 5px 12px; }
  .cp-navbar.bh-navbar .bh-navbar__logo { width: 20px; height: 20px; }
  .cp-navbar.bh-navbar a > span { font-size: 16px; }
  .cp-main { padding: 12px 10px 10px; }
  .cp-container { padding: 12px; border-radius: 12px; }
  .cp-name { font-size: 20px; margin-bottom: 12px; }

  .cp-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .cp-slider { aspect-ratio: 3 / 4; max-height: 480px; }

  .cp-gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  /* SEO section mobile */
  .cp-seo { padding: 32px 12px; }
  .cp-seo-inner { padding: 24px 16px; }
  .cp-seo-heading { font-size: 24px; }
  .cp-seo-content { grid-template-columns: 1fr; gap: 24px; }
  .cp-seo-img { max-height: 400px; }
  .cp-seo-cta { align-self: center; }
}
