.portal-shell #topNav .portal-recent-pages { position: relative; order: 3; flex: 0 0 auto; margin-left: auto; }
.portal-shell #topNav:has(.portal-approval-counters) .portal-recent-pages { margin-left: 0; }
.portal-shell.portal-product-header #topNav:has(.portal-recent-pages) .portal-skin-toggle { margin-left: 0; }
.portal-shell #topNav .portal-recent-toggle { display: flex; align-items: center; justify-content: center; width: 32px; height: 36px; padding: 0; border: 0; border-radius: 6px; background: transparent; color: #aaa; cursor: pointer; }
.portal-shell #topNav .portal-recent-toggle svg { width: 22px; height: 22px; }
.portal-shell #topNav .portal-recent-toggle:hover, .portal-shell #topNav .portal-recent-toggle[aria-expanded="true"] { color: #f07057; background: #ffffff0d; }
.portal-shell #topNav .portal-recent-toggle:focus-visible, .portal-shell :is(#topNav,.summarypage) .portal-recent-items a:focus-visible { outline: 2px solid #f07057; outline-offset: 2px; }
.portal-shell #topNav .portal-recent-list { --recent-bg:#222; --recent-text:#ddd; --recent-muted:#aaa; --recent-line:#555; --recent-active:#3c2a26; --recent-accent:#f07057; position: fixed; box-sizing: border-box; z-index: 1100; right: 16px; width: min(480px, calc(100vw - 32px)); max-height: min(520px, calc(100vh - 100px)); overflow-y: auto; padding: 10px 0; border: 1px solid #444; border-radius: 8px; background: var(--recent-bg); color: var(--recent-text); box-shadow: 0 8px 24px #0005; font: 14px/1.4 "Source Sans 3", sans-serif; }
.portal-shell #topNav .portal-recent-list[hidden] { display: none; }
.portal-shell #topNav .portal-recent-heading { padding: 8px 26px 18px; font-weight: 600; }
.portal-shell :is(#topNav,.summarypage) .portal-recent-items { position:relative; padding:0 16px 8px; }
.portal-shell :is(#topNav,.summarypage) .portal-recent-items:has(a ~ a)::before { content:""; position:absolute; left:35px; top:24px; bottom:32px; width:2px; background:var(--recent-line); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-items a { position:relative; display:grid; grid-template-columns:20px minmax(0,1fr) auto; align-items:center; gap:12px; font: 14px/1.4 "Source Sans 3", sans-serif !important; padding: 10px; border:0; border-radius:6px; color: inherit; text-decoration: none; overflow-wrap: anywhere; }
.portal-shell :is(#topNav,.summarypage) .portal-recent-items a:hover { background: #ffffff0d; color: var(--recent-accent); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-items a[aria-current="page"] { background:var(--recent-active); box-shadow:inset 3px 0 var(--recent-accent); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-copy { min-width:0; }
.portal-shell :is(#topNav,.summarypage) .portal-recent-current { color:var(--recent-accent); font:600 11px/1.4 "Source Sans 3",sans-serif; }
.portal-shell :is(#topNav,.summarypage) .portal-recent-icon { position:relative; display:block; width:20px; height:20px; box-sizing:border-box; border:1px solid var(--recent-line); border-radius:50%; background:var(--recent-bg); color:var(--recent-muted); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-icon::before { content:""; position:absolute; inset:4px; background:currentColor; -webkit-mask:var(--recent-icon) center / contain no-repeat; mask:var(--recent-icon) center / contain no-repeat; }
.portal-shell :is(#topNav,.summarypage) .portal-recent-items a[aria-current="page"] .portal-recent-icon { border-color:var(--recent-accent); color:var(--recent-accent); background:var(--recent-active); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-icon[data-icon="desktop"] { --recent-icon:url('/assets/img/icons/desktop.svg'); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-icon[data-icon="shield-check"] { --recent-icon:url('/assets/img/icons/shield-check.svg'); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-icon[data-icon="users"] { --recent-icon:url('/assets/img/icons/users.svg'); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-icon[data-icon="chart-simple"] { --recent-icon:url('/assets/img/icons/chart-simple.svg'); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-icon[data-icon="file-lines"] { --recent-icon:url('/assets/img/icons/file-lines.svg'); }
.portal-shell :is(#topNav,.summarypage) .portal-recent-items p { margin: 0; padding: 9px 20px; }
html[data-portal-skin="light"] .portal-shell #topNav .portal-recent-list { --recent-bg:#fff; --recent-text:#454b52; --recent-muted:#66717b; --recent-line:#c3cbd2; --recent-active:#fff0ea; --recent-accent:#f07057; border-color: #ddd; }
html[data-portal-skin="light"] .portal-shell :is(#topNav,.summarypage) .portal-recent-items a:hover { background: #f3f3f3; }
.portal-shell :is(#topNav,.summarypage) .portal-recent-time { display: block; margin-top: 3px; font: 12px/1.4 "Source Sans 3", sans-serif; opacity: .7; }

.portal-shell .summarypage .portal-summary-history { --recent-bg:var(--portal-surface); --recent-text:var(--portal-text); --recent-muted:var(--portal-muted); --recent-line:var(--portal-border); --recent-active:var(--portal-subtle); --recent-accent:var(--portal-action); color:var(--recent-text); }

/* Compact navigation trail in the menu; a plain, denser list inside the dashboard. */
.portal-shell #topNav .portal-recent-heading { padding-bottom:10px; }
.portal-shell #topNav .portal-recent-items a { padding-block:5px; }
.portal-workspace .summarypage .portal-summary-canvas > [data-summary-tile="shortcuts"] { padding-top:26px; }
.portal-shell :is(#topNav,.summarypage) .portal-summary-history.portal-recent-items { margin-top:8px; padding:0; }
.portal-shell :is(#topNav,.summarypage) .portal-summary-history.portal-recent-items::before { display:none; }
.portal-shell :is(#topNav,.summarypage) .portal-summary-history.portal-recent-items a { grid-template-columns:14px minmax(0,1fr) auto; gap:10px; padding:5px 10px; border-radius:3px; border-bottom:1px solid var(--recent-line); min-height:34px; box-shadow:none; }
.portal-shell :is(#topNav,.summarypage) .portal-summary-history .portal-recent-icon { width:14px; height:14px; border:0; border-radius:0; background:transparent; }
.portal-shell :is(#topNav,.summarypage) .portal-summary-history .portal-recent-icon::before { inset:0; }
.portal-shell :is(#topNav,.summarypage) .portal-summary-history .portal-recent-copy { display:block; }
.portal-shell :is(#topNav,.summarypage) .portal-summary-history .portal-recent-time { flex:none; margin:0; font-size:11px; }
.portal-shell :is(#topNav,.summarypage) .portal-summary-history .portal-recent-current { font-size:10px; }
@media(max-width:600px) { .portal-shell :is(#topNav,.summarypage) .portal-summary-history .portal-recent-copy { display:block; } }
