/* ============================================================
   Bilder — Design System
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700;800&family=Space+Grotesk:wght@500;600;700&display=swap');

:root {
  --bg: #0b0b0d;
  --bg-soft: #141417;
  --bg-elevated: #1a1a1f;
  --border: #26262c;
  --border-strong: #3a3a42;
  --text: #f4e9ee;
  --text-soft: #c9c2c8;
  --text-muted: #8f8a92;
  --accent: #f41e45;
  --accent-strong: #d61a3c;
  --accent-soft: rgba(244,30,69,.14);
  --accent-contrast: #ffffff;
  --accent-2: #e158ab;
  --success: #34d399;
  --success-soft: rgba(52,211,153,.14);
  --danger: #f87171;
  --danger-soft: rgba(248,113,113,.14);
  --warning: #fbbf24;
  --warning-soft: rgba(251,191,36,.14);
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 18px;
  --radius-full: 999px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.4);
  --shadow: 0 4px 20px rgba(0,0,0,.45);
  --shadow-lg: 0 12px 48px rgba(0,0,0,.55);
  --font: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Space Grotesk", "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --maxw: 1180px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 { font-family: var(--font-display); }

img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font-family: inherit; cursor: pointer; }
input, textarea, select { font-family: inherit; font-size: 15px; }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background .15s, border-color .15s, transform .05s, box-shadow .15s;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn svg { flex-shrink: 0; }

.btn-primary {
  background: var(--accent);
  color: var(--accent-contrast);
}
.btn-primary:hover { background: var(--accent-strong); text-decoration: none; }

.btn-outline {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text);
}
.btn-outline:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }

.btn-ghost {
  background: transparent;
  color: var(--text-soft);
}
.btn-ghost:hover { background: var(--bg-soft); color: var(--text); text-decoration: none; }

.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #b91c1c; text-decoration: none; }

.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { background: #15803d; text-decoration: none; }

.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-lg { padding: 14px 26px; font-size: 16px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .55; cursor: not-allowed; }

/* ---------- Icon button ---------- */
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  border: none;
  background: transparent;
  color: var(--text-soft);
  transition: background .15s, color .15s;
  position: relative;
}
.icon-btn:hover { background: var(--bg-soft); color: var(--text); }

/* ---------- Avatar ---------- */
.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #fff;
  font-weight: 700;
  flex-shrink: 0;
  user-select: none;
  letter-spacing: .5px;
}

/* ---------- Brand ---------- */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}
.brand:hover { text-decoration: none; }
.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-weight: 800;
  font-size: 18px;
}
.brand-name { font-size: 20px; font-weight: 800; letter-spacing: -.5px; }

/* ---------- Header ---------- */
.site-header, .app-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11,11,13,.82);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
}
.header-nav, .header-actions { display: flex; align-items: center; gap: 10px; }
.avatar-link { display: inline-flex; border-radius: 50%; }
.avatar-link:hover { text-decoration: none; }

.notif-btn { position: relative; }
.notif-dot {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: var(--radius-full);
  background: var(--danger);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ---------- Bottom nav (mobile) ---------- */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  background: rgba(11,11,13,.95);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
}
.bottom-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 9px 0 10px;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  text-decoration: none;
}
.bottom-nav-item:hover { text-decoration: none; color: var(--text); }
.bottom-nav-item.is-active { color: var(--accent); }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-soft);
  padding: 48px 0 24px;
  margin-top: 60px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
}
.footer-brand p { color: var(--text-soft); font-size: 14px; margin: 10px 0 4px; }
.footer-count { color: var(--text-muted) !important; }
.footer-col h4 { margin: 0 0 12px; font-size: 14px; }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: 8px; }
.footer-col a { color: var(--text-soft); font-size: 14px; }
.footer-col a:hover { color: var(--accent); }
.footer-bottom { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--border); }
.footer-bottom p { color: var(--text-muted); font-size: 13px; margin: 0; }

/* ---------- Flash ---------- */
.flash {
  padding: 12px 16px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  font-size: 14px;
  font-weight: 500;
}
.flash-success { background: var(--success-soft); color: var(--success); border: 1px solid rgba(52,211,153,.3); }
.flash-error { background: var(--danger-soft); color: var(--danger); border: 1px solid rgba(248,113,113,.3); }

/* ---------- Hero ---------- */
.hero {
  padding: 72px 0 56px;
  text-align: center;
  background:
    radial-gradient(60% 60% at 20% 10%, rgba(244,30,69,.14), transparent 60%),
    radial-gradient(50% 50% at 85% 20%, rgba(225,88,171,.12), transparent 60%);
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 20px;
}
.hero h1 {
  font-size: clamp(34px, 6vw, 60px);
  line-height: 1.08;
  letter-spacing: -1.5px;
  margin: 0 auto 18px;
  max-width: 760px;
}
.hero p.lead {
  font-size: 19px;
  color: var(--text-soft);
  max-width: 620px;
  margin: 0 auto 30px;
}
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-stats {
  display: flex;
  gap: 48px;
  justify-content: center;
  margin-top: 48px;
  flex-wrap: wrap;
}
.hero-stats dt { font-size: 30px; font-weight: 800; letter-spacing: -1px; }
.hero-stats dd { margin: 2px 0 0; color: var(--text-muted); font-size: 14px; }

/* ---------- Hero split (Startseite) ---------- */
.hero-split { text-align: left; padding: 56px 0 64px; }
.hero-split-inner {
  display: grid;
  grid-template-columns: minmax(0, 420px) 1fr;
  gap: 48px;
  align-items: center;
}
.hero-media { display: flex; justify-content: center; }
.hero-photo-frame {
  position: relative;
  width: 100%;
  max-width: 380px;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 20px 60px rgba(0,0,0,.45);
}
.hero-photo {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}
.hero-photo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--bg-elevated), var(--bg-soft));
}
.hero-photo-placeholder .avatar {
  font-size: 44px;
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
}
.hero-photo-badge {
  position: absolute;
  bottom: 14px;
  left: 14px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  background: rgba(11,11,13,.75);
  backdrop-filter: blur(6px);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  border: 1px solid var(--border-strong);
}
.hero-content h1 { text-align: left; margin-left: 0; }
.hero-content p.lead { text-align: left; margin-left: 0; }
.hero-content .hero-actions { justify-content: flex-start; }
.hero-content .hero-stats { justify-content: flex-start; }

/* ---------- Action cards (Galerie / Live-Chat / Live-Call) ---------- */
.action-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.action-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 28px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: var(--text);
  transition: transform .15s, border-color .15s, box-shadow .15s;
}
.action-card:hover {
  transform: translateY(-3px);
  border-color: var(--accent);
  box-shadow: 0 12px 30px rgba(244,30,69,.12);
  text-decoration: none;
  color: var(--text);
}
.action-icon {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 6px;
}
.action-card h3 { margin: 0; font-size: 20px; }
.action-card p { margin: 0; color: var(--text-soft); font-size: 15px; line-height: 1.5; }
.action-link {
  margin-top: auto;
  padding-top: 8px;
  color: var(--accent);
  font-weight: 600;
  font-size: 14px;
}

/* ---------- About section (Startseite) ---------- */
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
}
.about-media { position: relative; padding-bottom: 40px; }
.about-img {
  border-radius: 20px;
  border: 1px solid var(--border);
  object-fit: cover;
  box-shadow: 0 16px 40px rgba(0,0,0,.35);
}
.about-img-main {
  width: 78%;
  aspect-ratio: 4 / 5;
  display: block;
}
.about-img-secondary {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 46%;
  aspect-ratio: 1 / 1;
  border: 4px solid var(--bg-soft);
}
.about-content h2 { font-size: 32px; letter-spacing: -1px; margin: 12px 0 16px; }
.about-content p { color: var(--text-soft); font-size: 16px; line-height: 1.7; margin: 0 0 14px; }
.about-list {
  list-style: none;
  padding: 0;
  margin: 18px 0 24px;
  display: grid;
  gap: 10px;
}
.about-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-soft);
  font-size: 15px;
}
.about-list li::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}
.about-list strong { color: var(--text); }

/* ---------- Section ---------- */
.section { padding: 40px 0; }
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}
.section-head h2 { font-size: 26px; letter-spacing: -.5px; margin: 0; }
.section-head p { color: var(--text-soft); margin: 4px 0 0; }

/* ---------- Cards ---------- */
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

/* Creator card */
.creator-card { padding: 22px; }
.creator-card-top { display: flex; align-items: center; gap: 14px; }
.creator-card-name { display: flex; align-items: center; gap: 6px; }
.creator-card-name h3 { margin: 0; font-size: 17px; }
.creator-card-name h3 a { color: var(--text); }
.creator-card-name h3 a:hover { color: var(--accent); }
.verified {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  flex-shrink: 0;
}
.creator-handle { color: var(--text-muted); font-size: 14px; margin: 4px 0 10px; }
.creator-bio { color: var(--text-soft); font-size: 14px; margin: 0 0 14px; min-height: 42px; }
.creator-meta { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.category-pill {
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: var(--bg-soft);
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 600;
}
.followers-count { color: var(--text-muted); font-size: 13px; }

/* Post card */
.post-card { padding: 20px; }
.post-head { display: flex; align-items: center; gap: 12px; }
.post-head-meta { flex: 1; min-width: 0; }
.post-head-name { display: flex; align-items: center; gap: 6px; font-weight: 700; }
.post-head-name a { color: var(--text); }
.post-head-name a:hover { color: var(--accent); }
.post-head-sub { margin: 0; color: var(--text-muted); font-size: 13px; }
.post-body { margin: 14px 0; font-size: 15px; }
.post-media { border-radius: var(--radius); overflow: hidden; margin: 12px 0; position: relative; }
.post-media img { width: 100%; object-fit: cover; max-height: 480px; }
.post-media.is-gallery img { max-height: 340px; }
.gallery-badge, .video-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 30px;
  height: 30px;
  border-radius: var(--radius-full);
  background: rgba(0,0,0,.55);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}
.post-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.tag {
  padding: 3px 10px;
  border-radius: var(--radius-full);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
}
.post-actions { display: flex; gap: 4px; border-top: 1px solid var(--border); padding-top: 12px; }
.action-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border: none;
  background: transparent;
  border-radius: var(--radius-full);
  color: var(--text-soft);
  font-size: 14px;
  font-weight: 600;
  transition: background .15s, color .15s;
}
.action-btn:hover { background: var(--bg-soft); color: var(--text); }
.action-btn.liked { color: var(--danger); }

/* ---------- Feature grid ---------- */
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature {
  padding: 26px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg-elevated);
}
.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}
.feature h3 { margin: 0 0 6px; font-size: 17px; }
.feature p { margin: 0; color: var(--text-soft); font-size: 14px; }

/* ---------- CTA ---------- */
.cta {
  text-align: center;
  padding: 64px 20px;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  margin: 40px 0;
}
.cta h2 { font-size: 32px; letter-spacing: -1px; margin: 0 0 10px; }
.cta p { opacity: .9; margin: 0 0 24px; font-size: 17px; }
.cta .btn-primary { background: #fff; color: var(--accent); }
.cta .btn-primary:hover { background: #f3f4f6; }

/* ---------- Auth ---------- */
.auth-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  background:
    radial-gradient(50% 50% at 15% 10%, rgba(244,30,69,.14), transparent 60%),
    radial-gradient(50% 50% at 90% 90%, rgba(225,88,171,.12), transparent 60%);
}
.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow);
}
.auth-card .brand { margin-bottom: 24px; }
.auth-card h1 { font-size: 24px; margin: 0 0 6px; letter-spacing: -.5px; }
.auth-card .sub { color: var(--text-soft); margin: 0 0 24px; font-size: 14px; }

/* ---------- Forms ---------- */
.form-group { margin-bottom: 16px; }
.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text);
}
.form-control {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--bg-elevated);
  color: var(--text);
  transition: border-color .15s, box-shadow .15s;
}
.form-control:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(244,30,69,.18);
}
textarea.form-control { resize: vertical; min-height: 90px; }
select.form-control { appearance: auto; }
.form-control-sm { padding: 6px 10px; font-size: 13px; border-radius: var(--radius-sm); }
.form-hint { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.form-error { font-size: 13px; color: var(--danger); margin-top: 4px; }
.form-check { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.form-check input { width: 16px; height: 16px; accent-color: var(--accent); }

/* ---------- Layout (app) ---------- */
.app-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 28px;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 28px 20px 90px;
}
.sidebar { position: sticky; top: 82px; align-self: start; }
.sidebar-nav { display: flex; flex-direction: column; gap: 2px; }
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--radius);
  color: var(--text-soft);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
}
.sidebar-link:hover { background: var(--bg-soft); color: var(--text); text-decoration: none; }
.sidebar-link.is-active { background: var(--accent-soft); color: var(--accent); }
.sidebar-link svg { flex-shrink: 0; }

.page-title { font-size: 26px; letter-spacing: -.5px; margin: 0 0 4px; }
.page-sub { color: var(--text-soft); margin: 0 0 24px; }

/* ---------- Feed ---------- */
.feed-col { max-width: 640px; margin: 0 auto; }
.composer {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 20px;
}
.composer textarea { border: none; resize: none; min-height: 60px; padding: 0; }
.composer textarea:focus { box-shadow: none; }
.composer-footer { display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--border); padding-top: 12px; margin-top: 8px; }
.composer-tools { display: flex; gap: 4px; }

/* ---------- Profile / creator ---------- */
.profile-hero {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  height: 160px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}
.profile-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 24px;
}
.profile-body { padding: 0 24px 24px; margin-top: -40px; }
.profile-avatar-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.profile-avatar-row .avatar { border: 4px solid var(--bg); }
.profile-name-row { display: flex; align-items: center; gap: 8px; margin-top: 12px; }
.profile-name-row h1 { margin: 0; font-size: 24px; }
.profile-handle { color: var(--text-muted); margin: 2px 0 12px; }
.profile-bio { color: var(--text-soft); margin: 0 0 16px; }
.profile-stats { display: flex; gap: 24px; margin-bottom: 16px; }
.profile-stat b { font-size: 18px; display: block; }
.profile-stat span { color: var(--text-muted); font-size: 13px; }

/* ---------- Messages ---------- */
.messages-layout { display: grid; grid-template-columns: 320px 1fr; height: calc(100vh - 150px); min-height: 480px; border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; background: var(--bg-elevated); }
.conv-list { border-right: 1px solid var(--border); overflow-y: auto; }
.conv-item { display: flex; gap: 12px; padding: 14px 16px; cursor: pointer; border-bottom: 1px solid var(--border); transition: background .15s; }
.conv-item:hover { background: var(--bg-soft); }
.conv-item.is-active { background: var(--accent-soft); }
.conv-item-meta { flex: 1; min-width: 0; }
.conv-item-name { font-weight: 700; font-size: 14px; display: flex; justify-content: space-between; }
.conv-item-time { color: var(--text-muted); font-size: 12px; }
.conv-item-preview { color: var(--text-muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-pane { display: flex; flex-direction: column; }
.chat-header { padding: 14px 18px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; }
.chat-messages { flex: 1; overflow-y: auto; padding: 20px; display: flex; flex-direction: column; gap: 10px; background: var(--bg-soft); }
.msg { max-width: 70%; padding: 10px 14px; border-radius: var(--radius-lg); font-size: 14px; line-height: 1.4; }
.msg-in { align-self: flex-start; background: var(--bg-elevated); border: 1px solid var(--border); border-bottom-left-radius: 4px; }
.msg-out { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.msg-time { display: block; font-size: 11px; opacity: .7; margin-top: 4px; }
.chat-input { display: flex; gap: 10px; padding: 14px; border-top: 1px solid var(--border); background: var(--bg-elevated); }
.chat-input input { flex: 1; }

/* ---------- Plans ---------- */
.plans-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.plan-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 26px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: box-shadow .2s, transform .2s;
}
.plan-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.plan-card.is-featured { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), var(--shadow); }
.plan-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: var(--radius-full);
}
.plan-image { border-radius: var(--radius); overflow: hidden; margin-bottom: 18px; height: 140px; }
.plan-image img { width: 100%; height: 100%; object-fit: cover; }
.plan-type { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--accent); margin-bottom: 6px; }
.plan-name { font-size: 22px; font-weight: 800; margin: 0 0 6px; letter-spacing: -.5px; }
.plan-desc { color: var(--text-soft); font-size: 14px; margin: 0 0 16px; }
.plan-price { font-size: 34px; font-weight: 800; letter-spacing: -1px; margin-bottom: 4px; }
.plan-price small { font-size: 14px; font-weight: 500; color: var(--text-muted); letter-spacing: 0; }
.plan-features { list-style: none; padding: 0; margin: 16px 0 20px; flex: 1; }
.plan-features li { display: flex; gap: 8px; align-items: flex-start; padding: 5px 0; font-size: 14px; color: var(--text-soft); }
.plan-features li svg { color: var(--success); flex-shrink: 0; margin-top: 2px; }

/* ---------- Admin ---------- */
.admin-layout { display: grid; grid-template-columns: 220px 1fr; gap: 28px; max-width: var(--maxw); margin: 0 auto; padding: 28px 20px 60px; }
.admin-sidebar { position: sticky; top: 82px; align-self: start; }
.admin-sidebar h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .5px; color: var(--text-muted); margin: 0 0 10px; padding: 0 14px; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; }
.stat-card .stat-label { color: var(--text-muted); font-size: 13px; }
.stat-card .stat-value { font-size: 28px; font-weight: 800; letter-spacing: -1px; margin-top: 4px; }

/* ---------- Table ---------- */
.table-wrap { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; padding: 12px 16px; background: var(--bg-soft); font-size: 12px; text-transform: uppercase; letter-spacing: .5px; color: var(--text-muted); border-bottom: 1px solid var(--border); }
.table td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table tr:hover td { background: var(--bg-soft); }
.table .actions { display: flex; gap: 6px; justify-content: flex-end; }

/* ---------- Badges ---------- */
.badge { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: var(--radius-full); font-size: 12px; font-weight: 600; }
.badge-green { background: var(--success-soft); color: var(--success); }
.badge-red { background: var(--danger-soft); color: var(--danger); }
.badge-yellow { background: var(--warning-soft); color: var(--warning); }
.badge-purple { background: var(--accent-soft); color: var(--accent); }
.badge-gray { background: var(--bg-soft); color: var(--text-soft); }

/* ---------- Live chat ---------- */
.live-chat-wrap { max-width: 760px; margin: 0 auto; }
.live-chat-card { background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; display: flex; flex-direction: column; height: calc(100vh - 180px); min-height: 480px; }
.live-chat-header { padding: 16px 20px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; }
.live-status-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--success); animation: pulse 1.5s infinite; }
.live-status-dot.offline { background: var(--text-muted); animation: none; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .4; } }
.live-messages { flex: 1; overflow-y: auto; padding: 20px; display: flex; flex-direction: column; gap: 10px; background: var(--bg-soft); }
.live-input { display: flex; gap: 10px; padding: 14px; border-top: 1px solid var(--border); }
.live-input input { flex: 1; }
.live-timer { font-size: 13px; color: var(--text-muted); font-weight: 600; }

/* ---------- Misc ---------- */
.empty-state { text-align: center; padding: 60px 20px; color: var(--text-muted); }
.empty-state svg { margin-bottom: 12px; opacity: .4; }
.empty-state h3 { color: var(--text); margin: 0 0 6px; }
.muted { color: var(--text-muted); }
.soft { color: var(--text-soft); }
.small { font-size: 13px; }
.mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; } .mb-2 { margin-bottom: 16px; } .mb-3 { margin-bottom: 24px; }
.flex { display: flex; } .flex-between { display: flex; justify-content: space-between; align-items: center; }
.gap-2 { gap: 16px; } .gap-1 { gap: 8px; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.align-center { align-items: center; }
.divider { border: none; border-top: 1px solid var(--border); margin: 20px 0; }

/* ---------- Page head ---------- */
.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.page-head h1 { font-size: 28px; letter-spacing: -.5px; margin: 0; }
.page-head p { margin: 4px 0 0; }

/* ---------- App main ---------- */
.app-main { padding: 28px 0 90px; }

/* ---------- Token pill (header balance) ---------- */
.token-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  border: 1px solid transparent;
  transition: border-color .15s, background .15s;
}
.token-pill:hover { border-color: var(--accent); text-decoration: none; }
.token-pill svg { flex-shrink: 0; }

/* ---------- Photo / gallery card ---------- */
.photo-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow .2s, transform .2s;
}
.photo-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.photo-media { position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: var(--bg-soft); }
.photo-media > img { width: 100%; height: 100%; object-fit: cover; }
.photo-blur { position: absolute; inset: 0; }
.photo-blur img { width: 100%; height: 100%; object-fit: cover; filter: blur(18px) brightness(.7); transform: scale(1.1); }
.photo-lock-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 20px;
  text-align: center;
  color: #fff;
  background: rgba(0,0,0,.35);
}
.photo-lock-overlay svg { opacity: .9; }
.photo-lock-price {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -.3px;
  background: rgba(0,0,0,.45);
  padding: 6px 14px;
  border-radius: var(--radius-full);
}
.photo-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.photo-title { font-size: 16px; font-weight: 700; margin: 0; letter-spacing: -.2px; }
.photo-desc { color: var(--text-soft); font-size: 14px; margin: 0; }
.photo-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: auto;
  padding-top: 10px;
  font-size: 13px;
  color: var(--text-muted);
}
.photo-time { }
.photo-views { display: inline-flex; align-items: center; gap: 4px; }
.photo-locked-label {
  margin-left: auto;
  padding: 2px 10px;
  border-radius: var(--radius-full);
  background: var(--warning-soft);
  color: var(--warning);
  font-size: 11px;
  font-weight: 700;
}
.photo-unlocked-label {
  margin-left: auto;
  padding: 2px 10px;
  border-radius: var(--radius-full);
  background: var(--success-soft);
  color: var(--success);
  font-size: 11px;
  font-weight: 700;
}

/* ---------- Creator profile card ---------- */
.creator-profile-wrap { max-width: 560px; margin: 0 auto; }
.creator-profile-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-sm);
}
.creator-profile-top { display: flex; align-items: center; gap: 16px; }
.creator-profile-name h2 { margin: 0; font-size: 22px; display: flex; align-items: center; gap: 8px; }
.creator-profile-name .creator-handle { margin: 2px 0 0; }
.creator-profile-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }

/* ---------- Token amount (plans + chat lock) ---------- */
.token-amount {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 6px;
  margin: 6px 0;
}
.token-count { font-size: 44px; font-weight: 800; letter-spacing: -2px; line-height: 1; }
.token-unit { font-size: 15px; font-weight: 600; color: var(--text-muted); }
.token-bonus {
  display: inline-block;
  align-self: center;
  padding: 3px 12px;
  border-radius: var(--radius-full);
  background: var(--success-soft);
  color: var(--success);
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 8px;
}

/* ---------- Chat lock overlay ---------- */
.chat-lock {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 40px 24px;
  text-align: center;
  background: var(--bg-soft);
}
.chat-lock-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
}
.chat-lock h3 { margin: 0; font-size: 20px; }
.chat-lock p { color: var(--text-soft); margin: 0 0 6px; max-width: 360px; }
.chat-lock .token-amount {
  font-size: 22px;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 8px;
}

/* ---------- Filter / search / inline forms ---------- */
.filter-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.search-bar { display: flex; gap: 8px; margin-bottom: 20px; }
.search-bar .form-control { flex: 1; }
.inline-form { display: inline; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .grid-3, .grid-4, .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .app-layout { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .admin-layout { grid-template-columns: 1fr; }
  /* Admin-Navigation wird auf schmalen Screens zu einer horizontal scrollbaren Leiste */
  .admin-sidebar {
    position: static;
    margin-bottom: 4px;
  }
  .admin-sidebar h3 { display: none; }
  .admin-sidebar .sidebar-nav {
    flex-direction: row;
    overflow-x: auto;
    gap: 8px;
    padding: 2px 2px 10px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
  }
  .admin-sidebar .sidebar-link {
    flex-shrink: 0;
    white-space: nowrap;
    padding: 9px 14px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    font-size: 14px;
  }
  .admin-sidebar .sidebar-link.is-active { background: var(--accent-soft); border-color: var(--accent); }
  .messages-layout { grid-template-columns: 1fr; }
  .conv-list { display: none; }
  .hero-split-inner { grid-template-columns: 1fr; gap: 32px; }
  .hero-media { order: -1; }
  .hero-photo-frame { max-width: 320px; }
  .hero-split { text-align: center; }
  .hero-content h1, .hero-content p.lead { text-align: center; margin-left: auto; margin-right: auto; }
  .hero-content .hero-actions, .hero-content .hero-stats { justify-content: center; }
  .action-grid { grid-template-columns: repeat(3, 1fr); }
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-media { max-width: 480px; margin: 0 auto; }
}
@media (max-width: 600px) {
  .grid-2, .grid-3, .grid-4, .feature-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero { padding: 48px 0 40px; }
  .hero-stats { gap: 24px; }
  .auth-card { padding: 26px; }
  .bottom-nav { display: flex; }
  .app-layout { padding-bottom: 80px; }
  .page-head { flex-direction: column; align-items: flex-start; }
  .creator-profile-top { flex-direction: column; align-items: flex-start; }
  .photo-media { aspect-ratio: 1 / 1; }
  .action-grid { grid-template-columns: 1fr; }
  .action-card { flex-direction: row; align-items: center; padding: 20px; }
  .action-icon { margin-bottom: 0; }
  .action-card h3 { font-size: 18px; }
  .action-card p { display: none; }
  .action-link { margin-top: 0; padding-top: 0; margin-left: auto; }
  .about-media { padding-bottom: 30px; }
  .about-img-main { width: 82%; }
  .about-img-secondary { width: 50%; }

  /* Admin: Tabellen horizontal scrollbar machen, damit nichts abgeschnitten wird */
  .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .table-wrap .table { min-width: 620px; }
  .table .actions { flex-wrap: wrap; }

  /* Admin: Karten & Formulare kompakter */
  .admin-layout { padding: 20px 14px 60px; gap: 16px; }
  .admin-layout .card { padding: 18px !important; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .stat-card { padding: 16px; }
  .stat-card .stat-value { font-size: 24px; }
  .page-title { font-size: 22px; }
  .filter-bar, .search-bar { flex-direction: column; align-items: stretch; }
  .filter-bar .form-control, .search-bar .form-control { width: 100%; }
  .filter-bar .btn, .search-bar .btn { width: 100%; }
  .flex-between { flex-direction: column; align-items: flex-start; gap: 12px; }
  .flex-between .btn { width: 100%; }

  /* Admin-Header kompakt */
  .header-inner { height: 56px; }
  .header-actions { gap: 6px; }
  .header-actions .btn { padding: 6px 10px; font-size: 12px; }
}
@media (min-width: 601px) {
  .bottom-nav { display: none; }
}

/* ===== Live-Call (WebRTC) UI ===== */
.call-card { background: #000; }
.call-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  background: #000;
  overflow: hidden;
}
.call-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #000;
}
.call-video-remote { display: block; }
.call-video-local {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 30%;
  max-width: 180px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 12px;
  border: 2px solid rgba(255,255,255,0.25);
  background: #111;
  z-index: 5;
  box-shadow: 0 4px 16px rgba(0,0,0,0.5);
}
/* Status-Overlay */
.call-status {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
  background: linear-gradient(180deg, rgba(0,0,0,0.55), rgba(0,0,0,0.75));
  z-index: 3;
  padding: 20px;
}
.call-status-icon { font-size: 56px; margin-bottom: 12px; }
.call-status-title { font-size: 20px; font-weight: 700; margin-bottom: 6px; }
.call-status-sub { font-size: 14px; opacity: 0.8; }
.call-timer {
  margin-top: 14px;
  font-size: 18px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  background: rgba(255,255,255,0.12);
  padding: 6px 16px;
  border-radius: 999px;
}
/* Steuerleiste */
.call-controls {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  justify-content: center;
  gap: 14px;
  padding: 16px;
  background: linear-gradient(0deg, rgba(0,0,0,0.7), transparent);
  z-index: 6;
}
.call-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.18);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}
.call-btn:hover { background: rgba(255,255,255,0.3); }
.call-btn:active { transform: scale(0.94); }
.call-btn-off { background: var(--accent); }
.call-btn-hangup { background: #e02424; }
.call-btn-hangup:hover { background: #c01f1f; }
/* Timer in der Steuerleiste (sichtbar, wenn das Status-Overlay ausgeblendet ist) */
#callTimerBar {
  align-self: center;
  font-size: 15px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: #fff;
  background: rgba(255,255,255,0.14);
  padding: 6px 14px;
  border-radius: 999px;
  white-space: nowrap;
}
/* Start-/Antwort-Buttons */
.call-actions {
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--bg-elevated);
}
.call-actions .btn { min-width: 220px; }
@media (max-width: 600px) {
  .call-stage { aspect-ratio: 4 / 3; }
  .call-video-local { width: 34%; }
  .call-status-icon { font-size: 44px; }
  .call-status-title { font-size: 17px; }
}
