:root {
  /* Theme colors - easy to customize */
  --bg-primary: #0f0f1a;
  --bg-secondary: #1a1a2e;
  --bg-tertiary: #252540;
  --accent: #ff9ecd;
  --accent-glow: rgba(255, 158, 205, 0.3);
  --text-primary: #f0f0f5;
  --text-secondary: #a0a0b0;
  --success: #7ee787;
  --danger: #ff6b6b;
  --border: rgba(255, 255, 255, 0.08);
  --radius: 16px;
  --radius-sm: 10px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  overflow: hidden;
}

.app {
  display: flex;
  flex-direction: column;
  height: 100vh;
}

/* Header */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
}

.logo {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.5px;
  background: linear-gradient(135deg, var(--accent), #c9a0ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-secondary);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-secondary);
  transition: background 0.3s;
}

.status-dot.live {
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
  animation: pulse 2s infinite;
}

.status-dot.offline {
  background: var(--danger);
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* Main layout */
.main {
  display: flex;
  flex: 1;
  overflow: hidden;
}

/* Video section */
.video-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 20px;
  min-width: 0;
}

.video-wrapper {
  position: relative;
  flex: 1;
  background: var(--bg-secondary);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}

.video-wrapper video {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.video-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  transition: opacity 0.5s;
}

.video-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

.offline-message {
  text-align: center;
  color: var(--text-secondary);
}

.offline-icon {
  font-size: 48px;
  display: block;
  margin-bottom: 12px;
}

.offline-message p:first-of-type {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.offline-sub {
  font-size: 14px;
}

/* Chat section */
.chat-section {
  width: 380px;
  display: flex;
  flex-direction: column;
  background: var(--bg-secondary);
  border-left: 1px solid var(--border);
}

.chat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  font-weight: 600;
  font-size: 14px;
}

.chat-count {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 400;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chat-messages::-webkit-scrollbar {
  width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
  background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
  background: var(--bg-tertiary);
  border-radius: 3px;
}

.message {
  animation: messageIn 0.2s ease-out;
}

@keyframes messageIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.message-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.message-username {
  font-weight: 700;
  font-size: 13px;
  color: var(--accent);
}

.message-time {
  font-size: 11px;
  color: var(--text-secondary);
}

.message-text {
  font-size: 14px;
  line-height: 1.4;
  color: var(--text-primary);
  word-wrap: break-word;
}

.system-message {
  text-align: center;
  color: var(--text-secondary);
  font-size: 12px;
  font-style: italic;
  padding: 8px 0;
}

/* Chat input */
.chat-input-area {
  padding: 16px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.chat-input-area input {
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}

.chat-input-area input:focus {
  border-color: var(--accent);
}

.chat-input-area input::placeholder {
  color: var(--text-secondary);
}

.message-row {
  display: flex;
  gap: 8px;
}

#message-input {
  flex: 1;
}

#send-btn {
  background: var(--accent);
  color: var(--bg-primary);
  border: none;
  border-radius: var(--radius-sm);
  padding: 10px 20px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.1s, box-shadow 0.2s;
}

#send-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px var(--accent-glow);
}

#send-btn:active {
  transform: translateY(0);
}

/* Mobile responsive */
@media (max-width: 900px) {
  .main {
    flex-direction: column;
  }

  .chat-section {
    width: 100%;
    height: 40vh;
    border-left: none;
    border-top: 1px solid var(--border);
  }
}

/* ─── CONSENT OVERLAY ─── */

.consent-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 15, 26, 0.92);
  backdrop-filter: blur(12px);
  z-index: 50;
  transition: opacity 0.5s ease;
}

.consent-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

.consent-card {
  text-align: center;
  padding: 40px;
  border-radius: var(--radius);
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  max-width: 320px;
  animation: cardPop 0.5s ease-out;
}

@keyframes cardPop {
  from {
    opacity: 0;
    transform: scale(0.9) translateY(20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.consent-bunny {
  font-size: 48px;
  margin-bottom: 16px;
  animation: bunnyBounce 2s ease infinite;
}

@keyframes bunnyBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.consent-card h2 {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 8px;
  background: linear-gradient(135deg, var(--accent), #c9a0ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.consent-card p {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 24px;
}

.consent-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, var(--accent), #c9a0ff);
  color: var(--bg-primary);
  border: none;
  border-radius: var(--radius-sm);
  padding: 14px 32px;
  font-weight: 800;
  font-size: 16px;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.3s;
  font-family: inherit;
}

.consent-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px var(--accent-glow);
}

.consent-btn:active {
  transform: translateY(0);
}

.btn-icon {
  font-size: 14px;
}

.consent-note {
  margin-top: 16px !important;
  font-size: 11px !important;
  color: rgba(255, 255, 255, 0.3) !important;
}
