/* Spectrum Tool — scoped to #spectrum-tool */

#spectrum-tool {
  margin: 3rem 0;
  font-family: "stevie-sans", sans-serif;
}

#spectrum-tool *,
#spectrum-tool *::before,
#spectrum-tool *::after {
  box-sizing: border-box;
}

/* Outer container — makes the tool a distinct object */
#spectrum-tool .st-container {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 28px 28px 24px;
}

/* Tool header */
#spectrum-tool .st-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

#spectrum-tool .st-header-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: #11BBBB;
}

#spectrum-tool .st-header-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

#spectrum-tool .st-header-title {
  font-size: 1.5rem;
  font-weight: 600;
  font-family: "stevie-sans", sans-serif;
  letter-spacing: -0.03em;
  color: #fff;
}

#spectrum-tool .st-header-subtitle {
  margin-top: 4px;
  font-family: "miller-text", serif;
  font-size: 1.375rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 20px;
}

/* Task input */
#spectrum-tool .st-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 12px 16px;
  color: #fff;
  font-size: 1.125rem;
  font-family: "stevie-sans", sans-serif;
  line-height: 1.5;
  outline: none;
  transition: border-color 0.2s;
}

#spectrum-tool .st-input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

#spectrum-tool .st-input:focus {
  border-color: rgba(255, 255, 255, 0.3);
}

#spectrum-tool .st-input:disabled {
  opacity: 0.4;
  cursor: default;
}

#spectrum-tool .st-input-hint {
  margin-top: 6px;
  font-family: "stevie-sans", sans-serif;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.4);
}

/* Start button */
#spectrum-tool .st-start-btn {
  margin-top: 28px;
  padding: 10px 24px;
  background: #fff;
  border: 1px solid #fff;
  border-radius: 8px;
  color: #111;
  font-family: "stevie-sans", sans-serif;
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  margin-bottom: 4px;
  transition: background 0.2s, border-color 0.2s, opacity 0.2s;
}

#spectrum-tool .st-start-btn:hover {
  opacity: 0.85;
}

/* Locked task name — shown during questions and result */
#spectrum-tool .st-input-locked {
  display: inline-block;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  color: #fff;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 6px;
}

#spectrum-tool .st-input-locked::before {
  content: "Task: ";
  color: rgba(255, 255, 255, 0.5);
  font-weight: 500;
}


/* Step containers */
#spectrum-tool .st-step {
  opacity: 1;
  transform: translateY(0);
}

/* Progress bar (visual) */
#spectrum-tool .st-progress-wrap {
  margin-top: 1.25rem;
  margin-bottom: 20px;
}

#spectrum-tool .st-progress-text {
  font-size: 0.85rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.4);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

#spectrum-tool .st-progress-track {
  width: 100%;
  height: 3px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 2px;
  overflow: hidden;
}

#spectrum-tool .st-progress-fill {
  height: 100%;
  background: #11BBBB;
  border-radius: 2px;
  transition: width 0.4s ease;
}

/* Questions */
#spectrum-tool .st-question-text {
  font-size: 1.375rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

#spectrum-tool .st-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#spectrum-tool .st-option {
  display: block;
  width: 100%;
  text-align: left;
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.75);
  font-family: "miller-text", serif;
  font-size: 1.2rem;
  line-height: 1.4;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

#spectrum-tool .st-option:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.2);
  color: #fff;
}

#spectrum-tool .st-option-selected {
  background: rgba(17, 187, 187, 0.12);
  border-color: rgba(17, 187, 187, 0.4);
  color: #fff;
}

/* ============================
   Result
   ============================ */

/* Spectrum visualisation */
#spectrum-tool .st-viz {
  margin-top: 1.75rem;
  margin-bottom: 2.5rem;
}

#spectrum-tool .st-viz-labels {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
}

#spectrum-tool .st-viz-labels span:last-child {
  text-align: right;
}

/* Track and gradient bar */
#spectrum-tool .st-viz-track {
  position: relative;
  width: 100%;
  height: 8px;
  border-radius: 4px;
  overflow: visible;
}

#spectrum-tool .st-viz-bar {
  width: 100%;
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(
    to right,
    #dc4664 0%,
    #11BBBB 100%
  );
}

/* Dot on the spectrum */
#spectrum-tool .st-viz-dot {
  position: absolute;
  top: 50%;
  left: 0%;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  transform: translate(-50%, -50%) scale(0);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  transition: none;
}

#spectrum-tool .st-viz-dot.st-viz-dot-animate {
  transform: translate(-50%, -50%) scale(1);
  transition: left 0.8s cubic-bezier(0.34, 1.56, 0.64, 1),
              transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Badge — inside white card */
#spectrum-tool .st-viz-badge {
  display: inline-block;
  margin-bottom: 18px;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #fff;
  border: none;
}

/* Result card — white box for the verdict */
#spectrum-tool .st-result-card {
  margin-top: 0;
  background: #fff;
  border-radius: 10px;
  padding: 28px 28px;
}

#spectrum-tool .st-feedback-label {
  font-size: 1.375rem;
  font-weight: 600;
  color: #111;
  letter-spacing: -0.025em;
  margin-bottom: 8px;
}

#spectrum-tool .st-feedback-body {
  font-family: "stevie-sans", sans-serif;
  font-size: 1.125rem;
  font-weight: 400;
  line-height: 1.6;
  color: rgba(0, 0, 0, 0.55);
}

/* Divider before reset */
#spectrum-tool .st-result-footer {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Reset link */
#spectrum-tool .st-reset {
  font-size: 1.05rem;
  font-weight: 600;
  color: #fff;
  text-decoration: none;
  transition: color 0.2s;
}

#spectrum-tool .st-reset:hover {
  color: #11BBBB;
}

/* Responsive */
@media (max-width: 480px) {
  #spectrum-tool .st-container {
    padding: 20px 18px 18px;
  }

  #spectrum-tool .st-question-text {
    font-size: 1.2rem;
  }

  #spectrum-tool .st-option {
    padding: 14px 16px;
    font-size: 1.05rem;
  }

  #spectrum-tool .st-feedback-label {
    font-size: 1.2rem;
  }

  #spectrum-tool .st-feedback-body {
    font-size: 1rem;
  }

  #spectrum-tool .st-viz-labels {
    font-size: 0.7rem;
  }

  #spectrum-tool .st-result-card {
    padding: 20px;
  }

  #spectrum-tool .st-result-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}
