.contest-help-actions { display: flex; align-items: center; gap: 8px; justify-self: end; }
.pool-help-launcher, .pool-help-dialog {
  --help-ink: #203c31;
  --help-green: #173e35;
  --help-paper: #fffef8;
  --help-muted: #526354;
  --help-line: #d5ddce;
  font-family: inherit;
}
.pool-help-launcher {
  position: fixed;
  right: max(22px, env(safe-area-inset-right));
  bottom: max(22px, env(safe-area-inset-bottom));
  z-index: 90;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 11px 18px 11px 11px;
  border: 1px solid #a8bd9d;
  border-radius: 999px;
  background: var(--help-green);
  color: var(--help-paper);
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 5px 22px #173e3526;
}
.pool-help-mark { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 50%; background: #d6f65a; color: var(--help-green); font-size: 17px; }
.pool-help-dialog {
  position: fixed;
  inset: auto 22px 22px auto;
  margin: 0;
  width: min(430px, calc(100vw - 32px));
  max-width: none;
  max-height: calc(100dvh - 44px);
  padding: 0;
  border: 1px solid var(--help-line);
  border-radius: 20px;
  background: var(--help-paper);
  color: var(--help-ink);
  box-shadow: 0 16px 75px #0a261e40;
  overflow: hidden;
  color-scheme: light;
}
.pool-help-dialog::backdrop { background: #162c2447; }
.pool-help-shell { display: flex; flex-direction: column; max-height: calc(100dvh - 46px); }
.pool-help-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 20px 15px; background: var(--help-green); color: var(--help-paper); }
.pool-help-eyebrow { display: block; color: #d6e3c8; font-size: 10px; letter-spacing: .07em; }
.pool-help-header h2 { margin: 6px 0 0; font-size: 23px; line-height: 1.15; letter-spacing: -.035em; }
.pool-help-dialog .pool-help-close { flex: 0 0 auto; width: 38px; height: 38px; min-width: 38px; padding: 0; background: #ffffff12; border: 1px solid #c6dab64d; border-radius: 50%; color: var(--help-paper); font-size: 26px; line-height: 1; font-weight: 400; }
.pool-help-description { margin: 0; padding: 14px 20px; border-bottom: 1px solid var(--help-line); color: var(--help-muted); font-size: 11px; line-height: 1.6; }
.pool-help-log { flex: 1 1 auto; overflow-y: auto; overscroll-behavior: contain; min-height: 100px; max-height: 310px; padding: 18px 20px 4px; }
.pool-help-message { margin: 0 0 14px; border: 1px solid var(--help-line); border-radius: 11px; padding: 12px 14px; background: #f4f5ec; overflow-wrap: anywhere; }
.pool-help-message-user { margin-left: 30px; background: #e9efd9; border-color: #d4dfbc; }
.pool-help-speaker { display: block; margin-bottom: 5px; font-size: 10px; font-weight: 750; color: var(--help-muted); }
.pool-help-message p { margin: 0; color: var(--help-ink); font-size: 13px; line-height: 1.65; white-space: pre-wrap; }
.pool-help-sources { list-style: none; margin: 11px 0 0; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.pool-help-sources a { color: var(--help-green); font-size: 12px; font-weight: 650; text-decoration: underline; text-underline-offset: 3px; }
.pool-help-suggestions { display: flex; flex-direction: column; gap: 6px; flex: 0 1 auto; overflow-y: auto; padding: 0 20px 8px; }
.pool-help-suggestions[hidden] { display: none; }
.pool-help-dialog .pool-help-suggestion { background: transparent; border: 1px solid #bdcbb4; color: var(--help-green); border-radius: 8px; padding: 9px 11px; text-align: left; font-size: 11px; font-weight: 600; line-height: 1.45; }
.pool-help-status { min-height: 17px; padding: 0 20px; margin: 0 0 5px; color: var(--help-muted); font-size: 11px; line-height: 1.5; }
.pool-help-form { border-top: 1px solid var(--help-line); margin: 0; padding: 12px 20px 10px; }
.pool-help-form label { display: block; margin-bottom: 6px; font-size: 11px; color: var(--help-ink); font-weight: 700; }
.pool-help-form textarea { display: block; width: 100%; min-height: 64px; max-height: 110px; resize: vertical; margin: 0; padding: 11px; border: 1px solid #aebea5; border-radius: 8px; background: #fffefb; color: var(--help-ink); font: inherit; font-size: 14px; line-height: 1.45; }
.pool-help-form textarea::placeholder { color: #647060; opacity: 1; }
.pool-help-form-actions { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 8px; }
.pool-help-limit { font-size: 10px; color: var(--help-muted); }
.pool-help-dialog .pool-help-send { min-width: 64px; min-height: 36px; padding: 8px 16px; border-radius: 7px; background: var(--help-green); color: var(--help-paper); font-size: 12px; }
.pool-help-dialog button:disabled { opacity: .6; cursor: wait; }
.pool-help-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 0 20px 12px; color: var(--help-muted); font-size: 10px; }
.pool-help-dialog .pool-help-reset { background: transparent; border: 0; border-radius: 3px; color: var(--help-green); font-size: 10px; padding: 6px 0; text-decoration: underline; text-underline-offset: 3px; font-weight: 600; }
.pool-help-dialog :focus-visible, .pool-help-launcher:focus-visible { outline: 3px solid #678841; outline-offset: 3px; }
.pool-help-dialog .pool-help-close:focus-visible { outline-color: #d6f65a; }
@media (max-width: 600px) {
  .pool-help-launcher { right: max(12px, env(safe-area-inset-right)); bottom: max(12px, env(safe-area-inset-bottom)); font-size: 12px; }
  .pool-help-dialog { inset: auto 8px max(8px, env(safe-area-inset-bottom)) 8px; width: auto; max-height: calc(100dvh - 16px); border-radius: 16px; }
  .pool-help-shell { max-height: calc(100dvh - 18px); }
  .pool-help-header { padding: 16px; }
  .pool-help-description { padding: 10px 16px; }
  .pool-help-log { padding: 12px 16px 0; max-height: 32dvh; }
  .pool-help-suggestions { padding: 0 16px 8px; }
  .pool-help-status { padding: 0 16px; }
  .pool-help-form { padding: 10px 16px 8px; }
  .pool-help-form textarea { font-size: 16px; }
  .pool-help-footer { padding: 0 16px 9px; }
}
@media (max-height: 590px) {
  .pool-help-header { padding: 10px 16px; }
  .pool-help-eyebrow { display: none; }
  .pool-help-description { padding: 8px 16px; }
  .pool-help-suggestions { max-height: 70px; }
  .pool-help-log { min-height: 64px; }
}
