/* ──── Lab Tour Page Layout ──── */

.lab-main {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  min-height: 100vh;
  padding: 4.5rem 1rem 1.5rem;
  box-sizing: border-box;
}

/* ──── Terminal Window ──── */

.terminal-window {
  width: 100%;
  max-width: 1000px;
  height: calc(100vh - 6rem);
  display: flex;
  flex-direction: column;
  background: #070F1D;
  border: 1px solid rgba(100, 255, 218, 0.18);
  border-radius: 10px;
  box-shadow:
    0 0 50px rgba(100, 255, 218, 0.06),
    0 8px 40px rgba(0, 0, 0, 0.6);
  overflow: hidden;
}

/* ──── Title Bar ──── */

.terminal-titlebar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 1rem;
  background: #0C1824;
  border-bottom: 1px solid rgba(100, 255, 218, 0.08);
  flex-shrink: 0;
}

.titlebar-dots {
  display: flex;
  gap: 0.4rem;
  flex-shrink: 0;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.dot-red    { background: #FF5F57; cursor: pointer; }
.dot-yellow { background: #FEBC2E; }
.dot-green  { background: #28C840; }

.dot-red:hover { filter: brightness(1.25); }

.titlebar-label {
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.78rem;
  color: rgba(100, 255, 218, 0.35);
  flex: 1;
  text-align: center;
}

/* ──── Terminal Body ──── */

.terminal-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow: hidden;
  padding: 1rem 1.25rem 0.75rem;
}

/* ──── Output Area ──── */

.terminal-output {
  flex: 1;
  overflow-y: auto;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.875rem;
  line-height: 1.72;
  color: #64FFDA;
  padding-bottom: 0.5rem;
  word-break: break-word;
  white-space: pre-wrap;
}

.terminal-output {
  scrollbar-width: thin;
  scrollbar-color: rgba(100, 255, 218, 0.25) transparent;
}

.terminal-output::-webkit-scrollbar {
  width: 6px;
}
.terminal-output::-webkit-scrollbar-track {
  background: transparent;
}
.terminal-output::-webkit-scrollbar-thumb {
  background: rgba(100, 255, 218, 0.25);
  border-radius: 3px;
}
.terminal-output::-webkit-scrollbar-thumb:hover {
  background: rgba(100, 255, 218, 0.45);
}
.terminal-output::-webkit-scrollbar-button,
.terminal-output::-webkit-scrollbar-button:start,
.terminal-output::-webkit-scrollbar-button:end,
.terminal-output::-webkit-scrollbar-button:vertical:start:decrement,
.terminal-output::-webkit-scrollbar-button:vertical:end:increment {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

/* ──── Output Line Variants ──── */

.term-line {
  display: block;
  white-space: pre-wrap;
}

.term-line.dim       { opacity: 0.38; }
.term-line.muted     { opacity: 0.6; }
.term-line.accent    { color: #A7FFEB; }
.term-line.header    { color: #64FFDA; font-weight: bold; letter-spacing: 0.03em; }
.term-line.separator { color: rgba(100, 255, 218, 0.25); }
.term-line.error     { color: #FF6B6B; }
.term-line.success   { color: #64FFDA; font-weight: bold; }
.term-line.cmd-echo  { color: #E0F7FA; }

.running {
  color: #64FFDA;
}

/* Clickable service links inside output */
.term-service-link {
  color: #A7FFEB;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
  transition: opacity 0.15s;
}
.term-service-link:hover {
  opacity: 0.65;
}

/* ──── Input Row ──── */

.terminal-input-row {
  display: flex;
  align-items: center;
  padding: 0.4rem 0 0;
  border-top: 1px solid rgba(100, 255, 218, 0.07);
  flex-shrink: 0;
}

.term-prompt {
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.875rem;
  color: #64FFDA;
  white-space: nowrap;
  flex-shrink: 0;
}

.term-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.875rem;
  color: #E0F7FA;
  caret-color: #64FFDA;
  min-width: 0;
}

/* ──── Mobile ──── */

@media (max-width: 640px) {
  .lab-main {
    padding: 4rem 0 0;
  }

  .terminal-window {
    height: calc(100vh - 4rem);
    border-radius: 0;
    border-left: none;
    border-right: none;
  }

  .terminal-output,
  .term-prompt,
  .term-input {
    font-size: 0.8rem;
  }

  .terminal-body {
    padding: 0.75rem 0.85rem 0.5rem;
  }
}
