/* ============================================
   Committed-Streaming — Frontend Demo CSS
   YouTube風動画配信プラットフォーム
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@300;400;500;600;700&display=swap');

:root {
  /* Color Palette */
  --primary: #6366F1;
  --primary-dark: #4F46E5;
  --primary-light: #818CF8;
  --secondary: #10B981;
  --secondary-dark: #059669;
  --accent: #F59E0B;
  --error: #EF4444;
  --live-red: #FF0000;

  /* Dark Theme (Default) */
  --bg-app: #0F0F0F;
  --bg-sidebar: #0F0F0F;
  --bg-surface: #1A1A2E;
  --bg-card: #16213E;
  --bg-card-hover: #1E2A4A;
  --bg-input: #1A1A2E;
  --bg-header: rgba(15, 15, 15, 0.95);

  --text-primary: #E8EAED;
  --text-secondary: #AAAAAA;
  --text-muted: #717171;

  --border: #333333;
  --border-light: #272727;

  /* Spacing */
  --sidebar-width: 240px;
  --header-height: 56px;

  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.5);

  /* Transitions */
  --transition: all 0.2s ease;
  --transition-slow: all 0.3s ease;
}

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

body {
  font-family: 'Noto Sans JP', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-app);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: var(--primary-light); text-decoration: none; }
a:hover { color: var(--primary); }

/* ============ HEADER ============ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: var(--bg-header);
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  z-index: 1000;
  backdrop-filter: blur(12px);
}

.header-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.menu-btn {
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: 8px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  transition: var(--transition);
}
.menu-btn:hover { background: rgba(255,255,255,0.1); }

.logo {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  cursor: pointer;
}
.logo-icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.header-center {
  flex: 1;
  max-width: 640px;
  display: flex;
  align-items: center;
  margin: 0 40px;
}

.search-container {
  display: flex;
  flex: 1;
  border-radius: var(--radius-full);
  overflow: hidden;
}

.search-input {
  flex: 1;
  padding: 8px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-right: none;
  color: var(--text-primary);
  font-size: 14px;
  border-radius: var(--radius-full) 0 0 var(--radius-full);
  outline: none;
  font-family: inherit;
}
.search-input:focus {
  border-color: var(--primary);
}
.search-input::placeholder {
  color: var(--text-muted);
}

.search-btn {
  padding: 0 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-primary);
  cursor: pointer;
  border-radius: 0 var(--radius-full) var(--radius-full) 0;
  display: flex;
  align-items: center;
  transition: var(--transition);
}
.search-btn:hover { background: var(--bg-card-hover); }

.header-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  border: none;
  background: none;
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  position: relative;
  font-size: 18px;
}
.icon-btn:hover { background: rgba(255,255,255,0.1); }

.icon-btn .badge {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: var(--error);
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.upload-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: rgba(255,255,255,0.08);
  border: none;
  color: var(--text-primary);
  border-radius: var(--radius-full);
  cursor: pointer;
  font-size: 14px;
  font-family: inherit;
  transition: var(--transition);
}
.upload-btn:hover { background: rgba(255,255,255,0.15); }

.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--primary), #EC4899);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
}

/* ============ SIDEBAR ============ */
.sidebar {
  position: fixed;
  top: var(--header-height);
  left: 0;
  width: var(--sidebar-width);
  height: calc(100vh - var(--header-height));
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border-light);
  overflow-y: auto;
  padding: 12px 0;
  z-index: 900;
  transition: var(--transition-slow);
}

.sidebar::-webkit-scrollbar { width: 6px; }
.sidebar::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

.sidebar-section { padding: 8px 0; border-bottom: 1px solid var(--border-light); }
.sidebar-section:last-child { border-bottom: none; }

.sidebar-title {
  padding: 8px 24px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.sidebar-item {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 10px 24px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  font-size: 14px;
  border-radius: 0;
}
.sidebar-item:hover {
  background: rgba(255,255,255,0.05);
  color: var(--text-primary);
}
.sidebar-item.active {
  background: rgba(255,255,255,0.08);
  color: var(--text-primary);
  font-weight: 500;
}
.sidebar-item .icon { width: 24px; text-align: center; font-size: 18px; }

/* ============ MAIN CONTENT ============ */
.main-content {
  margin-left: var(--sidebar-width);
  margin-top: var(--header-height);
  padding: 24px;
  min-height: calc(100vh - var(--header-height));
}

/* ============ CATEGORY CHIPS ============ */
.category-chips {
  display: flex;
  gap: 12px;
  padding: 0 0 20px 0;
  overflow-x: auto;
  flex-wrap: nowrap;
}
.category-chips::-webkit-scrollbar { display: none; }

.chip {
  padding: 8px 16px;
  background: rgba(255,255,255,0.1);
  border: none;
  border-radius: var(--radius-full);
  color: var(--text-primary);
  font-size: 13px;
  white-space: nowrap;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}
.chip:hover { background: rgba(255,255,255,0.2); }
.chip.active {
  background: var(--text-primary);
  color: var(--bg-app);
  font-weight: 500;
}

/* ============ VIDEO GRID ============ */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}

.video-card {
  cursor: pointer;
  transition: var(--transition);
  border-radius: var(--radius-lg);
}
.video-card:hover { transform: translateY(-2px); }
.video-card:hover .video-thumbnail img {
  transform: scale(1.03);
}

.video-thumbnail {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16/9;
  background: var(--bg-card);
}
.video-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition-slow);
}

.video-duration {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0,0,0,0.8);
  color: white;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 500;
}
.live-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--live-red);
  color: white;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 4px;
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.viewer-count {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: rgba(0,0,0,0.7);
  color: white;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.video-info {
  display: flex;
  gap: 12px;
  padding: 12px 0;
}
.video-info .channel-avatar {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 14px;
}
.video-info .video-meta h3 {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 4px;
}
.video-info .video-meta .channel-name {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 2px;
}
.video-info .video-meta .channel-name:hover { color: var(--text-primary); }
.video-info .video-meta .video-stats {
  font-size: 13px;
  color: var(--text-muted);
}

/* ============ LIVE STREAMING PAGE ============ */
.live-page {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 24px;
  max-width: 1400px;
}

.player-container {
  background: #000;
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.player-wrapper {
  position: relative;
  aspect-ratio: 16/9;
  background: linear-gradient(135deg, #1a1a2e, #16213e);
  display: flex;
  align-items: center;
  justify-content: center;
}
.player-wrapper .play-overlay {
  width: 68px;
  height: 48px;
  background: rgba(0,0,0,0.7);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  cursor: pointer;
  transition: var(--transition);
}
.player-wrapper .play-overlay:hover { background: var(--primary); }

.player-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  background: rgba(0,0,0,0.9);
}
.player-controls .progress {
  flex: 1;
  height: 4px;
  background: rgba(255,255,255,0.2);
  border-radius: 2px;
  margin: 0 12px;
  position: relative;
  cursor: pointer;
}
.player-controls .progress-bar {
  height: 100%;
  background: var(--live-red);
  border-radius: 2px;
  width: 100%;
}
.player-controls .control-btn {
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  padding: 4px 8px;
  font-size: 16px;
}

.video-details {
  padding: 16px 0;
}
.video-details h1 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 12px;
  line-height: 1.4;
}
.video-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.channel-info {
  display: flex;
  align-items: center;
  gap: 12px;
}
.channel-info .avatar-lg {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 600;
}
.channel-text .name { font-weight: 600; font-size: 15px; }
.channel-text .subs { font-size: 12px; color: var(--text-muted); }

.subscribe-btn {
  padding: 8px 20px;
  background: var(--text-primary);
  color: var(--bg-app);
  border: none;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}
.subscribe-btn:hover { opacity: 0.9; }
.subscribe-btn.subscribed {
  background: rgba(255,255,255,0.1);
  color: var(--text-primary);
}

.action-buttons {
  display: flex;
  gap: 8px;
}
.action-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: rgba(255,255,255,0.1);
  border: none;
  border-radius: var(--radius-full);
  color: var(--text-primary);
  font-size: 13px;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}
.action-btn:hover { background: rgba(255,255,255,0.2); }

/* ============ CHAT PANEL ============ */
.chat-panel {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  height: calc(100vh - var(--header-height) - 48px);
  max-height: 700px;
}
.chat-header {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  font-weight: 600;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.chat-header .live-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--live-red);
  animation: pulse 2s infinite;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
}
.chat-messages::-webkit-scrollbar { width: 4px; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.chat-message {
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  margin-bottom: 2px;
  font-size: 13px;
  line-height: 1.5;
  transition: var(--transition);
}
.chat-message:hover { background: rgba(255,255,255,0.03); }
.chat-message .chat-author {
  font-weight: 600;
  margin-right: 6px;
}
.chat-message .chat-author.streamer { color: var(--primary-light); }
.chat-message .chat-author.member { color: var(--secondary); }

.superchat {
  background: linear-gradient(135deg, rgba(245,158,11,0.15), rgba(245,158,11,0.05));
  border: 1px solid rgba(245,158,11,0.3);
  border-radius: var(--radius-md);
  padding: 8px 12px;
  margin: 6px 0;
}
.superchat .sc-amount {
  color: var(--accent);
  font-weight: 700;
  font-size: 14px;
}

.chat-input-area {
  padding: 12px;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 8px;
}
.chat-input {
  flex: 1;
  padding: 10px 14px;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  font-family: inherit;
}
.chat-input:focus { border-color: var(--primary); }
.chat-send-btn {
  padding: 8px 16px;
  background: var(--primary);
  border: none;
  border-radius: var(--radius-full);
  color: white;
  cursor: pointer;
  font-size: 14px;
  transition: var(--transition);
}
.chat-send-btn:hover { background: var(--primary-dark); }

.chat-actions {
  display: flex;
  gap: 4px;
  padding: 4px 12px 0;
}
.chat-action-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px 8px;
  font-size: 16px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}
.chat-action-btn:hover { color: var(--text-primary); background: rgba(255,255,255,0.05); }

/* ============ DASHBOARD (STUDIO) ============ */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  padding: 20px;
  transition: var(--transition);
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.stat-card .stat-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin-bottom: 12px;
}
.stat-card .stat-icon.blue { background: rgba(99,102,241,0.15); color: var(--primary-light); }
.stat-card .stat-icon.green { background: rgba(16,185,129,0.15); color: var(--secondary); }
.stat-card .stat-icon.amber { background: rgba(245,158,11,0.15); color: var(--accent); }
.stat-card .stat-icon.red { background: rgba(239,68,68,0.15); color: var(--error); }

.stat-card .stat-value {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 4px;
}
.stat-card .stat-label {
  font-size: 13px;
  color: var(--text-secondary);
}
.stat-card .stat-trend {
  font-size: 12px;
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.stat-card .stat-trend.up { color: var(--secondary); }
.stat-card .stat-trend.down { color: var(--error); }

/* ============ TABLE ============ */
.table-container {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.table-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}
.table-header h3 { font-size: 16px; font-weight: 600; }

table {
  width: 100%;
  border-collapse: collapse;
}
th {
  text-align: left;
  padding: 12px 20px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border);
}
td {
  padding: 14px 20px;
  font-size: 14px;
  border-bottom: 1px solid var(--border-light);
}
tr:last-child td { border-bottom: none; }
tr:hover { background: rgba(255,255,255,0.02); }

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 500;
}
.status-badge.live { background: rgba(255,0,0,0.15); color: var(--live-red); }
.status-badge.published { background: rgba(16,185,129,0.15); color: var(--secondary); }
.status-badge.processing { background: rgba(245,158,11,0.15); color: var(--accent); }
.status-badge.draft { background: rgba(255,255,255,0.1); color: var(--text-secondary); }

/* ============ UPLOAD PAGE ============ */
.upload-zone {
  background: var(--bg-surface);
  border: 2px dashed var(--border);
  border-radius: var(--radius-xl);
  padding: 80px 40px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 24px;
}
.upload-zone:hover {
  border-color: var(--primary);
  background: rgba(99,102,241,0.05);
}
.upload-zone .upload-icon {
  font-size: 56px;
  margin-bottom: 16px;
}
.upload-zone h3 {
  font-size: 18px;
  margin-bottom: 8px;
}
.upload-zone p {
  color: var(--text-muted);
  font-size: 14px;
}

.form-group {
  margin-bottom: 20px;
}
.form-group label {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 500;
}
.form-input, .form-textarea, .form-select {
  width: 100%;
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  font-family: inherit;
  transition: var(--transition);
}
.form-input:focus, .form-textarea:focus, .form-select:focus { border-color: var(--primary); }
.form-textarea { min-height: 120px; resize: vertical; }

.btn {
  padding: 10px 24px;
  border: none;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-secondary { background: rgba(255,255,255,0.1); color: var(--text-primary); }
.btn-secondary:hover { background: rgba(255,255,255,0.15); }
.btn-danger { background: var(--error); color: white; }
.btn-danger:hover { background: #DC2626; }
.btn-success { background: var(--secondary); color: white; }
.btn-success:hover { background: var(--secondary-dark); }

/* ============ SETTINGS PAGE ============ */
.settings-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 24px;
}
.settings-nav {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  padding: 12px;
}
.settings-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  cursor: pointer;
  font-size: 14px;
  transition: var(--transition);
  color: var(--text-secondary);
}
.settings-nav-item:hover { background: rgba(255,255,255,0.05); color: var(--text-primary); }
.settings-nav-item.active { background: rgba(99,102,241,0.15); color: var(--primary-light); }

.settings-content {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  padding: 24px;
}
.settings-section { margin-bottom: 32px; }
.settings-section h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

/* ============ ADMIN PANEL ============ */
.admin-charts-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}
.chart-container {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  padding: 20px;
}
.chart-container h4 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 16px;
}
.chart-bar-group {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 160px;
  padding-top: 8px;
}
.chart-bar {
  flex: 1;
  background: linear-gradient(to top, var(--primary), var(--primary-light));
  border-radius: 4px 4px 0 0;
  transition: var(--transition);
  position: relative;
  min-height: 8px;
}
.chart-bar:hover { opacity: 0.8; }
.chart-bar-label {
  text-align: center;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}
.chart-labels {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.donut-chart {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: conic-gradient(
    var(--primary) 0deg 180deg,
    var(--secondary) 180deg 270deg,
    var(--accent) 270deg 360deg
  );
  margin: 0 auto 16px;
  position: relative;
}
.donut-chart::after {
  content: '';
  position: absolute;
  top: 30px;
  left: 30px;
  right: 30px;
  bottom: 30px;
  background: var(--bg-surface);
  border-radius: 50%;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  margin-bottom: 6px;
}
.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

/* ============ PAGE VISIBILITY ============ */
.page { display: none; }
.page.active { display: block; }

/* ============ FADE IN ANIMATION ============ */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.page.active { animation: fadeIn 0.3s ease; }

/* ============ SCROLLBAR ============ */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ============ RESPONSIVE ============ */
@media (max-width: 1400px) {
  .live-page { grid-template-columns: 1fr 340px; }
}
@media (max-width: 1200px) {
  .dashboard-grid { grid-template-columns: repeat(2, 1fr); }
  .admin-charts-grid { grid-template-columns: 1fr; }
}
@media (max-width: 1024px) {
  .live-page { grid-template-columns: 1fr; }
  .chat-panel { max-height: 400px; }
  .sidebar { transform: translateX(-100%); }
  .main-content { margin-left: 0; }
}
@media (max-width: 768px) {
  .video-grid { grid-template-columns: 1fr; }
  .header-center { display: none; }
  .settings-layout { grid-template-columns: 1fr; }
  .dashboard-grid { grid-template-columns: 1fr; }
}

/* ============ LOGIN PAGE ============ */
.login-page-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: linear-gradient(135deg, #0F0F0F 0%, #1A1A2E 50%, #16213E 100%);
}
.login-card {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  padding: 48px 40px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}
.login-card .logo-large {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 32px;
  font-size: 24px;
  font-weight: 700;
}
.login-card .logo-icon-lg {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}
.login-card h2 {
  text-align: center;
  font-size: 20px;
  margin-bottom: 8px;
}
.login-card .subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 28px;
}
.login-card .form-group { margin-bottom: 16px; }
.login-card .btn-primary {
  width: 100%;
  padding: 12px;
  font-size: 15px;
  margin-top: 8px;
}
.login-card .divider {
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
  margin: 20px 0;
  position: relative;
}
.login-card .divider::before, .login-card .divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 40%;
  height: 1px;
  background: var(--border);
}
.login-card .divider::before { left: 0; }
.login-card .divider::after { right: 0; }
.login-link {
  text-align: center;
  margin-top: 20px;
  font-size: 14px;
  color: var(--text-secondary);
}
.login-link a { color: var(--primary-light); font-weight: 500; }
