/* NOTE: this file still has !important rules on purpose. Removing them changes how pages look (checked page by page with admin/tests/tools/css_check.php) because they override older rules; merge the overlapping rules before removing them. */
/* THE left menu (Live\Chrome::sidebar): the menu links, the profile / category lists, the site's links and the language list. One component for every page.
   Colours: the admin theme (--msg-*). Wide screens only (a phone has the same content in the menu drawer). */
.ch-sidebar { position: fixed; z-index: 99; top: var(--ch-h, 54px); bottom: 0; left: 0; width: clamp(200px, 13vw, 250px); overflow-y: auto; scrollbar-width: thin; scrollbar-color: #0000 #0000; background: var(--msg-surface); color: var(--msg-text); padding-bottom: 82px; box-sizing: border-box; display: none; font-size: 14px; line-height: 20px; font-weight: 400; letter-spacing: normal; text-align: left; } /* (its own text size: the page's own (the legal pages use 16px / 1.65) must never change the menu, owner 2026-11-11) */
.ch-sidebar:hover { scrollbar-color: var(--msg-border) transparent; }
.ch-sidebar ul { list-style: none; margin: 0; padding: 0; }
.ch-sidebar a { text-decoration: none; }
body.acct-bn-on .ch-sidebar { top: calc(var(--ch-h, 54px) + var(--acct-bn)); }
@media (min-width: 1200px) {
  .ch-sidebar { display: block; }
  /* the page next to it: every page except the home page (which has its own layout) starts to the right of the menu */
  body:has(.ch-sidebar:not(.is-overlay)):not(:has(#browseTabs)) { margin-left: clamp(200px, 13vw, 250px); }
  body.sidebar-rail:has(.ch-sidebar:not(.is-overlay)):not(:has(#browseTabs)) { margin-left: 72px; }
  body.sidebar-norail.sidebar-rail:has(.ch-sidebar:not(.is-overlay)):not(:has(#browseTabs)) { margin-left: 0; }
  body.sidebar-norail.sidebar-rail .ch-sidebar:not(.is-overlay) { display: none; }
  }
.ch-sidebar .category_heading { cursor: default; }
.cat-flag { width: 20px; height: 20px; vertical-align: -4px; margin-right: 6px; }
.cat-icon { width: 1.2em; margin-right: 6px; text-align: center; }

/* the left list the way the big sites draw it: small muted headings (no coloured bars), light rows with the picture on the left and the count on the right */
:is(body:not(.sidebar-rail), .ch-sidebar.is-overlay) .sidebar-section-block { padding: 10px 10px 6px; border-top: 1px solid var(--msg-border); }
:is(body:not(.sidebar-rail), .ch-sidebar.is-overlay) .sidebar-section-block:first-child { border-top: 0; }
:is(body:not(.sidebar-rail), .ch-sidebar.is-overlay) .category_heading { background: transparent !important; border: 0 !important; color: var(--msg-muted) !important; font-size: 12px !important; font-weight: 600 !important; letter-spacing: .08em; text-transform: uppercase; height: auto !important; line-height: 1.2 !important; padding: 8px 10px !important; cursor: default; }
:is(body:not(.sidebar-rail), .ch-sidebar.is-overlay) .category_heading i { display: none; }
:is(body:not(.sidebar-rail), .ch-sidebar.is-overlay) .sidebar_filters a.collection-item { display: flex; align-items: center; min-height: 36px; padding: 4px 10px !important; margin: 1px 0; border: 0 !important; border-radius: 8px; background: transparent !important; color: var(--msg-text) !important; font-size: 15px; font-weight: 500; line-height: 20px !important; }
:is(body:not(.sidebar-rail), .ch-sidebar.is-overlay) .sidebar_filters a.collection-item .count { margin-left: auto; padding-left: 8px; float: none !important; color: var(--msg-text); font-size: 14px; opacity: .85; }
:is(body:not(.sidebar-rail), .ch-sidebar.is-overlay) .sidebar_filters a.collection-item.second-nv-active { background: var(--msg-hover) !important; font-weight: 700; }
@media (hover: hover) { :is(body:not(.sidebar-rail), .ch-sidebar.is-overlay) .sidebar_filters a.collection-item:hover { background: var(--msg-hover) !important; } }
.sidebar_filters a.collection-item .cat-flag, .sidebar_filters a.collection-item .cat-icon { flex: none; width: 22px; height: 22px; margin-right: 12px; font-size: 18px; line-height: 22px; text-align: center; }

/* the menu block at the top of the left list (Home, My Favorites, Recommended ...): bigger rows, a picture in front, no count */
.side-links { display: flex; flex-direction: column; gap: 2px; padding: 10px 10px 6px; }
.side-link { display: flex; align-items: center; gap: 14px; min-height: 40px; padding: 4px 12px; border-radius: 8px; color: var(--msg-text) !important; font-size: 15px; font-weight: 600; text-decoration: none; }
.side-link .cat-icon { flex: none; width: 22px; margin: 0; font-size: 17px; text-align: center; }
.side-link .cat-flag, .side-link .side-gap { flex: none; width: 22px; height: 22px; margin: 0; }
.side-link.on { background: var(--msg-hover); }
.side-link.on .cat-icon { color: var(--msg-accent); }
@media (hover: hover) { .side-link:hover { background: var(--msg-hover); } }


/* the menu folded into a thin rail (wide screens, the menu button): icons only, for the first two blocks (the menu links and the first list); every icon is a normal link; it
   unfolds only with the menu button; the rail runs the full height of the page */
@media (min-width: 1200px) {
  body.sidebar-rail .ch-sidebar:not(.is-overlay) { width: 64px; overflow-x: hidden; overflow-y: auto; }
  body.sidebar-rail .ch-sidebar:not(.is-overlay) .sidebar-section-block, body.sidebar-rail .ch-sidebar:not(.is-overlay) .side-foot { display: none; }
  body.sidebar-rail .ch-sidebar:not(.is-overlay) .category_heading, body.sidebar-rail .ch-sidebar:not(.is-overlay) .row-t, body.sidebar-rail .ch-sidebar:not(.is-overlay) .count, body.sidebar-rail .ch-sidebar:not(.is-overlay) .side-link > span:last-child { display: none !important; }
  body.sidebar-rail .ch-sidebar:not(.is-overlay) .side-links { padding: 8px 8px 8px; }
  body.sidebar-rail .ch-sidebar:not(.is-overlay) .side-link, body.sidebar-rail .ch-sidebar:not(.is-overlay) .sidebar_filters a.collection-item { justify-content: center; padding: 0 !important; min-height: 44px; gap: 0; }
  body.sidebar-rail .ch-sidebar:not(.is-overlay) .side-link .cat-icon, body.sidebar-rail .ch-sidebar:not(.is-overlay) .sidebar_filters a.collection-item .cat-icon { margin: 0; }
  body.sidebar-rail .ch-sidebar:not(.is-overlay) .sidebar_filters a.collection-item .cat-flag { margin: 0; }
  body.sidebar-rail .ch-sidebar:not(.is-overlay) .sidebar_filters a.collection-item:not(.second-nv-active):not(:hover) { background: transparent !important; }
  body.sidebar-rail .ch-sidebar:not(.is-overlay) .sidebar_filters a.collection-item.no-icon { display: none; } /* a row without a picture has nothing to show in the rail */
}
/* the room: the menu is closed, no rail, and opens OVER the page with the menu button (a click anywhere else closes it) */
.ch-sidebar.is-overlay { display: none; }
@media (min-width: 1200px) {
  body.ch-side-open .ch-sidebar.is-overlay { display: block; z-index: 1250; width: 250px; box-shadow: 8px 0 40px color-mix(in srgb, var(--msg-black) 50%, transparent); }
}

/* a model's menu (her panel): the badge and the lock sit at the right end, the label is last in the markup so the folded rail can hide it */
.side-link > span:last-child { order: 2; flex: 1; min-width: 0; }
.side-link .msg-nav-badge, .side-link .pnl-lockmark { order: 3; margin-left: auto; }
.side-link .pnl-lockmark { display: inline-flex; opacity: .65; }
.side-link .pnl-lockmark .ch-ic { width: 16px; height: 16px; }
.side-link .cat-icon .pnl-ic { width: 20px; height: 20px; }

/* the heading of a block in the left list (was an inline style) */
.ch-sidebar .category_heading { position: relative; width: 100%; margin-top: 0; }
