/* Product surfaces sized for a phone first; charts and evidence keep their own space. */
body { -webkit-font-smoothing: antialiased; }
button, a, summary { -webkit-tap-highlight-color: transparent; }
.home-greeting { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.home-greeting p { color: var(--muted); font-size: 13px; margin-bottom: 8px; }
.home-greeting h1 { font-size: 36px; letter-spacing: -.6px; }
.home-archive { width: 48px; height: 48px; border-radius: 16px; background: white; border: 1px solid var(--line); display: grid; place-items: center; color: #586672; }
.home-archive svg { width: 25px; height: 25px; }
.start-detection { display: flex; align-items: center; gap: 18px; padding: 28px; border-radius: 21px; background: #18583f; color: white; min-height: 126px; transition: background .15s, transform .15s; }
.start-detection:hover { background: #124c37; }
.start-detection:active { transform: scale(.99); }
.start-symbol { width: 58px; height: 58px; display: grid; place-items: center; background: #ffffff19; border: 1px solid #ffffff25; border-radius: 17px; }
.start-symbol svg { width: 29px; height: 29px; stroke-width: 1.6; }
.start-detection strong { font-size: 22px; display: block; font-weight: 600; letter-spacing: .2px; }
.start-detection small { display: block; color: #e5f1e7; font-size: 13px; margin-top: 5px; }
.start-arrow { margin-left: auto; display: grid; place-items: center; }
.home-sections { display: grid; grid-template-columns: 1.3fr 1fr; gap: 28px; margin-top: 30px; }
.mobile-home .section-head { margin-bottom: 12px; min-height: 36px; }
.mobile-home .section-head h2 { font-size: 19px; letter-spacing: 0; }
.mobile-home .text-link { min-height: 44px; }
.record-surface, .discovery-surface { border-radius: 18px; background: white; border: 1px solid #e8e9ed; overflow: hidden; }
.record-surface { padding: 0 20px; }
.record-surface .task-meta strong { font-size: 14px; }
.record-surface .task-row { min-height: 94px; padding: 19px 0; }
.record-surface .task-side { gap: 4px; }
.compact-empty { display: flex; gap: 14px; align-items: center; min-height: 106px; }
.compact-empty>svg { color: #8793a0; width: 24px; height: 24px; }
.compact-empty strong { font-size: 14px; font-weight: 500; }
.compact-empty p { color: var(--muted); font-size: 12px; margin-top: 5px; }
.home-count { color: var(--muted); font-size: 12px; margin-top: 12px; }
.demo-entry { border: 0; background: transparent; width: 100%; display: flex; align-items: center; gap: 13px; text-align: left; padding: 22px 20px; color: var(--text); }
.demo-entry>span:nth-child(2) { flex: 1; min-width: 0; }
.demo-entry>svg { width: 16px; color: #9b9fa6; }
.demo-entry strong { font-size: 15px; font-weight: 550; display: block; }
.demo-entry small { font-size: 12px; color: var(--muted); display: block; margin-top: 5px; }
.demo-symbol { display: grid; place-items: center; width: 42px; height: 44px; border-radius: 12px; color: #426c9b; background: #eff4fa; }
.demo-symbol svg { width: 25px; height: 25px; }
.demo-entry:active { background: #f5f7fa; }
.preparation { padding: 0; margin: 0 20px; border-top: 1px solid var(--line); }
.preparation summary { display: flex; align-items: center; justify-content: space-between; min-height: 56px; font-size: 13px; color: #606873; list-style: none; }
.preparation summary::after { content: '+'; color: #808994; font-size: 20px; font-weight: 300; }
.preparation[open] summary::after { content: '−'; }
.preparation .prep-row:last-child { margin-bottom: 12px; }

.result-page-header { max-width: 980px; margin: 0 auto 18px; }
.result-page-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.result-page-nav .back-link { min-height: 40px; margin: 0; font-size: 13px; }
.result-page-header h1 { font-size: 29px; letter-spacing: -.4px; line-height: 1.4; overflow-wrap: anywhere; }
.result-page-header>p { display: flex; gap: 9px; color: #777e88; font-size: 12px; margin-top: 6px; flex-wrap: wrap; }
.result-layout, .history-disclosure { max-width: 980px; margin-left: auto; margin-right: auto; }
.result-status { display: flex; gap: 14px; align-items: center; padding: 20px 22px; border-radius: 16px; background: #eaf0f6; margin-bottom: 20px; }
.status-symbol { display: grid; place-items: center; color: #426284; width: 40px; height: 40px; background: #fff9; border-radius: 12px; flex-shrink: 0; }
.status-symbol svg { width: 24px; height: 24px; }
.result-status.has-findings { background: #f4ede1; }
.has-findings .status-symbol { color: #946422; }
.status-kicker { font-size: 11px; color: #686f78; margin-bottom: 3px; }
.result-status h2 { font-size: 20px; letter-spacing: 0; font-weight: 600; }
.status-context { font-size: 12px; color: #77756f; margin-top: 5px; }
.result-info-button { display: grid; place-items: center; color: #666e78; min-width: 44px; min-height: 44px; border: 0; background: transparent; margin-left: auto; flex-shrink: 0; }
.result-workspace { display: grid; grid-template-columns: minmax(0, 1fr) 290px; gap: 22px; align-items: start; }
.result-analysis { padding: 20px; overflow: hidden; border-radius: 20px; }
.result-tabs { display: flex; background: #eef0f3; padding: 4px; border-radius: 11px; gap: 4px; }
.result-tabs button { display: flex; align-items: center; justify-content: center; gap: 7px; flex: 1; min-height: 40px; border: none; background: transparent; color: #6c7480; border-radius: 8px; font-size: 14px; font-weight: 500; }
.result-tabs button[aria-selected=true] { background: white; color: #1f2c3c; box-shadow: 0 1px 4px #14243913; }
.tab-dot, .flag-key, .channel i { width: 5px; height: 5px; border-radius: 50%; background: #ac782d; display: inline-block; flex-shrink: 0; }
.cell-picker { margin-top: 20px; }
.cell-picker-label { display: flex; justify-content: space-between; color: #727b86; font-size: 11px; margin-bottom: 9px; }
.cell-picker-label>span:last-child { display: flex; align-items: center; gap: 5px; }
.flag-key { margin-left: 5px; }
.result-analysis .channel-grid { display: flex; gap: 7px; overflow-x: auto; margin: 0 -4px 10px; padding: 4px 4px 8px; scrollbar-width: thin; scrollbar-color: #d7dee7 transparent; }
.result-analysis .channel { display: flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap; flex: 0 0 auto; border: 1px solid #e4e8ec; border-radius: 9px; background: #fafbfc; min-height: 40px; padding: 8px 13px; }
.result-analysis .channel>span { font-size: 12px; }
.result-analysis .channel.flagged:after { content: none; }
.result-analysis .channel.active { background: #eaf2eb; color: #18583f; border-color: #8eaf98; box-shadow: none; }
.reading-summary { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); padding: 18px 0 10px; border-top: 1px solid var(--line); margin-top: 12px; }
.reading-summary>div { padding: 0 10px; border-right: 1px solid var(--line); }
.reading-summary>div:first-child { padding-left: 0; }
.reading-summary>div:last-child { padding-right: 0; border-right: 0; }
.reading-summary>div>span { display: block; color: #727b86; font-size: 11px; }
.reading-summary strong { display: flex; align-items: baseline; gap: 4px; font-size: 22px; letter-spacing: -.4px; font-weight: 550; margin-top: 7px; font-variant-numeric: tabular-nums; }
.reading-summary small { color: #727b86; font-size: 10px; font-weight: 400; letter-spacing: 0; }
.reading-summary .not-measured { font-size: 15px; color: #8a9199; letter-spacing: 0; }
.reading-caption { font-size: 11px; color: #858b93; margin: 0 0 14px; }
.result-utilities { display: flex; justify-content: space-between; gap: 8px; border-top: 1px solid var(--line); padding-top: 8px; margin-top: 8px; }
.result-utilities .text-link { min-height: 44px; font-size: 12px; color: #526c8a; gap: 4px; }
.result-utilities svg { width: 14px; height: 14px; }
.next-panel { padding: 22px; }
.next-panel .section-head { margin-bottom: 8px; }
.next-panel h2 { font-size: 18px; letter-spacing: 0; }
.followup-item { padding: 0; margin: 0; border-top: 1px solid var(--line); }
.followup-item summary { min-height: 56px; padding: 16px 0; color: #485665; font-size: 13px; }
.followup-item p { margin: 0 0 18px; }
.next-panel .review-box { padding: 0; margin-top: 4px; }
.review-box>summary { display: flex; gap: 8px; align-items: center; padding-top: 16px; padding-bottom: 6px; min-height: 50px; list-style: none; }
.review-box>summary svg { width: 17px; height: 17px; }
.review-box>summary::after { content: '+'; font-size: 20px; font-weight: 300; margin-left: auto; }
.review-box[open]>summary::after { content: '−'; }
.channel-header { border: 0; padding: 10px 0 0; gap: 7px; }
.channel-header h3 { font-size: 17px; }
.channel-header h3 span { font-size: 12px; color: #7b838d; font-weight: 400; margin-left: 9px; }
.channel-header p { font-size: 11px; }
.channel-facts { gap: 20px; margin: 16px 0; }
.channel-facts div { font-size: 11px; }
.channel-facts strong { font-size: 13px; margin-top: 3px; }
.residual-disclosure { margin: 14px 0; padding-top: 12px; }
.residual-disclosure .chart-box { border: none; margin: 0; padding: 18px 0 8px; }
.evidence-group { margin: 22px 0 10px; }
.evidence-heading h3 { font-size: 12px; }
.evidence-heading>span { font-size: 10px; }
.evidence-row { gap: 5px 8px; }
.evidence-row h3 { font-size: 13px; }
.evidence-row p { font-size: 11px; }
.evidence-row .text-link { min-height: 44px; }
.no-fragments { background: #f5f7fa; color: #637080; border-radius: 10px; padding: 18px; font-size: 13px; margin: 18px 0; }
.no-fragments span { display: block; color: #8a929c; font-size: 11px; margin-top: 7px; }
.history-disclosure>summary { min-height: 44px; }

.result-sheet { padding: 0; width: min(560px,calc(100% - 40px)); max-height: 80dvh; border: 0; border-radius: 22px; overflow: auto; overscroll-behavior: contain; }
.sheet-handle { display: none; }
.sheet-heading { position: sticky; top: 0; background: #fffffff5; backdrop-filter: blur(16px); display: flex; justify-content: space-between; align-items: center; padding: 20px 24px; z-index: 1; border-bottom: 1px solid #e8ebef; }
.sheet-heading h2 { font-size: 19px; margin: 0; }
.sheet-heading .icon-button { width: 44px; height: 44px; }
.sheet-content { padding: 0 24px 28px; }
.sheet-content .notice { margin: 16px 0; }
.sheet-verdict { padding: 18px 0; }
.sheet-verdict h3 { font-size: 17px; }
.sheet-verdict p { font-size: 13px; margin: 8px 0 0; }
.sheet-content .finding p { margin: 8px 0 0 25px; }
body:has(.result-sheet[open]) { overflow: hidden; }

@media(max-width:800px) {
 .result-workspace { grid-template-columns: 1fr; gap: 16px; }
 .home-sections { grid-template-columns: minmax(0,1fr); gap: 22px; }
}
@media(max-width:650px) {
 .site-header { height: 56px; }
 .header-inner { padding: 0 20px; }
 .wordmark { font-size: 17px; letter-spacing: 0; }
 .wordmark svg { width: 24px; height: 24px; }
 .help-button { min-height: 44px; }
 .app-shell { padding: 0 18px; }
 main { padding-top: 22px; }
 .home-greeting { margin-bottom: 22px; }
 .home-greeting p { font-size: 12px; margin-bottom: 5px; }
 .home-greeting h1 { font-size: 29px; letter-spacing: 0; }
 .home-archive { width: 44px; height: 44px; border-radius: 14px; }
 .start-detection { padding: 22px 18px; min-height: 112px; gap: 14px; border-radius: 18px; }
 .start-symbol { width: 48px; height: 52px; border-radius: 14px; }
 .start-detection strong { font-size: 19px; }
 .start-detection small { font-size: 12px; margin-top: 5px; }
 .home-sections { margin-top: 23px; gap: 21px; }
 .mobile-home .section-head { margin-bottom: 8px; }
 .mobile-home .section-head h2 { font-size: 17px; }
 .record-surface, .discovery-surface { border-radius: 16px; }
 .record-surface { padding: 0 16px; }
 .record-surface .task-meta strong { font-size: 13px; }
 .record-surface .task-side .pill { font-size: 9px; }
 .record-surface .task-glyph { width: 30px; }
 .compact-empty { min-height: 97px; gap: 12px; }
 .compact-empty p { font-size: 11px; }
 .demo-entry { padding: 19px 16px; gap: 12px; }
 .demo-entry strong { font-size: 14px; }
 .demo-entry small { font-size: 11px; }
 .preparation { margin: 0 16px; }
 .preparation summary { min-height: 51px; font-size: 12px; }
 .app-footer { padding-bottom: 100px; margin-top: 26px; border-top: 0; color: #8b9199; }
 .bottom-nav { height: calc(70px + env(safe-area-inset-bottom)); border-top-color: #e5e8ed; box-shadow: 0 -4px 24px #27354b03; }
 .bottom-nav a { font-size: 10px; min-height: 52px; gap: 4px; }
 .bottom-nav a.active svg { stroke-width: 1.9; }
 .result-page-header { margin: -8px 2px 16px; }
 .result-page-nav { margin-bottom: 5px; }
 .result-page-nav .back-link { min-height: 40px; }
 .result-page-header h1 { font-size: 22px; letter-spacing: -.25px; }
 .result-page-header>p { font-size: 11px; margin-top: 5px; }
 .result-status { padding: 15px 12px; gap: 10px; margin-bottom: 16px; border-radius: 14px; }
 .status-symbol { width: 34px; height: 36px; border-radius: 10px; }
 .status-symbol svg { width: 21px; height: 21px; }
 .status-kicker { font-size: 10px; margin-bottom: 3px; }
 .result-status h2 { font-size: 17px; }
 .status-context { font-size: 10px; margin-top: 5px; }
 .result-info-button { min-width: 44px; min-height: 44px; }
 .result-info-button svg { width: 16px; height: 16px; }
 .result-analysis { padding: 14px; border-radius: 17px; }
 .result-tabs button { min-height: 40px; font-size: 13px; }
 .cell-picker { margin-top: 16px; }
 .cell-picker-label { font-size: 10px; margin-bottom: 7px; }
 .result-analysis .channel-grid { margin-bottom: 7px; scrollbar-width: none; }
 .result-analysis .channel { min-height: 44px; padding: 8px 12px; }
 .result-analysis .channel>span { font-size: 11px; }
 .reading-summary strong { font-size: 21px; }
 .reading-summary>div>span { font-size: 10px; }
 .reading-summary .not-measured { font-size: 14px; }
 .reading-caption { font-size: 10px; }
 .result-utilities .text-link { font-size: 11px; }
 .result-utilities svg { width: 13px; height: 13px; }
 .next-panel { padding: 18px; }
 .next-panel .section-head h2 { font-size: 17px; }
 .channel-header { padding-top: 8px; }
 .evidence-row p { font-size: 10px; }
 .evidence-heading h3 { font-size: 11px; }
 .evidence-heading>span { font-size: 9px; }
 .source-readout p { font-size: 11px; }
 .result-sheet { width: 100%; max-width: none; max-height: 88dvh; margin: auto 0 0; border-radius: 23px 23px 0 0; padding-bottom: env(safe-area-inset-bottom); }
 .sheet-handle { display: block; width: 34px; height: 4px; background: #d5d8dc; margin: 10px auto 0; border-radius: 9px; }
 .sheet-heading { padding: 11px 20px; }
 .sheet-heading h2 { font-size: 18px; }
 .sheet-content { padding: 0 20px 28px; }
}
@media(max-width:360px) {
 .app-shell { padding-left: 12px; padding-right: 12px; }
 .result-status { gap: 7px; }
 .result-status h2 { font-size: 15px; }
 .result-status .status-symbol { width: 29px; }
 .start-detection { padding: 20px 14px; gap: 11px; }
 .start-detection strong { font-size: 17px; }
 .start-detection small { font-size: 11px; }
 .result-analysis { padding: 12px; }
}
