body.scope-open { overflow: hidden; }
.scope-trigger { min-height: 36px; border: 1px solid currentColor; border-radius: 2px; padding: 0 12px; background: transparent; color: #3f512d; font-family: var(--font-dot); font-size: var(--small); font-weight: 700; cursor: pointer; }
.offer-remediation .scope-trigger, .offer-iso .scope-trigger { color: var(--paper); }
.scope-page-trigger { min-height: 42px; margin-top: 28px; border: 1px solid #aeb1a7; border-radius: 2px; padding: 0 15px; background: transparent; color: var(--paper); font-family: var(--font-dot); font-size: var(--small); font-weight: 700; cursor: pointer; }
.scope-dialog { width: min(1080px, calc(100% - 32px)); max-height: calc(100svh - 32px); margin: auto; border: 0; padding: 0; background: var(--paper); color: var(--ink); }
.scope-dialog::backdrop { background: rgba(17, 18, 15, .78); }
.scope-dialog-shell { padding: clamp(20px, 4vw, 48px); }
.scope-dialog-head { display: grid; grid-template-columns: 1fr auto; gap: 32px; padding-bottom: 28px; border-bottom: 1px solid #c9c4b7; }
.scope-kicker { margin: 0 0 12px; color: var(--accent); font-family: var(--font-dot); font-size: var(--small); font-weight: 700; }
.scope-dialog h2 { max-width: 19ch; margin: 0; font-family: var(--font-dot); font-size: clamp(30px, 4vw, 52px); line-height: 1.04; letter-spacing: -.04em; }
.scope-dialog-head [data-scope-summary] { max-width: 68ch; margin: 18px 0 0; color: var(--muted); }
.scope-close { align-self: start; min-width: 76px; min-height: 42px; border: 1px solid #807d74; border-radius: 2px; background: transparent; color: var(--ink); font-family: var(--font-dot); font-size: var(--small); font-weight: 700; cursor: pointer; }
.scope-notice { margin: 24px 0; padding: 16px 18px; background: #ded8c9; font-size: var(--small); }
.scope-tools { display: grid; grid-template-columns: auto minmax(220px, 1fr) auto; gap: 14px; align-items: center; margin-bottom: 18px; }
.scope-tools label { font-family: var(--font-dot); font-size: var(--small); font-weight: 700; }
.scope-tools input { min-height: 44px; border: 1px solid #aaa597; border-radius: 2px; padding: 0 14px; background: #fff; color: var(--ink); }
.scope-tools p { margin: 0; color: var(--muted); font-size: 12px; }
.scope-legend { display: flex; flex-wrap: wrap; gap: 10px 20px; margin: 0 0 20px; color: var(--muted); font-size: 12px; }
.scope-legend span { display: inline-flex; align-items: center; gap: 7px; }
.scope-legend i { width: 10px; height: 10px; display: inline-block; border-radius: 50%; }
.scope-legend .is-included { background: #4f6238; }
.scope-legend .is-conditional { background: #b57935; }
.scope-legend .is-excluded { background: #8b8982; }
.scope-categories { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.scope-category { border: 1px solid #c9c4b7; background: #fff; }
.scope-category summary { min-height: 72px; display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; padding: 14px 16px; cursor: pointer; list-style: none; }
.scope-category summary::-webkit-details-marker { display: none; }
.scope-category summary span { display: flex; flex-direction: column; gap: 3px; }
.scope-category summary strong { font-family: var(--font-dot); font-size: 15px; line-height: 1.2; }
.scope-category summary small { color: var(--muted); font-size: 12px; }
.scope-category summary b { padding: 5px 7px; border-radius: 2px; font-size: 11px; font-weight: 600; white-space: nowrap; }
.scope-category.is-included summary b { background: #dce5d5; color: #35502a; }
.scope-category.is-conditional summary b { background: #f0dfc9; color: #704817; }
.scope-category.is-excluded summary b { background: #e4e2de; color: #5b5953; }
.scope-category ul { columns: 2; gap: 28px; margin: 0; padding: 0 18px 20px 34px; color: #4f4d45; font-size: 13px; }
.scope-category li { break-inside: avoid; margin-bottom: 7px; }
.scope-category.is-excluded ul { color: #77746c; }
.scope-dialog-foot { display: flex; justify-content: space-between; gap: 24px; align-items: center; margin-top: 28px; padding-top: 24px; border-top: 1px solid #c9c4b7; }
.scope-dialog-foot p { max-width: 62ch; margin: 0; color: var(--muted); font-size: var(--small); }

@media (max-width: 760px) {
  .scope-dialog { width: calc(100% - 16px); max-height: calc(100svh - 16px); }
  .scope-dialog-head { gap: 16px; }
  .scope-tools { grid-template-columns: 1fr; }
  .scope-categories { grid-template-columns: 1fr; }
  .scope-category ul { columns: 1; }
  .scope-dialog-foot { align-items: stretch; flex-direction: column; }
  .scope-dialog-foot .button { width: 100%; }
}
