/* =============================================
   ACS START PAGE STYLES - ExtJS Overrides
   =============================================

   MANDATORY THEME REFERENCES:
   - docs/theme/THEME_GUIDE.md (Single source of truth for styling)
   - docs/welcome_page/mocks/mock_home_screen.html (Visual reference implementation)
   - docs/welcome_page/home_screen.md (Feature specifications)
   - docs/welcome_page/ (Implementation plan)
   - contentserver/static/css/theme-icons.css (SVG icon library)

   All new styling MUST follow THEME_GUIDE.md specifications.
   Key sections:
   - Section 1: Color Palette (brand colors, neutrals, states)
   - Section 2: Typography (font families, sizes, weights)
   - Section 4: Border Radius (sm/md/lg values)
   - Section 5: Shadows (sm/md/lg/card)
   - Section 6: Component Patterns (accordion, dropdown, cards)
   - Section 11: Theme Icons System (SVG icons usage)

   Last updated: 2026-04-02
   ============================================= */

/* Modern SVG icons come from shared-icons.css (loaded via ExtJS.py
   alongside ext-acs-theme.css). The legacy theme-icons.css with
   baked-grey-stroke SVGs was retired in Phase 6 Step 7 — every consumer
   now uses mask-image (or the new <button>+<svg currentColor> trigger
   pattern) so currentColor / bg-color drives the icon fill. */

/* Manrope ExtraBold: brand wordmark font for the Discover panel
   headings. */
@font-face {
    font-family: 'Manrope';
    font-style: normal;
    font-weight: 800;
    font-display: swap;
    src: local('Manrope ExtraBold'), local('Manrope-ExtraBold'),
         url('../fonts/manrope/Manrope-ExtraBold.ttf') format('truetype');
}

/* ===== THEME COLOR VARIABLES =====
   Centralised color definitions for the startpage.
   Source: THEME_GUIDE.md Section 1.2 (mock implementation colors).
   Using these variables instead of hardcoded hex values improves
   maintainability — a brand color change is a single edit here.
   Migration: new/modified rules should use var(); legacy rules
   will be migrated incrementally. */
:root {
    /* Brand */
    --sp-brand-cyan: #00aeef;
    --sp-brand-cyan-hover: #00c2ff;
    --sp-brand-cyan-muted: #0e8bb0;
    --sp-brand-cyan-deep: #0a6f8c;
    --sp-brand-cyan-tint: #e6f5fb;
    --sp-brand-cyan-wash: #f0f8fc;

    /* Neutrals */
    --sp-dark: #1c2127;
    --sp-text-primary: #1c2127;
    --sp-text-secondary: #5a6370;
    --sp-text-tertiary: #8c95a0;
    --sp-surface: #f5f7f9;        /* primary chrome (toolbars, col-1 tree, panels) — matches --acs-surface */
    --sp-surface-soft: #fafbfc;   /* secondary chrome (book sidebar) — matches --acs-surface-soft */
    --sp-card-bg: #ffffff;        /* content surround / focal content (cards, paper, tiles) — matches --acs-card-bg */

    /* Borders */
    --sp-border: #e2e6ec;         /* default divider — matches --acs-border */
    --sp-border-light: #ECF0F6;   /* subtle divider — matches --acs-border-light */
    --sp-border-strong: #cdd9ec;  /* chrome↔content boundary (tinted-canvas dividers) — matches --acs-border-strong */
    --sp-border-input: #DCE2EF;   /* input borders — matches --acs-border-input */

    /* State backgrounds */
    --sp-hover-bg: #F6F8FB;
    --sp-hover-bg-blue: #f0f7ff;
    --sp-selection-bg: #EEF6FB;
    --sp-active-bg: rgba(0, 174, 239, 0.1);

    /* Button gradient companion (documented in STYLING_PATTERNS.md) */
    --sp-btn-gradient-end: #0098d4;

    /* Module / feature accents — single source of truth is the canonical
       palette in `ext-acs-theme.css` (top of file) and
       `shared-theme/scss/_variables.scss`. The startpage scope re-declares
       the same hex values under `--sp-*` aliases so the Discover promo
       cards (§2.8) and any future startpage-internal accent consume the
       *same* feature colour as the home-app cards and the top nav-bar
       button hovers. If the canonical hex changes upstream, mirror here.

       VIVID vs MUTED — the rule (THEME_GUIDE §1.2 + docs/theme/PALETTE.md):

         Each module has TWO variants. They are NOT interchangeable.
           - VIVID (e.g. --sp-task-green #1AED94): identity moments —
             brand glyphs, DISCOVER dots, card top-accent strips,
             notification dots. Anywhere the colour SAYS "this is
             AffiniTask / AffiniAI / AffiniTag".
           - MUTED (e.g. --sp-task-green-muted #1A9E7A): chrome accents —
             button-hover icon color, large fills, "my tasks" row markers.
             Same brand, quieter intensity for large surfaces or
             hover-state context.

         Lower-intensity hover *backgrounds* are the vivid colour at
         10–15% alpha (e.g. rgba(26,237,148,0.10)), NOT the muted variant.
         The muted variant is for foreground colour roles only.

         Cyan has the same rule (--sp-brand-cyan vs --sp-brand-cyan-muted),
         and the rule generalises to every module accent. */
    --sp-ai-purple: #B261D5;       /* AffiniAI — matches --acs-ai-purple (VIVID) */
    --sp-task-green: #1AED94;      /* AffiniTask — matches --acs-tasks-green (VIVID) */
    --sp-task-green-muted: #1A9E7A; /* AffiniTask muted (chrome hover, fills) — matches --acs-tasks-accent */
    --sp-tag-red: #FE235D;         /* AffiniTag / Search — matches --acs-tag-red (VIVID) */
    --sp-docs-blue: #00B3FA;       /* AffiniDocs / Browse Library — matches --acs-docs-blue (VIVID) */
}

/* ===== SCROLLBAR THEME =====
   Moved to contentserver/static/css/ext-acs-theme.css during Phase 2
   of the theme refactor (THEME_REVIEW.md §4.3 Phase 2). Thin neutral
   scrollbar now applies shell-wide via the var(--acs-scrollbar-*)
   tokens in acs-theme-properties.css. */

/* ADDITIONS FOR NEW LOOK 2016   ====================================================>     */

/* HACK for Azzure Theme to set library viewer backgrounds to WHITE */
.x-panel .x-panel-mc, .x-panel .x-panel-body , .x-grid3{
	background-color: #FFFFFF;
}	

/* This enlarges the Bookshelf toolbar in library viewer */
.x-toolbar-bookshelf {
	height: 40px;	
	background-color: #FFFFFF; 
	margin-top:12px;
}

.x-panel-header {
  height: 28px;
  padding-top: 8px !important;
  font-size: 14px !important;
  color: white !important;
  background-color: var(--sp-brand-cyan-muted, #0e8bb0) !important;
  border-color: white !important;
}

/* This changes the active element's font color in library tree
.x-tree-node a span:hover {
	color: #9DC4FF;
	
}
*/ 

/* This turns OFF icons in toolbar menus -- we may want it but only for the top level toolbar, not for all of them.  
.x-menu {background-image: none;}
.x-menu a.x-menu-item {padding-left: 3px;}
.x-menu .x-menu-item-icon {display: none;}
*/

/*Fix for ExtJs icons height*/

.x-tree-node-collapsed .x-tree-node-icon, .x-tree-node-expanded .x-tree-node-icon, .x-tree-node-leaf .x-tree-node-icon {
	height: 16px;
}

/*book viewer*/
.x-layout-split{
  position:absolute;
  height:5px;
  width:5px;
  line-height:1px;
  font-size:1px;
  z-index:3;
}

.x-layout-collapsed-west {
  position:absolute;
  height:5px;
  width:5px;
  line-height:1px;
  font-size:1px;
  z-index:3;
  /* ToDo: Compute THIS: */
  background-color:#231F20;
}


	
/* IE6 strict won't drag w/out a color */
.ext-strict .ext-ie6 .x-layout-split{
  background-color: #231F20 !important;
  filter: alpha(opacity=100);
}

/* Split bar styles moved to ext-acs-widgets.css for global availability */

#viewer_header{
  background-color: #FAFAFA;
}

#start_header_logo{
  padding-top:1px !important;
  /*background-color: white;*/
}

/* toolbar styles */

.x-panel-body.x-panel-body-noheader.x-panel-body-noborder.header {
	background-color: #231F20;
}

/* tree node text colouring */
.node_heading *{
  font-weight:bold;
  color: #BA4743 !important;;
}

.node_heading_2 *{
  font-weight:bold;
  color: #004292 !important;
}

.node_heading_3 *{
  font-weight:bold;
}

/* various icons for branches on a tree */

.x-tree-node img.fldr_real, .x-tree-node-collapsed img.fldr_real,
.x-tree-node img.fldr_link, .x-tree-node-collapsed img.fldr_link,
.x-tree-node img.fldr_marker, .x-tree-node-collapsed img.fldr_marker,
.x-tree-node img.fldr_user, .x-tree-node-collapsed img.fldr_user
{
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -32px 0;
}

.x-tree-node-expanded img.fldr_real,
.x-tree-node-expanded img.fldr_marker,
.x-tree-node-expanded img.fldr_marker,
.x-tree-node-expanded img.fldr_user
{
  background-image: url("/static/images/folder_open.png");
  background-repeat: no-repeat;
}

.x-tree-node img.fldr_user, .x-tree-node-collapsed img.fldr_user{
  background-image: url("/static/images/workspace.gif");
  background-repeat: no-repeat;
}

.x-tree-node-expanded img.fldr_user {
  background-image: url("/static/images/workspace.gif");
  background-repeat: no-repeat;
}

.x-tree-node img.fldr_cat, .x-tree-node-collapsed img.fldr_cat{
  background-image:url(/static/images/libraryswitcher.png); background-position: -240px 0;
}

.x-tree-node-expanded img.fldr_cat {
  background-image: url("/static/images/category.png");
  background-repeat: no-repeat;
}

.x-tree-node img.fldr_consolidated, .x-tree-node-collapsed img.fldr_consolidated{
  background-image:url(/static/images/libraryswitcher.png); background-position: -384px 0;
}

.x-tree-node-expanded img.fldr_consolidated {
  background-image: url("/static/images/consolidated.gif");
  background-repeat: no-repeat;
}

.x-tree-node img.fldr_download, .x-tree-node-collapsed img.fldr_download{
  background-image: url("/static/images/workspace.gif");
  background-repeat: no-repeat;
}

.x-tree-node-expanded img.fldr_download {
  background-image: url("/static/images/workspace.gif");
  background-repeat: no-repeat;
}

.x-tree-node img.fldr_workspace, .x-tree-node-collapsed img.fldr_workspace{
  background-image: url("/static/images/workspace.gif");
  background-repeat: no-repeat;
}

.x-tree-node-expanded img.fldr_workspace {
  background-image: url("/static/images/workspace.gif");
  background-repeat: no-repeat;
}

.x-tree-node img.track_folder, .x-tree-node-collapsed img.track_folder
{
  background-image: url("/static/images/folder_close.png");
  background-repeat: no-repeat;
}

.x-tree-node-expanded img.track_folder
{
  background-image: url("/static/images/folder_open.png");
  background-repeat: no-repeat;
}

.x-tree-node img.track_item
{
 background-image: url(/static/images/libraryswitcher.png) !important; background-position: 0 0 !important;
}

.x-tree-node .notWritableNode img.track_item
{
  background-position: 0 -16px !important;
}

.x-tree-node img.track_item_started
{
  background-image: url(/static/images/at_start.png) !important; background-position: 0 0 !important;
}

.x-tree-node .notWritableNode img.x-ss-item {
  background-position: -352px -16px !important;
}

.x-tree-node img.x-ss-item {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -352px 0 !important;
}


/* grid styles */
.grid-object-icon{
  border:0 none;
  height:16px;
  width:16px;
  margin:0;
  padding:0;
  vertical-align:top;
  background-position:center;
  background-repeat:no-repeat;
}

.ext-ie .grid-object-icon{
  vertical-align:middle!important;
}

.tb_expand_folder
{
    background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -256px !important;
}

.tb_collapse_folder
{
    background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -272px !important;
}

.book_img {
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: -16px 0 !important;
}

.consolidated_book_img {
  background-image:url("/static/images/consolidated_book_small.gif") !important;
}

.fldr_img, .fldr_real, .fldr_link, .fldr_marker {
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: -32px 0 !important;
}

.fldr_user {
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: -32px 0 !important;
}

.fldr_cat {
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: -240px 0 !important;
}

.parent_folder {
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: -32px -32px !important;
}

.fldr_consolidated {
  background-image:url(/static/images/libraryswitcher.png); background-position: -384px 0;
}

.ss_item {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: 0 -224px !important;
}

.fldr_download {
  background-image: url("/static/images/workspace.gif");
}

.fldr_workspace {
  background-image: url("/static/images/workspace.gif");
}

.grid_img {
  background-image:url("/static/images/folder_open.png") !important;
}

.lib_img {
  background-image:url("/static/images/library_large.gif") !important;
  border:0 none;
  width:32px;
  height:32px;
  margin:0;
  padding-right:5px;
  padding-bottom:0px;
  padding-top:0px;
  vertical-align:top;
  background-position:center;
  background-repeat:no-repeat;
}

.lib_img_small {
  background-image:url("/static/images/library_small.gif") !important;
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: -80px 0 !important;
}

.x-grid3-td-client_short_name a , .x-grid3-td-client_name a{
  color: #385F95;
  text-decoration:none;
}
.x-grid3-td-client_short_name a:hover, .x-grid3-td-client_name a:hover {
  text-decoration:underline;
}

/* toolbar objects */

.open_folder{
  background-image:url("/static/images/cmd_open_folder2.gif") !important;
}

.open_book{
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -48px !important;
}

.open_all {
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -64px !important;
}

.switch_library {
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -32px !important;
}

.user_sec {
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -80px !important;
}

.index {
  background-image:url("/static/images/cmd_index2.gif") !important;
}

.sync_books {
  background-image:url("/static/images/cmd_sync_books.gif") !important;
}

.compliance {
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -128px !important;
}
.show_all_books {
  background-image:url("/static/images/view-all-disabl.png") !important;
}

/* tab toolbars. Phase 6 mask-image migration. */
.tb_add_all_my_sel {
  -webkit-mask-image: var(--icon-plus) !important;
          mask-image: var(--icon-plus) !important;
  -webkit-mask-size: 16px 16px !important;
          mask-size: 16px 16px !important;
  -webkit-mask-repeat: no-repeat !important;
          mask-repeat: no-repeat !important;
  -webkit-mask-position: center !important;
          mask-position: center !important;
  background-image: none !important;
  background-color: var(--acs-text-secondary, #5a6370) !important;
  transition: background-color 0.15s !important;
}
.tb_add_all_my_sel:hover,
.x-btn-over .tb_add_all_my_sel {
  background-color: var(--acs-brand-cyan, #00aeef) !important;
}
.tb_delete_folder {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -320px -16px !important;
}
.tb_rename_folder {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -256px 0 !important;
}
.tb_new_folder {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -320px 0 !important;
}
.tb_open_all {
  background-image:url("/static/images/cmd_openall2.gif") !important;
}
.tb_add_book {
  background-image:url("/static/images/cmd_tab_add2.gif") !important;
}
.tb_add_all {
  background-image:url("/static/images/cmd_tab_addall2.gif") !important;
}
.tb_remove_book {
  background-image:url("/static/images/cmd_remove.gif") !important;
}
.tb_remove_all {
  background-image:url("/static/images/cmd_tab_removeall2.gif") !important;
}
.tb_group_node{
  background-image: url("/static/images/groups.png") !important;
}
.tb_user_node{
  background-image: url("/static/images/user_grid.png") !important;
}
.tb_notes{
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -96px !important;
}
.tb_notes_summary{
  background-image: url("/static/images/notes.png") !important;
}
.tb_user_reg {
  background-image: url("/static/images/user_registration.png") !important;
}
.tb_password {
  background-image: url("/static/images/key.png") !important;
}
.tb_edit {
  background-image: url("/static/images/pub_edit.gif") !important;
}
.tb_calendar {
  background-image: url("/static/images/calendar.gif") !important;
}

/* AT buttons styles */
.cmd_export_to_pdf {
  background-image: url("/static/images/export-to-pdf.png") !important;
}
.cmd_email_page {
  background-image: url("/static/images/email_page.png") !important;
}
.cmd_print {
  background-image: url("/static/images/print.png") !important;
}
.cmd_edit_track
{
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -352px -48px !important;
}
.cmd_refresh_track
{
  background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -144px !important;  
}
.cmd_start_track
{
  background-image: url("/static/images/at_start.png") !important;
}
.cmd_stop_track
{
  background-image: url("/static/images/at_stop.png") !important;
}
.cmd_delete_track
{
  background-image: url("/static/images/at_remove.png") !important;
}
.cmd_new_track
{
  background-image: url("/static/images/at_new.png") !important;
}

/* general screen styles */

#object_detail{
  overflow:auto;
  font-size: 13px;
  font-weight: normal;
  font-family: "Arial Narrow";
  color:#666666;
}

#object_detail div{
  padding:10px;
}

.workspace_tabs{
  color:#666666;
  font-family:"Arial Narrow";
  font-size:13px;
  font-weight:normal;
}

.lib_available{
  font-size: 12px;
  font-weight: bold;
  font-family: "Arial Narrow";
  color:#658FBE;
  text-transform:uppercase;
  padding-bottom:10px;
}

.start_image_list{
  padding-top:2px;
  padding-bottom:2px;
}
		
/* for the message area so it calculates text size correctly */
#start_page_message_area
{
  position: relative;
  margin-right: 10px;
  color:#444444;
  font-size:13px;
  font-size-adjust:none;
  font-style:normal;
  font-variant:normal;
  font-weight:normal;
  line-height:normal;
}
/* Custom stylesheets */
/* styles for books' view switchers toolbar */
.x-icon-basicviewswitcher{
  background-image: url(/static/images/libraryswitcher.png); background-position: -176px 0 !important;
}
.selected button.x-icon-basicviewswitcher {
  background-position: -176px -16px !important;
}
.x-icon-iconviewswitcher{
  border-left: 20px;
  background-image: url(/static/images/libraryswitcher.png); background-position: -160px 0 !important;
}
.selected button.x-icon-iconviewswitcher {
  background-position: -160px -16px !important;
}
.x-icon-gridviewswitcher{
  background-image: url(/static/images/libraryswitcher.png);background-position: -144px 0 !important;
}
.selected button.x-icon-gridviewswitcher {
  background-position: -144px -16px !important;
}

/* library icon view styles */
.x-icon-libbigbook {
  background-image: url(/static/images/libiconview.png); background-position: 0 0; height: 80px; width: 80px;
  -pie-png-fix: true;
  behavior: url(/static/javascript/startpage/PIE.htc);
  zoom: 1;
  margin: 0 auto;
}
.x-icon-libbigfolder {
  background-image: url(/static/images/libiconview.png); background-position: -80px 0; height: 80px; width: 80px;
  -pie-png-fix: true;
  behavior: url(/static/javascript/startpage/PIE.htc);
  zoom: 1;
  margin: 0 auto;
}
.x-icon-libbigcategory {
  background-image: url(/static/images/libiconview.png); background-position: -160px 0; height: 80px; width: 80px;
  -pie-png-fix: true;
  behavior: url(/static/javascript/startpage/PIE.htc);
  zoom: 1;
  margin: 0 auto;
}
.x-component-libiconel {
  -moz-box-sizing: border-box;
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
  font-size: 13px;
  overflow: hidden;
  color: #3e3e3e;
  text-align: center;
  border: #fff 2px solid;
  margin: 0px 2px 2px 0px;
  padding: 15px 10px;
  display: inline-block;
  width: 180px;
  vertical-align: top;
/* for ie */  
  zoom: 1;
  *display: inline;
  position: relative;
  behavior: url(/static/javascript/startpage/PIE.htc);
}
.x-component-libiconel:hover {
  background-color: #f5f5f5;
  border: 2px solid #f5f5f5;
  behavior:url(/static/javascript/startpage/PIE.htc);
  zoom: 1;

}
.x-component-libiconel a {
  color: #3e3e3e;
  text-decoration: none;
  display: block;
  width: 100%;
  overflow: hidden;
}
.x-component-libiconel a:hover {
  color: #1b5bb8;
  text-decoration: underline;
}

.x-component-libiconel.x-bigfolderselected {
  border: 2px solid #37a8ff;
  behavior:url(/static/javascript/startpage/PIE.htc);
  zoom: 1;
}

/* library common view */
.x-grid3-row-commonview td{
  border: none;
}
/**TODO different view for odd and even rows */
.x-grid3-row-commonview .odd { }

.x-tree-node-libicon {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -80px 0 !important;
}
.x-tree-node-myselicon {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -224px 0 !important;
}
.x-tree-node-aticon {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -0px 0 !important;
}
.x-tree-node-ssicon {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -96px 0 !important;
}
.x-tree-node-leftpanel ul { width:100%; }

/**/
.x-tree-node-over a.active{
   display: inline;
}

.x-tree-node-plus, .x-tree-node-minus, .x-tree-node-refresh {
   background-image: url(/static/images/libraryswitcher.png) !important;
   height: 16px;
   width: 16px;
   position: absolute;
   right : 10px;
   display: none;
   margin-top: 2px;
}

.x-tree-node-plus {
   background-position: -192px 0 !important;
}
.x-tree-node-plus:hover {
   background-position: -192px -16px !important;
}
.x-tree-node-minus{
   background-position: -208px 0 !important;
}
.x-tree-node-minus:hover{
   background-position: -208px -16px !important;
}
.x-tree-node-refresh{
   background-position: -368px 0 !important;
}
.x-tree-node-refresh:hover{
   background-position: -368px -16px !important;
}

p span.start_library_label {
  color: #a3a3a3;
}

.x-panel-lib1.x-panel-libtooltip {
  overflow: visible !important;
  background-color: #fff;
/*  padding: 20px;*/
  max-width: 421px;
  /*
  max-height: 286px;
  */
  behavior:url(/static/javascript/startpage/PIE.htc);
  zoom: 1;
  
  -webkit-box-shadow: 1px 0px 7px rgba(7, 43, 57, 0.28);
  -moz-box-shadow:    1px 0px 7px rgba(7, 43, 57, 0.28);
  box-shadow:         1px 0px 7px rgba(7, 43, 57, 0.28);

}
.x-panel-libtooltip h4 {
  font: normal normal 400 15px/14px;
  color: #202020;
  margin: 0px 0px 7px;
  display: block;
  padding: 0px;
  
}
.x-panel-libtooltip p {
  margin: 4px 0px 0px;
  font: 400 11px/14px ;
  text-align: left;
  overflow: hidden;
}

.x-panel-libtooltip span {
  font: 400 11px/14px ;
  color: #666666;
}

.x-panel-libtooltip strong {
  font: normal normal 700 12px/17px;
}

.notWritableNode .x-icon-private {
  background-position: -64px -16px !important;
}
.notWritableNode .x-icon-shared {
  background-position: -48px -16px !important;
}
.notWritableNode .x-icon-public {
  background-position: -32px -16px !important;
}

.x-icon-private {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -64px 0 !important;
}
.x-icon-shared {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -48px 0 !important;
}
.x-icon-public {
  background-image: url(/static/images/libraryswitcher.png) !important; background-position: -32px 0 !important;
}
.x-panel-libtooltip-body {
  padding: 12px 14px;
  max-width: 421px;
/*  max-height: 246px;*/
  overflow: hidden;
}

.x-box-item {
  text-align: justify;
  display: inline-block;
  zoom: 1;
}

.x-tip-anchor {
    overflow: visible;
    background-image:url(/static/images/tip.png);
    -pie-png-fix: true;
    behavior: url(/static/javascript/startpage/PIE.htc);    
    position: absolute;
    width: 29px;
    height: 29px;
    
    /*background: transparent no-repeat 0 0;*/
    zoom:1;
}
.x-tip-anchor-top {
  background-image:url(/static/images/tip.png);
  -pie-png-fix: true;
  behavior: url(/static/javascript/startpage/PIE.htc);
  zoom: 1;
  background-position: 0 100%;
}

.x-tip-anchor-bottom {
    left: 13px !important;
    background-image:url(/static/images/tip.png);
    -pie-png-fix: true;
    behavior: url(/static/javascript/startpage/PIE.htc);
    zoom: 1;
    background-position: -29px 0;
    top: auto !important;
}
.x-tip-anchor-right {
  top: 8px !important;
  background-image:url(/static/images/tip.png);
  -pie-png-fix: true;
  behavior: url(/static/javascript/startpage/PIE.htc);
  zoom: 1;
    background-position: -57px 0;
    width: 20px;
}
.x-tip-anchor-left {
  top: 8px !important;
  left: -20px !important;
  background-image:url(/static/images/tip.png);
  -pie-png-fix: true;
  behavior: url(/static/javascript/startpage/PIE.htc);
  zoom: 1;
    background-position: -78px 0;
    width: 20px;
}
.x-panel-libtooltip-bwrap {
  
  _width: 421px;
}
.x-icon-logout {
  background-image: url(/static/images/libraryswitcher.png) !important;
  background-position: -112px 0 !important;
  height: 16px;
  width: 16px;
  display: block;
}
.startpage-rightop {
  position: absolute;
  top: 10px;
  right: 20px;
}
.start_user_info
{
  color:#990000;
  height:30px;
}

.x-tree-node-el {
    line-height: 22px;
}
.x-tree-node-el img.x-tree-node-icon {
    margin-top: -4px;
}

/* Trees */

.preference_btn {
	background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -160px !important;
}
.sort_btn {
	background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -176px !important;
}
.xg-hmenu-sort-desc img.x-menu-item-icon,
.sort_desc_btn {
	background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -208px !important;
}
.xg-hmenu-sort-asc img.x-menu-item-icon,
.sort_acs_btn {
	background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -192px !important;
}
.sort_orig_btn {
	background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -240px !important;
}

.delete_ss_icon {
	background-image: url(/static/images/libraryswitcher.png) !important; background-position: -352px -32px !important;
}

.edit_ss_icon {
	background-image: url(/static/images/libraryswitcher.png) !important; background-position: -352px -48px !important;
}

.run_ss_icon {
	background-image: url(/static/images/libraryswitcher.png) !important; background-position: -352px -64px !important;
}


.x-dd-drag-ghost .active{
  background-image: none !important;
}

/* Drag-drop proxy / ghost rules moved to ext-acs-theme.css during
   Phase 3 PR 3.1 (THEME_REVIEW.md §4.3). Now applies shell-wide. */




/* table of contents */

td.x-table-layout-cell {
  vertical-align: top;
}

td.x-table-layout-cell.cell-icon {
  
  width: 200px;
  text-align: center;
}
td.x-table-layout-cell.cell-icon img {
  margin-top: 30px;
}

td.x-table-layout-cell.cell-description {
  
}

div.table-description {
  padding: 15px;
}
div.table-description h4 {
  font-size: 16px;
  font-weight: normal;
  color: #161616;
  text-align: left;
  margin-bottom: 20px;
}
div.table-description p {
  font-size: 13px;
  color: #383838;
}
div.table-description p span {
  color: #9d9d9d;
}

.tree-panel-content-cell .x-panel-body{
	padding: 0px 10px 10px 0px;
}

div.tree-panel-content span {
  color: #383838;
  font-size: 13px;
  vertical-align: baseline;
}

div.tree-panel-content div.tree-panel-header span {
  color: #000000;
  font-size: 13px;
  vertical-align: baseline;
}

#tocTree .x-tree-selected {
  background: none !important;
}

#tocTree div.tree-panel-header{
  background-color: #dcdfe3 !important;
}

div.tree-panel-content img.x-tree-node-icon {
  display: none;
}

div.tree-panel-content img.x-tree-node-icon,
div.tree-panel-content img.x-tree-elbow-line {
  background-image: none !important;
}

div.tree-panel-content li.x-tree-node .x-tree-node-over,
div.tree-panel-content li.x-tree-node .x-tree-node-over a span {
  color: #1a53a1;
  text-decoration: underline;
  background-color: transparent;
}

/* =============================================
   TOOLTIP STYLING (Scoped to startpage)
   Dark theme for tooltips to distinguish from popovers
   ============================================= */
div.x-tip {
    float: left;
    padding: 0 !important;
    font-size: 13px !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
    color: #fff !important;
    background: #1c2127 !important;
    border: none !important;
    border-radius: 6px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
    overflow: hidden !important;
}

/* Hide the entire top row (header row) - it's always empty for simple tooltips */
div.x-tip > .x-tip-tl {
    display: none !important;
}

/* Remove all ExtJS tooltip background images and reset padding */
div.x-tip div.x-tip-tl,
div.x-tip div.x-tip-tc,
div.x-tip div.x-tip-tr,
div.x-tip div.x-tip-ml,
div.x-tip div.x-tip-mc,
div.x-tip div.x-tip-mr,
div.x-tip div.x-tip-bl,
div.x-tip div.x-tip-bc,
div.x-tip div.x-tip-br {
    background-image: none !important;
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* Reset wrapper elements */
div.x-tip .x-tip-bwrap,
div.x-tip .x-tip-ml,
div.x-tip .x-tip-mr,
div.x-tip .x-tip-mc {
    padding: 0 !important;
    margin: 0 !important;
}

/* Hide bottom row decorations */
div.x-tip .x-tip-bl,
div.x-tip .x-tip-br,
div.x-tip .x-tip-bc {
    display: none !important;
}

/* Tooltip body */
div.x-tip .x-tip-body {
    padding: 8px 12px !important;
    font-size: 13px !important;
    color: #fff !important;
    line-height: 1.4 !important;
}

/* =============================================
   CONTEXT MENU STYLING - Tree Context Menus
   Per THEME_GUIDE.md Section 6.5 Dropdown/Popover
   Scoped to to avoid bleeding to other pages
   ============================================= */

/* Hide ExtJS image-based shadow — we use CSS box-shadow on windows instead */
div.x-shadow {
    display: none !important;
}

/* Dialog drag proxy — themed outline during window drag */


/* Canonical light-theme popover — aligned with Kendo .k-popup / .k-menu-popup
   via THEME_GUIDE.md §6.5. Scoped to startpage to exclude header menus
   (.header-menu) which have their own dark theme in ext-acs-header.css. */
.x-menu:not(.header-menu),
.x-menu.x-menu-floating:not(.header-menu) {
    background: #fff !important;
    background-image: none !important;
    /* Border + radius aligned with `.x-combo-list` (canonical floating
       panel). Polish-pass alignment — was border-color #e2e6ec / radius
       10px which drifted from the canonical 6px / `--acs-border-input`. */
    border: 1px solid var(--acs-border-input) !important;
    border-radius: var(--acs-radius-md) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    padding: 4px !important;
    overflow: hidden !important;
    font-family: var(--acs-font-family) !important;
    /* `box-sizing: border-box` so the inline width ExtJS sets on `.x-layer`
       includes the 1px border + 4px padding. Default `content-box` made
       the menu visually shrink by ~2px between the initial open render
       and the post-hover relayout. */
    box-sizing: border-box !important;
}

/* Menu list - remove old backgrounds */
.x-menu:not(.header-menu) ul,
.x-menu.x-menu-floating:not(.header-menu) ul {
    background: transparent !important;
    background-image: none !important;
}

.x-menu:not(.header-menu) .x-menu-list,
.x-menu.x-menu-floating:not(.header-menu) .x-menu-list {
    background: transparent !important;
    background-image: none !important;
    padding: 0 !important;
}

/* Menu items — no horizontal margin so the hover wash extends to the
   menu's content edge (inside the 4px container padding). With the
   previous `margin: 0 4px` the wash was inset 8px from the menu border
   (4px padding + 4px li margin), which created a visual "shift" — on
   hover the wash band reads as the menu and the 8px gap looks like the
   container has shrunk inwards. Polish-pass alignment.

   Also pin `padding: 0` so the `<li>` is identically sized in normal
   and `.x-menu-item-active` states. azzurra-legacy.css:2015 sets
   `.x-menu-list-item { padding: 1px }` and azzurra-legacy.css:2027
   sets `.x-menu-item-active { padding: 0; margin: 0 1px; border: 1px
   solid }` — that 1px padding/margin/border swap on hover is what
   makes the menu visually "shift" by 2px on hover. Locking padding
   and margin to 0 in both states keeps the geometry stable. */
.x-menu:not(.header-menu) li.x-menu-list-item,
.x-menu.x-menu-floating:not(.header-menu) li.x-menu-list-item,
.x-menu:not(.header-menu) li.x-menu-list-item.x-menu-item-active,
.x-menu.x-menu-floating:not(.header-menu) li.x-menu-list-item.x-menu-item-active {
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
}

.x-menu:not(.header-menu) a.x-menu-item,
.x-menu.x-menu-floating:not(.header-menu) a.x-menu-item {
    display: flex !important;
    align-items: center !important;
    /* Match Kendo .k-menu-link compact vertical-menu padding (4px/8px)
       so ExtJS context menus feel the same density as Angular ones. */
    padding: 4px 8px !important;
    color: var(--acs-text-primary) !important;
    font-size: 13px !important;
    /* Use canonical `--acs-font-family` (Inter) so menu text matches
       the rest of the shell — was an explicit `-apple-system / Segoe UI`
       stack which drifted from the rest of the theme. */
    font-family: var(--acs-font-family) !important;
    border-radius: 6px !important;
    background: transparent !important;
    text-decoration: none !important;
}

/* Menu item icon - override absolute positioning, use flex */
.x-menu:not(.header-menu) a.x-menu-item img.x-menu-item-icon,
.x-menu.x-menu-floating:not(.header-menu) a.x-menu-item img.x-menu-item-icon {
    position: static !important;
    flex-shrink: 0 !important;
}

/* Menu item text - flex child */
.x-menu:not(.header-menu) a.x-menu-item .x-menu-item-text,
.x-menu.x-menu-floating:not(.header-menu) a.x-menu-item .x-menu-item-text {
    flex: 1 !important;
    line-height: 1.4 !important;
}

/* Menu item hover — canonical: cyan-wash bg, muted-teal text.
   Also override the dark-gray hover border from xtheme-affinitext.css
   (.x-menu-item-active { border-color:#7d7d7d }) which shows through as
   a thin gray ring around the hovered item. */
.x-menu:not(.header-menu) li.x-menu-list-item.x-menu-item-active,
.x-menu.x-menu-floating:not(.header-menu) li.x-menu-list-item.x-menu-item-active {
    background: var(--sp-brand-cyan-wash, #f0f8fc) !important;
    background-image: none !important;
    border-color: transparent !important;
    border-radius: 6px !important;
}

.x-menu:not(.header-menu) li.x-menu-item-active a.x-menu-item,
.x-menu.x-menu-floating:not(.header-menu) li.x-menu-item-active a.x-menu-item {
    color: var(--sp-brand-cyan-muted, #0e8bb0) !important;
    background: transparent !important;
    /* Pin border + margin to 0 in the active state so the `<a>`'s
       geometry stays identical to its non-active state. azzurra-legacy
       2029 sets `.x-menu-item-active a.x-menu-item { border: 0 1px; margin: 0 -1px }`
       — invisible 1px borders that still take 2px of width and shift
       the `<a>` -1px on x. The visible "menu shifts on hover" was the
       `<a>` growing 2px and shifting left 1px. */
    border: none !important;
    margin: 0 !important;
}

/* Lock `<a>.x-menu-item` line-box height regardless of active state.
   ExtJS HTML uses inline-block-ish layout for `<a>` with `<img>` icons
   and `<span>` text inside. When `.x-menu-item-active` adds 1px borders
   on the `<a>` (azzurra-legacy 2029), even with `border-color:
   transparent` the line-box height changes by 1-2px which sub-pixel
   re-baselines the surrounding `<li>`s, producing a 0.5px y-shift
   across the entire menu when an item activates. Pin a fixed height
   on the `<a>` so the line-box doesn't fluctuate. */
.x-menu:not(.header-menu) a.x-menu-item,
.x-menu.x-menu-floating:not(.header-menu) a.x-menu-item,
.x-menu:not(.header-menu) li.x-menu-item-active a.x-menu-item,
.x-menu.x-menu-floating:not(.header-menu) li.x-menu-item-active a.x-menu-item {
    box-sizing: border-box !important;
    line-height: 18px !important;
}

/* Pin `<li>` itself: stable display, no inline-baseline reflow.
   `:not(.x-hide-display)` so this never outranks Ext's own `display: none`
   and leave an item the app has hidden still painted (work item #49). */
.x-menu:not(.header-menu) li.x-menu-list-item:not(.x-hide-display),
.x-menu.x-menu-floating:not(.header-menu) li.x-menu-list-item:not(.x-hide-display),
.x-menu:not(.header-menu) li.x-menu-list-item.x-menu-item-active:not(.x-hide-display),
.x-menu.x-menu-floating:not(.header-menu) li.x-menu-list-item.x-menu-item-active:not(.x-hide-display) {
    display: block !important;
    vertical-align: top !important;
}

/* Menu separator */
.x-menu:not(.header-menu) .x-menu-sep-li,
.x-menu.x-menu-floating:not(.header-menu) .x-menu-sep-li {
    margin: 4px 8px !important;
    padding: 0 !important;
    background: transparent !important;
}

.x-menu:not(.header-menu) .x-menu-sep,
.x-menu.x-menu-floating:not(.header-menu) .x-menu-sep {
    border-top: 1px solid #e2e6ec !important;
    background: none !important;
    height: 0 !important;
}

/* ===== CONTEXT MENU ICONS - Modern SVG ===== */
/* Replace old sprite-based icons with theme icons */

/* Base styles for all context menu icons. Phase 6 mask-image migration:
   per-icon rules below set mask-image AND background-color. The base
   rule supplies geometry (size 16x16, mask position/repeat) and box
   metrics only. Crucially it does NOT set background-color or
   background-image:none — items that have no per-icon migration
   (e.g. ExtJS placeholders with src="blank_image_url.gif" and no
   iconCls) keep their default look (visually empty), avoiding a
   solid grey square regression. */
.x-menu .x-menu-item-icon,
.x-menu.x-menu-floating .x-menu-item-icon,
.x-menu.x-menu-floating img.x-menu-item-icon {
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 8px !important;
    vertical-align: middle !important;
}

/* Phase 6 mask-image fill — shared across every per-icon rule below.
   Selector list mirrors the per-icon rules so it inherits their
   specificity, without painting ANY x-menu-item-icon that has no
   migrated per-icon rule (those keep their default ExtJS look).
   This rule supplies background-color (consumer-side icon fill) +
   background-image: none (clears the legacy PNG/sprite that ExtJS
   may set via inline src on the <img>). */
.x-menu .cmd_new_track,
.x-menu.x-menu-floating .cmd_new_track,
.x-menu .cmd_edit_track,
.x-menu.x-menu-floating .cmd_edit_track,
.x-menu .cmd_delete_track,
.x-menu.x-menu-floating .cmd_delete_track,
.x-menu .cmd_start_track,
.x-menu.x-menu-floating .cmd_start_track,
.x-menu .cmd_stop_track,
.x-menu.x-menu-floating .cmd_stop_track,
.x-menu .cmd_refresh_track,
.x-menu.x-menu-floating .cmd_refresh_track,
.x-menu .tb_new_folder,
.x-menu.x-menu-floating .tb_new_folder,
.x-menu .tb_rename_folder,
.x-menu.x-menu-floating .tb_rename_folder,
.x-menu .tb_delete_folder,
.x-menu.x-menu-floating .tb_delete_folder,
.x-menu .sort_acs_btn,
.x-menu.x-menu-floating .sort_acs_btn,
.x-menu .xg-hmenu-sort-asc img.x-menu-item-icon,
.x-menu .sort_desc_btn,
.x-menu.x-menu-floating .sort_desc_btn,
.x-menu .xg-hmenu-sort-desc img.x-menu-item-icon,
.x-menu .sort_orig_btn,
.x-menu.x-menu-floating .sort_orig_btn,
.x-menu .cmd_print,
.x-menu.x-menu-floating .cmd_print,
.x-menu .cmd_export_to_pdf,
.x-menu.x-menu-floating .cmd_export_to_pdf,
.x-menu .cmd_email_page,
.x-menu.x-menu-floating .cmd_email_page,
.x-menu img.x-menu-item-icon.tb_expand_folder,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_expand_folder,
.x-menu img.x-menu-item-icon.tb_collapse_folder,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_collapse_folder,
.x-menu img.x-menu-item-icon.refresh_icon,
.x-menu.x-menu-floating img.x-menu-item-icon.refresh_icon,
.x-menu img.x-menu-item-icon.tb_add_book,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_add_book,
.x-menu img.x-menu-item-icon.tb_add_all,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_add_all,
.x-menu img.x-menu-item-icon.tb_remove_book,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_remove_book,
.x-menu img.x-menu-item-icon.tb_remove_all,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_remove_all,
.x-menu img.x-menu-item-icon.open_book,
.x-menu.x-menu-floating img.x-menu-item-icon.open_book,
.x-menu img.x-menu-item-icon.open_folder,
.x-menu.x-menu-floating img.x-menu-item-icon.open_folder,
.x-menu img.x-menu-item-icon.open_all,
.x-menu.x-menu-floating img.x-menu-item-icon.open_all,
.x-menu .x-cols-icon img.x-menu-item-icon,
.x-menu li.x-menu-list-item a.x-menu-item .x-menu-item-icon[class*="x-cols"],
.x-menu .ux-gridfilter-icon img.x-menu-item-icon,
.x-menu .x-menu-list-item .ux-gridfilter-icon img.x-menu-item-icon,
.x-menu .x-menu-check-item.x-menu-item-arrow img.x-menu-item-icon,
.x-menu img.x-menu-item-icon.ux-gridfilter-text-icon {
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Analysis Track context menu icons */
.x-menu .cmd_new_track,
.x-menu.x-menu-floating .cmd_new_track {
    -webkit-mask-image: var(--icon-circle-plus) !important;
            mask-image: var(--icon-circle-plus) !important;
}

.x-menu .cmd_edit_track,
.x-menu.x-menu-floating .cmd_edit_track {
    -webkit-mask-image: var(--icon-edit) !important;
            mask-image: var(--icon-edit) !important;
}

.x-menu .cmd_delete_track,
.x-menu.x-menu-floating .cmd_delete_track {
    -webkit-mask-image: var(--icon-trash) !important;
            mask-image: var(--icon-trash) !important;
}

.x-menu .cmd_start_track,
.x-menu.x-menu-floating .cmd_start_track {
    -webkit-mask-image: var(--icon-play) !important;
            mask-image: var(--icon-play) !important;
}

.x-menu .cmd_stop_track,
.x-menu.x-menu-floating .cmd_stop_track {
    -webkit-mask-image: var(--icon-square) !important;
            mask-image: var(--icon-square) !important;
}

.x-menu .cmd_refresh_track,
.x-menu.x-menu-floating .cmd_refresh_track {
    -webkit-mask-image: var(--icon-refresh) !important;
            mask-image: var(--icon-refresh) !important;
}

/* Saved Search icons — page-wide (menus, toolbars, tree tools).
   Phase 6 mask-image migration. Each rule sets its own mask geometry
   because these surfaces appear outside .x-menu (no shared base rule).
   :not(button) excludes the toolbar buttons (button.edit_ss_icon /
   button.delete_ss_icon / button.run_ss_icon at L4622+) which use
   the ::before pseudo-element pattern - applying mask-image to the
   <button> itself would mask out the button text. */
.delete_ss_icon:not(button) {
    -webkit-mask-image: var(--icon-trash) !important;
            mask-image: var(--icon-trash) !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.edit_ss_icon:not(button) {
    -webkit-mask-image: var(--icon-edit) !important;
            mask-image: var(--icon-edit) !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.run_ss_icon:not(button) {
    -webkit-mask-image: var(--icon-play) !important;
            mask-image: var(--icon-play) !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Folder/Tree context menu icons */
.x-menu .tb_new_folder,
.x-menu.x-menu-floating .tb_new_folder {
    -webkit-mask-image: var(--icon-folder-plus) !important;
            mask-image: var(--icon-folder-plus) !important;
}

.x-menu .tb_rename_folder,
.x-menu.x-menu-floating .tb_rename_folder {
    -webkit-mask-image: var(--icon-edit) !important;
            mask-image: var(--icon-edit) !important;
}

.x-menu .tb_delete_folder,
.x-menu.x-menu-floating .tb_delete_folder {
    -webkit-mask-image: var(--icon-trash) !important;
            mask-image: var(--icon-trash) !important;
}

/* Sort menu icons */
.x-menu .sort_acs_btn,
.x-menu.x-menu-floating .sort_acs_btn,
.x-menu .xg-hmenu-sort-asc img.x-menu-item-icon {
    -webkit-mask-image: var(--icon-sort-asc) !important;
            mask-image: var(--icon-sort-asc) !important;
}

.x-menu .sort_desc_btn,
.x-menu.x-menu-floating .sort_desc_btn,
.x-menu .xg-hmenu-sort-desc img.x-menu-item-icon {
    -webkit-mask-image: var(--icon-sort-desc) !important;
            mask-image: var(--icon-sort-desc) !important;
}

.x-menu .sort_orig_btn,
.x-menu.x-menu-floating .sort_orig_btn {
    -webkit-mask-image: var(--icon-list-restart) !important;
            mask-image: var(--icon-list-restart) !important;
}

/* Print/Export icons */
.x-menu .cmd_print,
.x-menu.x-menu-floating .cmd_print {
    -webkit-mask-image: var(--icon-printer) !important;
            mask-image: var(--icon-printer) !important;
}

.x-menu .cmd_export_to_pdf,
.x-menu.x-menu-floating .cmd_export_to_pdf {
    -webkit-mask-image: var(--icon-file-pdf) !important;
            mask-image: var(--icon-file-pdf) !important;
}

.x-menu .cmd_email_page,
.x-menu.x-menu-floating .cmd_email_page {
    -webkit-mask-image: var(--icon-mail) !important;
            mask-image: var(--icon-mail) !important;
}

/* Browse Library / Tree expand/collapse icons */
.x-menu img.x-menu-item-icon.tb_expand_folder,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_expand_folder {
    -webkit-mask-image: var(--icon-folder-plus) !important;
            mask-image: var(--icon-folder-plus) !important;
}

.x-menu img.x-menu-item-icon.tb_collapse_folder,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_collapse_folder {
    -webkit-mask-image: var(--icon-folder-minus) !important;
            mask-image: var(--icon-folder-minus) !important;
}

/* Refresh icon in context menus */
.x-menu img.x-menu-item-icon.refresh_icon,
.x-menu.x-menu-floating img.x-menu-item-icon.refresh_icon {
    -webkit-mask-image: var(--icon-refresh) !important;
            mask-image: var(--icon-refresh) !important;
}

/* Add to My Selections icon */
.x-menu img.x-menu-item-icon.tb_add_book,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_add_book,
.x-menu img.x-menu-item-icon.tb_add_all,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_add_all {
    -webkit-mask-image: var(--icon-circle-plus) !important;
            mask-image: var(--icon-circle-plus) !important;
}

/* Remove from My Selections icon */
.x-menu img.x-menu-item-icon.tb_remove_book,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_remove_book,
.x-menu img.x-menu-item-icon.tb_remove_all,
.x-menu.x-menu-floating img.x-menu-item-icon.tb_remove_all {
    -webkit-mask-image: var(--icon-x) !important;
            mask-image: var(--icon-x) !important;
}

/* Open book/folder icons */
.x-menu img.x-menu-item-icon.open_book,
.x-menu.x-menu-floating img.x-menu-item-icon.open_book {
    -webkit-mask-image: var(--icon-book-open) !important;
            mask-image: var(--icon-book-open) !important;
}

.x-menu img.x-menu-item-icon.open_folder,
.x-menu.x-menu-floating img.x-menu-item-icon.open_folder {
    -webkit-mask-image: var(--icon-folder-open) !important;
            mask-image: var(--icon-folder-open) !important;
}

.x-menu img.x-menu-item-icon.open_all,
.x-menu.x-menu-floating img.x-menu-item-icon.open_all {
    -webkit-mask-image: var(--icon-external-link) !important;
            mask-image: var(--icon-external-link) !important;
}


/* The filtered-column header treatment lives in `ext-acs-theme.css`, which paints the
   funnel as an SVG mask via `::before` and clears this legacy background. This file
   loads after the theme, so the old `filtered-column.png` rule that used to sit here
   won that cascade tie on order and drew a second funnel under the themed one. */

.clear_grid_filters {
	background-image:url(/static/images/libraryswitcher.png) !important; background-position: 0 -288px !important;
}

/*Styles for TOC in common grid*/

.grid_toc {
	padding: 8px 20px 20px 2px;
}

.grid_toc * {
	background-color: inherit !important;
}

.grid_toc span.flange {
	color: black;
	font-size: 13px;
	vertical-align: baseline;
    font-weight: bold;
}

.grid_toc .x-tree-root-ct > li > div > a > span {
   font-weight: bold;
}

.grid_toc .flangeToc:hover span.flange {
	color: #1A53A1;
	text-decoration: underline;
}

.grid_toc  .flangeToc img {
    background: transparent no-repeat 0 0;
    background-image: url("/tg_widgets/acs/extJS_3_4_1_1/resources/images/azzurra-legacy/tree/arrows.gif");
}

.common-grid-panel .x-grid3-row-over {
	background: inherit;
}

/** book_shelf_panel **/

.book_shelf_panel div.x-panel-body {
  background-color: transparent;
}

.book_shelf_panel label.x-form-item-label {
  left: 35px;
}

.book_shelf_panel label.x-form-cb-label {
  margin-left: 7px;
  outline-style: none;
}

.book_shelf_panel form.x-panel-body .x-form-element {
  left: -110px;
}

.book_shelf_panel form.x-panel-body .x-btn {
  padding-top: 15px;
  padding-left: 15px;
}

.book_shelf_panel form.x-panel-body.x-form {
  background-color: transparent;
  color: #ffffff;
  font-size: 16px;
  opacity: 0.9;
  -moz-opacity: 0.9;
}

.book_shelf_panel form.x-panel-body.x-form .x-form-item label {
  font-size: 13px;
  opacity: 0.7;
  -moz-opacity: 0.7;
}

/* Big Icon Styles*/
.book-icon .book-mask, .book-icon img {
	top: 1px; 
	left: 1px; 
	z-index: 0;
	float: left; 
	position: relative;
	border: 0; 
}

.book-icon .book-mask {
	overflow: hidden;
	width: 46px;
	height: 72px;
	top: 0px;
}


.book-icon {
	float: left; 
	position: relative; 
	width: 58px; 
	height: 76px; 
	margin: 0px 0px 10px 50px;
}

.book-icon .book-cover {
	float: left; 
	position: absolute; 
	top: 0; 
	left: 0; 
	width: 58px; 
	height: 76px; 
	background: url("/static/images/book_cover.png"); 
	z-index: 1;
}

.book-icon.folder, .book-icon.book {
	background: none !important;
}

.book-icon.folder .book-cover {
	background: url("/static/images/folder_cover.png"); 
}

.ext-ie6 .book-icon .book-cover {
	background: url("/static/images/book_cover.gif");
}

.ext-ie6 .book-icon.folder .book-cover {
	background: url("/static/images/folder_cover.png");
}

.x-grid3-row-commonview .x-component-libiconel a {
	display: none;
} 

.x-grid3-row-commonview .book-icon {
	margin: 0px;
}

.x-grid3-row-commonview .x-component-libiconel:hover, 
.x-grid3-row-commonview .x-component-libiconel {
	background-color: inherit;
	border: none;
	padding: 0px;
	width: auto;
}

.x-grid3-cell-first .x-grid3-cell-inner {
	padding-left: 8px !important;
}

.x-grid3 .x-grid3-row,
.x-grid3 .x-grid3-row:last-child {
  border-color: #d6d6d;
  border-bottom-width: 1px;
  border-top-width: 0px;
}

.icon-view-panel {
  padding: 2px 0px 0px 2px;
}



/*Styles for toolbar Title*/

.toolbar-title, .toolbar-title span {
  padding: 3px 0px 4px 10px !important;
  color: #231F20;
  font-weight: bold !important;
  font-size: 16px !important;
  font-family:tahoma,arial,helvetica,sans-serif !important;
}

.toolbar-counter {
	font-size: 13px;
	color: #5c7297;
}

div.x-toolbar-bookshelf table.x-toolbar-ct {
  margin-top: -3px;
}

div.x-toolbar-bookshelf .x-toolbar-left table {
  margin-top: 3px;
}

/* multiline for common grid rows*/
.common-grid-panel .x-grid3-cell-inner {
 overflow:hidden;
 padding:3px 3px 3px 5px;
 white-space:normal;
}

/* fix heght li elements */
div.autoHeight li.x-menu-date-item,
ul.x-menu-list li.x-menu-list-item.autoHeight {
  height: auto;
}

/* ===== ADVANCED LIBRARY SEARCH PANEL ===== */
/* Floating panel that appears below search field with "Search Library" / "Search Folder" options */
.advancedLibSearch {
    background: #fff !important;
    border: 1px solid #DCE2EF !important;
    border-radius: 6px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    overflow: hidden !important;
}

/* Remove ExtJS panel styling */
.advancedLibSearch .x-panel-bwrap,
.advancedLibSearch .x-panel-body {
    background: #fff !important;
    border: none !important;
    border-radius: 6px !important;
}

.advancedLibSearch .x-panel-body {
    padding: 8px 12px !important;
    font-size: 13px;
}

.advancedLibSearch .x-form-check-wrap {
    width: auto !important;
    height: auto !important;
    padding: 4px 0 !important;
}

/* Radio button styling */
.advancedLibSearch .x-form-radio-wrap {
    display: flex !important;
    align-items: center !important;
}

/* Radio button label styling */
.advancedLibSearch .x-form-cb-label {
    color: #1c2127 !important;
    font-size: 13px !important;
    cursor: pointer !important;
}

.advancedLibSearch .x-form-check-wrap:hover .x-form-cb-label {
    color: #00aeef !important;
}

.background {
  background-color: #FFFFFF
}

.chat-history-placeholder {
    background: center / contain no-repeat url(/static/images/placeholder-list.png);
    width: 100%;
    height: 400px;
    margin: 30px 0 20px;
}

.placeholder-text {
    color: #676767;
    font-size: 11px;
    text-align: center;
    background-color: rgb(255 255 255);
    position: absolute;
    top: 223px;
    left: 50%;
    width: 190px;
    margin-left: -95px;
}

.placeholder-title {
    font-weight: bold;
    margin-bottom: 10px;
}


/* =============================================
   SEARCH ACCORDION CONTENT STYLING (S2)
   Option 2: Visual harmony without breaking ExtJS layout

   Strategy:
   - Colors, borders, border-radius for visual consistency
   - Use SVG icons from theme-icons.css
   - Minimal layout changes to avoid breaking ExtJS

   Colors from mock (see THEME_GUIDE.md Section 1.0):
   - #F6F8FB: Input background (light gray)
   - #DCE2EF: Input/fieldset borders (Affini Cloud)
   - #00aeef: Focus/accent color (brand cyan)
   - #5a6370: Label text (secondary)
   - #1c2127: Input text (primary)

   Scoped to to prevent bleeding
   ============================================= */

/* ===== SEARCH PANEL CONTAINER ===== */
/* =============================================
   THEME FORM COMPONENTS — page-wide
   Fieldsets, inputs, combos, triggers, checkboxes,
   radios, labels. Phase 4 stripped the .acs-startpage
   gate; these now apply shell-wide via the file's
   load-scoping (only view_startpage.html includes it).
   ============================================= */

/* --- Fieldsets --- */
.x-fieldset {
    border: none !important;
    border-radius: 0 !important;
    margin: 0 0 4px 0 !important;
    padding: 0 6px !important;
    box-sizing: border-box !important;
}

/* Nested fieldsets: no extra padding (only top-level gets padding) */
.x-fieldset .x-fieldset-noborder,
.x-fieldset .x-fieldset {
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: content-box !important;
}

.x-fieldset legend {
    color: #5a6370 !important;
    font-weight: 600 !important;
    font-size: 11px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 8px 8px 6px 8px !important;
    margin-bottom: 8px !important;
    border-bottom: 1px solid #ECF0F6 !important;
    display: block !important;
}

.x-fieldset .x-fieldset-noborder legend {
    display: none !important;
}

/* --- Text inputs — page-wide base ---
   Moved to ext-acs-theme.css during Phase 2 of the theme refactor
   (THEME_REVIEW.md §4.3 Phase 2). Now applies shell-wide. */

/* Form-text 32px geometry consolidated onto the page-wide `.x-form-text`
   rule in ext-acs-theme.css during Phase 3 PR 3.3 (THEME_REVIEW.md §4.3).
   Closes the SHELL_TECH_DEBT entry "Phase 2 surfaced visual gaps on
   non-startpage form inputs" — admin/viewer ExtJS inputs now match
   dialog inputs at 32px instead of native ~21px. */

/* --- Combo wrappers in dialogs — flex layout ---
   Same pattern as search accordion Modifier/Include combos,
   adapted for full-size inputs. Triggers sit flush right.
   Excludes .operator-wrap which needs ExtJS native sizing. */






/* Superbox wrap in dialogs — match 32px height */




/* Operator-wrap in dialogs: keep ExtJS sizing, just add border-box */


/* --- Metadata filter operator in dialogs ---
   The operator dropdown (=, ≠, etc.) sits next to a 32px value field.
   Match the height so both align. The operator-wrap and its contents
   stretch to fill. */




/* Superbox grid in dialogs — match dialog operator width (50px + 5px margin = 55px).
   The hbox operators render at their configured 50px; grid operators need the
   same: width 50px + margin 5px = 55px column (ext-acs-theme.css). */






/* --- Radio alignment in dialogs — fix ExtJS absolute positioning --- */




/* Radio horizontal layout and check-wrap alignment for dialogs
   are handled in the "DIALOG FORM" section below. */

/* --- Page-wide form chrome ---
   Moved to ext-acs-theme.css during Phase 2 of the theme refactor
   (THEME_REVIEW.md §4.3 Phase 2). Now applies shell-wide to:
     .x-form-text (+ :focus), .x-form-invalid, .x-form-item-label,
     .x-form-field-wrap (+ nested .x-form-text), .x-form-trigger
     (+ :hover, date/clear variants), .x-form-checkbox (+ states),
     .x-form-radio (+ states), .x-form-cb-label,
     .x-form-radio-group .x-form-check-wrap (+ .x-form-cb-label).

   Dialog-scoped overrides above (`.x-window .x-form-*`) were
   migrated by Phase 3's dialogs/popups PR and now apply shell-wide
   via ext-acs-theme.css. */

/* Tab panel rules moved to ext-acs-theme.css during Phase 3 PR 3.1
   (THEME_REVIEW.md §4.3). Now applies shell-wide. */


/* =============================================
   SEARCH PANEL (col-1 sidebar) — compact overrides
   Space-constrained layout-specific rules only.
   Theme colors/appearance inherited from page-wide
   form component rules above.
   ============================================= */

/* (Note: no `.search_panel { background: #fff }` override
   here — the form surface inherits `--sp-surface` from `.tree-twocol-tree`
   so the col-1 tint matches the other col-1s. Form fields stay white via
   their own `.x-form-text` styling.) */

/* --- Compact form geometry for the col-1 sidebar search (Bucket-B) ---
   The page-wide `.x-form-text` rule in `ext-acs-theme.css` enforces the
   canonical 32px geometry (padding 8px 12px, height 32px, line-height 14px,
   border-box) for shell-wide form inputs. That geometry is too large for
   the col-1 sidebar search view (~280–440px wide), where ExtJS HBox layout
   precomputed inline widths for compact ~25px inputs — forcing 32px /
   8px-12px padding here collapses operator combos and overflows the rows.

   This block applies a compact 25px geometry scoped to the search panel,
   with the trimmings needed to play well with the surrounding cascade
   (page-wide `.x-form-field-wrap` chrome, `.search-wrap` flex layout from
   azzurra-legacy.css:3719, the `.x-superboxselect` chip-list, and the
   `.operator-field` symbol-input).

   Tracked tech debt; will be replaced wholesale when this view is rebuilt
   per `docs/welcome_page/mocks/mock_library_navbar_proposal.html`. */

/* Compact 25px input geometry. `:not(.x-superboxselect)` excludes the
   multi-select chip list which shares the `.x-form-text` class but needs
   to grow vertically when chips wrap (Region / Document Type).
   line-height: 23 = height(25) - vertical-padding(2). Tightening the line
   box to the content area vertically centres single-line text in the
   25px input. Previously 21px which floated the text ~1px above centre. */
.search_panel .x-form-text:not(.x-superboxselect) {
    padding: 1px 6px !important;
    height: 25px !important;
    line-height: 23px !important;
    box-sizing: border-box !important;
}

/* `.operator-field` (the small symbol input next to the chevron) needs
   enough room to show 2-character operators (`!~`, `!=`, `<=`, `>=`).
   ExtJS HBox sets the input to ~21px which crops 2-char ops. The grid
   layout on superbox rows sets the operator-wrap to 40px; widen both
   so 2-char operators stay visible across all metadata-filter rows.
   `:where()` keeps specificity flat against the page-wide
   `.x-form-text:not(.x-superboxselect)` block above so this rule wins. */
.search_panel :where(.operator-field) {
    padding: 1px 2px !important;
    text-align: center !important;
    width: 28px !important;
    min-width: 28px !important;
}

/* `.search-wrap`, `.date-wrap`, `.boolean-wrap` are `display: flex` with
   `width: 100%` (azzurra-legacy.css:3722). Make the inner input shrink
   to leave room for the trigger button — without this the input's
   ExtJS-set inline width takes 100% of the wrap and pushes the trigger
   outside the wrap's right edge. The theme's default `flex: 0 0 auto`
   on `.x-form-text` is correct for compliance/inline-flex combos but
   wrong for these full-width flex wraps. */
.search_panel .search-wrap .x-form-text,
.search_panel .date-wrap .x-form-text,
.search_panel .boolean-wrap .x-form-text {
    flex: 1 1 0% !important;
    min-width: 0 !important;
    width: auto !important;
}

/* Combo trigger (chevron) fills the wrap vertically. Without this rule,
   the natively-sized 23px trigger leaves a ~2-4px empty strip at the
   bottom of the 27px wrap (wrap = 1px border + 25px input + 1px border). */
.search_panel .x-form-field-wrap .x-form-arrow-trigger,
.search_panel .x-form-field-wrap .x-form-trigger {
    height: 25px !important;
}


/* `.superbox-wrap` (Region, Document Type) houses a `.x-superboxselect`
   chip-list that grows when chips are added. Pin the wrap to 25px for
   the empty/single-line state to match the rest of the column, but let
   it grow vertically when content overflows. */
.search_panel .superbox-wrap {
    min-height: 25px !important;
    height: auto !important;
}

/* Align the Region / Document Type rows (CSS-grid layout via
   `.x-box-inner.superbox-container`) with the rest of the metadata
   rows (ExtJS hbox layout — operator 50px + 5px margin + value 191px
   + button 26px = 272px total). Mirror via grid by baking the 5px
   operator gap into cell-1's width (55px = 50px operator + 5px
   trailing space); column-gap stays 0 between cell-2 (value) and
   cell-3 (button) to match hbox where the button sits flush against
   the value field. The right column is 26px on grid rows even though
   the actual element is an invisible `.add-empty-btn` placeholder
   (see L2422); the width is purely about column alignment. */
.search_panel .x-box-inner.superbox-container {
    grid-template-columns: 55px 1fr 26px !important;
    column-gap: 0 !important;
}

.search_panel .x-box-inner.superbox-container .operator-wrap {
    width: 50px !important;
    margin-right: 0 !important;
}

/* Combo wrapper — search panel uses compact 25px geometry (not the 32px
   theme default). Override wrap height to match the input's 25px so the
   trigger button doesn't overflow vertically. */
.search_panel .x-form-field-wrap {
    overflow: visible !important;
    height: 25px !important;
}

/* Every metadata-filter row keeps the same 26px height: the date wrap counts
   its border inside the 25px like the operator wrap beside it, and the
   invisible placeholder on the Region / Document Type rows matches the 26px
   add button instead of the dialog's 32px. */
.search_panel .x-form-field-wrap.date-wrap {
    box-sizing: border-box !important;
}
.search_panel .metadata-filters .add-empty-btn {
    height: 26px !important;
}

/* Region / Document Type grow with their chips, as in the Save Search
   dialog; the 25px wrap height above would otherwise hide every chip line
   after the first. */
.search_panel .x-form-field-wrap.superbox-wrap,
.search_panel .superbox-wrap .x-superboxselect,
.search_panel .x-box-inner.superbox-container {
    height: auto !important;
}
.search_panel .superbox-wrap .x-superboxselect {
    min-height: 23px !important;
}

/* Compact combo wrappers — flex layout for tight space.
   Modifier and Include combos need full-width flex. */
.search_panel .x-form-field-wrap:has(#search_modifier),
.search_panel .x-form-field-wrap:has(#filter_type) {
    width: 100% !important;
    box-sizing: border-box !important;
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
}

.search_panel .x-form-field-wrap:has(#search_modifier) .x-form-text,
.search_panel .x-form-field-wrap:has(#filter_type) .x-form-text {
    flex: 1 1 0% !important;
    width: 0 !important;
    min-width: 0 !important;
}

.search_panel .x-form-field-wrap:has(#search_modifier) .x-form-trigger,
.search_panel .x-form-field-wrap:has(#filter_type) .x-form-trigger {
    position: relative !important;
    flex: 0 0 auto !important;
    order: 3 !important;
}

/* Search text field wrapper — border-box to prevent trigger cropping */
.search_panel .search-wrap {
    box-sizing: border-box !important;
}

/* Standalone checkbox: align with input column (145px label width) */
.search_panel .x-form-check-wrap {
    padding-left: 145px !important;
}

.search_panel .x-form-radio-group .x-form-check-wrap {
    padding-left: 0 !important;
}

/* Override ext-acs-widgets rules that break flex alignment in search-for radios.
   Page-wide — applies in search accordion and dialogs. */
.search-for .x-form-element .x-form-radio {
    position: relative !important;
    top: auto !important;
}

.search-for .x-form-element .x-form-cb-label {
    padding: 0 !important;
    width: auto !important;
    line-height: 16px !important;
}

/* ===== BUTTON CONTAINER ===== */
/* Top separator + right-alignment. Matches OF form-actions pattern.
 *
 * The Search (solid) and Reset (outline) buttons below implement the
 * primary / secondary variants documented in
 * docs/theme/THEME_GUIDE.md §6.10 — mirrors of the Angular mixins
 * acs-btn-primary / acs-btn-outline in shared-theme/scss/_buttons.scss
 * but applied via ExtJS selectors + --sp-* CSS vars. Keep hover colors
 * in lockstep with those mixins when editing (muted → deep for Search,
 * cyan-wash background for Reset). */
.search_panel .x-panel.x-panel-noborder:has(.search-btn) > .x-panel-bwrap > .x-panel-body {
    border-top: 1px solid #DCE2EF !important;
    padding: 8px 4px 4px 4px !important;
    box-sizing: border-box !important;
    text-align: right !important;
}

/* Auto-width buttons with min-width so they don't collapse too small.
   Geometry matches Kendo k-button-md (chat-bot "Start new chat") */
.search_panel .search-btn,
.search_panel .reset-btn {
    width: auto !important;
    min-width: 80px !important;
}

.search_panel .reset-btn {
    margin-right: 8px !important;
}

/* ===== SEARCH & RESET BUTTONS - Shared ===== */
/* Hide ExtJS 9-slice table border rows and side cells for clean centering */
.search_panel .search-btn .x-btn-tl,
.search_panel .search-btn .x-btn-tc,
.search_panel .search-btn .x-btn-tr,
.search_panel .search-btn .x-btn-bl,
.search_panel .search-btn .x-btn-bc,
.search_panel .search-btn .x-btn-br,
.search_panel .search-btn .x-btn-ml,
.search_panel .search-btn .x-btn-mr,
.search_panel .reset-btn .x-btn-tl,
.search_panel .reset-btn .x-btn-tc,
.search_panel .reset-btn .x-btn-tr,
.search_panel .reset-btn .x-btn-bl,
.search_panel .reset-btn .x-btn-bc,
.search_panel .reset-btn .x-btn-br,
.search_panel .reset-btn .x-btn-ml,
.search_panel .reset-btn .x-btn-mr {
    display: none !important;
}

.search_panel .search-btn .x-btn-mc,
.search_panel .reset-btn .x-btn-mc {
    background-image: none !important;
    padding: 0 !important;
}

/* Button element: border-box, vertical padding only (table width handles horizontal),
   height:auto so padding expands the element for proper vertical centering */
.search_panel .search-btn button,
.search_panel .reset-btn button {
    box-sizing: border-box !important;
    height: auto !important;
    padding: 6px 12px !important;
    line-height: 1.2 !important;
    cursor: pointer !important;
    border: none !important;
    background: transparent !important;
    text-align: center !important;
    font-size: 13px !important;
}

/* ===== SEARCH BUTTON ===== */
/* Primary — mirrors acs-btn-primary (THEME_GUIDE §6.10): muted → deep teal, flat */
.search_panel .search-btn {
    background: #0e8bb0 !important;
    border: 1px solid #0e8bb0 !important;
    border-radius: 4px !important;
    box-shadow: none !important;
    margin-top: 0 !important;
    padding: 0 !important;
}

/* Step-7 prep: search icon via ::before pseudo so the parent's
   "Search" label renders untouched. Icon always white on the deep-teal
   primary button. */
.search_panel .search-btn .x-btn-text {
    position: relative !important;
    color: #fff !important;
    font-weight: 500 !important;
    font-size: 13px !important;
    padding-left: 20px !important;
    padding-right: 6px !important;
    background-image: none !important;
}

.search_panel .search-btn .x-btn-text::before {
    content: '' !important;
    position: absolute !important;
    left: 2px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 14px !important;
    height: 14px !important;
    -webkit-mask-image: var(--icon-search) !important;
            mask-image: var(--icon-search) !important;
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: #fff !important;
    pointer-events: none !important;
}

.search_panel .search-btn:hover,
.search_panel .search-btn.x-btn-over {
    background: #0a6f8c !important;
    border-color: #0a6f8c !important;
    box-shadow: none !important;
}

.search_panel .search-btn:active,
.search_panel .search-btn.x-btn-click {
    background: #0a6f8c !important;
    box-shadow: none !important;
}

/* ===== RESET BUTTON ===== */
/* Secondary — mirrors acs-btn-outline (THEME_GUIDE §6.10): muted-teal outline */
.search_panel .reset-btn {
    background: transparent !important;
    border: 1px solid #0e8bb0 !important;
    border-radius: 4px !important;
    box-shadow: none !important;
    margin-top: 0 !important;
    padding: 0 !important;
}

/* Step-7 prep: refresh icon via ::before pseudo. bg-color:
   currentColor so the icon tracks the muted-teal text colour
   automatically across rest/hover. */
.search_panel .reset-btn .x-btn-text {
    position: relative !important;
    color: #0e8bb0 !important;
    font-weight: 500 !important;
    font-size: 13px !important;
    padding-left: 20px !important;
    padding-right: 6px !important;
    background-image: none !important;
}

.search_panel .reset-btn .x-btn-text::before {
    content: '' !important;
    position: absolute !important;
    left: 2px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 14px !important;
    height: 14px !important;
    -webkit-mask-image: var(--icon-refresh) !important;
            mask-image: var(--icon-refresh) !important;
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: currentColor !important;
    pointer-events: none !important;
}

.search_panel .reset-btn:hover,
.search_panel .reset-btn.x-btn-over {
    background: #f0f8fc !important;
    border-color: #0e8bb0 !important;
    box-shadow: none !important;
}

.search_panel .reset-btn:hover .x-btn-text,
.search_panel .reset-btn.x-btn-over .x-btn-text {
    color: #0e8bb0 !important;
}

.search_panel .reset-btn:active,
.search_panel .reset-btn.x-btn-click {
    background: #e3eef3 !important;
    box-shadow: none !important;
}

/* ===== BROWSE BUTTON (folder tree icon) — page-wide ===== */
/* Used next to "Search in:" field in both search accordion and dialogs.
   Rest + hover: transparent on the outer .x-btn table (the inner
   .x-btn-text gets the circular cyan-wash hover via the rule further down).
   Specificity bumped to .acs-new-theme .x-btn.browse-btn.x-btn-over (0,4,0)
   to beat .acs-new-theme .x-btn.x-btn-over:not(.reset-btn) (0,4,0) which
   would otherwise paint deep-cyan-fill on the outer table. Same-spec, so
   source-order wins — this rule lives after theme.css. */
.browse-btn,
.browse-btn button,
.browse-btn .x-btn-center,
.browse-btn .x-btn-mc {
    background-color: transparent !important;
    background-image: none !important;
    border: none !important;
}
.acs-new-theme .x-btn.browse-btn.x-btn-over,
.acs-new-theme .x-btn.browse-btn:hover {
    background: transparent !important;
    background-color: transparent !important;
    border-color: transparent !important;
}

/* Step-7 prep: icon-only circular buttons. Two channels on hover —
   container 10% cyan wash + icon-fill flip (grey -> cyan, except
   add-filter which stays cyan). Use ::before pseudo so each channel
   lives on its own element. */
.browse-btn .x-btn-text {
    position: relative !important;
    background-image: none !important;
    min-width: 20px !important;
    min-height: 20px !important;
    border-radius: 50% !important;
    cursor: pointer !important;
}

.browse-btn .x-btn-text::before {
    content: '' !important;
    position: absolute !important;
    inset: 0 !important;
    -webkit-mask-image: var(--icon-folder-tree) !important;
            mask-image: var(--icon-folder-tree) !important;
    -webkit-mask-size: 18px 18px !important;
            mask-size: 18px 18px !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
    pointer-events: none !important;
}

.browse-btn:hover .x-btn-text,
.browse-btn.x-btn-over .x-btn-text {
    background-color: rgba(0, 174, 239, 0.1) !important;
    border-radius: 50% !important;
}

.browse-btn:hover .x-btn-text::before,
.browse-btn.x-btn-over .x-btn-text::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* ===== ADD FILTER BUTTONS (+) — page-wide ===== */
/* SVG plus icon — used in metadata filter rows (search accordion + dialogs).
   Always-cyan affordance preserved: the rest icon paints in brand-cyan, and
   hover only adds the container wash (no icon-color change). */
.add-filter-btn,
.add-filter-btn button,
.add-filter-btn .x-btn-center,
.add-filter-btn .x-btn-mc {
    background-color: transparent !important;
    background-image: none !important;
    border: none !important;
}

.add-filter-btn .x-btn-text {
    position: relative !important;
    background-image: none !important;
    min-width: 20px !important;
    min-height: 20px !important;
    border-radius: 50% !important;
    cursor: pointer !important;
}

.add-filter-btn .x-btn-text::before {
    content: '' !important;
    position: absolute !important;
    inset: 0 !important;
    -webkit-mask-image: var(--icon-plus) !important;
            mask-image: var(--icon-plus) !important;
    -webkit-mask-size: 18px 18px !important;
            mask-size: 18px 18px !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: var(--acs-brand-cyan, #00aeef) !important;
    pointer-events: none !important;
}

.add-filter-btn:hover .x-btn-text,
.add-filter-btn.x-btn-over .x-btn-text {
    background-color: rgba(0, 174, 239, 0.1) !important;
}

/* ===== REMOVE FILTER BUTTONS (x) — page-wide ===== */
.remove-filter-btn,
.remove-filter-btn button,
.remove-filter-btn .x-btn-center,
.remove-filter-btn .x-btn-mc {
    background-color: transparent !important;
    background-image: none !important;
    border: none !important;
}

.remove-filter-btn .x-btn-text {
    position: relative !important;
    background-image: none !important;
    min-width: 20px !important;
    min-height: 20px !important;
    border-radius: 50% !important;
    cursor: pointer !important;
}

.remove-filter-btn .x-btn-text::before {
    content: '' !important;
    position: absolute !important;
    inset: 0 !important;
    -webkit-mask-image: var(--icon-x) !important;
            mask-image: var(--icon-x) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
    pointer-events: none !important;
}

.remove-filter-btn:hover .x-btn-text,
.remove-filter-btn.x-btn-over .x-btn-text {
    background-color: rgba(0, 174, 239, 0.1) !important;
}

.remove-filter-btn:hover .x-btn-text::before,
.remove-filter-btn.x-btn-over .x-btn-text::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* ===== EMPTY BUTTON (placeholder for rows without add capability) ===== */
.add-empty-btn {
    visibility: hidden !important;
    width: 20px !important;
}

/* ===== METADATA FILTER ROW ALIGNMENT — page-wide ===== */
/* Operator-wrap: border-box so our added border fits within ExtJS/grid column width */


/* Superbox rows use CSS Grid (from azzurra-legacy) while other rows use flex.
   Flex rows: operator(52px) + margin-right(5px) + value(170px) + button(26px) = 253px
   Grid equivalent: first column 57px (52px operator + 5px margin), value 1fr, button 26px.
   align-items:start prevents operator from stretching when superbox grows vertically. */


/* Operator in superbox grid rows: 52px + 5px margin = 57px grid cell */


/* Superbox-wrap: keep wrapper border (houses superbox + trigger), border-box for grid fit */


/* Hide the wrapper's combo trigger — the superbox has its own expand button inside */


/* ===== SUPERBOX SELECT (Multi-select tags) ===== */
/* ===== SUPERBOX SELECT — page-wide ===== */
/* Border is on the wrapper (.superbox-wrap), not on the superbox itself */
.x-superboxselect {
    background: transparent !important;
    border: none !important;
}

/* Input inside superbox - transparent to match container */
.x-superboxselect-input {
    background: transparent !important;
}

.x-superboxselect-input input {
    background: transparent !important;
    border: none !important;
}

/* Selected tags in superbox */
.x-superboxselect-item {
    background: #E6F5FB !important;
    border: 1px solid #B8E0F0 !important;
    border-radius: 4px !important;
    color: #0e8bb0 !important;
}

/* Tag close button - use x icon. Phase 6 mask-image migration. */
.x-superboxselect-item-close {
    -webkit-mask-image: var(--icon-x) !important;
            mask-image: var(--icon-x) !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-size: 10px 10px !important;
            mask-size: 10px 10px !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.x-superboxselect-item-close:hover {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Step-7 prep: superbox triggers carry the same two-channel hover
   pattern as the search-panel circular buttons — container 10% wash
   plus icon flip. ::before pseudo separates them. */
.x-superboxselect-btn-clear {
    position: relative !important;
    background-image: none !important;
}

.x-superboxselect-btn-clear::before {
    content: '' !important;
    position: absolute !important;
    inset: 0 !important;
    -webkit-mask-image: var(--icon-x) !important;
            mask-image: var(--icon-x) !important;
    -webkit-mask-size: 12px 12px !important;
            mask-size: 12px 12px !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
    pointer-events: none !important;
}

.x-superboxselect-btn-clear:hover,
.x-superboxselect-btn-clear.x-superboxselect-btn-over {
    background-color: rgba(0, 174, 239, 0.1) !important;
    border-radius: 50% !important;
}

.x-superboxselect-btn-clear:hover::before,
.x-superboxselect-btn-clear.x-superboxselect-btn-over::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Superbox expand button — SVG chevron-down icon */
.x-superboxselect-btn-expand {
    position: relative !important;
    background-image: none !important;
}

.x-superboxselect-btn-expand::before {
    content: '' !important;
    position: absolute !important;
    inset: 0 !important;
    -webkit-mask-image: var(--icon-chevron-down) !important;
            mask-image: var(--icon-chevron-down) !important;
    -webkit-mask-size: 12px 12px !important;
            mask-size: 12px 12px !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
    pointer-events: none !important;
}

.x-superboxselect-btn-expand:hover,
.x-superboxselect-btn-expand.x-superboxselect-btn-over {
    background-color: rgba(0, 174, 239, 0.1) !important;
    border-radius: 50% !important;
}

.x-superboxselect-btn-expand:hover::before,
.x-superboxselect-btn-expand.x-superboxselect-btn-over::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Combo dropdown list (.x-combo-list and descendants) moved to
   ext-acs-theme.css so it applies on every page — combos render in
   document body outside any container scope, and they appear in
   non-startpage views (compliance admin, user admin, audit, etc.). */

/* Date-picker rules (.x-date-picker and descendants) moved to
   ext-acs-theme.css during Phase 3 PR 3.2 (THEME_REVIEW.md §4.3).
   Now applies shell-wide. */

/* =============================================
   UNIVERSAL DIALOG / MODAL THEME
   Applies shell-wide to ALL ExtJS windows post-Phase-4
   (THEME_REVIEW.md §4.3 Phase 4 stripped the gate):
   - acs.Msg (newAlert / newConfirm)
   - Ext.MessageBox / Ext.Msg (x-window-dlg)
   - Ext.Window (any custom window)
   - Session expiration dialogs
   ============================================= */

/* --- Window chrome: rounded, shadow, white bg --- */


/* --- 9-slice frame removal (universal) --- */


/* --- Content area --- */


/* --- Header --- */




/* --- Tool buttons — kill azzurra background-color on hover ---
   azzurra-legacy sets .x-tool:hover { background-color: #b7bec5 }
   and .x-window .x-tool:hover { background-color: #c5cbd0 }.
   Override with transparent for all tool buttons in dialogs. */
.x-window .x-tool {
    background-color: transparent !important;
}


/* --- Close button (theme x icon) --- */




/* --- Maximize / Minimize / Restore tool buttons ---
   ExtJS 3.x adds x-tool-{id}-over class on mouseover,
   so we target both :hover and the -over class.
   Phase 6 mask-image migration. */
.x-window .x-tool-maximize {
    -webkit-mask-image: var(--icon-maximize) !important;
            mask-image: var(--icon-maximize) !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    opacity: 0.6 !important;
}











/* --- Window body --- */


/* acs.Msg body — ExtJS sets tight inline height that clips text.
   Override with min-height and allow overflow for content to breathe. */


/* --- Footer / button bar ---
   ExtJS renders footer in three variants depending on baseCls:
   - .x-panel-footer (standard panels/forms)
   - .x-window-footer (Ext.Window with buttons)
   - .x-plain-footer (panels with baseCls:'x-plain', e.g. JobWizard) */








/* --- 9-slice removal on dialog footer/button-bar buttons ---
   Scoped to footer areas only to avoid bleeding into content buttons
   (search/reset in accordion, browse buttons, etc.).
   Covers: .x-panel-footer, .x-window-footer, .x-panel-btns, .x-window-dlg,
   and acs.Msg (.newAlert) button classes. */




/* --- Default button styling (secondary) ---
   Scoped to dialog footer areas only — does NOT affect content buttons
   (search/reset, browse, add-filter, etc. in the accordion/panels).
   Phase 4 dropped the historical bodyspecificity bump;
   button rules now live shell-wide in ext-acs-theme.css. */










/* --- Primary button (OK / Yes / Accept) ---
   Must beat both azzurra (0,5,0) AND our own secondary footer rules (0,5,1).
   Routes through footer containers for (0,6,1) specificity.
   Applied to known primary-action classes within any dialog. */








/* --- Secondary / cancel button hover overrides --- */


/* --- Disabled state for all dialog buttons ---
   ExtJS adds .x-item-disabled when formBind disables a button.
   Primary buttons get a muted appearance; no hover effect. */












/* --- Details button (tertiary — transparent bg) --- */




/* --- Ext.MessageBox / Ext.Msg (x-window-dlg) ---
   Handles native ExtJS dialogs: confirm, alert, prompt, progress.
   The first button in Ext.Msg (OK/Yes) gets primary styling via
   the x-toolbar-cell:last-child selector since Ext renders
   the primary button last in the footer. */












/* Ext.Msg body text */


/* Ext.Msg text input (for prompt dialogs) */
/* Ext.Msg text input/textarea — inherits base colors from page-wide
   .x-form-text rule; only needs full-size padding + height override. */






/* Ext.Msg progress bar */






/* Text inside the blue bar (clipped to bar width) — white */


/* Text behind the bar (full width, on white bg) — dark */


/* --- Checkbox styling (universal for any dialog) --- */












/* Loader & overlay-mask rules (.ext-el-mask, .ext-el-mask-msg,
   .x-mask-loading, .loading-indicator, .x-tree-node-loading,
   .x-grid-row-loading, @keyframes acs-spin) moved to ext-acs-theme.css
   during Phase 3 PR 3.1 (THEME_REVIEW.md §4.3). Now applies shell-wide. */

/* =============================================
   DIALOG TREE PANELS — universal
   Tree panel styling for all dialogs (Search-In,
   Save Search permissions, etc.). SVG folder icons,
   chevron expand/collapse, hover/selected states.
   ============================================= */

/* Tree panel — clean border */


/* Tree node text */


/* Tree node hover */


/* Tree node selected — light bg only, no border-left accent in dialogs */






/* Tree folder icons */




/* Tree connection lines and expand/collapse chevrons are handled
   by page-wide rules in the TREE EXPAND/COLLAPSE section above. */

/* Search-In dialog — panel body border (specific to folder picker layout).
   ExtJS sizes the inner panel-body to the window's content area + body
   padding, which overshoots the window's right edge by ~5–6px (the
   window's 9-slice chrome eats into that). The right border then gets
   clipped by the window's overflow:hidden, leaving the panel looking
   like its right edge is missing. Override ExtJS's inline width so the
   panel-body sits inside the window's visible chrome on all sides. */
/* ===========================================================================
   BUCKET B: page-specific dialog variant (Phase 3 PR 3.3 — annotated;
   Phase 4 stripped the `body.acs-startpage` prefix).
   `.x-window.search-in` is the "Search in" picker opened from the startpage
   search panel — a tree-in-dialog used to scope a query to specific folders.
   The `.x-window.search-in` selector itself is unique to this dialog so
   the rules remain effectively page-scoped without the gate.
   =========================================================================== */
.x-window.search-in .x-window-body .x-panel-body {
    border: 1px solid #DCE2EF !important;
    border-radius: 6px !important;
    background: #fff !important;
    box-sizing: border-box !important;
    width: calc(100% - 8px) !important;
    margin-right: 4px !important;
    margin-left: 2px !important;
}
/* Mirror the width cap on the tree panel itself so the inner UL
   doesn't push the body wider than its container. */
.x-window.search-in .x-window-body .x-panel.x-tree {
    box-sizing: border-box !important;
    max-width: calc(100% - 8px) !important;
}


/* =============================================
   acs.Msg (newAlert / newConfirm) — content-specific
   Icon, title, body text, additional components.
   Chrome and buttons handled by universal theme.
   ============================================= */

/* Icon — sits in the west region (32px wide via ExtJS).
   Icon aligns vertically with title's first line (line-height 24px).
   Centered horizontally in the 32px column. */


/* Title text — in the center region, no extra left padding needed
   since the icon is in its own west region. */


/* Body text — in the center region alongside title, no left indent needed. */


/* Additional components area */


/* §3.B.4 follow-up — "Include books from subfolders and categories"
   confirm-dialog checkbox. Drop the ExtJS form-row indent so the box
   sits flush-left with the dialog body text, and let the boxLabel wrap
   cleanly with consistent line-height. Generous top + bottom padding
   on the wrapper so the checkbox is not flush against the dialog body
   text above or the footer separator below. */





/* newAlert footer spacing (headerless dialog uses bottom 9-slice for padding) */




/* =============================================
   DIALOG FORM — layout-specific overrides
   Browse button SVG, folder selector border fix,
   search options spacing.
   ============================================= */

/* Browse button SVG icon is now page-wide (see THEME FORM COMPONENTS section) */

/* --- FolderSelector (Search in) — fix clipped border ---
   CompositeField sets height:25 which clips the wrapper border.
   Override to auto so the themed input can breathe. */


/* --- Search Options fieldset — spacing after checkboxes/radios --- */


/* --- Standalone checkbox alignment in dialogs ---
   Align with input column (ExtJS default label 100px + 5px = 105px) */


/* Reset inside radio groups — radios handle their own layout */


/* --- Radio groups in dialogs — horizontal layout ---
   With columns:3, ExtJS creates 3 .x-column divs inside .x-column-inner.
   Each .x-column has inline width set by ExtJS. Override to flex row. */

/* Outer radio group container — full width */


/* Column inner — flex row to arrange columns horizontally */


/* Each column — auto width, no float */


/* Hide the clear-left divs that force vertical stacking */


/* Each radio .x-form-item: no bottom margin (flex gap handles spacing) */


/* Remove the 105px left indent on radios inside the horizontal group */


/* Hide per-radio empty labels (the fieldset title serves as the group label) */


/* --- Form item spacing in dialogs --- */


/* --- Fieldset spacing in dialogs — 15px between sections --- */


/* Nested fieldsets (Metadata Filters etc.) — same spacing */


/* --- Permission panel padding --- */




/* Inner panel headers inside dialogs — clean white, no blue ExtJS chrome.
   Covers: permission panel "Sharing" header, and any other panel headers
   nested inside dialog windows. */


/* Assign button — primary style (matches Save button) with SVG icon */




/* Remove 9-slice chrome on Assign button */












/* --- Tree checkboxes (input type) — for .x-tree-node-cb --- */








/* --- Tree checkboxes (img type) — for img.x-tree-checkbox ---
   Used by ExtTriStateTreePanel (permissions tree). The <img> gets
   classes: unchecked (base), .x-tree-node-checked, .x-tree-node-grayed.
   Override sprite with inline SVG for all three states. */




/* Checked — cyan bg with white checkmark */


/* Partial/grayed — cyan bg with white dash */


/* ===== S4: BOOKSHELF / BROWSE LIBRARY RESTYLING ===== */
/* Grid headers, rows, toolbar, pagination, view switchers, sort/filter,
   column header menus, filter checkboxes, TOC, Layout menu icons */
/* Scoped to to prevent bleeding to other pages */

/* --- Grid Column Headers --- */
.x-grid3-header {
    background-image: none !important;
    background-color: #f5f7f9 !important;
    overflow: hidden !important;
}

.x-grid3-header-offset {
    background-image: none !important;
    background-color: transparent !important;
}

/* Grid column-header chrome (wash + border + typography + hover + filter
   funnel + menu-trigger button + sort caret) now lives shell-wide in
   ext-acs-theme.css ("Grid column header — shell-wide chrome, typography,
   hover, and filter state"). */

/* --- Grid Column Header Dropdown Menu ---
   Sort/columns/filter/search glyphs and columns-submenu checkbox theming
   for the ExtJS grid column-header dropdown are now shell-wide in
   ext-acs-theme.css (end of file). The chevron-right submenu indicator
   lives in the .x-menu cluster in ext-acs-theme.css (L3275). Removed
   from here 2026-05-15. */

/* Grid body checkbox column appearance reset — applies to <input> cells
   inside .x-grid3, not to the portal-rendered .x-menu. Kept here because
   it's a startpage grid concern. */
.x-menu .x-menu-item-checkbox,
.x-menu .x-grid3-check-col {
    appearance: none !important;
    -webkit-appearance: none !important;
}

/* Bookshelf custom Sort menu — uses iconCls sort_acs_btn / sort_desc_btn
   rather than xg-hmenu-sort-asc/desc. The cyan ::after check on the right
   marks the currently-active sort option in addition to the gutter glyph.
   This is the startpage's own column-toolbar sort menu, NOT the ExtJS grid
   column-header sort items (those use xg-hmenu-sort-asc/desc and are themed
   shell-wide). */
.x-menu li.x-menu-item-checked a.x-menu-item:has(.sort_acs_btn),
.x-menu li.x-menu-item-checked a.x-menu-item:has(.sort_desc_btn) {
    padding-right: 28px !important;
    position: relative !important;
}

.x-menu li.x-menu-item-checked a.x-menu-item:has(.sort_acs_btn)::after,
.x-menu li.x-menu-item-checked a.x-menu-item:has(.sort_desc_btn)::after {
    content: '';
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 14px;
    height: 14px;
    -webkit-mask-image: var(--icon-check);
            mask-image: var(--icon-check);
    -webkit-mask-size: 14px 14px;
            mask-size: 14px 14px;
    -webkit-mask-position: center;
            mask-position: center;
    -webkit-mask-repeat: no-repeat;
            mask-repeat: no-repeat;
    background-image: none;
    background-color: var(--acs-brand-cyan);
}

/* Filter sub-menu text inputs */
/* Menu filter input — compact padding for dropdown context,
   but uses theme border-radius and font-size */
.x-menu .x-form-text {
    border: 1px solid #DCE2EF !important;
    border-radius: 6px !important;
    padding: 4px 8px !important;
    font-size: 12px !important;
    color: #1c2127 !important;
    background-color: #fff !important;
    outline: none !important;
}

.x-menu .x-form-text:focus {
    border-color: #00aeef !important;
    box-shadow: 0 0 0 2px rgba(0, 174, 239, 0.1) !important;
}


/* --- Grid Rows --- */
.x-grid3 .x-grid3-row {
    border-color: #f0f2f5 !important;
    border-bottom-width: 1px !important;
    border-top-width: 0 !important;
    background-color: #fff !important;
}

.x-grid3 .x-grid3-row-alt {
    background-color: #fafbfc !important;
}

.x-grid3 .x-grid3-row-over {
    background-color: #f0f7ff !important;
    border-color: #e2e6ec !important;
}

.x-grid3 .x-grid3-row-selected {
    background-color: #EEF6FB !important;
    border-color: #c8e1f0 !important;
}

/* Grid cells */
.x-grid3-cell-inner {
    color: #1c2127 !important;
    font-size: 13px !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    padding: 6px 6px !important;
    line-height: 1.4 !important;
}

.x-grid3-cell-first .x-grid3-cell-inner {
    padding-left: 10px !important;
}

/* Note: "No" (order_num) column width set to 35px in ext-acs-startpage-libraryViews.js */

/* Grid cell borders — remove vertical separators for cleaner look */
.x-grid3 td {
    border-right: none !important;
}



/* Client name column links */
.x-grid3-td-client_short_name a,
.x-grid3-td-client_name a {
    color: #0e8bb0 !important;
    text-decoration: none !important;
}

.x-grid3-td-client_short_name a:hover,
.x-grid3-td-client_name a:hover {
    color: #00aeef !important;
    text-decoration: underline !important;
}

/* --- Bookshelf Toolbar --- */
/* Bookshelf toolbar — match mock §BROWSE @line 770:
   `min-height: 44px; background: var(--sp-card-bg)`. Buttons centered
   on the vertical (flex align-items center on the toolbar, plus
   vertical-align middle on the legacy table cells inside). */
.x-toolbar-bookshelf {
    background-color: #ffffff !important;
    background-image: none !important;
    border: none !important;
    margin-top: 0 !important;
    padding: 4px 10px !important;
    height: 44px !important;
    min-height: 44px !important;
    max-height: 44px !important;
    box-sizing: border-box !important;
    display: flex !important;
    align-items: center !important;
}

/* Paint the toolbar's bottom border on the wrapping `.x-panel-tbar`
   instead of `.x-toolbar-bookshelf` itself. ExtJS sizes the toolbar
   inline (width = wrapper.clientWidth - frameWidth), so a border on
   the toolbar stops ~10px short of the panel's right edge — visually
   clipped. The wrapper spans the full panel width, so the line runs
   edge-to-edge. */
.x-panel-tbar:has(> .x-toolbar-bookshelf) {
    border-bottom: 1px solid #e2e6ec !important;
}

/* The legacy ExtJS toolbar wraps items in an inner table.x-toolbar-ct
   that reverts to table-block layout. Force it to flex so vertical
   centering on the parent actually applies to all cells. */
.x-toolbar-bookshelf .x-toolbar-ct,
.x-toolbar-bookshelf .x-toolbar-ct > tbody,
.x-toolbar-bookshelf .x-toolbar-ct > tbody > tr,
.x-toolbar-bookshelf .x-toolbar-left,
.x-toolbar-bookshelf .x-toolbar-right {
    height: 100% !important;
    vertical-align: middle !important;
}

.x-toolbar-bookshelf .x-toolbar-cell {
    vertical-align: middle !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

/* Ensure view switcher buttons don't clip at right edge */
.x-toolbar-bookshelf .x-toolbar-right {
    padding-right: 8px !important;
}

/* --- View Switcher Group — plain div with Ext.Button children --- */
/* Mock §BROWSE @805: `display: inline-flex; background: transparent;
   border-radius: 0; overflow: visible`. Centered vertically with the
   rest of the toolbar (no translate hacks). */
.view-switcher-group {
    display: inline-flex !important;
    align-items: center !important;
    flex-shrink: 0 !important;
}

div.x-toolbar-bookshelf table.x-toolbar-ct {
    margin-top: 0 !important;
    vertical-align: middle !important;
}

div.x-toolbar-bookshelf .x-toolbar-left table {
    margin-top: 0 !important;
}

/* Toolbar title — breadcrumb path */
.toolbar-title,
.toolbar-title span {
    color: #1c2127 !important;
    font-weight: 600 !important;
    font-size: 15px !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    padding: 4px 0 4px 4px !important;
}

/* Toolbar title — auto width, inline, no trailing space */
.x-toolbar-bookshelf .toolbar-title,
.search-page-toolbar .toolbar-title {
    display: inline-block !important;
    width: auto !important;
    padding: 4px 0 4px 4px !important;
    vertical-align: middle !important;
}

.x-toolbar-bookshelf td.x-toolbar-cell:has(> .toolbar-title),
.search-page-toolbar td.x-toolbar-cell:has(> .toolbar-title) {
    width: auto !important;
    padding-right: 0 !important;
    vertical-align: middle !important;
}

/* Toolbar counter — pill/chip next to the title */
.toolbar-counter {
    display: inline-block !important;
    margin: 0 !important;
    padding: 2px 8px !important;
    color: #5a6370 !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    line-height: 16px !important;
    background-color: #eef1f5 !important;
    border-radius: 10px !important;
    white-space: nowrap !important;
    vertical-align: middle !important;
    /* ExtJS sets an inline width that's narrower than the rendered box
       (the parent x-toolbar-cell forces it wider), leaving the text
       flush-left with ~14px dead space on the right. Center it. */
    text-align: center !important;
}

.x-toolbar-bookshelf td.x-toolbar-cell:has(> .toolbar-counter),
.search-page-toolbar td.x-toolbar-cell:has(> .toolbar-counter) {
    width: auto !important;
    padding-left: 8px !important;
    vertical-align: middle !important;
}

.toolbar-counter:empty {
    display: none !important;
}

/* --- Toolbar Buttons — base styling for ALL startpage toolbar buttons --- */
/* Follows the Search-In dialog Cancel button pattern but flatter (no border).
   Applied to bookshelf toolbar AND search results toolbar. */

/* Remove ExtJS 9-slice table-based button chrome.
   Exclude toggleButtons (view switchers) and x-btn-icon (paging nav, icon-only buttons). */
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) .x-btn-tl,
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) .x-btn-tc,
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) .x-btn-tr,
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) .x-btn-bl,
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) .x-btn-bc,
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) .x-btn-br,
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) .x-btn-ml,
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) .x-btn-mr {
    display: none !important;
}

:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) .x-btn-mc {
    background-image: none !important;
    padding: 0 !important;
}

/* Base button container — flat, no border, rounded */
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) {
    border: none !important;
    background: transparent !important;
    background-image: none !important;
    border-radius: 4px !important;
    transition: background-color 0.15s !important;
}

/* Button text — consistent height via padding, matching dialog button pattern.
   Exclude toggleButtons (view switchers) and x-btn-icon (paging nav buttons)
   — they use icon backgrounds on the button element. */
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon) button.x-btn-text {
    box-sizing: border-box !important;
    height: auto !important;
    padding: 6px 12px !important;
    line-height: 1.2 !important;
    color: #5a6370 !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    border: none !important;
    background: transparent !important;
    cursor: pointer !important;
    white-space: nowrap !important;
}

/* Hover state — flat version of Cancel button hover: light bg + cyan text */
:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon).x-btn-over {
    background-color: #F6F8FB !important;
}

:not(#acs_top_menu_div) > .x-toolbar .x-btn:not(.toggleButtons):not(.x-btn-icon).x-btn-over button.x-btn-text {
    color: #00aeef !important;
}

/* Pressed/menu-active wash + text, dropdown caret on em.x-btn-arrow, and
   Layout-button sliders icon — moved to ext-acs-theme.css "Menu-button
   chrome — shell-wide" block. The shell rule paints the caret via ::after
   (12×12) instead of the legacy ::before (17×12) used here previously. */

/* Sort button — sort icon via ::before. Phase 6 mask-image migration. */
.x-toolbar-bookshelf button.sort_btn {
    background-image: none !important;
}

.x-toolbar-bookshelf button.sort_btn::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-sort) !important;
            mask-image: var(--icon-sort) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.x-toolbar-bookshelf .x-btn.x-btn-over button.sort_btn::before,
.x-toolbar-bookshelf .x-btn.x-btn-menu-active button.sort_btn::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Clear Filters button — filter-x icon via ::before. Phase 6 mask-image. */
.x-toolbar-bookshelf button.clear_grid_filters {
    background-image: none !important;
}

.x-toolbar-bookshelf button.clear_grid_filters::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-filter-x) !important;
            mask-image: var(--icon-filter-x) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.x-toolbar-bookshelf .x-btn.x-btn-over button.clear_grid_filters::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* All Books button — library icon via ::before. Phase 6 mask-image. */
button.icon-library {
    background-image: none !important;
}

button.icon-library::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-library) !important;
            mask-image: var(--icon-library) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.x-btn.x-btn-over button.icon-library::before,
.x-btn.x-btn-pressed button.icon-library::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Open button — book-open icon via ::before. Phase 6 mask-image. */
button.icon-book-open {
    background-image: none !important;
}

button.icon-book-open::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-book-open) !important;
            mask-image: var(--icon-book-open) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.x-btn.x-btn-over button.icon-book-open::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Open All button — external-link icon via ::before. Phase 6 mask-image. */
button.icon-external-link {
    background-image: none !important;
}

button.icon-external-link::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-external-link) !important;
            mask-image: var(--icon-external-link) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.x-btn.x-btn-over button.icon-external-link::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Chat-bot book-viewer preview header — "Open in new window" icon-only button.
   Icon-only ExtJS button sits in the book-viewer preview header (Section 11
   theme-icons, Section 1.7 icon-only button pattern). The button has no text,
   so no ::before pseudo is needed — the icon renders directly on the
   <button class="icon-external-link"> element. Scoped to
   .book-viewer-open-new-window-btn so it can't leak into other
   icon-external-link buttons elsewhere in the shell.

   ExtJS renders each button as a 9-slice <table> where each cell (.x-btn-tl,
   .x-btn-tc, ..., .x-btn-br) carries sprite-image borders that together form
   the default blue button chrome. Strip all nine cells + the .x-btn wrapper
   so only the icon shows, then let .book-viewer-preview-header's 'transparent'
   inline style pass through. */
.book-viewer-open-new-window-btn,
.book-viewer-open-new-window-btn .x-btn-tl,
.book-viewer-open-new-window-btn .x-btn-tr,
.book-viewer-open-new-window-btn .x-btn-tc,
.book-viewer-open-new-window-btn .x-btn-ml,
.book-viewer-open-new-window-btn .x-btn-mr,
.book-viewer-open-new-window-btn .x-btn-mc,
.book-viewer-open-new-window-btn .x-btn-bl,
.book-viewer-open-new-window-btn .x-btn-br,
.book-viewer-open-new-window-btn .x-btn-bc {
    background: transparent !important;
    background-image: none !important;
    border: none !important;
}

.book-viewer-open-new-window-btn button.icon-external-link {
    -webkit-mask-image: var(--icon-external-link) !important;
            mask-image: var(--icon-external-link) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
    border: none !important;
}

.book-viewer-open-new-window-btn.x-btn-over button.icon-external-link,
.book-viewer-open-new-window-btn .x-btn-over button.icon-external-link {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Toolbar separator — thin vertical divider between logical button groups
   (§4.12). Matches mock `.mt-sep`: 1px × 22px, --sp-border, 4px horiz
   margin. ExtJS 3 renders `'-'` items as a `td.x-toolbar-cell` containing
   `<span class="xtb-sep">`. The sprite shorthand needs a clean reset
   (`background: none`) so any remnants of the legacy 9-cell sprite
   background can't peek through the flat divider — the `border-left`
   then draws the actual line. */
.x-toolbar-bookshelf .xtb-sep {
    background: none !important;
    border-left: 1px solid var(--sp-border) !important;
    width: 1px !important;
    height: 22px !important;
    margin: 0 4px !important;
}

/* --- View Switcher Buttons (List / Icon / Contents) --- */
/* Segmented view-switcher — mock §BROWSE @line 805–822.
   Two thin vertical strokes at the outer edges (left of first cell,
   right of last cell). No top/bottom borders, no rounded corners,
   no extra margin. Selected cell uses a cyan-tinted background.
   Hover swaps the icon to the cyan-baked variant + soft hover bg. */
.toggleButtons {
    background-color: transparent !important;
    background-image: none !important;
    border: 0 !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 32px !important;
    height: 28px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: background-color 0.12s !important;
}

/* §4.2 — view-switcher edges come from real toolbar separators bracketing
   the group (see `_refreshToolbarSeparators`'s collapse rules and the
   `viewStateGroup.push('-')` calls in `buildToolbarItems`), not from
   `.first`/`.last` cell borders. That keeps the outer edges visually
   identical to inter-group dividers (22px tall, 4px symmetric gap) and
   matches the mock more cleanly. The `.first` / `.last` modifier classes
   are retained for ExtJS compatibility but no longer carry borders. */

/* Specificity bumped to .acs-new-theme .toggleButtons.toggleButtons.x-btn-over
   (0,4,0) to beat .acs-new-theme .x-btn.x-btn-over:not(.reset-btn) (0,4,0)
   at ext-acs-theme.css:471 which paints muted-cyan-deep with !important.
   Equal-spec means source order wins; we're after-theme so we'd win,
   except the theme's rule is also picked up by other consumers. Adding
   the doubled .toggleButtons chain bumps us to (0,5,0). */
.acs-new-theme .toggleButtons.toggleButtons:hover,
.acs-new-theme .toggleButtons.toggleButtons.x-btn-over {
    background-color: var(--sp-hover-bg, #F6F8FB) !important;
}

.acs-new-theme .toggleButtons.toggleButtons.selected {
    background-color: var(--sp-active-bg, #EEF6FB) !important;
}

.acs-new-theme .toggleButtons.toggleButtons.selected:hover,
.acs-new-theme .toggleButtons.toggleButtons.selected.x-btn-over {
    background-color: var(--sp-active-bg, #EEF6FB) !important;
}

/* Modern toggle buttons (view-switcher) — flat ExtJS template:
   `<span class="x-btn modern-toggle toggleButtons ..."><button></button></span>`.
   The outer span owns segmented border/radius/hover/selected; the inner
   button is the full-cell hit target carrying the icon. ExtJS rewrites
   the inner button's className to `x-btn-text {iconCls}`, so target
   `.modern-toggle > button` rather than a custom class. */
.modern-toggle {
    display: inline-flex !important;
    align-items: stretch !important;
    padding: 0 !important;
    overflow: hidden !important;
}
.modern-toggle > button {
    background-color: transparent !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    background-size: 16px 16px !important;
    border: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
    height: 100% !important;
    min-width: 32px !important;
    min-height: 28px !important;
    cursor: pointer !important;
    color: inherit !important;
    font: inherit !important;
    line-height: 0 !important;
    outline: none !important;
}
.modern-toggle > button:focus-visible {
    outline: 2px solid var(--sp-brand-cyan, #00aeef) !important;
    outline-offset: -2px !important;
}

/* View switcher icons — Phase 6 mask-image migration. Specificity bumped
   to `.modern-toggle > button.x-icon-Xviewswitcher` (0,2,1) to beat
   `.modern-toggle > button { background-color: transparent !important }`
   (0,1,1) at L3580, which would kill the icon colour otherwise.
   Explicit `background-image: none` clears the legacy PNG sprite at
   startpage.css:578 (.x-icon-iconviewswitcher only; defensive on basic). */
.modern-toggle > button.x-icon-basicviewswitcher,
.x-icon-basicviewswitcher {
    -webkit-mask-image: var(--icon-list) !important;
            mask-image: var(--icon-list) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.toggleButtons.selected button.x-icon-basicviewswitcher,
.toggleButtons:hover button.x-icon-basicviewswitcher {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

.modern-toggle > button.x-icon-iconviewswitcher,
.x-icon-iconviewswitcher {
    -webkit-mask-image: var(--icon-grid) !important;
            mask-image: var(--icon-grid) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
    border-left: none !important;
}

.toggleButtons.selected button.x-icon-iconviewswitcher,
.toggleButtons:hover button.x-icon-iconviewswitcher {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Phase 6 mask-image migration. Specificity bumped to
   `.modern-toggle > button.x-icon-gridviewswitcher` (0,2,1) to beat
   `.modern-toggle > button { background-color: transparent !important }`
   (0,1,1) above, which was killing the icon colour. Explicit
   `background-image: none` clears the legacy PNG sprite at
   startpage.css:584. */
.modern-toggle > button.x-icon-gridviewswitcher,
.x-icon-gridviewswitcher {
    -webkit-mask-image: var(--icon-table) !important;
            mask-image: var(--icon-table) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.toggleButtons.selected button.x-icon-gridviewswitcher,
.toggleButtons:hover button.x-icon-gridviewswitcher {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* --- Sort Button & Menu Icons --- */
/* Sort icon for non-toolbar contexts (left panel tree, menus).
   Toolbar Sort button uses ::before pseudo-element instead.
   Phase 6 mask-image migration. */
.sort_btn:not(.x-btn-text) {
    -webkit-mask-image: var(--icon-sort) !important;
            mask-image: var(--icon-sort) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.x-btn-over .sort_btn:not(.x-btn-text),
.sort_btn:not(.x-btn-text):hover {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Toolbar Sort button background cleared in toolbar section above (line ~3754) */

/* Phase 6 mask-image migration. Toolbar sort_desc/asc/orig _btn icons —
   used outside .x-menu (the .x-menu variants are migrated at L1341-1359). */
.sort_desc_btn {
    -webkit-mask-image: var(--icon-sort-desc) !important;
            mask-image: var(--icon-sort-desc) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.sort_acs_btn {
    -webkit-mask-image: var(--icon-sort-asc) !important;
            mask-image: var(--icon-sort-asc) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.sort_orig_btn {
    -webkit-mask-image: var(--icon-list-restart) !important;
            mask-image: var(--icon-list-restart) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Clear Filters icon + row expander SVG rules moved to ext-acs-theme.css (global) */

/* --- Preference/Layout Button & Menu Icons --- */
/* Note: Layout button icon is handled via ::before on the button text (above).
   The preference_btn class is only used in the old toolbar (now removed).
   Keep these rules for backwards compatibility with any other usage.
   Phase 6 mask-image migration. */
.preference_btn {
    -webkit-mask-image: var(--icon-sliders) !important;
            mask-image: var(--icon-sliders) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.x-btn-over .preference_btn,
.preference_btn:hover {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Layout menu icons — handled via iconCls in ext-acs-preference-widgets.js.
   The icon-save and icon-rotate-ccw utility classes from theme-icons.css
   are applied to menu item <img> elements by ExtJS automatically.
   The existing .x-menu icon styling (flexbox, 16px sizing)
   from the context menu section applies here too. */

/* --- Grid Object Icons (book/folder in rows) ---
   Phase 6 mask-image migration. The folder/library tile glyphs below
   are static (no hover swap) — bg-color: text-secondary at all times.
   .book_img / .consolidated_book_img bare-class rules render the
   shelf-book glyph (matching the folder-tree leaves at
   ext-acs-startpage.css:8346) so the bookshelf list/contents views
   share one visual for "book" everywhere. */
.book_img,
.consolidated_book_img {
    -webkit-mask-image: var(--icon-shelf-book) !important;
            mask-image: var(--icon-shelf-book) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Bookshelf list + contents views (.basic-view-grid) — make every row
   feel clickable (cursor pointer, hover wash, cyan title text). Each
   row is either a folder, a book, or "Folder up" — all are navigable
   on dblclick / row-click. */
.basic-view-grid .x-grid3-row {
    cursor: pointer !important;
}
.basic-view-grid .x-grid3-col-book_name {
    cursor: pointer !important;
    color: var(--acs-link-color, #0e8bb0) !important;
    font-weight: 500 !important;
}
.basic-view-grid .x-grid3-row-over .x-grid3-col-book_name,
.basic-view-grid .x-grid3-row:hover .x-grid3-col-book_name {
    color: var(--acs-brand-cyan, #00aeef) !important;
    text-decoration: underline !important;
}
/* Folder up label — slightly muted so it reads as a navigation aid */
.basic-view-grid .x-grid3-row:has(.parent_folder) .x-grid3-col-book_name {
    color: var(--acs-text-secondary, #5a6370) !important;
    font-style: italic !important;
    font-weight: 500 !important;
}
.basic-view-grid .x-grid3-row:has(.parent_folder):hover .x-grid3-col-book_name,
.basic-view-grid .x-grid3-row-over:has(.parent_folder) .x-grid3-col-book_name {
    color: var(--acs-brand-cyan, #00aeef) !important;
    text-decoration: underline !important;
}
/* Row hover wash (matches the theme cyan-tint pattern) */
.basic-view-grid .x-grid3 .x-grid3-row-over,
.basic-view-grid .x-grid3 .x-grid3-row:hover {
    background-color: var(--acs-hover-bg, #f6f8fb) !important;
}

/* Type-column icon hover — flip to brand-cyan so the entire row tracks
   together when the user hovers anywhere on the row. */
.basic-view-grid .x-grid3-row-over img.grid-object-icon,
.basic-view-grid .x-grid3-row:hover img.grid-object-icon {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* --- Unified folder icons across ALL startpage surfaces ---
   Covers: accordion trees, content grids, icon view, dialogs, buttons.
   Scoped to so it won't affect other apps (book viewer, etc.).
   Overrides the legacy libraryswitcher.png sprite rules defined earlier. */

/* Closed/default folder (grid cells, bare classes outside a tree) */
.fldr_img,
.fldr_real,
.fldr_link,
.fldr_marker,
.fldr_download,
.fldr_workspace {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* User/workspace folder — gear variant */
.fldr_user {
    -webkit-mask-image: var(--icon-folder-cog) !important;
            mask-image: var(--icon-folder-cog) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Category folder */
.fldr_cat {
    -webkit-mask-image: var(--icon-folder-cog) !important;
            mask-image: var(--icon-folder-cog) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Parent (folder up) */
.parent_folder {
    -webkit-mask-image: var(--icon-folder-up) !important;
            mask-image: var(--icon-folder-up) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Consolidated folder */
.fldr_consolidated {
    -webkit-mask-image: var(--icon-folder-sync) !important;
            mask-image: var(--icon-folder-sync) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Track folder (Analysis Track grids/content) */
.track_folder {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
    mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.lib_img_small {
    -webkit-mask-image: var(--icon-library) !important;
            mask-image: var(--icon-library) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* ----- Tree node variants (collapsed/expanded) —
   all accordion trees (library, saved searches, analysis track) inside startpage ----- */
.x-tree-node img.fldr_real,
.x-tree-node img.fldr_link,
.x-tree-node img.fldr_marker,
.x-tree-node img.fldr_download,
.x-tree-node img.fldr_workspace,
.x-tree-node-collapsed img.fldr_real,
.x-tree-node-collapsed img.fldr_link,
.x-tree-node-collapsed img.fldr_marker,
.x-tree-node-collapsed img.fldr_download,
.x-tree-node-collapsed img.fldr_workspace {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-tree-node-expanded img.fldr_real,
.x-tree-node-expanded img.fldr_link,
.x-tree-node-expanded img.fldr_marker,
.x-tree-node-expanded img.fldr_download,
.x-tree-node-expanded img.fldr_workspace {
    -webkit-mask-image: var(--icon-folder-open) !important;
            mask-image: var(--icon-folder-open) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-tree-node img.fldr_user,
.x-tree-node-collapsed img.fldr_user,
.x-tree-node-expanded img.fldr_user,
.x-tree-node img.fldr_cat,
.x-tree-node-collapsed img.fldr_cat,
.x-tree-node-expanded img.fldr_cat {
    -webkit-mask-image: var(--icon-folder-cog) !important;
            mask-image: var(--icon-folder-cog) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-tree-node img.fldr_consolidated,
.x-tree-node-collapsed img.fldr_consolidated,
.x-tree-node-expanded img.fldr_consolidated {
    -webkit-mask-image: var(--icon-folder-sync) !important;
            mask-image: var(--icon-folder-sync) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-tree-node img.track_folder,
.x-tree-node-collapsed img.track_folder {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-tree-node-expanded img.track_folder {
    -webkit-mask-image: var(--icon-folder-open) !important;
            mask-image: var(--icon-folder-open) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* ----- Toolbar expand/collapse-all folder buttons ----- */
.tb_expand_folder {
    -webkit-mask-image: var(--icon-folder-plus) !important;
            mask-image: var(--icon-folder-plus) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.tb_collapse_folder {
    -webkit-mask-image: var(--icon-folder-minus) !important;
            mask-image: var(--icon-folder-minus) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* ----- Grid "grid_img" (header/empty folder icon in grids) ----- */
.grid_img {
    -webkit-mask-image: var(--icon-folder-open) !important;
            mask-image: var(--icon-folder-open) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* --- Icon View (large book/folder tiles) --- */
/* Scoped to .icon-view-panel to avoid affecting Contents View grid icons.
   `:not(.x-hide-display)` keeps ExtJS's display:none hide working — without
   it, our `display: grid !important` beats `.x-hide-display` on specificity
   and the tiles bleed into List/Contents views. */
.icon-view-panel:not(.x-hide-display) {
    padding: 12px !important;
    background-color: var(--sp-card-bg) !important;
    /* CSS grid: tiles are uniform per row without truncating text */
    display: grid !important;
    grid-template-columns: repeat(auto-fill, 220px) !important;
    gap: 8px !important;
    align-content: start !important;
}

.icon-view-panel .x-component-libiconel {
    background-color: #ffffff !important;
    border: 1px solid #e2e6ec !important;
    border-top: 1px solid rgba(0, 174, 239, 0.4) !important;
    /* Material 3 elevation tier: list (radius-md = 6px). Tiles are
       scannable items in a grid, NOT focal cards — keep the shadow
       light. Same rgba(15,23,42,...) slate-blue cool grey as the book
       paper for shadow-colour consistency app-wide. */
    border-radius: 6px !important;
    padding: 12px 10px !important;
    margin: 0 !important;
    box-shadow:
        0 1px 3px rgba(15, 23, 42, 0.05),
        0 4px 10px rgba(15, 23, 42, 0.06) !important;
    transition: background-color 0.15s, border-color 0.15s, box-shadow 0.15s, transform 0.15s !important;
    /* Flex column so icon sits above text, both centred */
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    width: 100% !important;
    box-sizing: border-box !important;
    text-align: center !important;
    overflow: visible !important;
}

.icon-view-panel .x-component-libiconel:hover {
    background-color: #ffffff !important;
    border-color: #b8d0e8 !important;
    border-top-color: #00aeef !important;
    /* Step up one elevation tier on hover + tiny lift — same shape as the
       book paper / home cards interaction so the affordance language is
       consistent across the app. */
    box-shadow:
        0 2px 6px rgba(15, 23, 42, 0.07),
        0 8px 20px rgba(15, 23, 42, 0.10) !important;
    transform: translateY(-2px) !important;
}

.icon-view-panel .x-component-libiconel.x-bigfolderselected {
    background-color: #EEF6FB !important;
    border-color: #00aeef !important;
    border-top-width: 1px !important;
    /* Selected tiles get a 2px cyan ring + rest-level shadow so the
       selection state reads as "marked", not "lifted further". */
    box-shadow:
        0 0 0 2px rgba(0, 174, 239, 0.20),
        0 1px 3px rgba(15, 23, 42, 0.05),
        0 4px 10px rgba(15, 23, 42, 0.06) !important;
    transform: none !important;
}

.icon-view-panel .x-component-libiconel a {
    color: #1c2127 !important;
    font-size: 13px !important;
    font-weight: 400 !important;
    line-height: 1.3 !important;
    display: -webkit-box !important;
    -webkit-box-orient: vertical !important;
    -webkit-line-clamp: 2 !important;
    line-clamp: 2 !important;
    width: 100% !important;
    text-align: center !important;
    word-break: break-word !important;
    text-wrap: balance !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    /* Reserve space for two lines so tiles stay equal height even when
       a title is short — keeps the grid even and prevents reflow on
       hover/select. */
    min-height: calc(2 * 1.3em) !important;
}

.icon-view-panel .x-component-libiconel a:hover {
    color: #0e8bb0 !important;
}

/* ===== BOOKSHELF TILE ICONS (SVG) ===== */
/* Modern SVG icons replacing old PNG/sprite bookshelf tiles.
   Phase 6 Step 6.1: mask-image migration — bg-color drives the cyan
   tint; --icon-shelf-* (currentColor) supply the glyph geometry. */
.icon-view-panel .shelf-icon {
    width: 48px !important;
    height: 48px !important;
    flex-shrink: 0 !important;
    margin: 0 auto 8px;
    -webkit-mask-size: contain;
            mask-size: contain;
    -webkit-mask-repeat: no-repeat;
            mask-repeat: no-repeat;
    -webkit-mask-position: center;
            mask-position: center;
    background-color: var(--acs-brand-cyan, #00aeef);
    opacity: 0.6;
    transition: opacity 0.12s, background-color 0.12s;
}

.icon-view-panel .shelf-book { -webkit-mask-image: var(--icon-shelf-book); mask-image: var(--icon-shelf-book); }
.icon-view-panel .shelf-folder { -webkit-mask-image: var(--icon-shelf-folder); mask-image: var(--icon-shelf-folder); }
.icon-view-panel .shelf-category { -webkit-mask-image: var(--icon-shelf-category); mask-image: var(--icon-shelf-category); }
.icon-view-panel .shelf-parent { -webkit-mask-image: var(--icon-shelf-parent); mask-image: var(--icon-shelf-parent); }
.icon-view-panel .shelf-consolidated { -webkit-mask-image: var(--icon-shelf-consolidated); mask-image: var(--icon-shelf-consolidated); }

/* Hover / selected — saturation jump via opacity bump (mask-image
   inherited from rest, bg-color stays brand-cyan; raising opacity from
   0.6 → 1 reproduces the legacy -hover SVG swap exactly). */
.icon-view-panel .x-component-libiconel:hover .shelf-icon,
.icon-view-panel .x-component-libiconel.x-bigfolderselected .shelf-icon {
    opacity: 1;
}

/* Contents View — disable tile hover effects on icons inside grid rows */
.x-grid3-row-commonview .x-component-libiconel,
.x-grid3-row-commonview .x-component-libiconel:hover {
    background-color: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* Contents View (.common-grid-panel) — Type column icons. The cell markup
   is `<div class="x-component-libiconel x-icon-sel">... <span class="shelf-
   icon shelf-{book|folder|parent}"></span> ...</div>`.

   We match the List view's icon sizing (16x16) AND family — shelf-book
   matches `.book_img` (Phosphor 256), shelf-folder/parent use the same
   Lucide glyphs as `.fldr_real` / `.parent_folder` in List view so both
   views read identically. */
.common-grid-panel .x-grid3-col-type .x-component-libiconel {
    display: inline-block !important;
    width: auto !important;
    padding: 0 !important;
    margin: 0 !important;
    border: none !important;
    background: transparent !important;
}
.common-grid-panel .x-grid3-col-type .shelf-icon {
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin: 0 auto !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
    vertical-align: middle !important;
}
.common-grid-panel .x-grid3-col-type .shelf-book {
    -webkit-mask-image: var(--icon-shelf-book) !important;
            mask-image: var(--icon-shelf-book) !important;
}
.common-grid-panel .x-grid3-col-type .shelf-folder {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
}
.common-grid-panel .x-grid3-col-type .shelf-parent {
    -webkit-mask-image: var(--icon-folder-up) !important;
            mask-image: var(--icon-folder-up) !important;
}
.common-grid-panel .x-grid3-col-type .shelf-category {
    -webkit-mask-image: var(--icon-folder-cog) !important;
            mask-image: var(--icon-folder-cog) !important;
}
.common-grid-panel .x-grid3-col-type .shelf-consolidated {
    -webkit-mask-image: var(--icon-folder-sync) !important;
            mask-image: var(--icon-folder-sync) !important;
}
/* Row hover — icon flips to brand-cyan to match the title */
.common-grid-panel .x-grid3-row-over .x-grid3-col-type .shelf-icon,
.common-grid-panel .x-grid3-row:hover .x-grid3-col-type .shelf-icon {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Contents View — make the title text inside `.flange` clickable and
   themed. The cell is `<div class="grid_toc"><span class="flange">…</span>
   </div>` for folders / "Folder up", or wraps in <a class="flangeToc">
   for books with a TOC. */
.common-grid-panel .x-grid3-row {
    cursor: pointer !important;
}
.common-grid-panel .x-grid3-col-book_name,
.common-grid-panel .x-grid3-col-book_name .flange {
    color: var(--acs-link-color, #00aeef) !important;
    font-weight: 500 !important;
}
.common-grid-panel .x-grid3-row-over .x-grid3-col-book_name .flange,
.common-grid-panel .x-grid3-row:hover .x-grid3-col-book_name .flange {
    color: var(--acs-brand-cyan, #00aeef) !important;
    text-decoration: underline !important;
}
/* "Folder up" row — muted italic to read as a navigation aid */
.common-grid-panel .x-grid3-row:has(.shelf-parent) .x-grid3-col-book_name .flange {
    color: var(--acs-text-secondary, #5a6370) !important;
    font-style: italic !important;
}
.common-grid-panel .x-grid3-row:has(.shelf-parent):hover .x-grid3-col-book_name .flange,
.common-grid-panel .x-grid3-row-over:has(.shelf-parent) .x-grid3-col-book_name .flange {
    color: var(--acs-brand-cyan, #00aeef) !important;
    text-decoration: underline !important;
}

/* Row hover wash to match the theme */
.common-grid-panel .x-grid3 .x-grid3-row-over,
.common-grid-panel .x-grid3 .x-grid3-row:hover {
    background-color: var(--acs-hover-bg, #f6f8fb) !important;
}

/* flangeToc expand/collapse chevron — legacy paints
   `azzurra-legacy/tree/elbow-end-plus.gif` (and -minus when expanded) as
   the img's background. Use the `content: var(--icon-X)` trick (replaced
   elements don't paint mask-image over their intrinsic src). Default to
   chevron-right; the -minus state flips to chevron-down. */
.common-grid-panel .grid_toc .flangeToc img.x-tree-ec-icon {
    content: var(--icon-chevron-right) !important;
    width: 12px !important;
    height: 12px !important;
    background-image: none !important;
    color: var(--acs-text-secondary, #5a6370) !important;
    vertical-align: middle !important;
    margin-right: 4px !important;
    transition: color 0.15s, transform 0.15s !important;
    opacity: 1 !important;
}
.common-grid-panel .grid_toc .flangeToc img.x-tree-ec-icon.x-tree-elbow-end-minus,
.common-grid-panel .grid_toc .flangeToc img.x-tree-ec-icon.x-tree-elbow-minus,
.common-grid-panel .grid_toc .flangeToc img.x-tree-ec-icon.x-tree-end-minus {
    content: var(--icon-chevron-down) !important;
}
.common-grid-panel .grid_toc .flangeToc:hover img.x-tree-ec-icon {
    color: var(--acs-brand-cyan, #00aeef) !important;
    opacity: 1 !important;
}

/* Contents View — TOC inner tree (`.grid_toc .tree-panel-content`).
   Replace legacy azzurra-legacy/tree/arrows.gif + per-node sprite icons
   with theme SVGs. Mirrors the patterns at lines 5560-5594 for
   `.x-grid3-row-body`, scoped to the Contents view's inline TOC. */

/* Expand/collapse chevrons (replaced <img>; use content swap) */
.common-grid-panel .grid_toc img.x-tree-ec-icon.x-tree-elbow-plus,
.common-grid-panel .grid_toc img.x-tree-ec-icon.x-tree-elbow-end-plus {
    content: var(--icon-chevron-right) !important;
    width: 12px !important;
    height: 12px !important;
    background-image: none !important;
    color: var(--acs-text-secondary, #5a6370) !important;
    vertical-align: middle !important;
    margin: 0 2px 0 2px !important;
    cursor: pointer !important;
    transition: color 0.15s !important;
}
.common-grid-panel .grid_toc img.x-tree-ec-icon.x-tree-elbow-minus,
.common-grid-panel .grid_toc img.x-tree-ec-icon.x-tree-elbow-end-minus {
    content: var(--icon-chevron-down) !important;
    width: 12px !important;
    height: 12px !important;
    background-image: none !important;
    color: var(--acs-text-secondary, #5a6370) !important;
    vertical-align: middle !important;
    margin: 0 2px 0 2px !important;
    cursor: pointer !important;
    transition: color 0.15s !important;
}
.common-grid-panel .grid_toc img.x-tree-ec-icon.x-tree-elbow,
.common-grid-panel .grid_toc img.x-tree-ec-icon.x-tree-elbow-end {
    /* No expand/collapse — just a spacer; suppress any sprite */
    background-image: none !important;
    visibility: hidden !important;
}
.common-grid-panel .grid_toc .x-tree-node-el:hover > .x-tree-ec-icon {
    color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Node icons — section (folder) / page (file) */
.common-grid-panel .grid_toc img.x-tree-node-icon.toc_section {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}
.common-grid-panel .grid_toc .x-tree-node-expanded > .x-tree-node-icon.toc_section {
    -webkit-mask-image: var(--icon-folder-open) !important;
            mask-image: var(--icon-folder-open) !important;
}
.common-grid-panel .grid_toc img.x-tree-node-icon.toc_page {
    -webkit-mask-image: var(--icon-file-text) !important;
            mask-image: var(--icon-file-text) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Generic .x-tree-icon spacer — kill the sprite */
.common-grid-panel .grid_toc img.x-tree-icon {
    background-image: none !important;
    visibility: hidden !important;
}

/* Tree node hover/select states — match theme cyan-tint */
.common-grid-panel .grid_toc .x-tree-node-over,
.common-grid-panel .grid_toc .x-tree-node-el:hover {
    background-color: var(--acs-hover-bg, #f6f8fb) !important;
}
.common-grid-panel .grid_toc .x-tree-selected a {
    background-color: #EEF6FB !important;
}
.common-grid-panel .grid_toc .x-tree-node-el:hover .x-tree-node-icon.toc_section,
.common-grid-panel .grid_toc .x-tree-node-el:hover .x-tree-node-icon.toc_page {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* --- Common View (Contents) Grid — expand/collapse rows --- */
.common-grid-panel .x-grid3-row-over {
    background-color: #f8fafc !important;
}

.common-grid-panel .x-grid3-cell-inner {
    padding: 6px 6px 6px 8px !important;
    white-space: normal !important;
}

/* --- TOC Container (table of contents in Common View rows) --- */
/* Subtle inset area — blends into the row, not a separate card */
.grid_toc {
    padding: 8px 16px 12px 16px !important;
    background-color: transparent !important;
    border: none !important;
}

.grid_toc span.flange {
    color: #1c2127 !important;
    font-size: 13px !important;
    line-height: 1.5 !important;
}

.grid_toc .x-tree-root-ct > li > div > a > span {
    font-weight: 600 !important;
    color: #1c2127 !important;
}

.grid_toc .flangeToc:hover span.flange {
    color: #0e8bb0 !important;
    text-decoration: underline !important;
}

.grid_toc .flangeToc img {
    opacity: 0.5 !important;
    transition: opacity 0.15s !important;
}

.grid_toc .flangeToc:hover img {
    opacity: 0.8 !important;
}

/* Pagination bbar rules — promoted shell-wide to ext-acs-theme.css
   (search for "Pagination bbar — shell-wide canonical rules"). The
   bookshelf and search-results grids inherit them from there. */

/* Remove right border from grid panel body, top toolbar, and paging toolbar */
.x-panel-body.x-panel-body-noheader,
.x-panel-tbar.x-panel-tbar-noheader,
.x-toolbar.x-small-editor {
    border-right: none !important;
}

/* --- Bookshelf Title Panel Header --- */
/* Hide the blue panel headers inside bookshelf — they add visual noise */
.book_shelf_panel > .x-panel-header {
    display: none !important;
}

/* --- Grid header checker (select all) --- */
.x-grid3-hd-checker {
    background-image: none !important;
}

/* --- Sort menu items icons (in any context menu) ---
   Migrated in Phase 6 5b-1 at L1341-1359 (canonical rules win by
   source-order; the legacy duplicates here have been removed). */

/* ===== S4b: SEARCH RESULTS GRID RESTYLING ===== */
/* Toolbar icons, pagination, expanded row tree, grid fixes */

/* --- Search Results Toolbar Icons — replace old PNGs with SVGs --- */

/* Clear Filters in search results toolbar — Phase 6 mask-image migration. */
.search-results-grid button.clear_grid_filters,
.search-books-grid button.clear_grid_filters {
    background-image: none !important;
}

.search-results-grid button.clear_grid_filters::before,
.search-books-grid button.clear_grid_filters::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-filter-x) !important;
            mask-image: var(--icon-filter-x) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.search-results-grid .x-btn-over button.clear_grid_filters::before,
.search-books-grid .x-btn-over button.clear_grid_filters::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Preview/Details button — ::before icon. Phase 6 mask-image migration. */
.srch_expand .x-btn-text {
    background-image: none !important;
}

.srch_expand .x-btn-text::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-eye) !important;
            mask-image: var(--icon-eye) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.srch_expand.x-btn-over .x-btn-text::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Clear Filters button — already handled by S4 .clear_grid_filters rules */

/* --- Search toolbar icon+text buttons — Phase 6 mask-image migration. */
.search-results-grid button.srch_not_indexed,
.search-results-grid button.srch_export,
.search-results-grid button.ss_item,
.search-books-grid button.srch_export,
.search-books-grid button.ss_item,
button.srch_not_indexed,
button.srch_export,
button.ss_item {
    background-image: none !important;
}

/* Unsearchable files — alert triangle via ::before */
button.srch_not_indexed::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-alert-triangle) !important;
            mask-image: var(--icon-alert-triangle) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

/* Export to Excel — spreadsheet icon via ::before */
button.srch_export::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-file-spreadsheet) !important;
            mask-image: var(--icon-file-spreadsheet) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

/* Save (saved search) — save icon via ::before */
button.ss_item::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-save) !important;
            mask-image: var(--icon-save) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

/* Saved Search toolbar buttons — SVG icons via ::before. Phase 6 mask-image. */
button.edit_ss_icon,
button.delete_ss_icon,
button.run_ss_icon {
    background-image: none !important;
}

button.edit_ss_icon::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-edit) !important;
            mask-image: var(--icon-edit) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

button.delete_ss_icon::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-trash) !important;
            mask-image: var(--icon-trash) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

button.run_ss_icon::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-image: var(--icon-play) !important;
            mask-image: var(--icon-play) !important;
    -webkit-mask-size: 16px 16px !important;
    mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

/* Hover — cyan icons. Phase 6 mask-image: swap fill colour. */
.x-btn-over button.edit_ss_icon::before,
.x-btn-over button.delete_ss_icon::before,
.x-btn-over button.run_ss_icon::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Export to Excel dropdown menu item — spreadsheet icon.
   The menu item has no iconCls, so target by menu id="export_menu".
   Phase 6 mask-image migration. Geometry + bg-color inherited from
   .x-menu .x-menu-item-icon base rule (L1224, 5b-1). */
.x-menu img.x-menu-item-icon.srch_export,
#export_menu img.x-menu-item-icon {
    -webkit-mask-image: var(--icon-file-spreadsheet) !important;
            mask-image: var(--icon-file-spreadsheet) !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Expand/collapse window — icon-only button. Phase 6 mask-image migration. */
.srch_resize_expand {
    -webkit-mask-image: var(--icon-maximize) !important;
            mask-image: var(--icon-maximize) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    padding: 0 !important;
}

.srch_resize_collapse {
    -webkit-mask-image: var(--icon-minimize) !important;
            mask-image: var(--icon-minimize) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* --- Grid Column Filter Tree (project/folder filter popover) --- */
/* TreeFilter uses acs.ExtEnhancedTreePanel inside a floating menu.
   Style the tree, its toolbar, and checkboxes to match the theme. */

/* Tree container */
.x-menu .x-tree {
    background-color: #fff !important;
}

.x-menu .x-tree .x-panel-body.x-panel-body-noheader {
    border: none !important;
}

.x-menu .x-tree .x-tree-root-ct.x-tree-lines {
    width: 100% !important;
}

/* Tree node text */
.x-menu .x-tree-node-el {
    line-height: 22px !important;
    font-size: 13px !important;
}

.x-menu .x-tree-node-anchor span {
    color: #1c2127 !important;
    font-size: 13px !important;
}

.x-menu .x-tree-node-anchor:hover span {
    color: #0e8bb0 !important;
}

/* Tree node hover */
.x-menu .x-tree-node-over {
    background-color: #f0f7ff !important;
}

/* Tree selected node — background tint only, no border-left accent */
.x-menu .x-tree-node .x-tree-selected,
.x-menu .x-tree-node div.x-tree-selected,
.x-menu .x-tree-selected {
    background-color: #EEF6FB !important;
    background-image: none !important;
    background: #EEF6FB !important;
}

.x-menu .x-tree-node .x-tree-selected a,
.x-menu .x-tree-node .x-tree-selected a span,
.x-menu .x-tree-selected a,
.x-menu .x-tree-selected a span {
    color: #1c2127 !important;
    font-weight: 500 !important;
    background-color: transparent !important;
}

.x-menu .x-tree-selected.x-tree-node-over {
    background-color: #EEF6FB !important;
    background: #EEF6FB !important;
}

/* Tree node icons — folder SVG. Phase 6 mask-image migration. */
.x-menu .x-tree-node-collapsed .x-tree-node-icon,
.x-menu .x-tree-node-expanded .x-tree-node-icon {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-menu .x-tree-node-expanded .x-tree-node-icon {
    -webkit-mask-image: var(--icon-folder-open) !important;
            mask-image: var(--icon-folder-open) !important;
}

.x-menu .x-tree-node-leaf .x-tree-node-icon {
    -webkit-mask-image: var(--icon-file-text) !important;
            mask-image: var(--icon-file-text) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* An attachment row's icon is an <img> whose src is the file type's picture; the mask
   alone lets that picture show through. Move it out of the box so only the glyph shows. */
.x-menu img.x-tree-node-inline-icon {
    object-position: -9999px 0;
}

/* Tree checkboxes — match search accordion checkbox pattern */
.x-menu .x-tree-node-cb {
    appearance: none !important;
    -webkit-appearance: none !important;
    width: 16px !important;
    height: 16px !important;
    min-width: 16px !important;
    min-height: 16px !important;
    background: #F6F8FB !important;
    border: 1px solid #DCE2EF !important;
    border-radius: 4px !important;
    cursor: pointer !important;
    position: relative !important;
    vertical-align: middle !important;
    margin-right: 4px !important;
}

.x-menu .x-tree-node-cb:hover {
    border-color: #00aeef !important;
}

.x-menu .x-tree-node-cb:checked {
    background: #00aeef !important;
    border-color: #00aeef !important;
}

.x-menu .x-tree-node-cb:checked::after {
    content: '' !important;
    position: absolute !important;
    left: 50% !important;
    top: 45% !important;
    width: 3px !important;
    height: 7px !important;
    border: solid #fff !important;
    border-width: 0 2px 2px 0 !important;
    transform: translate(-50%, -50%) rotate(45deg) !important;
}

/* Tree filter toolbar — match library tree toolbar style */
.x-menu .x-tree .x-toolbar,
.x-menu .x-tree .x-panel-tbar .x-toolbar {
    background-image: none !important;
    background-color: #fff !important;
    border: none !important;
    border-bottom: 1px solid #e2e6ec !important;
    padding: 2px 4px !important;
}

/* Remove 9-slice button chrome + azzurra dark hover bg */
.x-menu .x-tree .x-toolbar .x-btn,
.x-menu .x-tree .x-toolbar .x-btn-tl,
.x-menu .x-tree .x-toolbar .x-btn-tr,
.x-menu .x-tree .x-toolbar .x-btn-tc,
.x-menu .x-tree .x-toolbar .x-btn-ml,
.x-menu .x-tree .x-toolbar .x-btn-mr,
.x-menu .x-tree .x-toolbar .x-btn-mc,
.x-menu .x-tree .x-toolbar .x-btn-bl,
.x-menu .x-tree .x-toolbar .x-btn-br,
.x-menu .x-tree .x-toolbar .x-btn-bc {
    background: transparent !important;
    background-image: none !important;
    border: none !important;
}

.x-menu .x-tree .x-toolbar .x-btn:hover,
.x-menu .x-tree .x-toolbar .x-btn-over {
    background: #F6F8FB !important;
    border-radius: 4px !important;
}

/* Tree filter toolbar icons — same pattern as the col-1 tree toolbar.
   Actual button classes are toc_expand, toc_collapse, toc_next, toc_prev,
   tb_expand_folder, tb_collapse_folder, refresh_icon.
   Phase 6 mask-image migration: per-icon rules below set mask-image;
   the base rule supplies geometry + bg-color (text-secondary) + the
   opacity rest state. Hover boosts opacity to 1 (no bg-image swap
   needed under mask-image). */
.x-menu .x-tree .toc_expand,
.x-menu .x-tree .toc_collapse,
.x-menu .x-tree .toc_next,
.x-menu .x-tree .toc_prev,
.x-menu .x-tree .tb_expand_folder,
.x-menu .x-tree .tb_collapse_folder,
.x-menu .x-tree .refresh_icon {
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    opacity: 0.7 !important;
    transition: opacity 0.15s !important;
}

.x-menu .x-tree .toc_expand:hover,
.x-menu .x-tree .toc_collapse:hover,
.x-menu .x-tree .toc_next:hover,
.x-menu .x-tree .toc_prev:hover,
.x-menu .x-tree .tb_expand_folder:hover,
.x-menu .x-tree .tb_collapse_folder:hover,
.x-menu .x-tree .refresh_icon:hover,
.x-menu .x-tree .x-btn-over .toc_expand,
.x-menu .x-tree .x-btn-over .toc_collapse,
.x-menu .x-tree .x-btn-over .toc_next,
.x-menu .x-tree .x-btn-over .toc_prev,
.x-menu .x-tree .x-btn-over .tb_expand_folder,
.x-menu .x-tree .x-btn-over .tb_collapse_folder,
.x-menu .x-tree .x-btn-over .refresh_icon {
    opacity: 1 !important;
}

/* Expand all */
.x-menu .x-tree .toc_expand,
.x-menu .x-tree .tb_expand_folder {
    -webkit-mask-image: var(--icon-folder-plus) !important;
            mask-image: var(--icon-folder-plus) !important;
}

/* Collapse all */
.x-menu .x-tree .toc_collapse,
.x-menu .x-tree .tb_collapse_folder {
    -webkit-mask-image: var(--icon-folder-minus) !important;
            mask-image: var(--icon-folder-minus) !important;
}

/* Next */
.x-menu .x-tree .toc_next {
    -webkit-mask-image: var(--icon-chevron-down) !important;
            mask-image: var(--icon-chevron-down) !important;
}

/* Previous */
.x-menu .x-tree .toc_prev {
    -webkit-mask-image: var(--icon-chevron-up) !important;
            mask-image: var(--icon-chevron-up) !important;
}

/* Refresh */
.x-menu .x-tree .refresh_icon {
    -webkit-mask-image: var(--icon-refresh) !important;
            mask-image: var(--icon-refresh) !important;
}

/* --- Search Results Pagination — handled by shell-wide .x-panel-bbar rules
       in ext-acs-theme.css ("Pagination bbar — shell-wide canonical rules") --- */

/* --- Search Results Expanded Row — location tree styling --- */
/* Match the library tree styling from the left accordion panel */

/* Location links */
.grid_result_location div span a {
    color: #0e8bb0 !important;
    text-decoration: none !important;
    font-size: 13px !important;
}

.grid_result_location div span a:hover {
    color: #00aeef !important;
    text-decoration: underline !important;
}

/* Location tree icons — Phase 6 mask-image migration. Per-icon rules
   below set mask-image; this base rule supplies geometry + bg-color. */
.grid_result_location .x-tree-node-icon {
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Folder icons in location tree */
.grid_result_location .x-tree-node-collapsed .x-tree-node-icon {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
}

.grid_result_location .x-tree-node-expanded .x-tree-node-icon {
    -webkit-mask-image: var(--icon-folder-open) !important;
            mask-image: var(--icon-folder-open) !important;
}

.grid_result_location .x-tree-node-leaf .x-tree-node-icon {
    -webkit-mask-image: var(--icon-book) !important;
            mask-image: var(--icon-book) !important;
}

/* Location tree node text */
.grid_result_location .x-tree-node-el {
    line-height: 22px !important;
    font-size: 13px !important;
    color: #1c2127 !important;
}

.grid_result_location .x-tree-node a span {
    color: #1c2127 !important;
    font-size: 13px !important;
}

.grid_result_location .x-tree-node a:hover span {
    color: #0e8bb0 !important;
}

/* Selected tree node in location tree — background tint only */
.grid_result_location .x-tree-selected a {
    background-color: #EEF6FB !important;
}

/* Expanded row body — only style when it has content */
.x-grid3-row-body:not(:empty) {
    padding: 8px 12px !important;
    background-color: #f5f7f9 !important;
    position: relative !important;
}

/* Loading state inside preview row — clean inline indicator */
.x-grid3-row-body .loading-indicator {
    padding: 8px 8px 8px 28px !important;
    min-height: 16px !important;
    line-height: 16px !important;
    color: #5a6370 !important;
    font-size: 12px !important;
    background-image: none !important;
}

.x-grid3-row-body .loading-indicator::before {
    left: 4px !important;
    width: 14px !important;
    height: 14px !important;
}

/* Mask inside preview row — ensure visible with enough space */
.x-grid3-row-body .ext-el-mask {
    background-color: rgba(245, 247, 249, 0.8) !important;
}

.x-grid3-row-body .ext-el-mask-msg {
    display: block !important;
}

/* Preview panel needs min-height so mask message has room */
.x-grid3-row-body .x-plain {
    min-height: 50px !important;
}

/* Empty row body — invisible */
.x-grid3-row-body:empty {
    padding: 0 !important;
    display: none !important;
}

/* Search result title links */
.grid_result_title {
    color: #0e8bb0 !important;
}

.search-results-grid .x-grid3-row-over .grid_result_title {
    color: #00aeef !important;
}

/* --- Search Results Location Tree (expanded row) --- */
/* Match the library tree styling from the left accordion panel */

/* Tree container */
.x-grid3-row-body .x-tree {
    background-color: #fff !important;
}

/* Tree node text */
.x-grid3-row-body .x-tree-node-el {
    line-height: 24px !important;
    font-size: 13px !important;
    padding: 1px 4px !important;
}

.x-grid3-row-body .x-tree-node-anchor span {
    color: #1c2127 !important;
    font-size: 13px !important;
}

.x-grid3-row-body .x-tree-node-anchor:hover span {
    color: #0e8bb0 !important;
    text-decoration: underline !important;
}

/* Tree node icons — Phase 6 mask-image migration. */
.x-grid3-row-body .x-tree-node-icon.toc_root {
    -webkit-mask-image: var(--icon-folder-tree) !important;
            mask-image: var(--icon-folder-tree) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-grid3-row-body .x-tree-node-icon.toc_section {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-grid3-row-body .x-tree-node-expanded > .x-tree-node-icon.toc_section {
    -webkit-mask-image: var(--icon-folder-open) !important;
            mask-image: var(--icon-folder-open) !important;
}

.x-grid3-row-body .x-tree-node-icon.toc_page {
    -webkit-mask-image: var(--icon-file-text) !important;
            mask-image: var(--icon-file-text) !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Tree expand/collapse arrow icons */
.x-grid3-row-body .x-tree-ec-icon {
    background-image: none !important;
}

/* Selected tree node — background tint only */
.x-grid3-row-body .x-tree-selected a {
    background-color: #EEF6FB !important;
}

/* Hover tree node */
.x-grid3-row-body .x-tree-node-over {
    background-color: #f0f7ff !important;
}

/* Search results expander column — don't apply extra padding that shrinks it */
.search-results-grid .x-grid3-td-expander .x-grid3-cell-inner {
    padding: 2px 2px !important;
    min-width: 20px !important;
}

/* Row expander SVG rules moved to ext-acs-theme.css (global) */


/* ===== S7: ANALYSIS TRACK VIEW RESTYLING ===== */
/* Complete restyle of the Analysis Track view: toolbar, detail panel,
   track items, hover buttons, notes, invalid states.
   Scoped to to prevent bleeding to other pages. */

/* --- S7.1: Toolbar --- */
.analysis-track .acs-big-toolbar {
    background-color: #fff !important;
    background-image: none !important;
    border: none !important;
    border-bottom: 1px solid #e2e6ec !important;
    margin-top: 0 !important;
    height: 44px !important;
    padding: 0 8px !important;
}

/* The toolbar's bottom border is the one line above the details panel;
   drop the panel body's ExtJS top border, which doubled it. */
.analysis-track .x-panel.atButton > .x-panel-bwrap > .x-panel-body {
    border-top-width: 0 !important;
}

/* Remove ExtJS 9-slice chrome from toolbar buttons */
.analysis-track .acs-big-toolbar .x-btn-tl,
.analysis-track .acs-big-toolbar .x-btn-tc,
.analysis-track .acs-big-toolbar .x-btn-tr,
.analysis-track .acs-big-toolbar .x-btn-ml,
.analysis-track .acs-big-toolbar .x-btn-mr,
.analysis-track .acs-big-toolbar .x-btn-bl,
.analysis-track .acs-big-toolbar .x-btn-bc,
.analysis-track .acs-big-toolbar .x-btn-br {
    display: none !important;
}

.analysis-track .acs-big-toolbar .x-btn-mc {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
}

/* Flat toolbar button styling */
.analysis-track .acs-big-toolbar .x-btn {
    border: none !important;
    border-radius: 4px !important;
    background: transparent !important;
}

.analysis-track .acs-big-toolbar .x-btn button.x-btn-text {
    color: #5a6370 !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    padding: 6px 12px !important;
    border-radius: 4px !important;
    transition: background-color 0.15s, color 0.15s !important;
}

.analysis-track .acs-big-toolbar .x-btn.x-btn-over button.x-btn-text {
    background-color: #F6F8FB !important;
    color: #00aeef !important;
}

/* Toolbar separators */
.analysis-track .acs-big-toolbar .xtb-sep {
    background-color: #e2e6ec !important;
    background-image: none !important;
    width: 1px !important;
    height: 20px !important;
    margin: 0 8px !important;
}

/* Toolbar title */
.analysis-track .acs-big-toolbar .acs-toolbar-title {
    font-size: 16px !important;
    font-weight: 600 !important;
    color: #1c2127 !important;
}

/* Vertically center all toolbar cells (same pattern as bookshelf toolbar) */
.analysis-track .acs-big-toolbar .x-toolbar-cell {
    vertical-align: middle !important;
}

.analysis-track .acs-big-toolbar table.x-toolbar-ct {
    margin-top: 0 !important;
    vertical-align: middle !important;
    height: 100% !important;
}

.analysis-track .acs-big-toolbar .x-toolbar-left table {
    margin-top: 0 !important;
}

/* --- S7.1b: Toolbar icon replacement via ::before --- */
/* Clear old sprite backgrounds on ALL toolbar iconCls buttons */
.analysis-track .acs-big-toolbar button.cmd_refresh_track,
.analysis-track .acs-big-toolbar button.cmd_edit_track,
.analysis-track .acs-big-toolbar button.cmd_start_track,
.analysis-track .acs-big-toolbar button.cmd_stop_track,
.analysis-track .acs-big-toolbar button.cmd_export_to_pdf,
.analysis-track .acs-big-toolbar button.cmd_print,
.analysis-track .acs-big-toolbar button.cmd_email_page {
    background-image: none !important;
}

/* Common ::before icon style. Phase 6 mask-image migration. */
.analysis-track .acs-big-toolbar button.cmd_refresh_track::before,
.analysis-track .acs-big-toolbar button.cmd_edit_track::before,
.analysis-track .acs-big-toolbar button.cmd_start_track::before,
.analysis-track .acs-big-toolbar button.cmd_stop_track::before,
.analysis-track .acs-big-toolbar button.cmd_export_to_pdf::before,
.analysis-track .acs-big-toolbar button.cmd_print::before,
.analysis-track .acs-big-toolbar button.cmd_email_page::before {
    content: '' !important;
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    margin-right: 4px !important;
    vertical-align: -3px !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

/* Individual icon assignments */
.analysis-track .acs-big-toolbar button.cmd_refresh_track::before {
    -webkit-mask-image: var(--icon-refresh) !important;
            mask-image: var(--icon-refresh) !important;
}
.analysis-track .acs-big-toolbar button.cmd_edit_track::before {
    -webkit-mask-image: var(--icon-edit) !important;
            mask-image: var(--icon-edit) !important;
}
.analysis-track .acs-big-toolbar button.cmd_start_track::before {
    -webkit-mask-image: var(--icon-play) !important;
            mask-image: var(--icon-play) !important;
}
.analysis-track .acs-big-toolbar button.cmd_stop_track::before {
    -webkit-mask-image: var(--icon-circle-stop) !important;
            mask-image: var(--icon-circle-stop) !important;
}
.analysis-track .acs-big-toolbar button.cmd_export_to_pdf::before {
    -webkit-mask-image: var(--icon-download) !important;
            mask-image: var(--icon-download) !important;
}
.analysis-track .acs-big-toolbar button.cmd_print::before {
    -webkit-mask-image: var(--icon-printer) !important;
            mask-image: var(--icon-printer) !important;
}
.analysis-track .acs-big-toolbar button.cmd_email_page::before {
    -webkit-mask-image: var(--icon-mail) !important;
            mask-image: var(--icon-mail) !important;
}

/* Hover — bg-color swap (mask-image inherits from rest). */
.analysis-track .acs-big-toolbar .x-btn.x-btn-over button.cmd_refresh_track::before,
.analysis-track .acs-big-toolbar .x-btn.x-btn-over button.cmd_edit_track::before,
.analysis-track .acs-big-toolbar .x-btn.x-btn-over button.cmd_start_track::before,
.analysis-track .acs-big-toolbar .x-btn.x-btn-over button.cmd_stop_track::before,
.analysis-track .acs-big-toolbar .x-btn.x-btn-over button.cmd_export_to_pdf::before,
.analysis-track .acs-big-toolbar .x-btn.x-btn-over button.cmd_print::before,
.analysis-track .acs-big-toolbar .x-btn.x-btn-over button.cmd_email_page::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* --- S7.2: Detail Panel Header --- */
.analysis-track .x-panel-header {
    background-color: #f5f7f9 !important;
    background-image: none !important;
    border-bottom: 1px solid #e2e6ec !important;
    height: auto !important;
    padding: 8px 12px !important;
}

/* Step-7 prep: chevron via ::before pseudo so the text on the parent
   span renders untouched. mask-image on the parent would mask the
   element's entire painted output including text. */
.analysis-track .x-panel-header span {
    position: relative !important;
    color: #5a6370 !important;
    font: 600 12px/16px inherit !important;
    text-transform: uppercase !important;
    letter-spacing: 0.03em !important;
    background-image: none !important;
    padding-left: 18px !important;
}

.analysis-track .x-panel-header span::before {
    content: '' !important;
    position: absolute !important;
    left: 0 !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 14px !important;
    height: 14px !important;
    -webkit-mask-image: var(--icon-chevron-down) !important;
            mask-image: var(--icon-chevron-down) !important;
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: currentColor !important;
    pointer-events: none !important;
}

.analysis-track .x-panel-collapsed .x-panel-header span::before {
    -webkit-mask-image: var(--icon-chevron-right) !important;
            mask-image: var(--icon-chevron-right) !important;
}

/* --- S7.3: Track Info Table --- */
.analysis-track .trackInfo {
    padding: 12px 16px !important;
}

.analysis-track .trackInfo .title {
    color: #5a6370 !important;
    font: 600 12px/16px inherit !important;
    text-transform: uppercase !important;
    letter-spacing: 0.03em !important;
    padding-bottom: 8px !important;
}

.analysis-track .trackInfo .details {
    color: #1c2127 !important;
    font-size: 13px !important;
    border-right-color: #e2e6ec !important;
}

.analysis-track .trackInfo .description {
    color: #5a6370 !important;
    font-size: 13px !important;
    font-style: italic !important;
}

/* --- S7.4: Track Items --- */
.analysis-track .trackItem {
    border-bottom: 1px solid #e2e6ec !important;
    margin: 0 !important;
    background-image: none !important;
    transition: background-color 0.15s !important;
}

.analysis-track .trackItem.trackItem-over {
    background-color: #fafbfc !important;
}

.analysis-track .trackItemContent {
    padding: 12px 16px !important;
    margin: 0 !important;
}

/* --- S7.5: Item Source / Breadcrumbs --- */
.analysis-track .itemSource {
    font-size: 13px !important;
    font-weight: 500 !important;
    font-style: italic !important;
    font-family: inherit !important;
    color: #5a6370 !important;
    margin-bottom: 8px !important;
    line-height: 1.4 !important;
}

.analysis-track .itemSource .trackItemNumber {
    color: #8c95a0 !important;
    font-style: normal !important;
}

.analysis-track .itemSource .sourceLabel {
    color: #8c95a0 !important;
}

.analysis-track .itemSource a {
    color: #00aeef !important;
}

.analysis-track .itemSource a:hover {
    color: #0e8bb0 !important;
    text-decoration: underline !important;
}

/* --- S7.6: Track Item Text --- */
.analysis-track .trackItemText {
    font-size: 14px !important;
    color: #1c2127 !important;
    line-height: 1.5 !important;
}

/* Definition source styling */
.analysis-track .definitionSource {
    font-size: 12px !important;
    color: #8c95a0 !important;
}

.analysis-track .definitionSource a {
    color: #8c95a0 !important;
    font-size: 12px !important;
}

.analysis-track .definitionTitle {
    color: #1c2127 !important;
    font-size: 14px !important;
    font-family: inherit !important;
}

/* --- S7.7: Item Hover Buttons --- */
/* HTML structure (from XTemplate):
   Remove: <a class="atButton remove"><b><span class="icon"></span></b></a>
   Move:   <a class="atButton top"><b></b></a>  (no span!)
   Wrapper: <div class="atButton"> around move buttons
   Strategy: hide all inner elements, use ::after on the <a> for the icon. */

/* Button container — white background so buttons don't overlap text */
.analysis-track .trackItemContent .itemButtons.item {
    background-color: #fff !important;
    border-radius: 6px !important;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08) !important;
    padding: 2px 4px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 2px !important;
}

.analysis-track .trackItem.trackItem-over .trackItemContent .itemButtons.item {
    background-color: #fff !important;
}

/* Remove sprite background from the wrapper div */
.analysis-track .trackItemContent .itemButtons.item div.atButton {
    background-image: none !important;
    width: auto !important;
    height: auto !important;
    display: inline-flex !important;
    gap: 2px !important;
    padding: 0 !important;
    margin-left: 2px !important;
}

/* Base style for all item action buttons */
.analysis-track .itemButtons.item a.atButton,
.analysis-track .itemButtons.item a.markValid {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 28px !important;
    height: 28px !important;
    border-radius: 4px !important;
    background-image: none !important;
    background-color: transparent !important;
    transition: background-color 0.15s !important;
    float: none !important;
    margin: 0 !important;
}

.analysis-track .itemButtons.item a.atButton:hover,
.analysis-track .itemButtons.item a.markValid:hover {
    background-color: #F6F8FB !important;
}

/* Item button inner elements: funcName is on the <a> itself for item buttons,
   so b/span just need to be visually hidden. Using sr-only pattern. */
.analysis-track .itemButtons.item a.atButton {
    position: relative !important;
}

.analysis-track .itemButtons.item a.atButton b,
.analysis-track .itemButtons.item a.atButton span,
.analysis-track .itemButtons.item a.atButton:hover b,
.analysis-track .itemButtons.item a.atButton:active b {
    background-image: none !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 1 !important;
    opacity: 0 !important;
    cursor: pointer !important;
}

/* ::after pseudo-element for SVG icon — pointer-events: none so clicks pass to b/a underneath.
   Phase 6 mask-image migration. */
.analysis-track .itemButtons.item a.atButton::after {
    content: '' !important;
    display: block !important;
    width: 16px !important;
    height: 16px !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
    pointer-events: none !important;
}

/* Individual icon assignments via ::after */
.analysis-track .itemButtons.item a.atButton.remove::after {
    -webkit-mask-image: var(--icon-trash) !important;
            mask-image: var(--icon-trash) !important;
}
.analysis-track .itemButtons.item a.atButton.top::after {
    -webkit-mask-image: var(--icon-arrow-up-to-line) !important;
            mask-image: var(--icon-arrow-up-to-line) !important;
}
.analysis-track .itemButtons.item a.atButton.up::after {
    -webkit-mask-image: var(--icon-arrow-up) !important;
            mask-image: var(--icon-arrow-up) !important;
}
.analysis-track .itemButtons.item a.atButton.down::after {
    -webkit-mask-image: var(--icon-arrow-down) !important;
            mask-image: var(--icon-arrow-down) !important;
}
.analysis-track .itemButtons.item a.atButton.bottom::after {
    -webkit-mask-image: var(--icon-arrow-down-to-line) !important;
            mask-image: var(--icon-arrow-down-to-line) !important;
}

/* Hover — bg-color swap (mask geometry inherits from rest). */
.analysis-track .itemButtons.item a.atButton.remove:hover::after,
.analysis-track .itemButtons.item a.atButton.top:hover::after,
.analysis-track .itemButtons.item a.atButton.up:hover::after,
.analysis-track .itemButtons.item a.atButton.down:hover::after,
.analysis-track .itemButtons.item a.atButton.bottom:hover::after {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Mark Valid button — wider, with text + icon */
.analysis-track .itemButtons.item a.markValid {
    width: auto !important;
    padding: 4px 10px !important;
    gap: 4px !important;
    background-image: none !important;
}

.analysis-track .itemButtons.item a.markValid span {
    display: inline !important;
    width: auto !important;
    height: auto !important;
    font-size: 12px !important;
    color: #e5484d !important;
    font-weight: 500 !important;
    background-image: none !important;
}

/* Phase 6 mask-image. Rest: red text + check icon (#e5484d).
   Hover: cyan text + check icon. */
.analysis-track .itemButtons.item a.markValid::before {
    content: '' !important;
    display: inline-block !important;
    width: 14px !important;
    height: 14px !important;
    -webkit-mask-image: var(--icon-check) !important;
            mask-image: var(--icon-check) !important;
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: #e5484d !important;
    transition: background-color 0.15s !important;
}

.analysis-track .itemButtons.item a.markValid:hover span {
    color: #00aeef !important;
    background-image: none !important;
}
.analysis-track .itemButtons.item a.markValid:hover::before {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Disabled buttons */
.analysis-track .itemButtons.item a.atButton.atButtonDisabled {
    opacity: 0.3 !important;
    cursor: default !important;
}
.analysis-track .itemButtons.item a.atButton.atButtonDisabled:hover {
    background-color: transparent !important;
}
.analysis-track .itemButtons.item a.atButton.atButtonDisabled span {
    opacity: 1 !important;
}

/* --- S7.8: Notes Section --- */
/* Collapse toggle — Notes title should stand out */
.analysis-track .trackItem .collapse-notes {
    border-top: 1px solid #e2e6ec !important;
    background-color: #f9fafb !important;
    padding: 8px 16px !important;
    height: auto !important;
}

.analysis-track .trackItem .collapse-notes span {
    font: 600 12px/16px inherit !important;
    color: #5a6370 !important;
    opacity: 1 !important;
    padding-left: 18px !important;
    margin-left: 0 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.03em !important;
}

/* Step-7 prep: chevron via ::before pseudo. Both the .collapse-notes
   span shapes share padding-left + position-relative from the parent
   rule above (L5754-5762). Each variant supplies its own mask-image
   on the pseudo. bg-color: currentColor tracks the parent's text colour. */
.analysis-track .trackItem .collapse-notes span.collapseNotesButton,
.analysis-track .trackItem .collapse-notes span.expandNotesButton {
    position: relative !important;
    background: transparent !important;
}

.analysis-track .trackItem .collapse-notes span.collapseNotesButton::before,
.analysis-track .trackItem .collapse-notes span.expandNotesButton::before {
    content: '' !important;
    position: absolute !important;
    left: 0 !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 14px !important;
    height: 14px !important;
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: currentColor !important;
    pointer-events: none !important;
}

.analysis-track .trackItem .collapse-notes span.collapseNotesButton::before {
    -webkit-mask-image: var(--icon-chevron-up) !important;
            mask-image: var(--icon-chevron-up) !important;
}

.analysis-track .trackItem .collapse-notes span.expandNotesButton::before {
    -webkit-mask-image: var(--icon-chevron-down) !important;
            mask-image: var(--icon-chevron-down) !important;
}

/* Note icon. Phase 6 mask-image migration. */
.analysis-track .trackNoteIcon {
    -webkit-mask-image: var(--icon-sticky-note) !important;
            mask-image: var(--icon-sticky-note) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-position: 10px 10px !important;
            mask-position: 10px 10px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

/* Note rows */
.analysis-track .trackItemNote td {
    border-top-color: #e2e6ec !important;
}

.analysis-track .trackItemNote {
    font: normal 13px/1.4 inherit !important;
    color: #1c2127 !important;
}

.analysis-track .trackNoteNumber {
    font: 600 11px/16px inherit !important;
    color: #8c95a0 !important;
    opacity: 1 !important;
}

.analysis-track .noteOwner {
    color: #8c95a0 !important;
}

/* Add note row */
.analysis-track .trackItemNote.addTrackItemNote {
    color: #8c95a0 !important;
    transition: background-color 0.15s !important;
}

.analysis-track .trackItemNote.addTrackItemNote:hover {
    background-color: #fafbfc !important;
}

/* Note action buttons — remove sprite backgrounds, use ::after for icons
   HTML structure: <a class="atButton editNote"><b><span class="icon"></span></b></a> */
.analysis-track .itemButtons.note {
    background-image: none !important;
    width: auto !important;
    height: auto !important;
    display: inline-flex !important;
    gap: 2px !important;
    visibility: hidden !important;
}

/* Show note buttons on hover and in active-edit mode */
.analysis-track .trackItemNote:hover .itemButtons.note,
.analysis-track .trackItemNote.active-edit .itemButtons.note,
.analysis-track .trackItemNote.addTrackItemNote:hover .itemButtons.note {
    visibility: visible !important;
}

.analysis-track .itemButtons.note a.atButton {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 26px !important;
    height: 26px !important;
    border-radius: 4px !important;
    background-image: none !important;
    transition: background-color 0.15s !important;
}

.analysis-track .itemButtons.note a.atButton:hover {
    background-color: #F6F8FB !important;
}

/* Note button inner elements: b carries funcName/itemId/noteId for click handlers.
   Make b fill the a element so clicks land on it, but hide its sprite visuals.
   The ::after on the a provides the SVG icon on top. */
.analysis-track .itemButtons.note a.atButton {
    position: relative !important;
}

.analysis-track .itemButtons.note a.atButton b,
.analysis-track .itemButtons.note a.atButton:hover b,
.analysis-track .itemButtons.note a.atButton:active b {
    background-image: none !important;
    background-position: initial !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 1 !important;
    opacity: 0 !important;
    cursor: pointer !important;
}

.analysis-track .itemButtons.note a.atButton span {
    background-image: none !important;
    position: absolute !important;
    width: 100% !important;
    height: 100% !important;
    top: 0 !important;
    left: 0 !important;
    z-index: 1 !important;
    opacity: 0 !important;
}

/* ::after pseudo-element for SVG icon — pointer-events: none so clicks pass to b underneath.
   Phase 6 mask-image migration. */
.analysis-track .itemButtons.note a.atButton::after {
    content: '' !important;
    display: block !important;
    width: 14px !important;
    height: 14px !important;
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
    pointer-events: none !important;
}

/* Note edit button */
.analysis-track .itemButtons.note a.atButton.editNote::after {
    -webkit-mask-image: var(--icon-edit) !important;
            mask-image: var(--icon-edit) !important;
}
.analysis-track .itemButtons.note a.atButton.editNote:hover::after {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Note remove button */
.analysis-track .itemButtons.note a.atButton.remove::after {
    -webkit-mask-image: var(--icon-trash) !important;
            mask-image: var(--icon-trash) !important;
}
.analysis-track .itemButtons.note a.atButton.remove:hover::after {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* Note save button — hidden by default, shown in active-edit mode */
.analysis-track .itemButtons.note a.atButton.saveNote {
    display: none !important;
}
.analysis-track .trackItemNote.active-edit .itemButtons.note a.atButton.saveNote {
    display: inline-flex !important;
}

.analysis-track .itemButtons.note a.atButton.saveNote::after {
    -webkit-mask-image: var(--icon-save) !important;
            mask-image: var(--icon-save) !important;
}
.analysis-track .itemButtons.note a.atButton.saveNote:hover::after {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* In active-edit mode, hide edit and remove buttons */
.analysis-track .trackItemNote.active-edit .itemButtons.note a.atButton.editNote,
.analysis-track .trackItemNote.active-edit .itemButtons.note a.atButton.remove {
    display: none !important;
}

/* In active-edit mode, show save button as a prominent action button
   in the normal buttons column position */
.analysis-track .trackItemNote.active-edit .itemButtons.note {
    visibility: visible !important;
}

.analysis-track .trackItemNote.active-edit .itemButtons.note a.atButton.saveNote {
    display: inline-flex !important;
    background: linear-gradient(135deg, #00aeef 0%, #0098d4 100%) !important;
    border: 1px solid #0098d4 !important;
    border-radius: 4px !important;
    width: 32px !important;
    height: 32px !important;
    box-shadow: 0 2px 4px rgba(0, 174, 239, 0.25) !important;
}

.analysis-track .trackItemNote.active-edit .itemButtons.note a.atButton.saveNote::after {
    /* White icon on primary cyan-gradient bg. The base ::after at L5938
       supplies geometry + grey bg-color; we just flip bg-color to white
       here. mask-image: var(--icon-save) is inherited from the saveNote
       rest rule (L5981), so the save shape stays masked correctly. */
    background-image: none !important;
    background-color: #fff !important;
}

.analysis-track .trackItemNote.active-edit .itemButtons.note a.atButton.saveNote:hover {
    background: linear-gradient(135deg, #00c2ff 0%, #00aeef 100%) !important;
    box-shadow: 0 4px 8px rgba(0, 174, 239, 0.3) !important;
}

/* Note textarea */
.analysis-track .trackItemNote .trackItemNoteText textarea {
    font: normal 13px/1.4 inherit !important;
    border: 1px solid #DCE2EF !important;
    border-radius: 4px !important;
    padding: 8px !important;
    width: 95% !important;
    box-sizing: border-box !important;
}

.analysis-track .trackItemNote .trackItemNoteText textarea:focus {
    border-color: #00aeef !important;
    outline: none !important;
}

/* Note buttons cell — enough width to fit icons without overlapping textarea */
.analysis-track .trackNoteButtons {
    width: 90px !important;
    text-align: right !important;
    padding-right: 8px !important;
}

/* --- S7.9: Invalid Items --- */
.analysis-track .trackItem.invalid {
    border: none !important;
    border-bottom: 1px solid #e2e6ec !important;
    border-left: 3px solid #e5484d !important;
    background-color: #fef2f2 !important;
}

/* --- S7.10: Edit Track Dialog --- */
/* The Edit Track dialog (acs_track.view.EditTrackForm) is an Ext.Window.
   Apply the same dialog theming patterns used for other startpage dialogs
   (Save Search, Search In, etc.) — see S10 patterns. */

/* Dialog window chrome */
.x-window.x-window-plain.at-edit-track-dialog,
.x-window.x-window-plain[id*="editTrack"] {
    border-radius: 8px !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.16) !important;
}

/* Dialog header */
.analysis-track-dialog .x-window-header,
.x-window[id*="editTrack"] .x-window-header {
    background-color: #f5f7f9 !important;
    background-image: none !important;
    border-bottom: 1px solid #e2e6ec !important;
    padding: 12px 16px !important;
}

.analysis-track-dialog .x-window-header-text,
.x-window[id*="editTrack"] .x-window-header-text {
    color: #1c2127 !important;
    font-size: 15px !important;
    font-weight: 600 !important;
}

/* --- S7.10b: Job Progress Dialog (Export to PDF) --- */
/* The JobProgressDialog uses Ext.Window with cls='export-to-excel-modal',
   fixed height=150px. Our dialog padding overrides can cause content cropping.
   Force min-height:auto so content fits regardless of header padding changes. */
/* ===========================================================================
   BUCKET B: page-specific dialog variant (Phase 3 PR 3.3 — annotated;
   Phase 4 stripped the `body.acs-startpage` prefix).
   `.x-window.export-to-excel-modal` is the JobProgressDialog used by the
   bookshelf "Export to Excel" flow. Page-specific layout (progress bar
   placement, button-bar alignment) lives here; the `.x-window.export-to-
   excel-modal` selector itself is unique so the rules remain effectively
   page-scoped without the gate.
   =========================================================================== */
.x-window.export-to-excel-modal {
    min-height: 160px !important;
    height: auto !important;
}

.x-window.export-to-excel-modal .x-window-body {
    padding: 16px 20px !important;
    height: auto !important;
    min-height: 60px !important;
}

/* The wizard's progress bar starts hidden and is revealed once the job runs.
   ExtJS sizes these wrappers from the Window's fixed height:250 while the bar
   is still hidden, writes the result inline, and never re-lays-out on reveal,
   so the bar lands past the overflow:hidden cut and is clipped away.
   !important is required to beat that inline height. */
.x-window.export-to-excel-modal .x-plain,
.x-window.export-to-excel-modal .x-plain-bwrap,
.x-window.export-to-excel-modal .x-plain-body {
    height: auto !important;
    overflow: visible !important;
}

.x-window.export-to-excel-modal .job-status {
    font-size: 14px !important;
    font-weight: 600 !important;
    color: #1c2127 !important;
    display: inline-block !important;
    margin-bottom: 12px !important;
}

/* Progress bar inside JobProgressDialog.
   ExtJS ProgressBar structure:
   .x-progress-wrap > .x-progress-inner > .x-progress-bar (the fill)
   .x-progress-wrap > .x-progress-text (background text, behind the bar)
   .x-progress-bar > .x-progress-text-back (text over the filled part, clips to bar width) */
.x-window.export-to-excel-modal .x-progress-wrap {
    border: 1px solid #DCE2EF !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    background: #F6F8FB !important;
    height: 20px !important;
}

.x-window.export-to-excel-modal .x-progress-inner {
    background: #F6F8FB !important;
    height: 20px !important;
}

.x-window.export-to-excel-modal .x-progress-bar {
    background: linear-gradient(135deg, #00aeef 0%, #0098d4 100%) !important;
    border-radius: 0 !important;
    height: 20px !important;
}

/* Progress text — dual-layer: dark on white bg, white on blue bar.
   Structure: .x-progress-bar > .x-progress-text (inside bar, clipped = white)
              .x-progress-inner > .x-progress-text-back (behind bar, full width = dark) */
.x-window.export-to-excel-modal .x-progress-bar .x-progress-text {
    color: #fff !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    line-height: 20px !important;
}

.x-window.export-to-excel-modal .x-progress-text-back {
    color: #1c2127 !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    line-height: 20px !important;
}

/* S7.10d block removed 2026-05-15. The Export-to-Excel Run button is now
   themed by the shell-wide .dialog-ok-btn rule in ext-acs-theme.css (L1702).
   The earlier .x-btn-mc gradient override was painting a bright cyan that
   didn't match the muted-teal primary color used elsewhere in the theme. */

/* --- S7.11: Toolbar Overflow More Icon ---
   Replace ExtJS sprite >> icon with themed SVG chevrons-right.
   Phase 6 mask-image migration. */
.analysis-track .acs-big-toolbar .x-toolbar-more-icon {
    -webkit-mask-image: var(--icon-chevrons-right) !important;
            mask-image: var(--icon-chevrons-right) !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    transition: background-color 0.15s !important;
}

.analysis-track .acs-big-toolbar .x-btn-over .x-toolbar-more-icon {
    background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* --- S7.12: Note Row Vertical Alignment --- */
/* Align note icon, number, and text on the same baseline */
.analysis-track .trackItemNote td {
    vertical-align: middle !important;
    padding-top: 8px !important;
    padding-bottom: 8px !important;
}

/* The note icon is a mask, so centre the mask vertically, not a background */
.analysis-track .trackNoteIcon {
    -webkit-mask-position: 10px center !important;
            mask-position: 10px center !important;
    width: 30px !important;
}

/* =============================================
   S7.13: NOT INDEXED SUPPORTING DOCUMENT LIST DIALOG
   Dialog opened from search results toolbar (unsearchable files button).
   Uses acs.ExtEnhancedTreePanel with:
   - Toolbar: toc_expand, toc_collapse, toc_next, toc_prev
   - Sort buttons: attach_sort_toc (by sequence), attach_sort_alpha (A-Z)
   - Filter text field
   - Tree with toc_root, folder, and leaf node icons
   ============================================= */

/* --- S7.13a: Tree toolbar — white bg, subtle bottom border --- */


/* Remove 9-slice button chrome + azzurra dark hover bg —
   same pattern as the col-1 tree toolbar buttons. */




/* --- S7.13b: Tree toolbar icon base — SVG sizing + hover transition --- */




/* Expand all */



/* Collapse all */



/* Next */



/* Previous */



/* Refresh */



/* Sort by document sequence (TOC order) */



/* Sort alphabetically */



/* Clear filters */



/* --- S7.13c: Filter input — inherits page-wide .x-form-text + dialog
   .x-window .x-form-text rules (background, border, radius, focus).
   Override azzurra-legacy .x-small-editor height (20px) so the filter
   input matches other dialog inputs. */


/* Filter label text */


/* --- S7.13d: Tree container --- */




/* --- S7.13e: Tree node text --- */






/* --- S7.13f: Tree node hover/selected --- */








/* --- S7.13g: Tree node icons — SVG replacements --- */
/* Root node (toc_root) — library icon */


/* Folder nodes — collapsed/expanded */




/* Leaf nodes — file icon by default. Excludes nodes with an explicit
   iconCls (`fldr_user`, `fldr_real`, `book_img`, etc.) so those keep
   their semantic glyph. The Search-in dialog renders user-folders that
   contain only books as `leaf: true` server-side, but they still have
   `iconCls: fldr_user` and should display as folders, not file-text. */


/* Folder iconCls glyphs inside dialog trees — let the per-iconCls
   token win against the generic leaf rule when both apply (e.g. a
   leaf user-folder that should still render as a folder). */



/* --- S7.13h: Tree lines — subtle SVG chevrons for expand/collapse --- */






/* Hide tree lines (elbow connectors) */


/* --- S7.13i: Fix right-side clipping — ensure tree content fills window --- */




/* Tree scrollbar — thin styled */










/* =============================================================================
   HOME GEAR / CUSTOMIZE POPOVER
   Fixed-position gear button (bottom-left) with popover for card visibility
   toggles. Follows the overlay pattern from STYLING_PATTERNS.md Section 10.
   ============================================================================= */

/* Gear toolbar — fixed footer at bottom of the left panel */
.home-gear-toolbar {
    position: relative;
    background: #fff !important;
    background-image: none !important;
    border: none !important;
    border-top: 1px solid #ecf0f6 !important;
    padding: 6px 8px 8px !important;
    min-height: 44px !important;
}

/* Remove ExtJS toolbar inner table styling */
.home-gear-toolbar .x-toolbar-ct {
    display: none;
}

.home-gear {
    position: absolute;
    bottom: 12px;
    left: 12px;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: #8c95a0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.home-gear:hover {
    background: #f0f8fc;
    color: #5a6370;
}

.home-gear.active {
    background: #e6f5fb;
    color: #0e8bb0;
}

.home-customize {
    position: fixed;
    z-index: 19000;
    background: #fff;
    border: 1px solid #e2e6ec;
    border-radius: 10px;
    padding: 16px 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    min-width: 220px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.home-customize-title {
    font-size: 13px;
    font-weight: 600;
    color: #1c2127;
    margin-bottom: 12px;
}

.home-customize-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 0;
    font-size: 13px;
    color: #1c2127;
    cursor: pointer;
}

.home-customize-item input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #0e8bb0;
    cursor: pointer;
}

/* ===== LOADING MASK CENTERING ===== */
/* Ensure loading mask is always centered in the grid, even on first render */
.search-results-panel .ext-el-mask-msg,
.search-results-panel .x-mask-loading {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    margin: 0 !important;
}

/* ===== EMPTY STATE PLACEHOLDERS ===== */
/* Content follows the home-app empty state (mock_home_screen.html lines 308-324).
   Full-height panes anchor it near the top instead of centring it: on a tall
   screen the centre falls far below the col-1 form the user is reading. */
.empty-state-panel {
    background: #fff !important;
    position: relative !important;
}

.empty-state-panel .x-panel-body {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    box-sizing: border-box !important;
    padding-top: clamp(48px, 20vh, 200px) !important;
    display: flex !important;
    align-items: flex-start !important;
    justify-content: center !important;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 28px 20px;
    text-align: center;
}

.empty-state-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #b0b8c4;
    margin-bottom: 12px;
}

.empty-state-icon svg {
    display: block;
}

.empty-state h3 {
    font-size: 16px;
    font-weight: 600;
    color: #1c2127;
    margin: 0 0 8px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.empty-state p {
    font-size: 13px;
    color: #5a6370;
    line-height: 1.5;
    margin: 0 0 14px;
    max-width: 320px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.empty-state-hint {
    font-size: 12px;
    color: #8c95a0;
    font-style: italic;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ===== SEARCH TIPS SHEET (STYLING_PATTERNS 29.7) ===== */
/* The Search page's empty state: clickable example queries in two columns. The sheet is tall, so it
   starts closer to the top than a one-line empty state, level with the form's first fields. */
.search-tips-panel .x-panel-body {
    overflow: auto !important;
    padding-top: clamp(16px, 6vh, 56px) !important;
}

.search-tips-sheet p {
    max-width: 420px;
}

.search-tips {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 260px));
    gap: 10px 14px;
    list-style: none;
    margin: 4px 0 18px;
    padding: 0;
    width: 100%;
    max-width: 560px;
    justify-content: center;
}

@media (max-width: 1100px) {
    .search-tips {
        grid-template-columns: minmax(0, 320px);
    }
}

/* Each row's cards share the row's height: the item is a flex box and the button fills it. */
.search-tip {
    display: flex;
}

.search-tip-button {
    display: block;
    flex: 1 1 auto;
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    text-align: left;
    background: var(--acs-card-bg, #fff);
    border: 1px solid var(--acs-border, #e2e6ec);
    border-radius: var(--acs-radius-sm, 4px);
    font-family: var(--acs-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);
    cursor: pointer;
}

.search-tip-button:hover,
.search-tip-button:focus-visible {
    border-color: var(--acs-brand-cyan, #00aeef);
    background: var(--acs-brand-cyan-wash, #f0f8fc);
    outline: none;
}

.search-tip-query {
    display: block;
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 13px;
    font-weight: 600;
    color: var(--acs-brand-cyan-muted, #0e8bb0);
    margin-bottom: 3px;
}

.search-tip-text {
    display: block;
    font-size: 12px;
    line-height: 1.45;
    color: var(--acs-text-secondary, #5a6370);
}

/* The way back to the results shows only once a search has run. */
.search-tips-back {
    display: none;
    margin-top: 16px;
    padding: 8px 24px;
    background: var(--acs-card-bg, #fff);
    border: 1px solid var(--acs-border-input, #dce2ef);
    border-radius: 4px;
    color: var(--acs-text-secondary, #5a6370);
    font-family: var(--acs-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);
    font-size: 13px;
    font-weight: 500;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    cursor: pointer;
}

.search-tips-panel-has-results .search-tips-back {
    display: inline-block;
}

.search-tips-back:hover {
    background: var(--acs-hover-bg, #f6f8fb);
    border-color: var(--acs-brand-cyan, #00aeef);
    color: var(--acs-brand-cyan, #00aeef);
}

/* ===== BOOK INFO PANEL (right-side detail view) ===== */
/* Modern styling for the panel shown when a book is selected */

/* Info panel table — full width, icon column shrinks to fit */
.book-info-panel table.x-table-layout {
    width: 100% !important;
}

.book-info-panel td.x-table-layout-cell:first-child {
    width: 130px !important;
    min-width: 130px !important;
    text-align: center;
    vertical-align: top !important;
}

.book-info-panel .book-info-icon {
    padding: 20px !important;
}

.book-info-panel img.img-icon {
    max-width: 90px;
    height: auto;
    border-radius: 6px;
    margin-top: 0 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Fallback icon when book image fails to load or is default.
   Phase 6 Step 6.1: card surface bg-color stays on the parent;
   the glyph rides a ::before pseudo so its mask + cyan fill don't
   collide with the panel's grey card surface. */
.book-info-panel .img-icon-fallback {
    display: block;
    position: relative;
    width: 90px;
    height: 110px;
    margin: 0 auto;
    background-color: #F6F8FB;
    border: 1px solid #DCE2EF;
    border-radius: 8px;
}

.book-info-panel .img-icon-fallback::before {
    content: '';
    position: absolute;
    inset: 0;
    -webkit-mask-image: var(--icon-shelf-book);
            mask-image: var(--icon-shelf-book);
    -webkit-mask-size: 56px 56px;
            mask-size: 56px 56px;
    -webkit-mask-position: center;
            mask-position: center;
    -webkit-mask-repeat: no-repeat;
            mask-repeat: no-repeat;
    background-color: var(--acs-brand-cyan, #00aeef);
    opacity: 0.6;
}

/* Description cell — left-aligned */
.book-info-panel td.cell-description {
    text-align: left !important;
}

/* Description text */
.book-info-panel div.table-description {
    padding: 20px 20px 12px 8px !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
}

.book-info-panel div.table-description h4 {
    font-size: 16px !important;
    font-weight: 600 !important;
    color: #1c2127 !important;
    margin-bottom: 12px !important;
    line-height: 1.3 !important;
}

.book-info-panel div.table-description p {
    font-size: 13px !important;
    color: #5a6370 !important;
    line-height: 1.6 !important;
    margin-bottom: 2px !important;
}

.book-info-panel div.table-description p span {
    color: #8c95a0 !important;
}

/* Table of contents tree — full width, left-aligned */
.book-info-panel td.tree-panel-content-cell {
    width: 100% !important;
    text-align: left !important;
}

.book-info-panel .tree-panel-content-cell .x-panel-body {
    padding: 0 12px 12px 12px !important;
}

.book-info-panel .tree-panel-content-cell .x-tree-root-ct {
    width: 100% !important;
}

.book-info-panel div.tree-panel-content span {
    color: #1c2127 !important;
    font-size: 13px !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
}

.book-info-panel #tocTree div.tree-panel-header {
    background-color: #EEF6FB !important;
    border-radius: 4px !important;
    padding: 6px 10px !important;
}

.book-info-panel div.tree-panel-content div.tree-panel-header span {
    color: #1c2127 !important;
    font-size: 13px !important;
    font-weight: 600 !important;
}

.book-info-panel div.tree-panel-content li.x-tree-node .x-tree-node-over,
.book-info-panel div.tree-panel-content li.x-tree-node .x-tree-node-over a span {
    color: #00aeef !important;
    text-decoration: none !important;
    background-color: transparent !important;
}

.book-info-panel div.tree-panel-content li.x-tree-node a:hover span {
    color: #00aeef !important;
}

/* TOC expand/collapse chevrons. The tree runs in useArrows mode, which paints
   the legacy azzurra arrows.gif as the img's background. These are replaced
   <img> elements, so mask-image can't recolor them — swap the rendered glyph
   via `content:` (the SVG inherits `currentColor`) and drop the GIF.
   -plus = collapsed (chevron-right), -minus = expanded (chevron-down). */
.book-info-panel #tocTree img.x-tree-ec-icon.x-tree-elbow-plus,
.book-info-panel #tocTree img.x-tree-ec-icon.x-tree-elbow-end-plus {
    content: var(--icon-chevron-right) !important;
    width: 14px !important;
    height: 14px !important;
    background-image: none !important;
    color: var(--acs-text-secondary, #5a6370) !important;
    vertical-align: middle !important;
    cursor: pointer !important;
    transition: color 0.15s !important;
}
.book-info-panel #tocTree img.x-tree-ec-icon.x-tree-elbow-minus,
.book-info-panel #tocTree img.x-tree-ec-icon.x-tree-elbow-end-minus {
    content: var(--icon-chevron-down) !important;
    width: 14px !important;
    height: 14px !important;
    background-image: none !important;
    color: var(--acs-text-secondary, #5a6370) !important;
    vertical-align: middle !important;
    cursor: pointer !important;
    transition: color 0.15s !important;
}
.book-info-panel #tocTree .x-tree-node-el:hover > .x-tree-ec-icon {
    color: var(--acs-brand-cyan, #00aeef) !important;
}

/* =============================================================================
   NAV RAIL — vertical nav rail in the west region
   =============================================================================
   Mock reference: docs/welcome_page/mocks/mock_library_navbar_proposal.html §nav-list
   (lines 477-557). Tokens: --sp-* (defined at top of this file).
   A2 may relocate generic rules (border-left active pill, etc.) to
   ext-acs-theme.css.
   ============================================================================= */
.nav-rail-v2 {
    background: var(--sp-card-bg);
    border-right: 1px solid var(--sp-border);
    overflow: hidden;
    height: 100%;
}

.nav-rail-v2 .x-panel-body,
.nav-rail-v2 .x-panel-bwrap {
    background: var(--sp-card-bg);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.nav-rail-v2 .nav-v2-top {
    display: flex;
    align-items: center;
    /* 2026-05-28: "NAVIGATE" caption removed; the toggle button is the only
       child here now, so anchor it to the right edge. */
    justify-content: flex-end;
    padding: 8px 12px;
    min-height: 40px;
    border-bottom: 1px solid var(--sp-border-light);
}

.nav-rail-v2 .nav-v2-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--sp-text-tertiary);
    font-weight: 700;
}

.nav-rail-v2--collapsed .nav-v2-title {
    display: none;
}

.nav-rail-v2 .nav-v2-toggle {
    background: transparent;
    border: 1px solid var(--sp-border);
    border-radius: 6px;
    width: 26px;
    height: 26px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--sp-text-secondary);
    padding: 0;
}

.nav-rail-v2 .nav-v2-toggle:hover {
    background: var(--sp-brand-cyan-tint);
    color: var(--sp-brand-cyan);
    border-color: var(--sp-brand-cyan);
}

.nav-rail-v2 .nav-v2-toggle-icon {
    display: inline-block;
    width: 14px;
    height: 14px;
    background-color: currentColor;
    -webkit-mask-image: var(--icon-chevron-right);
    mask-image: var(--icon-chevron-right);
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-size: contain;
    mask-size: contain;
    transform: rotate(180deg); /* chevron points left when expanded (collapse hint) */
    transition: transform 180ms ease;
}

.nav-rail-v2--collapsed .nav-v2-toggle-icon {
    transform: rotate(0deg); /* points right when collapsed (expand hint) */
}

.nav-rail-v2 .nav-v2-list {
    list-style: none;
    margin: 0;
    padding: 4px 0;
    flex: 1;
    overflow-y: auto;
}

.nav-rail-v2 .nav-v2-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 18px 10px 15px;
    color: var(--sp-text-primary);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    position: relative;
    white-space: nowrap;
    border-left: 3px solid transparent;
    border-bottom: 1px solid var(--sp-border-light);
    user-select: none;
}

/* Hover — cyan wash + cyan text + cyan border accent. The cyan-wash is
   lighter than the active-state tint, so active stays visibly bolder. */
.nav-rail-v2 .nav-v2-item:hover {
    background: var(--sp-brand-cyan-wash);
    color: var(--sp-brand-cyan);
    border-left-color: var(--sp-brand-cyan);
}

/* Active state — cyan-tint bg (deeper than hover wash) + cyan text +
   3px cyan border + bold weight. Provides the clearer "you are here"
   affordance per docs/theme/PALETTE.md "Per-card identity" pattern. */
.nav-rail-v2 .nav-v2-item--active {
    background: var(--sp-brand-cyan-tint);
    color: var(--sp-brand-cyan);
    border-left-color: var(--sp-brand-cyan);
    font-weight: 700;
}

/* Active wins over hover: re-state the active rule when both apply
   (user hovers the active item) so active doesn't collapse to the
   lighter hover wash. */
.nav-rail-v2 .nav-v2-item--active:hover {
    background: var(--sp-brand-cyan-tint);
    color: var(--sp-brand-cyan);
    border-left-color: var(--sp-brand-cyan);
}

/* §3.B.4 — drop-target affordance on the My Selections rail icon when
   the user drags a book over it. Stronger than `:hover` (full
   border-left + dashed outline) so the user clearly sees that
   continuing to drop here will route into the My Selections tree.
   The `:hover` pseudo isn't reliable on touch devices, so we toggle
   this class via JS in `_wireRailDropTargets` instead. */
.nav-rail-v2 .nav-v2-item--drop-active {
    background: var(--sp-brand-cyan-tint);
    color: var(--sp-brand-cyan);
    border-left-color: var(--sp-brand-cyan);
    outline: 1px dashed var(--sp-brand-cyan);
    outline-offset: -3px;
}

/* Module-tinted active state for AffiniAI (purple). THEME_GUIDE.md §1.2. */
.nav-rail-v2 .nav-v2-item--module-ai.nav-v2-item--active {
    background: #F7EDFB;
    color: #B261D5;
    border-left-color: #B261D5;
}

.nav-rail-v2 .nav-v2-icon {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    background-color: currentColor;
    /* Force-clear any background-image leaked by theme-icons.css utility
       classes (e.g. `.icon-search`, `.icon-library`, `.icon-book`,
       `.icon-file-check`, `.icon-file-text`) which match the rail's icon
       <span> via its bare per-icon class. We use only mask-image for the
       glyph; the utility-class background-image would paint a grey-stroked
       layer on top of the mask, producing the "partial black, partial
       cyan" effect. §2.6. */
    background-image: none !important;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-size: contain;
    mask-size: contain;
}

/* Per-icon mask wiring. All tokens come from shared-icons.css with
   `stroke='currentColor'` SVGs so the icon flips cleanly to the
   parent's text colour when active. (Phase 6 Step 7 retired the old
   theme-icons.css token-shadowing layer that previously forced the
   search/library/book/file-check/file-text rules to inline data URIs.) */
.nav-rail-v2 .nav-v2-icon.icon-home       { -webkit-mask-image: var(--icon-home);       mask-image: var(--icon-home); }
.nav-rail-v2 .nav-v2-icon.icon-affinidocs { -webkit-mask-image: var(--icon-affinidocs); mask-image: var(--icon-affinidocs); }
.nav-rail-v2 .nav-v2-icon.icon-sparkles   { -webkit-mask-image: var(--icon-sparkles);   mask-image: var(--icon-sparkles); }
.nav-rail-v2 .nav-v2-icon.icon-bookmark   { -webkit-mask-image: var(--icon-bookmark);   mask-image: var(--icon-bookmark); }
.nav-rail-v2 .nav-v2-icon.icon-search     { -webkit-mask-image: var(--icon-search);     mask-image: var(--icon-search); }
.nav-rail-v2 .nav-v2-icon.icon-library    { -webkit-mask-image: var(--icon-library);    mask-image: var(--icon-library); }
.nav-rail-v2 .nav-v2-icon.icon-book       { -webkit-mask-image: var(--icon-book);       mask-image: var(--icon-book); }
.nav-rail-v2 .nav-v2-icon.icon-file-check { -webkit-mask-image: var(--icon-file-check); mask-image: var(--icon-file-check); }
.nav-rail-v2 .nav-v2-icon.icon-file-text  { -webkit-mask-image: var(--icon-file-text);  mask-image: var(--icon-file-text); }

/* Collapsed state — icon-only rail. */
.nav-rail-v2--collapsed .nav-v2-item {
    justify-content: center;
    padding: 10px 0;
}

.nav-rail-v2--collapsed .nav-v2-label {
    display: none;
}

/* Discover section — promo cards above the gear in the rail's bottom
   slot. Mock: docs/welcome_page/mocks/mock_library_navbar_proposal.html
   lines 533-557, 2429-2435. It keeps the rail's white, not the mock's grey:
   the column next to the rail is that grey on every view, so a grey block
   read as the page running into the rail. The top line is its divider. */
.nav-rail-v2 .nav-v2-promos {
    border-top: 1px solid var(--sp-border-light);
    padding: 10px 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.nav-rail-v2 .nav-v2-promos-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--sp-text-tertiary);
    font-weight: 600;
    margin: 2px 6px 4px;
}

.nav-rail-v2--collapsed .nav-v2-promos-title {
    display: none;
}

.nav-rail-v2 .nav-v2-promo {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border: 1px solid var(--sp-border-light);
    /* 3px module-coloured left border reinforces the dot — two identity
       signals per card (dot + border-left), both VIVID per the
       vivid-vs-muted rule (THEME_GUIDE §1.2). Per-module border colours
       are set in the module variants below. */
    border-left-width: 3px;
    border-radius: 6px;
    color: var(--sp-text-secondary);
    font-size: 12px;
    background: var(--sp-card-bg);
    cursor: pointer;
    box-sizing: border-box;
}

/* Default hover (overridden per module below) — kept for back-compat in
   case any future promo variant doesn't carry a module class. */
.nav-rail-v2 .nav-v2-promo:hover {
    border-color: var(--sp-brand-cyan);
    color: var(--sp-brand-cyan);
    background: var(--sp-brand-cyan-wash);
}

/* Keyboard focus ring: --sp-brand-cyan is the theme focus-ring colour.
   !important beats the legacy .ext-webkit :focus reset. */
.nav-rail-v2 .nav-v2-promo:focus-visible {
    outline: 2px solid var(--sp-brand-cyan) !important;
    outline-offset: 2px !important;
}

.nav-rail-v2 .nav-v2-promo .nav-v2-promo-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    flex: 0 0 auto;
}

/* Product name — plain text, inherits `color` from the parent
   .nav-v2-promo so hover recolours it with the rest of the card. */
.nav-rail-v2 .nav-v2-promo .nav-v2-promo-name {
    flex: 1 1 auto;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* DISCOVER promo dots — module *identity* moments (not chrome accents).
   Per the vivid-vs-muted rule (THEME_GUIDE §1.2), identity moments use
   the VIVID module color (--sp-*-green / -purple / -tag), not the muted
   variant. This matches the home-app card top-accent strips which also
   use vivid values. Muted module variants (--sp-task-green-muted, etc.)
   are for chrome hover-states and large fills only. */
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--core .nav-v2-promo-dot { background: var(--sp-brand-cyan); }
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--task .nav-v2-promo-dot { background: var(--sp-task-green); }
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--ai   .nav-v2-promo-dot { background: var(--sp-ai-purple); }
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--tag  .nav-v2-promo-dot { background: var(--sp-tag-red); }

/* Per-module border-left colour — pairs with the dot to give each card
   two coordinated identity signals. Same VIVID module hex as the dot. */
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--core { border-left-color: var(--sp-brand-cyan); }
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--task { border-left-color: var(--sp-task-green); }
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--ai   { border-left-color: var(--sp-ai-purple); }
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--tag  { border-left-color: var(--sp-tag-red); }

/* Per-module hover — each card lights up in its own module wash + text
   + border colour, matching the home-app card row-hover pattern. Hover
   *backgrounds* are pre-mixed light washes (NOT the muted variant —
   see vivid-vs-muted rule in THEME_GUIDE §1.2). */
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--core:hover {
    background: var(--sp-brand-cyan-tint);  /* #e6f5fb */
    color: var(--sp-brand-cyan);
    border-color: var(--sp-brand-cyan);
}
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--task:hover {
    background: #e6f7f0;                    /* green wash */
    color: var(--sp-task-green);
    border-color: var(--sp-task-green);
}
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--ai:hover {
    background: #f5e9fb;                    /* purple wash */
    color: var(--sp-ai-purple);
    border-color: var(--sp-ai-purple);
}
.nav-rail-v2 .nav-v2-promo.nav-v2-promo--tag:hover {
    background: #fde6ed;                    /* red wash */
    color: var(--sp-tag-red);
    border-color: var(--sp-tag-red);
}

.nav-rail-v2--collapsed .nav-v2-promo {
    justify-content: center;
    padding: 7px;
}

.nav-rail-v2--collapsed .nav-v2-promo .nav-v2-promo-name {
    display: none;
}

/* Discover panel window chrome. */
.nav-v2-discover-window .x-window-body { padding: 0 !important; background: var(--sp-card-bg) !important; border: 0 !important; }
/* ExtJS's .x-window-mc ships `padding: 16px 16px 0` which makes the
   top of the body heavier than the bottom. Zero it out so our dialog's
   own padding is the single source of truth. */
.nav-v2-discover-window .x-window-mc { padding: 0 !important; }
.nav-v2-discover-window { border-radius: 10px; overflow: hidden; }

/* ====================================================================
   Discover panels (ext-acs-startpage.js → _showDiscoverDialog).
   The accent defaults to AffiniCore blue; a product class sets its own.
   The AffiniAI contact dialog (.affiniai-contact-window) also uses these rules.
   ==================================================================== */
.nav-v2-cta-window { --cta: var(--sp-docs-blue); --cta-deep: var(--sp-brand-cyan-deep); --cta-rgb: 0,179,250; --cta-wash: var(--sp-brand-cyan-wash); --cta-tint: var(--sp-brand-cyan-tint); }
.nav-v2-cta-window--affiniai { --cta: #9b50b8; --cta-deep: #7a3f93; --cta-rgb: 155,80,184; --cta-wash: #faf2fc; --cta-tint: #ede3f2; }
.nav-v2-cta-window--affinitag { --cta: var(--sp-tag-red); --cta-deep: #b8123f; --cta-rgb: 254,35,93; --cta-wash: #fff4f7; --cta-tint: #ffe3ea; }
.nav-v2-cta-window--affinitask { --cta: var(--sp-task-green-muted); --cta-deep: #137a5e; --cta-rgb: 26,158,122; --cta-wash: #effaf6; --cta-tint: #dcf5ea; }
.nav-v2-cta-window .x-window-body { padding: 0 !important; background: var(--sp-card-bg) !important; border: 0 !important; }

.nav-v2-cta { background: var(--sp-card-bg); display: flex; flex-direction: column; max-height: 86vh; }
/* The panel takes focus on a click inside it, so Esc still closes; it never shows a ring. */
.nav-v2-cta:focus { outline: none; }

/* Header: brand glyph + wordmark. 3px accent top edge. */
.nav-v2-cta-head {
    display: flex; align-items: center; gap: 12px;
    padding: 18px 22px 16px; position: relative; flex: 0 0 auto;
    background: linear-gradient(180deg, rgba(var(--cta-rgb),.07), rgba(var(--cta-rgb),0) 80%);
}
.nav-v2-cta-head::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 3px; background: var(--cta); }
.nav-v2-cta-head .nav-v2-promo-icon { width: 38px; height: 38px; flex: 0 0 auto; }
.nav-v2-cta-head .nav-v2-promo-icon svg { width: 100%; height: 100%; display: block; }
.nav-v2-cta-head-text { margin-right: auto; }
.nav-v2-cta-eyebrow {
    font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 11px;
    letter-spacing: .09em; text-transform: uppercase; color: var(--cta-deep); margin: 0 0 2px;
}
.nav-v2-cta-title {
    font-family: 'Manrope', sans-serif; font-weight: 800; font-size: 20px;
    letter-spacing: -0.04em; line-height: 1.15; color: var(--sp-text-primary); margin: 0;
}

.nav-v2-cta-body { padding: 20px 22px; overflow-y: auto; flex: 1 1 auto; }

.nav-v2-cta-demo { display: block; text-align: center; margin-top: 14px; font-size: 12.5px; color: var(--sp-text-secondary); text-decoration: none; }
.nav-v2-cta-demo:hover { color: var(--cta); }
.nav-v2-cta-demo b { color: var(--cta-deep); font-weight: 600; }

/* Buttons. */
.nav-v2-cta .cta-btn {
    font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 13.5px;
    border-radius: 8px; padding: 11px 16px; cursor: pointer; border: 1px solid transparent;
    transition: filter .15s ease, background .15s ease, border-color .15s ease;
    display: inline-flex; align-items: center; gap: 8px; justify-content: center;
}
.nav-v2-cta .cta-btn-primary { background: var(--cta); color: #fff; flex: 1; }
.nav-v2-cta .cta-btn-primary:hover { filter: brightness(1.06); }
.nav-v2-cta .cta-btn-primary:disabled { opacity: .5; cursor: not-allowed; filter: none; }
.nav-v2-cta .cta-btn-secondary { background: #fff; color: var(--cta-deep); border-color: var(--sp-border-input); flex: 1; }
.nav-v2-cta .cta-btn-secondary:hover { background: var(--cta-wash); border-color: var(--cta); }
.nav-v2-cta .cta-btn-ghost { background: transparent; color: var(--sp-text-secondary); border-color: var(--sp-border-input); }
.nav-v2-cta .cta-btn-ghost:hover { background: rgba(28,33,39,.04); color: var(--sp-text-primary); }

/* Panes: one view of a panel at a time. */
.nav-v2-cta .cta-pane { display: none; }
.nav-v2-cta .cta-pane.is-active { display: block; }
@keyframes navV2CtaFade { from { opacity: 0; transform: translateX(6px); } to { opacity: 1; transform: none; } }

.nav-v2-cta .cta-pane-head { display: flex; align-items: center; gap: 8px; margin: 0 0 16px; }
.nav-v2-cta .cta-pane-head h3 { font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 16px; letter-spacing: -0.02em; margin: 0; }
.nav-v2-cta .cta-pane-back {
    border: 0; background: transparent; cursor: pointer; color: var(--sp-text-secondary);
    font-size: 13px; padding: 4px 8px 4px 4px; border-radius: 6px; display: inline-flex; align-items: center; gap: 4px;
}
.nav-v2-cta .cta-pane-back:hover { background: rgba(28,33,39,.05); color: var(--sp-text-primary); }

/* Form controls. */
.nav-v2-cta .cta-field { margin-bottom: 14px; }
.nav-v2-cta .cta-field.cta-row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.nav-v2-cta .cta-field label { display: block; font-size: 12.5px; font-weight: 600; color: var(--sp-text-primary); margin-bottom: 5px; }
.nav-v2-cta .cta-field label .req { color: #d6336c; margin-left: 2px; }
.nav-v2-cta .cta-control {
    width: 100%; box-sizing: border-box; font-family: inherit; font-size: 13.5px; color: var(--sp-text-primary);
    background: #fff; border: 1px solid var(--sp-border-input); border-radius: 7px; padding: 9px 11px;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.nav-v2-cta .cta-control:focus { outline: none; border-color: var(--cta); box-shadow: 0 0 0 3px rgba(var(--cta-rgb),.16); }
.nav-v2-cta textarea.cta-control { resize: vertical; min-height: 64px; }
.nav-v2-cta select.cta-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235a6370' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 10px center; padding-right: 32px;
}
.nav-v2-cta .cta-control.invalid { border-color: #d6336c; }
.nav-v2-cta .cta-err { color: #d6336c; font-size: 11.5px; margin-top: 4px; display: none; }
.nav-v2-cta .cta-err.show { display: block; }
.nav-v2-cta .cta-hint { color: var(--sp-text-tertiary); font-size: 11.5px; margin: 4px 0 0; }
.nav-v2-cta .cta-pane-actions { display: flex; gap: 10px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--sp-border-light); }

/* Discover forms: paired fields, value bands, sample marker, answer box. */
.nav-v2-cta [hidden] { display: none !important; }
.nav-v2-cta .cta-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.nav-v2-cta .cta-field .opt { font-weight: 400; color: var(--sp-text-tertiary); }
.nav-v2-cta .cta-answer { display: none; margin: 2px 0 0; padding: 10px 12px; border-radius: 7px; background: #fdecf2; color: #a61e4d; font-size: 12.5px; line-height: 1.5; }
.nav-v2-cta .cta-answer.show { display: block; }
.nav-v2-cta .cta-answer a { color: inherit; font-weight: 700; text-decoration: underline; }
/* Add a Party: one card per party, up to ten. */
.nav-v2-cta .cta-party { border: 1px solid var(--sp-border-light); border-radius: 9px; padding: 10px 12px 0; margin-bottom: 10px; }
.nav-v2-cta .cta-party-head { display: flex; justify-content: space-between; align-items: center; min-height: 24px; margin-bottom: 8px; }
.nav-v2-cta .cta-party-title { font-family: 'Manrope', sans-serif; font-weight: 800; font-size: 11px; letter-spacing: .07em; text-transform: uppercase; color: var(--sp-text-tertiary); }
.nav-v2-cta .cta-party-remove { width: 24px; height: 24px; padding: 0; border: 0; border-radius: 6px; background: none; color: var(--sp-text-tertiary); font-size: 18px; line-height: 1; cursor: pointer; }
.nav-v2-cta .cta-party-remove:hover { background: var(--cta-wash); color: var(--sp-text-primary); }
.nav-v2-cta .cta-party-remove:disabled { opacity: .5; cursor: not-allowed; }
.nav-v2-cta .cta-party-add { width: 100%; }
.nav-v2-cta .cta-party-add:disabled { opacity: .5; cursor: not-allowed; background: #fff; border-color: var(--sp-border-input); }

/* Keyboard focus inside a panel, in its accent. !important beats the legacy .ext-webkit :focus reset. */
.nav-v2-cta .cta-btn:focus-visible,
.nav-v2-cta .cta-pane-back:focus-visible,
.nav-v2-cta .cta-party-remove:focus-visible,
.nav-v2-cta a:focus-visible,
.nav-v2-cta-window .x-tool-close:focus-visible { outline: 2px solid var(--cta) !important; outline-offset: 2px !important; }

/* Success. */
.nav-v2-cta .cta-success { text-align: center; padding: 12px 8px 4px; }
.nav-v2-cta .cta-check { width: 56px; height: 56px; border-radius: 50%; margin: 0 auto 16px; background: rgba(26,158,122,.12); display: grid; place-items: center; color: var(--sp-task-green-muted); }
.nav-v2-cta .cta-check svg { width: 30px; height: 30px; }
.nav-v2-cta .cta-success h3 { font-family: 'Manrope', sans-serif; font-weight: 800; font-size: 19px; letter-spacing: -0.02em; margin: 0 0 8px; }
.nav-v2-cta .cta-success p { color: var(--sp-text-secondary); font-size: 13.5px; line-height: 1.55; margin: 0 auto 20px; max-width: 42ch; }
.nav-v2-cta .cta-success .cta-btn-primary { margin: 0 auto; flex: none; }

/* --------------------------------------------------------------------
   Showcase: the wide (up to 1040px) product overview of each Discover
   panel. The window width is set in JS (_fitDiscoverWindow).
   -------------------------------------------------------------------- */
.nav-v2-cta .cta-showcase { animation: navV2CtaFade .2s ease; }

/* Hero band: copy + stat strip on a tinted gradient. */
.cta-sc-hero {
    display: grid; grid-template-columns: 1.5fr 1fr; gap: 28px; align-items: center;
    padding: 26px 28px; border-radius: 12px; margin-bottom: 22px;
    background: linear-gradient(135deg, rgba(var(--cta-rgb),.10), rgba(var(--cta-rgb),.02) 70%);
    border: 1px solid var(--sp-border-light);
}
.cta-sc-eyebrow { font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 11px; letter-spacing: .09em; text-transform: uppercase; color: var(--cta-deep); margin: 0 0 8px; }
.cta-sc-hero-title { font-family: 'Manrope', sans-serif; font-weight: 800; font-size: 26px; line-height: 1.18; letter-spacing: -0.035em; color: var(--sp-text-primary); margin: 0 0 12px; }
.cta-sc-hero-lede { font-size: 14px; line-height: 1.6; color: var(--sp-text-secondary); margin: 0 0 18px; }
.cta-sc-hero-actions { display: flex; gap: 10px; }
.cta-sc-hero-actions .cta-btn { flex: 0 0 auto; }
.cta-sc-hero-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cta-sc-hero-stats .cta-sc-stat--wide { grid-column: 1 / -1; }
.cta-sc-hero .nav-v2-cta-demo { text-align: left; }
.cta-sc-stat { background: #fff; border: 1px solid var(--sp-border-light); border-radius: 10px; padding: 14px 16px; }
.cta-sc-stat .n { font-family: 'Manrope', sans-serif; font-weight: 800; font-size: 20px; letter-spacing: -0.03em; color: var(--cta-deep); }
.cta-sc-stat .l { font-size: 11.5px; line-height: 1.35; color: var(--sp-text-secondary); margin-top: 3px; }

.cta-sc-section { margin-bottom: 26px; }
.cta-sc-h3 { font-family: 'Manrope', sans-serif; font-weight: 800; font-size: 19px; letter-spacing: -0.03em; color: var(--sp-text-primary); margin: 0 0 8px; }
.cta-sc-section-lede { font-size: 13.5px; line-height: 1.6; color: var(--sp-text-secondary); margin: 0 0 16px; max-width: 70ch; }

/* Foundation: copy + "stops having to" problem checklist (two columns). */
.cta-sc-foundation { display: grid; grid-template-columns: 1fr 1.2fr; gap: 28px; align-items: start; }
.cta-sc-foundation-copy p { font-size: 13.5px; line-height: 1.6; color: var(--sp-text-secondary); margin: 6px 0 0; }
.cta-sc-problems { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; }
.cta-sc-problems li { display: flex; align-items: flex-start; gap: 9px; font-size: 12.5px; line-height: 1.4; color: var(--sp-text-primary); }
.cta-sc-x { width: 18px; height: 18px; flex: 0 0 auto; border-radius: 50%; background: rgba(254,35,93,.10); color: #d6336c; display: grid; place-items: center; margin-top: 1px; }
.cta-sc-x svg { width: 11px; height: 11px; }

/* Capability cards (3-up grid). */
.cta-sc-caps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.cta-sc-cap { background: var(--sp-surface-soft); border: 1px solid var(--sp-border-light); border-radius: 10px; padding: 16px; }
.cta-sc-cap h4 { font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 14px; letter-spacing: -0.01em; color: var(--sp-text-primary); margin: 0 0 6px; }
.cta-sc-cap p { font-size: 12.5px; line-height: 1.5; color: var(--sp-text-secondary); margin: 0; }

/* Belief blocks (two side by side; second carries the accent). */
.cta-sc-beliefs { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 26px; }
.cta-sc-belief { background: #fff; border: 1px solid var(--sp-border); border-radius: 12px; padding: 20px 22px; }
.cta-sc-belief h4 { font-family: 'Manrope', sans-serif; font-weight: 800; font-size: 16px; letter-spacing: -0.02em; margin: 0 0 8px; color: var(--sp-text-primary); }
.cta-sc-belief p { font-size: 13px; line-height: 1.6; color: var(--sp-text-secondary); margin: 0; }
.cta-sc-belief-accent { border-color: var(--cta); background: var(--cta-wash); }
.cta-sc-belief-accent h4 { color: var(--cta-deep); }

/* Case study cards (3-up). */
.cta-sc-cases { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.cta-sc-case { border: 1px solid var(--sp-border-light); border-radius: 10px; padding: 16px; display: flex; flex-direction: column; gap: 10px; transition: border-color .15s ease, box-shadow .15s ease; cursor: pointer; }
.cta-sc-case:hover { border-color: var(--cta); box-shadow: 0 6px 20px rgba(28,33,39,.08); }
a.cta-sc-case, a.cta-sc-case:hover { color: inherit; text-decoration: none; }
.cta-sc-case-meta { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.cta-sc-case-client { font-family: 'Manrope', sans-serif; font-weight: 700; font-size: 13.5px; color: var(--sp-text-primary); }
.cta-sc-case-loc { font-size: 11px; color: var(--sp-text-tertiary); }
.cta-sc-case-title { display: block; font-size: 12.5px; line-height: 1.45; color: var(--sp-text-secondary); margin: 0; flex: 1; }
.cta-sc-case-link { font-family: 'Manrope', sans-serif; font-weight: 600; font-size: 12px; color: var(--cta-deep); }

/* Closing CTA band. */
.cta-sc-cta-band { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding: 22px 24px; border-radius: 12px; background: var(--sp-dark); }
.cta-sc-band-title { font-family: 'Manrope', sans-serif; font-weight: 800; font-size: 20px; letter-spacing: -0.03em; color: #fff; margin: 0 0 4px; }
.cta-sc-band-sub { font-size: 13px; color: rgba(255,255,255,.72); margin: 0; }
.cta-sc-band-actions { display: flex; gap: 10px; align-items: center; }
.cta-sc-band-actions .cta-btn { flex: 0 0 auto; }
.cta-sc-band-actions .cta-btn-secondary { background: rgba(255,255,255,.10); color: #fff; border-color: rgba(255,255,255,.28); }
.cta-sc-band-actions .cta-btn-secondary:hover { background: rgba(255,255,255,.18); border-color: rgba(255,255,255,.5); }
.cta-sc-band-actions .cta-btn-ghost { color: rgba(255,255,255,.85); border-color: rgba(255,255,255,.28); text-decoration: none; }
.cta-sc-band-actions .cta-btn-ghost:hover { background: rgba(255,255,255,.10); color: #fff; }

/* Responsive collapse for the wide showcase on smaller viewports. */
@media (max-width: 920px) {
    .cta-sc-hero, .cta-sc-foundation { grid-template-columns: 1fr; }
    .cta-sc-caps, .cta-sc-cases, .cta-sc-beliefs, .cta-sc-problems { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 620px) {
    .cta-sc-caps, .cta-sc-cases, .cta-sc-beliefs, .cta-sc-problems, .cta-sc-hero-stats { grid-template-columns: 1fr; }
}

/* AffiniAI contact dialog (Home promo card request buttons). Built in
   ext-acs-startpage.js → _showAffiniAiContactDialog on top of the
   AffiniCore dialog's .nav-v2-cta and .cta-* rules, in AffiniAI purple. */
.affiniai-contact-window { --cta: var(--acs-ai-purple-muted, #9b50b8); --cta-deep: var(--acs-ai-purple-deep, #7a3f93); }
.affiniai-contact-window .nav-v2-cta-head { background: linear-gradient(180deg, rgba(155,80,184,.08), rgba(155,80,184,0) 80%); }
.affiniai-contact-window .cta-control:focus { box-shadow: 0 0 0 3px rgba(155,80,184,.18); }
.affiniai-contact-window .affiniai-contact-intro { font-size: 13.5px; line-height: 1.55; color: var(--sp-text-secondary); margin: 0 0 16px; }
.affiniai-contact-window .affiniai-contact-answer { display: none; margin: 2px 0 0; padding: 10px 12px; border-radius: 7px; background: #fdecf2; color: #a61e4d; font-size: 12.5px; line-height: 1.5; }
.affiniai-contact-window .affiniai-contact-answer.show { display: block; }
.affiniai-contact-window .affiniai-contact-answer a { color: inherit; font-weight: 700; text-decoration: underline; }
.affiniai-contact-window .cta-success h3:focus,
.affiniai-contact-window .nav-v2-cta-title:focus { outline: none; }

/* N5: bottom slot of the rail. Hosts the home-gear-btn (Customize Home).
   The Discover promos block (above) sits between the nav list and this
   slot, settings-tray convention — gear stays last. */
.nav-rail-v2 .nav-v2-bottom {
    border-top: 1px solid var(--sp-border-light);
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    background: var(--sp-card-bg);
}

.nav-rail-v2--collapsed .nav-v2-bottom {
    justify-content: center;
}

/* Reposition the home-gear button when it lives in the rail bottom slot
   (instead of the legacy .home-gear-toolbar absolute layout). */
.nav-rail-v2 .nav-v2-bottom .home-gear {
    position: static;
    bottom: auto;
    left: auto;
}

/* =============================================================================
   N4 TWO-COLUMN — col-1 (tree, tinted) + col-2 (content, white)
   =============================================================================
   Mock reference: docs/welcome_page/mocks/mock_library_navbar_proposal.html §col-tree
   (lines 562+). Applied to all rail-driven sections: BROWSE/SELECTIONS share
   browseTwoCol (col-1 card-swaps libraryTree/mySelectionsTree), Saved Search
   uses savedSearchTwoCol, Analysis Track uses tracksTwoCol. All three carry
   the `.tree-twocol` class for shared styling. Rendered only when the navbar
   v2 flag is on. N5 will fold these into a single generic treeColumn.
   ============================================================================= */
/* Col-1 (tree / search form) is grey between the white nav rail and the
   white col-2; a lighter tint does not read as a separate column. The
   col-1 ↔ col-2 boundary is the tone gap plus this border (at most two
   signals per boundary, so no shadow on col-2). */
.browse-two-col .browse-tree-column,
.tree-twocol .tree-twocol-tree {
    background: var(--sp-surface);
    border-right: 1px solid var(--sp-border-strong);
}

.browse-two-col .browse-tree-column .x-panel-body,
.browse-two-col .browse-tree-column .x-panel-bwrap,
.tree-twocol .tree-twocol-tree .x-panel-body,
.tree-twocol .tree-twocol-tree .x-panel-bwrap {
    background: var(--sp-surface);
}

/* =============================================================================
   §3.A.15 — col-1 ↔ col-2 drag-resize handle
   =============================================================================
   Restores the col-1 ↔ col-2 resize affordance lost when the rail refactor
   moved col-1 into a fixed-width hbox child. _setupColResizers wires
   Ext.Resizable (handles: 'e', pinned: true) on each tree-col panel; this
   block tames the vendor handle to match the shared split bar in
   ext-acs-widgets.css (SPLIT BARS) — invisible 12px hit area, the grip in
   the middle and a blue glow on hover. The `.tree-col`'s existing 1px
   `border-right` already supplies the resting visual line so we don't
   double-paint it here.

   Note: Ext.Resizable adds .x-resizable-pinned to the panel's el so the
   handle is always interactive (cursor: ew-resize on hover).
   ============================================================================= */
.tree-col.x-resizable-pinned > .x-resizable-handle-east,
.tree-col > .x-resizable-handle-east {
    width: 12px !important;
    right: -6px !important;
    top: 0 !important;
    height: 100% !important;
    background: transparent !important;
    background-image: none !important;
    cursor: ew-resize !important;
    opacity: 1 !important;
    filter: none !important;
    z-index: 6 !important;
}

/* The handle's middle is half a pixel left of the border it sits on, so the
   hover line and the grip are centred on calc(50% + 0.5px). */
.tree-col > .x-resizable-handle-east::before {
    content: '' !important;
    display: block !important;
    position: absolute !important;
    top: 0 !important;
    bottom: 0 !important;
    left: calc(50% + 0.5px) !important;
    transform: translateX(-50%) !important;
    width: 3px !important;
    background: transparent !important;
    transition: background 0.15s !important;
}

.tree-col > .x-resizable-handle-east:hover::before {
    background: rgba(0, 174, 239, 0.3) !important;
}

/* The hover line replaces the sidebar's border, as on the shared split bar,
   instead of tinting over it. */
.tree-col:has(> .x-resizable-handle-east:hover) {
    border-right-color: transparent !important;
}

.tree-col > .x-resizable-handle-east::after {
    content: '' !important;
    position: absolute !important;
    top: 50% !important;
    left: calc(50% + 0.5px) !important;
    transform: translate(-50%, -50%) !important;
    width: 2px !important;
    height: 20px !important;
    border-radius: 1px !important;
    background: var(--acs-text-tertiary, #8c95a0) !important;
    transition: background 0.15s !important;
}

.tree-col > .x-resizable-handle-east:hover::after {
    background: var(--acs-brand-cyan, #00aeef) !important;
}

/* =============================================================================
   COL-1 SEARCH PILL (M1.1)
   =============================================================================
   Mock: docs/welcome_page/mocks/mock_library_navbar_proposal.html §BROWSE @line 2443
   (.col-search). Renders a global library search above the tree-toolbar in
   col-1. Submit routes to the Search view with the entered query (same
   semantics as the prior in-accordion quick-search). The field is an
   ExtJS TwinTriggerField (acs_search.SearchField); we host it inside a
   dedicated `.browse-col-search` container and override every layer of
   ExtJS chrome (panel-body, form-element, twin-triggers, etc.) to match
   the mock pill exactly.
   ============================================================================= */

/* Outer container — natural height driven by inner pill (30px) + padding
   (10px top, 10px bottom). ExtJS-rendered .x-panel-body / .x-box-inner
   chrome is forced transparent + bordered to inherit the column tint. */
.browse-col-search,
.browse-col-search .x-panel-body,
.browse-col-search .x-panel-bwrap,
.browse-col-search .x-box-inner {
    background: var(--sp-surface) !important;  /* match col-1 surface */
    border: 0 !important;
}
/* IMPORTANT: do NOT put horizontal padding on `.browse-col-search` itself
   — it's a vbox box-item, and ExtJS's vbox-stretch (Ext 3.x) subtracts
   the child's CSS horizontal padding from its computed width, leaving
   a visible right-side gap inside the column. Top/bottom padding is
   safe; the 12px horizontal gutter lives on the inner form-element
   wrapper below. */
.browse-col-search {
    padding: 10px 0 !important;
    border-bottom: 1px solid var(--sp-border-light) !important;
    box-sizing: border-box !important;
    height: auto !important;
}

/* The vbox parent (browseTreeColumn) wraps each child in an .x-box-item.
   The global `.x-box-item { display: inline-block }` rule (line 786)
   defeats the vbox-stretch inline width — force block so the row honors
   the explicit width set by the JS layout. */
.browse-col-search.x-box-item {
    display: block !important;
}

/* If ExtJS renders an .x-form-element / .x-form-item wrapper, neutralize
   it (with `layout: 'fit'` on the col-search container the field-wrap
   is a direct child, so these usually don't render). */
.browse-col-search .x-form-element,
.browse-col-search .x-form-item {
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
}

/* The field-wrap is the positioning anchor for the floating clear-X
   inside the pill (the magnifier itself is a background-image on the
   input — no separate element). Strip its own border / background so
   only the input below carries the pill chrome. The 12px horizontal
   padding here applies the column gutter — we can't put it on the
   outer box-item (`.browse-col-search`) because Ext 3.x vbox-stretch
   subtracts a child's CSS horizontal padding from its computed width. */
.browse-col-search .x-form-field-wrap {
    position: relative !important;
    width: 100% !important;
    height: 30px !important;
    display: block !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    margin: 0 !important;
    padding: 0 12px !important;
    border: 0 !important;
    background: transparent !important;
}

/* The pill itself. Mock §BROWSE @line 577–589 (.col-search input):
     height 30px, padding 6px 12px 6px 30px, 1px solid var(--sp-border-light),
     border-radius var(--sp-radius-md) (6px), background transparent,
     color var(--sp-text-primary).
   Hover (line 584): border-color → var(--sp-border-input).
   Focus (line 585–589): background var(--sp-card-bg), border-color
     var(--sp-brand-cyan), box-shadow var(--sp-focus-ring)
     (= 0 0 0 3px rgba(0,174,239,0.25)).
   Magnifier glyph painted in the left padding by the field-wrap
   ::before pseudo at L7178 — keeps the icon color independent of
   the input text color (mock L590-594 has the icon at
   var(--sp-text-tertiary), not the input's text color). */
.browse-col-search input.x-form-text.col-search-field {
    width: 100% !important;
    height: 30px !important;
    margin: 0 !important;
    padding: 6px 28px 6px 30px !important;
    background-color: transparent !important;
    background-image: none !important;
    border: 1px solid var(--sp-border-light) !important;
    border-radius: 6px !important;
    color: var(--sp-text-primary) !important;
    font-size: 13px !important;
    line-height: 18px !important;
    box-sizing: border-box !important;
    box-shadow: none !important;
    outline: none !important;
}

.browse-col-search input.x-form-text.col-search-field::placeholder {
    color: var(--sp-text-tertiary) !important;
}

/* ExtJS 3.x doesn't use the native placeholder attribute — when the
   input is empty, it sets input.value to the configured emptyText and
   adds .x-form-empty-field. Color the "fake placeholder" tertiary
   grey to match the mock; the class drops as soon as the user types. */
.browse-col-search input.x-form-text.col-search-field.x-form-empty-field {
    color: var(--sp-text-tertiary) !important;
}

.browse-col-search input.x-form-text.col-search-field:hover {
    border-color: var(--sp-border-input) !important;
}

.browse-col-search input.x-form-text.col-search-field:focus {
    background-color: var(--sp-card-bg) !important;
    border-color: var(--sp-brand-cyan) !important;
    box-shadow: 0 0 0 3px rgba(0, 174, 239, 0.25) !important;
}

/* Search magnifier glyph rendered as a ::before on the field-wrap
   (the input's parent, .x-form-field-wrap), positioned absolutely
   inside the input's left padding. mask-image + background-color
   keeps the icon color independent of the input's text color
   (mock §BROWSE L590-594: .col-search .s-ico { color:
   var(--sp-text-tertiary) }). */
.browse-col-search .x-form-field-wrap {
    position: relative !important;
}

/* Icon positioned 10px from the input's left edge. The wrap has
   padding-left: 12px (ExtJS default), so 10px from the input edge
   = 22px from the wrap's outer edge. */
.browse-col-search .x-form-field-wrap::before {
    content: '' !important;
    position: absolute !important;
    left: 22px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 14px !important;
    height: 14px !important;
    -webkit-mask-image: var(--icon-search) !important;
            mask-image: var(--icon-search) !important;
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    -webkit-mask-position: center !important;
            mask-position: center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-color: var(--sp-text-tertiary) !important;
    pointer-events: none !important;
    z-index: 1 !important;
}

/* Hide the search trigger entirely — magnifier lives inside the input
   left padding; Enter submits via SearchField specialkey handler. */
.browse-col-search .x-form-search-trigger {
    display: none !important;
}

/* §1.1a — drop the clear-X entirely. Mock has only the magnifier on the
   left; the X was perpetually misaligned. Users can clear via Esc or
   select-all-and-delete. */
.browse-col-search .x-form-twin-triggers {
    display: none !important;
}

/* The field's placeholder example (ExtJS emptyText) reads as a hint, not as a value. */
.search_panel .search-wrap .x-form-text.x-form-empty-field {
    color: var(--acs-text-tertiary, #8c95a0) !important;
}

/* The search tips button in the Text Filters header, drawn like a field trigger: an inline SVG
   painted through `color`, not a CSS mask, so it stays as crisp as the magnifier. */
.search_panel .x-fieldset.text-filters > legend {
    position: relative !important;
}

.search_panel .text-filters .search-tips-trigger {
    position: absolute;
    top: 50%;
    right: 4px;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    padding: 0;
    border: 0;
    border-radius: var(--acs-radius-sm, 4px);
    background: transparent;
    color: var(--acs-text-secondary, #5a6370);
    cursor: pointer;
    transition: background-color 0.15s, color 0.15s;
}

.search_panel .text-filters .search-tips-trigger > svg {
    display: block;
    pointer-events: none;
}

.search_panel .text-filters .search-tips-trigger:hover,
.search_panel .text-filters .search-tips-trigger:focus-visible {
    background-color: #e8ecf1;
    color: var(--acs-brand-cyan, #00aeef);
    outline: none;
}

/* The FoldersTree (libraryTree / mySelectionsTree) carries a rootTitle
   panel header ("Browse Library" / "My Selections") that the accordion
   era hid via the accordion frame. With the rail layout the tree is
   rendered as the only item in col-1's card-swap, so the header would
   show as a dark cyan strip — suppress it (mock §BROWSE has no such
   header in col-1). */
/* §3.A.13 — applies to all four tree col-1s (Browse, My Selections,
   Saved Search, Analysis Tracks). `.tree-col` is the shared scope on
   every col-1 tree-container; suppression here covers all of them.
   The `.search-form-col` extension covers the Search route's col-1
   (which carries `tree-col` too but the inner panel had a `Search`
   title — see §5.7). */
.tree-col .x-tree-node-leftpanel > .x-panel-header,
.tree-col > .x-panel-header {
    display: none !important;
}

/* =============================================================================
   TREE STYLING IN COL-1
   =============================================================================
   Library / Selections / Saved Search / Tracks trees live inside `.tree-col`
   wrappers (col-1 of each twoCol section). Selection / hover state, toolbar
   icons, and tree-node inline action icons are scoped here. Folder icons are
   scoped to `.x-tree-node` higher up in this file.
   ============================================================================= */

/* --- Tree row selection / hover --- */
.tree-col .x-tree-node .x-tree-selected,
.tree-col .x-tree-node div.x-tree-selected,
.tree-col .x-tree-selected {
    background: #EEF6FB !important;
    border-left: none !important;
}

.tree-col .x-tree-node .x-tree-selected a,
.tree-col .x-tree-node .x-tree-selected a span,
.tree-col .x-tree-selected a,
.tree-col .x-tree-selected a span {
    color: var(--sp-brand-cyan) !important;
    background: transparent !important;
    font-weight: 500 !important;
}

.tree-col .x-tree-node .x-tree-node-over,
.tree-col .x-tree-node div.x-tree-node-over,
.tree-col .x-tree-node-over {
    background: rgba(0, 174, 239, 0.06) !important;
}

/* Hover tints the label cyan-muted (mock §BROWSE @line 748–749, M1.4). */
.tree-col .x-tree-node .x-tree-node-over a,
.tree-col .x-tree-node .x-tree-node-over a span,
.tree-col .x-tree-node-over a,
.tree-col .x-tree-node-over a span {
    color: var(--sp-brand-cyan-muted) !important;
    background: transparent !important;
}

.tree-col .x-tree-node .x-tree-selected.x-tree-node-over,
.tree-col .x-tree-selected.x-tree-node-over {
    background: #EEF6FB !important;
}

/* Resting node text — near-black + medium weight so labels read clearly
   against the grey col-1 surface (--sp-surface). The previous
   var(--sp-text) was undefined, so text fell back to the azzurra-legacy
   grey (#31373d / weight 400) and sat too lightly. Selected/active nodes
   keep their own cyan colour via the more-specific rules above/below. */
.tree-col .x-tree-node a,
.tree-col .x-tree-node a span {
    color: var(--sp-text-primary) !important;
    font-weight: 500 !important;
}

/* --- Tree toolbar icons ---
   Phase 6 mask-image: bg-color drives the cyan tint at rest (matches mock
   §BROWSE @line 635 `.tree-toolbar .t-btn { color: var(--sp-brand-cyan) }`);
   per-button mask-image rules below supply the glyph. Rest opacity 0.85,
   hover 1 — same look as the legacy bg-image cascade. */
.tree-col .tb_expand_folder,
.tree-col .tb_collapse_folder,
.tree-col .refresh_icon,
.tree-col .toc_expand,
.tree-col .toc_collapse,
.tree-col .toc_next,
.tree-col .toc_prev,
.tree-col .preference_btn,
.tree-col .sort_btn,
.tree-col .sort_desc_btn,
.tree-col .sort_acs_btn,
.tree-col .sort_orig_btn {
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-brand-cyan, #00aeef) !important;
    opacity: 0.85 !important;
    transition: opacity 0.15s !important;
}

.tree-col .tb_expand_folder:hover,
.tree-col .tb_collapse_folder:hover,
.tree-col .refresh_icon:hover,
.tree-col .toc_expand:hover,
.tree-col .toc_collapse:hover,
.tree-col .toc_next:hover,
.tree-col .toc_prev:hover,
.tree-col .preference_btn:hover,
.tree-col .sort_btn:hover,
.tree-col .sort_desc_btn:hover,
.tree-col .sort_acs_btn:hover,
.tree-col .sort_orig_btn:hover,
.tree-col .x-btn-over .tb_expand_folder,
.tree-col .x-btn-over .tb_collapse_folder,
.tree-col .x-btn-over .refresh_icon,
.tree-col .x-btn-over .toc_expand,
.tree-col .x-btn-over .toc_collapse,
.tree-col .x-btn-over .toc_next,
.tree-col .x-btn-over .toc_prev,
.tree-col .x-btn-over .preference_btn,
.tree-col .x-btn-over .sort_btn,
.tree-col .x-btn-over .sort_desc_btn,
.tree-col .x-btn-over .sort_acs_btn,
.tree-col .x-btn-over .sort_orig_btn {
    opacity: 1 !important;
}

/* Tree node inline action icons.
   Step-7 prep: mask-image so bg-color drives the static grey fill;
   no colour change on :hover, only opacity bumps to 1 (preserved). */
.tree-col .x-tree-node-plus,
.tree-col .x-tree-node-minus,
.tree-col .x-tree-node-refresh {
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    opacity: 0.6 !important;
    transition: opacity 0.15s !important;
}

.tree-col .x-tree-node-plus {
    -webkit-mask-image: var(--icon-plus) !important;
            mask-image: var(--icon-plus) !important;
}

.tree-col .x-tree-node-minus {
    -webkit-mask-image: var(--icon-minus) !important;
            mask-image: var(--icon-minus) !important;
}

.tree-col .x-tree-node-refresh {
    -webkit-mask-image: var(--icon-refresh) !important;
            mask-image: var(--icon-refresh) !important;
}

.tree-col .x-tree-node-plus:hover,
.tree-col .x-tree-node-minus:hover,
.tree-col .x-tree-node-refresh:hover {
    opacity: 1 !important;
}

/* Tree node icon variants for selections/saved-search/tracks (mirrors L2202+).
   Step-7 prep: mask-image, static grey, no colour change on row :hover. */
.tree-col .x-tree-node-myselicon,
.tree-col img.x-tree-node-icon.x-tree-node-myselicon,
.tree-col .x-tree-node-aticon,
.tree-col img.x-tree-node-icon.x-tree-node-aticon,
.tree-col .x-tree-node-ssicon,
.tree-col img.x-tree-node-icon.x-tree-node-ssicon,
.tree-col .x-icon-private,
.tree-col img.x-tree-node-icon.x-icon-private,
.tree-col .x-icon-shared,
.tree-col img.x-tree-node-icon.x-icon-shared,
.tree-col .x-icon-public,
.tree-col img.x-tree-node-icon.x-icon-public {
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-size: 16px 16px !important;
            mask-size: 16px 16px !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
}

.tree-col .x-tree-node-myselicon,
.tree-col img.x-tree-node-icon.x-tree-node-myselicon {
    -webkit-mask-image: var(--icon-folder-cog) !important;
            mask-image: var(--icon-folder-cog) !important;
}

.tree-col .x-tree-node-aticon,
.tree-col img.x-tree-node-icon.x-tree-node-aticon {
    -webkit-mask-image: var(--icon-clipboard-list) !important;
            mask-image: var(--icon-clipboard-list) !important;
}

.tree-col .x-tree-node-ssicon,
.tree-col img.x-tree-node-icon.x-tree-node-ssicon {
    -webkit-mask-image: var(--icon-search) !important;
            mask-image: var(--icon-search) !important;
}

.tree-col .x-icon-private,
.tree-col img.x-tree-node-icon.x-icon-private,
.tree-col .x-icon-shared,
.tree-col img.x-tree-node-icon.x-icon-shared,
.tree-col .x-icon-public,
.tree-col img.x-tree-node-icon.x-icon-public {
    -webkit-mask-image: var(--icon-folder) !important;
            mask-image: var(--icon-folder) !important;
}

/* =============================================================================
   TREE — MOCK ALIGNMENT (M1)
   =============================================================================
   Mock: docs/welcome_page/mocks/mock_library_navbar_proposal.html §BROWSE
   - tree-toolbar: 4px 8px padding, light bottom border, transparent bg
     (mock @line 630)
   - tree rows: 13px font, 24px line-height, 6px-10px padding, hover #F6F8FB
     muted-cyan text, selected #EEF6FB tint only (mock @line 660)
   - row-menu: three-dot button revealed on hover, popover with Expand/
     Collapse actions replacing the ExtJS native context menu
     (mock @line 682)
   ============================================================================= */

/* Tree column body — surface tint, no internal scrollbar (the tree itself
   scrolls). The default ExtJS panel-body bg/borders are killed elsewhere
   (browseTreeColumn rules) but the inner card-swap and tree shells need
   their own treatment. */
.browse-tree-column .x-tree-node-leftpanel,
.browse-tree-column .x-tree-node-leftpanel .x-panel-body {
    background: var(--sp-surface) !important;
    border: 0 !important;
}

/* --- Tree toolbar — match mock §BROWSE @line 630 ---
   The element wears `.x-toolbar.x-toolbar-layout-ct` and contains an
   inner `<table class="x-toolbar-ct">` that holds the buttons. ExtJS's
   inner table is 24px tall (button height); we let the outer hug the
   table rather than imposing a `min-height` that the table can't fill
   (which would leave the button row visually off-centre with empty
   space below). */
.tree-col .x-toolbar,
.tree-col .x-toolbar.x-small-editor,
.tree-col .x-toolbar-layout-ct {
    background: var(--sp-surface) !important;
    background-image: none !important;
    border: 0 !important;
    border-bottom: 1px solid var(--sp-border-light) !important;
    padding: 4px 8px !important;
    height: auto !important;
    min-height: 0 !important;
}

/* Toolbar button hit-target — 28×28 with flat hover (§3.A.14, mock
   @line 635). ExtJS 3 wraps each button in a table where the outer
   `<table class="x-btn">` is the hover hit-target and the inner
   `<button class="x-btn-text">` carries the icon background-image.
   Treat them differently: outer paints the bg + border, inner stays
   sized to fit the icon and never has its bg-image touched. */
.tree-col .x-toolbar .x-btn {
    min-width: 28px !important;
    min-height: 28px !important;
    border: 1px solid transparent !important;
    border-radius: 6px !important;
    margin: 0 1px !important;
    background: transparent !important;
    transition: background-color 0.12s !important;
}
/* Specificity stacked to beat azzurra-legacy's
   `.x-toolbar.x-toolbar.x-toolbar.x-toolbar .x-btn.x-btn-over` (5 cls).
   Stacking `.x-toolbar` four times here yields equivalent specificity,
   plus the `.tree-col` prefix wins via source order. */
.tree-col .x-toolbar.x-toolbar.x-toolbar.x-toolbar .x-btn:hover,
.tree-col .x-toolbar.x-toolbar.x-toolbar.x-toolbar .x-btn.x-btn-over {
    background: var(--sp-brand-cyan-tint, rgba(0, 174, 239, 0.08)) !important;
    border-color: transparent !important;
}

/* Neutralise the ExtJS sprite cell-chrome inside tree-toolbar buttons —
   defensive: even though they currently render with `background-image:
   none`, a future ExtJS upgrade or theme could re-introduce the sprite
   tiles. Keep them transparent so only the outer .x-btn paints the bg. */
.tree-col .x-toolbar .x-btn .x-btn-tl,
.tree-col .x-toolbar .x-btn .x-btn-tc,
.tree-col .x-toolbar .x-btn .x-btn-tr,
.tree-col .x-toolbar .x-btn .x-btn-ml,
.tree-col .x-toolbar .x-btn .x-btn-mc,
.tree-col .x-toolbar .x-btn .x-btn-mr,
.tree-col .x-toolbar .x-btn .x-btn-bl,
.tree-col .x-toolbar .x-btn .x-btn-bc,
.tree-col .x-toolbar .x-btn .x-btn-br {
    background: transparent !important;
    background-image: none !important;
    border: 0 !important;
}

/* --- Tree rows — match mock §BROWSE @line 660 --- */
/* azzurra-legacy.css:1586 sets `.x-tree-node-el { background-color: white }`
   on every non-hovered/non-selected row, which leaks through the surface
   tint. Force transparent so the col-1 bg shows through; selected/hover
   rules below paint their own backgrounds. */
.tree-col .x-tree-node-el {
    line-height: 24px !important;
    height: 24px !important;
    padding: 0 6px 0 4px !important;
    font-size: 13px !important;
    background: transparent !important;
    background-color: transparent !important;
}

.tree-col .x-tree-node-anchor,
.tree-col .x-tree-node-anchor span {
    font-size: 13px !important;
    line-height: 24px !important;
    vertical-align: middle !important;
}

/* Hover background: neutral slate so it shows on the grey col-1 and stays
   distinct from the blue selected row (#EEF6FB). */
.tree-col .x-tree-node .x-tree-node-over,
.tree-col .x-tree-node div.x-tree-node-over,
.tree-col .x-tree-node-over {
    background: rgba(15, 23, 42, 0.05) !important;
    border-radius: 4px !important;
}

/* Selected row — light cyan tint, rounded, no left border (mock @line
   659 "selected #EEF6FB tint only"). */
.tree-col .x-tree-node .x-tree-selected,
.tree-col .x-tree-node div.x-tree-selected,
.tree-col .x-tree-selected {
    border-radius: 4px !important;
}

/* --- Tree body breathing room ---
   Pad the tree-panel's body so the first / last rows aren't flush
   against the toolbar bottom-border or the column's lower edge. */
.tree-col .x-tree-node-leftpanel > .x-panel-bwrap > .x-panel-body {
    padding-top: 8px !important;
    padding-bottom: 8px !important;
}

/* --- Long-label truncation (Finder / VS Code / Notion convention) ---
   Tree rows must never horizontally scroll. The container clips
   horizontally; the row-menu dots get a 30px gutter so they never
   overlap text. The `.x-tree-node-anchor` is constrained to the
   available row width — short labels stay at natural width, long
   labels truncate with `…` (text-overflow only fires on overflow).
   Full text is surfaced via QuickTips (`qtip = node.text`, set in
   AbstractTreePanel's `append` listener). */
/* Clip wide tree-row labels at the panel body — that's the actual
   scroll container. Do NOT apply overflow-x to the inner .x-tree-root-ct
   UL: per the CSS spec, setting overflow-x to non-`visible` upgrades
   overflow-y from `visible` to `auto`, which spawns a 1-pixel scrollbar
   on the UL whenever scrollHeight rounds 1px above clientHeight (a
   common rendering quirk on this tree). The panel body's clip already
   covers wide labels — no need for a redundant clip on the UL. */
.tree-col .x-panel-body {
    overflow-x: hidden !important;
}

/* Flex layout on the row gives the anchor exactly "remaining space" —
   the indent spans and elbow/folder icons consume their natural width
   (`flex: 0 0 auto`), and the anchor takes the rest (`flex: 1 1 auto`)
   with `min-width: 0` so it can shrink below its content for ellipsis.
   The row reserves 36px on the right for the row-menu button (22px at
   right:6px = 28px, plus 8px breathing gap). */
.tree-col .x-tree-node-el {
    display: flex !important;
    align-items: center !important;
    padding-right: 36px !important;
}

.tree-col .x-tree-node-el > * {
    flex: 0 0 auto;
}

/* The anchor alone clips the label and draws the ellipsis: a second
   clipping box on every row slows large open trees (RM#9842). The two
   negative margins keep the label where the former inline-block span put
   it, for any font: that span's padding (azzurra-legacy) pushed its end
   5px past the anchor, and its 1px top and bottom padding raised the
   text by 0.5px. */
.tree-col .x-tree-node-el .x-tree-node-anchor {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    margin-top: -1px !important;
    margin-right: -5px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
}

.tree-col .x-tree-node-el .x-tree-node-anchor span {
    display: inline;
    white-space: nowrap;
    vertical-align: middle;
}

/* The absolute-positioned row-menu button is outside the flex flow
   (`position: absolute` removes it from flex layout) — keep it that way. */
.tree-col .x-tree-node-el > .row-menu-btn {
    flex: 0 0 auto;
}

/* When the row is hovered or selected the three-dot menu becomes visible —
   widen the right-gutter so the ellipsis pulls back further left and the
   trailing characters never sit underneath the dots. Without this, narrow
   col-1 widths cause the ellipsis to render directly behind the button. */
.tree-col .x-tree-node-el.x-tree-selected {
    padding-right: 40px !important;
}

@media (hover: hover) {
    .tree-col .x-tree-node-el.x-tree-node-hovered,
    .tree-col .x-tree-node-el.x-tree-node-over {
        padding-right: 40px !important;
    }
}

/* --- Three-dot row-menu (Notion / Linear pattern) --- */
/* The button is injected into each .x-tree-node-el on hover by
   FoldersTree's onTreeMouseover (see ext-acs-startpage-foldersTree.js).
   The CSS below mirrors mock @line 682. */
.tree-col .x-tree-node-el .row-menu-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 22px;
    height: 22px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--sp-text-secondary);
    opacity: 0;
    cursor: pointer;
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='%235a6370'%3E%3Ccircle cx='5' cy='12' r='2'/%3E%3Ccircle cx='12' cy='12' r='2'/%3E%3Ccircle cx='19' cy='12' r='2'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center center;
    transition: opacity 0.12s, background-color 0.12s;
    z-index: 2;
}

/* Reveal on the selected row and while the menu is open. */
.tree-col .x-tree-node .x-tree-selected .row-menu-btn,
.tree-col .x-tree-selected .row-menu-btn,
.tree-col .x-tree-node-el .row-menu-btn.row-menu-open {
    opacity: 0.8;
    pointer-events: auto;
}

/* Hover reveal only for a mouse or trackpad: iOS Safari drops a tap's
   click when the tap reveals the button. */
@media (hover: hover) {
    .tree-col .x-tree-node-el.x-tree-node-hovered .row-menu-btn,
    .tree-col .x-tree-node-el.x-tree-node-over .row-menu-btn,
    .tree-col .x-tree-node .x-tree-node-over .row-menu-btn,
    .tree-col .x-tree-node-over .row-menu-btn {
        opacity: 0.8;
        pointer-events: auto;
    }
}

.tree-col .x-tree-node-el .row-menu-btn:hover,
.tree-col .x-tree-node-el .row-menu-btn.row-menu-open {
    background-color: rgba(0, 0, 0, 0.06);
    opacity: 1;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='%2300aeef'%3E%3Ccircle cx='5' cy='12' r='2'/%3E%3Ccircle cx='12' cy='12' r='2'/%3E%3Ccircle cx='19' cy='12' r='2'/%3E%3C/svg%3E");
}

/* Make the node-el a positioning context for the absolute-positioned
   row-menu button. */
.tree-col .x-tree-node-el {
    position: relative !important;
}

/* --- Row-menu popover --- */
/* Injected as a sibling of the button when opened. Notion-style: small
   white card with two icon-rows. */
.row-menu-popover {
    position: absolute;
    min-width: 160px;
    background: var(--sp-card-bg);
    color: var(--sp-text-primary);
    border: 1px solid var(--sp-border, #d4dadf);
    border-radius: 6px;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.08);
    padding: 4px;
    z-index: 10000;
    font-size: 13px;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    user-select: none;
}

.row-menu-popover .rmi {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 4px;
    color: var(--sp-text-primary);
    cursor: pointer;
    white-space: nowrap;
    line-height: 18px;
    font-size: 12.5px;
}

.row-menu-popover .rmi:hover {
    background: var(--sp-brand-cyan-wash, rgba(0, 174, 239, 0.08));
    color: var(--sp-brand-cyan-muted, #0891b2);
}

.row-menu-popover .rmi .rmi-icon {
    width: 14px;
    height: 14px;
    flex: 0 0 14px;
    /* Step-7 prep: mask-image + bg-color: text-secondary so geometry
       and tint live on one rule. `!important` mask-position/-size
       overrides the legacy iconCls (e.g. `cmd_edit_track`,
       `delete_ss_icon`) which used to set bg-position offsets that
       would otherwise have pushed the theme-icon SVG off-screen. */
    -webkit-mask-position: center center !important;
            mask-position: center center !important;
    -webkit-mask-repeat: no-repeat !important;
            mask-repeat: no-repeat !important;
    -webkit-mask-size: 14px 14px !important;
            mask-size: 14px 14px !important;
    background-image: none !important;
    background-color: var(--acs-text-secondary, #5a6370) !important;
    opacity: 0.75;
}

.row-menu-popover .rmi:hover .rmi-icon {
    opacity: 1;
}

/* Row-menu popover icons.
   Trees declare each item with a `kind` (semantic CSS hook, used here)
   and an optional `iconCls` (legacy class also recognised by the
   existing `.x-menu` rules above for the right-click context menu).
   Both menus end up showing the same theme-icon SVG. The
   `kind`-based rules below are the canonical mapping for the row-menu;
   they use `!important` so the legacy classes' `!important`
   `background-image` (libraryswitcher.png sprite) cannot leak in
   when both classes are present on the same span.

   Phase 6 5b-fix-3: icon-on-hover colour swap rules removed (Browse
   Library / Saved Search / Analysis Track row-menu icons inherit
   mask-image from per-iconCls rules in 5b-1/5b-3, which masks the
   bg-image hover swap and makes the swap visually inert anyway).
   All four trees now keep their row-menu icons grey on hover, with
   only the menu-item background tinting via .rmi:hover. Matches the
   Layout / Sort dropdowns and the .x-menu context menu pattern. */
.row-menu-popover .rmi-expand .rmi-icon {
    -webkit-mask-image: var(--icon-folder-plus) !important;
            mask-image: var(--icon-folder-plus) !important;
}
.row-menu-popover .rmi-collapse .rmi-icon {
    -webkit-mask-image: var(--icon-folder-minus) !important;
            mask-image: var(--icon-folder-minus) !important;
}

/* My Selections action icons. */
.row-menu-popover .rmi-new-folder .rmi-icon {
    -webkit-mask-image: var(--icon-folder-plus) !important;
            mask-image: var(--icon-folder-plus) !important;
}
.row-menu-popover .rmi-delete-folder .rmi-icon,
.row-menu-popover .rmi-delete-all-books .rmi-icon,
.row-menu-popover .rmi-delete-book .rmi-icon {
    -webkit-mask-image: var(--icon-trash) !important;
            mask-image: var(--icon-trash) !important;
}
.row-menu-popover .rmi-rename-folder .rmi-icon {
    -webkit-mask-image: var(--icon-edit) !important;
            mask-image: var(--icon-edit) !important;
}

/* Saved Search action icons. */
.row-menu-popover .rmi-delete .rmi-icon {
    -webkit-mask-image: var(--icon-trash) !important;
            mask-image: var(--icon-trash) !important;
}
.row-menu-popover .rmi-edit .rmi-icon {
    -webkit-mask-image: var(--icon-edit) !important;
            mask-image: var(--icon-edit) !important;
}
.row-menu-popover .rmi-run .rmi-icon {
    -webkit-mask-image: var(--icon-play) !important;
            mask-image: var(--icon-play) !important;
}

/* Analysis Track action icons. */
.row-menu-popover .rmi-new .rmi-icon {
    -webkit-mask-image: var(--icon-circle-plus) !important;
            mask-image: var(--icon-circle-plus) !important;
}
.row-menu-popover .rmi-start .rmi-icon {
    -webkit-mask-image: var(--icon-play) !important;
            mask-image: var(--icon-play) !important;
}
.row-menu-popover .rmi-stop .rmi-icon {
    -webkit-mask-image: var(--icon-circle-stop) !important;
            mask-image: var(--icon-circle-stop) !important;
}

/* Fallback: any rmi row without a kind-specific mapping above shows
   a neutral circle-dot so we never leave an empty 14px gap. This is
   defined on the base `.rmi-icon` selector — kind-specific rules
   above use `!important` to win when matched. */
.row-menu-popover .rmi-icon {
    -webkit-mask-image: var(--icon-circle-dot);
            mask-image: var(--icon-circle-dot);
}

/* Destructive items get a softer red hover instead of cyan. */
.row-menu-popover .rmi-delete-folder:hover,
.row-menu-popover .rmi-delete-all-books:hover,
.row-menu-popover .rmi-delete-book:hover,
.row-menu-popover .rmi-delete:hover {
    background: rgba(220, 38, 38, 0.06);
    color: #b42424;
}

/* Section separator inside the popover. */
.row-menu-popover .rm-sep {
    height: 1px;
    background: var(--sp-border-light, #ECF0F6);
    margin: 4px 2px;
}

/* --- Tree row icons ---
   Every row of an open tree has a chevron and a folder or book icon. As
   faded masks they made each mouse move over a large open tree slow: up
   to 1.7 s with 35,000 open rows (RM#9842). So they are pre-coloured SVG
   backgrounds with the fade drawn into the SVG. The paths are copies of
   the shared --icon-folder, -folder-open, -folder-cog, -shelf-book,
   -chevron-right and -chevron-down tokens: update both together. */
.tree-col {
    --tree-icon-folder: url("data:image/svg+xml,%3Csvg opacity='0.7' xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2300aeef' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z'/%3E%3C/svg%3E");
    --tree-icon-folder-open: url("data:image/svg+xml,%3Csvg opacity='0.7' xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2300aeef' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2v2'/%3E%3C/svg%3E");
    --tree-icon-folder-cog: url("data:image/svg+xml,%3Csvg opacity='0.7' xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2300aeef' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10.5 20H4a2 2 0 0 1-2-2V5c0-1.1.9-2 2-2h3.93a2 2 0 0 1 1.66.9l.82 1.2a2 2 0 0 0 1.66.9H20a2 2 0 0 1 2 2v3'/%3E%3Ccircle cx='18' cy='18' r='3'/%3E%3Cpath d='M18 14v1'/%3E%3Cpath d='M18 21v1'/%3E%3Cpath d='M22 18h-1'/%3E%3Cpath d='M15 18h-1'/%3E%3Cpath d='M21 15l-.7.7'/%3E%3Cpath d='M15.7 20.3l-.7.7'/%3E%3Cpath d='M21 21l-.7-.7'/%3E%3Cpath d='M15.7 15.7l-.7-.7'/%3E%3C/svg%3E");
    --tree-icon-book: url("data:image/svg+xml,%3Csvg opacity='0.7' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 256 256' fill='%2300aeef'%3E %3Cpath d='M208,88H152V32Z' opacity='0.2'/%3E %3Cpath d='M213.66,82.34l-56-56A8,8,0,0,0,152,24H56A16,16,0,0,0,40,40V216a16,16,0,0,0,16,16H200a16,16,0,0,0,16-16V88A8,8,0,0,0,213.66,82.34ZM160,51.31,188.69,80H160ZM200,216H56V40h88V88a8,8,0,0,0,8,8h48V216Zm-32-80a8,8,0,0,1-8,8H96a8,8,0,0,1,0-16h64A8,8,0,0,1,168,136Zm0,32a8,8,0,0,1-8,8H96a8,8,0,0,1,0-16h64A8,8,0,0,1,168,168Z'/%3E %3C/svg%3E");
    --tree-icon-chevron-right: url("data:image/svg+xml,%3Csvg opacity='0.55' xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%235a6370' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='9 18 15 12 9 6'/%3E%3C/svg%3E");
    --tree-icon-chevron-down: url("data:image/svg+xml,%3Csvg opacity='0.55' xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%235a6370' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
}

/* Hovered and selected rows show their icon at full colour. */
.tree-col .x-tree-node-el:hover,
.tree-col .x-tree-node-over,
.tree-col .x-tree-selected {
    --tree-icon-folder: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2300aeef' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z'/%3E%3C/svg%3E");
    --tree-icon-folder-open: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2300aeef' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2v2'/%3E%3C/svg%3E");
    --tree-icon-folder-cog: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2300aeef' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10.5 20H4a2 2 0 0 1-2-2V5c0-1.1.9-2 2-2h3.93a2 2 0 0 1 1.66.9l.82 1.2a2 2 0 0 0 1.66.9H20a2 2 0 0 1 2 2v3'/%3E%3Ccircle cx='18' cy='18' r='3'/%3E%3Cpath d='M18 14v1'/%3E%3Cpath d='M18 21v1'/%3E%3Cpath d='M22 18h-1'/%3E%3Cpath d='M15 18h-1'/%3E%3Cpath d='M21 15l-.7.7'/%3E%3Cpath d='M15.7 20.3l-.7.7'/%3E%3Cpath d='M21 21l-.7-.7'/%3E%3Cpath d='M15.7 15.7l-.7-.7'/%3E%3C/svg%3E");
    --tree-icon-book: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 256 256' fill='%2300aeef'%3E %3Cpath d='M208,88H152V32Z' opacity='0.2'/%3E %3Cpath d='M213.66,82.34l-56-56A8,8,0,0,0,152,24H56A16,16,0,0,0,40,40V216a16,16,0,0,0,16,16H200a16,16,0,0,0,16-16V88A8,8,0,0,0,213.66,82.34ZM160,51.31,188.69,80H160ZM200,216H56V40h88V88a8,8,0,0,0,8,8h48V216Zm-32-80a8,8,0,0,1-8,8H96a8,8,0,0,1,0-16h64A8,8,0,0,1,168,136Zm0,32a8,8,0,0,1-8,8H96a8,8,0,0,1,0-16h64A8,8,0,0,1,168,168Z'/%3E %3C/svg%3E");
}

/* The chevron is at full colour on the hovered row only. */
.tree-col .x-tree-node-el:hover,
.tree-col .x-tree-node-over {
    --tree-icon-chevron-right: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%235a6370' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='9 18 15 12 9 6'/%3E%3C/svg%3E");
    --tree-icon-chevron-down: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%235a6370' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
}

/* --- Tree expand/collapse chevrons --- */
/* The col-1 trees still render the legacy ExtJS azzurra elbow sprite.
   Override with the modern chevron (mock @line 668: 10×10 glyph in a
   20×20 hit target). Rows that cannot expand keep an empty hit target. */
.tree-col .x-tree-ec-icon {
    background-image: none !important;
    background-color: transparent !important;
    width: 18px !important;
    height: 24px !important;
    opacity: 1 !important;
}

.tree-col .x-tree-node-collapsed .x-tree-ec-icon,
.tree-col img.x-tree-elbow-plus,
.tree-col img.x-tree-elbow-end-plus,
.tree-col .x-tree-node-expanded .x-tree-ec-icon,
.tree-col img.x-tree-elbow-minus,
.tree-col img.x-tree-elbow-end-minus {
    -webkit-mask-image: none !important;
            mask-image: none !important;
    background-size: 10px 10px !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
}

.tree-col .x-tree-node-collapsed .x-tree-ec-icon,
.tree-col img.x-tree-elbow-plus,
.tree-col img.x-tree-elbow-end-plus {
    background-image: var(--tree-icon-chevron-right) !important;
}

.tree-col .x-tree-node-expanded .x-tree-ec-icon,
.tree-col img.x-tree-elbow-minus,
.tree-col img.x-tree-elbow-end-minus {
    background-image: var(--tree-icon-chevron-down) !important;
}

/* Hide tree-line connectors (left over from azzurra). */
.tree-col img.x-tree-elbow,
.tree-col img.x-tree-elbow-end,
.tree-col img.x-tree-elbow-line {
    background-image: none !important;
}

/* Per-button mask-image — geometry + cyan fill come from the canonical
   .tree-col toolbar base rule above; each rule here just supplies the
   glyph. Migrated to mask-image in Phase 6 step-7 prep. */
.tree-col .tb_expand_folder,
.tree-col .toc_expand {
    -webkit-mask-image: var(--icon-folder-plus) !important;
            mask-image: var(--icon-folder-plus) !important;
}

.tree-col .tb_collapse_folder,
.tree-col .toc_collapse {
    -webkit-mask-image: var(--icon-folder-minus) !important;
            mask-image: var(--icon-folder-minus) !important;
}

.tree-col .refresh_icon {
    -webkit-mask-image: var(--icon-refresh) !important;
            mask-image: var(--icon-refresh) !important;
}

.tree-col .toc_next {
    -webkit-mask-image: var(--icon-chevron-down) !important;
            mask-image: var(--icon-chevron-down) !important;
}

.tree-col .toc_prev {
    -webkit-mask-image: var(--icon-chevron-up) !important;
            mask-image: var(--icon-chevron-up) !important;
}

.tree-col .preference_btn {
    -webkit-mask-image: var(--icon-sliders) !important;
            mask-image: var(--icon-sliders) !important;
}

.tree-col .sort_btn {
    -webkit-mask-image: var(--icon-sort) !important;
            mask-image: var(--icon-sort) !important;
}

.tree-col .sort_acs_btn {
    -webkit-mask-image: var(--icon-sort-asc) !important;
            mask-image: var(--icon-sort-asc) !important;
}

.tree-col .sort_desc_btn {
    -webkit-mask-image: var(--icon-sort-desc) !important;
            mask-image: var(--icon-sort-desc) !important;
}

.tree-col .sort_orig_btn {
    -webkit-mask-image: var(--icon-list-restart) !important;
            mask-image: var(--icon-list-restart) !important;
}

/* Tree folder and book icons: brand cyan, faded at rest and full on the
   hovered or selected row (the --tree-icon-* properties above). */
.tree-col .x-tree-node img.fldr_real,
.tree-col .x-tree-node img.fldr_link,
.tree-col .x-tree-node img.fldr_marker,
.tree-col .x-tree-node img.fldr_download,
.tree-col .x-tree-node img.fldr_workspace,
.tree-col .x-tree-node-collapsed img.fldr_real,
.tree-col .x-tree-node-collapsed img.fldr_link,
.tree-col .x-tree-node-collapsed img.fldr_marker,
.tree-col .x-tree-node-collapsed img.fldr_download,
.tree-col .x-tree-node-collapsed img.fldr_workspace,
.tree-col img.x-tree-node-icon.fldr_real,
.tree-col img.x-tree-node-icon.fldr_link {
    -webkit-mask-image: none !important;
            mask-image: none !important;
    background-image: var(--tree-icon-folder) !important;
    background-size: 16px 16px !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    background-color: transparent !important;
    opacity: 1 !important;
}

.tree-col .x-tree-node-expanded img.fldr_real,
.tree-col .x-tree-node-expanded img.fldr_link,
.tree-col .x-tree-node-expanded img.fldr_marker,
.tree-col .x-tree-node-expanded img.fldr_download,
.tree-col .x-tree-node-expanded img.fldr_workspace {
    background-image: var(--tree-icon-folder-open) !important;
}

/* My Selections uses `.fldr_user` (gear-folder) and `.fldr_cat` for
   user-owned / category nodes — switch to cyan variants. */
.tree-col img.x-tree-node-icon.fldr_user,
.tree-col .x-tree-node img.fldr_user,
.tree-col img.x-tree-node-icon.fldr_cat,
.tree-col .x-tree-node img.fldr_cat {
    -webkit-mask-image: none !important;
            mask-image: none !important;
    background-image: var(--tree-icon-folder-cog) !important;
    background-size: 16px 16px !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    background-color: transparent !important;
    opacity: 1 !important;
}

/* Book-leaf icons in the tree — shelf-book glyph matching the bookshelf
   tile icons (mock @line 740 .tree .node .doc → shelf-book.svg).
   Same glyph everywhere: tree leaves and bookshelf tiles. */
.tree-col img.x-tree-node-icon.book_img,
.tree-col .x-tree-node img.book_img,
.tree-col img.x-tree-node-icon.consolidated_book_img,
.tree-col .x-tree-node img.consolidated_book_img,
.tree-col .x-tree-node-leaf img.x-tree-node-icon {
    -webkit-mask-image: none !important;
            mask-image: none !important;
    background-image: var(--tree-icon-book) !important;
    background-size: 16px 16px !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    background-color: transparent !important;
    opacity: 1 !important;
}

/* Vertical alignment for tree-col icons. The legacy rule at line 865
   (`.x-tree-node-el img.x-tree-node-icon { margin-top: -4px }`) was a
   sprite-era hack that misaligns the new SVG mask-image icons. Reset
   the negative margin and use inline vertical centering. */
.tree-col .x-tree-node-el img.x-tree-node-icon {
    margin-top: 0 !important;
    vertical-align: middle !important;
}
/* Undo the global `.x-box-item` justify for the Search page results, filters and table. */
.search-results-panel {
  text-align: left;
}
/* Search page result rows keep the grid's sorting and filters, but read as results. */
body.acs-new-theme .search-result-cards .x-grid3-hd-row,
body.acs-new-theme .search-result-cards .x-grid3-row-table {
  border-collapse: separate;
}

body.acs-new-theme .search-result-cards .x-grid3-row {
  border: 0;
  border-bottom: 1px solid var(--acs-border-light, #ecf0f6);
  background: var(--acs-card-bg, #fff);
}

/* The card open in the preview: the selection tint plus a cyan bar, since the hover
   tint is nearly the same blue (STYLING_PATTERNS 2.3). */
body.acs-new-theme .search-result-cards .x-grid3-row-selected {
  background: var(--acs-selection-bg, #eef6fb) !important;
  box-shadow: inset 3px 0 var(--acs-brand-cyan, #00aeef);
}

body.acs-new-theme .search-result-cards .x-grid3-cell-inner {
  white-space: normal !important;
  overflow: visible;
  padding: 0 !important;
}

body.acs-new-theme .search-result-card {
  padding: 15px 18px 17px;
  cursor: pointer;
  line-height: 1.45;
}

body.acs-new-theme .search-result-card-title {
  color: var(--acs-brand-cyan-muted, #0e8bb0);
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
}

body.acs-new-theme .search-result-card-excerpt {
  color: var(--acs-text-primary, #1c2127);
  font-size: 13px;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

body.acs-new-theme .search-result-card-details {
  color: var(--acs-text-secondary, #5a6370);
  font-size: 12px;
}

/* The location line: the book in the secondary text at weight 600, then its heading path. */
body.acs-new-theme .search-result-card-details .search-result-card-book {
  font-weight: 600;
}

/* The cell separator in an excerpt from a table, muted also inside a hit mark. */
body.acs-new-theme .search-result-card-excerpt .search-result-excerpt-sep,
body.acs-new-theme .search-results-grid .search-result-table-excerpt .search-result-excerpt-sep {
  color: var(--acs-text-tertiary, #8c95a0);
}

body.acs-new-theme .search-result-card-details .search-result-card-crumb-sep {
  color: var(--acs-text-tertiary, #8c95a0);
}

/* Table view: the Clause cell shows the title and the card's 2-line excerpt.
   One block, since the theme makes the first cell a flex row. */
body.acs-new-theme .search-results-grid .search-result-table-cell {
  flex: 1 1 auto;
  min-width: 0;
}

/* The card title's link colour and weight, at the table's 13px. */
body.acs-new-theme .search-results-grid .search-result-table-title {
  color: var(--acs-brand-cyan-muted, #0e8bb0);
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.acs-new-theme .search-results-grid .search-result-table-excerpt {
  margin-top: 2px;
  color: var(--acs-text-secondary);
  font-size: 12px;
  line-height: 1.4;
  white-space: normal;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

/* Table view: the first column starts 18px in, as the cards and the "Search Results" title above it, and every
   cell has 10px at the sides instead of the grid default's 6px. The header's right padding is left to the theme,
   which reserves room for the sort caret there. */
body.acs-new-theme .search-results-grid:not(.search-result-cards) .x-grid3-cell-inner {
  padding: 8px 10px !important;
}

body.acs-new-theme .search-results-grid:not(.search-result-cards) .x-grid3-hd-inner {
  padding-left: 10px !important;
}

body.acs-new-theme .search-results-grid:not(.search-result-cards) .x-grid3-cell-first .x-grid3-cell-inner,
body.acs-new-theme .search-results-grid:not(.search-result-cards) .x-grid3-cell-first .x-grid3-hd-inner {
  padding-left: 18px !important;
}

/* A filtered column's header shows the theme's filter icon. The paddings above outweigh the theme's room for it,
   so the icon takes the text's place and the text moves right of it. */
body.acs-new-theme .search-results-grid:not(.search-result-cards) td.ux-acs-filtered-column .x-grid3-hd-inner {
  padding-left: 28px !important;
}

body.acs-new-theme .search-results-grid:not(.search-result-cards) td.ux-acs-filtered-column .x-grid3-hd-inner::before {
  left: 10px !important;
}

body.acs-new-theme .search-results-grid:not(.search-result-cards) td.x-grid3-cell-first.ux-acs-filtered-column .x-grid3-hd-inner {
  padding-left: 36px !important;
}

body.acs-new-theme .search-results-grid:not(.search-result-cards) td.x-grid3-cell-first.ux-acs-filtered-column .x-grid3-hd-inner::before {
  left: 18px !important;
}

/* The Book Title wraps to two lines rather than cutting the name short; the Clause cell is three lines anyway.
   The clamp sits on the name's own block, not on the padded cell, or the third line shows through the padding. */
body.acs-new-theme .search-results-grid:not(.search-result-cards) .x-grid3-td-book_name .x-grid3-cell-inner {
  white-space: normal !important;
}

body.acs-new-theme .search-results-grid:not(.search-result-cards) .search-result-table-book {
  white-space: normal;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

/* The Book Viewer's search_hit colour, without changing the line's text metrics. */
body.acs-new-theme .search-result-card-excerpt .search-result-excerpt-hit,
body.acs-new-theme .search-results-grid .search-result-table-excerpt .search-result-excerpt-hit,
body.acs-new-theme .search-result-card-title .search-result-excerpt-hit,
body.acs-new-theme .search-results-grid .search-result-table-title .search-result-excerpt-hit {
  background-color: #FFF893;
  color: inherit;
  font: inherit;
  padding: 0;
}

/* The excerpt shows the clause's definition of the searched term: a muted chip before the excerpt. */
body.acs-new-theme .search-result-card-excerpt .search-result-definition-label,
body.acs-new-theme .search-results-grid .search-result-table-excerpt .search-result-definition-label {
  display: inline-block;
  margin-right: 6px;
  padding: 0 6px;
  border: 1px solid var(--acs-border, #e2e6ec);
  border-radius: var(--acs-radius-sm, 4px);
  background-color: var(--acs-surface, #f5f7f9);
  color: var(--acs-text-secondary, #5a6370);
  font-size: 11px;
  font-weight: 600;
  line-height: 16px;
  vertical-align: baseline;
}

/* Book results: the title as the clause titles; Folder and Project open the same
   book, so they read as plain text. */
body.acs-new-theme .search-results-panel .search-books-grid .x-grid3-col-book_name a.grid-anchor-cell {
  color: var(--acs-brand-cyan-muted, #0e8bb0);
  font-weight: 600;
}

body.acs-new-theme .search-results-panel .search-books-grid .x-grid3-col-folder_name a.grid-anchor-cell,
body.acs-new-theme .search-results-panel .search-books-grid .x-grid3-col-project_name a.grid-anchor-cell {
  color: var(--acs-text-primary, #1c2127);
}

/* Search page result bar: the bookshelf / track toolbar (STYLING_PATTERNS 3.1-3.3).
   Its bottom border is the one line above the results, filters and preview. */
.x-toolbar.search-page-toolbar.border-none {
  border-bottom: 1px solid var(--acs-border, #e2e6ec) !important;
  padding: 2px 12px 2px 10px !important;
}

/* The list's line above the pager takes the view's border colour, not azzurra's #aeb6be. */
.search-results-panel .search-results-grid > .x-panel-bwrap > .x-panel-body-noheader {
  border-top-width: 0 !important;
  border-bottom-color: var(--acs-border, #e2e6ec) !important;
}

/* Separators in the bookshelf / track colour (STYLING_PATTERNS 3.3), pager included. */
.search-page-toolbar .xtb-sep,
.search-results-panel .x-panel-bbar .xtb-sep {
  border-left-color: var(--acs-border, #e2e6ec) !important;
}

/* One line under the header row: the theme's cell border (STYLING_PATTERNS 2.1);
   the azzurra row border under it goes. */
.search-results-panel .search-results-grid .x-grid3-header {
  border-bottom-width: 0;
}

/* 35px, as the preview header next to it, so the two header lines meet. */
.search-results-panel .search-results-grid .x-grid3-hd-inner {
  padding-top: 9px !important;
  padding-bottom: 9px !important;
}

.search-page-toolbar .search-unsearchable-btn {
  margin-left: 8px;
}

/* Filters funnel: the Clear button's mask pattern (ext-acs-theme.css) with --icon-filter. */
.x-toolbar button.search_filters_btn {
  background-image: none !important;
}

.x-toolbar button.search_filters_btn::before,
.search-page-toolbar button.sort_btn::before {
  content: '' !important;
  display: inline-block !important;
  width: 16px !important;
  height: 16px !important;
  margin-right: 4px !important;
  vertical-align: -3px !important;
  -webkit-mask-size: 16px 16px !important;
          mask-size: 16px 16px !important;
  -webkit-mask-repeat: no-repeat !important;
          mask-repeat: no-repeat !important;
  -webkit-mask-position: center !important;
          mask-position: center !important;
  background-image: none !important;
  background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-toolbar button.search_filters_btn::before {
  -webkit-mask-image: var(--icon-filter) !important;
          mask-image: var(--icon-filter) !important;
}

/* Sort: the bookshelf's sort icon, which is scoped to .x-toolbar-bookshelf. */
.search-page-toolbar button.sort_btn {
  background-image: none !important;
}

.search-page-toolbar button.sort_btn::before {
  -webkit-mask-image: var(--icon-sort) !important;
          mask-image: var(--icon-sort) !important;
}

.x-toolbar .x-btn.x-btn-over button.search_filters_btn::before,
.x-toolbar .x-btn.x-btn-pressed button.search_filters_btn::before,
.search-page-toolbar .x-btn.x-btn-over button.sort_btn::before,
.search-page-toolbar .x-btn.x-btn-menu-active button.sort_btn::before {
  background-color: var(--acs-brand-cyan, #00aeef) !important;
}

/* The bar's own action (Save on Search, Edit Saved Search on Saved Search): the outlined
   secondary button (STYLING_PATTERNS 1.2); the ID beats the flat toolbar rule. */
:not(#acs_top_menu_div) > .x-toolbar.search-page-toolbar table.x-btn.search-page-action-btn {
  border: 1px solid var(--acs-brand-cyan, #00aeef) !important;
  border-radius: 4px !important;
}

.search-page-toolbar table.x-btn.search-page-action-btn button::before {
  background-color: var(--acs-brand-cyan-muted, #0e8bb0) !important;
}

/* Sort menu: book and project icons, and a tick on the current choice
   (as the bookshelf sort menu, which keys its tick on the asc/desc icons only). */
.x-menu img.x-menu-item-icon.search_sort_book,
.x-menu img.x-menu-item-icon.search_sort_project {
  -webkit-mask-size: 16px 16px !important;
          mask-size: 16px 16px !important;
  -webkit-mask-repeat: no-repeat !important;
          mask-repeat: no-repeat !important;
  -webkit-mask-position: center !important;
          mask-position: center !important;
  background-image: none !important;
  background-color: var(--acs-text-secondary, #5a6370) !important;
}

.x-menu img.x-menu-item-icon.search_sort_book {
  -webkit-mask-image: var(--icon-book) !important;
          mask-image: var(--icon-book) !important;
}

.x-menu img.x-menu-item-icon.search_sort_project {
  -webkit-mask-image: var(--icon-folder) !important;
          mask-image: var(--icon-folder) !important;
}

/* The right padding is the tick's room. The selector must outweigh the theme's menu item padding,
   `.x-menu.x-menu-floating:not(.header-menu) a.x-menu-item`, or the tick lands on the label. */
.x-menu.x-menu-floating.search-sort-menu:not(.header-menu) a.x-menu-item {
  padding-right: 28px !important;
  position: relative !important;
}

.search-sort-menu a.x-menu-item.search-sort-current::after {
  content: '';
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 14px;
  height: 14px;
  -webkit-mask: var(--icon-check) center / 14px 14px no-repeat;
          mask: var(--icon-check) center / 14px 14px no-repeat;
  background-color: var(--acs-brand-cyan, #00aeef);
}

body.acs-new-theme .search-result-filter-panel {
  background: #fff;
}

body.acs-new-theme .search-result-filter-panel .x-panel-body {
  background: #fff;
}

/* Filters sections: flat, a §9.3 legend label with the §21 chevron, divided by a light line. */
body.acs-new-theme .search-result-filter-section > .x-panel-header {
  background: transparent none !important;
  border: 0 !important;
  border-top: 1px solid var(--acs-border-light, #ecf0f6) !important;
  padding: 10px 12px 8px !important;
  cursor: pointer;
}

body.acs-new-theme .search-result-filter-section:first-child > .x-panel-header {
  border-top: 0 !important;
}

body.acs-new-theme .search-result-filter-section > .x-panel-header .x-panel-header-text {
  position: relative;
  padding-left: 18px;
  color: var(--acs-text-secondary, #5a6370) !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  line-height: 16px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

body.acs-new-theme .search-result-filter-section > .x-panel-header .x-panel-header-text::before {
  content: '';
  position: absolute;
  left: 0;
  top: 1px;
  width: 14px;
  height: 14px;
  -webkit-mask: var(--icon-chevron-up) center / 14px 14px no-repeat;
          mask: var(--icon-chevron-up) center / 14px 14px no-repeat;
  background-color: var(--acs-text-secondary, #5a6370);
}

body.acs-new-theme .search-result-filter-section.x-panel-collapsed > .x-panel-header .x-panel-header-text::before {
  -webkit-mask-image: var(--icon-chevron-down);
          mask-image: var(--icon-chevron-down);
}

body.acs-new-theme .search-result-filter-section > .x-panel-header:hover .x-panel-header-text {
  color: var(--acs-text-primary, #1c2127) !important;
}

body.acs-new-theme .search-result-filter-section > .x-panel-header:hover .x-panel-header-text::before {
  background-color: var(--acs-text-primary, #1c2127);
}

/* Per-section Clear: the header Clear all glyph (--icon-filter-x) at section size;
   the extra classes beat the theme's transparent panel tools. */
body.acs-new-theme .search-result-filter-section > .x-panel-header .x-tool.x-tool-search-clear {
  width: 16px;
  height: 16px;
  margin: 0;
  background: none !important;
  -webkit-mask: var(--icon-filter-x) center / 14px 14px no-repeat;
          mask: var(--icon-filter-x) center / 14px 14px no-repeat;
  background-color: var(--acs-text-secondary, #5a6370) !important;
}

body.acs-new-theme .search-result-filter-section > .x-panel-header .x-tool.x-tool-search-clear-over {
  background-color: var(--acs-brand-cyan, #00aeef) !important;
}

body.acs-new-theme .search-result-filter-section > .x-panel-bwrap > .x-panel-body {
  padding: 0 12px 12px;
  border: 0 !important;
  background: transparent;
}

body.acs-new-theme .search-result-filter-section .x-form-check-wrap {
  margin-top: 8px;
}

body.acs-new-theme .search-result-filter-section .search-result-filter-search {
  margin-bottom: 6px;
}

/* In-field clear, as the Book Viewer find bar: an x at the field's right edge. */
body.acs-new-theme .search-result-filter-field {
  position: relative;
}

body.acs-new-theme .search-result-filter-field input.x-form-text {
  padding-right: 30px !important;
}

body.acs-new-theme .search-result-filter-field .x-btn.search-result-filter-clear-btn {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
}

body.acs-new-theme .search-result-filter-field .x-btn.search-result-filter-clear-btn,
body.acs-new-theme .search-result-filter-field .x-btn.search-result-filter-clear-btn.x-btn-over,
body.acs-new-theme .search-result-filter-field .x-btn.search-result-filter-clear-btn td {
  background: transparent !important;
  background-image: none !important;
  border: none !important;
}

body.acs-new-theme .search-result-filter-field .search-result-filter-clear-btn button {
  -webkit-mask: var(--icon-close, var(--icon-x)) center / 14px 14px no-repeat !important;
          mask: var(--icon-close, var(--icon-x)) center / 14px 14px no-repeat !important;
  background-image: none !important;
  background-color: var(--acs-text-secondary, #5a6370) !important;
  border: none !important;
}

body.acs-new-theme .search-result-filter-field .search-result-filter-clear-btn.x-btn-over button {
  background-color: var(--acs-brand-cyan, #00aeef) !important;
}

body.acs-new-theme .search-result-filter-more {
  display: block;
  padding: 6px 4px 0;
  font-size: 12px;
  color: var(--acs-brand-cyan-muted, #0e8bb0);
  text-decoration: none;
  cursor: pointer;
}

body.acs-new-theme .search-result-filter-more:hover {
  text-decoration: underline;
}

body.acs-new-theme .search-result-filter-more.search-result-filter-note {
  color: var(--acs-text-secondary, #5a6370);
  text-decoration: none;
  cursor: default;
}

body.acs-new-theme .search-result-filter-option {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 6px 4px;
  cursor: pointer;
  color: var(--acs-text-primary, #1c2127);
  border-radius: 4px;
}

body.acs-new-theme .search-result-filter-option:hover {
  background: var(--acs-hover-bg-blue, #f0f7ff);
}

/* A ring, not an outline: azzurra's `.ext-webkit :focus` removes outlines app-wide. */
body.acs-new-theme .search-result-filter-option:focus-visible {
  box-shadow: inset 0 0 0 2px var(--acs-brand-cyan, #00aeef);
}

body.acs-new-theme .search-result-filter-option-disabled {
  opacity: 0.5;
  cursor: default;
}

body.acs-new-theme .search-result-filter-option input {
  margin: 2px 0 0;
  pointer-events: none;
}

/* The row takes the click, so it also lights the themed box (.x-form-checkbox). */
body.acs-new-theme .search-result-filter-option:not(.search-result-filter-option-disabled):hover .x-form-checkbox {
  border-color: var(--acs-brand-cyan) !important;
}

/* Filters trees (Folder, Location): the Browse Library look (.tree-col: chevrons, no
   connector lines, cyan outline folder and book icons), the themed tree checkbox
   (.x-menu .x-tree-node-cb) and titles that wrap like the Book list. Section rows show no
   icon, as the Book Viewer contents tree. */
body.acs-new-theme .search-result-filter-panel .x-tree .x-panel-body {
  border: 0 !important;
  background: transparent !important;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-el {
  display: flex !important;
  align-items: flex-start;
  padding: 2px 4px 2px 0;
  line-height: 20px;
  font-size: 13px;
  border-radius: 4px;
  cursor: pointer;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-el:hover,
body.acs-new-theme .search-result-filter-panel .x-tree-node-over,
body.acs-new-theme .search-result-filter-panel .x-tree-selected {
  background: var(--acs-hover-bg-blue, #f0f7ff) !important;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-indent {
  display: inline-flex;
  flex: none;
}

/* Chevron (20px), checkbox and icon (16px) centred on the first line of the name. */
body.acs-new-theme .search-result-filter-panel .x-tree-node-el img {
  flex: none;
  margin-top: 0 !important;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-el img.x-tree-node-icon {
  margin-top: 2px !important;
}

/* Chevron, checkbox, icon, name: the checkbox leads, as in the Book and Project lists. */
body.acs-new-theme .search-result-filter-panel input.x-tree-node-cb {
  order: 1;
}

body.acs-new-theme .search-result-filter-panel img.x-tree-node-icon {
  order: 2;
}

body.acs-new-theme .search-result-filter-panel a.x-tree-node-anchor {
  order: 3;
}

body.acs-new-theme .search-result-filter-panel .x-tree-elbow,
body.acs-new-theme .search-result-filter-panel .x-tree-elbow-end,
body.acs-new-theme .search-result-filter-panel .x-tree-elbow-line,
body.acs-new-theme .search-result-filter-panel .x-tree-ec-icon {
  background-image: none !important;
  background-color: transparent !important;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-collapsed .x-tree-ec-icon,
body.acs-new-theme .search-result-filter-panel .x-tree-node-expanded .x-tree-ec-icon {
  -webkit-mask: var(--icon-chevron-right) center / 10px 10px no-repeat !important;
          mask: var(--icon-chevron-right) center / 10px 10px no-repeat !important;
  background-color: var(--acs-text-secondary, #5a6370) !important;
  opacity: 0.55;
  transition: opacity 0.12s;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-expanded .x-tree-ec-icon {
  -webkit-mask-image: var(--icon-chevron-down) !important;
          mask-image: var(--icon-chevron-down) !important;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-el:hover .x-tree-ec-icon {
  opacity: 1;
}

body.acs-new-theme .search-result-filter-panel img.x-tree-node-icon {
  -webkit-mask: var(--icon-folder) center / 16px 16px no-repeat !important;
          mask: var(--icon-folder) center / 16px 16px no-repeat !important;
  background-image: none !important;
  background-color: var(--acs-brand-cyan, #00aeef) !important;
  opacity: 0.7;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-expanded img.x-tree-node-icon {
  -webkit-mask-image: var(--icon-folder-open) !important;
          mask-image: var(--icon-folder-open) !important;
}

body.acs-new-theme .search-result-filter-panel img.x-tree-node-icon.toc_root {
  -webkit-mask-image: var(--icon-shelf-book) !important;
          mask-image: var(--icon-shelf-book) !important;
}

body.acs-new-theme .search-result-filter-panel img.x-tree-node-icon.toc_section {
  display: none !important;
}

/* Attachment rows, here and in the column menu's Location tree: the file type's glyph, by the
   same mapping as the Edit Note dialog (ext-acs-notes-widgets.css). The src picture is moved
   out of the box, or it shows through the mask. */
body.acs-new-theme .search-result-filter-panel img.x-tree-node-inline-icon {
  object-position: -9999px 0;
}

body.acs-new-theme .search-result-filter-panel img.x-tree-node-inline-icon,
.x-menu .x-tree-node-leaf img.x-tree-node-inline-icon {
  -webkit-mask-image: var(--icon-file) !important;
          mask-image: var(--icon-file) !important;
}

body.acs-new-theme .search-result-filter-panel img.x-tree-node-inline-icon[src$="/pdf.gif"],
.x-menu .x-tree-node-leaf img.x-tree-node-inline-icon[src$="/pdf.gif"] {
  -webkit-mask-image: var(--icon-file-pdf) !important;
          mask-image: var(--icon-file-pdf) !important;
}

body.acs-new-theme .search-result-filter-panel img.x-tree-node-inline-icon:is([src$="/xls.png"], [src$="/xlsx.png"], [src$="/xlt.png"]),
.x-menu .x-tree-node-leaf img.x-tree-node-inline-icon:is([src$="/xls.png"], [src$="/xlsx.png"], [src$="/xlt.png"]) {
  -webkit-mask-image: var(--icon-file-spreadsheet) !important;
          mask-image: var(--icon-file-spreadsheet) !important;
}

body.acs-new-theme .search-result-filter-panel img.x-tree-node-inline-icon:is([src$="/doc.png"], [src$="/docx.png"], [src$="/dot.png"], [src$="/odt.png"], [src$="/ppt.png"], [src$="/htm.png"], [src$="/html.png"]),
.x-menu .x-tree-node-leaf img.x-tree-node-inline-icon:is([src$="/doc.png"], [src$="/docx.png"], [src$="/dot.png"], [src$="/odt.png"], [src$="/ppt.png"], [src$="/htm.png"], [src$="/html.png"]) {
  -webkit-mask-image: var(--icon-file-text) !important;
          mask-image: var(--icon-file-text) !important;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-el:hover img.x-tree-node-icon {
  opacity: 1;
}

/* Loading: the theme's tree ring (ext-acs-theme.css), drawn on the icon itself, which
   cannot carry the theme's ::after. */
body.acs-new-theme .search-result-filter-panel .x-tree-node-loading img.x-tree-node-icon {
  -webkit-mask: none !important;
          mask: none !important;
  background: transparent !important;
  box-sizing: border-box;
  width: 14px !important;
  height: 14px !important;
  margin: 3px 1px 0 !important;
  border: 2px solid var(--acs-border-input, #dce2ef);
  border-top-color: var(--acs-brand-cyan, #00aeef);
  border-radius: 50%;
  opacity: 1;
  animation: acs-spin 0.6s linear infinite;
}

/* Rows without a checkbox (Location projects and books) cannot be ticked: no hover tint;
   a click opens them. */
body.acs-new-theme .search-result-filter-panel .x-tree-node-el:not(:has(> input.x-tree-node-cb)):hover {
  background: transparent !important;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-el:has(a.x-tree-node-anchor:focus-visible) {
  box-shadow: inset 0 0 0 2px var(--acs-brand-cyan, #00aeef);
}

/* The themed checkbox (.x-form-checkbox). */
body.acs-new-theme .search-result-filter-panel input.x-tree-node-cb {
  appearance: none !important;
  -webkit-appearance: none !important;
  flex: none;
  position: relative;
  width: 16px !important;
  height: 16px !important;
  margin: 2px 6px 0 0 !important;
  background: var(--acs-hover-bg, #f6f8fb) !important;
  border: 1px solid var(--acs-border-input, #dce2ef) !important;
  border-radius: 4px !important;
  cursor: pointer;
}

body.acs-new-theme .search-result-filter-panel .x-tree-node-el:hover input.x-tree-node-cb {
  border-color: var(--acs-brand-cyan, #00aeef) !important;
}

body.acs-new-theme .search-result-filter-panel input.x-tree-node-cb:checked {
  background: var(--acs-brand-cyan, #00aeef) !important;
  border-color: var(--acs-brand-cyan, #00aeef) !important;
}

body.acs-new-theme .search-result-filter-panel input.x-tree-node-cb:checked::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 45%;
  width: 3px;
  height: 7px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: translate(-50%, -50%) rotate(45deg);
}

body.acs-new-theme .search-result-filter-panel a.x-tree-node-anchor {
  flex: 1 1 auto;
  min-width: 0;
  padding-left: 4px;
  white-space: normal;
  text-decoration: none;
}

body.acs-new-theme .search-result-filter-panel a.x-tree-node-anchor span {
  color: var(--acs-text-primary, #1c2127) !important;
  font-size: 13px;
  padding: 0 !important;
}

/* Zero results: the empty state sits near the top of the list (STYLING_PATTERNS 27). */
body.acs-new-theme .search-results-panel .search-results-grid .x-grid-empty {
  display: flex;
  justify-content: center;
  padding: clamp(48px, 20vh, 200px) 0 0;
  background: transparent;
}

/* One action per empty state: Clear filters, Search again, or Search tips on its own, as the primary button
   (STYLING_PATTERNS 1.1). Search tips under a Search again button is the quiet alternative: a flat text button (1.3). */
body.acs-new-theme .search-results-grid .x-grid-empty .search-empty-clear,
body.acs-new-theme .search-results-grid .x-grid-empty .search-empty-modifier,
body.acs-new-theme .search-results-grid .x-grid-empty .search-empty-tips {
  background: var(--acs-brand-cyan-muted, #0e8bb0);
  border: 1px solid var(--acs-brand-cyan-muted, #0e8bb0);
  border-radius: 4px;
  color: var(--acs-card-bg, #fff);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 24px;
  cursor: pointer;
}

body.acs-new-theme .search-results-grid .x-grid-empty .search-empty-clear:hover,
body.acs-new-theme .search-results-grid .x-grid-empty .search-empty-modifier:hover,
body.acs-new-theme .search-results-grid .x-grid-empty .search-empty-tips:hover {
  background: var(--acs-brand-cyan-deep, #0a6f8c);
  border-color: var(--acs-brand-cyan-deep, #0a6f8c);
}

body.acs-new-theme .search-results-grid .x-grid-empty .search-empty-modifier + .search-empty-tips {
  margin-top: 10px;
  background: transparent;
  border: none;
  color: var(--acs-text-secondary, #5a6370);
  font-weight: 500;
  padding: 6px 12px;
}

body.acs-new-theme .search-results-grid .x-grid-empty .search-empty-modifier + .search-empty-tips:hover {
  background: var(--acs-hover-bg, #f6f8fb);
  color: var(--acs-brand-cyan, #00aeef);
}

body.acs-new-theme .search-book-preview > .x-panel-bwrap > .x-panel-body {
  overflow: hidden;
}

body.acs-new-theme .search-book-preview iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}
