/* ===== KEELQUILL TERMINAL — Moments 1 + 2 =====
   KEELQUILL-001 | steerable.org static site
   Farbpalette: #0D1117 bg / #0A0F14 terminal / #00C9A7 teal / #F59E0B amber
*/

/* ── Wrapper: widget-card + terminal nebeneinander ── */
.keelquill-anchor {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  justify-content: center;
}

/* Fix: .widget-card hat margin: 0 auto — in Flex absorbiert auto-margin
   den gesamten Freiraum und schiebt das Terminal an den Rand */
.keelquill-anchor .widget-card {
  margin: 0;
  flex-shrink: 0;
}

/* ── Terminal panel ── */
.keelquill-terminal {
  background: #0A0F14;
  border: 1px solid #00C9A7;
  border-radius: 6px;
  width: 340px;
  flex-shrink: 0;
  overflow: hidden;
  font-family: 'Courier New', monospace;

  /* Hidden state */
  opacity: 0;
  transform: translateX(110%);
  pointer-events: none;
  transition: opacity 0.45s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.keelquill-terminal.kq--visible {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}

/* ── Header bar ── */
.kq-header {
  padding: 6px 10px;
  font-size: 11px;
  color: #1a4030;
  background: #060A0D;
  border-bottom: 1px solid #0d2a1f;
  letter-spacing: 0.08em;
}

/* ── Body ── */
.kq-body {
  display: flex;
  gap: 10px;
  padding: 12px 10px;
}

.kq-ascii {
  color: #00C9A7;
  font-size: 12px;
  line-height: 1.4;
  white-space: pre;
  flex-shrink: 0;
  padding-top: 2px;
}

.kq-text {
  font-size: 13px;
  color: #8B949E;
  line-height: 1.65;
  flex: 1;
}

.kq-text .kq-amber {
  color: #F59E0B;
}

/* Typewriter cursor */
.kq-cursor {
  display: inline-block;
  width: 7px;
  height: 11px;
  background: #00C9A7;
  animation: kqBlink 0.8s step-end infinite;
  vertical-align: text-bottom;
  margin-left: 1px;
}

@keyframes kqBlink {
  50% { opacity: 0; }
}

/* ── Status bar ── */
.kq-status {
  padding: 6px 10px;
  font-size: 11px;
  color: #1a4030;
  background: #060A0D;
  border-top: 1px solid #0d2a1f;
  letter-spacing: 0.06em;
}

/* ── Demo button ── */
.kq-demo-btn {
  display: block;
  width: 100%;
  padding: 8px 14px;
  background: #F59E0B;
  color: #0D1117;
  font-family: 'Courier New', monospace;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  border: none;
  cursor: pointer;
  letter-spacing: 0.05em;
  border-top: 1px solid #0d2a1f;

  /* Hidden until typewriter done */
  opacity: 0;
  transform: translateY(4px);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.kq-demo-btn.kq--btn-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* ── Mobile: terminal below widget ── */
@media (max-width: 768px) {
  .keelquill-anchor {
    flex-direction: column;
    align-items: center;
  }

  .keelquill-terminal {
    width: 100%;
    max-width: 480px;
    transform: translateY(110%);
  }

  .keelquill-terminal.kq--visible {
    transform: translateY(0);
  }
}
