/* ==========================================================================
   INTEGERAI LMS - Signature Dark Glassmorphic Template Theme
   ========================================================================== */

:root {
  --bg-dark: #070a16;
  --bg-surface: #0c1024;
  --bg-card: rgba(18, 24, 52, 0.75);
  --bg-card-hover: rgba(28, 38, 76, 0.9);
  --bg-card-solid: #121834;
  
  --border-glass: rgba(255, 255, 255, 0.08);
  --border-active: rgba(91, 82, 249, 0.45);
  --border-cyan: rgba(56, 189, 248, 0.35);
  
  --primary: #5b52f9;
  --primary-glow: rgba(91, 82, 249, 0.4);
  --primary-gradient: linear-gradient(135deg, #5b52f9 0%, #38bdf8 100%);
  
  --accent-cyan: #38bdf8;
  --accent-emerald: #10b981;
  --accent-purple: #a855f7;
  --accent-amber: #f59e0b;
  --accent-rose: #f43f5e;
  
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 9999px;
  
  --shadow-main: 0 10px 30px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 25px rgba(91, 82, 249, 0.25);
  
  --font-sans: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', Consolas, monospace;
}

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

body {
  font-family: var(--font-sans);
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Ambient Floating Glows */
.lms-ambient-glow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  background: 
    radial-gradient(circle at 15% 15%, rgba(91, 82, 249, 0.14) 0%, transparent 45%),
    radial-gradient(circle at 85% 20%, rgba(56, 189, 248, 0.1) 0%, transparent 45%),
    radial-gradient(circle at 50% 85%, rgba(168, 85, 247, 0.1) 0%, transparent 50%);
}

.lms-wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ==========================================================================
   1. TOP NAVBAR HEADER (IntegerAI Signature Dark Header)
   ========================================================================== */
.skool-top-header {
  background: rgba(12, 16, 36, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-glass);
  padding: 0.75rem 1.75rem;
  position: sticky;
  top: 0;
  z-index: 100;
}

.skool-header-container {
  max-width: 100%;
  width: 100%;
  padding: 0 1.5rem;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
}

.program-selector-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: #fff;
  font-weight: 800;
  font-size: 1.05rem;
  padding: 6px 12px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-glass);
  transition: all 0.2s;
}

.program-selector-btn:hover {
  background: rgba(91, 82, 249, 0.15);
  border-color: var(--border-active);
}

.program-avatar-thumb {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 0.9rem;
  box-shadow: 0 0 12px var(--primary-glow);
}

.skool-search-bar {
  flex: 1;
  max-width: 500px;
  position: relative;
}

.skool-search-input {
  width: 100%;
  padding: 0.6rem 1.2rem 0.6rem 2.5rem;
  background: rgba(7, 10, 22, 0.75);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-pill);
  font-size: 0.9rem;
  color: #fff;
  outline: none;
  transition: all 0.2s;
}

.skool-search-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 15px var(--primary-glow);
  background: rgba(14, 20, 40, 0.9);
}

.skool-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-dim);
  font-size: 0.85rem;
}

.skool-header-actions {
  display: flex;
  align-items: center;
  gap: 1.1rem;
}

.header-icon-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  font-size: 1.1rem;
  cursor: pointer;
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  text-decoration: none;
}

.header-icon-btn:hover {
  background: rgba(91, 82, 249, 0.2);
  border-color: var(--border-active);
  color: #fff;
}

.notification-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  background: #ef4444;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: var(--radius-pill);
  border: 2px solid var(--bg-dark);
  box-shadow: 0 0 8px rgba(239, 68, 68, 0.6);
}

.user-nav-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--primary-gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
  cursor: pointer;
  border: 2px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 0 12px var(--primary-glow);
}

/* ==========================================================================
   2. MAIN NAVIGATION TAB BAR (Electric Neon Tab Styling)
   ========================================================================== */
.skool-tabs-nav {
  background: rgba(14, 20, 44, 0.7);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-bottom: 1px solid var(--border-glass);
  padding: 0 1.75rem;
}

.skool-tabs-container {
  max-width: 100%;
  width: 100%;
  padding: 0 1.5rem;
  margin: 0 auto;
  display: flex;
  gap: 2rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.skool-tabs-container::-webkit-scrollbar {
  display: none;
}

.skool-tab-link {
  padding: 0.95rem 0.2rem;
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  position: relative;
  white-space: nowrap;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
}

.skool-tab-link:hover {
  color: #fff;
}

.skool-tab-link.active {
  color: #fff;
  font-weight: 800;
}

.skool-tab-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--primary-gradient);
  border-radius: 3px 3px 0 0;
  box-shadow: 0 0 10px var(--primary);
}

/* ==========================================================================
   3. COMMUNITY PAGE LAYOUT (2-COLUMN GRID IN DARK GLASSMORPHISM)
   ========================================================================== */
.skool-main-layout {
  max-width: 100%;
  width: 100%;
  margin: 1.5rem auto 3rem;
  padding: 0 1.5rem;
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 1.75rem;
  align-items: flex-start;
}

.skool-main-layout.layout-full-width {
  grid-template-columns: 1fr !important;
  max-width: 100% !important;
  width: 100% !important;
  padding: 0 1.5rem !important;
}

@media (max-width: 980px) {
  .skool-main-layout {
  max-width: 100%;
  width: 100%;
  margin: 1.5rem auto 3rem;
  padding: 0 1.5rem;
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 1.75rem;
  align-items: flex-start;
}
}

/* Quick "Write something" trigger box */
.write-something-box {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 1.1rem 1.4rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-main);
  cursor: pointer;
  transition: all 0.2s;
}

.write-something-box:hover {
  border-color: var(--border-active);
  background: var(--bg-card-hover);
  box-shadow: 0 8px 25px rgba(91, 82, 249, 0.15);
}

.write-something-placeholder {
  color: var(--text-muted);
  font-size: 0.95rem;
  flex: 1;
}

/* Category Filter Buttons Bar */
.category-filters-bar {
  display: flex;
  gap: 10px;
  margin-bottom: 1.5rem;
  overflow-x: auto;
  align-items: center;
  padding-bottom: 4px;
}

.cat-filter-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.cat-filter-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.cat-filter-btn.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
  box-shadow: 0 4px 15px var(--primary-glow);
}

/* Skool Community Post Card in IntegerAI Theme */
.skool-post-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow-main);
  transition: all 0.2s ease;
}

.skool-post-card:hover {
  border-color: var(--border-active);
  background: var(--bg-card-hover);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.skool-post-card.instructor-post {
  border-color: rgba(168, 85, 247, 0.4);
  background: rgba(28, 20, 56, 0.45);
}

.post-card-author-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.author-thumb-wrapper {
  position: relative;
}

.author-thumb-img {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.95rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.author-level-pill {
  position: absolute;
  bottom: -2px;
  right: -2px;
  background: #38bdf8;
  color: #080b18;
  font-size: 0.65rem;
  font-weight: 800;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--bg-dark);
}

.post-card-meta h4 {
  font-size: 0.98rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.post-card-meta .post-subline {
  font-size: 0.82rem;
  color: var(--text-dim);
}

.badge-tag-category {
  color: var(--accent-cyan);
  font-weight: 700;
}

.skool-post-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.6rem;
  line-height: 1.4;
}

.skool-post-body {
  font-size: 0.95rem;
  color: #cbd5e1;
  line-height: 1.65;
  white-space: pre-line;
  margin-bottom: 1.25rem;
}

.skool-post-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid var(--border-glass);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.post-metrics-left {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.metric-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.metric-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.metric-btn.liked {
  color: var(--accent-rose);
  border-color: rgba(244, 63, 94, 0.4);
  background: rgba(244, 63, 94, 0.15);
}

.post-metrics-right {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.8rem;
  color: var(--text-dim);
}

/* Avatar Stack in Card Footer */
.avatar-stack {
  display: flex;
  align-items: center;
}

.avatar-stack-item {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--bg-surface);
  margin-left: -6px;
  background: #64748b;
  color: #fff;
  font-size: 0.6rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.avatar-stack-item:first-child {
  margin-left: 0;
}

/* ==========================================================================
   4. RIGHT SIDEBAR PROGRAM WIDGET (IntegerAI Dark Card)
   ========================================================================== */
.skool-sidebar-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-main);
  position: sticky;
  top: 90px;
}

.sidebar-cover-banner {
  height: 120px;
  background: linear-gradient(135deg, #5b52f9 0%, #06b6d4 100%);
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 14px;
}

.powered-by-tag {
  position: absolute;
  top: 10px;
  right: -25px;
  background: #38bdf8;
  color: #080b18;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 3px 30px;
  transform: rotate(45deg);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.sidebar-body {
  padding: 1.5rem;
}

.sidebar-program-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 2px;
}

.sidebar-program-url {
  font-size: 0.8rem;
  color: var(--accent-cyan);
  margin-bottom: 1rem;
  display: block;
  text-decoration: none;
}

.sidebar-program-bio {
  font-size: 0.88rem;
  color: #cbd5e1;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.sidebar-stats-row {
  display: flex;
  justify-content: space-around;
  text-align: center;
  padding: 1rem 0;
  background: rgba(7, 10, 22, 0.5);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  margin-bottom: 1.5rem;
}

.stat-number {
  font-size: 1.3rem;
  font-weight: 800;
  color: #fff;
  display: block;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.btn-sidebar-action {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: #fff;
  padding: 0.75rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}

.btn-sidebar-action:hover {
  background: rgba(91, 82, 249, 0.2);
  border-color: var(--border-active);
}

/* ==========================================================================
   5. POST CREATION MODAL (Dark Glassmorphic Dialog)
   ========================================================================== */
.post-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(7, 10, 22, 0.8);
  backdrop-filter: blur(10px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 20px;
}

.post-modal-card {
  max-width: 620px;
  width: 100%;
  background: var(--bg-card-solid);
  border: 1px solid var(--border-active);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8), var(--shadow-glow);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.modal-header h3 {
  font-size: 1.3rem;
  font-weight: 800;
  color: #fff;
}

.btn-close-modal {
  background: transparent;
  border: none;
  font-size: 1.4rem;
  color: var(--text-muted);
  cursor: pointer;
}

/* Classroom / Modules Cards in IntegerAI Theme - Strictly 3 in a row on Desktop/Laptops */
.classroom-grid {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 1.5rem !important;
  width: 100% !important;
}

.classroom-module-card {
  min-width: 0 !important;
  width: 100% !important;
  box-sizing: border-box !important;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-main);
  transition: all 0.25s ease;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
}

.classroom-module-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-active);
  background: var(--bg-card-hover);
  box-shadow: 0 12px 30px rgba(91, 82, 249, 0.2);
}

.classroom-thumb-banner {
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 2.4rem;
}

.classroom-card-body {
  padding: 1.25rem;
  flex: 1;
}

.classroom-card-body h3 {
  font-size: 1.1rem;
  font-weight: 800;
  color: #fff;
  margin: 6px 0;
  line-height: 1.35;
}

.classroom-card-body p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
}

@media (max-width: 768px) {
  .classroom-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 1rem !important;
  }
}

@media (max-width: 520px) {
  .classroom-grid {
    grid-template-columns: 1fr !important;
  }
}


.badge-code {
  font-family: var(--font-mono);
  background: rgba(56, 189, 248, 0.15);
  color: var(--accent-cyan);
  padding: 3px 8px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.82rem;
}

.badge-instructor {
  background: rgba(168, 85, 247, 0.2);
  color: var(--accent-purple);
  border: 1px solid rgba(168, 85, 247, 0.4);
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: var(--radius-pill);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-brand-hover);
  box-shadow: 0 4px 20px var(--primary-glow);
}

.btn-outline {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-glass);
  color: var(--text-main);
}

.btn-outline:hover {
  border-color: #fff;
  color: #fff;
}

.lms-input, .lms-textarea {
  width: 100%;
  padding: 0.8rem 1rem;
  background: rgba(7, 10, 22, 0.8);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-sm);
  color: #fff;
  font-size: 0.92rem;
  font-family: inherit;
  transition: border-color 0.2s;
}

.lms-input:focus, .lms-textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 15px var(--primary-glow);
}

.form-group-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

@media (max-width: 600px) {
  .form-group-row {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   6. SKOOL THREAD & COMMENTS MODAL (Matching User Screenshot)
   ========================================================================== */
.thread-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(7, 10, 22, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 1.5rem;
}

.thread-modal-card {
  max-width: 680px;
  width: 100%;
  max-height: 90vh;
  background: #0f152e;
  border: 1px solid var(--border-active);
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), var(--shadow-glow);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
  animation: modal-slide-up 0.25s ease-out;
}

@keyframes modal-slide-up {
  from { opacity: 0; transform: translateY(20px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.thread-modal-scrollable-body {
  padding: 1.75rem;
  overflow-y: auto;
  flex: 1;
}

.thread-post-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1.25rem;
}

.thread-actions-top {
  display: flex;
  align-items: center;
  gap: 10px;
}

.thread-icon-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.2s;
}

.thread-icon-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.thread-post-title {
  font-size: 1.45rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.6rem;
  line-height: 1.35;
}

.thread-post-content {
  font-size: 0.98rem;
  color: #cbd5e1;
  line-height: 1.7;
  white-space: pre-line;
  margin-bottom: 1.5rem;
}

.thread-metrics-bar {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 0;
  border-top: 1px solid var(--border-glass);
  border-bottom: 1px solid var(--border-glass);
  margin-bottom: 1.5rem;
}

.btn-like-pill {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-glass);
  color: #fff;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.btn-like-pill:hover {
  background: rgba(91, 82, 249, 0.2);
  border-color: var(--border-active);
}

.comments-count-label {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Comments List inside Thread */
.thread-comments-stream {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  margin-bottom: 1rem;
}

.comment-card-bubble {
  background: rgba(18, 24, 52, 0.85);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  position: relative;
  transition: border-color 0.2s;
}

.comment-card-bubble:hover {
  border-color: rgba(255, 255, 255, 0.15);
}

.comment-author-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.6rem;
}

.comment-meta h5 {
  font-size: 0.92rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 6px;
}

.comment-meta span {
  font-size: 0.78rem;
  color: var(--text-dim);
}

.comment-body-text {
  font-size: 0.92rem;
  color: #cbd5e1;
  line-height: 1.6;
  white-space: pre-line;
  margin-bottom: 0.75rem;
}

.comment-action-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.btn-comment-like {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.8rem;
  font-weight: 600;
}

.btn-comment-like:hover {
  color: var(--accent-rose);
}

.btn-comment-reply {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 600;
}

.btn-comment-reply:hover {
  color: var(--accent-cyan);
}

/* Floating "Jump to latest comment" button */
.jump-to-latest-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(14, 20, 44, 0.95);
  border: 1px solid var(--border-active);
  color: var(--accent-cyan);
  padding: 6px 16px;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  margin: 10px auto;
  box-shadow: 0 4px 15px rgba(0,0,0,0.5);
  transition: all 0.2s;
}

.jump-to-latest-btn:hover {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 4px 15px var(--primary-glow);
}

/* Sticky Comment Composer at Modal Footer */
.thread-composer-footer {
  padding: 1rem 1.5rem;
  background: rgba(7, 10, 22, 0.95);
  border-top: 1px solid var(--border-glass);
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.composer-avatar-thumb {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary-gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.composer-input-field {
  flex: 1;
  background: rgba(18, 24, 52, 0.8);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-pill);
  padding: 0.65rem 1.2rem;
  color: #fff;
  font-size: 0.9rem;
  outline: none;
  font-family: inherit;
  transition: border-color 0.2s;
}

.composer-input-field:focus {
  border-color: var(--primary);
  box-shadow: 0 0 12px var(--primary-glow);
}

.btn-send-comment {
  background: var(--primary);
  color: #fff;
  border: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}

.btn-send-comment:hover {
  background: var(--primary-brand-hover);
  box-shadow: 0 0 15px var(--primary-glow);
}

/* ==========================================================================
   7. RICH MEDIA EMBEDS (Image, YouTube, Instagram) & LIKE TOGGLE STATES
   ========================================================================== */
.post-embed-media-box {
  margin: 1rem 0 1.25rem;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-glass);
  background: rgba(0, 0, 0, 0.4);
}

.post-media-image {
  width: 100%;
  max-height: 480px;
  object-fit: cover;
  display: block;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: transform 0.2s ease;
}

.post-media-image:hover {
  transform: scale(1.01);
}

.video-responsive-box {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  border-radius: var(--radius-md);
}

.video-responsive-box iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.instagram-responsive-box {
  max-width: 500px;
  margin: 0 auto;
  min-height: 440px;
  border-radius: var(--radius-md);
  overflow: hidden;
}

.instagram-responsive-box iframe {
  width: 100%;
  min-height: 460px;
  border: none;
}

/* Liked Toggle Active States */
.metric-btn.is-liked, .btn-like-pill.is-liked {
  background: rgba(56, 189, 248, 0.2) !important;
  color: #38bdf8 !important;
  border-color: #38bdf8 !important;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.4);
}

.btn-comment-like.is-liked {
  color: #38bdf8 !important;
  font-weight: 800;
}

/* Modal Media Tabs */
.media-tab-btns {
  display: flex;
  gap: 8px;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.media-tab-pill {
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.media-tab-pill:hover, .media-tab-pill.active {
  background: rgba(91, 82, 249, 0.2);
  border-color: var(--border-active);
  color: #fff;
}

/* ==========================================================================
   8. CLIENT-SIDE SECURITY, CONTENT PROTECTION & DRM SHIELD
   ========================================================================== */
body {
  -webkit-touch-callout: none;
}

img, video, iframe {
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
  pointer-events: auto;
}

.skool-header, .skool-tabs-nav, .skool-sidebar-card, .btn, button, .user-nav-avatar {
  user-select: none;
  -webkit-user-select: none;
}

/* ==========================================================================
   9. COMPREHENSIVE MOBILE RESPONSIVENESS (< 992px, < 768px, < 480px)
   ========================================================================== */
@media (max-width: 992px) {
  .skool-main-layout {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
  }
  .skool-sidebar-card {
    margin-top: 1rem;
  }
  .lesson-player-layout {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 768px) {
  .skool-header-container {
    padding: 0 1rem;
    gap: 0.75rem;
  }
  .skool-brand-title {
    display: none;
  }
  .skool-search-bar {
    max-width: 100%;
  }
  .skool-tabs-container {
    padding: 0 1rem;
    gap: 1.25rem;
  }
  .skool-tab-link {
    font-size: 0.88rem;
    padding: 0.8rem 0.1rem;
  }
  .skool-post-card, .admin-card-box {
    padding: 1.1rem !important;
    border-radius: var(--radius-md) !important;
  }
  .skool-field-row, .form-group-row {
    grid-template-columns: 1fr !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
  }
  .profile-card-container {
    margin: 15px auto !important;
    padding: 20px 18px !important;
    border-radius: 12px !important;
    max-width: 96% !important;
  }
  .thread-modal-card, .post-modal-card {
    width: 96% !important;
    max-height: 92vh !important;
    border-radius: 12px !important;
  }
  .admin-table-wrapper, table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
  }
  .btn {
    min-height: 40px;
  }
}

@media (max-width: 480px) {
  .skool-header {
    padding: 0.5rem 0;
  }
  .skool-post-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  .post-metrics-right {
    width: 100%;
    justify-content: flex-start;
  }
  .category-filters-bar {
    gap: 6px;
  }
  .cat-filter-btn {
    padding: 6px 12px;
    font-size: 0.78rem;
  }
}
