/* ================================================================
   LABS.CSS — AI Labs Section (Section 5)
   Synapse · Product of Synaptix Technologies · Built by Gurnoor Singh
   ================================================================ */

/* ── Labs Grid ── */
.labs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 22px;
}

/* ── Lab Cards ── */
.lab-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 28px;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  overflow: hidden;
}

.lab-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 0%, rgba(139, 92, 246, 0.12), transparent 70%);
  opacity: 0;
  transition: opacity 0.35s;
  pointer-events: none;
}

.lab-card:hover {
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
}

.lab-card:hover::before {
  opacity: 1;
}

.lab-icon {
  font-size: 36px;
}

.lab-title {
  font-family: var(--fd);
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}

.lab-desc {
  color: var(--dim);
  font-size: 13px;
  line-height: 1.7;
  flex: 1;
}

.lab-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}

.lab-tag {
  font-family: var(--fd);
  font-size: 9px;
  letter-spacing: 2px;
  color: var(--purple);
  padding: 4px 10px;
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: var(--radius-full);
}

.lab-enter {
  font-family: var(--fd);
  font-size: 10px;
  letter-spacing: 2px;
  color: var(--blue);
  transition: color 0.3s;
}

.lab-card:hover .lab-enter {
  color: var(--magenta);
}


/* ── Lab Modal ── */
.lab-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 3000;
  background: rgba(2, 4, 8, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  align-items: center;
  justify-content: center;
}

.lab-modal.open {
  display: flex;
}

.lab-inner {
  background: rgba(2, 4, 8, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-xl);
  width: 92%;
  max-width: 900px;
  max-height: 88vh;
  overflow-y: auto;
  position: relative;
  animation: popIn 0.4s var(--ease-spring) both;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.lab-header {
  padding: 24px 32px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  background: rgba(2, 4, 8, 0.95);
  z-index: 10;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.lab-header-title {
  font-family: var(--fd);
  font-size: 15px;
  color: var(--blue);
}

.lab-body {
  padding: 32px;
}


/* ── Drawing Canvas ── */
#draw-canvas {
  border-radius: 12px;
  cursor: crosshair;
  touch-action: none;
  display: block;
  border: 1px solid var(--border);
  transition: border-color 0.3s;
}

#draw-canvas:hover {
  border-color: var(--border-hover);
}


/* ── Waveform Canvas ── */
#wave-canvas {
  display: block;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border);
}


/* ── Sentiment Bars ── */
.sent-bar-wrap {
  margin-bottom: 10px;
}

.sent-bar-label {
  font-family: var(--fd);
  font-size: 10px;
  letter-spacing: 1px;
  margin-bottom: 5px;
  display: flex;
  justify-content: space-between;
}

.sent-bar {
  height: 8px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.sent-bar-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.8s ease;
}


