.trace-feedback {
  position: fixed;
  z-index: 1001;
  inset: max(1rem, env(safe-area-inset-top)) auto auto max(1rem, env(safe-area-inset-left));
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: .62rem;
  width: min(25rem, calc(100% - 2rem));
  padding: .85rem;
  border: 1px solid #c69a93;
  border-inline-start-width: 4px;
  border-radius: 6px;
  background: #29201f;
  color: #f6eeea;
  box-shadow: 0 8px 24px #0005;
  animation: trace-feedback-enter 160ms ease-out;
}
.trace-feedback[data-success] { background: #192d24; border-color: #91bc9f; color: #edf9ee; }
.trace-feedback strong { font-size: .87rem; text-transform: uppercase; }
.trace-feedback p { margin-top: .25rem; font-size: .88rem; line-height: 1.35; }
.trace-feedback p:empty { display: none; }
.trace-feedback-mark svg { width: 1.25rem; height: 1.25rem; }
.trace-feedback button { color: inherit; background: transparent; border: 0; font-size: 1.45rem; cursor: pointer; min-width: 36px; min-height: 36px; }
@keyframes trace-feedback-enter { from { opacity: 0; transform: translateY(-.35rem); } }

.trace-terms, .trace-code-dialog {
  color: var(--paper);
  background: #242424 url("/assets/bp-timeline.webp") center / 94px auto repeat;
  border: 1px solid #aaa;
  padding: clamp(1rem, 5vw, 2rem);
  max-width: min(33rem, calc(100% - 2rem));
  max-height: calc(100dvh - 2rem);
}
.trace-terms::backdrop, .trace-code-dialog::backdrop { background: #141414bd; }
.trace-terms p, .trace-code-dialog p { line-height: 1.5; }
.trace-code-dialog strong { display: block; font-size: clamp(1.5rem, 6vw, 2.6rem); }
:where(.checkout-page,.product-page) [aria-invalid="true"] { outline: 2px solid #c47d73; outline-offset: 2px; }
