/* Business & Industry (careers-business.html), warm theme: Chapter III of the botanical career
   handbook. Chapter headings, the framed directory, and warm paper follow the editorial system.
   A seed-pod vine from assets/img/business/ sits beside the directory.
   assets/js/business-hub.js adds html.bx-hub and rearranges the built page; every
   rule here is scoped to it (or to this page's body), so other pages and the classic theme are
   untouched. The [data-palette] in each selector lets these rules outrank the palette's own. */

html[data-theme="warm"][data-palette].bx-hub {
  --bx-brass: var(--color-ornament, #A68B5A);
  --bx-rule: var(--line-soft, #C8BBA3);
  --bx-green: var(--color-primary, #20382F);
  --bx-ink: var(--color-text, #252D28);
  --bx-muted: var(--color-text-muted, #655F54);
  --bx-vine: clamp(130px, 12.5vw, 180px);       /* business-seedpod-vine.png, 294 × 757 */
  --bx-margin: max(var(--gutter, 3rem), (100vw - 76rem) / 2);   /* window edge → content edge */
  /* the directory stops this short of the content edge: the vine (visible 2.4%–97.6% across the
     PNG) sits 12px outside the frame, its leaves ending at least 14px inside the window */
  --bx-vine-room: max(1.5rem, .976 * var(--bx-vine) + 22px - var(--bx-margin));
}

/* ---------- Paper: the kit's grain and a soft vignette (as on Finance and Consulting) ---------- */
html[data-theme="warm"] body[data-page="careers-business"] {
  background: var(--surface-page) url("../img/consulting/kit/warm_paper_tile_1024.png") repeat;
}
html[data-theme="warm"] body[data-page="careers-business"]::before,
html[data-theme="warm"] body[data-page="careers-business"]::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
}
html[data-theme="warm"] body[data-page="careers-business"]::before {
  background: url("../img/consulting/kit/warm_paper_tile_1024.png") repeat;
  filter: grayscale(1) brightness(.54) contrast(6); mix-blend-mode: overlay; opacity: .4;
}
html[data-theme="warm"] body[data-page="careers-business"]::after {
  background: radial-gradient(ellipse at 50% 46%, rgba(252, 244, 228, .55) 0%, rgba(252, 244, 228, 0) 40%, rgba(225, 160, 50, 0) 44%, rgba(225, 160, 50, .16) 100%);
}
html[data-theme="warm"] body[data-page="careers-business"] main > .hero { background: transparent; }

html[data-theme="warm"].bx-hub .bx-plant { position: absolute; z-index: 0; display: block; max-width: none; pointer-events: none; }

/* ---------- 2. Section headings: italic, a brass line to the column's right edge ---------- */
html[data-theme="warm"][data-palette].bx-hub main section h2:not(.visually-hidden) {
  display: flex; align-items: center; gap: var(--space-5);
  margin: 0 0 6px; max-width: none;
  font: italic 500 2.1rem/1.15 var(--font-head); letter-spacing: 0; color: var(--bx-ink);
  text-align: left; text-wrap: balance;
}
html[data-theme="warm"][data-palette].bx-hub main section h2:not(.visually-hidden)::after {
  content: ""; flex: 1 1 2rem; min-width: 2rem; border-top: 1px solid var(--bx-brass);
}
html[data-theme="warm"][data-palette].bx-hub .playbill-heading { max-width: none; margin: 0; text-align: left; }
html[data-theme="warm"][data-palette].bx-hub .playbill-heading__rule,
html[data-theme="warm"][data-palette].bx-hub .playbill-heading .ornament-divider-wrap { display: none; }
html[data-theme="warm"][data-palette].bx-hub .playbill-heading__title { margin-block: 0; }

/* ---------- 3. The main areas: straight under the opener ---------- */
html[data-theme="warm"][data-palette].bx-hub #lanes { padding-top: 36px; padding-bottom: var(--space-10); background: transparent; overflow-x: clip; }
html[data-theme="warm"][data-palette].bx-hub .bx-lanes { position: relative; }
/* "Which one is which?": a plain paragraph */
html[data-theme="warm"][data-palette].bx-hub .bx-lede {
  max-width: 46rem; margin: 1rem 0 0;
  font-size: 1rem; line-height: 1.55; color: var(--bx-ink);
}
html[data-theme="warm"][data-palette].bx-hub .bx-lede strong { color: var(--bx-green); }

/* Seed-pod vine: hangs in the right margin from beside the heading down the outside of the
   directory's right edge, never over the frame. The heading's centre line (19.5px down) crosses
   the vine 9.4% down its drawn height (2.575 × its width), at every size. Decorative: no pointer events. */
html[data-theme="warm"][data-palette].bx-hub .bx-plant--vine {
  z-index: 1; width: var(--bx-vine); height: auto; opacity: .92;
  left: calc(100% - var(--gutter, 3rem) - var(--bx-vine-room) + 8px);
  top: calc(19.5px - .242 * var(--bx-vine));
}

/* ---------- 5. Compare the pathways: the Finance and Consulting table treatment ----------
   A static, semantic table (careers-*.html); each cell is a short phrase from that guide's "At a
   glance". Below 40rem the shared warm rules stack each row as a labelled block. */
html[data-theme="warm"][data-palette].bx-hub {
  --bx-t-head: #E0D6BF; --bx-t-body: #EEE5D3; --bx-t-border: #CDC4B0; --bx-t-rule: #DCD3C0; --bx-t-note: #6B6254;
}
html[data-theme="warm"][data-palette].bx-hub main > .path-compare { padding-top: var(--space-4); padding-bottom: var(--space-8); background: transparent; }
html[data-theme="warm"][data-palette].bx-hub .compare-note { max-width: 46rem; margin: 0 0 14px; font-size: .84rem; line-height: 1.45; color: var(--bx-t-note); }
html[data-theme="warm"][data-palette].bx-hub .path-compare .warm-compare { margin-top: 0; }
html[data-theme="warm"][data-palette].bx-hub .path-compare th[scope="row"] { font: 600 1.15rem/1.2 var(--font-head); }
html[data-theme="warm"][data-palette].bx-hub .path-compare th[scope="row"] a { color: var(--bx-green); text-decoration-line: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
@media (min-width: 40rem) {
  html[data-theme="warm"][data-palette].bx-hub .path-compare .warm-compare__scroll {
    overflow-x: auto; background: var(--bx-t-body); border: 1px solid var(--bx-t-border); border-radius: 6px; box-shadow: none;
  }
  html[data-theme="warm"][data-palette].bx-hub .path-compare table { table-layout: fixed; width: 100%; min-width: 56rem; font-size: 14px; color: #271F12; }
  html[data-theme="warm"][data-palette].bx-hub .path-compare thead th:nth-child(1) { width: 15%; }
  html[data-theme="warm"][data-palette].bx-hub .path-compare th,
  html[data-theme="warm"][data-palette].bx-hub .path-compare td {
    padding: 15px 16px; vertical-align: top; line-height: 1.35;
    border-bottom: 1px solid var(--bx-t-rule); border-right: 1px solid var(--bx-t-rule);
  }
  html[data-theme="warm"][data-palette].bx-hub .path-compare tr > :last-child { border-right: 0; }
  html[data-theme="warm"][data-palette].bx-hub .path-compare tbody tr:last-child > * { border-bottom: 0; }
  html[data-theme="warm"][data-palette].bx-hub .path-compare thead th {
    padding: 14px 16px; vertical-align: middle; background: var(--bx-t-head); color: #1F1910;
    font: 700 12.75px/1.35 var(--font-body); letter-spacing: .12em; text-transform: uppercase; font-variant: normal;
  }
  html[data-theme="warm"][data-palette].bx-hub .path-compare tbody th[scope="row"],
  html[data-theme="warm"][data-palette].bx-hub .path-compare tbody td { background: var(--bx-t-body); }
}

/* ---------- 6. Recruiting tips: headed paragraphs in an open grid (Consulting's "Recruiting from
   Grinnell, Iowa" treatment), no cards; rendered by site.js from SITE_DATA.chapterGuidance ---------- */
html[data-theme="warm"][data-palette].bx-hub main > :is(.path-tips, .path-orgs) { padding-top: var(--space-8); padding-bottom: var(--space-8); background: transparent; border-top: 1px solid var(--bx-rule); }
html[data-theme="warm"][data-palette].bx-hub main > :is(.path-tips, .path-orgs) .eyebrow { margin: 0 0 4px; }
html[data-theme="warm"][data-palette].bx-hub main > :is(.path-tips, .path-orgs) .section-intro {
  max-width: 46rem; margin: 0 0 var(--space-5); text-align: left; font-size: .95rem; line-height: 1.5; color: var(--bx-muted);
}
html[data-theme="warm"][data-palette].bx-hub .ptip-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 40px;
  border-top: 1px solid var(--bx-brass);
}
html[data-theme="warm"][data-palette].bx-hub .ptip { padding: 18px 0 20px; border-bottom: 1px solid var(--bx-rule); }
html[data-theme="warm"][data-palette].bx-hub .ptip > h3 { margin: 0 0 6px; font: 600 1.25rem/1.25 var(--font-head); color: var(--bx-green); text-wrap: balance; }
html[data-theme="warm"][data-palette].bx-hub .ptip > p { margin: 0; font-size: .92rem; line-height: 1.55; color: var(--bx-ink); }
html[data-theme="warm"][data-palette].bx-hub .ptip > .ptip__action { margin-top: 8px; color: var(--bx-ink); }
html[data-theme="warm"][data-palette].bx-hub .ptip__action > strong { color: var(--bx-green); }

/* ---------- 7. Organizations to research: filter chips, a count, and open rows (Consulting's
   "Target firms to research" family) ---------- */
html[data-theme="warm"][data-palette].bx-hub .org-filter { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 10px; }
html[data-theme="warm"][data-palette].bx-hub .org-filter .chip { min-height: 2.5rem; }
html[data-theme="warm"][data-palette].bx-hub .org-filter .chip:focus-visible { outline: 2px solid var(--bx-green); outline-offset: 2px; }
html[data-theme="warm"][data-palette].bx-hub .chip__n { font-weight: 400; opacity: .8; }
html[data-theme="warm"][data-palette].bx-hub .org-count { margin: 0 0 12px; font-size: .84rem; color: var(--bx-muted); }
html[data-theme="warm"][data-palette].bx-hub .org-list {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 48px;
  margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--bx-brass);
}
html[data-theme="warm"][data-palette].bx-hub .org { padding: 16px 0 18px; border-bottom: 1px solid var(--bx-rule); }
html[data-theme="warm"][data-palette].bx-hub .org[hidden] { display: none; }
html[data-theme="warm"][data-palette].bx-hub .org__name { margin: 0 0 4px; font: 600 1.25rem/1.25 var(--font-head); color: var(--bx-green); }
html[data-theme="warm"][data-palette].bx-hub .org__desc { margin: 0 0 8px; font-size: .92rem; line-height: 1.5; color: var(--bx-ink); }
html[data-theme="warm"][data-palette].bx-hub .org__links { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 0 0 8px; font-size: .9rem; font-weight: 600; }
html[data-theme="warm"][data-palette].bx-hub .org__meta { margin: 0; font-size: .84rem; line-height: 1.45; }
html[data-theme="warm"][data-palette].bx-hub .org__meta > div { display: grid; grid-template-columns: 8.5rem minmax(0, 1fr); column-gap: 12px; padding: 3px 0; }
html[data-theme="warm"][data-palette].bx-hub .org__meta dt { font: 700 .68rem/1.6 var(--font-body); letter-spacing: .1em; text-transform: uppercase; color: var(--bx-muted); }
html[data-theme="warm"][data-palette].bx-hub .org__meta dd { margin: 0; color: var(--bx-ink); }
@media (max-width: 74.999rem) {
  html[data-theme="warm"][data-palette].bx-hub .ptip-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 47.999rem) {
  html[data-theme="warm"][data-palette].bx-hub .ptip-grid,
  html[data-theme="warm"][data-palette].bx-hub .org-list { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 29.999rem) {
  html[data-theme="warm"][data-palette].bx-hub .org__meta > div { grid-template-columns: minmax(0, 1fr); row-gap: 0; padding: 4px 0; }
}

html[data-theme="warm"][data-palette].bx-hub #lanes .see-all { margin-top: 20px; }

/* ---------- 6. Sources ---------- */
html[data-theme="warm"][data-palette].bx-hub main > .sources { padding-top: var(--space-10); background: transparent; }

/* Verify markers anywhere on the page: each kept as one box; a long one wraps inside its box
   rather than running past a narrow column */
html[data-theme="warm"][data-palette].bx-hub main .badge-verify { display: inline-block; max-width: 100%; white-space: normal; }

/* ---------- 7. Responsive ---------- */
@media (min-width: 64rem) {
  html[data-theme="warm"][data-palette].bx-hub .bx-lanes .career-directory { margin-inline-end: var(--bx-vine-room); }   /* the vine hangs in the room on the right */
  html[data-theme="warm"][data-palette].bx-hub .bx-lede { max-width: min(46rem, 100% - var(--bx-vine-room) - 1.5rem); }
}
@media (max-width: 63.999rem) {
  html[data-theme="warm"][data-palette].bx-hub .bx-plant--vine { display: none; }
}
@media (max-width: 39.999rem) {
  /* headings wrap on a phone: the brass line runs under them instead of beside them */
  html[data-theme="warm"][data-palette].bx-hub main section h2:not(.visually-hidden) { display: block; font-size: 1.85rem; }
  html[data-theme="warm"][data-palette].bx-hub main section h2:not(.visually-hidden)::after { display: block; margin-top: var(--space-3); }
}
