/* StructBio shared chrome — suite bar, breadcrumb, footer.
 *
 * This is injected into three front-ends that know nothing about it: a Bootstrap 5
 * site (AlproDB), a hand-rolled themed page (Motif Scanner) and a React SPA
 * (ProDface). So every rule is namespaced `sb-`, every selector is anchored to a
 * `sb-` container, and every property the tools might set on generic elements —
 * font, colour, margin, list styling, box-sizing — is stated explicitly rather
 * than inherited.
 *
 * The bar and footer are a solid blue in all cases. They do not participate in any
 * tool's light/dark theme, and the bar does not use position:sticky, so the tools'
 * own sticky headers keep working unchanged.
 *
 * That blue is #2563eb, chosen so both marks on it stay legible: white text clears
 * 5.1:1 against it, and the black "Bio" in the wordmark clears 4:1. A lighter blue
 * would have carried the black and lost the white.
 *
 * The bar carries the wordmark and Group only. Moving between tools is the
 * breadcrumb's StructBio link and the home page — there is no switcher here.
 */

/* How much vertical space the chrome occupies at the top of the page: the suite
 * bar (65px, its 1px border included) plus the breadcrumb (33px). Published so a tool can account for it
 * where it must — an element positioned against the viewport rather than against
 * the document flow does not get pushed down by the bar on its own. Tools read it
 * with a 0px fallback, so they are unaffected when run standalone. */
:root { --sb-chrome-height: 98px; }

.sb-bar,
.sb-crumb,
.sb-foot {
  --sb-blue:      #2563eb;   /* the ground the bar and footer are painted on */
  --sb-line:      rgba(255, 255, 255, .24);
  --sb-ink:       #ffffff;
  --sb-ink-dim:   #e8f0ff;   /* was a cool grey; on blue that read as mud */
  --sb-accent:    #000000;   /* the "Bio" half of the wordmark, and nothing else */
  --sb-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

  box-sizing: border-box;
  font-family: var(--sb-sans);
  text-align: left;
}

.sb-bar *,
.sb-crumb *,
.sb-foot * { box-sizing: border-box; font-family: inherit; }

/* ── Suite bar ─────────────────────────────────────────────────────────────── */
.sb-bar {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  background: var(--sb-blue);
  border-bottom: 1px solid var(--sb-line);
  color: var(--sb-ink);
  position: relative;
  z-index: 2147483000;   /* above any tool's own overlays and sticky headers */
}

.sb-bar .sb-bar-inner {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.25rem;
  height: 64px;
}

.sb-bar .sb-brand {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  color: var(--sb-ink);
  text-decoration: none;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -.01em;
  line-height: 1;
  padding: 0;
  border: 0;
  background: none;
}
.sb-bar .sb-brand:hover { color: #fff; text-decoration: none; }
/* The lab's mark is a white disc with black lettering; rendered round it reads as
   a badge on the blue and needs no backing of its own. */
.sb-bar .sb-brand-mark {
  display: block;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
}
/* Black, and it stays black through the parent's hover — the span is targeted
   directly, so the colour set on .sb-brand:hover never reaches it. */
.sb-bar .sb-brand-accent { color: var(--sb-accent); }

.sb-bar .sb-meta { display: flex; align-items: center; gap: 1rem; margin-left: auto; }
.sb-bar .sb-meta a {
  color: var(--sb-ink-dim);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  line-height: 1;
}
.sb-bar .sb-meta a:hover { color: var(--sb-ink); text-decoration: none; }
/* The institute's mark is dark-blue ink drawn for a light ground, so it sits on a
   small white chip rather than directly on the bar's blue. */
.sb-bar .sb-iitj {
  display: block;
  flex: 0 0 auto;
  width: auto;
  height: 42px;
  padding: 3px 5px;
  border-radius: 8px;
  background: #fff;
}

/* ── Breadcrumb ────────────────────────────────────────────────────────────── */
.sb-crumb {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  background: #f2f5f8;
  border-bottom: 1px solid #dfe6ed;
  color: #55636f;
  position: relative;
  z-index: 2147482999;
}
.sb-crumb .sb-crumb-inner {
  display: flex;
  align-items: center;
  gap: .5rem;
  max-width: 1400px;
  margin: 0 auto;
  padding: .45rem 1.25rem;
  font-size: 12.5px;
  line-height: 1.4;
}
.sb-crumb a { color: #55636f; text-decoration: none; font-weight: 500; }
.sb-crumb a:hover { color: #2563eb; text-decoration: underline; }
.sb-crumb .sb-crumb-sep { color: #a9b6c2; }
.sb-crumb .sb-crumb-here { color: #16202c; font-weight: 600; }
.sb-crumb .sb-crumb-tag {
  color: #8595a3;
  padding-left: .6rem;
  margin-left: .2rem;
  border-left: 1px solid #dfe6ed;
}

/* ── Footer ────────────────────────────────────────────────────────────────── */
.sb-foot {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  background: var(--sb-blue);
  border-top: 1px solid var(--sb-line);
  color: var(--sb-ink-dim);
}
.sb-foot .sb-foot-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1.1rem 1.25rem;
  text-align: center;
}
.sb-foot p { margin: 0; font-size: 12.5px; line-height: 1.5; color: var(--sb-ink-dim); }

/* The full contact block, on StructBio's own pages. Same blue ground; the ink
   steps up to white where it matters (the heading, the address) and back to the
   dim tint for the copyright line. */
.sb-foot .sb-foot-full { padding: 2rem 1.25rem 1.4rem; }
.sb-foot .sb-foot-head {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--sb-ink);
  margin: 0 0 .7rem;
}
.sb-foot .sb-foot-addr {
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--sb-ink);
  margin: 0 0 .55rem;
}
.sb-foot .sb-foot-mail { margin: 0 0 1.1rem; font-size: 13.5px; }
.sb-foot .sb-foot-mail a { color: var(--sb-ink); text-decoration: underline; }
.sb-foot .sb-foot-mail a:hover { color: #fff; }
.sb-foot .sb-foot-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: .9rem;
  margin: 0 0 1.1rem;
}
/* Same treatment as the bar: the lab's mark is its own white disc; the
   institute's dark-blue ink sits on a white chip. */
.sb-foot .sb-foot-sbl {
  display: block;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #fff;
}
.sb-foot .sb-foot-iitj {
  display: block;
  width: auto;
  height: 48px;
  padding: 3px 5px;
  border-radius: 8px;
  background: #fff;
}
.sb-foot .sb-foot-copy {
  border-top: 1px solid var(--sb-line);
  padding-top: 1rem;
  font-size: 12.5px;
  color: var(--sb-ink-dim);
}

/* ── Narrow screens ────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
  .sb-bar .sb-bar-inner { gap: .7rem; padding: 0 .8rem; }
  .sb-bar .sb-brand { font-size: 17px; }
  .sb-bar .sb-meta { gap: .8rem; }
  .sb-crumb .sb-crumb-tag { display: none; }
}
