/* The demo of what SiteGuard does (demo.js): a drawn browser window playing one
   scene after another, with tabs to pick one. Drawn with the kit's colours, so
   it is right in light and dark wherever it sits: the sign-in pages, the home
   page and the extension's welcome page (a copy, by its tools/sync-kit.mjs).

   Each page in the window is written as the real one would be (a results page,
   a feed, a chat, a listing), in that site's own plain colours, and follows
   the theme the way those sites' own dark modes do. What SiteGuard draws over
   it is the extension's own: content.js's red outline and "⚠ SiteGuard" label,
   the amber dashed reminder, the phone chip, block.html's card, and the side
   panel as sidepanel.html lays it out (extension.css). */
.sgd { --sgd-h: 360px; --sgd-flag: #dc2626; --sgd-link: #1a0dab; --sgd-page: #fff; --sgd-sub: #4d5156; --sgd-soft: #f0f2f5; --sgd-rule: #e4e6eb;
  --sgd-chat: #efeae2; --sgd-in: #fff; --sgd-out: #d9fdd3; --sgd-shade: rgba(20, 20, 24, .4);
  --sgd-shadow: 0 34px 70px -30px rgba(20, 20, 30, .32), 0 14px 28px -16px rgba(20, 20, 30, .16);
  position: relative; min-width: 0; }
.sgd[data-size="large"] { --sgd-h: 392px; }
:root[data-theme="dark"] .sgd { --sgd-flag: #f05252; --sgd-link: #99c3ff; --sgd-page: #1f1f22; --sgd-sub: #a9abb2; --sgd-soft: #18191a; --sgd-rule: #3a3b3c;
  --sgd-chat: #0b141a; --sgd-in: #202c33; --sgd-out: #005c4b; --sgd-shade: rgba(0, 0, 0, .6);
  --sgd-shadow: 0 34px 70px -30px rgba(0, 0, 0, .85), 0 14px 28px -16px rgba(0, 0, 0, .6); }
.sgd svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.t-phishing { --c: var(--phishing); } .t-malware { --c: var(--malware); } .t-gambling { --c: var(--gambling); } .t-nsfw { --c: var(--nsfw); }
.t-scam { --c: var(--red); } .t-file { --c: var(--malware); } .t-data { --c: var(--amber); } .t-ok { --c: var(--green); }

/* The tabs: plain words on a line, the picked one underlined. */
/* The row scrolls sideways when it is wider than the demo: swiped, dragged, wheeled, or moved
   by the arrows at its ends, which come with a fade where there is more to see. */
.sgd-tabs-wrap { position: relative; margin: 0 0 16px; border-bottom: 1px solid var(--line); }
.sgd-tabs { display: flex; gap: 14px; overflow-x: auto; scrollbar-width: none; cursor: grab; user-select: none; -webkit-user-select: none; }
.sgd-tabs.is-dragging { cursor: grabbing; }
.sgd-tabs.is-dragging .sgd-tab { pointer-events: none; }
.sgd .sgd-tabs-arrow { position: absolute; top: 0; bottom: 1px; z-index: 1; display: grid; width: 40px; min-height: 0; margin: 0; padding: 0; border: 0; border-radius: 0; box-shadow: none;
  color: var(--ink); cursor: pointer; opacity: 0; pointer-events: none; transition: opacity .2s; place-items: center; }
.sgd .sgd-tabs-arrow svg { width: 18px; height: 18px; padding: 3px; border-radius: 50%; background: var(--surface); box-shadow: 0 0 0 1px var(--line), 0 2px 6px rgba(0, 0, 0, .12);
  fill: none; stroke: currentColor; stroke-width: 2.2; }
.sgd .sgd-tabs-arrow:hover svg { background: var(--surface-soft); }
.sgd .sgd-tabs-arrow.is-prev { left: 0; justify-items: start; background: linear-gradient(90deg, var(--sgd-fade, var(--surface)) 45%, transparent); }
.sgd .sgd-tabs-arrow.is-next { right: 0; justify-items: end; background: linear-gradient(270deg, var(--sgd-fade, var(--surface)) 45%, transparent); }
.sgd-tabs-wrap.can-prev .is-prev, .sgd-tabs-wrap.can-next .is-next { opacity: 1; pointer-events: auto; }
.sgd .sgd-tabs-arrow.is-prev:hover, :root[data-theme="dark"] .sgd .sgd-tabs-arrow.is-prev:hover { background: linear-gradient(90deg, var(--sgd-fade, var(--surface)) 45%, transparent); box-shadow: none; }
.sgd .sgd-tabs-arrow.is-next:hover, :root[data-theme="dark"] .sgd .sgd-tabs-arrow.is-next:hover { background: linear-gradient(270deg, var(--sgd-fade, var(--surface)) 45%, transparent); box-shadow: none; }
.sgd-tabs::-webkit-scrollbar { display: none; }
.sgd-tab { flex: none; min-height: 0; margin: 0; padding: 0 0 9px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: none; box-shadow: none;
  color: var(--muted); font: inherit; font-size: var(--fs-small); font-weight: 600; white-space: nowrap; cursor: pointer; transition: color .2s, border-color .2s; }
.sgd-tab:hover { background: none; color: var(--ink); }
.sgd-tab[aria-pressed="true"] { border-bottom-color: var(--ink); color: var(--ink); }
.sgd-tab:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* The window. */
.sgd-window { position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: var(--sgd-page); box-shadow: var(--sgd-shadow); text-align: left; }
.sgd-bar { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); background: var(--surface-soft); }
.sgd-dots { display: flex; gap: 6px; } .sgd-dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--line-strong); }
.sgd-url { display: flex; flex: 1; min-width: 0; align-items: center; gap: 7px; height: 28px; padding: 0 10px; border-radius: 999px; background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line); color: var(--muted); font-size: var(--fs-small); white-space: nowrap; overflow: hidden; }
.sgd-url svg { width: 12px; height: 12px; flex: none; stroke-width: 2; }
.sgd-url-text { overflow: hidden; color: var(--ink-soft); text-overflow: ellipsis; }
.sgd-url-text b { color: var(--red); font-weight: 600; }
.sgd-caret { display: none; flex: none; width: 1px; height: 14px; margin-left: -6px; background: var(--ink); animation: sgd-blink 1s steps(1) infinite; }
.sgd[data-step="typing"] .sgd-caret { display: inline-block; }
@keyframes sgd-blink { 50% { opacity: 0; } }
/* SiteGuard's toolbar button: its own icon, a spinning arc while it checks, and the red "!" badge once it found something. */
.sgd-ext { position: relative; display: grid; width: 28px; height: 28px; flex: none; place-items: center; border-radius: 8px; }
.sgd-ext img { display: block; width: 18px; height: 18px; }
.sgd-ext::after { position: absolute; inset: 0; border: 2px solid transparent; border-top-color: var(--accent); border-radius: 50%; content: ""; opacity: 0; transition: opacity .2s; }
.sgd[data-step="scan"] .sgd-ext::after { opacity: 1; animation: sgd-spin .7s linear infinite; }
.sgd-count { position: absolute; top: -3px; right: -5px; min-width: 14px; height: 14px; padding: 0 3px; border-radius: 4px; background: #b0353a; color: #fff;
  font-size: 10px; font-weight: 700; line-height: 14px; text-align: center; opacity: 0; transform: scale(.4); transition: opacity .15s, transform .15s; }
.sgd[data-step="found"] .sgd-count { opacity: 1; transform: none; transition: opacity .2s, transform .5s var(--spring-pop); }
@keyframes sgd-spin { to { transform: rotate(1turn); } }

/* The page, and the side panel that opens beside it. */
.sgd-body { display: flex; height: var(--sgd-h); container-type: inline-size; }
.sgd-page { position: relative; flex: 1 1 auto; min-width: 0; overflow: hidden; background: var(--sgd-page); container: sgd-page / inline-size; }
.sgd-scene { position: absolute; inset: 0; overflow: hidden; color: var(--ink); font-size: 13px; line-height: 1.45; opacity: 0; visibility: hidden; transition: opacity .35s, visibility 0s .35s; }
.sgd-scene.is-on { opacity: 1; visibility: visible; transition: opacity .35s; }
.sgd[data-step="typing"] .sgd-scene { opacity: 0; visibility: hidden; transition: opacity .2s, visibility 0s .2s; }
/* A new tab while the address is typed: never an empty white box. */
.sgd-blank { position: absolute; inset: 0; display: grid; place-items: center; opacity: 0; transition: opacity .3s; pointer-events: none; }
.sgd-blank img { opacity: .16; filter: grayscale(1); }
.sgd[data-step="typing"] .sgd-blank { opacity: 1; }

/* The side panel (sidepanel.html): opens once the check is done. */
.sgd-panel { flex: none; width: 0; overflow: hidden; border-left: 0 solid var(--line); background: var(--canvas); transition: width .45s var(--spring), border-width 0s .45s; }
.sgd[data-answer="panel"][data-step="found"] .sgd-panel { width: 46%; border-left-width: 1px; transition: width .6s var(--spring) .35s; }
.sgd[data-panel][data-step="found"] .sgd-panel { width: 46%; border-left-width: 1px; transition: width .6s var(--spring); }
.sgd-panel-in { width: 46cqi; height: 100%; overflow: hidden; box-sizing: border-box; font-size: 12px; line-height: 1.4; }
.sgd-panel-head { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; border-bottom: 1px solid var(--line); background: var(--surface); }
.sgd-logo-img { width: 66px; height: 21px; flex: none; background: var(--sgd-logo) left center / contain no-repeat; }
:root[data-theme="dark"] .sgd-logo-img { background-image: var(--sgd-logo-dark); }
.sgd-panel-head small { padding-left: 8px; border-left: 1px solid var(--line); color: var(--muted); font-size: 10.5px; white-space: nowrap; }
.sgd-pv { display: none; }
.sgd-pv-in { flex: 1 1 auto; min-height: 0; padding: 10px; overflow: hidden; -webkit-mask-image: linear-gradient(#000 calc(100% - 14px), transparent); mask-image: linear-gradient(#000 calc(100% - 14px), transparent); }
/* A column: the head, what was found (scrolled in the explorer's demo, as the real panel is), then the foot. */
.sgd-pv.is-on { display: flex; height: 100%; flex-direction: column; }
.sgd.is-fixed .sgd-pv-in { overflow-y: auto; scrollbar-width: thin; overscroll-behavior: contain; }
/* The foot, sidepanel.html's: "Is this page safe?" with Safe and Unsafe (or Report this conversation),
   then Local detection and Rescan. */
.sgd-fb { flex: none; margin: 0 10px 8px; padding: 9px 10px; border-radius: 10px; background: var(--surface); box-shadow: var(--shadow); }
.sgd-fb > b { display: block; margin-bottom: 7px; color: var(--ink); font-size: 11.5px; font-weight: 650; }
.sgd-fb-acts { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.sgd-fb-acts.is-one { grid-template-columns: 1fr; }
.sgd-fb-acts span { display: flex; align-items: center; justify-content: center; gap: 5px; padding: 5px 0; border-radius: 8px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line), 0 1px 2px rgba(0, 0, 0, .06);
  color: var(--ink); font-size: 11px; font-weight: 600; white-space: nowrap; }
.sgd-fb-acts svg { width: 12px; height: 12px; }
.sgd-fb-thanks { display: none; color: var(--green); font-size: 11px; font-weight: 600; }
.sgd[data-rep="rated"] .sgd-fb-acts { display: none; }
.sgd[data-rep="rated"] .sgd-fb-thanks { display: block; }
.sgd-pv-foot { display: flex; flex: none; align-items: center; justify-content: space-between; height: 28px; padding: 0 12px; border-top: 1px solid var(--line); background: var(--surface); color: var(--muted); font-size: 10.5px; }
.sgd-pv-foot span { display: inline-flex; align-items: center; gap: 5px; } .sgd-pv-foot span + span { color: var(--ink); font-weight: 600; }
.sgd-pv-foot svg { width: 11px; height: 11px; }
/* The report form over the panel (Unsafe, or Report this conversation), and its thanks once sent. */
.sgd-rep { position: absolute; inset: 0; z-index: 2; display: none; flex-direction: column; background: var(--canvas); }
.sgd-panel-in { position: relative; }
.sgd[data-rep="form"] .sgd-rep, .sgd[data-rep="sent"] .sgd-rep { display: flex; }
.sgd-rep-head b { color: var(--ink); font-size: 12px; font-weight: 650; }
.sgd-rep-back { display: grid; width: 24px; height: 24px; margin-left: -4px; place-items: center; border-radius: 7px; color: var(--ink); }
.sgd-rep-back svg { width: 14px; height: 14px; }
.sgd-rep-form { display: flex; flex-direction: column; -webkit-mask-image: none; mask-image: none; }
.sgd-rep-form .sgd-sp-h { margin: 2px 0 6px; } .sgd-rep-form .sgd-sp-h + .sgd-rep-note { margin-bottom: 6px; }
.sgd-rep-cats { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 10px; }
.sgd-rep-cats span { padding: 3px 9px; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); color: var(--ink-soft); font-size: 10.5px; font-weight: 600; }
.sgd-rep-cats span.is-on { background: var(--ink); box-shadow: none; color: var(--surface); }
.sgd-rep-note { display: block; min-height: 40px; padding: 6px 8px; border-radius: 8px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); color: var(--ink); font-size: 11px; }
.sgd-rep-hint { display: block; margin-bottom: 8px; color: var(--muted); font-size: 10px; line-height: 1.4; }
.sgd-rep-send { padding: 7px 0; border-radius: 9px; background: linear-gradient(180deg, #15a093 0%, var(--accent) 100%); color: #fff; font-size: 11.5px; font-weight: 600; text-align: center; }
.sgd-rep-done { display: none; flex: 1; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 16px; text-align: center; }
.sgd-rep-done i { display: grid; width: 34px; height: 34px; place-items: center; color: var(--green); } .sgd-rep-done svg { width: 30px; height: 30px; }
.sgd-rep-done b { color: var(--ink); font-size: 13px; } .sgd-rep-done small { color: var(--muted); font-size: 11px; line-height: 1.45; }
.sgd[data-rep="sent"] .sgd-rep-form { display: none; } .sgd[data-rep="sent"] .sgd-rep-done { display: flex; }
/* The status card: the page on its white lid, the verdict on the tone's bed. */
.sgd-status { overflow: hidden; border: 1px solid var(--red-line); border-radius: 10px; background: var(--red-soft); }
.sgd-sp-site { display: flex; align-items: center; gap: 8px; padding: 8px 9px; border-bottom: 1px solid var(--red-line); background: var(--surface); }
.sgd-sp-site > i { display: grid; width: 20px; height: 20px; flex: none; place-items: center; color: var(--muted); }
.sgd-sp-site > i svg { width: 16px; height: 16px; }
.sgd-sp-site > span:not(.sgd-live) { flex: 1; min-width: 0; }
.sgd-sp-site b { display: block; overflow: hidden; color: var(--ink); font-size: 11.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.sgd-sp-site small { display: block; overflow: hidden; color: var(--muted); font-size: 10.5px; text-overflow: ellipsis; white-space: nowrap; }
.sgd-live { display: inline-flex; flex: none; align-items: center; gap: 4px; height: 17px; padding: 0 6px; border: 1px solid var(--green-line); border-radius: 999px; background: var(--green-soft);
  color: var(--green); font-size: 9.5px; font-weight: 600; }
.sgd-live i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.sgd-verdict { display: flex; align-items: center; gap: 8px; padding: 9px; }
.sgd-verdict > i { display: grid; width: 22px; height: 22px; flex: none; place-items: center; color: var(--red); }
.sgd-verdict > i svg { width: 20px; height: 20px; }
.sgd-verdict b { display: block; color: var(--red); font-size: 12px; font-weight: 650; }
.sgd-status.is-ok { border-color: var(--green-line); background: var(--green-soft); }
.sgd-status.is-ok .sgd-sp-site { border-bottom-color: var(--green-line); }
.sgd-status.is-ok .sgd-verdict > i, .sgd-status.is-ok .sgd-verdict b { color: var(--green); }
.sgd-empty { margin: 0; padding: 10px; border-radius: 10px; background: var(--surface-soft); box-shadow: var(--shadow); color: var(--muted); font-size: 11px; line-height: 1.45; }
.sgd-status.is-amber { border-color: var(--amber-line); background: var(--amber-soft); }
.sgd-status.is-amber .sgd-sp-site { border-bottom-color: var(--amber-line); }
.sgd-status.is-amber .sgd-verdict > i, .sgd-status.is-amber .sgd-verdict b { color: var(--amber); }
.sgd-verdict small { display: block; color: var(--muted); font-size: 10.5px; }
.sgd-sp-h { margin: 12px 0 6px; color: var(--ink); font-size: 12px; font-weight: 600; }
/* A category's fold, and a card for each finding on its bed. */
.sgd-group + .sgd-group { margin-top: 6px; }
.sgd-group { border-radius: 10px; background: var(--surface-soft); box-shadow: var(--shadow); }
.sgd-group-head { display: flex; align-items: center; gap: 8px; padding: 8px 9px; }
.sgd-dot { width: 10px; height: 10px; flex: none; border-radius: 3px; background: var(--c); }
.sgd-group-head b { color: var(--ink); font-size: 11.5px; font-weight: 600; }
.sgd-group ul { display: grid; grid-template-columns: minmax(0, 1fr); gap: 5px; margin: 0; padding: 0 6px 6px; list-style: none; }
.sgd-group li { display: flex; align-items: center; gap: 7px; padding: 7px 8px; border-radius: 8px; background: var(--surface); box-shadow: var(--shadow); opacity: 0; transform: translateY(4px); }
.sgd[data-step="found"] .sgd-group li { opacity: 1; transform: none; transition: opacity .3s .8s, transform .5s var(--spring) .8s; }
.sgd[data-step="found"] .sgd-group li + li { transition-delay: .95s; }
.sgd-sev { width: 7px; height: 7px; flex: none; border-radius: 50%; background: var(--c); }
.sgd-ft { flex: 1; min-width: 0; overflow: hidden; color: var(--ink); font-size: 11.5px; font-weight: 600; line-height: 1.3; }
.sgd-ft.is-host { text-overflow: ellipsis; white-space: nowrap; }
.sgd-ft.is-host { font: 500 11px/1.4 var(--mono, ui-monospace, SFMono-Regular, Menlo, monospace); }
.sgd-ftag { flex: none; padding: 0 5px; border-radius: 4px; background: var(--canvas); color: var(--muted); font-size: 10px; font-weight: 600; line-height: 16px; }

/* The check: a band of the brand's colour sweeping down the page. */
.sgd-scan { position: absolute; top: 0; right: 0; left: 0; height: 80px; opacity: 0; pointer-events: none;
  background: linear-gradient(180deg, transparent, color-mix(in srgb, var(--accent-bright) 16%, transparent) 70%, color-mix(in srgb, var(--accent-bright) 40%, transparent)); }
.sgd[data-step="scan"] .sgd-scan { animation: sgd-sweep 1.3s cubic-bezier(.45, 0, .55, 1) forwards; }
@keyframes sgd-sweep { 0% { opacity: 1; transform: translateY(-80px); } 90% { opacity: 1; } 100% { opacity: 0; transform: translateY(var(--sgd-h)); } }

/* The block page coming up over the page, as block.html draws it: the mark on the left, the words on the right. */
.sgd-shade { position: absolute; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(0, 0, 0, 0); transition: background-color .4s; }
.sgd[data-step="found"] .sgd-shade { background: var(--sgd-shade); }
.sgd-block { display: grid; width: 100%; max-width: 392px; grid-template-columns: 32px minmax(0, 1fr); column-gap: 13px; padding: 20px 20px 16px; border-radius: 15px; background: var(--surface);
  box-shadow: 0 22px 44px -12px rgba(0, 0, 0, .35); opacity: 0; transform: translateY(22px) scale(.94); transition: opacity .2s, transform .2s; }
:root[data-theme="dark"] .sgd-block { background: var(--surface-soft); box-shadow: 0 0 0 1px var(--line-strong), 0 22px 44px -12px rgba(0, 0, 0, .7); }
.sgd[data-step="found"] .sgd-block { opacity: 1; transform: none; transition: opacity .25s, transform .65s var(--spring-bounce); }
.sgd-mark { width: 32px; height: 32px; color: var(--c); }
.sgd-mark svg { width: 32px; height: 32px; stroke-width: 1.6; }
.sgd-mark path, .sgd-mark rect { stroke-dasharray: 1; stroke-dashoffset: 1; }
.sgd[data-step="found"] .sgd-mark :is(path, rect) { animation: sgd-draw .7s cubic-bezier(.45, 0, .2, 1) .15s forwards; }
@keyframes sgd-draw { to { stroke-dashoffset: 0; } }
.sgd-cat { display: block; margin-bottom: 2px; color: var(--c); font-size: var(--fs-caption); font-weight: 700; }
.sgd-block strong { display: block; color: var(--ink); font-size: var(--fs-h3); line-height: 1.3; }
.sgd-block p { margin: 4px 0 0; color: var(--muted); font-size: var(--fs-small); line-height: 1.5; }
/* block.html's blocked address: the site in ink, its path muted, after the category's no-entry mark. */
.sgd-bp-url { display: flex; grid-column: 1 / -1; align-items: center; gap: 10px; min-width: 0; margin-top: 12px; padding: 7px 11px; border-radius: 10px; background: var(--surface-soft); }
:root[data-theme="dark"] .sgd-bp-url { background: var(--surface); }
.sgd-bp-url > i { display: grid; flex: none; color: var(--c); } .sgd-bp-url svg { width: 15px; height: 15px; }
.sgd-bp-url > span { min-width: 0; }
.sgd-bp-url small { display: block; color: var(--muted); font-size: 10.5px; font-weight: 600; line-height: 1.3; }
.sgd-bp-addr { display: block; overflow: hidden; color: var(--muted); font-size: 12.5px; text-overflow: ellipsis; white-space: nowrap; }
.sgd-bp-addr b { color: var(--ink); font-weight: 600; }
.sgd-block .sgd-chips { grid-column: 1 / -1; margin: 8px 0 0; }
/* Advanced, folded as block.html has it: Hold to proceed and Always allow this site inside. */
.sgd-adv { grid-column: 1 / -1; margin-top: 10px; border-top: 1px solid var(--line); }
.sgd-adv-t { display: inline-flex; align-items: center; gap: 4px; padding: 7px 0 2px; color: var(--muted); font-size: 11.5px; font-weight: 600; }
.sgd-adv-t svg { width: 12px; height: 12px; stroke-width: 2.2; transition: transform .3s var(--spring-bounce); }
.sgd[data-adv] .sgd-adv-t svg { transform: rotate(90deg); }
.sgd-adv-body { display: none; flex-wrap: wrap; align-items: center; gap: 6px 12px; padding: 6px 0 2px; }
.sgd[data-adv] .sgd-adv-body { display: flex; }
.sgd-hold { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); color: var(--ink); font-size: 11.5px; font-weight: 600; }
.sgd-hold svg { width: 12px; height: 12px; color: var(--c); stroke-width: 2.4; }
.sgd-allow { color: var(--ink-soft); font-size: 11.5px; font-weight: 600; text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
.sgd-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.sgd-chips span { padding: 3px 9px; border-radius: 999px; background: var(--canvas); color: var(--ink-soft); font-size: var(--fs-caption); font-weight: 600; }
:root[data-theme="dark"] .sgd-chips span { background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.sgd-row { display: grid; grid-column: 1 / -1; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.sgd-row span { padding: 8px 0; border-radius: 10px; font-size: var(--fs-small); font-weight: 600; text-align: center; }
.sgd-row .go { background: linear-gradient(180deg, #15a093 0%, var(--accent) 100%); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25); }
.sgd-row .on { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line), 0 1px 2px rgba(0, 0, 0, .08); }
:root[data-theme="dark"] .sgd-row .on { background: var(--surface); }
/* In the explorer's demo what a visitor could press can be pressed: it says so with the pointer and a lift. */
.sgd.is-fixed[data-step="found"] :is(.sgd-row span, .sgd-adv-t, .sgd-hold, .sgd-allow, .sgd-note-acts span, .sgd-guard-acts span, .sgd-fb-acts span,
  .sgd-rep-cats span, .sgd-rep-send, .sgd-rep-back, .sgd-then-acts span) { cursor: pointer; transition: filter .15s, box-shadow .15s; }
.sgd.is-fixed[data-step="found"] :is(.sgd-row span, .sgd-hold, .sgd-note-acts span, .sgd-guard-acts span, .sgd-fb-acts span, .sgd-rep-cats span, .sgd-rep-send, .sgd-then-acts span):hover { filter: brightness(.96); }
.sgd.is-fixed[data-step="found"] :is(.sgd-adv-t, .sgd-allow, .sgd-rep-back):hover { color: var(--ink); }
/* Where a choice leads (the explorer draws it): over the page, in front of the warning it answers. */
.sgd-then { position: absolute; inset: 0; z-index: 8; display: none; place-items: center; padding: 16px; background: var(--sgd-shade); }
.sgd[data-then] .sgd-then { display: grid; }
.sgd[data-then] .sgd-scene.is-on :is(.sgd-shade > .sgd-block, .sgd-note, .sgd-guard, .sgd-upcard) { visibility: hidden; }
.sgd[data-then] .sgd-scene.is-on .sgd-shade { background: none; }
.sgd-then .sgd-block { animation: sgd-then .55s var(--spring-bounce) both; }
@keyframes sgd-then { from { opacity: 0; transform: translateY(14px) scale(.96); } }
.sgd-then .sgd-mark circle { color: var(--c); }
.sgd-then .sgd-chips { grid-column: 2; margin: 10px 0 0; }
.sgd-then-acts { display: grid; grid-column: 1 / -1; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.sgd-then-acts.is-one { grid-template-columns: 1fr; }
.sgd-then-acts span { padding: 8px 0; border-radius: 10px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); color: var(--ink); font-size: var(--fs-small); font-weight: 600; text-align: center; }
.sgd-then-acts .is-go { background: linear-gradient(180deg, #15a093 0%, var(--accent) 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25); color: #fff; }

/* What content.js draws on a page: a red outline with its "⚠ SiteGuard" label, and a wavy red underline on the link. */
.sgd-flag { position: relative; outline: 2px solid transparent; outline-offset: 3px; transition: outline-color .3s, box-shadow .3s; }
.sgd-flag::after { position: absolute; top: -10px; right: 8px; z-index: 2; padding: 2px 6px; border-radius: 999px; background: var(--sgd-flag); color: #fff; content: "⚠ SiteGuard";
  font-size: 10px; font-weight: 600; line-height: 1.4; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); opacity: 0; transform: scale(.6); transition: opacity .15s, transform .15s; }
.sgd[data-step="found"] .sgd-flag { outline-color: var(--sgd-flag); box-shadow: 0 0 0 3px color-mix(in srgb, var(--sgd-flag) 14%, transparent); }
.sgd[data-step="found"] .sgd-flag::after { opacity: 1; transform: none; transition: opacity .2s .1s, transform .5s var(--spring-pop) .1s; }
.sgd[data-step="found"] .sgd-flag :is(.sgd-link, u) { color: var(--sgd-flag); text-decoration: underline wavy var(--sgd-flag); text-underline-offset: 3px; }
/* The reminder on a message asking for money: amber and dashed, below the red of a warning. */
.sgd-remind { position: relative; outline: 2px dashed transparent; outline-offset: 3px; transition: outline-color .3s; }
.sgd-remind-tag { position: absolute; bottom: -12px; left: 8px; max-width: calc(100% - 16px); overflow: hidden; padding: 1px 6px; border: 1px solid #f0c36d; border-radius: 999px;
  background: #fff4d6; color: #7a4a00; font-size: 10px; font-weight: 600; line-height: 1.4; text-overflow: ellipsis; white-space: nowrap; opacity: 0; transition: opacity .2s; }
.sgd[data-step="found"] .sgd-remind { outline-color: #d97706; }
.sgd[data-step="found"] .sgd-remind-tag { opacity: 1; transition: opacity .25s .35s; }

/* A lookalike sign-in page. */
.sgd-login { display: grid; justify-items: center; gap: 9px; max-width: 260px; margin: 0 auto; padding: 30px 0 0; color: var(--ink); text-align: center; }
.sgd-logo { display: grid; width: 34px; height: 34px; place-items: center; border-radius: 50%; background: #003087; color: #fff; font-size: 18px; font-weight: 800; font-style: italic; }
.sgd-login > b { margin-bottom: 4px; font-size: 16px; }
.sgd-input { box-sizing: border-box; width: 100%; padding: 9px 11px; border: 1px solid var(--line-strong); border-radius: 6px; color: var(--faint); font-size: 12.5px; text-align: left; }
.sgd-btn { box-sizing: border-box; width: 100%; padding: 9px; border-radius: 999px; background: #0070ba; color: #fff; font-size: 13px; font-weight: 700; }
.sgd-login small { color: #0070ba; font-size: 12px; font-weight: 600; }
:root[data-theme="dark"] .sgd-login small { color: #6fb7ea; }

/* A search engine's results page. */
.sgd-serp { padding: 14px 18px; }
.sgd-q { display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px; border-radius: 999px; background: var(--sgd-page); box-shadow: 0 0 0 1px var(--sgd-rule), 0 1px 5px rgba(0, 0, 0, .1); font-size: 13px; }
.sgd-q svg { width: 14px; height: 14px; flex: none; color: var(--sgd-sub); }
.sgd-q > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sgd-filters { display: flex; gap: 16px; margin: 10px 0 12px; padding: 0 4px 8px; border-bottom: 1px solid var(--sgd-rule); color: var(--sgd-sub); font-size: 11.5px; }
.sgd-filters b { color: var(--ink); font-weight: 600; box-shadow: 0 10px 0 -7px var(--ink); }
.sgd-res { display: block; margin: 0 -6px 12px; padding: 4px 6px; border-radius: 8px; }
.sgd-site { display: flex; align-items: center; gap: 8px; margin-bottom: 2px; min-width: 0; }
.sgd-site > i { display: grid; width: 22px; height: 22px; flex: none; place-items: center; border-radius: 50%; background: var(--sgd-soft); box-shadow: inset 0 0 0 1px var(--sgd-rule); color: var(--sgd-sub);
  font-size: 11px; font-style: normal; font-weight: 700; }
.sgd-site > span { min-width: 0; }
.sgd-site b, .sgd-site small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sgd-site b { color: var(--ink); font-size: 11.5px; font-weight: 500; }
.sgd-site small { color: var(--sgd-sub); font-size: 10.5px; }
.sgd-link { display: block; overflow: hidden; color: var(--sgd-link); font-size: 15px; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.sgd-snip { display: -webkit-box; overflow: hidden; color: var(--sgd-sub); font-size: 12px; line-height: 1.45; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }

/* A social feed's post with a picture: a giveaway flyer and its QR code. */
.sgd-feed { height: 100%; padding: 12px; background: var(--sgd-soft); box-sizing: border-box; }
.sgd-post { padding: 12px 12px 8px; border-radius: 8px; background: var(--sgd-page); box-shadow: 0 1px 2px rgba(0, 0, 0, .12); }
.sgd-who { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.sgd-who b { display: block; font-size: 12.5px; font-weight: 600; }
.sgd-who small { display: block; color: var(--sgd-sub); font-size: 10.5px; }
.sgd-more { margin-left: auto; color: var(--sgd-sub); font-weight: 700; letter-spacing: 1px; }
.sgd-av { display: grid; width: 32px; height: 32px; flex: none; place-items: center; border-radius: 50%; background: #e9b10c; color: #3a2a00; font-size: 11px; font-style: normal; font-weight: 800; }
.sgd-post p { margin: 0 0 10px; font-size: 12.5px; }
.sgd-pic { display: flex; align-items: center; gap: 10px; height: 126px; margin: 0 -12px; padding: 0 16px; background: #fff7dc; color: #1c1c1c; }
.sgd-poster { display: grid; justify-items: start; gap: 3px; min-width: 0; }
.sgd-ribbon { padding: 2px 7px; background: #d0021b; color: #fff; font-size: 10px; font-weight: 800; letter-spacing: .06em; }
.sgd-poster b { font-size: 22px; font-weight: 800; letter-spacing: -.02em; line-height: 1.05; }
.sgd-poster small { color: #d0021b; font-size: 11px; font-weight: 700; }
.sgd-device { position: relative; width: 38px; height: 74px; flex: none; margin-left: auto; border-radius: 9px; background: #2b2b2e; box-shadow: inset 0 0 0 2px #4a4a4f; }
.sgd-device::after { position: absolute; top: 6px; left: 50%; width: 12px; height: 3px; border-radius: 2px; background: #111; content: ""; transform: translateX(-50%); }
.sgd .sgd-qr { width: 82px; height: 82px; flex: none; padding: 5px; border-radius: 4px; background: #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, .1); fill: #111; stroke: none !important; }
.sgd .sgd-qr .w { fill: #fff; }
.sgd-badge { position: absolute; bottom: 8px; left: 10px; padding: 3px 8px; border-radius: 999px; background: var(--sgd-flag); color: #fff; font-size: 10.5px; font-weight: 600;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .3); opacity: 0; transform: translateY(6px); transition: opacity .15s, transform .15s; }
.sgd[data-step="found"] .sgd-badge { opacity: 1; transform: none; transition: opacity .25s .3s, transform .5s var(--spring) .3s; }
.sgd-reacts { display: flex; justify-content: space-between; gap: 10px; margin-top: 8px; color: var(--sgd-sub); font-size: 11px; white-space: nowrap; }

/* A chat app: the wallpaper, the contact, the bubbles with their times and ticks. */
.sgd-chat { display: flex; flex-direction: column; height: 100%; background: var(--sgd-chat); }
.sgd-chat-head { display: flex; align-items: center; gap: 9px; padding: 8px 14px; background: var(--sgd-page); box-shadow: 0 1px 0 var(--sgd-rule); }
.sgd-chat-head .sgd-av { width: 28px; height: 28px; background: #dfe5e7; color: #fff; }
.sgd-chat-head .sgd-av svg { width: 17px; height: 17px; }
:root[data-theme="dark"] .sgd-chat-head .sgd-av { background: #6a7175; }
.sgd-chat-head b { display: block; font-size: 12.5px; font-weight: 600; }
.sgd-chat-head small { display: block; color: var(--sgd-sub); font-size: 10.5px; }
.sgd-chat-list { display: flex; flex-direction: column; padding: 10px 16px; }
.sgd-day { align-self: center; margin-bottom: 12px; padding: 2px 9px; border-radius: 6px; background: var(--sgd-page); color: var(--sgd-sub); font-size: 10px; box-shadow: 0 1px .5px rgba(0, 0, 0, .1); }
.sgd-msg { position: relative; align-self: flex-start; max-width: 78%; margin-bottom: 18px; padding: 6px 9px 6px; border-radius: 0 8px 8px 8px; background: var(--sgd-in);
  box-shadow: 0 1px .5px rgba(0, 0, 0, .13); font-size: 12.5px; line-height: 1.4; }
.sgd-msg.out { align-self: flex-end; border-radius: 8px 0 8px 8px; background: var(--sgd-out); }
.sgd-msg small { float: right; margin: 6px 0 -4px 10px; color: var(--sgd-sub); font-size: 9.5px; }
.sgd-msg small i { color: #53bdeb; font-style: normal; letter-spacing: -3px; }
.sgd-msg u { color: #027eb5; text-decoration: none; }
:root[data-theme="dark"] .sgd-msg u { color: #53bdeb; }

/* A business's listing on a results page, and the chip SiteGuard puts beside its number
   (content.js renderSearchPhoneChip, searchPhonePalette): white, or a pale red when it is a scam. */
.sgd-kp { display: grid; gap: 5px; padding: 12px 14px; border: 1px solid var(--sgd-rule); border-radius: 10px; font-size: 12px; }
.sgd-kp-name { font-size: 17px; font-weight: 500; }
.sgd-kp-sub { color: var(--sgd-sub); font-size: 11.5px; }
.sgd-stars { color: #e7711b; }
.sgd-kp-acts { display: flex; gap: 6px; margin: 4px 0 6px; }
.sgd-kp-acts span { padding: 4px 10px; border: 1px solid var(--sgd-rule); border-radius: 999px; color: var(--sgd-link); font-size: 11px; font-weight: 500; }
.sgd-kp-row { color: var(--ink); line-height: 1.5; }
.sgd-kp-row b { font-weight: 600; }
.sgd-kp-phone { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.sgd-chip { position: relative; display: inline-flex; align-items: center; gap: 6px; height: 24px; margin-left: 6px; padding: 0 10px 0 6px; border-radius: 999px; background: #fff; color: #1d1d1f;
  font-size: 12px; font-weight: 600; line-height: 1; box-shadow: 0 0 0 .5px rgba(0, 0, 0, .14), 0 1px 3px rgba(0, 0, 0, .12); opacity: 0; transform: scale(.6); transition: opacity .15s, transform .15s; }
.sgd-chip.is-bad { background: #fff3f2; color: #d92d20; box-shadow: 0 0 0 .5px rgba(217, 45, 32, .35), 0 1px 3px rgba(217, 45, 32, .14); }
:root[data-theme="dark"] .sgd-chip { background: #2b2b30; color: #f2f2f4; box-shadow: 0 0 0 .5px rgba(255, 255, 255, .16), 0 1px 3px rgba(0, 0, 0, .55); }
:root[data-theme="dark"] .sgd-chip.is-bad { background: #3b2427; color: #ff7a7a; box-shadow: 0 0 0 .5px rgba(255, 122, 122, .4), 0 1px 3px rgba(0, 0, 0, .55); }
.sgd[data-step="found"] .sgd-chip { opacity: 1; transform: none; transition: opacity .2s .2s, transform .5s var(--spring-pop) .2s; }
.sgd[data-step="found"] .sgd-chip:is(.is-bad, .is-ok) { animation: sgd-press .3s ease-out 1.25s; }
.sgd-chip.is-ok .sgd-emblem i { right: -4px; bottom: -4px; width: 10px; height: 10px;
  background: #16a34a url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 12.5 3.5 3.5 6.5-7'/%3E%3C/svg%3E") center / 8px no-repeat; }
:root[data-theme="dark"] .sgd-chip.is-ok .sgd-emblem i { background-color: #4ade80; }
@keyframes sgd-press { 40% { transform: scale(.93); } }
.sgd-emblem { position: relative; display: block; width: 14px; height: 14px; }
.sgd-emblem img { display: block; width: 14px; height: 14px; }
.sgd-emblem i { position: absolute; right: -3px; bottom: -3px; width: 8px; height: 8px; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 2px #fff; }
.sgd-chip.is-bad .sgd-emblem i { background: #d92d20; box-shadow: 0 0 0 2px #fff3f2; }
:root[data-theme="dark"] .sgd-emblem i { background: #4ade80; box-shadow: 0 0 0 2px #2b2b30; }
:root[data-theme="dark"] .sgd-chip.is-bad .sgd-emblem i { background: #ff7a7a; box-shadow: 0 0 0 2px #3b2427; }
/* The pointer that comes to the chip and presses it. */
.sgd-cursor { position: absolute; top: 55%; left: 62%; z-index: 3; width: 16px; height: 22px; opacity: 0; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 22'%3E%3Cpath d='M1 1v17l4.4-4.2 2.9 6.6 2.8-1.2-2.8-6.5H14z' fill='%23111' stroke='%23fff' stroke-width='1.4' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat; }
.sgd[data-step="found"] .sgd-cursor { animation: sgd-point 1.6s cubic-bezier(.3, .7, .2, 1) .5s forwards; }
@keyframes sgd-point { 0% { opacity: 0; transform: translate(70px, 60px); } 15% { opacity: 1; } 50% { transform: none; } 58% { transform: scale(.85); } 66%, 100% { opacity: 1; transform: none; } }
/* A late answer (the Phone check, a paused download) comes once the pointer has pressed
   the chip, the menu or the file; the toolbar button has nothing to say about the page. */
.sgd[data-late][data-step="found"] .sgd-panel { transition-delay: 1.5s; }
.sgd[data-late] .sgd-count, .sgd[data-clean] .sgd-count { display: none; }

/* The Phone check (phone_check.html): the number, one answer, then what each source said. */
.sgd-pc-num { display: block; color: var(--ink); font: 700 17px/1.25 var(--mono, ui-monospace, SFMono-Regular, Menlo, monospace); letter-spacing: .02em; }
.sgd-pc-info { display: block; margin-top: 2px; color: var(--ink-soft); font-size: 11px; }
.sgd-answer { margin-top: 10px; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.sgd-answer-head { display: flex; align-items: flex-start; gap: 8px; padding: 9px; border-bottom: 1px solid var(--line); background: var(--red-soft); }
.sgd-answer-head > i { display: grid; width: 20px; height: 20px; flex: none; place-items: center; color: var(--red); }
.sgd-answer-head > i svg { width: 18px; height: 18px; }
.sgd-answer-head b { display: block; color: var(--red); font-size: 12.5px; font-weight: 650; line-height: 1.3; }
.sgd-answer-head small { display: block; margin-top: 2px; color: var(--ink-soft); font-size: 11px; line-height: 1.4; }
.sgd-src { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 9px; opacity: 0; }
.sgd-src + .sgd-src { border-top: 1px solid var(--line); }
.sgd-src b { min-width: 0; color: var(--ink); font-size: 11.5px; font-weight: 700; }
.sgd-src-crest { flex: none; width: 14px; height: 14px; margin-right: -2px; padding: 1px; box-sizing: border-box; border-radius: 4px; background: #fff; box-shadow: 0 0 0 1px var(--line); object-fit: contain; }
.sgd-src-crest + b { margin-right: auto; }
.sgd-answer.is-ok .sgd-answer-head { background: var(--green-soft); }
.sgd-answer.is-ok .sgd-answer-head > i, .sgd-answer.is-ok .sgd-answer-head b { color: var(--green); }
.sgd-answer.is-ok .sgd-pill { border-color: var(--green-line); background: var(--green-soft); color: var(--green); }
.sgd-pill { flex: none; padding: 1px 7px; border: 1px solid var(--red-line); border-radius: 999px; background: var(--red-soft); color: var(--red); font-size: 10.5px; font-weight: 700; white-space: nowrap; }
.sgd-pc-note { margin: 8px 0 0; color: var(--muted); font-size: 10.5px; line-height: 1.4; }
.sgd[data-step="found"] .sgd-src { opacity: 1; transition: opacity .3s 2.1s; }
.sgd[data-step="found"] .sgd-src + .sgd-src { transition-delay: 2.3s; }

/* A casino site, under its block page. */
.sgd-casino { height: 100%; background: #120d1f; color: #fff; }
.sgd-casino-top { display: flex; align-items: center; gap: 8px; padding: 10px 16px; background: #1d1530; font-size: 11px; }
.sgd-casino-top b { margin-right: auto; color: #f5c518; font-size: 14px; font-weight: 800; letter-spacing: .02em; }
.sgd-casino-top span { padding: 3px 10px; border: 1px solid #f5c518; border-radius: 4px; color: #f5c518; font-weight: 700; }
.sgd-casino-top .hot { background: #f5c518; color: #120d1f; }
.sgd-casino-hero { margin: 14px 16px; padding: 18px; border-radius: 8px; background: #2a1d47; }
.sgd-casino-hero small { display: block; color: #c9b8ff; font-size: 11px; font-weight: 700; letter-spacing: .08em; }
.sgd-casino-hero b { color: #f5c518; font-size: 36px; font-weight: 800; line-height: 1.1; }
.sgd-casino-games { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 0 16px; }
.sgd-casino-games span { padding: 22px 0; border-radius: 6px; background: #241a3a; color: #e9e2ff; font-size: 9.5px; font-weight: 700; text-align: center; }

/* An adult site, under its block page: only its shapes, blurred. */
.sgd-adult { height: 100%; background: #111; }
.sgd-adult-top { display: block; padding: 10px 16px; color: #ff4f8b; font-size: 14px; font-weight: 800; }
.sgd-thumbs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 0 16px; filter: blur(7px); }
.sgd-thumbs i { height: 92px; border-radius: 6px; background: #8a5a4a; }
.sgd-thumbs i:nth-child(2n) { background: #6b4a52; } .sgd-thumbs i:nth-child(3n) { background: #a07060; }

/* A fake government aid page. */
.sgd-aid { height: 100%; background: #f4f6f9; color: #1d2433; }
.sgd-aid-top { display: flex; align-items: center; gap: 10px; padding: 10px 16px; background: #0b2a5b; color: #fff; }
.sgd-aid-top b { display: block; font-size: 13px; } .sgd-aid-top small { display: block; color: #c8d3e8; font-size: 10.5px; }
.sgd-crest { width: 26px; height: 26px; flex: none; border-radius: 50%; background: #f2c200; box-shadow: inset 0 0 0 3px #0b2a5b, 0 0 0 1px #f2c200; }
.sgd-aid-body { display: grid; gap: 7px; max-width: 280px; margin: 0 auto; padding: 16px 0; }
.sgd-aid-body > b { margin-bottom: 3px; font-size: 13px; text-align: center; }
.sgd-aid .sgd-input { background: #fff; border-color: #cfd6e2; color: #8a93a5; }
.sgd-aid .sgd-btn { border-radius: 6px; background: #0b2a5b; }

/* A free film site, its player asking for an "update". */
.sgd-movie { height: 100%; background: #0f0f12; color: #e8e8ea; }
.sgd-movie-top { display: flex; align-items: center; gap: 14px; padding: 10px 16px; font-size: 11px; color: #a0a0a8; }
.sgd-movie-top b { margin-right: auto; color: #ffb000; font-size: 14px; }
.sgd-player { position: relative; display: grid; height: 210px; margin: 4px 16px; place-items: center; border-radius: 6px; background: #000; }
.sgd-play { position: absolute; width: 0; height: 0; border-top: 16px solid transparent; border-bottom: 16px solid transparent; border-left: 26px solid rgba(255, 255, 255, .25); }
.sgd-update { position: relative; display: grid; gap: 4px; width: 210px; padding: 12px 14px; border-radius: 6px; background: #fff; color: #1d1d1f; text-align: center; }
.sgd-update b { font-size: 12.5px; } .sgd-update small { color: #5f6368; font-size: 11px; }
.sgd-update > span { margin-top: 4px; padding: 6px; border-radius: 4px; background: #1a73e8; color: #fff; font-size: 12px; font-weight: 600; }

/* Telegram and Google Messages: their own wallpaper and bubbles. */
/* WhatsApp Web: its doodle wallpaper, its header and message bar, bubbles with a tail on the
   first of a run, in its own light and dark colours. */
.sgd-wa { --sgd-chat: #efeae2; --sgd-in: #fff; --sgd-out: #d9fdd3; --sgd-wa-bar: #f0f2f5; --sgd-wa-field: #fff; --sgd-wa-icon: #54656f; --sgd-wa-time: #667781;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='88' height='88' fill='none' stroke='%23000' stroke-opacity='.06' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 12h18a4 4 0 0 1 4 4v9a4 4 0 0 1-4 4H17l-6 5v-5h-1a4 4 0 0 1-4-4v-9a4 4 0 0 1 4-4z'/%3E%3Cpath d='M62 8v16a4 4 0 1 1-3-3.9V11l10-3'/%3E%3Cpath d='M70 58c3-4 10-2 9 4-1 5-9 9-9 9s-8-4-9-9c-1-6 6-8 9-4z'/%3E%3Crect x='12' y='56' width='18' height='14' rx='3'/%3E%3Ccircle cx='21' cy='63' r='3.5'/%3E%3Ccircle cx='46' cy='44' r='5'/%3E%3C/svg%3E") 0 0 / 88px 88px, var(--sgd-chat); }
:root[data-theme="dark"] .sgd-wa { --sgd-chat: #0b141a; --sgd-in: #202c33; --sgd-out: #005c4b; --sgd-wa-bar: #202c33; --sgd-wa-field: #2a3942; --sgd-wa-icon: #aebac1; --sgd-wa-time: rgba(233, 237, 239, .6);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='88' height='88' fill='none' stroke='%23fff' stroke-opacity='.035' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 12h18a4 4 0 0 1 4 4v9a4 4 0 0 1-4 4H17l-6 5v-5h-1a4 4 0 0 1-4-4v-9a4 4 0 0 1 4-4z'/%3E%3Cpath d='M62 8v16a4 4 0 1 1-3-3.9V11l10-3'/%3E%3Cpath d='M70 58c3-4 10-2 9 4-1 5-9 9-9 9s-8-4-9-9c-1-6 6-8 9-4z'/%3E%3Crect x='12' y='56' width='18' height='14' rx='3'/%3E%3Ccircle cx='21' cy='63' r='3.5'/%3E%3Ccircle cx='46' cy='44' r='5'/%3E%3C/svg%3E") 0 0 / 88px 88px, var(--sgd-chat); color: #e9edef; }
.sgd-wa .sgd-chat-head { gap: 10px; padding: 7px 14px; background: var(--sgd-wa-bar); box-shadow: none; }
.sgd-wa .sgd-chat-head .sgd-av { width: 32px; height: 32px; overflow: hidden; align-items: end; background: #dfe5e7; color: #fff; }
:root[data-theme="dark"] .sgd-wa .sgd-chat-head .sgd-av { background: #6a7175; color: #cfd4d6; }
.sgd-wa .sgd-chat-head .sgd-av svg { width: 26px; height: 26px; margin-bottom: -4px; stroke-width: 0; fill: currentColor; }
.sgd-wa .sgd-chat-head b { font-size: 13px; font-weight: 500; }
.sgd-wa .sgd-chat-head small { color: var(--sgd-wa-time); font-size: 11px; }
.sgd-chat-icons { display: flex; gap: 16px; margin-left: auto; color: var(--sgd-wa-icon); }
.sgd-chat-icons svg { width: 17px; height: 17px; stroke-width: 1.9; }
.sgd-wa .sgd-chat-list { flex: 1; min-height: 0; justify-content: flex-end; padding: 8px 16px 6px; }
.sgd-wa .sgd-day { margin-bottom: 10px; padding: 3px 10px; border-radius: 7px; background: var(--sgd-in); color: var(--sgd-wa-time); font-size: 10px; letter-spacing: .02em; }
:root[data-theme="dark"] .sgd-wa .sgd-day { background: #182229; color: #8696a0; }
.sgd-wa .sgd-msg { flex: none; max-width: 76%; margin-bottom: 14px; padding: 6px 8px 7px 9px; border-radius: 8px; box-shadow: 0 1px .5px rgba(11, 20, 26, .13); font-size: 12.5px; }
.sgd-wa .sgd-msg small { color: var(--sgd-wa-time); }
.sgd-wa .sgd-tail.in { border-top-left-radius: 0; }
.sgd-wa .sgd-tail.out { border-top-right-radius: 0; }
.sgd-wa .sgd-tail::before { position: absolute; top: 0; left: -8px; width: 8px; height: 13px; background: var(--sgd-in); content: ""; clip-path: path("M0 0 H8 V13 C6 8 3 4 0 0 Z"); }
.sgd-wa .sgd-tail.out::before { right: -8px; left: auto; background: var(--sgd-out); clip-path: path("M8 0 H0 V13 C2 8 5 4 8 0 Z"); }
.sgd-wa .sgd-file { background: rgba(11, 20, 26, .05); } :root[data-theme="dark"] .sgd-wa .sgd-file { background: rgba(0, 0, 0, .18); }
.sgd-wa-compose { display: flex; align-items: center; gap: 12px; padding: 7px 14px; background: var(--sgd-wa-bar); color: var(--sgd-wa-icon); }
.sgd-wa-compose > i, .sgd-wa-input > i { display: grid; place-items: center; }
.sgd-wa-compose svg { width: 18px; height: 18px; stroke-width: 1.9; }
.sgd-wa-input { display: flex; flex: 1; align-items: center; gap: 9px; height: 32px; padding: 0 11px; border-radius: 8px; background: var(--sgd-wa-field); color: var(--sgd-wa-time); font-size: 12.5px; }
/* The right-click menu opens upwards when the message is at the bottom of the chat. */
.sgd-wa .sgd-menu { top: auto; bottom: 48px; left: 60px; width: 180px; }
.sgd-wa .sgd-submenu { top: auto; bottom: -4px; }

.sgd-sender { display: block; color: #1f7aa8; font-size: 11px; font-weight: 700; }
.sgd-sender.is-2 { color: #c2477a; }
:root[data-theme="dark"] .sgd-sender { color: #53bdeb; } :root[data-theme="dark"] .sgd-sender.is-2 { color: #f08aa8; }
.sgd-fwd { display: block; margin-bottom: 2px; color: var(--sgd-wa-time, var(--sgd-sub)); font-size: 10.5px; font-style: italic; }
.sgd-tg .sgd-chat-head .sgd-av { font-style: normal; }

/* Telegram Web: its gradient wallpaper under a doodle pattern, bubbles with tails, its
   own bubble colours (green on light, the night theme's purple), the message bar. */
.sgd-tg { --sgd-in: #fff; --sgd-out: #e3fee0; --sgd-tg-time: #a1aab3; --sgd-tg-out-time: #4fae4e; --sgd-tg-bar: #fff; --sgd-tg-accent: #3390ec;
  --sgd-tg-doodle: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96' fill='none' stroke='%23000' stroke-opacity='.07' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 18l4 8 9 1-7 6 2 9-8-5-8 5 2-9-7-6 9-1z'/%3E%3Cpath d='M70 14c3-4 10-2 9 4-1 5-9 9-9 9s-8-4-9-9c-1-6 6-8 9-4z'/%3E%3Ccircle cx='76' cy='70' r='8'/%3E%3Cpath d='M18 70l20-8-6 20-4-8z'/%3E%3Cpath d='M46 42h10M51 37v10'/%3E%3C/svg%3E");
  background: var(--sgd-tg-doodle) 0 0 / 96px 96px, radial-gradient(circle at 15% 20%, #dbddbb 0, transparent 55%), radial-gradient(circle at 85% 25%, #6ba587 0, transparent 60%),
    radial-gradient(circle at 25% 85%, #d5d88d 0, transparent 55%), radial-gradient(circle at 80% 90%, #88b884 0, transparent 60%), #a7c799; }
:root[data-theme="dark"] .sgd-tg { --sgd-in: #212121; --sgd-out: #766ac8; --sgd-tg-time: #8f9396; --sgd-tg-out-time: rgba(255, 255, 255, .7); --sgd-tg-bar: #212121; --sgd-tg-accent: #8774e1;
  --sgd-tg-doodle: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96' fill='none' stroke='%23fff' stroke-opacity='.05' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 18l4 8 9 1-7 6 2 9-8-5-8 5 2-9-7-6 9-1z'/%3E%3Cpath d='M70 14c3-4 10-2 9 4-1 5-9 9-9 9s-8-4-9-9c-1-6 6-8 9-4z'/%3E%3Ccircle cx='76' cy='70' r='8'/%3E%3Cpath d='M18 70l20-8-6 20-4-8z'/%3E%3Cpath d='M46 42h10M51 37v10'/%3E%3C/svg%3E");
  background: var(--sgd-tg-doodle) 0 0 / 96px 96px, radial-gradient(circle at 15% 20%, #1f2a3a 0, transparent 55%), radial-gradient(circle at 85% 30%, #2a2340 0, transparent 60%),
    radial-gradient(circle at 30% 90%, #16302a 0, transparent 55%), #0f0f12; }
.sgd-tg .sgd-chat-head { gap: 10px; padding: 7px 12px; background: var(--sgd-tg-bar); box-shadow: 0 1px 2px rgba(0, 0, 0, .12); }
.sgd-tg .sgd-chat-head .sgd-av, :root[data-theme="dark"] .sgd-tg .sgd-chat-head .sgd-av { width: 32px; height: 32px; background: linear-gradient(#ff885e, #ff516a); color: #fff; font-size: 14px; font-weight: 600; }
.sgd-tg .sgd-chat-head b { font-size: 13px; font-weight: 600; }
.sgd-tg .sgd-chat-head small { color: var(--sgd-tg-time); font-size: 11px; }
.sgd-tg-icons { display: flex; gap: 14px; margin-left: auto; color: var(--sgd-tg-time); }
.sgd-tg-icons svg { width: 17px; height: 17px; stroke-width: 1.9; }
.sgd-tg .sgd-chat-list { flex: 1; min-height: 0; justify-content: flex-end; padding: 8px 14px 4px; }
.sgd-tg .sgd-day { margin-bottom: 10px; padding: 2px 9px; border-radius: 999px; background: rgba(0, 0, 0, .22); box-shadow: none; color: #fff; font-size: 10.5px; font-weight: 600; }
.sgd-tg .sgd-msg { flex: none; max-width: 74%; margin-bottom: 14px; padding: 6px 9px 6px 10px; border-radius: 12px; box-shadow: 0 1px 2px rgba(16, 35, 47, .15); font-size: 12.5px; }
.sgd-tg .sgd-msg.out { margin-left: auto; }
:root[data-theme="dark"] .sgd-tg .sgd-msg { color: #fff; }
.sgd-tg .sgd-msg small { color: var(--sgd-tg-time); }
.sgd-tg .sgd-msg.out small, .sgd-tg .sgd-msg.out small i { color: var(--sgd-tg-out-time); }
/* The tail on the last bubble of a run: bottom left on theirs, bottom right on yours. */
.sgd-tg .sgd-tail.in { border-bottom-left-radius: 0; }
.sgd-tg .sgd-tail.out { border-bottom-right-radius: 0; }
.sgd-tg .sgd-tail::before { position: absolute; bottom: 0; left: -7px; width: 8px; height: 13px; background: var(--sgd-in); content: ""; clip-path: path("M8 0 V13 H0 C4 12 8 8 8 0 Z"); }
.sgd-tg .sgd-tail.out::before { right: -7px; left: auto; background: var(--sgd-out); clip-path: path("M0 0 V13 H8 C4 12 0 8 0 0 Z"); }
.sgd-tg-compose { display: flex; align-items: center; gap: 8px; padding: 6px 12px 10px; }
.sgd-tg-input { display: flex; flex: 1; align-items: center; gap: 8px; height: 34px; padding: 0 10px; border-radius: 12px; background: var(--sgd-tg-bar); box-shadow: 0 1px 2px rgba(16, 35, 47, .15);
  color: var(--sgd-tg-time); font-size: 12.5px; }
.sgd-tg-input > span { flex: 1; }
.sgd-tg-input i { display: grid; place-items: center; }
.sgd-tg-input svg { width: 17px; height: 17px; }
.sgd-tg-mic { display: grid; width: 34px; height: 34px; flex: none; place-items: center; border-radius: 50%; background: var(--sgd-tg-accent); color: #fff; box-shadow: 0 1px 2px rgba(16, 35, 47, .2); }
.sgd-tg-mic svg { width: 17px; height: 17px; }
.sgd-gm { --sgd-chat: var(--sgd-page); --sgd-in: #e9eef6; }
:root[data-theme="dark"] .sgd-gm { --sgd-in: #303134; }
.sgd-gm .sgd-msg { border-radius: 18px; box-shadow: none; padding: 9px 13px; }
.sgd-gm .sgd-day { background: none; box-shadow: none; }
.sgd-gm .sgd-msg u { color: #0b57d0; text-decoration: underline; } :root[data-theme="dark"] .sgd-gm .sgd-msg u { color: #a8c7fa; }
.sgd-av.is-blue { background: #1877f2; color: #fff; }

/* A job scam's poster. */
.sgd-job { justify-content: flex-start; height: 96px; background: #ffd400; }
.sgd-job .sgd-poster small { color: #1c1c1c; }

/* A selection in a chat, and the browser's right-click menu with SiteGuard's item. */
.sgd-sel { background: #b4d5fe; color: inherit; } :root[data-theme="dark"] .sgd-sel { background: #2f5aa8; }
.sgd-has-menu { z-index: 4; }
.sgd-menu { position: absolute; top: 34px; left: 70px; z-index: 5; display: grid; width: 196px; padding: 4px 0; border-radius: 8px; background: #fff; color: #202124; font-size: 11.5px;
  box-shadow: 0 0 0 .5px rgba(0, 0, 0, .14), 0 8px 24px rgba(0, 0, 0, .2); opacity: 0; visibility: hidden; }
:root[data-theme="dark"] .sgd-menu { background: #292a2d; color: #e8eaed; box-shadow: 0 0 0 .5px rgba(255, 255, 255, .12), 0 8px 24px rgba(0, 0, 0, .6); }
.sgd-menu > span { padding: 5px 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sgd-menu > i { height: 1px; margin: 4px 0; background: rgba(128, 128, 128, .25); }
.sgd-menu-sg { position: relative; display: flex; align-items: center; gap: 7px; background: rgba(128, 128, 128, .14); overflow: visible !important; }
.sgd-menu-sg img { width: 14px; height: 14px; } .sgd-menu-sg b { margin-left: auto; font-weight: 400; }
.sgd-submenu { position: absolute; top: -4px; left: 100%; display: grid; width: 206px; padding: 4px 0; border-radius: 8px; background: inherit; box-shadow: inherit; }
.sgd-menu .sgd-submenu { background: #fff; } :root[data-theme="dark"] .sgd-menu .sgd-submenu { background: #292a2d; }
.sgd-submenu > span { position: relative; padding: 5px 12px; white-space: nowrap; }
.sgd-submenu .is-hl { transition: background-color .1s; }
.sgd[data-step="found"] .sgd-menu { animation: sgd-menu 1.5s linear .25s forwards; }
.sgd[data-step="found"] .sgd-submenu .is-hl { animation: sgd-hl 1.5s linear .25s forwards; }
@keyframes sgd-menu { 0% { opacity: 0; visibility: visible; } 6%, 86% { opacity: 1; visibility: visible; } 100% { opacity: 0; visibility: hidden; } }
@keyframes sgd-hl { 0%, 45% { background: none; } 50%, 100% { background: rgba(128, 128, 128, .2); } }
.sgd-submenu .sgd-cursor { top: 40%; left: 70%; }

/* A file sent in a chat, and the system notice for the download SiteGuard paused. */
.sgd-file-msg { width: 230px; }
.sgd-file { display: flex; align-items: center; gap: 9px; padding: 6px; border-radius: 6px; background: rgba(128, 128, 128, .12); }
.sgd-ext-tag { display: grid; width: 30px; height: 36px; flex: none; place-items: center; border-radius: 4px; background: #3ddc84; color: #073b1f; font-size: 9px; font-style: normal; font-weight: 800; }
.sgd-file > span { flex: 1; min-width: 0; }
.sgd-file b { display: block; overflow: hidden; font-size: 12px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.sgd-file small { display: block; float: none; margin: 0; color: var(--sgd-sub); font-size: 10.5px; }
.sgd-dl { position: relative; display: grid; width: 26px; height: 26px; flex: none; place-items: center; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--sgd-sub); color: var(--sgd-sub); }
.sgd-dl svg { width: 14px; height: 14px; }
.sgd-dl .sgd-cursor { top: 45%; left: 45%; }
.sgd-note { position: absolute; top: 54px; right: 12px; z-index: 6; display: block; width: 240px; padding: 12px; border-radius: 10px; background: var(--surface); color: var(--ink);
  box-shadow: 0 0 0 .5px rgba(0, 0, 0, .12), 0 12px 32px rgba(0, 0, 0, .28); opacity: 0; transform: translateX(24px); }
:root[data-theme="dark"] .sgd-note { background: #2b2b2e; box-shadow: 0 0 0 .5px rgba(255, 255, 255, .12), 0 12px 32px rgba(0, 0, 0, .7); }
.sgd-note-app { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; color: var(--muted); font-size: 10.5px; }
.sgd-note-app img { width: 14px; height: 14px; } .sgd-note-app i { margin-left: auto; font-style: normal; }
.sgd-note b { display: block; font-size: 12.5px; font-weight: 650; }
.sgd-note small { display: block; margin-top: 2px; color: var(--ink-soft); font-size: 11px; line-height: 1.4; }
.sgd-note .sgd-note-file { color: var(--ink); font-weight: 600; }
.sgd-note-acts { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 8px; }
.sgd-note-acts span { padding: 5px 0; white-space: nowrap; border-radius: 6px; background: var(--surface-soft); box-shadow: inset 0 0 0 1px var(--line); font-size: 11px; font-weight: 600; text-align: center; }
.sgd-note-acts span:first-child { background: var(--accent); box-shadow: none; color: #fff; }
.sgd[data-step="found"] .sgd-note { opacity: 1; transform: none; transition: opacity .3s 1.6s, transform .6s var(--spring) 1.6s; }

/* Payment codes as people meet them. Logos are the banks' and e-wallets' own (badges from
   icons/brands; .sgd-logo-cut shows just the logo out of one). Under each code, SiteGuard's
   note (content.js placePayQrBadge: a white card, a dot in the answer's colour, Details). */
.sgd-logo-cut { position: relative; display: block; flex: none; overflow: hidden; }
.sgd-logo-cut img { position: absolute; max-width: none; }
.sgd-badges { display: flex; flex-wrap: wrap; gap: 4px; }
.sgd-badge-img { display: block; width: 36px; height: 23px; }
.sgd .sgd-qr.is-pink { fill: #d4145a; } .sgd .sgd-qr.is-navy { fill: #0b2d6b; }
.sgd-pay-qr { display: grid; flex: none; justify-items: center; align-content: start; gap: 7px; width: 224px; }
.sgd-pay-qr.is-row { display: flex; align-items: flex-start; width: auto; }
.sgd-pay-qr.is-row .sgd-payqr { flex: 1; min-width: 0; margin-top: 4px; }
.sgd-pay-h { justify-self: start; font-size: 12.5px; }
.sgd-payqr { --pq: #1a7152; --pq-soft: #e7f4ec; position: relative; display: block; box-sizing: border-box; width: 100%; padding: 9px 11px 9px;
  border-radius: 12px; background: #fff; color: #1d1d1f; font-size: 10.5px; line-height: 1.4; box-shadow: 0 0 0 1px rgba(0, 0, 0, .08), 0 6px 18px -6px rgba(0, 0, 0, .22);
  opacity: 0; transform: translateY(6px); }
.sgd-payqr.is-bad { --pq: #b0353a; --pq-soft: #fbe9e9; }
:root[data-theme="dark"] .sgd-payqr { --pq: #5cd096; --pq-soft: rgba(92, 208, 150, .14); background: #26262b; color: #ececf1; box-shadow: 0 0 0 1px rgba(255, 255, 255, .1), 0 8px 20px -6px rgba(0, 0, 0, .7); }
:root[data-theme="dark"] .sgd-payqr.is-bad { --pq: #f28b8e; --pq-soft: rgba(242, 139, 142, .14); }
/* A small point towards the code it is about: up under a column, left beside a row. */
.sgd-payqr::after { position: absolute; top: -5px; left: 50%; width: 10px; height: 10px; background: inherit; box-shadow: -1px -1px 0 rgba(0, 0, 0, .06); content: ""; transform: translateX(-50%) rotate(45deg); }
.sgd-pay-qr.is-row .sgd-payqr::after { top: 18px; left: -5px; transform: rotate(45deg); box-shadow: -1px 1px 0 rgba(0, 0, 0, .06); }
.sgd-pq-head { display: flex; align-items: center; gap: 5px; margin-bottom: 4px; }
.sgd-pq-head img { width: 14px; height: 14px; }
.sgd-pq-head b { font-size: 10.5px; font-weight: 700; }
.sgd-pq-head i { margin-left: 2px; padding: 1px 7px; border-radius: 999px; background: var(--pq-soft); color: var(--pq); font-size: 9.5px; font-style: normal; font-weight: 700; }
.sgd-pq-k { display: block; color: var(--muted); font-size: 9.5px; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.sgd-pq-v { display: block; font-size: 12.5px; font-weight: 800; letter-spacing: -.005em; overflow-wrap: anywhere; }
.sgd-payqr.is-bad .sgd-pq-v { color: var(--pq); }
.sgd-pq-t { display: inline; color: var(--ink-soft); font-size: 10.5px; }
.sgd-pq-v + .sgd-pq-t::before { display: block; height: 3px; content: ""; }
:root[data-theme="dark"] .sgd-pq-t { color: #c9c9d1; }
.sgd-pq-more { margin-left: 4px; color: var(--accent-ink); font-size: 10.5px; font-weight: 700; white-space: nowrap; }
.sgd[data-step="found"] .sgd-payqr { opacity: 1; transform: none; transition: opacity .3s .2s, transform .5s var(--spring) .2s; }

/* A wide page (the home page's demo): the note beside the code it is about, pointing at it,
   not under it, so a poster and its note never run past the page's foot. */
@container sgd-page (min-width: 560px) {
  .sgd-pay-qr:not(.is-row) { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: flex-start; gap: 10px; width: auto; max-width: 400px; }
  .sgd-pay-qr:not(.is-row) > .sgd-pay-h { flex-basis: 100%; }
  .sgd-pay-qr:not(.is-row) > .sgd-dnc { width: 150px; }
  .sgd-pay-qr:not(.is-row) .sgd-payqr { flex: 1; min-width: 190px; margin-top: 10px; }
  .sgd-pay-qr:not(.is-row) .sgd-payqr::after { top: 18px; left: -5px; transform: rotate(45deg); box-shadow: -1px 1px 0 rgba(0, 0, 0, .06); }
  .sgd-pay.is-promo .sgd-pay-qr { width: auto; }
}

/* The national poster: pink frame, the white card with the logo, the code and the payee, the band, the partner. */
.sgd-dnp { display: grid; width: 124px; padding: 4px; border-radius: 10px; background: #e2336b; color: #111; text-align: center; box-shadow: 0 4px 12px rgba(0, 0, 0, .15); }
.sgd-dnp-card { display: grid; justify-items: center; gap: 3px; padding: 5px 5px 6px; border-radius: 7px; background: #fff; }
.sgd .sgd-dnp .sgd-qr { width: 68px; height: 68px; padding: 0; box-shadow: none; border-radius: 0; }
.sgd-dnp-card b { font-size: 7.5px; font-weight: 800; letter-spacing: .01em; white-space: nowrap; }
.sgd-dnp-band { padding: 3px 0 2px; color: #fff; font-size: 7.5px; white-space: nowrap; font-weight: 800; letter-spacing: .02em; }
.sgd-dnp-foot { display: grid; justify-items: center; gap: 1px; padding: 3px 4px 4px; border-radius: 7px; background: #fff; }
.sgd-dnp-foot small { font-size: 5.5px; font-weight: 600; white-space: nowrap; } .sgd-dnp-foot i { font-size: 5.5px; }

/* A checkout: the order on the left, "Pay with DuitNow QR" on the right. */
.sgd-shop2 { height: 100%; background: var(--sgd-soft); color: var(--ink); }
.sgd-shop2-top { display: flex; align-items: center; gap: 14px; height: 38px; padding: 0 16px; background: var(--sgd-page); box-shadow: inset 0 -1px 0 var(--sgd-rule); color: var(--sgd-sub); font-size: 11px; }
.sgd-shop2-top b { margin-right: auto; color: #c0392b; font-size: 14px; font-weight: 800; }
:root[data-theme="dark"] .sgd-shop2-top b { color: #ff7a6b; }
.sgd-shop2-top .on { color: var(--ink); font-weight: 700; box-shadow: 0 9px 0 -7px var(--ink); }
.sgd-shop2-body { display: flex; gap: 12px; padding: 10px 14px; }
.sgd-order { display: grid; flex: 1; align-content: start; gap: 6px; min-width: 0; padding: 12px; border-radius: 10px; background: var(--sgd-page); font-size: 11.5px; }
.sgd-order small { color: var(--sgd-sub); font-size: 10px; font-weight: 700; letter-spacing: .05em; }
.sgd-order > span:not(.sgd-badges) { display: flex; justify-content: space-between; gap: 8px; }
.sgd-order i { min-width: 0; overflow: hidden; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.sgd-order-total { margin-top: 2px; padding-top: 7px; border-top: 1px solid var(--sgd-rule); font-size: 13px; font-weight: 700; }
.sgd-order small.sgd-accept { margin-top: 6px; letter-spacing: 0; font-weight: 600; }
.sgd-dnc { display: grid; justify-items: center; gap: 3px; width: 100%; padding: 8px; border-radius: 10px; background: #fff; color: #111; box-sizing: border-box; box-shadow: 0 0 0 1px #ececf0; }
.sgd .sgd-dnc .sgd-qr { width: 84px; height: 84px; padding: 0; box-shadow: none; border-radius: 0; }
.sgd-dnc b { font-size: 10px; font-weight: 800; } .sgd-dnc small { color: #c0392b; font-size: 10px; font-weight: 700; }

/* The donation page. */
.sgd-pay { height: 100%; background: var(--sgd-page); color: var(--ink); }
.sgd-pay-top { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 16px; background: #0f5132; color: #fff; }
.sgd-pay-top > b { font-size: 13.5px; }
.sgd-crescent { width: 16px; height: 16px; border-radius: 50%; box-shadow: inset -4px 2px 0 #f2c200; transform: rotate(-20deg); }
.sgd-pay-nav { display: flex; gap: 12px; margin-left: auto; color: rgba(255, 255, 255, .75); font-size: 11px; }
.sgd-pay-nav b { color: #fff; box-shadow: 0 8px 0 -6px #f2c200; }
.sgd-pay-body { display: flex; gap: 14px; padding: 8px 16px; }
.sgd-pay-side { display: grid; flex: 1; align-content: start; gap: 6px; min-width: 0; padding-top: 4px; }
.sgd-pay-side small { color: var(--sgd-sub); font-size: 10px; font-weight: 700; letter-spacing: .06em; }
.sgd-pay-side > b { font-size: 18px; font-weight: 700; }
.sgd-pay-side > span:not(.sgd-countdown) { color: var(--ink-soft); font-size: 11.5px; line-height: 1.5; }
.sgd-pay-acct { margin-top: 4px; padding: 8px 10px; border-radius: 8px; background: var(--sgd-soft); }
.sgd-pay-acct b { color: var(--ink); }
.sgd-pay.is-promo .sgd-pay-top { background: #fff; box-shadow: inset 0 -1px 0 var(--sgd-rule); color: #1d1d1f; }
:root[data-theme="dark"] .sgd-pay.is-promo .sgd-pay-top { background: #1f1f22; color: #e8e8ea; }
.sgd-pay.is-promo .sgd-pay-nav { color: var(--sgd-sub); }
.sgd-pay.is-promo .sgd-pay-qr { width: 256px; }
.sgd-promo-logo { color: #e2336b; font-size: 15px !important; font-style: italic; font-weight: 800 !important; }
.sgd-promo-logo i { padding: 0 5px; border-radius: 4px; background: #e2336b; color: #fff; font-size: 11px; font-style: normal; vertical-align: 2px; }
.sgd-pay-side > b.sgd-promo-amt { color: #e2336b; font-size: 34px; font-weight: 800; line-height: 1; }
.sgd-countdown { justify-self: start; padding: 3px 9px; border-radius: 4px; background: #fff3cd; color: #8a5300; font-size: 11px; font-weight: 700; }
:root[data-theme="dark"] .sgd-countdown { background: #3a2c06; color: #f5c451; }

/* A Marketplace listing, and the seller's Touch 'n Go code: the blue top, the code, the name. */
.sgd-mp-item { display: flex; gap: 10px; margin-bottom: 8px; }
.sgd-mp-item .sgd-img { display: grid; width: 56px; height: 56px; flex: none; place-items: center; border-radius: 6px; background: var(--sgd-soft); }
.sgd-mp-item .sgd-img .sgd-device { width: 20px; height: 40px; margin: 0; }
.sgd-mp-item b { display: block; font-size: 12.5px; } .sgd-mp-item small { display: block; color: var(--sgd-sub); font-size: 10.5px; }
.sgd-mp-price { display: block; font-size: 13px; font-weight: 700; }
.sgd-tng { display: grid; flex: none; justify-items: center; gap: 4px; width: 118px; padding: 0 0 8px; overflow: hidden; border-radius: 10px; background: #fff; color: #0b2d6b; box-shadow: 0 0 0 1px #e1e6ef, 0 3px 10px rgba(0, 0, 0, .12); }
.sgd-tng-top { display: grid; justify-self: stretch; place-items: center; height: 26px; background: #0d4fc4; }
.sgd-tng > span { font-size: 8.5px; font-weight: 700; }
.sgd .sgd-tng .sgd-qr { width: 88px; height: 88px; padding: 0; box-shadow: none; border-radius: 0; }
.sgd-tng b { padding: 0 6px; font-size: 8px; font-weight: 800; text-align: center; }

/* A banking app's one-time code, screenshotted: the app bar, the code, the amount, the expiry. */
.sgd-shot { display: grid; flex: none; justify-items: center; gap: 3px; width: 118px; padding: 0 0 8px; overflow: hidden; border-radius: 12px; background: #fff; color: #111; box-shadow: 0 0 0 4px #1d1d1f, 0 4px 12px rgba(0, 0, 0, .25); }
.sgd-shot-bar { justify-self: stretch; margin-bottom: 4px; padding: 6px 8px; background: #f4f4f6; font-size: 9px; font-weight: 700; }
.sgd .sgd-shot .sgd-qr { width: 82px; height: 82px; padding: 0; box-shadow: none; border-radius: 0; }
.sgd-shot b { font-size: 8px; font-weight: 800; } .sgd-shot-amt { font-size: 12px; font-weight: 800; } .sgd-shot small { color: #666; font-size: 7px; }
.sgd-av.is-green { background: #2e7d32; color: #fff; }

/* Webmail, as Gmail and Outlook draw it: the app's bar, its rail of icons, the open email on
   its card. Each in its own light and dark colours. */
.sgd-mail { --sgd-m-bg: #f6f8fc; --sgd-m-card: #fff; --sgd-m-ink: #1f1f1f; --sgd-m-sub: #5e5e5e; --sgd-m-icon: #444746; --sgd-m-field: #e9eef6; --sgd-m-line: #e0e0e0;
  display: flex; flex-direction: column; height: 100%; background: var(--sgd-m-bg); color: var(--sgd-m-ink); }
:root[data-theme="dark"] .sgd-mail { --sgd-m-bg: #1b1b1b; --sgd-m-card: #2a2a2a; --sgd-m-ink: #e3e3e3; --sgd-m-sub: #a8a8a8; --sgd-m-icon: #c4c7c5; --sgd-m-field: #303134; --sgd-m-line: #444; }
.sgd-mail svg { stroke-width: 1.8; }
.sgd-mail-top { display: flex; flex: none; align-items: center; gap: 12px; height: 44px; padding: 0 12px; color: var(--sgd-m-icon); }
.sgd-mi, .sgd-mail-icons i, .sgd-rail i, .sgd-mail-tools i { display: grid; flex: none; place-items: center; }
.sgd-mi svg, .sgd-mail-icons svg { width: 17px; height: 17px; }
.sgd-gm-logo { display: flex; flex: none; align-items: center; gap: 5px; }
.sgd-gm-m { width: 21px; height: 16px; }
.sgd-gm-logo b { color: var(--sgd-m-icon); font-size: 16px; font-weight: 400; letter-spacing: -.01em; }
.sgd-mail-search { display: flex; flex: 1; align-items: center; gap: 9px; min-width: 0; height: 32px; padding: 0 12px; border-radius: 999px; background: var(--sgd-m-field); color: var(--sgd-m-sub); font-size: 12px; }
.sgd-mail-search > span { flex: 1; }
.sgd-mail-search svg { width: 15px; height: 15px; flex: none; }
.sgd-mail-icons { display: flex; align-items: center; gap: 12px; }
.sgd-me { width: 24px; height: 24px; border-radius: 50%; background: #0b8043; color: #fff; font-size: 11px; font-style: normal; font-weight: 600; }
.sgd-mail-main { display: flex; flex: 1; min-height: 0; }
.sgd-rail { display: flex; flex: none; flex-direction: column; align-items: center; gap: 10px; width: 46px; padding-top: 4px; color: var(--sgd-m-icon); }
.sgd-rail i { width: 30px; height: 26px; border-radius: 999px; }
.sgd-rail svg { width: 16px; height: 16px; }
.sgd-rail .is-on { background: #d3e3fd; color: #041e49; }
:root[data-theme="dark"] .sgd-rail .is-on { background: #004a77; color: #c2e7ff; }
.sgd-compose { width: 34px !important; height: 34px !important; margin-bottom: 4px; border-radius: 12px !important; background: #c2e7ff; color: #001d35; }
:root[data-theme="dark"] .sgd-compose { background: #004a77; color: #c2e7ff; }
.sgd-mail-in { flex: 1; min-width: 0; margin: 0 10px 0 0; padding: 4px 14px 10px; overflow: hidden; border-radius: 14px 14px 0 0; background: var(--sgd-m-card); }
.sgd-mail-tools { display: flex; align-items: center; gap: 14px; height: 30px; margin-bottom: 6px; color: var(--sgd-m-icon); }
.sgd-mail-tools svg { width: 15px; height: 15px; }
.sgd-subj { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.sgd-subj b { min-width: 0; overflow: hidden; font-size: 16px; font-weight: 400; text-overflow: ellipsis; white-space: nowrap; }
.sgd-label { flex: none; padding: 1px 6px; border-radius: 4px; background: #ddd; color: #444; font-size: 10px; }
:root[data-theme="dark"] .sgd-label { background: #5f6368; color: #e8eaed; }
.sgd-from { display: flex; align-items: flex-start; gap: 9px; margin-bottom: 10px; }
.sgd-from .sgd-av { width: 30px; height: 30px; color: #fff; font-size: 12px; font-style: normal; font-weight: 600; }
.sgd-from > span:not(.sgd-when) { flex: 1; min-width: 0; font-size: 12px; line-height: 1.35; }
.sgd-from b { font-weight: 600; } .sgd-from small { color: var(--sgd-m-sub); font-size: 10.5px; }
.sgd-from small + small { display: block; }
.sgd-when { flex: none; color: var(--sgd-m-sub); font-size: 10.5px; }
.sgd-mail-in p { margin: 0 0 10px; font-size: 12.5px; line-height: 1.5; }
.sgd-att-h { display: block; margin-bottom: 6px; padding-top: 8px; border-top: 1px solid var(--sgd-m-line); color: var(--sgd-m-sub); font-size: 11px; }
/* Gmail's attachment card: a thumbnail, and the file's name on a strip under it. */
.sgd-gatt { position: relative; display: grid; width: 168px; overflow: visible; border-radius: 6px; box-shadow: inset 0 0 0 1px var(--sgd-m-line); }
.sgd-gatt-thumb { position: relative; display: grid; height: 56px; place-items: center; border-radius: 6px 6px 0 0; background: var(--sgd-m-bg); }
.sgd-gatt-thumb .sgd-dl { position: absolute; top: 6px; right: 6px; background: var(--sgd-m-card); box-shadow: 0 1px 3px rgba(0, 0, 0, .25); }
.sgd-gatt-name { display: flex; align-items: center; gap: 6px; padding: 6px 8px; font-size: 11px; }
.sgd-gatt-name b { min-width: 0; overflow: hidden; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.sgd-ext-dot { width: 12px; height: 14px; flex: none; border-radius: 2px; background: #64748b; }
.sgd-ext-dot.is-zip { background: #f5b301; } .sgd-ext-dot.is-exe { background: #2563eb; }
/* Outlook: its blue bar, the New mail button, the first-contact tip, the attachment above the words. */
.sgd-mail.is-outlook { --sgd-m-bg: #f0f0f0; --sgd-m-field: #fff; --sgd-m-line: #e1dfdd; }
:root[data-theme="dark"] .sgd-mail.is-outlook { --sgd-m-bg: #1b1a19; --sgd-m-card: #292827; --sgd-m-field: #3b3a39; --sgd-m-line: #484644; }
.sgd-mail.is-outlook .sgd-mail-top { height: 40px; background: #0f6cbd; color: #fff; }
:root[data-theme="dark"] .sgd-mail.is-outlook .sgd-mail-top { background: #1f1f1f; box-shadow: inset 0 -1px 0 #333; }
.sgd-mail.is-outlook .sgd-mail-top > b { font-size: 14px; font-weight: 600; }
.sgd-mail.is-outlook .sgd-mail-search { height: 28px; border-radius: 4px; }
.sgd-mail.is-outlook .sgd-me { background: #c239b3; }
.sgd-mail.is-outlook .sgd-rail { width: 44px; padding-top: 8px; }
.sgd-mail.is-outlook .sgd-rail i { border-radius: 4px; }
.sgd-mail.is-outlook .sgd-rail .is-on { background: rgba(15, 108, 189, .12); color: #0f6cbd; }
:root[data-theme="dark"] .sgd-mail.is-outlook .sgd-rail .is-on { background: rgba(71, 158, 245, .16); color: #479ef5; }
.sgd-mail.is-outlook .sgd-mail-in { margin-top: 8px; border-radius: 6px 6px 0 0; }
.sgd-ol-new { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 4px; background: #0f6cbd; color: #fff; font-size: 11.5px; font-weight: 600; }
.sgd-ol-new svg { width: 13px; height: 13px; }
.sgd-ol-tip { display: block; margin-bottom: 8px; padding: 6px 9px; border-radius: 4px; background: var(--sgd-m-bg); color: var(--sgd-m-sub); font-size: 10.5px; }
.sgd-ol-tip u { color: #0f6cbd; text-decoration: none; } :root[data-theme="dark"] .sgd-ol-tip u { color: #479ef5; }
.sgd-oatt { position: relative; display: flex; align-items: center; gap: 8px; width: 186px; margin-bottom: 10px; padding: 6px 8px; border-radius: 4px; box-shadow: inset 0 0 0 1px var(--sgd-m-line); }
.sgd-oatt .sgd-ext-tag { width: 24px; height: 28px; }
.sgd-oatt > span { flex: 1; min-width: 0; }
.sgd-oatt b { display: block; overflow: hidden; font-size: 11.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.sgd-oatt small { display: block; color: var(--sgd-m-sub); font-size: 10.5px; }
.sgd-ext-tag.is-vbs { background: #64748b; color: #fff; } .sgd-ext-tag.is-zip { background: #f5b301; color: #3a2a00; } .sgd-ext-tag.is-exe { background: #2563eb; color: #fff; }

/* A results page in a narrow page: snippets a line long, so three results fit. */
@container sgd-page (max-width: 380px) {
  .sgd-snip { -webkit-line-clamp: 1; }
  .sgd-res { margin-bottom: 10px; }
}

/* Webmail in a narrow page (the side panel open beside it): as Gmail and Outlook do in a
   narrow window, the rail goes, search is its icon, the toolbar keeps its first few. */
@container sgd-page (max-width: 380px) {
  .sgd-rail { display: none; }
  .sgd-mail-in { margin-left: 10px; padding-right: 12px; padding-left: 12px; }
  .sgd-mail-top { gap: 10px; }
  .sgd-mail-search { flex: 0 0 auto; justify-content: center; width: 32px; padding: 0; }
  .sgd-mail-search > span, .sgd-mail-search > svg + span + svg { display: none; }
  .sgd-mail-icons i:not(.sgd-me) { display: none; }
  .sgd-mail-icons { margin-left: auto; }
  .sgd-mail-tools > i:nth-of-type(n+4) { display: none; }
  .sgd-ol-new { white-space: nowrap; }
  .sgd-ol-tip { display: none; }
  .sgd-subj b { font-size: 14px; }
  .sgd-from small:first-of-type { display: block; }
  .sgd-mail-in p { margin-bottom: 8px; font-size: 12px; }
}

/* A phishing email's button, outlined as content.js marks one, and the address it goes to,
   underlined in a dangerous email's dashed red once SiteGuard has looked. */
.sgd-mail-cta { display: inline-block; margin: 2px 0 10px; padding: 8px 18px; border-radius: 4px; color: #fff; font-size: 12px; font-weight: 700; }
.sgd-mail.is-gmail .sgd-mail-cta { color: #1d1d1f; }
.sgd-mail-link { display: block; color: var(--sgd-m-sub); font-size: 10.5px; }
.sgd-mail-link u { color: #1a73e8; text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 3px; transition: color .3s, text-decoration-color .3s; }
:root[data-theme="dark"] .sgd-mail-link u { color: #8ab4f8; }
.sgd[data-step="found"] .sgd-mail-link u { color: #b91c1c; text-decoration: underline dashed #dc2626; }
:root[data-theme="dark"] .sgd[data-step="found"] .sgd-mail-link u { color: #f87171; }
/* The brand a finding's host pretends to be, by its logo (popup.js finding-brand). */
.sgd-fbrand { width: 24px; height: 15px; flex: none; }

/* An investment ad's picture: a line that only goes up. */
.sgd-chart { justify-content: space-between; height: 96px; background: #0b1f17; color: #fff; }
.sgd-chart .sgd-poster b { color: #3ddc84; font-size: 26px; } .sgd-chart .sgd-poster small { color: #b8e6cc; }
.sgd-chart-line { width: 130px; height: 60px; fill: none !important; stroke: #3ddc84 !important; stroke-width: 3 !important; }
.sgd-post.sgd-remind { position: relative; }

/* A college journal's page, hijacked with slot spam, under its block page. */
.sgd-journal { height: 100%; background: #fff; color: #222; }
:root[data-theme="dark"] .sgd-journal { background: #1f1f22; color: #e8e8ea; }
.sgd-journal-top { display: flex; align-items: center; gap: 14px; padding: 10px 16px; background: #24356b; color: #dfe6ff; font-size: 11px; }
.sgd-journal-top b { margin-right: auto; color: #fff; font-size: 13px; }
.sgd-journal-in { display: grid; gap: 6px; padding: 14px 16px; }
.sgd-journal-in small { color: var(--sgd-sub); font-size: 10.5px; }
.sgd-journal-in > b { font-size: 16px; }
.sgd-journal-in > span:not(.sgd-tiles) { color: var(--sgd-sub); font-size: 12px; }
.sgd-journal .sgd-tiles i { height: 54px; background: linear-gradient(135deg, #f5c542, #c2410c); }

/* A fake browser update, and an installer on its maker's own site with Chrome's download bubble. */
.sgd-upd, .sgd-vlc { display: grid; align-content: start; justify-items: center; gap: 8px; height: 100%; padding: 40px 30px 0; box-sizing: border-box; text-align: center; }
.sgd-upd { background: #f1f3f4; color: #202124; } :root[data-theme="dark"] .sgd-upd { background: #202124; color: #e8eaed; }
.sgd-upd-logo { width: 54px; height: 54px; border-radius: 50%; background: radial-gradient(circle, #fff 0 30%, #4285f4 31% 42%, transparent 43%), conic-gradient(#db4437 0 33%, #f4b400 0 66%, #0f9d58 0); }
.sgd-upd b, .sgd-vlc b { font-size: 17px; }
.sgd-upd small, .sgd-vlc small { max-width: 300px; color: var(--sgd-sub); font-size: 12px; }
.sgd-upd-btn, .sgd-vlc-btn { position: relative; margin-top: 6px; padding: 8px 22px; border-radius: 6px; background: #1a73e8; color: #fff; font-size: 13px; font-weight: 600; }
.sgd-vlc { background: var(--sgd-page); }
.sgd-cone { width: 0; height: 0; border-right: 22px solid transparent; border-bottom: 50px solid #ff8800; border-left: 22px solid transparent; }
.sgd-vlc-btn { background: #ff8800; }
.sgd-upd-btn .sgd-cursor, .sgd-vlc-btn .sgd-cursor { top: 50%; left: 70%; }
.sgd-dlb { position: absolute; top: 8px; right: 10px; z-index: 6; display: grid; gap: 8px; width: 250px; padding: 12px; border-radius: 10px; background: var(--surface); color: var(--ink);
  box-shadow: 0 0 0 .5px rgba(0, 0, 0, .12), 0 12px 32px rgba(0, 0, 0, .25); opacity: 0; transform: translateY(-8px); }
:root[data-theme="dark"] .sgd-dlb { background: #2b2b2e; }
.sgd-dlb > b { font-size: 12.5px; font-weight: 600; }
.sgd-dlb-row { display: flex; align-items: center; gap: 9px; }
.sgd-dlb-row b { display: block; font-size: 12px; } .sgd-dlb-row small { display: block; color: var(--muted); font-size: 10.5px; }
.sgd[data-step="found"] .sgd-dlb { opacity: 1; transform: none; transition: opacity .3s 1.6s, transform .5s var(--spring) 1.6s; }

/* Look-alike bank and e-wallet pages: Maybank2u's yellow, Touch 'n Go's blue. */
.sgd-m2u, .sgd-tngpage, .sgd-packet, .sgd-loan { height: 100%; background: var(--sgd-soft); color: var(--ink); }
.sgd-m2u-top { display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 16px; background: #ffc83d; color: #1d1d1f; }
.sgd-m2u-top b { font-size: 14px; } .sgd-m2u-top span { margin-left: auto; padding: 2px 8px; border-radius: 4px; background: #1d1d1f; color: #ffc83d; font-size: 10px; font-weight: 800; }
.sgd-m2u-in, .sgd-tngpage-in, .sgd-loan-in { display: grid; gap: 8px; max-width: 280px; margin: 18px auto 0; padding: 16px; border-radius: 10px; background: var(--sgd-page); }
.sgd-m2u-in b, .sgd-tngpage-in b, .sgd-loan-in b { font-size: 13.5px; }
.sgd-m2u-in small, .sgd-tngpage-in small { color: var(--sgd-sub); font-size: 10.5px; }
.sgd-m2u .sgd-btn { border-radius: 6px; background: #1d1d1f; color: #ffc83d; }
.sgd-tngpage-top { display: grid; height: 42px; place-items: center; background: #0d4fc4; }
.sgd-tngpage .sgd-btn, .sgd-packet .sgd-btn { border-radius: 8px; background: #0d4fc4; }
.sgd-pin { position: relative; outline: 2px solid #0d4fc4; outline-offset: -1px; }
.sgd-pin .sgd-cursor { top: 50%; left: 30%; }
/* The typing guard's card beside the field (typing_guard.js), and the upload guard's (doc_guard.js). */
.sgd-guard, .sgd-upcard { position: absolute; right: 14px; bottom: 16px; z-index: 6; display: grid; gap: 6px; width: 236px; padding: 12px; border-radius: 12px; background: var(--surface); color: var(--ink);
  box-shadow: 0 0 0 1px var(--line), 0 14px 32px rgba(0, 0, 0, .28); opacity: 0; transform: translateY(10px); }
:root[data-theme="dark"] :is(.sgd-guard, .sgd-upcard) { background: #2b2b2e; box-shadow: 0 0 0 1px rgba(255, 255, 255, .12), 0 14px 32px rgba(0, 0, 0, .7); }
.sgd[data-step="found"] :is(.sgd-guard, .sgd-upcard) { opacity: 1; transform: none; transition: opacity .3s 1.4s, transform .5s var(--spring) 1.4s; }
.sgd-guard-head { display: flex; align-items: center; gap: 7px; }
.sgd-guard-head img { width: 16px; height: 16px; } .sgd-guard-head b { font-size: 12.5px; }
.sgd-guard p, .sgd-upcard p { margin: 0; color: var(--ink-soft); font-size: 11px; line-height: 1.45; }
.sgd-guard-why { color: var(--accent-ink); font-size: 11px; font-weight: 700; }
.sgd-guard-acts { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 2px; }
.sgd-guard-acts span { padding: 6px 0; border-radius: 7px; background: var(--surface-soft); box-shadow: inset 0 0 0 1px var(--line); font-size: 11px; font-weight: 600; text-align: center; white-space: nowrap; }
.sgd-guard-acts span:first-child { background: var(--accent); box-shadow: none; color: #fff; }
.sgd-upcard-hit { display: flex; justify-content: space-between; gap: 8px; padding: 6px 8px; border-radius: 7px; background: var(--red-soft); color: var(--red); font-size: 10.5px; }
/* A "Money Packet" with its red envelope. */
.sgd-packet-in { display: grid; justify-items: center; gap: 6px; max-width: 240px; margin: 20px auto 0; padding: 18px; border-radius: 14px; background: #d32f2f; color: #fff; text-align: center; }
.sgd-angpow { width: 40px; height: 48px; border-radius: 6px; background: #ffca28; box-shadow: inset 0 14px 0 -10px #f9a825; }
.sgd-packet-in b { font-size: 13px; } .sgd-packet-amt { font-size: 26px; font-weight: 800; } .sgd-packet-in small { color: #ffd6d6; font-size: 11px; }
.sgd-packet .sgd-btn { background: #fff; color: #d32f2f; }
/* A government-looking aid banner. */
.sgd-gov { height: 100px; background: #0b2a5b; color: #fff; }
.sgd-gov .sgd-poster b { color: #f2c200; font-size: 19px; } .sgd-gov .sgd-poster small { color: #c8d3e8; }
.sgd-ribbon.is-gov { background: #f2c200; color: #0b2a5b; }
.sgd-gov .sgd-crest { width: 46px; height: 46px; margin-left: auto; }
.sgd-av.is-navy { background: #0b2a5b; color: #f2c200; font-size: 9px; }
/* Telegram: a promo's picture, a forwarded contact card with its MESSAGE and ADD. */
.sgd-tg-promo { display: grid; margin: -2px -5px 6px; padding: 10px; border-radius: 8px; background: #1b1330; color: #ffd700; text-align: center; }
.sgd-tg-promo b { font-size: 14px; } .sgd-tg-promo small { float: none; margin: 0; color: #e7dcff; font-size: 10px; }
.sgd-tg-card { display: flex; align-items: center; gap: 8px; margin: 4px 0 6px; }
.sgd-tg-card .sgd-av { width: 34px; height: 34px; background: linear-gradient(#72d5fd, #2a9ef1); color: #fff; font-style: normal; font-weight: 700; }
.sgd-tg-card b { display: block; font-size: 12.5px; } .sgd-tg-card small { display: block; float: none; margin: 0; font-size: 11px; }
.sgd-tg-card-acts { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin: 0 -9px -6px; border-top: 1px solid rgba(128, 128, 128, .2); }
.sgd-tg-card-acts span { padding: 6px 0; color: #3390ec; font-size: 10.5px; font-weight: 700; text-align: center; }
/* A loan form with its file picker. */
.sgd-loan-top { display: flex; align-items: center; justify-content: space-between; height: 40px; padding: 0 16px; background: #2e7d32; color: #fff; font-size: 11px; }
.sgd-loan-top b { font-size: 13.5px; }
.sgd-loan-in { margin: 14px 16px 0; max-width: none; }
.sgd-drop { display: flex; align-items: center; gap: 8px; padding: 12px; border: 1.5px dashed var(--line-strong); border-radius: 8px; font-size: 11.5px; }
.sgd-drop > i { display: grid; color: var(--sgd-sub); } .sgd-drop svg { width: 16px; height: 16px; }
.sgd-drop > span:not(.sgd-drop-btn) { flex: 1; }
.sgd-drop-btn { position: relative; padding: 4px 10px; border-radius: 6px; background: var(--sgd-soft); font-weight: 600; }
.sgd-loan .sgd-btn { border-radius: 6px; background: #2e7d32; }

/* Under the window: what the scene shows, in a sentence. All of them in one cell, so the height never jumps. */
.sgd-captions { display: grid; margin-top: 14px; }
.sgd-caption { grid-area: 1 / 1; margin: 0; color: var(--muted); font-size: var(--fs-small); line-height: 1.5; opacity: 0; transition: opacity .3s; }
.sgd-caption.is-on { opacity: 1; }

/* A narrow window: the page's words get smaller, the block card tighter. */
@container (max-width: 440px) {
  .sgd-block { padding: 16px 14px 12px; grid-template-columns: 26px minmax(0, 1fr); column-gap: 10px; }
  .sgd-mark, .sgd-mark svg { width: 26px; height: 26px; }
  .sgd-pic { height: 108px; } .sgd .sgd-qr { width: 66px; height: 66px; } .sgd-poster b { font-size: 18px; } .sgd-pic .sgd-device { display: none; }
  .sgd-link { font-size: 14px; }
}
/* A phone-wide window: no room for the panel beside the page, so it opens under it, full width,
   like a sheet, and the page scrolls (demo.js's lift) to keep what SiteGuard marked in view. */
.sgd-window { container: sgd-win / inline-size; }
@container sgd-win (max-width: 480px) {
  .sgd-body { flex-direction: column; height: 480px; }
  .sgd-page { flex: 1 1 0; min-height: 0; }
  /* The page keeps its whole height under the panel, as a page does: the panel covers it, it doesn't squash it. */
  .sgd-scene { bottom: auto; height: 480px; }
  .sgd-panel { width: auto; height: 0; border-left: 0; border-top: 0 solid var(--line); transition: height .45s var(--spring), border-width 0s .45s; }
  .sgd[data-answer="panel"][data-step="found"] .sgd-panel { width: auto; height: 250px; border-left-width: 0; border-top-width: 1px; transition: height .6s var(--spring) .35s; }
  .sgd[data-late][data-step="found"] .sgd-panel { transition-delay: 1.5s; }
  .sgd[data-panel][data-step="found"] .sgd-panel { width: auto; height: 250px; border-left-width: 0; border-top-width: 1px; }
  .sgd-panel-in { width: 100%; height: 250px; font-size: 12.5px; }
  .sgd-pv-foot { display: none; }
  .sgd-panel-head { height: 36px; }
  .sgd-pv-in { padding: 8px 10px 10px; }
  .sgd-sp-h { margin: 8px 0 5px; }
  .sgd.is-fixed .sgd-body, .sgd.is-fixed .sgd-scene { height: 560px; }
  .sgd.is-fixed[data-answer="panel"][data-step="found"] .sgd-panel, .sgd.is-fixed[data-panel][data-step="found"] .sgd-panel, .sgd.is-fixed .sgd-panel-in { height: 320px; }
}
@media (prefers-reduced-motion: reduce) {
  .sgd *, .sgd *::before, .sgd *::after { animation: none !important; transition: none !important; }
  .sgd-mark :is(path, rect) { stroke-dashoffset: 0; }
}

/* ---- The explorer (demo.js's explorer()): every scene, to pick from ------------------------
   On the left, the places as chips (each with how many examples it has) and the scenes as a
   list, each with its kind; on the right, the demo playing the picked one (with no tabs of its
   own), and under it the picked one's name with arrows to step through the list, what to do in
   that place, what going on anyway would cost, how to report it, and Replay, Random example
   and Full screen. Side by side when there is room; one above the other when there isn't, the
   list then a row of cards with arrows at its ends. */
.sgx { container: sgx / inline-size; --sgx-fade: var(--sgd-fade, var(--canvas)); }
.sgx-in { display: grid; grid-template-columns: minmax(250px, 300px) minmax(0, 1fr); gap: 28px; align-items: start; }
.sgd.is-fixed .sgd-tabs-wrap { display: none; }
/* Taller than the auto-playing demo: there is a panel to read and a report form to fill in. */
.sgd.is-fixed { --sgd-h: 420px; }
.sgx-side { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.sgx-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.sgx .sgx-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 0; margin: 0; padding: 5px 9px 5px 11px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); box-shadow: none;
  color: var(--ink-soft); font: inherit; font-size: var(--fs-caption, 12px); font-weight: 600; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.sgx .sgx-chip::after { min-width: 18px; padding: 0 5px; border-radius: 999px; background: var(--surface-soft); color: var(--muted); content: attr(data-n); font-size: 10.5px; font-weight: 700; line-height: 16px; text-align: center; font-variant-numeric: tabular-nums; }
.sgx .sgx-chip:hover { border-color: var(--line-strong); background: var(--surface-soft); color: var(--ink); }
.sgx .sgx-chip[aria-pressed="true"] { border-color: var(--ink); background: var(--ink); color: var(--surface); }
.sgx .sgx-chip[aria-pressed="true"]::after { background: color-mix(in srgb, var(--surface) 22%, transparent); color: var(--surface); }
.sgx-list-wrap { position: relative; min-width: 0; }
.sgx-list { position: relative; display: flex; flex-direction: column; gap: 2px; max-height: 470px; margin: 0 -4px; padding: 0 4px; overflow-y: auto; scrollbar-width: thin; overscroll-behavior: contain; }
.sgx .sgx-list-arrow { display: none; }
.sgx .sgx-item { display: grid; flex: none; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px; height: auto; min-height: 0; margin: 0; padding: 7px 10px 7px 12px; line-height: 1.35; border: 1px solid transparent;
  border-radius: 10px; background: none; box-shadow: none; color: var(--ink); font: inherit; text-align: left; cursor: pointer; transition: background .15s, border-color .15s; }
.sgx .sgx-item[hidden] { display: none; }
.sgx .sgx-item:hover { background: var(--surface-soft); }
.sgx .sgx-item[aria-pressed="true"] { border-color: var(--line); background: var(--surface); box-shadow: 0 1px 2px rgba(0, 0, 0, .06); }
.sgx-item-t { overflow: hidden; font-size: var(--fs-small); font-weight: 600; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.sgx-group { flex: none; margin: 12px 0 4px; padding: 0 12px; color: var(--muted); font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.sgx-group:first-child { margin-top: 2px; }
.sgx-group[hidden] { display: none; }
.sgx-kind { padding: 2px 8px; border-radius: 999px; background: color-mix(in srgb, var(--k) 12%, transparent);
  color: var(--k); font-size: 11px; font-weight: 700; white-space: nowrap; }
.sgx-kind.k-phishing { --k: var(--phishing); } .sgx-kind.k-malware, .sgx-kind.k-file { --k: var(--malware); }
.sgx-kind.k-gambling { --k: var(--gambling); } .sgx-kind.k-nsfw { --k: var(--nsfw); }
.sgx-kind.k-scam { --k: var(--red); } .sgx-kind.k-data, .sgx-kind.k-check { --k: var(--amber); } .sgx-kind.k-safe { --k: var(--green); }
.sgx .sgx-item:focus-visible, .sgx .sgx-chip:focus-visible, .sgx .sgx-btn:focus-visible, .sgx .sgx-nav:focus-visible, .sgx .sgx-fold-t:focus-visible, .sgx .sgx-list-arrow:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sgx-main { min-width: 0; }
.sgx svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* Under the demo: the picked one, what to do, the two folds, the buttons. */
.sgx-info { margin-top: 18px; padding: 14px 18px 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.sgx-now { display: flex; align-items: center; gap: 10px; min-width: 0; margin: 0 0 12px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.sgx-now .sgx-kind { flex: none; }
.sgx-now-t { flex: 1; min-width: 0; overflow: hidden; color: var(--ink); font-size: var(--fs-body); font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.sgx-step { display: inline-flex; flex: none; align-items: center; gap: 4px; }
.sgx-pos { min-width: 52px; color: var(--muted); font-size: var(--fs-caption, 12px); font-weight: 600; text-align: center; font-variant-numeric: tabular-nums; }
.sgx .sgx-nav { display: grid; width: 30px; height: 30px; min-height: 0; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); box-shadow: none; color: var(--ink); cursor: pointer; place-items: center; }
.sgx .sgx-nav:hover { border-color: var(--line-strong); background: var(--surface-soft); }
.sgx .sgx-nav svg { width: 16px; height: 16px; stroke-width: 2.2; }
.sgx-info-h { display: block; margin-bottom: 4px; font-size: var(--fs-caption, 12px); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.sgx-advices { display: grid; }
.sgx-advice { grid-area: 1 / 1; margin: 0; color: var(--ink); font-size: var(--fs-small); line-height: 1.55; opacity: 0; visibility: hidden; transition: opacity .25s; }
.sgx-advice.is-on { opacity: 1; visibility: visible; }
.sgx-fold { margin-top: 10px; border-top: 1px solid var(--line); }
.sgx-fold[hidden] { display: none; }
.sgx .sgx-fold-t { display: flex; width: 100%; align-items: center; gap: 8px; min-height: 0; margin: 0; padding: 10px 0 0; border: 0; border-radius: 0; background: none; box-shadow: none;
  color: var(--ink); font: inherit; font-size: var(--fs-small); font-weight: 650; text-align: left; cursor: pointer; }
.sgx .sgx-fold-t:hover { background: none; color: var(--accent); }
.sgx-fold-t svg { width: 16px; height: 16px; flex: none; color: var(--muted); }
.sgx-fold-t svg:last-child { width: 14px; height: 14px; margin-left: auto; stroke-width: 2.2; transition: transform .3s var(--spring-bounce); }
.sgx-fold-t[aria-expanded="true"] svg:last-child { transform: rotate(90deg); }
.sgx-fold.is-after .sgx-fold-t > svg:first-child { color: var(--red); }
.sgx-fold-body { padding: 8px 0 2px 24px; color: var(--ink-soft); font-size: var(--fs-small); line-height: 1.55; }
.sgx-fold-body[hidden] { display: none; }
.sgx-fold-body p { margin: 0 0 6px; }
.sgx-after[hidden] { display: none; }
.sgx-after-h { color: var(--ink); font-weight: 650; }
.sgx-sub { margin: 12px 0 4px !important; color: var(--muted); font-size: var(--fs-caption, 12px); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.sgx-rows { display: grid; gap: 6px; margin: 0 0 6px; padding: 0; list-style: none; }
.sgx-rows li { display: grid; grid-template-columns: minmax(0, 180px) minmax(0, 1fr); gap: 2px 14px; padding: 8px 10px; border-radius: 10px; background: var(--surface-soft); }
.sgx-rows b { color: var(--ink); font-weight: 650; }
.sgx-fine { margin: 10px 0 0 !important; color: var(--muted); font-size: var(--fs-caption, 12px); font-style: italic; }
.sgx-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.sgx .sgx-btn { display: inline-flex; align-items: center; gap: 7px; min-height: 0; margin: 0; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); box-shadow: none;
  color: var(--ink); font: inherit; font-size: var(--fs-small); font-weight: 600; white-space: nowrap; cursor: pointer; }
.sgx .sgx-btn svg { width: 15px; height: 15px; }
.sgx .sgx-btn:hover { border-color: var(--line-strong); background: var(--surface-soft); }
.sgx .sgx-btn.is-random { border-color: var(--ink); background: var(--ink); color: var(--surface); }
.sgx .sgx-btn.is-random:hover { opacity: .88; background: var(--ink); }
.sgx .sgx-btn.is-full { margin-left: auto; }
.sgx-full-on, .sgx.is-full .sgx-full-off { display: none; }
.sgx.is-full .sgx-full-on { display: inline; }

/* Full screen: the demo and its card fill the screen, the window as tall as there is room for. */
.sgx.is-full .sgx-main { position: fixed; inset: 0; z-index: 2147483000; overflow-y: auto; padding: 24px max(24px, calc((100vw - 1180px) / 2)); background: var(--canvas); }
.sgx-main:fullscreen { overflow-y: auto; padding: 24px max(24px, calc((100vw - 1180px) / 2)); background: var(--canvas); }
.sgx.is-full .sgx-main .sgd { --sgd-h: max(420px, calc(100vh - 300px)); }
.sgx.is-full .sgx-main .sgd-panel-in { font-size: 13px; }
/* On a big screen the drawn browser is drawn bigger too, as a real one would fill it. */
@media (min-width: 1100px) and (min-height: 760px) {
  .sgx.is-full .sgx-main .sgd { zoom: 1.2; --sgd-h: max(400px, calc((100vh - 330px) / 1.2)); }
}

@container sgx (max-width: 760px) {
  .sgx-in { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .sgx-list-wrap { margin: 0 -2px; }
  .sgx-list { flex-direction: row; gap: 8px; max-height: none; margin: 0; padding: 2px 2px 4px; overflow-x: auto; overflow-y: hidden; scrollbar-width: none; scroll-snap-type: x proximity; }
  .sgx-list::-webkit-scrollbar { display: none; }
  .sgx-group { display: none; }
  .sgx .sgx-item { width: 196px; grid-template-columns: minmax(0, 1fr); align-content: start; justify-items: start; gap: 6px; padding: 10px 12px; border-color: var(--line); background: var(--surface); scroll-snap-align: start; }
  .sgx .sgx-item .sgx-kind { order: -1; }
  .sgx .sgx-item-t { display: -webkit-box; min-height: 2.7em; white-space: normal; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
  .sgx .sgx-item[aria-pressed="true"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
  .sgx .sgx-list-arrow { position: absolute; top: 0; bottom: 4px; z-index: 1; display: grid; width: 44px; min-height: 0; margin: 0; padding: 0; border: 0; border-radius: 0; box-shadow: none;
    color: var(--ink); cursor: pointer; opacity: 0; pointer-events: none; transition: opacity .2s; place-items: center; }
  .sgx .sgx-list-arrow svg { width: 26px; height: 26px; padding: 4px; border-radius: 50%; background: var(--surface); box-shadow: 0 0 0 1px var(--line), 0 2px 6px rgba(0, 0, 0, .12); stroke-width: 2.2; }
  .sgx .sgx-list-arrow.is-prev, .sgx .sgx-list-arrow.is-prev:hover { left: 0; justify-items: start; background: linear-gradient(90deg, var(--sgx-fade) 40%, transparent); }
  .sgx .sgx-list-arrow.is-next, .sgx .sgx-list-arrow.is-next:hover { right: 0; justify-items: end; background: linear-gradient(270deg, var(--sgx-fade) 40%, transparent); }
  .sgx-list-wrap.can-prev .is-prev, .sgx-list-wrap.can-next .is-next { opacity: 1; pointer-events: auto; }
}
@container sgx (max-width: 520px) {
  .sgx-rows li { grid-template-columns: minmax(0, 1fr); }
  .sgx .sgx-btn.is-full { margin-left: 0; }
  .sgx-now { flex-wrap: wrap; } .sgx-now-t { flex-basis: calc(100% - 120px); }
}
@media (prefers-reduced-motion: reduce) { .sgx-advice, .sgx-chip, .sgx-item, .sgx-fold-t svg { transition: none; } }
.sgx-chips, .sgx-list { user-select: none; -webkit-user-select: none; }
.sgx-chips.is-dragging .sgx-chip, .sgx-list.is-dragging .sgx-item { pointer-events: none; }
