/* ==========================================================================
   RootOS Core Hubs & 80+ Subpages Architecture CSS
   Expanded 10-Section Blueprint Components & Responsive Grid System
   Architecture: Synapse High Board / Chief System Architect
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Spatial Grids & Section Layouts
   -------------------------------------------------------------------------- */
.root-section {
  position: relative;
  padding: 6.5rem 2rem;
  overflow: hidden;
}

.root-section-hero {
  padding-top: 9.5rem;
  padding-bottom: 7rem;
  min-height: 85vh;
  display: flex;
  align-items: center;
}

.root-container {
  max-width: 1360px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.root-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3.5rem;
  align-items: center;
}

.root-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.2rem;
}

.root-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.8rem;
}

/* Sticky Column Pattern for Long Pages (Zero-Void Architecture) */
.root-sticky-col {
  position: -webkit-sticky;
  position: sticky;
  top: 110px;
  align-self: start;
}

/* --------------------------------------------------------------------------
   2. Section Headers & Badges
   -------------------------------------------------------------------------- */
.root-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 1.1rem;
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.25);
  border-radius: var(--radius-full);
  color: var(--root-cyan);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.5rem;
  font-family: var(--font-mono);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.08);
  transition: all 0.3s ease;
}

.root-badge:hover {
  border-color: var(--root-cyan);
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
}

.root-badge-gold {
  background: rgba(212, 175, 55, 0.1);
  border-color: rgba(212, 175, 55, 0.35);
  color: var(--root-gold);
  box-shadow: 0 0 15px rgba(212, 175, 55, 0.1);
}

.root-badge-gold:hover {
  border-color: var(--root-gold);
  box-shadow: 0 0 25px rgba(212, 175, 55, 0.25);
}

.root-badge-red {
  background: rgba(239, 68, 68, 0.1);
  border-color: rgba(239, 68, 68, 0.35);
  color: #EF4444;
  box-shadow: 0 0 15px rgba(239, 68, 68, 0.1);
}

.root-title-hero {
  font-size: clamp(2.4rem, 5vw, 4.2rem);
  font-weight: 900;
  line-height: 1.16;
  margin-bottom: 1.5rem;
  color: var(--root-text-white);
  letter-spacing: -0.02em;
}

.root-title-section {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 1.25rem;
  color: var(--root-text-white);
  letter-spacing: -0.01em;
}

.root-desc-hero {
  font-size: clamp(1.05rem, 1.8vw, 1.25rem);
  color: var(--root-text-titanium);
  line-height: 1.85;
  margin-bottom: 2.5rem;
  max-width: 680px;
}

.root-desc-section {
  font-size: 1.05rem;
  color: var(--root-text-muted);
  line-height: 1.8;
  margin-bottom: 2.5rem;
  max-width: 720px;
}

/* --------------------------------------------------------------------------
   3. Pain vs Solution Comparison Box
   -------------------------------------------------------------------------- */
.root-compare-box {
  background: rgba(10, 14, 22, 0.75);
  border: 1px solid var(--root-border-subtle);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  backdrop-filter: blur(16px);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.root-compare-box:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 240, 255, 0.3);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.root-pain-list, .root-solution-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding: 0;
  margin: 0;
}

.root-pain-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  color: #F87171;
  font-size: 0.95rem;
  line-height: 1.65;
}

.root-solution-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  color: #34D399;
  font-size: 0.95rem;
  line-height: 1.65;
}

/* --------------------------------------------------------------------------
   4. Section 3: Core Architectural Pillars (4 Deep Modules)
   -------------------------------------------------------------------------- */
.root-pillar-card {
  position: relative;
  background: rgba(18, 24, 33, 0.75);
  border: 1px solid rgba(0, 240, 255, 0.15);
  border-radius: var(--radius-lg);
  padding: 2.4rem 2rem;
  backdrop-filter: blur(16px);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.root-pillar-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: rgba(0, 240, 255, 0.5);
  box-shadow: 0 20px 45px rgba(0, 240, 255, 0.14), 0 0 25px rgba(0, 240, 255, 0.08);
  background: rgba(18, 24, 33, 0.92);
}

.root-pillar-num {
  font-family: var(--font-mono);
  font-size: 2.2rem;
  font-weight: 800;
  color: rgba(0, 240, 255, 0.25);
  margin-bottom: 1.25rem;
  transition: color 0.3s ease;
}

.root-pillar-card:hover .root-pillar-num {
  color: var(--root-cyan);
}

.root-pillar-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--root-text-white);
  margin-bottom: 0.85rem;
}

.root-pillar-desc {
  font-size: 0.92rem;
  color: var(--root-text-muted);
  line-height: 1.7;
  margin-bottom: 1.8rem;
}

.root-pillar-tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--root-cyan);
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.25);
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  align-self: flex-start;
  transition: all 0.3s ease;
}

.root-pillar-card:hover .root-pillar-tag {
  background: rgba(0, 240, 255, 0.15);
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}

/* --------------------------------------------------------------------------
   5. Section 4: Real-Time Executive Telemetry & C-Suite HUD
   -------------------------------------------------------------------------- */
.root-telemetry-hud {
  background: rgba(18, 24, 33, 0.75);
  border: 1px solid var(--root-border-subtle);
  border-radius: var(--radius-lg);
  padding: 2.2rem 1.8rem;
  backdrop-filter: blur(16px);
  text-align: center;
  transition: all 0.35s ease;
  position: relative;
  overflow: hidden;
}

.root-telemetry-hud::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--root-cyan), transparent);
  opacity: 0.4;
  transition: opacity 0.3s ease;
}

.root-telemetry-hud:hover {
  transform: translateY(-6px);
  border-color: rgba(0, 240, 255, 0.4);
  box-shadow: 0 15px 35px rgba(0, 240, 255, 0.12);
}

.root-telemetry-hud:hover::before {
  opacity: 1;
}

.root-telemetry-label {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--root-text-muted);
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
}

.root-telemetry-val {
  font-family: var(--font-mono);
  font-size: 2.8rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 0.75rem;
}

.root-telemetry-status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: var(--root-text-titanium);
}

.root-telemetry-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--root-cyan);
  box-shadow: 0 0 8px var(--root-cyan);
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

/* --------------------------------------------------------------------------
   6. Section 6: Phased Capital Deployment & Escrow Protocol
   -------------------------------------------------------------------------- */
.root-escrow-card {
  background: rgba(18, 24, 33, 0.75);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  backdrop-filter: blur(16px);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.root-escrow-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 45px rgba(0, 240, 255, 0.15);
}

.root-escrow-phase {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--root-cyan);
  letter-spacing: 0.08em;
  margin-bottom: 1rem;
}

.root-escrow-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--root-text-white);
  margin-bottom: 0.85rem;
}

.root-escrow-desc {
  font-size: 0.95rem;
  color: var(--root-text-muted);
  line-height: 1.7;
  margin-bottom: 1.8rem;
}

.root-escrow-badge {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--root-cyan);
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.25);
  padding: 0.4rem 0.9rem;
  border-radius: var(--radius-full);
  align-self: flex-start;
}

/* --------------------------------------------------------------------------
   7. Section 7: Deep-Dive Architectural Ecosystem Clusters
   -------------------------------------------------------------------------- */
.root-cluster-card {
  background: rgba(18, 24, 33, 0.7);
  border: 1px solid var(--root-border-subtle);
  border-radius: var(--radius-lg);
  padding: 2.2rem 1.8rem;
  backdrop-filter: blur(16px);
  text-decoration: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.root-cluster-card:hover {
  transform: translateY(-8px);
  border-color: var(--root-cyan);
  box-shadow: 0 20px 40px rgba(0, 240, 255, 0.16);
  background: rgba(18, 24, 33, 0.9);
}

.root-cluster-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--root-cyan);
  margin-bottom: 1.4rem;
  transition: transform 0.3s ease;
}

.root-cluster-card:hover .root-cluster-icon {
  transform: scale(1.1);
}

.root-cluster-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--root-text-white);
  margin-bottom: 0.75rem;
}

.root-cluster-desc {
  font-size: 0.9rem;
  color: var(--root-text-muted);
  line-height: 1.65;
  margin-bottom: 1.5rem;
}

.root-cluster-link {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--root-cyan);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: transform 0.3s ease;
}

.root-cluster-card:hover .root-cluster-link {
  transform: translateX(5px);
  color: var(--root-gold);
}

/* --------------------------------------------------------------------------
   8. Section 8: Enterprise Case Realizations & Benchmarks
   -------------------------------------------------------------------------- */
.root-case-card {
  background: rgba(18, 24, 33, 0.75);
  border: 1px solid var(--root-border-subtle);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  backdrop-filter: blur(16px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.root-case-card:hover {
  transform: translateY(-8px);
  border-color: rgba(212, 175, 55, 0.45);
  box-shadow: 0 20px 45px rgba(212, 175, 55, 0.12);
}

.root-case-category {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--root-gold);
  letter-spacing: 0.08em;
  margin-bottom: 0.85rem;
}

.root-case-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--root-text-white);
  margin-bottom: 0.85rem;
}

.root-case-desc {
  font-size: 0.95rem;
  color: var(--root-text-muted);
  line-height: 1.7;
  margin-bottom: 2rem;
}

.root-case-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.root-stat-num {
  font-family: var(--font-mono);
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--root-cyan);
  display: block;
  line-height: 1.2;
}

.root-stat-label {
  font-size: 0.78rem;
  color: var(--root-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* --------------------------------------------------------------------------
   9. Interactive FAQ Accordion
   -------------------------------------------------------------------------- */
.root-faq-item {
  background: var(--root-card-glass);
  border: 1px solid var(--root-border-subtle);
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
  overflow: hidden;
  transition: all 0.3s ease;
}

.root-faq-item:hover {
  border-color: rgba(0, 240, 255, 0.35);
  box-shadow: 0 10px 25px rgba(0, 240, 255, 0.08);
}

.root-faq-trigger {
  width: 100%;
  padding: 1.4rem 1.8rem;
  background: transparent;
  border: none;
  color: var(--root-text-white);
  font-size: 1.05rem;
  font-weight: 700;
  text-align: inherit;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  font-family: inherit;
  transition: color 0.25s ease;
}

.root-faq-trigger:hover {
  color: var(--root-cyan);
}

.root-faq-trigger svg {
  transition: transform 0.3s ease;
  color: var(--root-cyan);
  flex-shrink: 0;
}

.root-faq-item.is-open .root-faq-trigger svg {
  transform: rotate(180deg);
}

.root-faq-content {
  display: none;
  padding: 0 1.8rem 1.4rem;
  color: var(--root-text-muted);
  font-size: 0.95rem;
  line-height: 1.8;
}

.root-faq-item.is-open .root-faq-content {
  display: block;
}

/* --------------------------------------------------------------------------
   10. Proof & Metrics Ribbon
   -------------------------------------------------------------------------- */
.root-metrics-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  background: rgba(10, 15, 24, 0.7);
  border: 1px solid var(--root-border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.5rem 3rem;
  margin-top: 4rem;
  backdrop-filter: blur(16px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.root-metric-item {
  text-align: center;
}

.root-metric-val {
  font-family: var(--font-mono);
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--root-cyan);
  line-height: 1.1;
  margin-bottom: 0.35rem;
}

.root-metric-label {
  font-size: 0.85rem;
  color: var(--root-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* --------------------------------------------------------------------------
   11. Visual Diagram Frame & SVG Embedding
   -------------------------------------------------------------------------- */
.root-diagram-frame {
  position: relative;
  background: rgba(5, 11, 20, 0.9);
  border: 1px solid rgba(0, 240, 255, 0.25);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), 0 0 35px rgba(0, 240, 255, 0.1);
  overflow: hidden;
}

.root-diagram-scanner-line {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--root-cyan), var(--root-gold), transparent);
  box-shadow: 0 0 16px var(--root-cyan), 0 0 8px var(--root-gold);
  animation: laserScan 4.5s cubic-bezier(0.4, 0, 0.2, 1) infinite;
  z-index: 3;
  pointer-events: none;
}

@keyframes laserScan {
  0% { top: 0%; opacity: 0; }
  15% { opacity: 1; }
  85% { opacity: 1; }
  100% { top: 100%; opacity: 0; }
}

.root-diagram-img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-md);
  transition: transform 0.5s ease;
}

.root-diagram-frame:hover .root-diagram-img {
  transform: scale(1.02);
}

/* Tech Pills */
.root-tech-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.5rem;
}

.root-tech-pill {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  background: rgba(0, 240, 255, 0.06);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: var(--radius-full);
  padding: 0.35rem 0.9rem;
  color: var(--root-text-titanium);
  transition: all 0.3s ease;
}

.root-tech-pill:hover {
  transform: scale(1.05);
  border-color: var(--root-cyan);
  color: var(--root-cyan);
  box-shadow: 0 0 12px rgba(0, 240, 255, 0.2);
}

/* ICP Filtering Table */
.root-icp-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--root-border-subtle);
  background: var(--root-card-glass);
  margin-top: 2rem;
}

.root-icp-table th, .root-icp-table td {
  padding: 1.3rem 1.6rem;
  text-align: left;
  border-bottom: 1px solid var(--root-border-subtle);
}

.root-icp-table th {
  background: rgba(5, 11, 20, 0.95);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  text-transform: uppercase;
  color: var(--root-cyan);
  letter-spacing: 0.05em;
}

.root-icp-table tbody tr {
  transition: background 0.25s ease;
}

.root-icp-table tbody tr:hover {
  background: rgba(0, 240, 255, 0.04);
}

/* --------------------------------------------------------------------------
   12. Responsive Adaptations (Full Mobile Optimization)
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .root-grid-2,
  .root-grid-3,
  .root-grid-4 {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.75rem;
  }
  .root-metrics-bar {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
  .root-sticky-col {
    position: static;
  }
}

@media (max-width: 768px) {
  .root-section {
    padding: 4.5rem 1.25rem;
  }
  .root-section-hero {
    padding-top: 7.5rem;
    padding-bottom: 4rem;
    min-height: auto;
  }
  .root-grid-2,
  .root-grid-3,
  .root-grid-4 {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .root-metrics-bar {
    grid-template-columns: 1fr;
    padding: 1.75rem 1.25rem;
    gap: 1.5rem;
  }
  .root-title-hero {
    font-size: clamp(2rem, 7vw, 2.8rem);
  }
  .root-title-section {
    font-size: 1.75rem;
  }
  .root-icp-table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
  }
  .root-card {
    padding: 2.2rem 1.5rem !important;
  }
}
