/* ==========================================================================
   CodeCampus LMS v2.9.84
   Instructor Run Current Code — project visibility + terminal UX fix
   ========================================================================== */

/*
 * Emergency compatibility override:
 * v2.9.83 could accidentally place this class on the whole Submitted Java
 * Project. Never let that old class hide anything after v2.9.84 is loaded.
 */
.cc-review-old-terminal-hidden-v2983 {
  display: revert !important;
}

/* The new terminal has its own isolated class and never hides ancestors. */
.cc-review-current-run-terminal-v2984 {
  margin: 14px 0 4px;
  overflow: hidden;
  border: 1px solid rgba(76,112,154,.34);
  border-radius: 17px;
  background: #06111e;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.025),
    0 14px 32px rgba(0,0,0,.14);
  color: #eaf3ff;
}

.cc-review-current-run-terminal-v2984 > header {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(92,126,168,.22);
  background:
    linear-gradient(180deg, rgba(13,31,52,.98), rgba(8,23,40,.98));
}

.cc-run-title-v2984 {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.cc-run-title-v2984 > i {
  width: 9px;
  height: 9px;
  flex: 0 0 9px;
  border-radius: 50%;
  background: #38d39f;
  box-shadow: 0 0 0 5px rgba(56,211,159,.09);
}

.cc-review-current-run-terminal-v2984[data-state="running"] .cc-run-title-v2984 > i {
  background: #36c8ff;
  animation: ccRunPulse2984 1s ease-in-out infinite;
}

.cc-review-current-run-terminal-v2984[data-state="error"] .cc-run-title-v2984 > i {
  background: #fb7185;
  box-shadow: 0 0 0 5px rgba(251,113,133,.09);
}

.cc-run-title-v2984 > div {
  min-width: 0;
}

.cc-run-title-v2984 b {
  display: block;
  color: #f4f8ff !important;
  font-size: .82rem;
  line-height: 1.25;
}

.cc-run-title-v2984 span {
  display: block;
  margin-top: 2px;
  color: #6fcff1 !important;
  font-size: .62rem;
  font-weight: 900;
  letter-spacing: .10em;
  text-transform: uppercase;
}

.cc-run-terminal-actions-v2984 {
  display: flex;
  align-items: center;
  gap: 4px;
}

.cc-run-terminal-actions-v2984 button {
  min-height: 31px !important;
  padding: 0 8px !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #8ba1be !important;
  font: 700 .69rem/1 inherit !important;
  cursor: pointer;
}

.cc-run-terminal-actions-v2984 button:hover {
  color: #eaf3ff !important;
}

.cc-run-source-v2984 {
  padding: 7px 14px;
  border-bottom: 1px solid rgba(92,126,168,.15);
  background: rgba(255,255,255,.015);
  color: #7d94b2 !important;
  font-size: .68rem;
}

.cc-review-current-run-terminal-v2984 pre {
  min-height: 115px;
  max-height: 330px;
  margin: 0;
  padding: 16px 17px;
  overflow: auto;
  background: #030c16 !important;
  color: #e5eefb !important;
  font:
    600 .83rem/1.65
    "JetBrains Mono", Consolas, ui-monospace, monospace !important;
  white-space: pre-wrap;
  word-break: break-word;
}

.cc-review-current-run-terminal-v2984.is-minimized .cc-run-source-v2984,
.cc-review-current-run-terminal-v2984.is-minimized pre {
  display: none;
}

.cc-run-spinner-v2984 {
  display: inline-block;
  width: 14px;
  height: 14px;
  margin-right: 7px;
  vertical-align: -2px;
  border: 2px solid rgba(255,255,255,.34);
  border-top-color: #fff;
  border-radius: 50%;
  animation: ccRunSpin2984 .7s linear infinite;
}

@keyframes ccRunSpin2984 {
  to { transform: rotate(360deg); }
}

@keyframes ccRunPulse2984 {
  50% { opacity: .42; transform: scale(.82); }
}

/* Protect the Java project from accidental collapse/hiding after Run. */
.cc-review-live-run-v2984 .cc-review-student-card-v2980
:where(details, .cc-review-current-run-terminal-v2984) {
  visibility: visible;
}

/* Mobile */
@media (max-width: 640px) {
  .cc-review-current-run-terminal-v2984 {
    border-radius: 14px;
  }

  .cc-review-current-run-terminal-v2984 > header {
    padding: 9px 10px;
  }

  .cc-run-title-v2984 span {
    display: none;
  }

  .cc-review-current-run-terminal-v2984 pre {
    min-height: 105px;
    max-height: 42dvh;
    padding: 13px;
    font-size: .79rem !important;
  }

  .cc-run-source-v2984 {
    padding: 7px 11px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cc-run-spinner-v2984,
  .cc-review-current-run-terminal-v2984[data-state="running"] .cc-run-title-v2984 > i {
    animation: none !important;
  }
}
