html.gw-risk-pending body { visibility: hidden !important; }
html.gw-risk-locked, html.gw-risk-locked body { overflow: hidden !important; overscroll-behavior: none; }
html.gw-risk-locked body > :not(#gw-risk-gate) {
  pointer-events: none !important;
  user-select: none !important;
}
#gw-risk-gate {
  box-sizing: border-box;
  position: fixed;
  inset: 0;
  margin: auto;
  width: min(560px, calc(100% - 32px));
  max-width: none;
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
  padding: 0;
  border: 1px solid #ef4444;
  border-radius: 22px;
  background: #0c1d30;
  color: #edf1f7;
  box-shadow: 0 24px 100px rgba(0, 0, 0, .55);
  overflow: auto;
  overscroll-behavior: contain;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  text-align: left;
  line-height: 1.8;
  z-index: 2147483647;
}
#gw-risk-gate:not([open]) { display: none; }
#gw-risk-gate::backdrop {
  background: transparent;
}
#gw-risk-gate .gw-risk-panel { padding: 32px; }
#gw-risk-gate .gw-risk-heading { display: flex; align-items: center; gap: 16px; margin-bottom: 22px; }
#gw-risk-gate .gw-risk-icon {
  display: grid; place-items: center; flex: none; width: 40px; height: 40px;
  border: 1px solid rgba(239,68,68,.45); border-radius: 14px; color: #ff8a8a;
  background: rgba(239,68,68,.10); font: 700 24px/1 sans-serif;
}
#gw-risk-gate .gw-risk-brand { margin: 0 0 2px; color: #a9b6c2; font-size: 12px; letter-spacing: 1px; }
#gw-risk-gate #gw-risk-title { margin: 0; color: #fff; font-size: 22px; font-weight: 700; line-height: 1.35; }
#gw-risk-gate #gw-risk-title:focus { outline: none !important; }
#gw-risk-gate #gw-risk-copy p { margin: 0 0 14px; font-size: 14px; line-height: 1.85; color: #d5dce7; }
#gw-risk-gate #gw-risk-copy .gw-risk-important { color: #ffafaf; font-weight: 650; }
#gw-risk-gate .gw-risk-memory { margin: 22px 0 18px; color: #8c9da9; font-size: 12px; }
#gw-risk-gate .gw-risk-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
#gw-risk-gate .gw-risk-actions > * {
  box-sizing: border-box; display: flex; align-items: center; justify-content: center;
  min-width: 0; min-height: 44px; padding: 10px 14px; margin: 0; border: 1px solid #475368;
  border-radius: 10px; font-family: inherit; font-size: 14px;
  line-height: 1.4; font-weight: 600; cursor: pointer; text-decoration: none;
}
#gw-risk-gate #gw-risk-agree { background: linear-gradient(90deg, #efd397, #c9a45c); border-color: transparent; color: #15120d; }
#gw-risk-gate #gw-risk-agree:hover { filter: brightness(1.08); }
#gw-risk-gate #gw-risk-exit { background: rgba(201,164,92,.06); border-color: rgba(201,164,92,.45); color: #efd397; }
#gw-risk-gate #gw-risk-exit:hover { background: rgba(201,164,92,.14); }
#gw-risk-gate .gw-risk-actions > *:focus-visible { outline: 3px solid rgba(201,164,92,.6); outline-offset: 3px; }
#gw-risk-gate.gw-risk-fallback[open] {
  display: grid; place-items: center; width: 100%; height: 100%; max-height: none;
  border: 0; border-radius: 0; background: transparent;
}
#gw-risk-gate.gw-risk-fallback .gw-risk-panel {
  box-sizing: border-box; width: min(560px, calc(100% - 32px));
  max-height: calc(100vh - 32px); overflow: auto;
  background: #0c1d30; border: 1px solid #ef4444; border-radius: 22px;
}
@media (max-width: 480px) {
  #gw-risk-gate { border-radius: 18px; }
  #gw-risk-gate .gw-risk-panel { padding: 24px 20px; }
  #gw-risk-gate #gw-risk-title { font-size: 20px; }
  #gw-risk-gate .gw-risk-heading { gap: 12px; margin-bottom: 20px; }
}
@media (max-height: 560px) {
  #gw-risk-gate .gw-risk-panel { padding: 20px; }
}
