/* ==========================================================================
   CYVORA STUDIO — LESSON & TOPIC DETAIL STYLESHEET
   File: /Learning_Content/Style_sheets/lesson-detail.css
   Modern Cyber-Bento Article Aesthetics • Synchronized with Cyvora System
   ========================================================================== */

:root {
  --background: #080808;
  --foreground: #f4f7f5;
  --card: #111815;
  --card-hover: #16201b;
  --card-foreground: #f4f7f5;
  --muted: #17221d;
  --muted-foreground: #8b9a94;
  --border: #202b25;
  --border-subtle: rgba(255, 255, 255, 0.07);
  --border-glow: rgba(20, 244, 244, 0.35);

  --primary: #14f4f4;
  --primary-glow: rgba(20, 244, 244, 0.18);
  --primary-foreground: #040907;

  --secondary: #d99a25;
  --secondary-glow: rgba(217, 154, 37, 0.16);
  --accent: #d85f48;
  --accent-glow: rgba(216, 95, 72, 0.16);
  --emerald: #10b981;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;

  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

body.lesson-page {
  background: var(--background);
  color: var(--foreground);
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

/* Article Container */
.lesson-container {
  max-width: 980px;
  margin: 0 auto;
  padding-bottom: 80px;
}

/* Breadcrumb Navigation */
.lesson-breadcrumb {
  margin: 16px 0 28px;
  font-size: 0.88rem;
  color: var(--muted-foreground);
}

.lesson-breadcrumb ol {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.lesson-breadcrumb li:not(:last-child)::after {
  content: "/";
  margin-left: 10px;
  color: var(--border);
}

.lesson-breadcrumb a {
  color: var(--muted-foreground);
  text-decoration: none;
  font-weight: 500;
  transition: color var(--transition-fast);
}

.lesson-breadcrumb a:hover {
  color: var(--primary);
}

.lesson-breadcrumb li[aria-current="page"] {
  color: var(--foreground);
  font-weight: 600;
}

/* Lesson Header */
.lesson-header {
  position: relative;
  margin-bottom: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

.lesson-header::before {
  content: "";
  position: absolute;
  top: -20px;
  left: -40px;
  width: 380px;
  height: 240px;
  background: radial-gradient(circle, rgba(20, 244, 244, 0.08) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.lesson-header-content {
  position: relative;
  z-index: 1;
}

.lesson-topic-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(20, 244, 244, 0.08);
  border: 1px solid rgba(20, 244, 244, 0.25);
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.lesson-title {
  font-size: clamp(2rem, 4.4vw, 3.2rem);
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: -0.025em;
  color: var(--foreground);
  margin: 0 0 16px;
}

.lesson-title span.glow {
  color: var(--primary);
  text-shadow: 0 0 25px rgba(20, 244, 244, 0.35);
}

.lesson-intro-lead {
  font-size: 1.15rem;
  color: var(--muted-foreground);
  line-height: 1.65;
  margin: 0 0 24px;
  max-width: 840px;
}

/* Meta Bar (Reading time, Difficulty, Last updated) */
.lesson-meta-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--muted-foreground);
}

.lesson-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.lesson-meta-item svg {
  color: var(--primary);
}

.lesson-meta-pill {
  padding: 3px 10px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: rgba(20, 244, 244, 0.1);
  color: var(--primary);
  border: 1px solid rgba(20, 244, 244, 0.28);
}

/* Quick Jump Anchor Pills */
.quick-nav-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.quick-nav-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted-foreground);
  text-decoration: none;
  transition: all var(--transition-fast);
}

.quick-nav-pill:hover {
  color: var(--primary);
  border-color: rgba(20, 244, 244, 0.3);
  background: var(--muted);
}

/* Article Body Typography & Sections */
.lesson-content {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.content-block {
  scroll-margin-top: 40px;
}

.content-block h2 {
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--foreground);
  margin: 0 0 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.content-block h2::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 24px;
  border-radius: 2px;
  background: var(--primary);
  box-shadow: 0 0 10px var(--primary);
}

.content-block p {
  color: #cfd8d3;
  font-size: 1rem;
  line-height: 1.72;
  margin: 0 0 16px;
}

.content-block strong {
  color: var(--foreground);
  font-weight: 700;
}

/* Highlight / Callout Bento Box */
.bento-highlight {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 26px 28px;
  margin: 24px 0;
  overflow: hidden;
  transition: border-color var(--transition-normal);
}

.bento-highlight::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
}

.bento-highlight.amber::before {
  background: linear-gradient(90deg, transparent, var(--secondary), transparent);
}

.bento-highlight:hover {
  border-color: var(--border-glow);
}

.bento-highlight-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.highlight-icon-box {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(20, 244, 244, 0.1);
  border: 1px solid rgba(20, 244, 244, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}

.highlight-icon-box.amber {
  background: rgba(217, 154, 37, 0.1);
  border-color: rgba(217, 154, 37, 0.25);
  color: #f7b944;
}

.bento-highlight-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0;
}

.bento-highlight p {
  margin: 0 0 12px;
  color: var(--muted-foreground);
  font-size: 0.96rem;
}

.bento-highlight p:last-child {
  margin-bottom: 0;
}

/* 2-Column Comparison Bento Grid */
.comparison-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 24px 0;
}

.concept-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 26px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all var(--transition-normal);
}

.concept-card:hover {
  transform: translateY(-3px);
  border-color: rgba(20, 244, 244, 0.35);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}

.concept-card-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 12px;
  color: var(--primary);
}

.concept-card.amber .concept-card-tag {
  color: #f7b944;
}

.concept-card h3 {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--foreground);
  margin: 0 0 12px;
}

.concept-card p {
  font-size: 0.92rem;
  color: var(--muted-foreground);
  line-height: 1.6;
  margin: 0 0 18px;
}

.feature-bullets {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.feature-bullets li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.88rem;
  color: #d1dbd6;
}

.feature-bullets li svg {
  flex-shrink: 0;
  margin-top: 3px;
  color: var(--primary);
}

.concept-card.amber .feature-bullets li svg {
  color: #f7b944;
}

/* The 4 Pillars of AI Agents (4-Grid) */
.pillars-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin: 24px 0;
}

.pillar-item {
  background: #0d1411;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: all var(--transition-fast);
}

.pillar-item:hover {
  border-color: rgba(20, 244, 244, 0.35);
  background: var(--card);
}

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

.pillar-number {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--primary);
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(20, 244, 244, 0.1);
}

.pillar-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0;
}

.pillar-item p {
  font-size: 0.88rem;
  color: var(--muted-foreground);
  line-height: 1.55;
  margin: 0;
}

/* Side-by-Side Comparison Table */
.comparison-table-wrapper {
  overflow-x: auto;
  margin: 24px 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--card);
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  text-align: left;
}

.comparison-table th,
.comparison-table td {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.comparison-table th {
  background: #0b110e;
  font-weight: 700;
  color: var(--foreground);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.comparison-table th:first-child {
  color: var(--muted-foreground);
  width: 25%;
}

.comparison-table th:nth-child(2) {
  color: var(--primary);
  width: 37.5%;
}

.comparison-table th:nth-child(3) {
  color: #f7b944;
  width: 37.5%;
}

.comparison-table tr:last-child td {
  border-bottom: none;
}

.comparison-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.table-dim {
  font-weight: 700;
  color: var(--foreground);
}

/* Interactive Walkthrough / Real-World Scenario */
.scenario-box {
  background: #090e0c;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin: 28px 0;
}

.scenario-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.scenario-comparison {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.scenario-lane {
  background: var(--card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
}

.lane-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 12px;
}

.lane-genai {
  background: rgba(20, 244, 244, 0.12);
  color: var(--primary);
  border: 1px solid rgba(20, 244, 244, 0.3);
}

.lane-agent {
  background: rgba(217, 154, 37, 0.12);
  color: #f7b944;
  border: 1px solid rgba(217, 154, 37, 0.3);
}

.scenario-lane h4 {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 10px;
}

.scenario-lane ol {
  margin: 0;
  padding-left: 18px;
  color: var(--muted-foreground);
  font-size: 0.88rem;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Next Steps / CTA Box */
.lesson-footer-cta {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 36px 32px;
  margin-top: 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  position: relative;
  overflow: hidden;
}

.lesson-footer-cta::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
}

.cta-copy h3 {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--foreground);
  margin: 0 0 6px;
}

.cta-copy p {
  color: var(--muted-foreground);
  font-size: 0.94rem;
  margin: 0;
}

.cta-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* Responsive adjustments */
@media (max-width: 820px) {
  .comparison-grid,
  .pillars-grid,
  .scenario-comparison {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .lesson-header {
    margin-bottom: 28px;
  }
  .bento-highlight {
    padding: 20px;
  }
  .comparison-table th,
  .comparison-table td {
    padding: 12px 14px;
    font-size: 0.84rem;
  }
  .lesson-footer-cta {
    padding: 24px;
    flex-direction: column;
    align-items: flex-start;
  }
  .cta-actions {
    width: 100%;
  }
  .cta-actions .btn {
    width: 100%;
    justify-content: center;
  }
}
