/* IOVO Office — department rail, focus band, directory look and AQUIS dock.
   Colours come from the Office tokens in office-crm-c2.css (IOVO graphite + Orange 5). The one exception is the AQUIS
   identity below: four values sampled from app/assets/aquis/aquis-character-crystal.png, identical in both themes. */
.office-shell{display:grid;grid-template-columns:248px minmax(0,1fr);grid-template-rows:auto 1fr auto;min-height:100dvh}
.office-shell>.office-rail{grid-column:1;grid-row:1/4;position:sticky;inset-block-start:0;align-self:start;height:100dvh;display:flex;flex-direction:column;gap:18px;padding:22px 14px 16px;border-inline-end:1px solid var(--stroke);background:var(--bg-deep);overflow:auto;z-index:15}
.office-shell>.office-header{grid-column:2}.office-shell>.office-main{grid-column:2}.office-shell>.mobile-tabs{grid-column:2}
.office-header .office-departments,.office-header .department-switcher{display:none!important}
.rail-head{padding:0 8px}.rail-head small{display:block;color:var(--dim);font:600 10.5px var(--mono);letter-spacing:.16em;text-transform:uppercase}
.rail-head strong{display:block;margin-block-start:8px;font:400 24px/1.15 var(--serif);letter-spacing:.005em;overflow-wrap:anywhere}
.rail-nav{display:flex;flex-direction:column;gap:2px}
.rail-link{position:relative;display:flex;align-items:center;gap:12px;min-height:44px;padding:0 12px;border-radius:10px;color:var(--muted);text-decoration:none;font-size:14.5px}
.rail-link svg{width:18px;height:18px;flex:0 0 auto}
.rail-link:hover{background:var(--surface-soft);color:var(--text)}
.rail-link[aria-current=page]{background:rgba(244,121,32,.14);color:var(--text);box-shadow:inset 0 0 0 1px rgba(244,121,32,.35)}
.rail-link[aria-current=page]::before{content:"";position:absolute;inset-block:8px;inset-inline-start:-14px;width:3px;border-radius:0 3px 3px 0;background:var(--accent)}
.rail-link[aria-current=page] svg{color:var(--accent)}
.rail-sub{margin-inline-start:22px;min-height:38px;font-size:13.5px}
.rail-user{display:flex;align-items:center;gap:10px;margin-block-start:auto;padding:10px;border:1px solid var(--stroke);border-radius:12px;background:var(--surface-soft)}
.rail-user b{display:block;font-size:13.5px;overflow-wrap:anywhere}.rail-user small{display:block;color:var(--muted);font-size:11.5px}
.rail-avatar{display:grid;place-items:center;flex:0 0 auto;width:34px;height:34px;border-radius:50%;background:var(--teal-dark);color:var(--accent);font:600 12px var(--mono)}

/* One slim command bar over the content column */
.office-header{padding-inline:26px}
@media(min-width:1181px){.office-header .office-brand{display:none}}
.office-header .office-global-search{flex:1 1 360px;max-width:560px}
.office-header-actions{margin-inline-start:auto}


/* ---------- One theme across every Office screen ---------- */
.serif-title,.page-heading h1,.search-hero h1,.rail-head strong,.focus-band h2,.state-panel h2,.detail-title h2{font-family:var(--serif)}
:root{--serif:'Iowan Old Style','Palatino Linotype',Palatino,Georgia,'DejaVu Serif',serif}
.page-heading h1,.search-hero h1{font-weight:400;letter-spacing:.005em;line-height:1.08}
.eyebrow{display:flex;align-items:center;gap:8px;margin:0 0 10px;color:var(--dim);font:600 10.5px var(--mono);letter-spacing:.16em;text-transform:uppercase}
.eyebrow svg{width:14px;height:14px;color:var(--accent)}
.glass{background:var(--surface);backdrop-filter:none;border-color:var(--stroke)}
.button{border-radius:999px;background:var(--surface-soft)}
.button.primary,.btn-accent{background:var(--accent);color:var(--on-accent);border:1px solid var(--accent-deep);box-shadow:0 6px 22px rgba(244,121,32,.22);font-weight:600}
.button.primary svg{width:16px;height:16px}
.chip.active{color:var(--text);border-color:var(--accent);background:rgba(244,121,32,.14)}
.chip b{margin-inline-start:6px;color:var(--accent);font:600 11px var(--mono)}
.tabs .tab.active{color:var(--text);border-color:var(--accent)}
.avatar{background:var(--teal-dark);color:var(--accent);border-color:rgba(244,121,32,.3)}
.status{border-radius:999px}
.section-head h2{font-family:var(--serif);font-weight:400}
.office-main{max-width:1500px}
.page-heading{align-items:flex-end}
.page-heading p{color:var(--muted)}
.data-table thead th{color:var(--dim);font:600 10.5px var(--mono);letter-spacing:.12em;text-transform:uppercase}
.queue-item:hover,.list-row:hover{background:rgba(244,121,32,.06)}
.queue-item.selected,.queue-item[aria-current=true],.data-table tr.selected{background:rgba(244,121,32,.1)}
.metric-value,.pulse-item b{font-family:var(--mono)}
.state-panel svg{color:var(--accent)}
.boundary-note svg{color:var(--yellow)}

/* ---------- Clientes directory (O1) ---------- */
.dir-heading{gap:18px;flex-wrap:wrap}
.dir-heading h1{font-size:clamp(38px,4vw,52px)}
.dir-heading p#dir-count{margin-block-start:6px}
.dir-tools{display:flex;align-items:center;gap:10px;flex:1 1 420px;justify-content:flex-end}
.dir-search{flex:1 1 320px;max-width:560px}
.dir-search input{height:46px;border-radius:14px}
.dir-tools .button{width:auto;white-space:nowrap}
.dir-bar{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;padding:12px 16px;border-block-end:1px solid var(--stroke)}
.dir-sort{display:flex;align-items:center;gap:8px;color:var(--muted);font-size:12.5px}.dir-sort select{min-height:36px;width:auto}
.customers-layout{display:block;min-height:0}
.customers-layout .customer-list{overflow:visible}
.customers-layout.detail-open .customer-list{display:none}
.customers-layout:not(.detail-open) .customer-detail{display:none}
.customers-layout.detail-open .customer-detail{display:block;max-width:none}
.data-table.directory td{padding-block:10px;vertical-align:middle}
.data-table.directory tbody tr[data-id]{cursor:pointer;border-inline-start:3px solid transparent}
.data-table.directory tbody tr[data-id]>td:first-child{box-shadow:inset 3px 0 0 var(--tone,var(--stroke))}
.data-table.directory tr[data-tone=ok]{--tone:var(--green)}.data-table.directory tr[data-tone=bad]{--tone:var(--red)}.data-table.directory tr[data-tone=warn]{--tone:var(--yellow)}.data-table.directory tr[data-tone=neutral]{--tone:var(--accent)}
.data-table.directory tbody tr[data-id]:hover,.data-table.directory tr.is-open{background:rgba(244,121,32,.08)}
.customer-cell small{display:block;color:var(--dim);font:11px var(--mono)}
.seller{display:inline-flex;align-items:center;gap:8px;white-space:nowrap}
.avatar.mini{width:26px;height:26px;border-radius:50%;font-size:10px}
.dir-end{width:52px;text-align:end}
.dir-expand{display:inline-grid;place-items:center;width:36px;height:36px;border:1px solid var(--stroke);border-radius:50%;background:transparent;color:var(--muted);cursor:pointer}
.dir-expand svg{width:16px;height:16px;transition:transform .15s}.dir-expand[aria-expanded=true]{color:var(--accent);border-color:var(--accent)}.dir-expand[aria-expanded=true] svg{transform:rotate(180deg)}
.dir-foot{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;padding:12px 18px;border-block-start:1px solid var(--stroke);color:var(--muted);font-size:12.5px}
.pager{display:flex;gap:6px}.page-btn{min-width:36px;min-height:36px;border:1px solid var(--stroke);border-radius:8px;background:transparent;color:var(--text);cursor:pointer}.page-btn[aria-current=page]{border-color:var(--accent);background:rgba(244,121,32,.14)}
.peek-row>td{padding:0!important;background:var(--bg-deep)}
.peek{padding:16px 18px}
.peek-grid{display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,1fr) minmax(0,1fr);gap:18px}
.peek-col{min-width:0;display:flex;flex-direction:column;gap:10px}
.peek-col h3{display:flex;align-items:center;gap:8px;margin:0;color:var(--dim);font:600 10.5px var(--mono);letter-spacing:.14em;text-transform:uppercase}.peek-col h3 svg{width:15px;height:15px}
.peek-col .muted.small{font-size:12px;line-height:1.5}
.peek-actions{display:flex;gap:8px;flex-wrap:wrap;margin-block-start:auto}
.peek-actions .button{width:auto}
.kv-list .masked{color:var(--muted);font-family:var(--mono)}.kv-list .masked em{margin-inline-start:8px;color:var(--dim);font:11px var(--sans)}
.aquis-col{padding-inline-start:18px;border-inline-start:2px solid var(--accent)}
.aquis-col .button{align-self:flex-start;width:auto}
.detail-head [data-detail-back]{display:inline-grid}
.customer-detail{overflow:hidden}

/* ---------- Focus for today (V1) + department strip (O1) ---------- */
.stat-host:empty{display:none}
.focus-band{margin-block-end:14px;padding:0;overflow:hidden;border-radius:var(--radius);display:grid;grid-template-columns:minmax(220px,.7fr) minmax(0,3fr)}
.focus-band>header{padding:16px 18px;border-inline-end:1px solid var(--stroke);background:var(--surface-soft)}
.focus-band h2{margin:0;font:400 24px var(--serif)}.focus-band>header p:not(.eyebrow){margin:6px 0 0;color:var(--muted);font-size:12.5px;line-height:1.45}
.focus-body{min-width:0;padding:12px 14px}
.focus-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:10px;margin:0;padding:0;list-style:none}
.focus-card{position:relative;min-width:0;border:1px solid var(--stroke);border-radius:12px;background:var(--surface-soft);border-block-start:2px solid var(--tone,var(--stroke))}
.focus-card[data-tone=bad]{--tone:var(--red)}.focus-card[data-tone=warn]{--tone:var(--yellow)}.focus-card[data-tone=info]{--tone:var(--accent)}
.focus-card.none{border-block-start-color:var(--stroke)}.focus-card.none .focus-count,.focus-card.none .focus-n{color:var(--dim)}
.focus-card a,.focus-card.nc{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:10px;padding:12px;color:var(--text);text-decoration:none;height:100%}
.focus-card.nc{opacity:.75;border-style:dashed}
.focus-card a:hover{background:rgba(244,121,32,.08)}
.focus-n{display:grid;place-items:center;width:26px;height:26px;border-radius:50%;background:var(--teal-dark);color:var(--accent);font:600 12px var(--mono)}
.focus-t{display:grid;gap:3px;min-width:0}.focus-t b{font-size:13.5px;line-height:1.25}.focus-t small{color:var(--muted);font-size:12px;line-height:1.35;overflow-wrap:anywhere}.focus-names{color:var(--dim)!important}
.focus-count{font:500 24px var(--mono);align-self:start}
.focus-note{display:flex;align-items:center;gap:8px;margin:0;color:var(--muted);font-size:13.5px}.focus-note svg{width:16px;height:16px;color:var(--yellow)}
.focus-foot{margin:10px 0 0;color:var(--dim);font-size:11.5px;line-height:1.5}
.stat-strip{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));margin:0 0 16px;padding:0;list-style:none;border:1px solid var(--stroke);border-radius:var(--radius);background:var(--surface);overflow:hidden}
.stat-card+.stat-card{border-inline-start:1px solid var(--stroke)}
.stat-card a{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:start;gap:10px;height:100%;padding:14px;color:var(--text);text-decoration:none}
.stat-card a:hover{background:rgba(244,121,32,.07)}
.stat-ic{display:grid;place-items:center;width:34px;height:34px;border:1px solid rgba(244,121,32,.35);border-radius:10px;background:var(--teal-dark);color:var(--accent)}.stat-ic svg{width:17px;height:17px}
.stat-t{display:grid;gap:6px;min-width:0}.stat-t b{font-size:13.5px;font-weight:500}.stat-t small{color:var(--muted);font-size:11.5px;line-height:1.35}
.stat-bar{display:flex;gap:3px;height:4px;border-radius:3px;background:var(--surface-soft);overflow:hidden}.stat-bar i{display:block;border-radius:3px;background:var(--accent)}
.stat-bar i[data-tone=ok]{background:var(--green)}.stat-bar i[data-tone=warn]{background:var(--yellow)}.stat-bar i[data-tone=bad]{background:var(--red)}.stat-bar i[data-tone=info]{background:var(--blue)}
.stat-v{font:500 26px var(--mono)}
.stat-card.nc .stat-v,.stat-card.nc .stat-ic{opacity:.55}

/* ---------- AQUIS dock (V3) ---------- */
.aquis-dock{position:fixed;inset-block-end:20px;inset-inline-end:20px;z-index:60;display:flex;flex-direction:column;align-items:flex-end;gap:12px;pointer-events:none}
.aquis-dock>*{pointer-events:auto}
.aquis-fab{display:grid;place-items:center;width:58px;height:58px;border:0;border-radius:50%;background:radial-gradient(circle at 35% 30%,#ffb778,var(--accent) 55%,var(--accent-deep));color:#fff;cursor:pointer;box-shadow:0 10px 30px rgba(244,121,32,.4)}
.aquis-fab svg{width:27px;height:27px}.aquis-fab.is-open{box-shadow:0 0 0 3px var(--bg),0 0 0 5px var(--accent)}
.dock-buttons{position:relative;display:flex;align-items:center;gap:8px}
.fab-up{display:grid;place-items:center;width:36px;height:36px;border:1px solid var(--stroke-hi);border-radius:50%;background:var(--bg);color:var(--accent);cursor:pointer;box-shadow:var(--shadow)}.fab-up svg{width:18px;height:18px}
.aquis-sheet{order:-1;display:flex;flex-direction:column;width:min(420px,calc(100vw - 28px));max-height:min(660px,calc(100dvh - 120px));border:1px solid var(--stroke-hi);border-radius:18px;background:var(--bg);color:var(--text);box-shadow:var(--shadow);overflow:hidden}
.aquis-sheet[hidden]{display:none}
.aquis-sheet.expanded{width:min(980px,calc(100vw - 28px));height:min(700px,calc(100dvh - 120px))}
.sheet-head{display:flex;align-items:center;gap:10px;padding:12px 14px;border-block-end:1px solid var(--stroke)}
.sheet-head>div{flex:1;min-width:0}.sheet-head strong{display:block;font:600 14px var(--sans);letter-spacing:.18em}
.sheet-head small{display:block;color:var(--muted);font-size:12px}
.sheet-head .drop{display:grid;place-items:center;width:34px;height:34px;border-radius:50%;background:var(--teal-dark);color:var(--accent)}.sheet-head .drop svg{width:18px;height:18px}
.aquis-sheet .icon-btn{display:grid;place-items:center;flex:0 0 auto;width:40px;height:40px;border:1px solid var(--stroke);border-radius:50%;background:var(--surface-soft);color:var(--text);cursor:pointer}
.aquis-sheet .icon-btn svg{width:18px;height:18px}.aquis-sheet .icon-btn[aria-pressed=true]{background:var(--accent);color:var(--on-accent)}.aquis-sheet .icon-btn:disabled{opacity:.45;cursor:not-allowed}
.aquis-sheet .icon-btn.mic{border-color:var(--accent);color:var(--accent)}
.sheet-banner{display:flex;flex-direction:column;gap:3px;margin:10px 14px 0;padding:9px 12px;border:1px solid var(--stroke);border-radius:10px;background:var(--surface-soft);font-size:12px;line-height:1.45;color:var(--muted)}
.sheet-banner[data-kind=warn]{border-color:rgba(239,196,79,.4);background:rgba(239,196,79,.08);color:var(--text)}.sheet-banner[data-kind=warn] b{color:var(--yellow)}
.sheet-banner[data-kind=ok]{border-color:rgba(99,237,184,.3)}
.mode-row{display:flex;gap:6px;flex-wrap:wrap;padding:10px 14px 0}
.mode-pill{min-height:36px;padding:0 14px;border:1px solid var(--stroke);border-radius:999px;background:transparent;color:var(--muted);font-size:13px;cursor:pointer}
.mode-pill[aria-checked=true]{border-color:var(--accent);background:rgba(244,121,32,.14);color:var(--text)}
.mode-note{margin:6px 14px 0;color:var(--dim);font-size:11.5px}
.sheet-body{display:flex;flex:1;min-height:0;padding:10px 14px 14px;gap:14px}
.conv-col{display:none;flex-direction:column;gap:8px;width:250px;flex:0 0 auto;min-height:0}
.expanded .conv-col{display:flex}
.conv-head{display:flex;align-items:center;justify-content:space-between;color:var(--dim);font:600 10.5px var(--mono);letter-spacing:.12em;text-transform:uppercase}
.btn-link{display:inline-flex;align-items:center;gap:4px;min-height:32px;padding:0 6px;border:0;background:transparent;color:var(--accent);font:600 12.5px var(--sans);cursor:pointer;text-align:start}.btn-link svg{width:14px;height:14px}
.conv-search input{width:100%;height:38px;padding:0 12px;border:1px solid var(--stroke);border-radius:10px;background:var(--surface-soft);color:var(--text)}
.conv-col ul{margin:0;padding:0;list-style:none;overflow:auto;display:grid;gap:6px;align-content:start}
.conv-item{width:100%;text-align:start;padding:9px 10px;border:1px solid var(--stroke);border-radius:10px;background:var(--surface-soft);color:var(--text);cursor:pointer}
.conv-item[aria-current=true]{border-color:var(--accent);background:rgba(244,121,32,.1)}
.conv-item b,.conv-item small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.conv-item b{font-size:13px;font-weight:500}.conv-item small{color:var(--muted);font-size:11.5px}
.conv-empty{color:var(--dim);font-size:12px;line-height:1.5}
.btn-ghost{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:40px;padding:0 14px;border:1px solid var(--stroke);border-radius:10px;background:transparent;color:var(--text);font-size:13px;cursor:pointer}
.btn-accent{min-height:40px;padding:0 16px;border-radius:10px;cursor:pointer}.btn-accent:disabled{opacity:.55;cursor:default;box-shadow:none}
.thread-col{display:flex;flex-direction:column;gap:10px;flex:1;min-width:0;min-height:0}
.ctx{display:flex;align-items:center;flex-wrap:wrap;gap:4px 8px;padding:7px 10px;border:1px dashed var(--stroke-hi);border-radius:10px}.ctx svg{width:15px;height:15px;color:var(--accent)}.ctx small{color:var(--dim)}.ctx b{font-size:13px;overflow-wrap:anywhere}
.thread{flex:1;min-height:140px;overflow:auto;display:flex;flex-direction:column;gap:10px;padding:2px}
.thread-empty{margin:auto;color:var(--dim);font-size:13px;text-align:center}
.msg{max-width:94%;padding:9px 12px;border:1px solid var(--stroke);border-radius:12px;background:var(--surface-soft)}
.msg.you{align-self:flex-end;background:rgba(244,121,32,.12);border-color:rgba(244,121,32,.35)}.msg.err{border-color:rgba(255,111,116,.4)}
.msg>small{display:block;color:var(--dim);font:600 10px var(--mono);letter-spacing:.1em;text-transform:uppercase}.msg p{margin:4px 0 0;font-size:13.5px;line-height:1.5;overflow-wrap:anywhere;white-space:pre-wrap}
.draft{display:grid;gap:8px;margin-block-start:8px;padding:10px;border:1px dashed var(--stroke-hi);border-radius:10px}
.draft textarea{width:100%;padding:8px;border:1px solid var(--stroke);border-radius:8px;background:var(--bg-deep);color:var(--text);font:inherit}
.draft-actions{display:flex;gap:8px;flex-wrap:wrap}.draft-actions .btn-accent,.draft-actions .btn-ghost{min-height:38px}
.script-chips{display:flex;gap:6px;flex-wrap:wrap}
.chip.script{min-height:36px;padding:0 12px;border:1px solid var(--accent);color:var(--accent);background:transparent;font-size:12.5px;text-align:start;white-space:normal}
.chip.script:hover{background:rgba(244,121,32,.1)}.chip.script:disabled{opacity:.5;cursor:default}
.composer{display:flex;align-items:center;gap:8px}
.composer input{flex:1;min-width:0;height:44px;padding:0 14px;border:1px solid var(--stroke);border-radius:12px;background:var(--surface-soft);color:var(--text)}.composer input:disabled{opacity:.55}
.aquis-dock button:focus-visible,.aquis-dock input:focus-visible,.aquis-dock textarea:focus-visible,.rail-link:focus-visible,.focus-card a:focus-visible,.stat-card a:focus-visible,.dir-expand:focus-visible,.page-btn:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.office-main:has(.customers-layout.detail-open) .focus-band,.office-main:has(.customers-layout.detail-open) .stat-host,.office-main:has(.customers-layout.detail-open) .dir-heading .dir-tools{display:none}

@media(max-width:1180px){
  .office-shell{grid-template-columns:76px minmax(0,1fr)}
  .rail-head,.rail-link span,.rail-user>span:last-child{display:none}.rail-link{justify-content:center;padding:0}.rail-sub{margin-inline-start:0}.rail-user{justify-content:center;padding:6px}.office-shell>.office-rail{padding-inline:10px}.rail-link[aria-current=page]::before{inset-inline-start:-10px}
  .stat-strip{grid-template-columns:repeat(3,minmax(0,1fr))}.stat-card:nth-child(n+4){border-block-start:1px solid var(--stroke)}.stat-card:nth-child(4){border-inline-start:0}
  .focus-band{grid-template-columns:1fr}.focus-band>header{border-inline-end:0;border-block-end:1px solid var(--stroke)}
  .peek-grid{grid-template-columns:1fr 1fr}.peek-grid .aquis-col{grid-column:1/-1}
}
@media(max-width:820px){
  .office-shell{display:flex;flex-direction:column}.office-shell>.office-rail{display:none}
  .aquis-dock{inset-block-end:84px;inset-inline-end:12px}
  .aquis-sheet,.aquis-sheet.expanded{width:calc(100vw - 24px);height:auto;max-height:calc(100dvh - 170px)}
  .aquis-sheet.expanded .conv-col{display:none}
  .stat-strip{grid-template-columns:repeat(2,minmax(0,1fr))}.stat-card:nth-child(n){border-inline-start:0;border-block-start:1px solid var(--stroke)}.stat-card:nth-child(2n){border-inline-start:1px solid var(--stroke)}.stat-card:nth-child(-n+2){border-block-start:0}
  .focus-cards{grid-template-columns:1fr}
  .dir-tools{flex-basis:100%;justify-content:stretch}.dir-search{max-width:none}
  .peek-grid{grid-template-columns:1fr}.aquis-col{padding-inline-start:12px}
  .script-chips{flex-wrap:nowrap;overflow-x:auto;padding-block-end:4px}.chip.script{flex:0 0 auto;white-space:nowrap}
  .data-table.directory .hide-mobile{display:none}
  .page-heading{align-items:flex-start}
}
@media(max-width:480px){.stat-strip{grid-template-columns:1fr}.stat-card:nth-child(n){border-inline-start:0;border-block-start:1px solid var(--stroke)}.stat-card:first-child{border-block-start:0}}
@media(prefers-reduced-motion:no-preference){.aquis-fab{transition:transform .15s}.aquis-fab:hover{transform:scale(1.05)}}

.office-main{padding-block-end:96px}
.stat-card:last-child:nth-child(odd){grid-column:1/-1}
@media(min-width:1181px){.stat-card:last-child:nth-child(odd){grid-column:auto}}
.data-table .status{white-space:normal}
.queue-item{column-gap:10px}

/* ---------- Day theme: tokens already warm-white; replace the few hardcoded dark surfaces ---------- */
html[data-office-theme=day] .office-header{background:rgba(246,241,232,.94);border-block-end-color:var(--stroke)}
html[data-office-theme=day] .office-departments,html[data-office-theme=day] #office-settings{background:var(--surface-strong);color:var(--text)}
html[data-office-theme=day] .warning-box{color:#6b4d00;background:rgba(239,196,79,.16);border-color:rgba(125,91,0,.35)}
html[data-office-theme=day] .sample-tag,html[data-office-theme=day] .sample-badge{color:#6b4d00;background:rgba(239,196,79,.2);border-color:rgba(125,91,0,.4)}
html[data-office-theme=day] .mobile-tabs{background:var(--surface-strong)}
html[data-office-theme=day] .office-search-results{background:var(--surface-strong)}
html[data-office-theme=day] .rail-link[aria-current=page]{background:rgba(216,101,18,.12)}
html[data-office-theme=day] .aquis-sheet,html[data-office-theme=day] .fab-up{background:var(--surface-strong)}
html[data-office-theme=day] .peek-row>td{background:var(--bg-deep)}
html[data-office-theme=day] .time-block{color:var(--text)}
.detail-head [data-detail-back] svg{transform:scaleX(-1)}
.data-table th,.data-table thead th{background:var(--bg-deep)}
.hero-search input{background:var(--surface-strong);color:var(--text);border-color:var(--stroke)}
.hero-search input:focus{border-color:var(--accent)}
html[data-office-theme=day] .input,html[data-office-theme=day] .select{background:var(--surface-strong);color:var(--text)}
.dir-bar .chips{flex-wrap:wrap;overflow:visible}
@media(max-width:820px){.import-progress{display:grid;grid-template-columns:1fr 1fr;overflow:visible;gap:10px}}
@media(min-width:1181px){
  .verification-layout{grid-template-columns:minmax(0,1.7fr) minmax(0,.9fr) minmax(290px,.9fr)}
  .money-layout{grid-template-columns:minmax(270px,.68fr) minmax(0,1.6fr) minmax(250px,.66fr)}
}
.money-layout .data-table .status{white-space:nowrap}
.verification-layout .data-table td,.verification-layout .data-table th{white-space:normal}
.verification-layout .data-table .status{white-space:normal;margin:0}
.verification-layout .section-head{flex-wrap:wrap;gap:6px 10px}.verification-layout .sample-tag{white-space:normal}


/* =====================================================================================
   Premium pass (2026-10-19). Calmer, flatter, hairline-divided. Orange stays for the primary
   action, the selection marker and the focus ring; red/yellow only where a state is real.
   ===================================================================================== */
:root{--aquis-blue:#39b7f5;--aquis-blue-hi:#83dffb;--aquis-ink:#000517;--aquis-eye:#e7f5f9}

/* Office Night only: black/graphite surfaces and the existing IOVO orange.
   Day tokens and AQUIS's blue identity remain their approved values. */
html[data-office-theme=night]{--bg:#18191b;--bg-deep:#111214;--surface:#202124;--surface-strong:#292a2e;--surface-soft:#252629;--text:#f6f1e8;--muted:#b3aca0;--dim:#a39d93;--accent:#f47920;--teal:#f47920;--on-accent:#18191b}
html[data-office-theme=night] .office-header,
html[data-office-theme=night] .mobile-tabs,
html[data-office-theme=night] .office-search-results,
html[data-office-theme=night] #office-settings{background:var(--bg-deep)}
html[data-office-theme=night] .input,
html[data-office-theme=night] .select,
html[data-office-theme=night] .office-global-search input{background:var(--surface-strong);color:var(--text)}
.office-dealer-mobile{display:none}
@media(max-width:1180px){
  .office-header .office-brand{min-width:0;flex:1 1 auto;align-items:flex-start;flex-direction:column;gap:1px;overflow:hidden}
  .office-header .office-brand .office-dealer-mobile{display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font:500 12px/1.3 var(--sans);letter-spacing:normal}
}

/* Background: flat graphite / warm white, no coloured bloom */
body::before,body::after{display:none}
body{background:var(--bg)}
html[data-office-theme=day] body{background:var(--bg)}

/* Typography: mono only for numbers; quiet sans eyebrows and table heads */
.eyebrow,.peek-col h3,.conv-head,.msg>small{font:500 11px/1.3 var(--sans);letter-spacing:.14em;text-transform:uppercase}
.eyebrow{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--dim)}
.data-table thead th,.data-table th{font:500 11px var(--sans);letter-spacing:.1em}
.rail-head small{font:500 11px var(--sans);letter-spacing:.14em}
.state-panel h2{font:500 15px var(--sans)}
.focus-count,.stat-v,.metric-value,.pulse-item b,.indicator b{font-weight:400;font-variant-numeric:tabular-nums}

/* Buttons, avatars, tiles: neutral; one flat orange primary */
.button{border-radius:10px}
.button.primary,.btn-accent{box-shadow:none}
.avatar,.rail-avatar,.row-icon,.stat-ic{background:var(--surface-strong);color:var(--muted);border:1px solid var(--stroke)}
.avatar.mini{background:var(--surface-strong);color:var(--muted);border-color:var(--stroke)}
.stat-ic{border:0;background:transparent;color:var(--dim)}
.state-panel svg{color:var(--dim)}
.chip b{color:var(--muted)}
.rail-link[aria-current=page]{box-shadow:none;background:rgba(244,121,32,.1)}
.queue-item:hover,.list-row:hover{background:var(--surface-soft)}
.queue-item.selected,.queue-item.active,.queue-item[aria-current=true],.data-table tr.selected{background:rgba(244,121,32,.07)}
.dir-expand[aria-expanded=true]{color:var(--text);border-color:var(--muted)}

/* Status: dot + label, no capsule in tables and lists; hue only where it means something */
.data-table .status,.queue-item .status,.list-row .status,.guide-list .status{border:0;background:none;padding:0;margin:0;color:var(--text);white-space:nowrap;font-size:12px}
.status::before{background:var(--muted)}
.status.ok::before{background:var(--green)}.status.warn::before{background:var(--yellow)}.status.bad::before{background:var(--red)}
.status.info{color:var(--muted)}
.data-table .status.bad,.queue-item .status.bad,.list-row .status.bad,.status.bad{color:var(--red)}
.data-table .status.info,.queue-item .status.info{color:var(--muted)}
.time-block.info{border-color:var(--stroke);background:var(--surface-strong)}
.indicator .status{display:none}
.indicator-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
.indicator{min-height:112px}

/* Sample tags, ctx and draft: solid hairlines */
.sample-tag{border:1px solid var(--stroke);color:var(--dim);background:transparent}
html[data-office-theme=day] .sample-tag,html[data-office-theme=day] .sample-badge{color:var(--dim);background:transparent;border-color:var(--stroke)}
.section-head{flex-wrap:wrap;gap:4px 12px}
.ctx{border:1px solid var(--stroke);background:transparent}
.draft{border:1px solid var(--stroke)}
.drop-zone{border-color:var(--stroke-hi);background:transparent}

/* P1 focus band: one hairline-divided surface, no strips, no rank discs */
.focus-band{border-inline-start:1px solid var(--stroke)}
.focus-cards{gap:0}
.focus-card{border:0;border-radius:0;background:transparent}
.focus-card+.focus-card{border-inline-start:1px solid var(--stroke)}
.focus-card.none{border:0}.focus-card.none+.focus-card,.focus-card+.focus-card.none{border-inline-start:1px solid var(--stroke)}
.focus-card.nc{border-style:solid;opacity:1}.focus-card.nc .focus-t b,.focus-card.nc .focus-t small{color:var(--dim)}
.focus-card a:hover{background:var(--surface-soft)}
.focus-n{display:block;width:auto;height:auto;border-radius:0;background:none;color:var(--dim);font:500 11px var(--mono);align-self:start;padding-block-start:2px}
.focus-card.has[data-tone=bad] .focus-count{color:var(--red)}
.focus-card.has[data-tone=warn] .focus-t b::before{content:"";display:inline-block;width:6px;height:6px;margin-inline-end:7px;border-radius:50%;background:var(--yellow);vertical-align:middle}
.focus-summary,.focus-toggle{display:none}
.focus-band>header .eyebrow{margin-block-end:8px}

/* P2 stat strip: no bars */
.stat-bar{display:none}
.stat-t{gap:3px}

/* P3 directory rows: no tone rims; one selection marker */
.data-table.directory tbody tr[data-id]{border-inline-start:0}
.data-table.directory tbody tr[data-id]>td:first-child{box-shadow:none}
.data-table.directory tbody tr.is-open>td:first-child{box-shadow:inset 2px 0 0 var(--accent)}
.data-table.directory tbody tr[data-id]:hover{background:var(--surface-soft)}
.data-table.directory tr.is-open{background:rgba(244,121,32,.05)}
.aquis-col{border-inline-start:1px solid var(--stroke)}
.col-face{height:22px;width:auto;margin-inline-end:6px;vertical-align:middle}
.peek-col h3 .col-face{display:inline-block}

/* AQUIS identity: authentic blue face */
.aq-face{display:block;height:100%;width:auto;object-fit:contain;user-select:none;-webkit-user-drag:none}
.col-face{display:inline-block;height:22px}
.aq-mark{width:auto;height:15px;flex:0 0 auto}
.aq-mark .aq-drop-core{fill:var(--aquis-blue)}.aq-mark .aq-drop-shadow{fill:var(--aquis-ink)}.aq-mark .aq-drop-sheen{fill:#fff;opacity:.14}
.aq-mark .aq-eyes{fill:var(--aquis-eye)}.aq-mark .aq-eye-core{fill:var(--aquis-ink)}
.eyebrow .aq-mark{height:16px}
.ctx .aq-mark{height:16px;width:auto}
.ctx svg{color:inherit}
.aquis-fab{width:58px;height:58px;padding:0;background:var(--aquis-ink);box-shadow:0 8px 24px rgba(0,0,0,.28),0 0 0 1px rgba(57,183,245,.45) inset}
.aquis-fab{overflow:hidden}
.aquis-fab .fab-face{height:44px;width:auto;max-width:none;margin:0}
.aquis-fab.is-open{box-shadow:0 8px 24px rgba(0,0,0,.28),0 0 0 2px var(--aquis-blue)}
html[data-office-theme=day] .aquis-fab{box-shadow:0 8px 20px rgba(26,29,33,.22),0 0 0 1px rgba(57,183,245,.5) inset}
.sheet-head .drop{width:38px;height:38px;padding:0;border-radius:50%;background:var(--aquis-ink);box-shadow:0 0 0 1px rgba(57,183,245,.4) inset;display:grid;place-items:center}
.sheet-head .drop .sheet-face{height:30px;width:auto}
.sheet-head .drop svg{display:none}
.fab-up{border-color:var(--stroke);color:var(--muted)}

/* AQUIS sheet: neutral controls */
.aquis-sheet{border-color:var(--stroke)}
.mode-pill[aria-checked=true]{border-color:var(--stroke);background:var(--surface-strong);color:var(--text)}
.conv-item[aria-current=true]{border-color:var(--stroke);background:var(--surface-strong)}
.msg.you{background:var(--surface-strong);border-color:var(--stroke)}
.chip.script{border-color:var(--stroke);color:var(--text)}
.chip.script:hover{background:var(--surface-soft)}
.aquis-sheet .icon-btn.mic{border-color:var(--stroke);color:var(--muted)}
.aquis-sheet .icon-btn[aria-pressed=true]{background:var(--accent);color:var(--on-accent)}
.btn-link{color:var(--text)}.btn-link:hover{text-decoration:underline}
.aquis-dock button:focus-visible,.aquis-dock input:focus-visible,.aquis-dock textarea:focus-visible{outline-color:var(--aquis-blue)}

/* P8 department defects */
.verification-layout .input[type=date],.verification-layout input[type=date],.office-main input[type=date]{min-height:38px;padding:0 10px;border:1px solid var(--stroke);border-radius:10px;background:var(--surface-strong);color:var(--text);font:inherit}
.verification-layout .section-body>p,.verification-layout .section-body>.muted,.verification-layout p.count{padding-inline-start:16px}
.queue-item strong{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;line-height:1.3}
.money-layout .queue-item{grid-template-columns:auto minmax(0,1fr) auto;align-items:start}
.money-layout .queue-item strong{-webkit-line-clamp:1;white-space:normal}
@media(min-width:1181px){.installs-layout{grid-template-columns:minmax(330px,.95fr) minmax(0,1.5fr) minmax(270px,.72fr)}}
.import-grid .state-panel:not(.error){min-height:0;padding:10px 0;justify-items:start;text-align:start}
.import-grid .state-panel:not(.error) svg,.import-grid .state-panel:not(.error) h2{display:none}
.import-grid .state-panel:not(.error) p{margin:0;color:var(--dim);font-size:13px}
.import-confirm{align-items:center}
.import-confirm strong{font:500 13px var(--sans);color:var(--dim)}
.import-confirm p{margin:4px 0;color:var(--text)}
.import-confirm .button{justify-self:end}

/* P9 phone + tablet: compact focus, scrolling strip, customer rows early, controls clear of content */
@media(max-width:820px){
  .office-main{padding-block-end:calc(150px + env(safe-area-inset-bottom))}
  .focus-band{display:block;margin-block-end:10px}
  .focus-band>header{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:2px 10px;align-items:center;padding:12px 14px;border:0}
  .focus-band>header .eyebrow{grid-column:1/-1;margin:0 0 2px}
  .focus-band h2{font-size:18px}
  .focus-sub{display:none}
  .focus-summary,.focus-toggle{display:block}
  .focus-summary{grid-column:1;margin:0;color:var(--muted);font-size:12.5px}
  .focus-toggle{grid-row:2/4;grid-column:2;min-height:44px;padding:0 12px;border:1px solid var(--stroke);border-radius:10px;background:transparent;color:var(--text);font:500 12.5px var(--sans);cursor:pointer}
  .focus-body{display:none;padding:0 14px 8px;border-block-start:1px solid var(--stroke)}
  .focus-band.open .focus-body,.focus-body.always{display:block}
  .focus-cards{grid-template-columns:1fr}
  .focus-card+.focus-card{border-inline-start:0;border-block-start:1px solid var(--stroke)}
  .focus-card a,.focus-card.nc{grid-template-columns:28px minmax(0,1fr) auto;gap:8px;min-height:44px;align-items:center;padding:6px 0}
  .focus-t small{display:none}
  .focus-band.open .focus-t small{display:block}
  .focus-count{font-size:18px;align-self:center}
  .focus-foot{display:none}.focus-band.open .focus-foot{display:block}
  .stat-host{margin:0 -2px 10px}
  .stat-strip{display:flex;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none;border-radius:12px}
  .stat-card{flex:0 0 150px;scroll-snap-align:start;border:0!important;border-inline-start:1px solid var(--stroke)!important}
  .stat-card:first-child{border-inline-start:0!important}
  .stat-card a{grid-template-columns:minmax(0,1fr) auto;padding:10px 12px;gap:6px}
  .stat-ic{display:none}
  .stat-t small{display:none}
  .stat-v{font-size:20px}
  .fab-up{display:none}
  .aquis-dock{inset-block-end:calc(80px + env(safe-area-inset-bottom));inset-inline-end:12px}
  .aquis-fab{width:48px;height:48px}
  .aquis-fab .fab-face{height:37px}
  .dir-bar{padding:10px 12px;gap:8px}
  .dir-bar .chips{flex-wrap:nowrap;overflow-x:auto;width:100%}
  .dir-bar .chip{flex:0 0 auto}
  .aquis-dock:has(.aquis-sheet:not([hidden])) .aquis-fab{display:none}
  .aquis-sheet,.aquis-sheet.expanded{align-self:stretch;width:auto;min-width:0;max-width:100%;max-height:calc(100dvh - 190px)}
  .aquis-sheet .thread-col,.aquis-sheet .composer{min-width:0}
  .aquis-dock{inset-inline-start:8px}
  .dock-buttons{align-self:flex-end}
  .dir-heading h1{font-size:34px}
  .eyebrow{font-size:10.5px}
  .indicator-grid{grid-template-columns:1fr 1fr}
}
.customer-cell .avatar,.queue-item .avatar{flex:0 0 auto;min-width:32px}
.customer-cell{min-width:0}

/* Premium pass: department fixes found in the first captures */
#verification-evidence [data-verify-list]>.sample-tag,#verification-evidence [data-verify-list]>p{margin:10px 16px 8px;display:inline-flex}
#verification-evidence [data-verify-count],#verification-evidence [data-verify-detail]{padding-inline:16px}
#verification-evidence [data-verify-count]{margin:10px 0 4px}
.money-layout .queue-item strong{white-space:normal;overflow-wrap:anywhere;-webkit-line-clamp:2}
.money-layout .queue-item>span:last-child{display:flex;flex-direction:column;align-items:flex-end;gap:3px;text-align:end}
.drop-zone svg{color:var(--muted)}
.money-layout .data-table .status{white-space:normal}
#verification-evidence [data-verify-count]{padding-inline:0;margin-inline:16px}
@media(max-width:820px){.money-layout .queue-item>span:last-child{grid-column:2;flex-direction:row;align-items:baseline;justify-content:flex-start;gap:10px;text-align:start}}

/* Office containment: keep essential values readable inside their own cards. */
.office-main .indicator-grid{grid-template-columns:repeat(auto-fit,minmax(min(100%,220px),1fr))}
.office-main .indicator{min-width:0}
.office-main .indicator>b,.office-main .indicator>span{max-width:100%;overflow-wrap:anywhere}
.office-main .indicator>b{line-height:1.25}
.office-main .metric{min-width:0}
.office-main .metric-value,.office-main .metric-label,.office-main .queue-item .amount{overflow-wrap:anywhere}
@media(min-width:1181px){
  .office-main .home-grid{grid-template-columns:minmax(0,.82fr) minmax(0,1.45fr) minmax(0,1fr)}
  .office-main .tri-layout{grid-template-columns:minmax(0,.86fr) minmax(0,1.28fr) minmax(0,.9fr)}
  .office-main .reports-layout{grid-template-columns:minmax(0,.68fr) minmax(0,1.35fr) minmax(0,.8fr)}
  .office-main .import-grid{grid-template-columns:minmax(0,1fr) minmax(0,.8fr) minmax(0,1fr)}
}
.office-main :where(.home-grid,.tri-layout,.reports-layout,.import-grid)>*{min-width:0}
.office-main .detail-title h2,.office-main .kv-row dd,.office-main .kv-row dt,
.office-main .timeline strong,.office-main .transcript-part{min-width:0;overflow-wrap:anywhere}
.office-main :where(.queue-item,.list-row){grid-template-columns:auto minmax(0,1fr) fit-content(40%)}
.office-main :where(.queue-item,.list-row)>span{min-width:0}
.office-main :where(.queue-item,.list-row) small{overflow-wrap:anywhere}
.office-main :where(.queue-item,.list-row) .status{min-width:0;white-space:normal;overflow-wrap:anywhere}
.office-main .mapping-row>span,.office-main .mapping-row>strong{min-width:0;overflow-wrap:anywhere}
