/* Companion Cabin dashboard styles */
.cabin-shell {
  height: 100dvh;
  display: grid;
  grid-template-rows: auto 1fr;
  background: #0B0F19;
}

.cabin-body {
  display: grid;
  grid-template-columns: 300px 1fr;
  min-height: 0;
}

@media (max-width: 900px) {
  .cabin-body {
    grid-template-columns: 1fr;
  }
  .cabin-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: min(300px, 86vw);
    z-index: 40;
    transform: translateX(-105%);
    transition: transform 0.25s ease;
  }
  .cabin-sidebar.open { transform: translateX(0); }
  .cabin-sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    z-index: 35;
  }
  .cabin-sidebar-backdrop.show { display: block; }
}

.cabin-sidebar {
  background: #111827;
  border-right: 1px solid rgba(255,255,255,0.06);
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.char-card {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  width: 100%;
  text-align: left;
  padding: 0.85rem;
  border-radius: 0.9rem;
  border: 1px solid transparent;
  background: transparent;
  color: inherit;
  cursor: pointer;
  transition: all 0.2s ease;
}
.char-card:hover { background: rgba(139, 92, 246, 0.08); }
.char-card.active {
  border-color: rgba(139, 92, 246, 0.45);
  background: rgba(139, 92, 246, 0.14);
  box-shadow: 0 0 24px rgba(139, 92, 246, 0.15);
}

.char-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #fff;
  font-size: 0.95rem;
}

.cabin-main {
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 0;
  background:
    radial-gradient(ellipse 60% 40% at 80% 0%, rgba(139, 92, 246, 0.12), transparent),
    #0B0F19;
}

.chat-scroll {
  overflow-y: auto;
  padding: 1.25rem;
  min-height: 0;
  text-align: left;
}

.msg-row {
  display: flex;
  gap: 0.65rem;
  margin-bottom: 1rem;
  max-width: 820px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  align-items: flex-end;
}
.msg-row.user {
  flex-direction: row-reverse;
  justify-content: flex-start;
}

.msg-bubble {
  max-width: min(78%, 560px);
  padding: 0.75rem 1rem;
  border-radius: 1rem;
  line-height: 1.55;
  font-size: 0.925rem;
  white-space: pre-wrap;
  word-break: break-word;
  text-align: left;
}
.msg-row.ai .msg-bubble {
  background: #151C2C;
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-top-left-radius: 0.3rem;
  color: #E5E7EB;
}
.msg-row.user .msg-bubble {
  background: linear-gradient(135deg, #8B5CF6, #EC4899);
  border-top-right-radius: 0.3rem;
  color: #fff !important;
}

.msg-photo-fallback {
  color: #C4B5FD;
  font-style: normal;
  font-size: 0.85rem;
}

.msg-image {
  display: block;
  max-width: min(100%, 280px);
  width: 100%;
  border-radius: 0.75rem;
  margin-top: 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.msg-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: #fff;
}

.typing-row {
  display: none;
  align-items: center;
  gap: 0.5rem;
  max-width: 820px;
  margin: 0 auto 0.75rem;
  color: #A78BFA;
  font-size: 0.85rem;
}
.typing-row.show { display: flex; }
.typing-dots span {
  display: inline-block;
  width: 5px;
  height: 5px;
  margin-right: 3px;
  border-radius: 50%;
  background: #8B5CF6;
  animation: tb 1.2s infinite ease-in-out both;
}
.typing-dots span:nth-child(2) { animation-delay: 0.15s; }
.typing-dots span:nth-child(3) { animation-delay: 0.3s; }

.chat-composer {
  border-top: 1px solid rgba(255,255,255,0.06);
  background: rgba(17, 24, 39, 0.9);
  backdrop-filter: blur(12px);
  padding: 0.85rem 1rem 1rem;
}

.composer-box {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  gap: 0.5rem;
  align-items: flex-end;
  background: #151C2C;
  border: 1px solid rgba(139, 92, 246, 0.25);
  border-radius: 1rem;
  padding: 0.5rem;
}

.composer-box textarea {
  flex: 1;
  resize: none;
  background: transparent;
  border: none;
  outline: none;
  color: #F3F4F6;
  font-size: 0.95rem;
  line-height: 1.45;
  max-height: 140px;
  padding: 0.55rem 0.4rem;
}

.auth-modal,
.premium-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.auth-modal.open,
.premium-modal.open { display: flex; }
.auth-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(11, 15, 25, 0.82);
  backdrop-filter: blur(8px);
}
.auth-panel {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  padding: 1.5rem;
  background: #151C2C;
  border-radius: 1rem;
  border: 1px solid rgba(139, 92, 246, 0.3);
  box-shadow: 0 25px 60px rgba(0,0,0,0.5);
}

.auth-tabs {
  display: flex;
  gap: 0.35rem;
  margin-bottom: 1rem;
  background: #0B0F19;
  padding: 0.25rem;
  border-radius: 0.75rem;
}
.auth-tab {
  flex: 1;
  border: none;
  background: transparent;
  color: #9CA3AF;
  padding: 0.55rem;
  border-radius: 0.55rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}
.auth-tab.active {
  background: linear-gradient(135deg, #8B5CF6, #EC4899);
  color: #fff;
}

.field {
  margin-bottom: 0.85rem;
}
.field label {
  display: block;
  font-size: 0.78rem;
  color: #9CA3AF;
  margin-bottom: 0.35rem;
}
.field input {
  width: 100%;
  background: #0B0F19;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 0.65rem;
  padding: 0.7rem 0.85rem;
  color: #fff;
  font-size: 0.9rem;
}
.field input:focus {
  outline: none;
  border-color: rgba(139, 92, 246, 0.55);
}

.credits-pill {
  font-size: 0.75rem;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.35);
  color: #C4B5FD;
}

.gate-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100dvh;
  padding: 1.5rem;
  text-align: center;
}

/* Homepage hero embed — compact widget (not full-page cabin) */
.cabin-shell--embed {
  position: relative;
  height: 420px;
  min-height: 0;
  max-height: none;
  border-radius: 1.15rem;
  border: 1px solid rgba(139, 92, 246, 0.28);
  overflow: hidden;
  display: grid !important;
  grid-template-rows: auto 1fr;
  grid-template-columns: 1fr;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04),
    0 20px 50px rgba(0, 0, 0, 0.45),
    0 0 40px rgba(139, 92, 246, 0.1);
}

.cabin-shell--embed > header {
  grid-row: 1;
  z-index: 2;
}

.cabin-shell--embed > .cabin-body {
  grid-row: 2;
  min-height: 0;
  height: 100%;
  display: flex !important;
  flex-direction: column;
  grid-template-columns: none;
}

/* Companions as a horizontal chip row (not a tall sidebar) */
.cabin-shell--embed .cabin-sidebar {
  position: relative !important;
  inset: auto !important;
  transform: none !important;
  width: 100% !important;
  z-index: 1;
  flex: 0 0 auto;
  border-right: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: #111827;
  display: flex;
  flex-direction: column;
  max-height: none;
}

.cabin-shell--embed .cabin-sidebar > .p-4 {
  display: none;
}

.cabin-shell--embed .cabin-sidebar > .p-3.border-t {
  display: none;
}

.cabin-shell--embed #character-list,
.cabin-shell--embed .cabin-sidebar > .flex-1 {
  display: flex !important;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 0.5rem;
  overflow-x: auto;
  overflow-y: hidden;
  flex: 0 0 auto !important;
  padding: 0.65rem 0.75rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.cabin-shell--embed #character-list::-webkit-scrollbar {
  display: none;
}

.cabin-shell--embed .char-card {
  flex: 0 0 auto;
  width: auto;
  min-width: 0;
  max-width: none;
  align-items: center;
  padding: 0.45rem 0.7rem 0.45rem 0.45rem;
  gap: 0.5rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.cabin-shell--embed .char-card.active {
  border-color: rgba(139, 92, 246, 0.55);
  background: rgba(139, 92, 246, 0.18);
}

.cabin-shell--embed .char-avatar {
  width: 28px;
  height: 28px;
  font-size: 0.7rem;
}

.cabin-shell--embed .char-card .text-xs.text-violet-glow\/90,
.cabin-shell--embed .char-card .text-xs.text-gray-500 {
  display: none;
}

.cabin-shell--embed .char-card .min-w-0 > :not(:first-child) {
  display: none;
}

.cabin-shell--embed .char-card .font-semibold {
  font-size: 0.8rem;
  white-space: nowrap;
}

.cabin-shell--embed .cabin-sidebar-backdrop {
  display: none !important;
}

.cabin-shell--embed .cabin-main {
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.cabin-shell--embed .chat-scroll {
  padding: 0.85rem 1rem;
}

.cabin-shell--embed .chat-scroll .py-12,
.cabin-shell--embed .chat-scroll .py-16 {
  padding-top: 1.25rem !important;
  padding-bottom: 1.25rem !important;
}

.cabin-shell--embed .chat-composer {
  padding: 0.65rem 0.75rem 0.75rem;
}

.cabin-shell--embed #btn-sidebar {
  display: none !important;
}

.cabin-shell--embed > #cabin-lock,
.cabin-shell--embed > .cabin-lock,
.cabin-lock {
  position: absolute;
  inset: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  text-align: center;
  background: rgba(11, 15, 25, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  width: 100%;
  height: 100%;
  margin: 0;
}

.cabin-shell--embed > #cabin-lock,
.cabin-shell--embed > .cabin-lock {
  grid-row: 1 / -1;
  grid-column: 1 / -1;
}

.cabin-lock[hidden] {
  display: none !important;
}

.cabin-lock-inner {
  max-width: 320px;
  padding: 1.15rem 1.1rem;
  border-radius: 1rem;
  border: 1px solid rgba(139, 92, 246, 0.35);
  background: rgba(21, 28, 44, 0.95);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
}

.cabin-lock-inner h2 {
  font-family: 'Space Grotesk', Inter, sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 0.4rem;
}

.cabin-lock-inner p {
  font-size: 0.82rem;
  color: #9CA3AF;
  line-height: 1.5;
  margin: 0 0 1rem;
}

.cabin-lock-actions {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.cabin-lock-actions .btn-primary,
.cabin-lock-actions button {
  padding: 0.65rem 1.15rem;
  font-size: 0.875rem;
}

.hero-cabin {
  position: relative;
  width: 100%;
  max-width: 42rem;
  margin-left: auto;
  margin-right: auto;
}

.hero-cabin-glow {
  position: absolute;
  inset: -6% -3%;
  background: radial-gradient(ellipse at 50% 40%, rgba(139, 92, 246, 0.2), transparent 65%);
  pointer-events: none;
  z-index: 0;
}

.hero-cabin .cabin-shell--embed {
  position: relative;
  z-index: 1;
}

@media (max-width: 640px) {
  .cabin-shell--embed {
    height: 380px;
    border-radius: 1rem;
  }

  .cabin-shell--embed > header {
    padding-left: 0.65rem;
    padding-right: 0.65rem;
  }

  .cabin-lock {
    padding: 0.75rem;
    align-items: flex-end;
    padding-bottom: 1rem;
  }

  .cabin-lock-inner {
    max-width: 100%;
    width: 100%;
  }

  .cabin-lock-actions {
    flex-direction: column;
  }

  .cabin-lock-actions button {
    width: 100%;
  }
}

@media (max-width: 400px) {
  .cabin-shell--embed {
    height: 360px;
  }
}
/* build 1784215794 */
