/* ── Soulspace Public CSS ──────────────────────────────────────────────── */
:root {
  --ss-primary:    #7c6fcd;
  --ss-primary-d:  #6659b8;
  --ss-accent:     #f9a8d4;
  --ss-bg:         #faf5ff;
  --ss-surface:    #ffffff;
  --ss-border:     #e9d5ff;
  --ss-text:       #1e1b4b;
  --ss-muted:      #7c7c9a;
  --ss-radius:     14px;
  --ss-shadow:     0 4px 24px rgba(124,111,205,.12);
}

/* ── Auth (login / register) ───────────────────────────────────────────── */
.ss-auth-wrapper {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--ss-bg);
}
.ss-auth-card {
  background: var(--ss-surface);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius);
  padding: 40px 36px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--ss-shadow);
  text-align: center;
}
.ss-auth-logo { font-size: 2.5rem; margin-bottom: 8px; }
.ss-auth-card h2 { color: var(--ss-text); margin: 0 0 8px; font-size: 1.4rem; }
.ss-auth-subtitle { color: var(--ss-muted); font-size: .9rem; margin-bottom: 24px; }
.ss-auth-card label {
  display: block;
  text-align: left;
  font-size: .85rem;
  font-weight: 600;
  color: var(--ss-text);
  margin: 16px 0 4px;
}
.ss-auth-card input {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--ss-border);
  border-radius: 8px;
  font-size: .95rem;
  color: var(--ss-text);
  background: #fff;
  box-sizing: border-box;
  transition: border-color .2s;
}
.ss-auth-card input:focus { outline: none; border-color: var(--ss-primary); }
.ss-auth-error {
  background: #fef2f2;
  border: 1px solid #fca5a5;
  color: #b91c1c;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: .88rem;
  margin-bottom: 12px;
}
.ss-auth-success {
  background: #f0fdf4;
  border: 1px solid #86efac;
  color: #166534;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: .88rem;
  margin-bottom: 12px;
}
.ss-forgot-link {
  margin-top: 14px;
  text-align: center;
}
.ss-link-btn {
  background: none;
  border: none;
  color: var(--ss-primary);
  font-size: .88rem;
  cursor: pointer;
  text-decoration: underline;
  padding: 0;
  font-family: inherit;
}
.ss-link-btn:hover { color: var(--ss-primary-d); }

/* ── Chat wrapper ──────────────────────────────────────────────────────── */
.ss-chat-wrapper {
  display: flex;
  flex-direction: column;
  height: 600px;
  max-width: 680px;
  margin: 0 auto;
  border-radius: var(--ss-radius);
  border: 1px solid var(--ss-border);
  box-shadow: var(--ss-shadow);
  background: var(--ss-surface);
  overflow: hidden;
}
.ss-chat-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: var(--ss-primary);
  color: #fff;
}
.ss-chat-avatar { font-size: 1.6rem; }
.ss-chat-header h3 { margin: 0; font-size: 1rem; }
.ss-online-dot { font-size: .78rem; opacity: .85; }

.ss-chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--ss-bg);
}

/* ── Mesaj bubble ──────────────────────────────────────────────────────── */
.ss-msg-bubble {
  max-width: 78%;
  padding: 10px 14px;
  border-radius: 16px;
  font-size: .93rem;
  line-height: 1.5;
}
.ss-msg-bubble.ss-user {
  align-self: flex-end;
  background: var(--ss-primary);
  color: #fff;
  border-bottom-right-radius: 4px;
}
.ss-msg-bubble.ss-assistant {
  align-self: flex-start;
  background: var(--ss-surface);
  color: var(--ss-text);
  border: 1px solid var(--ss-border);
  border-bottom-left-radius: 4px;
}
.ss-msg-label {
  display: block;
  font-size: .75rem;
  font-weight: 600;
  opacity: .7;
  margin-bottom: 4px;
}
.ss-msg-bubble p { margin: 0; }

/* ── Typing indicator ──────────────────────────────────────────────────── */
.ss-dots { display: flex; gap: 4px; padding: 6px 2px; }
.ss-dots span {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--ss-primary);
  animation: ss-bounce .9s infinite;
}
.ss-dots span:nth-child(2) { animation-delay: .15s; }
.ss-dots span:nth-child(3) { animation-delay: .3s; }
@keyframes ss-bounce {
  0%, 60%, 100% { transform: translateY(0); }
  30% { transform: translateY(-6px); }
}

/* ── Chat input ────────────────────────────────────────────────────────── */
.ss-chat-input-area {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--ss-border);
  background: var(--ss-surface);
}
.ss-chat-input-area textarea {
  flex: 1;
  border: 1.5px solid var(--ss-border);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: .93rem;
  resize: none;
  font-family: inherit;
  color: var(--ss-text);
  line-height: 1.4;
  transition: border-color .2s;
}
.ss-chat-input-area textarea:focus { outline: none; border-color: var(--ss-primary); }
.ss-send-btn {
  width: 42px; height: 42px;
  border-radius: 50%;
  border: none;
  background: var(--ss-primary);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s;
  flex-shrink: 0;
}
.ss-send-btn:hover { background: var(--ss-primary-d); }

.ss-disclaimer {
  padding: 8px 16px;
  font-size: .75rem;
  color: var(--ss-muted);
  text-align: center;
  border-top: 1px solid var(--ss-border);
  margin: 0;
}

/* ── Profile ───────────────────────────────────────────────────────────── */
.ss-profile-wrapper {
  display: flex;
  justify-content: center;
  padding: 40px 20px;
}
.ss-profile-card {
  background: var(--ss-surface);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius);
  padding: 40px;
  text-align: center;
  max-width: 380px;
  width: 100%;
  box-shadow: var(--ss-shadow);
}
.ss-profile-avatar {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: var(--ss-primary);
  color: #fff;
  font-size: 1.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}
.ss-profile-stats {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin: 20px 0;
}
.ss-stat { display: flex; flex-direction: column; align-items: center; }
.ss-stat-value { font-size: 1.6rem; font-weight: 700; color: var(--ss-primary); }
.ss-stat-label { font-size: .8rem; color: var(--ss-muted); }
.ss-profile-actions { display: flex; flex-direction: column; gap: 10px; margin-top: 24px; }

/* ── Buttons (public) ──────────────────────────────────────────────────── */
.ss-btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: .93rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  border: none;
  transition: background .2s;
}
.ss-btn-primary { background: var(--ss-primary); color: #fff; }
.ss-btn-primary:hover { background: var(--ss-primary-d); color: #fff; }
.ss-btn-ghost {
  background: transparent;
  color: var(--ss-primary);
  border: 1.5px solid var(--ss-border);
}
.ss-btn-ghost:hover { background: var(--ss-bg); }
.ss-btn-full { width: 100%; box-sizing: border-box; margin-top: 20px; }

/* ── Notice ────────────────────────────────────────────────────────────── */
.ss-public-notice {
  padding: 20px;
  background: var(--ss-bg);
  border: 1px solid var(--ss-border);
  border-radius: var(--ss-radius);
  text-align: center;
  color: var(--ss-muted);
}
.ss-public-notice a { color: var(--ss-primary); }
