/* zlib.css - shared presentation for the Documents library and the Shared Drive.
 *
 * COLLISEUM, ZEUS Client Experience v1.2, WAVE 2a (2026-10-22). This file supplies only the
 * components the shared app layer (zapp.css) did not already define: the tool-page breadcrumb,
 * the folder tree and breadcrumb path, the grid/card view for files, the contextual detail
 * panel, and a client-visible toast. Everything else reuses zapp.css classes (.zh-sec,
 * .zx-tbl, .zx-tab, .zx-btn, .zx-chip, .zx-mets, .zx-state) so the two pages inherit the same
 * navy / white / gold / teal light system as the rest of the instance.
 *
 * TOKENS ONLY. Loaded after brand-uip.css, so every color is a var() and resolves to the
 * LIGHT brand. Gold is fill / rule / border only on this ground, never text (brand rule).
 * Nothing here may make the document wider than the viewport at 390px: wide areas scroll
 * inside their own container, grids collapse, long strings wrap.
 */

/* ---------- tool-page breadcrumb ----------------------------------------- */
.zx-crumb{margin:22px 0 2px;font-size:12px;}
.zx-crumb ol{list-style:none;display:flex;flex-wrap:wrap;align-items:center;gap:6px;
 margin:0;padding:0;}
.zx-crumb li{display:inline-flex;align-items:center;gap:6px;color:var(--muted);}
.zx-crumb li+li::before{content:"\203A";color:var(--line2);font-weight:700;}
.zx-crumb a{color:var(--teal);text-decoration:none;}
.zx-crumb a:hover{text-decoration:underline;}
.zx-crumb [aria-current]{color:var(--head);font-weight:700;}

/* ---------- page title block --------------------------------------------- */
.zx-ph{display:flex;align-items:baseline;justify-content:space-between;gap:14px;
 flex-wrap:wrap;margin:0 0 4px;}
.zx-ph h1{margin:4px 0 0;}

/* ---------- action bar (Upload / New folder / view toggle) --------------- */
.zx-actbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;
 margin:4px 0 16px;padding-bottom:16px;border-bottom:1px solid var(--line);}
.zx-actbar .zx-spacer{flex:1 1 auto;}
.zx-actbar .zx-tabrow{margin:0;}

/* ---------- search + filters row ----------------------------------------- */
.zx-filters{display:flex;gap:10px;flex-wrap:wrap;align-items:center;margin:0 0 14px;}
.zx-filters .zx-search{flex:1 1 240px;min-width:0;position:relative;}
.zx-filters .zx-search input{width:100%;padding-left:34px;}
.zx-filters .zx-search svg{position:absolute;left:11px;top:50%;transform:translateY(-50%);
 width:15px;height:15px;fill:var(--muted);pointer-events:none;}
.zx-filters select{flex:0 0 auto;width:auto;min-width:148px;}
@media(max-width:560px){.zx-filters select{flex:1 1 100%;}}

/* ---------- working area: optional two-pane (tree + content) ------------- */
.zx-work{display:grid;grid-template-columns:232px 1fr;gap:18px;align-items:start;}
@media(max-width:860px){.zx-work{grid-template-columns:1fr;}}

/* folder tree rail */
.zx-tree{background:var(--panel2);border:1px solid var(--line);border-radius:11px;
 padding:10px;display:flex;flex-direction:column;gap:3px;}
.zx-tree .zx-tree-h{font-size:10.5px;letter-spacing:.1em;text-transform:uppercase;
 color:var(--muted);font-weight:700;padding:5px 9px 7px;}
.zx-tree button{display:flex;align-items:center;gap:9px;width:100%;text-align:left;
 background:transparent;border:0;border-radius:7px;padding:9px 10px;font-family:inherit;
 font-size:13px;color:var(--head);cursor:pointer;line-height:1.25;}
.zx-tree button:hover{background:var(--ground);}
.zx-tree button.on{background:var(--ground);border:1px solid var(--line2);font-weight:700;}
.zx-tree button .zx-fcount{margin-left:auto;font-size:11px;color:var(--muted);font-weight:400;}
.zx-tree button svg{width:16px;height:16px;fill:var(--teal);flex:none;}

/* ---------- file grid / card view ---------------------------------------- */
.zx-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:13px;}
.zx-card{background:var(--ground);border:1px solid var(--line);border-radius:11px;
 padding:14px;display:flex;flex-direction:column;gap:9px;min-width:0;cursor:pointer;
 text-align:left;font-family:inherit;}
.zx-card:hover{border-color:var(--gold);}
.zx-card:focus-visible{outline:2px solid var(--teal);outline-offset:2px;}
.zx-card .zx-ic{width:40px;height:40px;border-radius:9px;display:flex;align-items:center;
 justify-content:center;font-size:11px;font-weight:700;letter-spacing:.02em;color:#fff;flex:none;}
.zx-card .zx-nm{font-size:13.5px;font-weight:700;color:var(--head);line-height:1.3;
 overflow-wrap:anywhere;}
.zx-card .zx-mt{font-size:11.5px;color:var(--muted);overflow-wrap:anywhere;}
.zx-card .zx-cardfoot{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin-top:auto;}

/* type color chips for the file icon (fills, so literal ink on them is fine) */
.zx-ic.pdf{background:#a12b2b;}
.zx-ic.word{background:#1B2A4A;}
.zx-ic.sheet{background:#1f7a3f;}
.zx-ic.slides{background:#b9701f;}
.zx-ic.page{background:#20696d;}
.zx-ic.file{background:#667085;}

/* type cell in the table */
.zx-ty{display:inline-flex;align-items:center;gap:8px;}
.zx-ty .zx-dot{width:9px;height:9px;border-radius:2px;flex:none;}

/* name cell with owner avatar helper */
.zx-nmrow{display:flex;align-items:center;gap:10px;min-width:0;}
.zx-nmrow .zx-nmtxt{min-width:0;}
.zx-nmrow .zx-nmtxt b{display:block;color:var(--head);overflow-wrap:anywhere;}

/* ---------- contextual detail / preview panel ---------------------------- */
.zx-detail{background:var(--panel2);border:1px solid var(--line);border-left:3px solid var(--teal);
 border-radius:11px;padding:16px 17px;margin:16px 0 0;}
.zx-detail h3{font-size:15px;margin:0 0 3px;color:var(--head);overflow-wrap:anywhere;}
.zx-detail .zx-dmeta{font-size:12px;color:var(--muted);margin:0 0 12px;}
.zx-detail .zx-preview{background:var(--ground);border:1px dashed var(--line2);border-radius:9px;
 padding:22px 16px;text-align:center;color:var(--muted);font-size:12.5px;margin:0 0 13px;}
.zx-detail .zx-preview b{display:block;color:var(--head);font-size:13px;margin-bottom:4px;}

/* ---------- client-visible toast / action feedback ----------------------- */
.zx-toast{margin:14px 0 0;border-radius:10px;padding:12px 15px;font-size:13px;
 background:#E7F2F2;border:1px solid var(--teal);border-left:3px solid var(--teal);
 color:#163f41;}
.zx-toast b{color:var(--head);}
.zx-toast.warn{background:#FBF3DC;border-color:var(--gold);border-left-color:var(--gold);
 color:#5f4a0c;}
.zx-toast.warn b{color:#5f4a0c;}
.zx-toast[hidden]{display:none;}

/* ---------- view switching (JS toggles .is-hidden) ----------------------- */
.is-hidden{display:none !important;}

/* ---------- small helpers ------------------------------------------------- */
.zx-countline{font-size:12px;color:var(--muted);margin:0 0 10px;}
.zx-ownerline{font-size:11.5px;color:var(--muted);}
.zx-assure{font-size:12px;color:var(--muted);line-height:1.55;margin:10px 0 0;
 display:flex;gap:9px;align-items:flex-start;}
.zx-assure svg{width:16px;height:16px;fill:var(--teal);flex:none;margin-top:2px;}
