/* Fonts served by Prism itself (no request to Google): Orbitron, Chakra Petch and JetBrains Mono, Latin and Latin
   Extended subsets, SIL Open Font License (web/font-licenses/). */
/* latin-ext */
@font-face {
  font-family: 'Chakra Petch';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/static/chakra-petch-400-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'Chakra Petch';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/static/chakra-petch-400-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
  font-family: 'Chakra Petch';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/static/chakra-petch-500-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'Chakra Petch';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/static/chakra-petch-500-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
  font-family: 'Chakra Petch';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/static/chakra-petch-600-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'Chakra Petch';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/static/chakra-petch-600-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
  font-family: 'Chakra Petch';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/static/chakra-petch-700-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'Chakra Petch';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/static/chakra-petch-700-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/static/jetbrains-mono-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/static/jetbrains-mono-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/static/jetbrains-mono-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/static/jetbrains-mono-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin */
@font-face {
  font-family: 'Orbitron';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/static/orbitron-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin */
@font-face {
  font-family: 'Orbitron';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/static/orbitron-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin */
@font-face {
  font-family: 'Orbitron';
  font-style: normal;
  font-weight: 900;
  font-display: swap;
  src: url(/static/orbitron-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #03050b; --panel: rgba(10, 18, 34, .72); --panel-solid: #0a1222; --line: rgba(64, 224, 255, .16);
  --line-hi: rgba(64, 224, 255, .45); --text: #e6f3ff; --muted: #7d93b2; --dim: #4a5d7a;
  --cyan: #3ee6ff; --violet: #9b7bff; --danger: #ff3d6e; --warn: #ffb22e; --safe: #2ef5a3;
  --display: "Orbitron", "Segoe UI", sans-serif; --ui: "Chakra Petch", "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", Consolas, monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { background: var(--bg); color: var(--text); font: 15px/1.5 var(--ui); overflow-x: hidden; }
/* Backdrop: perspective grid, glows, scanlines */
.backdrop { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.backdrop::before { content: ""; position: absolute; inset: 0;
  background: radial-gradient(900px 500px at 15% -10%, rgba(62, 230, 255, .14), transparent 60%),
              radial-gradient(800px 500px at 100% 0%, rgba(155, 123, 255, .14), transparent 60%),
              radial-gradient(700px 400px at 50% 120%, rgba(62, 230, 255, .08), transparent 60%); }
.grid { position: absolute; left: -50%; right: -50%; bottom: -10%; height: 60%;
  background-image: linear-gradient(rgba(62, 230, 255, .13) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(62, 230, 255, .13) 1px, transparent 1px);
  background-size: 64px 64px; transform: perspective(500px) rotateX(62deg); transform-origin: bottom;
  mask-image: linear-gradient(to top, #000 0%, transparent 85%); animation: drift 6s linear infinite; }
@keyframes drift { to { background-position: 0 64px; } }
.backdrop::after { content: ""; position: absolute; inset: 0;
  background: repeating-linear-gradient(0deg, rgba(255,255,255,.018) 0 1px, transparent 1px 3px); }
main { position: relative; z-index: 1; max-width: 1180px; margin: 0 auto; padding: 28px 16px 64px; }

/* Header */
header { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 26px; }
.logo { width: 52px; height: 52px; flex: none; filter: drop-shadow(0 0 12px rgba(62, 230, 255, .55)); }
.brand h1 { font: 900 26px/1 var(--display); letter-spacing: .32em; margin: 0;
  background: linear-gradient(90deg, #fff, var(--cyan) 55%, var(--violet)); -webkit-background-clip: text;
  background-clip: text; color: transparent; }
.brand p { margin: 6px 0 0; font: 500 11px var(--display); letter-spacing: .28em; color: var(--muted); }
.spacer { flex: 1; }
.status { display: flex; align-items: center; gap: 10px; padding: 8px 14px; border: 1px solid var(--line);
  background: var(--panel); border-radius: 999px; font-size: 13px; color: var(--muted); max-width: 100%;
  backdrop-filter: blur(10px); min-width: 0; }
.status b { color: var(--text); font: 600 11px var(--display); letter-spacing: .14em; flex: none; }
.status span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.pulse { width: 9px; height: 9px; border-radius: 50%; background: var(--safe); flex: none;
  box-shadow: 0 0 0 0 rgba(46, 245, 163, .6); animation: ping 1.8s infinite; }
.pulse.scanning { background: var(--cyan); box-shadow: 0 0 0 0 rgba(62, 230, 255, .6); animation-duration: .9s; }
.pulse.error { background: var(--danger); animation: none; box-shadow: 0 0 10px var(--danger); }
@keyframes ping { 70% { box-shadow: 0 0 0 10px rgba(0,0,0,0); } 100% { box-shadow: 0 0 0 0 rgba(0,0,0,0); } }

button { font: 600 12px var(--display); letter-spacing: .14em; text-transform: uppercase; color: var(--cyan);
  background: rgba(62, 230, 255, .06); border: 1px solid var(--line-hi); border-radius: 8px; padding: 10px 16px;
  cursor: pointer; transition: background .15s, box-shadow .15s, color .15s; }
button:hover { background: rgba(62, 230, 255, .14); box-shadow: 0 0 18px rgba(62, 230, 255, .25); }
button:focus-visible, input:focus-visible, select:focus-visible, .tile:focus-visible, .row-head:focus-visible {
  outline: 2px solid var(--cyan); outline-offset: 2px; }
button.icon { padding: 9px; line-height: 0; }
button.ghost { border-color: var(--line); color: var(--muted); }
button.ghost:hover { color: var(--text); }
button.bad { color: var(--danger); border-color: rgba(255, 61, 110, .5); background: rgba(255, 61, 110, .06); }
button.bad:hover { background: rgba(255, 61, 110, .14); box-shadow: 0 0 18px rgba(255, 61, 110, .3); }
button.good { color: var(--safe); border-color: rgba(46, 245, 163, .5); background: rgba(46, 245, 163, .06); }
button.good:hover { background: rgba(46, 245, 163, .14); box-shadow: 0 0 18px rgba(46, 245, 163, .3); }
button:disabled { opacity: .5; cursor: wait; }
.lock { display: inline-flex; align-items: center; gap: 5px; font: 700 10px var(--display); letter-spacing: .16em;
  color: var(--danger); border: 1px solid rgba(255, 61, 110, .5); background: rgba(255, 61, 110, .1); border-radius: 6px;
  padding: 2px 7px; box-shadow: 0 0 12px rgba(255, 61, 110, .25); white-space: nowrap; }
.lock.rel { color: var(--safe); border-color: rgba(46, 245, 163, .45); background: rgba(46, 245, 163, .08); box-shadow: none; }
.qbar { grid-column: 1 / -1; display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 10px;
  border: 1px solid rgba(255, 61, 110, .45); background: linear-gradient(90deg, rgba(255, 61, 110, .14), rgba(255, 61, 110, .03)); }
.qbar.rel { border-color: rgba(46, 245, 163, .4); background: linear-gradient(90deg, rgba(46, 245, 163, .1), rgba(46, 245, 163, .02)); }
.qbar svg { flex: none; }
.qbar b { font: 700 11px var(--display); letter-spacing: .18em; display: block; }
.qbar span { font-size: 13px; color: var(--muted); }
/* the email fakes who sent it: shown first in the detail panel */
.spoofbar { grid-column: 1 / -1; padding: 12px 16px; border-radius: 10px; border: 2px solid var(--danger);
  background: rgba(255, 61, 110, .16); box-shadow: 0 0 18px rgba(255, 61, 110, .25); }
.spoofbar b { display: block; font-size: 16px; color: var(--danger); }
.spoofbar ul { margin: 6px 0 0; padding-left: 18px; font-size: 13px; color: var(--muted); }
dialog { background: var(--panel-solid); color: var(--text); border: 1px solid var(--line-hi); border-radius: 14px;
  padding: 22px; width: min(460px, calc(100% - 32px)); box-shadow: 0 0 60px rgba(62, 230, 255, .2); }
dialog::backdrop { background: rgba(0, 0, 0, .6); backdrop-filter: blur(3px); }
dialog h3 { margin: 0 0 10px; font: 700 13px var(--display); letter-spacing: .2em; color: var(--warn); }
dialog p { margin: 0 0 12px; color: #c4d6ec; font-size: 14px; }
dialog .row-btns { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; flex-wrap: wrap; }

/* Stat tiles */
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 18px; }
.tile { position: relative; text-align: left; padding: 16px 18px; border-radius: 14px; border: 1px solid var(--line);
  background: var(--panel); backdrop-filter: blur(10px); cursor: pointer; color: var(--text); text-transform: none;
  letter-spacing: 0; font-family: var(--ui); overflow: hidden; }
.tile::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--c);
  box-shadow: 0 0 14px var(--c); opacity: .85; }
.tile:hover { box-shadow: 0 0 24px color-mix(in srgb, var(--c) 25%, transparent); background: var(--panel); }
.tile.on { border-color: var(--c); background: color-mix(in srgb, var(--c) 9%, var(--panel-solid)); }
.tile .k { font: 600 10px var(--display); letter-spacing: .22em; color: var(--muted); text-transform: uppercase; }
.tile .v { font: 700 34px/1.15 var(--display); color: var(--c); text-shadow: 0 0 18px color-mix(in srgb, var(--c) 55%, transparent);
  font-variant-numeric: tabular-nums; }
.tile .s { font-size: 12px; color: var(--dim); }

.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; flex-wrap: wrap; }
.search { flex: 1; min-width: 200px; position: relative; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--dim); }
input[type=search], select { width: 100%; font: 500 14px var(--ui); color: var(--text); background: var(--panel);
  border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px 10px 36px; backdrop-filter: blur(10px); }
select { width: auto; padding: 8px 10px; }
.accounts { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.acct { font: 600 12px var(--ui); color: var(--dim); background: var(--panel); border: 1px solid var(--line);
  border-radius: 999px; padding: 7px 14px; cursor: pointer; backdrop-filter: blur(10px); text-transform: none; letter-spacing: 0; }
.acct b { font: 600 11px var(--mono); margin-left: 6px; color: var(--text); }
.acct b.bad { color: var(--danger); }
.acct.on { color: var(--text); border-color: var(--cyan); box-shadow: 0 0 12px rgba(62, 230, 255, .25); }
.acct.add { color: var(--cyan); border-style: dashed; }
.acct i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 7px; background: var(--safe); vertical-align: 1px; }
.acct i.err { background: var(--danger); } .acct i.busy { background: var(--cyan); }
#addAcct { width: min(460px, calc(100vw - 32px)); }
#addAcct label { display: block; font: 600 11px var(--display); letter-spacing: .14em; color: var(--dim); margin: 12px 0 6px; }
#addAcct input, #addAcct select { width: 100%; padding: 10px 12px; box-sizing: border-box; font: 500 14px var(--ui);
  color: var(--text); background: rgba(0, 0, 0, .25); border: 1px solid var(--line); border-radius: 10px; }
#addAcct .help { font-size: 13px; color: #c4d6ec; background: rgba(62, 230, 255, .06); border: 1px solid var(--line);
  border-radius: 10px; padding: 10px 12px; margin-top: 12px; }
#addAcct .help.stop { background: rgba(255, 196, 0, .08); border-color: var(--warn); }
#addAcct .err { color: var(--danger); font-size: 13px; margin-top: 10px; min-height: 1em; }
.grid2 { display: grid; grid-template-columns: 1fr 110px; gap: 10px; }
.count { font: 500 11px var(--display); letter-spacing: .16em; color: var(--dim); }

/* Rows */
.list { display: flex; flex-direction: column; gap: 8px; }
.row { --c: var(--safe); border: 1px solid var(--line); border-left: 3px solid var(--c); border-radius: 12px;
  background: var(--panel); backdrop-filter: blur(10px); overflow: hidden; transition: border-color .2s; }
.row.danger { --c: var(--danger); } .row.suspect { --c: var(--warn); }
.row.danger { box-shadow: inset 4px 0 18px -10px var(--danger); }
.row.open { border-color: color-mix(in srgb, var(--c) 55%, transparent); border-left-color: var(--c); }
.row-head { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 14px; align-items: center;
  padding: 12px 16px; cursor: pointer; }
.row-head:hover { background: rgba(62, 230, 255, .035); }
.ring { width: 48px; height: 48px; position: relative; }
.ring svg { transform: rotate(-90deg); }
.ring .n { position: absolute; inset: 0; display: grid; place-items: center; font: 700 14px var(--display); color: var(--c);
  text-shadow: 0 0 10px var(--c); }
.who { display: flex; gap: 10px; align-items: baseline; min-width: 0; }
.who .name { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who .addr { font: 12px var(--mono); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.subj { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #c4d6ec; }
.unread .subj { color: var(--text); font-weight: 600; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.chip { font: 600 11px var(--ui); padding: 2px 8px; border-radius: 6px; border: 1px solid; white-space: nowrap; }
.chip.high { color: var(--danger); border-color: rgba(255, 61, 110, .4); background: rgba(255, 61, 110, .08); }
.chip.med { color: var(--warn); border-color: rgba(255, 178, 46, .4); background: rgba(255, 178, 46, .07); }
.chip.low { color: var(--muted); border-color: var(--line); }
.chip.good { color: var(--safe); border-color: rgba(46, 245, 163, .35); background: rgba(46, 245, 163, .06); }
.meta { text-align: right; font: 12px var(--mono); color: var(--muted); white-space: nowrap; }
.meta .verdict { font: 700 10px var(--display); letter-spacing: .2em; color: var(--c); display: block; margin-bottom: 4px; }
.meta .icons { display: flex; gap: 8px; justify-content: flex-end; margin-top: 4px; color: var(--dim); }
.meta .icons span { display: inline-flex; gap: 3px; align-items: center; }

/* Detail */
.detail { border-top: 1px solid var(--line); padding: 18px 16px 16px; display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 16px; animation: unfold .25s ease-out; }
@keyframes unfold { from { opacity: 0; transform: translateY(-6px); } }
.panel { position: relative; border: 1px solid var(--line); border-radius: 10px; padding: 14px; background: rgba(4, 9, 20, .55); }
.panel::before, .panel::after { content: ""; position: absolute; width: 12px; height: 12px; border-color: var(--cyan); opacity: .7; }
.panel::before { top: -1px; left: -1px; border-top: 2px solid; border-left: 2px solid; border-radius: 10px 0 0 0; }
.panel::after { bottom: -1px; right: -1px; border-bottom: 2px solid; border-right: 2px solid; border-radius: 0 0 10px 0; }
.panel.wide { grid-column: 1 / -1; }
.panel h3 { margin: 0 0 12px; font: 700 11px var(--display); letter-spacing: .24em; color: var(--cyan); text-transform: uppercase; }
dl { margin: 0; display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 7px 12px; font-size: 13.5px; }
dt { color: var(--muted); font: 600 10px/2 var(--display); letter-spacing: .14em; text-transform: uppercase; }
dd { margin: 0; overflow-wrap: anywhere; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.ok { color: var(--safe); } .bad { color: var(--danger); } .warn { color: var(--warn); } .dim { color: var(--muted); }
.auth { display: flex; gap: 6px; flex-wrap: wrap; }
.auth span { font: 600 11px var(--mono); padding: 2px 8px; border-radius: 6px; border: 1px solid currentColor; }
.finding { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; gap: 10px; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.finding:last-child { border-bottom: 0; }
.finding .ic { width: 10px; height: 10px; margin-top: 6px; transform: rotate(45deg); }
.finding.high .ic { background: var(--danger); box-shadow: 0 0 10px var(--danger); }
.finding.med .ic { background: var(--warn); box-shadow: 0 0 10px var(--warn); }
.finding.low .ic { background: var(--dim); }
.finding.good .ic { background: var(--safe); box-shadow: 0 0 10px var(--safe); }
.finding .t { font-weight: 600; }
.finding .d { color: var(--muted); font-size: 13px; overflow-wrap: anywhere; }
.finding .p { font: 600 12px var(--mono); color: var(--dim); }
.finding.high .p { color: var(--danger); } .finding.med .p { color: var(--warn); } .finding.good .p { color: var(--safe); }
table { width: 100%; border-collapse: collapse; font-size: 13px; table-layout: fixed; }
th { text-align: left; font: 600 10px var(--display); letter-spacing: .16em; color: var(--muted); padding: 0 8px 8px 0; text-transform: uppercase; }
td { padding: 7px 8px 7px 0; border-top: 1px solid var(--line); vertical-align: top; overflow-wrap: anywhere; }
td .mono { color: #a9c3e0; }
td.flags { color: var(--muted); }
.note { font-size: 12px; color: var(--dim); margin: 10px 0 0; }
.actions { grid-column: 1 / -1; display: flex; gap: 10px; flex-wrap: wrap; }
.empty { text-align: center; padding: 60px 16px; color: var(--muted); border: 1px dashed var(--line); border-radius: 14px; }
.empty .big { font: 700 15px var(--display); letter-spacing: .2em; color: var(--cyan); margin-bottom: 6px; }
.sweep { position: relative; height: 2px; margin: -10px 0 16px; overflow: hidden; border-radius: 2px; opacity: 0; transition: opacity .3s; }
.sweep.on { opacity: 1; }
.sweep::after { content: ""; position: absolute; inset: 0; width: 30%; background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  animation: sweep 1.2s linear infinite; }
@keyframes sweep { from { transform: translateX(-100%); } to { transform: translateX(400%); } }

/* Settings drawer */
.scrim { position: fixed; inset: 0; background: rgba(0, 0, 0, .55); z-index: 5; display: none; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(400px, 100%); z-index: 6; background: var(--panel-solid);
  border-left: 1px solid var(--line-hi); padding: 24px 20px; overflow-y: auto; transform: translateX(100%);
  transition: transform .25s ease; box-shadow: -20px 0 60px rgba(0, 0, 0, .5); }
.drawer.open { transform: none; } .drawer.open + .scrim { display: block; }
.drawer h2 { font: 700 14px var(--display); letter-spacing: .24em; margin: 0 0 20px; color: var(--cyan); }
.drawer h4 { font: 600 10px var(--display); letter-spacing: .2em; color: var(--muted); margin: 22px 0 10px; text-transform: uppercase; }
.set { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.set small { display: block; color: var(--dim); font-size: 12px; }
.switch { position: relative; width: 44px; height: 24px; flex: none; }
.switch input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 12px; background: #1a2539; border: 1px solid var(--line); transition: .2s; }
.switch span::after { content: ""; position: absolute; width: 18px; height: 18px; left: 2px; top: 2px; border-radius: 50%; background: var(--muted); transition: .2s; }
.switch input:checked + span { background: rgba(62, 230, 255, .25); border-color: var(--cyan); }
.switch input:checked + span::after { left: 22px; background: var(--cyan); box-shadow: 0 0 10px var(--cyan); }
.switch input:focus-visible + span { outline: 2px solid var(--cyan); outline-offset: 2px; }
.trusted { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 6px 0; font: 13px var(--mono); }
.trusted button { padding: 4px 8px; font-size: 10px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px); opacity: 0; z-index: 9;
  background: var(--panel-solid); border: 1px solid var(--line-hi); padding: 10px 18px; border-radius: 10px; transition: .25s;
  box-shadow: 0 0 30px rgba(62, 230, 255, .2); font-size: 14px; max-width: calc(100% - 32px); }
.toast.show { opacity: 1; transform: translateX(-50%); }

@media (max-width: 860px) {
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .detail { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .brand h1 { font-size: 20px; letter-spacing: .22em; }
  .row-head { grid-template-columns: 48px minmax(0, 1fr); }
  .meta { grid-column: 2; text-align: left; } .meta .icons { justify-content: flex-start; }
  .meta .verdict { display: inline; margin-right: 8px; }
  .who { flex-direction: column; gap: 0; }
  dl { grid-template-columns: 1fr; gap: 2px; } dd { margin-bottom: 8px; }
  .status { order: 3; width: 100%; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ===== Prism ===== */
[hidden] { display: none !important; }
.prism { width: 92px; height: 56px; flex: none; overflow: visible; }
.prism .beam { stroke-dasharray: 64; animation: beam 3.2s ease-in-out infinite; }
.prism .rays path { stroke-dasharray: 72; stroke-dashoffset: 72; animation: ray 3.2s ease-in-out infinite; }
.prism .rays path:nth-child(2) { animation-delay: .08s; } .prism .rays path:nth-child(3) { animation-delay: .16s; }
.prism .rays path:nth-child(4) { animation-delay: .24s; }
.prism .glass { animation: glass 3.2s ease-in-out infinite; }
.prism .glint { animation: glint 3.2s ease-in-out infinite; }
@keyframes beam { 0% { stroke-dashoffset: 64; opacity: .2; } 25%, 85% { stroke-dashoffset: 0; opacity: 1; } 100% { opacity: .6; } }
@keyframes ray { 0%, 22% { stroke-dashoffset: 72; } 45%, 88% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: 0; opacity: .55; } }
@keyframes glass { 0%, 100% { filter: drop-shadow(0 0 4px rgba(62,230,255,.4)); } 40% { filter: drop-shadow(0 0 14px rgba(155,123,255,.9)); } }
@keyframes glint { 0%, 30% { opacity: 0; } 42% { opacity: .9; } 60%, 100% { opacity: 0; } }
.wordmark { font: 900 28px/1 var(--display); letter-spacing: .42em; margin: 0;
  background: linear-gradient(90deg, #fff 0%, #ff3d6e 30%, #ffb22e 48%, #2ef5a3 66%, #3ee6ff 82%, #9b7bff 100%);
  background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: spectrum 8s linear infinite; filter: drop-shadow(0 0 10px rgba(62,230,255,.35)); }
@keyframes spectrum { to { background-position: 220% 0; } }
.tagline { margin: 7px 0 0; font: 500 12px var(--ui); letter-spacing: .08em; color: var(--muted); }
.by { margin: 6px 0 0; font: 600 10px var(--display); letter-spacing: .5em; color: var(--dim); }

/* Sign-in */
.auth-wrap { position: relative; z-index: 1; min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.auth-card { width: min(420px, 100%); background: var(--panel); border: 1px solid var(--line-hi); border-radius: 18px;
  padding: 30px 26px; backdrop-filter: blur(14px); box-shadow: 0 0 80px rgba(62,230,255,.12), inset 0 1px 0 rgba(255,255,255,.04); }
.brand-stack { text-align: center; margin-bottom: 24px; }
.brand-stack .prism { width: 160px; height: 96px; margin: 0 auto 8px; display: block; }
.brand-stack .wordmark { font-size: 36px; padding-left: .42em; }
.field { display: block; margin-bottom: 14px; }
.field > span { display: block; font: 600 10px var(--display); letter-spacing: .18em; color: var(--muted); margin-bottom: 6px; text-transform: uppercase; }
.field input, .field select, .field textarea { width: 100%; font: 500 15px var(--ui); color: var(--text); background: rgba(0,0,0,.3);
  border: 1px solid var(--line); border-radius: 10px; padding: 11px 12px; }
.field input:focus, .field select:focus { border-color: var(--cyan); outline: none; box-shadow: 0 0 0 3px rgba(62,230,255,.15); }
.field small { display: block; color: var(--dim); font-size: 12px; margin-top: 5px; }
.code-input { font: 700 26px var(--mono) !important; letter-spacing: .5em; text-align: center; }
.err { color: var(--danger); font-size: 13px; min-height: 1.2em; margin: 4px 0 10px; }
.wide-btn { width: 100%; padding: 13px; }
.qr { display: grid; place-items: center; padding: 14px; margin: 6px 0 12px; border: 1px solid var(--line); border-radius: 12px; background: rgba(0,0,0,.35); }
.qr img { width: 240px; height: 240px; image-rendering: pixelated; background: #fff; display: block; }
.secret { font: 600 13px var(--mono); letter-spacing: .12em; text-align: center; color: var(--cyan); overflow-wrap: anywhere; margin-bottom: 12px; }
.auth-card p { color: #c4d6ec; font-size: 14px; }

/* Shell */
#app main#view { position: relative; z-index: 1; max-width: 1240px; margin: 0 auto; padding: 4px 16px 64px; }
header.top { position: relative; z-index: 2; max-width: 1240px; margin: 0 auto; padding: 22px 16px 14px; display: flex; gap: 16px;
  align-items: center; flex-wrap: wrap; }
header.top .brand { display: flex; gap: 14px; align-items: center; }
.scope { display: flex; align-items: center; gap: 8px; }
.scope span { font: 600 10px var(--display); letter-spacing: .2em; color: var(--dim); }
.scope select { min-width: 220px; max-width: 320px; padding: 9px 12px; }
.user { display: flex; flex-direction: column; text-align: right; line-height: 1.2; }
.user b { font-size: 14px; } .user small { color: var(--muted); font: 600 10px var(--display); letter-spacing: .14em; text-transform: uppercase; }
.tabs { position: relative; z-index: 2; max-width: 1240px; margin: 0 auto 18px; padding: 0 16px; display: flex; gap: 6px;
  overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--line); }
.tabs button { border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: none; color: var(--muted);
  padding: 12px 14px; white-space: nowrap; }
.tabs button:hover { color: var(--text); box-shadow: none; background: rgba(62,230,255,.05); }
.tabs button.on { color: var(--cyan); border-bottom-color: var(--cyan); text-shadow: 0 0 12px rgba(62,230,255,.6); }
.tiles.five { grid-template-columns: repeat(5, 1fr); }
.sec { margin: 26px 0 12px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.sec h2 { margin: 0; font: 700 13px var(--display); letter-spacing: .24em; color: var(--cyan); text-transform: uppercase; }
.sec .spacer { flex: 1; }
.card { border: 1px solid var(--line); border-radius: 14px; background: var(--panel); backdrop-filter: blur(10px); padding: 16px; }
.card h3 { margin: 0 0 8px; font: 700 12px var(--display); letter-spacing: .18em; }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.data { width: 100%; border-collapse: collapse; table-layout: auto; }
.data th { padding: 12px 10px 8px; border-bottom: 1px solid var(--line-hi); white-space: nowrap; }
.data td { padding: 10px; border-top: 1px solid var(--line); vertical-align: middle; }
.data tr.click { cursor: pointer; } .data tr.click:hover td { background: rgba(62,230,255,.04); }
.data .num { font: 700 15px var(--display); font-variant-numeric: tabular-nums; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); backdrop-filter: blur(10px); }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--safe); box-shadow: 0 0 8px var(--safe); margin-right: 8px; vertical-align: 1px; }
.dot.error { background: var(--danger); box-shadow: 0 0 8px var(--danger); } .dot.scanning, .dot.pending { background: var(--cyan); box-shadow: 0 0 8px var(--cyan); }
.dot.off { background: var(--dim); box-shadow: none; }
.badge { display: inline-block; font: 700 9px var(--display); letter-spacing: .18em; padding: 3px 7px; border-radius: 6px;
  border: 1px solid var(--line-hi); color: var(--cyan); text-transform: uppercase; white-space: nowrap; }
.badge.partner { color: var(--violet); border-color: rgba(155,123,255,.5); } .badge.platform { color: #fff; border-color: rgba(255,255,255,.4); }
.badge.m365 { color: #7cc4ff; border-color: rgba(124,196,255,.5); } .badge.imap { color: var(--warn); border-color: rgba(255,178,46,.45); }
.mini { padding: 6px 10px; font-size: 10px; }
.btns { display: flex; gap: 8px; flex-wrap: wrap; }
.hint { color: var(--muted); font-size: 14px; }
.chk-list { max-height: 50vh; overflow-y: auto; border: 1px solid var(--line); border-radius: 10px; margin: 10px 0; }
.chk-list label { display: flex; gap: 10px; align-items: center; padding: 9px 12px; border-bottom: 1px solid var(--line); cursor: pointer; }
.chk-list label:hover { background: rgba(62,230,255,.05); }
.chk-list input { width: 18px; height: 18px; accent-color: var(--cyan); }
dialog { width: min(520px, calc(100% - 32px)); max-height: calc(100vh - 32px); overflow-y: auto; }
dialog h3 { color: var(--cyan); }
dialog.danger h3 { color: var(--warn); }
.copy { display: flex; gap: 8px; } .copy input { flex: 1; font: 12px var(--mono) !important; }
.steps { margin: 0; padding-left: 20px; color: #c4d6ec; font-size: 14px; } .steps li { margin-bottom: 6px; }
code { font: 12.5px var(--mono); color: var(--cyan); background: rgba(62,230,255,.07); padding: 1px 5px; border-radius: 4px; overflow-wrap: anywhere; }
@media (max-width: 960px) { .tiles.five { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px) {
  .tiles.five { grid-template-columns: repeat(2, 1fr); }
  .scope { order: 4; width: 100%; } .scope select { flex: 1; min-width: 0; max-width: none; }
  header.top .user { display: none; }
  .wordmark { font-size: 22px; } .prism { width: 70px; height: 42px; }
}
.badge.agent { color: var(--safe); border-color: rgba(46,245,163,.45); }
a.dl { display: inline-flex; align-items: center; font: 600 11px var(--display); letter-spacing: .12em; text-transform: uppercase; color: var(--violet); border: 1px dashed rgba(155,123,255,.5); border-radius: 8px; padding: 9px 12px; text-decoration: none; }
a.dl:hover { background: rgba(155,123,255,.1); }
ol.steps a.dl { padding: 2px 8px; font-size: 10px; }
h4.sub { font: 700 11px var(--display); letter-spacing: .18em; color: var(--cyan); margin: 18px 0 8px; text-transform: uppercase; }
.field label.check { display: flex; align-items: center; gap: 8px; margin: 6px 0; font-size: 14px; }
.field label.check input { width: auto; }
table.data tr.sub > td { background: rgba(0,0,0,.18); padding: 6px 12px 12px 28px; }
table.data tr.sub table.data { margin: 0; }

/* ---- phones: the emails right away (compact header and counters), touch-sized buttons, tight tables ---- */
@media (max-width: 560px) {
  header.top { padding: 12px 12px 8px; gap: 10px; }
  header.top .tagline { display: none; }
  .wordmark { font-size: 18px; } .prism { width: 52px; height: 32px; }
  .tabs { margin-bottom: 12px; padding: 0 8px; scrollbar-width: none; }
  .tabs::-webkit-scrollbar { display: none; }
  .tabs button { padding: 10px 10px; }
  .tiles, .tiles.five { grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
  .tile { padding: 9px 10px; border-radius: 10px; }
  .tile .k { font-size: 8.5px; letter-spacing: .14em; }
  .tile .v { font-size: 22px; }
  .tile .s { display: none; }
  table.data th, table.data td { padding: 7px 6px; font-size: 13px; }
  .sec { flex-wrap: wrap; gap: 6px 10px; }
  button.mini, a.dl { min-height: 34px; }
}
