/* Shared navigation and the November page updates. Load after existing styles. */
:root { --site-header-height: 100px; }
html { scroll-padding-top: calc(var(--site-header-height) + 24px); }
section[id], main[id] { scroll-margin-top: 24px; }
a:focus-visible, summary:focus-visible, button:focus-visible { outline: 3px solid #73865d; outline-offset: 4px; }

/* Phone, messengers and two partner links are always visible. */
body > .site-header { color: #293126; background: #f3f1e9f5; }
.site-header .bar {
  display: grid; grid-template-columns: auto minmax(0,1fr) auto auto;
  align-items: center; gap: 24px; height: auto; min-height: 100px;
  width: 100%; max-width: 1480px; margin: auto;
  padding: 15px clamp(20px,5.6vw,80px);
}
.site-header .site-brand { display: inline-flex; align-items: center; }
.site-header .logo { display: block; width: 120px; max-width: 100%; height: auto; }
.site-header .brand { gap: 8px; font-size: 15px; }
.site-header .brand svg { flex: 0 0 30px; width: 30px; }
.site-header nav { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px 23px; width: auto; order: initial; }
.site-header nav a { font-size: 15px; font-weight: 600; line-height: 1.35; white-space: nowrap; }
.regiment-page .site-header nav { gap: 10px 16px; }
.regiment-page .site-header nav a { font-size: 13px; }
.site-header .nav-request { text-decoration: underline; text-underline-offset: 4px; }
.header-contacts { display: grid; justify-items: center; gap: 8px; }
.header-phone { font-size: 19px; font-weight: 750; line-height: 1.2; letter-spacing: -.025em; white-space: nowrap; }
.header-messengers { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.site-header .messenger {
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  min-height: 32px; padding: 5px 8px; border: 1px solid #c9ccbf; border-radius: 4px;
  background: #faf9f3; font-size: 11px; font-weight: 650; line-height: 1.2;
  transition: background .15s, border-color .15s;
}
.messenger svg { width: 16px; height: 16px; flex-shrink: 0; }
.messenger--telegram svg { color: #197ca4; }
.messenger--max svg { color: #6151b2; }
.messenger--whatsapp svg { color: #247a40; }
.site-header .messenger:hover { background: #e9ecdf; border-color: #8f9b80; text-decoration: none; }
.header-partners { display: grid; gap: 6px; min-width: 132px; }
.header-partners a {
  display: flex; align-items: center; justify-content: center; min-height: 33px;
  padding: 6px 13px; border: 1px solid #526147; border-radius: 4px;
  background: #e5e7d9; color: #303e29; font-size: 12px; line-height: 1.3; font-weight: 700;
  transition: background .15s;
}
.header-partners a:first-child { background: #3e5038; color: #fff; }
.header-partners a:hover { text-decoration: none; background: #d8ddcc; }
.header-partners a:first-child:hover { background: #2d4028; }
.toc { top: calc(var(--site-header-height) + 24px); max-height: calc(100vh - var(--site-header-height) - 48px); overflow-y: auto; }
.mobile-guide { top: var(--site-header-height); }
.home-visual .route-intro { top: calc(var(--site-header-height) + 28px); }

/* Three open, unnumbered cards stepping gently to the right. */
.audience-staircase { display: grid; gap: 20px; margin-top: 36px; }
.audience-card { width: 84%; padding: clamp(24px,3vw,38px); background: #e6e8dc; border-radius: 5px; }
.audience-card:nth-child(2) { margin-left: 8%; background: #ececdf; }
.audience-card:nth-child(3) { margin-left: 16%; background: #e3e6d8; }
.audience-card h3 { margin: 0 0 15px; max-width: 32ch; font-size: clamp(23px,2.4vw,32px); font-weight: 750; line-height: 1.2; letter-spacing: -.03em; }
.audience-card p { margin: 0; max-width: 88ch; color: #4b5746; font-size: 17px; line-height: 1.65; }

/* All nineteen roles stay inside the first catalog card. */
.regrow:has(.catalog-roles[open]) { align-items: start; }
.role-overview { min-width: 0; }
.catalog-roles { margin-top: 12px; }
.catalog-roles summary { display: inline-block; padding: 5px 0; list-style: none; font-size: 14px; font-weight: 700; color: #344d2f; text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }
.catalog-roles summary::-webkit-details-marker { display: none; }
.catalog-roles .when-open { display: none; }
.catalog-roles[open] .when-open { display: inline; }
.catalog-roles[open] .when-closed { display: none; }
.role-overview:has(.catalog-roles[open]) .role-preview { display: none; }
.role-overview:has(.catalog-roles[open]) .catalog-roles { margin-top: 0; }
.catalog-role-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; list-style: none; padding: 0; margin: 12px 0 0; }
.catalog-role-list li { min-width: 0; padding: 9px 11px; background: #e8ebdf; border-radius: 4px; font-size: 13px; line-height: 1.45; overflow-wrap: anywhere; }
.openreg { text-align: center; justify-content: center; }

/* Distinct salary groups; their amounts and source text are unchanged. */
.chapter .pay-block { overflow: hidden; margin: 24px 0; border: 1px solid #b9c2ab; border-radius: 6px; background: #faf9f3; }
.chapter .pay-block h3 { margin: 0; padding: 20px 24px; background: #536148; color: #fff; font-size: clamp(22px,2.1vw,28px); font-weight: 750; letter-spacing: -.025em; line-height: 1.2; }
.chapter .pay-block dl { margin: 0; padding: 6px 24px; }
.chapter .pay-block dl > div { grid-template-columns: minmax(130px,.85fr) minmax(0,1.6fr); gap: 22px; padding: 19px 0; border-bottom-color: #d8ddce; }
.chapter .pay-block dl > div:last-child { border-bottom: 0; }
.chapter .pay-block dt { font-weight: 700; color: #35442e; }
.chapter .pay-block dd { margin: 0; line-height: 1.6; }

/* Regiment page: stacked promises and a full, concise journey. */
.hero-specialty-line { display: block; margin-top: 7px; }
.regiment-page .unit-facts { grid-template-columns: minmax(0,1fr); max-width: 900px; padding: 0; gap: 12px; border-top: 0; margin-top: 28px; }
.regiment-page .unit-facts li { padding: 18px 24px; background: #e8eadd; border-left: 3px solid #647354; border-radius: 0 5px 5px 0; font-size: 18px; font-weight: 650; line-height: 1.45; }
.unit-route { background: #e5e6d9; }
.unit-route-layout { display: grid; grid-template-columns: .82fr 1.18fr; gap: 8%; }
.unit-route-intro { position: sticky; top: calc(var(--site-header-height) + 28px); align-self: start; }
.unit-route-intro p { color: #526047; font-size: 18px; max-width: 30ch; line-height: 1.6; }
.unit-route-list { list-style: none; padding: 0; margin: 0; }
#path.unit-route .route-step { position: relative; display: grid; grid-template-columns: 50px minmax(0,1fr); gap: 20px; padding: 0 0 32px; }
#path.unit-route .route-step:last-child { padding-bottom: 0; }
#path.unit-route .route-step:not(:last-child)::before { content: ''; position: absolute; left: 24px; top: 49px; bottom: 0; width: 1px; height: auto; border-radius: 0; background: #a6b298; }
#path.unit-route .route-no { display: grid; place-items: center; width: 49px; height: 49px; border: 1px solid #a5b196; border-radius: 50%; background: #f4f4e9; color: #46573c; font: 600 15px/1.4 'Courier New',monospace; transition: background .3s, color .3s; }
#path.unit-route .route-step.in-view .route-no { background: #3a5134; color: #fff; }
.unit-route h3 { margin: 0; padding-top: 9px; font-size: clamp(21px,1.75vw,27px); line-height: 1.2; font-weight: 750; }
#path.unit-route .route-step p { color: #4c5a45; margin: 10px 0 0; line-height: 1.65; }
.unit-channel-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; margin-top: 30px; }
.unit-channel { display: flex; align-items: center; gap: 24px; min-height: 128px; padding: 28px 32px; color: #fff; border-radius: 6px; transition: filter .15s, transform .15s; }
.unit-channel--telegram { background: #16799c; }
.unit-channel--max { background: #6254a2; }
.unit-channel svg { width: 42px; height: 42px; flex: 0 0 42px; }
.unit-channel span { font-size: clamp(17px,1.7vw,21px); line-height: 1.35; }
.unit-channel strong { display: block; margin-top: 3px; font-size: clamp(26px,2.6vw,34px); letter-spacing: -.025em; }
.unit-channel:hover { text-decoration: none; filter: brightness(.93); transform: translateY(-2px); }
.unit-channel:focus-visible { outline-color: #8c7748; }
.partner-placeholder { min-height: 58vh; padding-block: 80px; }
.partner-placeholder h1 { margin: 0 0 22px; font-size: clamp(40px,5vw,66px); line-height: 1.1; letter-spacing: -.045em; }
.partner-eyebrow { color: #5a674e; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.partner-back { display: inline-flex; margin-top: 22px; padding: 12px 18px; background: #3e5038; color: #fff; border-radius: 4px; font-weight: 600; }

@media (max-width: 1160px) {
  .site-header .bar { grid-template-columns: minmax(0,1fr) auto auto; gap: 12px 24px; }
  .site-header nav { grid-column: 1/-1; grid-row: 2; justify-content: flex-start; padding-top: 6px; }
  .site-header .header-contacts { grid-column: 2; grid-row: 1; }
  .site-header .header-partners { grid-column: 3; grid-row: 1; }
}
@media (max-width: 1000px) {
  html { scroll-padding-top: calc(var(--site-header-height) + 100px); }
}
@media (max-width: 880px) {
  .regrow .role-overview { grid-column: 2/-1; grid-row: 2; }
  .audience-card { width: 92%; }
  .audience-card:nth-child(2) { margin-left: 4%; }
  .audience-card:nth-child(3) { margin-left: 8%; }
  .unit-channel { padding: 24px; gap: 18px; }
}
@media (max-width: 680px) {
  body > .site-header { position: relative; }
  :root { --site-header-height: 0px; }
  .site-header .bar { grid-template-columns: minmax(0,1fr) auto; padding: 16px 5.6vw 14px; gap: 16px 18px; }
  .site-header .logo { width: 115px; }
  .site-header .brand { font-size: 14px; gap: 7px; }
  .site-header .header-partners { grid-column: 2; grid-row: 1; min-width: 130px; }
  .site-header .header-contacts { grid-column: 1/-1; grid-row: 2; gap: 10px; justify-items: start; }
  .header-phone { font-size: 20px; }
  .header-messengers { flex-wrap: nowrap; gap: 7px; width: 100%; }
  .site-header .messenger { flex: 1; min-height: 36px; padding: 7px 6px; font-size: 12px; }
  .site-header nav { grid-row: 3; padding-top: 0; gap: 13px 24px; }
  .site-header nav a { font-size: 14px; }
  .regiment-page .site-header nav { gap: 12px 20px; }
  .site-header .brand svg { width: 25px; flex-basis: 25px; }
  .audience-staircase { gap: 14px; margin-top: 26px; }
  .audience-card,.audience-card:nth-child(2),.audience-card:nth-child(3) { width: 100%; margin-left: 0; padding: 24px; }
  .audience-card h3 { font-size: 24px; }
  .audience-card p { font-size: 16px; }
  .chapter .pay-block h3 { padding: 18px; }
  .chapter .pay-block dl { padding: 0 18px; }
  .chapter .pay-block dl > div { grid-template-columns: minmax(0,1fr); gap: 8px; padding: 18px 0; }
  .unit-route-layout { grid-template-columns: minmax(0,1fr); gap: 24px; }
  .unit-route-intro { position: static; }
  .unit-route-intro p { max-width: none; }
  #path.unit-route .route-step { grid-template-columns: 40px minmax(0,1fr); gap: 14px; }
  #path.unit-route .route-no { width: 39px; height: 39px; }
  #path.unit-route .route-step:not(:last-child)::before { left: 19px; top: 39px; }
  .unit-route h3 { padding-top: 5px; }
  .regiment-page .unit-facts li { font-size: 16px; padding: 17px 18px; }
  .unit-channel-grid { grid-template-columns: minmax(0,1fr); gap: 14px; }
  .unit-channel { min-height: 112px; }
  .partner-placeholder { padding-block: 50px; }
}
@media (max-width: 600px) {
  .regrow .role-overview { grid-column: 1/-1; grid-row: 2; }
  .catalog-role-list { grid-template-columns: minmax(0,1fr); }
}
@media (prefers-reduced-motion: reduce) {
  #path.unit-route .route-no,.unit-channel,.site-header a { transition: none; }
  .unit-channel:hover { transform: none; }
}
