/* Operator console frame (Andy, 25/10/2026): ComSec Cloud's workspace layout in Accountants.com.my colours.
   Left navigation (dark), top bar (breadcrumbs + tools), page body, status bar; right-edge Step-by-step guide tab. */
.opf-wrap{max-width:none!important;padding:0!important}
.opf-wrap>.site-header,.opf-wrap>footer{display:none}
.ops-frame{--opf-side:#162d43;--opf-side-2:#1f3a55;--opf-line:#dce3eb;--opf-bg:#f3f6fa;--opf-text:#162d43;--opf-muted:#607186;--opf-accent:#d8f377;--opf-blue:#244bda;
 display:grid!important;grid-template-columns:252px minmax(0,1fr)!important;min-height:100vh!important;background:var(--opf-bg);margin:0!important;max-width:none!important;width:100%}
.ops-frame .opf-side{background:var(--opf-side);color:#edf3f9;position:sticky;top:0;height:100vh;overflow:auto;display:flex;flex-direction:column;padding:0;border:0;min-width:0}
.opf-brand-row{display:flex;align-items:center;gap:8px;padding-right:12px;border-bottom:1px solid #ffffff1f}
.opf-brand{display:flex;align-items:center;gap:10px;padding:16px 14px 12px;color:#fff;text-decoration:none;min-width:0}
body:not(:has(.ops-frame)) :is(#cgTab,#cgPanel){display:none!important}
.opf-mark{width:34px;height:34px;border-radius:9px;background:#fff;color:var(--opf-side);font:italic 30px/.9 Georgia,serif;display:grid;place-items:center;padding:0 4px 3px 0;letter-spacing:-4px;flex:none}
.opf-mark span{color:#6c8a1c}
.opf-brand b{display:block;font-size:15px;letter-spacing:-.3px}.opf-brand small{display:block;font-size:11px;color:#b9c8d6;letter-spacing:.06em;text-transform:uppercase;margin-top:2px}
.opf-menu-btn{display:none}
.opf-quick{margin:8px 12px 0;padding:10px 12px;border-radius:8px;color:#fff;text-decoration:none;font-weight:600;font-size:14px;display:flex;align-items:center;justify-content:space-between;gap:8px;background:#ffffff12}
.opf-quick:hover{background:#ffffff1f}.opf-quick[aria-current=page]{background:#ffffff26;box-shadow:inset 3px 0 0 var(--opf-accent)}
.opf-badge{min-width:24px;padding:1px 8px;border-radius:999px;background:#ffdd00;color:#171717;font-size:12.5px;font-weight:700;text-align:center;line-height:20px}
.opf-badge.zero{background:#ffffff26;color:#d6e2ec}
.opf-nav{padding:6px 10px 18px;flex:1}
.opf-group{margin-top:8px}
.opf-group>button{width:100%;text-align:left;font:inherit;font-size:11px;font-weight:700;letter-spacing:.07em;text-transform:uppercase;padding:8px 10px 4px;border:0;background:none;cursor:pointer;color:#b9c8d6;display:flex;justify-content:space-between;align-items:center}
.opf-group>button::after{content:"\25BE";opacity:.7;font-size:12px}.opf-group.closed>button::after{content:"\25B8"}
.opf-group ul{list-style:none;margin:0;padding:0}.opf-group.closed ul{display:none}
.opf-group li a{display:flex;justify-content:space-between;align-items:center;gap:8px;padding:7px 10px;border-radius:7px;color:#edf3f9;text-decoration:none;font-size:14px;line-height:1.35}
.opf-group li a:hover{background:#ffffff16}
.opf-group li a[aria-current=page]{background:#fff;color:var(--opf-side);font-weight:650;box-shadow:inset 3px 0 0 var(--opf-accent)}
.opf-group li a .opf-n{font-size:12px;color:#b9c8d6;font-weight:600}.opf-group li a[aria-current=page] .opf-n{color:var(--opf-muted)}
.ops-frame .opf-right{display:flex;flex-direction:column;min-width:0;padding:0!important}
.opf-top{position:sticky;top:0;z-index:15;display:flex;flex-wrap:wrap;align-items:center;gap:8px 14px;background:#fff;border-bottom:1px solid var(--opf-line);padding:8px 22px;min-height:56px}
.opf-top .op-breadcrumbs{margin:0;font-size:13.5px;flex:1 1 260px}
.opf-tools{display:flex;align-items:center;gap:8px;margin-left:auto}
.opf-tools .btn{min-height:36px;padding:6px 14px;font-size:13.5px}
.opf-tools .avatar{width:34px;height:34px}
.opf-body{flex:1;padding:22px 28px 40px;min-width:0}
.opf-body>.panel,.opf-body>form>.panel{max-width:1200px}
/* Andy 25/10: the breadcrumb is the page title; page headings that repeat it are kept for screen readers only. */
.opf-sr{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
.ops-frame .work-lead{margin:0 0 14px}
.opf-status{position:sticky;bottom:0;z-index:14;display:flex;flex-wrap:wrap;gap:6px 18px;background:#f8fbfd;border-top:1px solid var(--opf-line);padding:6px 22px;font-size:12.5px;color:var(--opf-muted)}
.opf-status a{color:inherit;text-decoration:underline}
.ops-frame :is(a,button):focus-visible{outline:3px solid #7292ff;outline-offset:2px}.ops-frame .opf-side :is(a,button):focus-visible{outline-color:var(--opf-accent)}
/* The automation status dot (top right) keeps its place; the top bar leaves room for it. */
.opf-wrap:has(.auto-glance) .opf-top{padding-right:70px}
@media(min-width:901px){body.cg-open .opf-wrap .auto-glance{right:354px}}
/* The left menu already lists these views and the edge tab is the one guide; the page's own pills, tool links and
   embedded workflow guide would repeat them (Andy: no duplicated buttons). */
.ops-frame .work-filter-nav,.ops-frame .op-secondary-nav,.ops-frame nav.op-filter-nav[aria-label="Money views"],.ops-frame .workflow-guide{display:none!important}
.opf-brand{cursor:default}
.opf-legal{display:flex;flex-wrap:wrap;gap:4px 12px;margin:22px 10px 0;padding-top:12px;border-top:1px solid #ffffff1f;font-size:12px}
.opf-legal a{color:#b9c8d6;text-decoration:none}.opf-legal a:hover{color:#fff;text-decoration:underline}
/* A document open on the engagement page takes the right side; the guide folds away meanwhile. */
body.document-reading #cgTab,body.document-reading #cgPanel{display:none!important}
/* Step-by-step guide (engine ported from ComSec Cloud's operator-guide). */
#cgTab{position:fixed;right:0;top:38%;z-index:70;background:var(--opf-blue,#244bda);color:#fff;border:0;border-radius:6px 0 0 6px;padding:14px 8px;font:700 13px Arial,Helvetica,sans-serif;cursor:pointer;box-shadow:0 2px 8px rgba(0,0,0,.2)}
#cgTab span{display:block;writing-mode:vertical-rl;transform:rotate(180deg);white-space:nowrap}
body.cg-open #cgTab{right:340px}
#cgPanel{position:fixed;top:0;right:-360px;width:340px;height:100vh;z-index:70;background:#fff;border-left:1px solid #c9d3e0;box-shadow:-6px 0 18px rgba(0,0,0,.12);transition:right .2s ease,visibility 0s linear .2s;visibility:hidden;overflow:auto;font:13.5px/1.5 Arial,Helvetica,sans-serif;color:#162d43;padding:0 14px 24px;box-sizing:border-box}
body.cg-open #cgPanel{right:0;visibility:visible;transition:right .2s ease}
@media(min-width:901px){body.cg-open .opf-wrap{padding-right:340px!important}}
.cg-head{display:flex;justify-content:space-between;align-items:center;position:sticky;top:0;background:#fff;padding:12px 0 8px;border-bottom:1px solid #e4e9f0;margin-bottom:8px;z-index:1}
.cg-x{border:0;background:none;font-size:22px;cursor:pointer;line-height:1;color:#3a4654;min-width:36px;min-height:36px}
.cg-count{font-weight:600;margin:6px 0 4px}
.cg-bar{height:6px;background:#e4e9f0;border-radius:3px;overflow:hidden;margin-bottom:10px}.cg-bar span{display:block;height:100%;background:#244bda}
.cg-steps{list-style:none;padding:0;margin:0}.cg-steps li{display:flex;gap:8px;padding:7px 6px;border-radius:5px;margin-bottom:2px;border:1px solid transparent}
.cg-steps li.cur{background:#fff6d1;border-color:#f0c94b}.cg-steps li.done{color:#6b7a8a}.cg-steps li.done .cg-t{text-decoration:line-through}
.cg-steps li.todo{color:#3a4654}.cg-t em{color:#7a8794;font-style:normal}
.cg-n{flex:none;width:20px;height:20px;border-radius:50%;background:#e4e9f0;text-align:center;line-height:20px;font-size:11px;font-weight:700}
li.cur .cg-n{background:#ffdd00}li.done .cg-n{background:#244bda;color:#fff}
.cg-tip{margin-top:4px;color:#5b4a14;font-size:12.5px}
.cg-show,.cg-back,.cg-task{font:inherit;border:1px solid #9fb0c6;background:#f6f8fb;border-radius:5px;padding:4px 10px;cursor:pointer;color:#162d43}
.cg-show{margin-top:6px}.cg-back{margin:0 0 6px}
.cg-task{display:block;width:100%;text-align:left;margin:6px 0;padding:9px 10px}
.cg-intro,.cg-after,.cg-none,.cg-q{color:#3a4654;margin:6px 0}.cg-after{border-top:1px solid #e4e9f0;padding-top:8px}.cg-task-title{font-weight:700;margin:4px 0}
.cg-hl{outline:3px solid #f0a020!important;outline-offset:2px;box-shadow:0 0 0 6px rgba(240,160,32,.25)!important}
@media print{#cgTab,#cgPanel,.opf-side,.opf-top,.opf-status{display:none!important}}
@media(max-width:900px){
 .ops-frame{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:auto minmax(0,1fr)}
 .ops-frame .opf-side{position:sticky;top:0;z-index:20;height:auto;max-height:100vh;overflow:auto}
 .opf-brand{padding:10px 14px}.opf-brand-row{border-bottom:0}.opf-wrap:has(.auto-glance) .opf-brand-row{padding-right:62px}
 .opf-menu-btn{display:inline-flex;margin-left:auto;align-items:center;min-height:40px;padding:6px 14px;border-radius:7px;border:1px solid #ffffff40;background:transparent;color:#fff;font:inherit;font-weight:600;font-size:14px;cursor:pointer}
 .opf-side>.opf-nav{display:none}
 body.opf-menu-open .opf-side>.opf-nav{display:block}body.opf-menu-open .opf-side>.opf-quick{display:flex}
 .opf-top{position:static;padding:8px 16px}.opf-top .op-breadcrumbs{flex-basis:100%}.opf-tools{margin-left:0}
 .opf-body{padding:16px 16px 40px}
 .opf-status{display:none}
 #cgTab{top:auto;bottom:72px;padding:10px 6px;font-size:12px}body.opf-menu-open #cgTab{display:none}
 #cgPanel{width:100vw;right:-105vw}body.cg-open #cgPanel{right:0}body.cg-open #cgTab{display:none}body.cg-open .auto-glance{display:none}
}
/* The one primary action on Work: the first Needs-you row (Andy 25/10: Start-here card removed). */
.ops-frame .op-next-btn{background:#ffdd00;color:#171717!important;border:0;font-weight:800}.ops-frame .op-next-btn:hover{background:#f2cf00}
/* Without the Start-here card the Work page is one column: AI work queue, then the list. */
.ops-frame .work-layout{grid-template-columns:minmax(0,1fr)}.ops-frame .work-layout>*{grid-column:1/-1}
.ops-frame .work-top-side{grid-row:auto}.ops-frame .work-top-side .panel.aiq{margin:4px 0 16px}
/* One yellow primary action per page (audit 20): see onePrimary() in operator-frame.js. */
.ops-frame .opf-body .btn.primary.opf-main{background:#ffdd00;border-color:#ffdd00;color:#171717}
.ops-frame .opf-body .btn.primary.opf-demoted{background:#fff;border-color:#c7d3e2;color:var(--ink)}
/* Email delivery log on Work > System (audit 32). */
.op-mail-log td small{display:block;color:var(--muted);max-width:360px;overflow-wrap:anywhere}
.ops-frame [hidden]{display:none!important}
/* Pages that bring their own <main> (engagement, quotations, Genie) start at the top of the console body. */
.opf-body>.workspace-main,.opf-body>main{padding-top:0!important;margin-top:0!important}
/* Mail tab (Andy 25/10): hello@accountants.com.my in a right-edge drawer, as RCS's Mail tab. */
#mailTab{position:fixed;right:0;top:62%;z-index:70;background:#162d43;color:#fff;border:0;border-radius:6px 0 0 6px;padding:14px 8px;font:700 13px Arial,Helvetica,sans-serif;cursor:pointer;box-shadow:0 2px 8px rgba(0,0,0,.2);display:flex;flex-direction:column;align-items:center;gap:6px}
#mailTab>span{writing-mode:vertical-rl;transform:rotate(180deg)}
#mailTab .mail-count{background:#ffdd00;color:#171717;border-radius:999px;min-width:20px;padding:1px 5px;font-size:11.5px;line-height:18px;text-align:center}
#mailTab:hover{background:#0f2234}#mailTab:focus-visible{outline:3px solid #7292ff;outline-offset:2px}
body.cg-open #mailTab{right:340px}body.mail-open #mailTab,body.document-reading #mailTab,body.opf-menu-open #mailTab{display:none}
#mailDrawer{position:fixed;top:0;right:0;height:100vh;height:100dvh;width:min(480px,100vw);z-index:72;background:#fff;box-shadow:-8px 0 28px rgba(22,45,67,.25);display:flex;flex-direction:column;transform:translateX(105%);transition:transform .2s ease,visibility 0s linear .2s;visibility:hidden;font:14px/1.5 Arial,Helvetica,sans-serif;color:#162d43}
body.mail-open #mailDrawer{transform:none;visibility:visible;transition:transform .2s ease}
body.mail-open .auto-glance{display:none}
.mail-bar{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:6px 8px 6px 16px;background:#162d43;color:#fff}
.mail-bar strong{display:block;font-size:15px}.mail-bar small{display:block;color:#b9c8d6;font-size:12px}
.mail-bar button{min-width:44px;min-height:44px;border:0;border-radius:8px;background:transparent;color:#fff;font-size:24px;cursor:pointer}.mail-bar button:hover{background:#ffffff1f}
.mail-body{flex:1;overflow:auto;padding:12px 16px 24px}
.mail-list{list-style:none;margin:0;padding:0}
.mail-row{display:block;width:100%;text-align:left;font:inherit;background:#fff;border:0;border-bottom:1px solid #e4e9f0;padding:10px 6px;cursor:pointer;color:inherit}
.mail-row:hover{background:#f3f6fa}.mail-row strong,.mail-row span,.mail-row small{display:block}.mail-row span{color:#33475b}.mail-row small{color:#607186;font-size:12.5px}
.mail-row.is-open strong::before{content:"";display:inline-block;width:8px;height:8px;border-radius:50%;background:#ffdd00;margin-right:6px;vertical-align:middle}
.mail-back{font:inherit;border:0;background:none;color:#244bda;cursor:pointer;padding:4px 0;margin-bottom:6px}
.mail-body h2{font-size:18px;margin:2px 0}.mail-state,.mail-from,.mail-meta{color:#607186;font-size:12.5px;margin:2px 0}
.mail-msgitem{border:1px solid #e4e9f0;border-radius:8px;padding:10px 12px;margin:10px 0}.mail-msgitem.is-out{background:#f3f6fa}
.mail-text{white-space:pre-wrap;overflow-wrap:anywhere}
.mail-reply{display:block;margin-top:14px}.mail-reply span{display:block;font-weight:600;margin-bottom:4px}.mail-reply textarea{width:100%;box-sizing:border-box;font:inherit;border:1px solid #c7d3e2;border-radius:6px;padding:8px}
.mail-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:10px}.mail-actions .btn{min-height:40px;padding:8px 14px}
.mail-actions .btn.primary{background:#ffdd00;border-color:#ffdd00;color:#171717}
.mail-note,.mail-foot{color:#607186}.mail-foot{font-size:12.5px;margin-top:14px}.mail-msg{background:#fff6d1;border:1px solid #f0c94b;border-radius:6px;padding:6px 10px}
@media(max-width:900px){#mailTab{top:auto;bottom:230px;padding:10px 6px;font-size:12px}body.cg-open #mailTab{display:none}}
@media print{#mailTab,#mailDrawer{display:none!important}}
/* ComSec Cloud standard (Andy 26/10): Guide and Mail are top-bar buttons; the right-edge tabs are hidden. */
#cgTab,#mailTab{display:none!important}
.opf-tools .opf-tb-guide,.opf-tools .opf-tb-mail{font:inherit;font-size:13.5px;min-height:36px;padding:5px 12px;border:1px solid #9fb5c6;border-radius:7px;background:#fff;cursor:pointer;color:#162d43;font-weight:600}
.opf-tools .opf-tb-guide{background:#087f73;border-color:#087f73;color:#fff}.opf-tools .opf-tb-guide:hover{background:#066c62}
.opf-tools .opf-tb-mail{display:inline-flex;align-items:center;gap:6px;border-color:#c9d3e0}.opf-tools .opf-tb-mail:hover{background:#fdf3f2;border-color:#d0726b}
.opf-tb-mail svg{width:16px;height:16px;flex:none}
.opf-tb-mail .mail-count{background:#ffdd00;color:#171717;border-radius:999px;min-width:20px;padding:0 6px;font-size:11.5px;line-height:18px;text-align:center}
