/* BIRJA · symmetric news/projects rails, 2026-11-05
   Right heading reuses the exact same reactive-text + living-heading rules as the left.
   Keep the heading outside the independent card scroll region. */
.projects-rail{display:flex;flex-direction:column;gap:0;overflow:visible!important}
.projects-rail-head.feed-section-top{
  display:flex;align-items:end;justify-content:space-between;
  flex:0 0 auto;position:relative;z-index:2;
  gap:5px;margin:0 0 11px;padding:0;
  min-height:0;overflow:visible;
}
.projects-rail-head .eyebrow{font-size:8px;letter-spacing:.07em;color:#5c6f68}
.projects-rail-head h2{
  font-size:23px;line-height:1.08;letter-spacing:-.75px;
  margin:6px 0 0;color:#173026;
}
.projects-panel{min-height:0}

@media (min-width: 1180px) {
  body[data-page="home"],
  body.universal-projects-rail-page {
    --projects-fixed-width: clamp(230px, 20vw, 308px);
    --projects-fixed-edge: max(20px, calc((100vw - 1820px) / 2));
  }

  body[data-page="home"] main.home-layout > .projects-rail,
  body.universal-projects-rail-page main.wrap > .projects-rail {
    position: fixed !important;
    inset: 121px var(--projects-fixed-edge) auto auto !important;
    width: var(--projects-fixed-width) !important;
    height: calc(100dvh - 138px) !important;
    max-height: 830px;
    min-height: 0;
    margin: 0 !important;
    align-self: auto !important;
    display:flex;
    flex-direction:column;
    gap:10px;
    overflow: visible !important;
    z-index: 21;
  }

  body[data-page="home"] main.home-layout > .projects-rail > .projects-panel,
  body.universal-projects-rail-page main.wrap > .projects-rail > .projects-panel {
    width: 100%;
    flex: 1 1 auto;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #cbd8cc transparent;
  }

  body.universal-projects-rail-page.universal-news-rail-page main.wrap {
    width: calc(100vw - var(--home-content-left) - var(--projects-fixed-edge)) !important;
    max-width: none !important;
    margin-left: var(--home-content-left) !important;
    margin-right: 0 !important;
    grid-template-columns: minmax(0, 1fr) var(--projects-fixed-width);
    column-gap: 24px;
  }
}

@media (min-width: 1180px) and (max-width: 1359px) {
  body[data-page="home"] main.home-layout {
    grid-template-columns: var(--home-rail-width) minmax(0, 1fr) var(--projects-fixed-width);
    grid-template-areas: "news top projects" "news bottom projects";
    width: calc(100vw - 40px);
    max-width: none;
    margin-left: var(--home-rail-left);
    margin-right: 20px;
  }
  body[data-page="home"] main.home-layout > .projects-rail {
    grid-area: projects;
  }
}

@media (max-width: 1179px) {
  .projects-rail-head.feed-section-top{margin-bottom:11px}
}
