@font-face {
  font-family: "Grail UI";
  src: url("/fonts/checkout-ui.ttf") format("truetype");
}

#page-dialog.sheet:has(> #layer > .grail-boost-sheet) {
  width: min(480px, calc(100% - 32px));
  max-width: 100%;
  max-height: min(var(--sheet-limit, 100dvh), calc(100dvh - 32px));
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: var(--sheet-radius, 24px);
  background: var(--sheet-color, #100f24);
}
#page-dialog:has(> #layer > .grail-boost-sheet) > .native-sheet-grip {
  position: absolute;
  inset: 0 0 auto;
}
.grail-boost-sheet {
  --gb-accent: #d8c7ff;
  box-sizing: border-box;
  display: grid;
  gap: 16px;
  padding: 32px 20px calc(32px + env(safe-area-inset-bottom, 0px));
  font: 400 16px/1.5 Manrope, system-ui, sans-serif;
  color: white;
}
.grail-boost-sheet[data-panel="draw"] { --gb-accent: #ffe3a0; }
.grail-boost-sheet :is(h1,h2,p) { margin: 0; }
.grail-boost-sheet .gb-title { padding-right: 44px; font-size: 24px; font-weight: 800; line-height: 32px; }
.grail-boost-sheet .close-layer {
  inset: 24px 12px auto auto;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: rgb(255 255 255 / 70%);
}
.grail-boost-sheet .gb-body { color: rgb(255 255 255 / 80%); }
.grail-boost-sheet .gb-status, .grail-boost-sheet .gb-rule-heading { display: flex; align-items: center; gap: 8px; }
.grail-boost-sheet .gb-status { color: rgb(255 255 255 / 70%); font-size: 15px; }
.grail-boost-sheet .gb-icon { color: var(--gb-accent); font: 400 14px/1 "Grail UI"; }
.grail-boost-sheet .gb-rule-heading .gb-icon { font-size: 16px; }
.grail-boost-sheet .gb-rules {
  display: grid;
  gap: 6px;
  padding: 16px;
  border: 1px solid rgb(255 255 255 / 10%);
  border-radius: 16px;
  background: rgb(255 255 255 / 5%);
  color: rgb(255 255 255 / 75%);
  font-size: 14px;
  line-height: 20px;
}
.grail-boost-sheet .gb-rule-heading { color: white; font-size: 15px; font-weight: 700; }
.grail-boost-sheet .gb-applied { margin-top: 4px; color: var(--gb-accent); font-weight: 600; }
.grail-boost-sheet .gb-draw-rules, .grail-boost-sheet .gb-note, .grail-boost-sheet .gb-pack-info {
  color: rgb(255 255 255 / 65%); font-size: 14px; line-height: 20px;
}
.grail-boost-sheet .gb-entry { font-size: 14px; font-weight: 600; }
.grail-boost-sheet .gb-switch, .grail-boost-sheet summary, .grail-boost-sheet .related-link {
  box-sizing: border-box; min-height: 44px; padding: 11px 0; font-size: 14px; font-weight: 600; cursor: pointer;
}
.grail-boost-sheet .gb-switch { justify-self: start; color: var(--gb-accent); text-underline-offset: 3px; }
.grail-boost-sheet .gb-options { border-top: 1px solid rgb(255 255 255 / 10%); }
.grail-boost-sheet .gb-options p { margin: 4px 0 12px; }
.grail-boost-sheet .related { display: grid; gap: 0; margin: 0; }
.grail-boost-sheet .related-link { border: 0; border-radius: 0; background: transparent; color: white; }
.grail-boost-sheet :is(a,button,summary):focus-visible { outline: 2px solid var(--gb-accent); outline-offset: 1px; }

@media (max-width: 760px) {
  #page-dialog.sheet:has(> #layer > .grail-boost-sheet) {
    width: 100%; max-height: min(var(--sheet-limit, 100dvh), 96dvh);
    margin: auto 0 0; border-radius: var(--sheet-radius, 24px) var(--sheet-radius, 24px) 0 0;
  }
}
