.rst-public {
  max-width: 900px;
  margin: 20px 0;
}

.rst-header {
  margin-bottom: 20px;
}

.rst-group {
  margin-top: 28px;
  padding-top: 8px;
  border-top: 1px solid #e5e5e5;
}

.rst-group h3 {
  margin: 0 0 12px;
  font-size: 1.25rem;
}

.rst-question {
  margin-bottom: 14px;
}

.rst-label {
  display: block;
  font-weight: 500;
  margin-bottom: 5px;
}

.rst-number {
  font-weight: 700;
}

.rst-hint {
  color: #666;
  white-space: nowrap;
  cursor: pointer;
  text-decoration: underline dotted;
}

.rst-hint:focus {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

.rst-input {
  max-width: 420px;
}

.rst-feedback {
  min-height: 20px;
  font-size: 0.9rem;
  margin-top: 3px;
}

.rst-ok {
  color: #198754;
}

.rst-bad {
  color: #dc3545;
}

.rst-actions {
  margin-top: 22px;
}

.rst-actions .btn {
  margin-right: 8px;
  margin-bottom: 8px;
}

.rst-score {
  margin-top: 12px;
  font-size: 1.05rem;
}

/* Bootstrap 4-friendly fallback */
.rst-public .btn {
  display: inline-block;
  font-weight: 400;
  text-align: center;
  border: 1px solid transparent;
  padding: .375rem .75rem;
  border-radius: .25rem;
  cursor: pointer;
}

.rst-public .btn-primary {
  color: #fff;
  background-color: #007bff;
  border-color: #007bff;
}

.rst-public .btn-warning {
  color: #212529;
  background-color: #ffc107;
  border-color: #ffc107;
}

.rst-public .btn-secondary {
  color: #fff;
  background-color: #6c757d;
  border-color: #6c757d;
}

.rst-public .form-control {
  display: block;
  width: 100%;
  padding: .375rem .75rem;
  font-size: 1rem;
  line-height: 1.5;
  border: 1px solid #ced4da;
  border-radius: .25rem;
}

.rst-public .is-valid {
  border-color: #28a745;
}

.rst-public .is-invalid {
  border-color: #dc3545;
}


/* v5.3 fixed bottom action bar */
.rst-public {
  padding-bottom: 110px;
}

.rst-public .rst-actions {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  background: #fff;
  border-top: 1px solid #ddd;
  padding: 12px 20px;
  display: flex;
  gap: 10px;
  align-items: center;
  box-shadow: 0 -2px 10px rgba(0,0,0,.10);
}

.rst-public .rst-actions .btn {
  margin-right: 0;
  margin-bottom: 0;
}

.rst-public .rst-score {
  margin-top: 0;
  margin-left: auto;
  font-size: 1.05rem;
}

@media (max-width: 768px) {
  .rst-public {
    padding-bottom: 170px;
  }

  .rst-public .rst-actions {
    flex-wrap: wrap;
    padding: 10px;
  }

  .rst-public .rst-actions .btn {
    flex: 1 1 140px;
  }

  .rst-public .rst-score {
    flex: 1 1 100%;
    margin-left: 0;
    text-align: center;
  }
}
