.teacher-feedback-section {
  flex: 1 1 auto;
  min-width: 0;
}

.teacher-feedback-inner {
  min-width: 0;
}

.teacher-feedback-toolbar {
  position: static;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 36px;
}

.teacher-feedback-navigation-slot {
  flex: 0 0 auto;
  min-width: 0;
}

.teacher-feedback-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 22px;
  align-items: center;
  justify-content: flex-end;
}

.teacher-feedback-action,
.teacher-feedback-write {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--color-text);
  cursor: pointer;
  font: inherit;
}

.teacher-feedback-action {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 4px 0;
  font-size: 13px;
  font-weight: 600;
}

.teacher-feedback-action:hover,
.teacher-feedback-action:focus-visible,
.teacher-feedback-write {
  color: var(--color-accent);
}

.teacher-feedback-action:disabled {
  cursor: not-allowed;
  opacity: .55;
}

.teacher-feedback-action:focus-visible,
.teacher-feedback-write:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--color-accent) 60%, transparent);
  outline-offset: 4px;
}

.teacher-feedback-heart,
.teacher-feedback-comment-icon {
  width: 18px;
  height: 18px;
  fill: transparent;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: color 160ms ease, fill 160ms ease, transform 160ms ease;
}

.teacher-feedback-action.is-liked .teacher-feedback-heart {
  fill: currentColor;
  transform: scale(1.05);
}

.teacher-feedback-count,
.teacher-feedback-date {
  color: var(--color-text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.teacher-feedback-status {
  margin: 4px 0 0;
  color: var(--color-text-secondary);
  font-size: 12px;
  text-align: right;
}

.teacher-feedback-status:empty {
  display: none;
}

.teacher-feedback-status.is-error {
  color: var(--color-accent);
}

.teacher-feedback-status.is-success {
  color: #2f5f43;
}

.teacher-feedback-panel {
  width: 100%;
  margin-top: 10px;
  padding-top: 18px;
  border-top: 1px solid var(--color-border);
}

.teacher-feedback-published,
.teacher-feedback-composer {
  padding-top: 0;
}

.teacher-feedback-eyebrow,
.teacher-feedback-reply-label {
  margin: 0 0 8px;
  color: var(--color-accent);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .08em;
}

.teacher-feedback-list-status,
.teacher-feedback-note {
  margin: 0;
  color: var(--color-text-secondary);
  font-size: 13px;
}

.teacher-feedback-comment {
  border-top: 1px solid var(--color-border);
  padding: 18px 0;
}

.teacher-feedback-comment:last-child {
  border-bottom: 1px solid var(--color-border);
}

.teacher-feedback-byline {
  margin: 0;
  font-size: 15px;
}

.teacher-feedback-date {
  margin: 4px 0 0;
}

.teacher-feedback-copy {
  max-width: 720px;
  margin: 12px 0 0;
  line-height: 1.65;
  white-space: pre-wrap;
}

.teacher-feedback-reply {
  margin-top: 18px;
  padding: 12px 0 0 16px;
  border-top: 1px solid var(--color-border);
  border-left: 2px solid var(--color-accent);
}

.teacher-feedback-reply .teacher-feedback-copy {
  margin-top: 5px;
}

.teacher-feedback-write {
  display: inline-block;
  margin-top: 18px;
  padding: 0;
  font-size: 13px;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.teacher-feedback-form-wrap {
  max-width: 680px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--color-border);
}

.teacher-feedback-form {
  display: grid;
  gap: 8px;
}

.teacher-feedback-form label {
  margin-top: 10px;
  font-size: 14px;
  font-weight: 600;
}

.teacher-feedback-form input,
.teacher-feedback-form textarea {
  width: 100%;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  color: var(--color-text);
  font: inherit;
  padding: 11px 12px;
}

.teacher-feedback-form textarea {
  min-height: 124px;
  resize: vertical;
}

.teacher-feedback-form input:focus,
.teacher-feedback-form textarea:focus {
  border-color: var(--color-accent);
  outline: 2px solid color-mix(in srgb, var(--color-accent) 18%, transparent);
  outline-offset: 1px;
}

.teacher-feedback-form button[type="submit"] {
  justify-self: start;
  margin-top: 14px;
}

.teacher-feedback-turnstile {
  min-height: 65px;
  margin-top: 10px;
}

.teacher-feedback-form :disabled {
  cursor: not-allowed;
  opacity: .66;
}

@media (max-width: 680px) {
  .teacher-feedback-toolbar {
    align-items: center;
    flex-wrap: wrap;
    gap: 4px 18px;
  }

  .teacher-feedback-navigation-slot {
    flex: 0 0 auto;
  }

  .teacher-feedback-actions {
    flex: 1 1 180px;
    justify-content: flex-start;
    gap: 4px 18px;
  }

  .teacher-feedback-status {
    text-align: left;
  }

  .teacher-feedback-panel {
    margin-top: 8px;
  }

  .teacher-feedback-copy {
    line-height: 1.6;
  }

  .teacher-feedback-form input,
  .teacher-feedback-form textarea {
    font-size: 16px;
  }

  .teacher-feedback-turnstile {
    max-width: 100%;
    overflow: hidden;
  }
}

@media (prefers-reduced-motion: reduce) {
  .teacher-feedback-heart,
  .teacher-feedback-comment-icon {
    transition: none;
  }
}
