/* labs-chrome.css: the one header and footer every lab product page wears (tools/labs-chrome.py writes
   the markup from tools/labs/chrome.json). Look taken from the bracket demo header
   (labs/bracket/demo/shared/demo.css: .nav, .brand, .nav-switch, .cta-btn).
   Everything is namespaced .lc-* and sets its own font, colour and box model, so a page's own CSS
   (often plain `header`, `nav a`, `footer` rules) cannot reshape it. Light only, like the labs.
   Colours are the --manav-* tokens (assets/css/manav_tokens.css, linked by tools/labs-chrome.py on pages that lack it). */

.lc-bar, .lc-bar *, .lc-foot, .lc-foot * { box-sizing: border-box; }
/* a page's own rules for plain div/a/ul (position, float, size, transforms) must not move the bar's parts */
.lc-bar div, .lc-bar a, .lc-bar img, .lc-foot div, .lc-foot a, .lc-foot ul, .lc-foot li, .lc-foot img {
  position: static; float: none; transform: none; inset: auto; min-height: 0; max-height: none; opacity: 1; visibility: visible;
}
.lc-bar { position: sticky !important; top: 0 !important; left: auto; right: auto; bottom: auto; }
/* full width even when the page lays out <body> as a flex or grid box */
.lc-bar, .lc-foot { flex: 0 0 auto; align-self: stretch; grid-column: 1 / -1; max-width: none; }
/* on a page whose body is a centred flex column, keep the bar at the top and the footer at the bottom
   (in normal page flow these auto margins are zero) */
.lc-bar { margin-bottom: auto !important; }
.lc-foot { margin-top: auto !important; }

.lc-bar {
  position: sticky; top: 0; z-index: 2147482000;
  display: block; width: 100%; margin: 0; padding: 0;
  background: rgba(244, 243, 249, 0.92);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--manav-border-soft);
  font: 400 14px/1.4 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--manav-ink); text-align: left;
}
.lc-bar-in {
  max-width: 1080px; height: 54px; margin: 0 auto; padding: 0 20px;
  display: flex; align-items: center; gap: 14px;
}
.lc-bar a, .lc-foot a { text-decoration: none; border: 0; box-shadow: none; background-image: none; }

/* the manav mark: the landing page */
.lc-mark { display: inline-flex; align-items: center; flex: none; padding: 4px; margin: 0 -4px; border-radius: 8px; }
.lc-mark img { display: block; width: 26px; height: auto; margin: 0; }
.lc-mark:hover { background: var(--manav-violet-soft); }

/* [product]: the product's own home */
.lc-brand {
  font: 600 15.5px/1 'JetBrains Mono', 'SF Mono', ui-monospace, Menlo, monospace;
  letter-spacing: -0.02em; white-space: nowrap; color: var(--manav-ink) !important;
}
.lc-brand .lc-brk { color: var(--manav-violet); font-weight: 400; }

/* the product's demo switch */
.lc-switch {
  display: inline-flex; gap: 2px; padding: 3px; margin: 0 0 0 4px;
  border-radius: 9px; background: rgba(255, 255, 255, 0.78); border: 1px solid var(--manav-border-soft);
  min-width: 0; overflow-x: auto; scrollbar-width: none;
}
.lc-switch::-webkit-scrollbar { display: none; }
.lc-switch a {
  padding: 5px 13px; border-radius: 6px; white-space: nowrap;
  font: 600 13px/1.3 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--manav-ink-2) !important; transition: background .16s, color .16s;
}
.lc-switch a:hover { color: var(--manav-ink) !important; }
.lc-switch a.is-current { background: var(--manav-ink); color: var(--manav-surface) !important; }

.lc-right { margin-left: auto; display: flex; align-items: center; gap: 10px; flex: none; }
.lc-link { font: 600 13px/1 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; color: var(--manav-ink-2) !important; padding: 8px 4px; }
.lc-link:hover { color: var(--manav-ink) !important; }
.lc-user { font: 500 12px/1 'JetBrains Mono', 'SF Mono', ui-monospace, Menlo, monospace; color: var(--manav-ink-3); max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lc-out { display: inline; margin: 0; padding: 0; }
.lc-out button {
  margin: 0; padding: 8px 4px; border: 0; background: none; box-shadow: none; cursor: pointer;
  font: 600 13px/1 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; color: var(--manav-ink-2);
}
.lc-out button:hover { color: var(--manav-ink); }
.lc-cta {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 15px; border-radius: 8px;
  background: var(--manav-ink); color: var(--manav-surface) !important; white-space: nowrap;
  font: 600 13px/1 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  transition: background .16s, transform .12s;
}
.lc-cta:hover { background: var(--manav-violet); }
.lc-cta:active { transform: scale(0.98); }

/* footer: this product's pages, then the mark back to the landing page */
.lc-foot {
  display: block; width: 100%; margin: 0; padding: 28px 0 32px; clear: both;
  background: var(--manav-bg-warm); border-top: 1px solid var(--manav-border-soft);
  font: 400 13px/1.5 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--manav-ink-2); text-align: left;
}
.lc-foot-in { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.lc-foot-top { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 22px; }
.lc-foot .lc-brand { font-size: 14px; margin-right: 6px; }
.lc-pages { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0; padding: 0; list-style: none; }
.lc-pages li { margin: 0; padding: 0; list-style: none; }
.lc-pages li::before, .lc-pages li::marker { content: none; }
.lc-pages a { color: var(--manav-ink-2) !important; font-weight: 500; }
.lc-pages a:hover { color: var(--manav-violet) !important; }
.lc-pages a[aria-current="page"] { color: var(--manav-ink) !important; font-weight: 600; }
.lc-foot-end {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--manav-border-soft); color: var(--manav-ink-3);
}
.lc-foot-end .lc-mark { gap: 8px; margin: 0; padding: 0; color: var(--manav-ink) !important; font-weight: 600; }
.lc-foot-end .lc-mark img { width: 22px; }
.lc-foot-end .lc-mark:hover { background: none; color: var(--manav-violet) !important; }

@media (max-width: 720px) {
  .lc-bar-in { gap: 10px; padding: 0 14px; }
  .lc-switch { order: 3; flex: 1 1 100%; margin: 0; }
  .lc-bar-in { height: auto; min-height: 54px; flex-wrap: wrap; padding-top: 8px; padding-bottom: 8px; }
  .lc-link, .lc-user { display: none; }
}
/* an old header a page's script still reads: kept in the page, never shown (beats the page's own display rule) */
[data-lc-old] { display: none !important; }

@media print { .lc-bar, .lc-foot { display: none !important; } }
