:root {
  --ink: #202124;
  --muted: #686b70;
  --paper: #f6f6f6;
  --white: #fff;
  --line: #e2e2e2;
  --orange: #ff4800;
  --orange-dark: #d83d00;
  --orange-soft: #fff1eb;
  --dark: #292929;
  --radius: 12px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--white); color: var(--ink); font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif; }
a { color: inherit; }
button, input, textarea, select { font: inherit; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, summary:focus-visible { outline: 3px solid rgba(255,72,0,.28); outline-offset: 3px; }
.shell { width: min(1280px, calc(100% - 48px)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
.skip-link { position: fixed; z-index: 100; top: 10px; left: 10px; padding: 12px 16px; background: var(--white); color: var(--ink); border: 2px solid var(--orange); border-radius: 6px; transform: translateY(-160%); transition: transform .15s; }
.skip-link:focus { transform: translateY(0); }
#main-content:focus { outline: none; }

.brand-strip { background: var(--dark); color: #d7d7d7; font-size: 12px; }
.brand-strip .shell { min-height: 36px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand-strip a { color: white; text-decoration: none; }
.site-header { position: relative; z-index: 5; background: white; border-bottom: 1px solid var(--line); }
.header-inner { min-height: 98px; display: flex; align-items: center; gap: 42px; }
.brand { display: inline-flex; align-items: center; text-decoration: none; flex: 0 0 auto; }
.brand img { display: block; width: 182px; height: auto; }
.brand-text { gap: 10px; color: var(--ink); }
.brand-text > span:last-child { display: grid; gap: 2px; }
.brand-text strong { font-size: 22px; letter-spacing: -.04em; }
.brand-text small { color: var(--muted); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; }
.brand-mark { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--orange); color: white; font-size: 24px; font-weight: 700; }
.kodos-banner { position: relative; width: min(1360px, calc(100% - 30px)); aspect-ratio: 2233 / 557; margin-top: 16px; margin-bottom: 16px; overflow: hidden; border-radius: 8px; background: #f2f2f2; box-shadow: 0 3px 12px rgba(10,21,72,.1); }
.kodos-banner__disclosure { position: absolute; z-index: 3; top: 10px; left: 12px; padding: 4px 7px; border-radius: 4px; background: rgba(0,0,0,.62); color: white; font-size: 10px; font-weight: 700; letter-spacing: .04em; }
.kodos-banner__slide { position: absolute; inset: 0; display: block; opacity: 0; pointer-events: none; transition: opacity .45s ease; }
.kodos-banner__slide.is-active { z-index: 1; opacity: 1; pointer-events: auto; }
.kodos-banner__image { display: block; width: 100%; height: 100%; object-fit: contain; }
.site-header nav { display: flex; align-items: center; gap: 28px; margin-left: auto; }
.site-header nav a { color: #444; text-decoration: none; font-size: 14px; font-weight: 500; white-space: nowrap; }
.site-header nav a:hover, .site-header nav a[aria-current="page"] { color: var(--orange); }
.header-search { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--paper); color: var(--orange); text-decoration: none; font-size: 20px; }

.hero { padding: 78px 0 84px; background: linear-gradient(115deg,#fff 0%,#fff 56%,#fff3ee 100%); border-bottom: 1px solid var(--line); }
.hero-grid { display: grid; grid-template-columns: minmax(0,1.1fr) minmax(360px,.7fr); gap: 70px; align-items: center; }
.eyebrow { color: var(--orange); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; margin: 0 0 16px; }
h1, h2, h3 { letter-spacing: -.025em; }
.hero h1 { max-width: 800px; font-size: clamp(46px,5vw,72px); line-height: 1.02; margin: 0; overflow-wrap: anywhere; }
.hero-copy { max-width: 680px; color: var(--muted); font-size: 19px; line-height: 1.55; margin: 26px 0 34px; }
.hero-tagline { color: var(--muted); font-style: italic; font-size: 16px; margin: 18px 0 28px; }
.hero-note { padding: 28px; border-left: 4px solid var(--orange); background: white; box-shadow: 0 16px 44px rgba(0,0,0,.07); }
.hero-note strong { display: block; font-size: 36px; margin-bottom: 8px; }
.hero-note p { color: var(--muted); line-height: 1.55; margin: 0; }
.search-bar { display: flex; max-width: 820px; padding: 6px; border: 1px solid #cfcfcf; border-radius: 8px; background: white; box-shadow: 0 12px 35px rgba(0,0,0,.08); }
.search-bar input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 16px 18px; font-size: 16px; }
.search-bar button, .button { border: 0; border-radius: 6px; background: var(--orange); color: white; padding: 15px 25px; text-decoration: none; font-weight: 700; cursor: pointer; }
.search-bar button:hover, .button:hover { background: var(--orange-dark); }

.section-block { padding: 72px 0; }
.section-block.alt { background: var(--paper); }
.section-block.compact { padding-bottom: 96px; }
.section-heading { display: flex; justify-content: space-between; gap: 40px; align-items: end; margin-bottom: 32px; }
.section-heading h2 { font-size: clamp(34px,4vw,48px); margin: 0; }
.section-heading > p { max-width: 500px; color: var(--muted); line-height: 1.6; margin: 0; }
.category-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; }
.category-card { min-height: 238px; padding: 26px; border: 1px solid var(--line); border-radius: var(--radius); background: white; display: flex; flex-direction: column; text-decoration: none; transition: border-color .2s, transform .2s, box-shadow .2s; }
.category-card:hover { border-color: var(--orange); transform: translateY(-3px); box-shadow: 0 16px 38px rgba(0,0,0,.07); }
.category-number { margin-left: auto; color: var(--orange); font-weight: 700; font-size: 13px; }
.category-card h3 { margin: auto 0 12px; font-size: 25px; line-height: 1.12; }
.category-card p { min-height: 66px; margin: 0 0 18px; color: var(--muted); font-size: 14px; line-height: 1.55; }
.category-card strong { color: var(--orange); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }

.materials-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
.material-card { overflow: hidden; background: white; border-radius: var(--radius); border: 1px solid var(--line); transition: transform .2s,box-shadow .2s; }
.material-card:hover { transform: translateY(-3px); box-shadow: 0 16px 40px rgba(0,0,0,.08); }
.card-cover { position: relative; display: block; aspect-ratio: 16/9; background: #dedede; overflow: hidden; }
.card-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.material-card:hover .card-cover img { transform: scale(1.025); }
.card-cover > span { position: absolute; right: 10px; bottom: 10px; padding: 5px 7px; background: rgba(0,0,0,.78); color: white; border-radius: 4px; font-size: 11px; font-weight: 700; }
.card-body { padding: 22px; }
.category-link { color: var(--orange); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; text-decoration: none; }
.card-body h3 { margin: 10px 0; font-size: 21px; line-height: 1.24; }
.card-body h3 a { text-decoration: none; }
.card-body p { min-height: 64px; color: var(--muted); font-size: 14px; line-height: 1.5; }
.card-meta { display: grid; grid-template-columns: 1fr auto; gap: 7px 12px; padding-top: 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.card-meta span:nth-child(even) { text-align: right; }
.empty-state { padding: 60px; background: white; border: 1px dashed #bdbdbd; border-radius: var(--radius); text-align: center; }
.empty-state h3 { font-size: 27px; margin: 0 0 10px; }
.empty-state p { color: var(--muted); margin: 0; }

.listing-page { min-height: 65vh; padding: 48px 0 96px; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 9px; color: var(--muted); font-size: 12px; margin-bottom: 52px; }
.breadcrumbs a { text-decoration: none; }
.breadcrumbs a:hover { color: var(--orange); }
.listing-head { margin-bottom: 48px; max-width: 800px; }
.listing-head h1, .search-page h1 { font-size: clamp(44px,6vw,68px); margin: 0 0 18px; }
.listing-head > p:not(.eyebrow) { color: var(--muted); font-size: 18px; line-height: 1.6; }
.listing-head > strong { display: inline-block; margin-top: 12px; color: var(--orange); font-size: 12px; text-transform: uppercase; }
.catalog-sort { display: flex; align-items: end; gap: 12px; margin: -14px 0 28px; padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.catalog-sort label { display: grid; flex: 1 1 auto; gap: 7px; color: var(--navy); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.catalog-sort select { min-width: min(100%, 360px); padding: 11px 38px 11px 12px; border: 1px solid #c9d0dc; border-radius: 6px; background: var(--white); color: var(--ink); }
.catalog-sort .button { flex: 0 0 auto; }
.catalog-controls { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 340px); gap: 24px; align-items: end; margin: -14px 0 28px; }
.catalog-controls__rubrics h2 { margin: 0 0 12px; color: var(--navy); font-size: 20px; }
.catalog-rubric-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.catalog-rubric-grid a { display: grid; gap: 5px; min-height: 70px; align-content: center; padding: 12px 14px; border: 1px solid var(--line); border-radius: 6px; background: var(--white); color: var(--navy); text-decoration: none; }
.catalog-rubric-grid a:hover, .catalog-rubric-grid a:focus-visible { border-color: var(--yellow); background: #fffbea; }
.catalog-rubric-grid a.is-active { border-color: var(--yellow); background: var(--yellow); }
.catalog-rubric-grid span { font-size: 14px; font-weight: 700; line-height: 1.25; }
.catalog-rubric-grid strong { color: var(--muted); font-size: 11px; font-weight: 700; }
.catalog-rubric-grid a.is-active strong { color: var(--navy); }
.catalog-controls .catalog-sort { display: grid; align-items: stretch; margin: 0; }
.catalog-controls .catalog-sort select, .catalog-controls .catalog-sort .button { width: 100%; }
.is-public .fire-catalog { grid-template-columns: minmax(0, 1fr); }
.is-public .fire-catalog .catalog-rubric-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.is-public .fire-catalog .catalog-rubric-grid a { min-width: 0; min-height: 92px; }
@media (min-width: 621px) and (max-width: 960px) {
  .is-public .fire-catalog .catalog-rubric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.search-page .search-bar { margin: 30px 0; }
.search-summary { color: var(--muted); margin: 35px 0 22px; }

.article-hero { padding: 64px 0 72px; background: var(--paper); border-bottom: 1px solid var(--line); }
.article-hero .breadcrumbs { margin-bottom: 42px; }
.article-hero-copy { max-width: 1040px; margin-inline: auto; text-align: center; }
.article-hero-copy h1 { max-width: 1040px; margin: 15px auto 22px; font-size: clamp(42px,5.5vw,66px); line-height: 1.06; overflow-wrap: anywhere; }
.article-hero-copy > p { max-width: 820px; margin-inline: auto; color: var(--muted); font-size: 19px; line-height: 1.6; }
.article-hero-copy .category-link { display: inline-block; }
.article-hero-copy .article-meta { justify-content: center; }
.article-meta { display: flex; flex-wrap: wrap; gap: 10px 24px; margin-top: 28px; font-size: 12px; font-weight: 600; color: var(--muted); }
.article-layout { display: grid; grid-template-columns: minmax(0,820px) minmax(320px,1fr); gap: 70px; align-items: start; padding: 58px 0 96px; }
.article-copy section { margin-bottom: 48px; scroll-margin-top: 24px; }
.article-copy h2, .fragments-head h2 { font-size: 34px; line-height: 1.15; margin: 0 0 20px; }
.article-copy p { color: #353535; font-size: 18px; line-height: 1.78; margin: 0 0 17px; }
.quick-answer { padding: 30px; border-left: 4px solid var(--orange); background: var(--orange-soft); }
.quick-answer h2 { font-size: 25px; }
.quick-answer p { margin: 0; font-size: 18px; }
.takeaways { padding: 30px; border: 1px solid var(--line); border-radius: var(--radius); }
.takeaways ul, .checklist { margin: 0; padding: 0; list-style: none; display: grid; gap: 13px; }
.takeaways li, .checklist li { position: relative; padding-left: 28px; line-height: 1.55; }
.takeaways li::before { content: "→"; position: absolute; left: 0; color: var(--orange); font-weight: 700; }
.checklist li::before { content: "✓"; position: absolute; left: 0; color: var(--orange); font-weight: 700; }
.article-toc { padding: 26px 28px; border-radius: var(--radius); background: var(--paper); }
.article-toc h2 { font-size: 23px; }
.article-toc ol { margin: 0; padding-left: 22px; display: grid; gap: 9px; }
.article-toc a { color: #444; text-decoration: none; line-height: 1.4; }
.article-toc a:hover { color: var(--orange); }
.glossary { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.glossary > div { padding: 20px; background: var(--paper); border-radius: 8px; }
.glossary dt { font-weight: 700; margin-bottom: 7px; }
.glossary dd { margin: 0; color: var(--muted); line-height: 1.55; }
.source-box { padding: 32px; background: #303030; color: white; border-radius: var(--radius); }
.source-box h2 { color: white; }
.source-box p:not(.eyebrow) { color: #d7d7d7; font-size: 15px; line-height: 1.6; margin-bottom: 25px; }
.source-image { margin-top: 20px; }
.source-image img { display: block; width: 100%; height: auto; border-radius: 8px; user-select: none; -webkit-user-select: none; pointer-events: none; }
.source-image-link { display: block; border-radius: 8px; cursor: pointer; transition: box-shadow .18s ease, transform .18s ease; }
.source-image-link:hover { transform: translateY(-1px); box-shadow: 0 0 0 3px var(--gold); }
.source-image-link:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }
.source-box .source-access-note { margin: 12px 0 0; color: #d7d7d7; font-size: 13px; }
.source-box .source-auth-link { color: var(--gold); font-weight: 700; text-underline-offset: 3px; }
.article-neighbors { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 18px; }
.article-neighbors a { display: grid; gap: 5px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); text-decoration: none; }
.article-neighbors a:hover { border-color: var(--gold); }
.article-neighbors small { color: var(--muted); }
@media (max-width: 640px) { .article-neighbors { grid-template-columns: 1fr; } }
.article-poster { width: min(100%, 720px); aspect-ratio: 16 / 9; margin: 28px auto 0; overflow: hidden; border: 1px solid rgba(255,255,255,.26); border-radius: 8px; background: #030821; }
.article-poster img { display: block; width: 100%; height: 100%; object-fit: cover; }
.policy-page { min-height: 65vh; padding: 48px 0 96px; }
.policy-copy { max-width: 820px; padding: 42px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.policy-copy h1 { margin: 0 0 24px; font-size: clamp(38px,5vw,58px); }
.policy-copy h2 { margin-top: 38px; }
.policy-copy p { color: var(--muted); font-size: 17px; line-height: 1.7; }
.policy-copy ul { display: grid; gap: 10px; margin: 14px 0 24px; padding-left: 24px; color: var(--muted); font-size: 16px; line-height: 1.65; }
.policy-copy code { padding: 2px 5px; border-radius: 4px; background: var(--paper); color: var(--navy); font-size: .88em; }
.policy-revision { margin-top: -14px; font-size: 14px !important; }
.policy-details { display: grid; gap: 0; margin: 16px 0 24px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.policy-details div { display: grid; grid-template-columns: minmax(120px, 180px) 1fr; gap: 16px; padding: 12px 15px; border-top: 1px solid var(--line); }
.policy-details div:first-child { border-top: 0; }
.policy-details dt { color: var(--muted); font-size: 13px; font-weight: 700; }
.policy-details dd { margin: 0; overflow-wrap: anywhere; }
@media (max-width: 600px) { .policy-copy { padding: 28px 20px; } .policy-details div { grid-template-columns: 1fr; gap: 4px; } }
.fragments-panel { position: sticky; top: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: white; overflow: hidden; }
.fragments-panel > summary { display: none; }
.fragments { max-height: calc(100vh - 44px); overflow: auto; padding: 26px; }
.fragments-head { margin-bottom: 16px; }
.fragments-head > p:last-child { color: var(--muted); font-size: 13px; }
.fragment { border-top: 1px solid var(--line); }
.fragment:last-child { border-bottom: 1px solid var(--line); }
.fragment-toggle { width: 100%; display: grid; grid-template-columns: 50px 1fr 20px; gap: 12px; align-items: start; padding: 16px 0; border: 0; color: var(--ink); background: transparent; text-align: left; cursor: pointer; font-size: 13px; line-height: 1.5; }
.timecode { color: var(--orange); font-weight: 700; font-size: 11px; padding-top: 2px; }
.plus { color: var(--orange); font-size: 19px; line-height: 1; transition: transform .2s; }
.fragment-toggle[aria-expanded="true"] .plus { transform: rotate(45deg); }
.fragment-explanation { padding: 0 28px 20px 62px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.fragment-explanation p { margin: 0 0 9px; }
.kodos-expert { --kodos-ink: #17253e; --kodos-surface: #f5f7fa; position: relative; display: grid; gap: 26px; margin: 4px 0 48px; padding: 28px 30px 30px; overflow: hidden; border: 1px solid #dce3ea; border-radius: 16px; background: var(--kodos-surface); color: var(--kodos-ink); box-shadow: 0 14px 36px rgba(23, 37, 62, .07); }
.kodos-expert::before { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 4px; background: #ff4800; pointer-events: none; }
.kodos-expert__masthead { position: relative; display: flex; align-items: center; gap: 18px; }
.kodos-expert__brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.kodos-expert__mark { display: grid; flex: 0 0 auto; place-items: center; width: 46px; height: 46px; padding: 3px; overflow: hidden; border: 1px solid #e1e6ec; border-radius: 10px; background: #fff; }
.kodos-expert__mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
.kodos-expert__brand-copy { display: grid; gap: 1px; min-width: 0; }
.kodos-expert__brand-copy strong { color: var(--kodos-ink); font-size: 22px; line-height: 1; letter-spacing: .035em; }
.kodos-expert__brand-copy small { color: #536273; font-size: 9px; font-weight: 700; line-height: 1.2; letter-spacing: .12em; text-transform: uppercase; }
.kodos-expert__content { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(210px, 248px); gap: 28px; align-items: end; padding-top: 24px; border-top: 1px solid #dce3ea; }
.kodos-expert__copy h2 { max-width: 560px; margin: 0 0 13px; color: var(--kodos-ink); font-size: clamp(27px, 3vw, 35px); line-height: 1.08; letter-spacing: -.035em; }
.article-copy .kodos-expert__message { max-width: 620px; margin: 0; color: #43546a; font-size: 16px; line-height: 1.62; }
.kodos-expert__action { display: grid; gap: 10px; }
.kodos-expert .kodos-expert__link { display: flex; min-height: 50px; align-items: center; justify-content: center; padding: 13px 10px; border-radius: 9px; background: #203858; color: #fff; font-size: 13px; line-height: 1.3; text-align: center; white-space: nowrap; transition: background-color .16s ease, transform .16s ease, box-shadow .16s ease; }
.kodos-expert .kodos-expert__link:hover { background: #132741; color: #fff; transform: translateY(-2px); box-shadow: 0 10px 24px rgba(23, 37, 62, .16); }
.kodos-expert .kodos-expert__link:focus-visible { outline: 3px solid #ff4800; outline-offset: 4px; box-shadow: none; }
@media (max-width: 860px) {
  .kodos-expert { gap: 22px; padding: 25px 23px 26px; }
  .kodos-expert__content { grid-template-columns: 1fr; gap: 22px; }
  .kodos-expert__copy h2 { font-size: 28px; }
  .kodos-expert .kodos-expert__link { width: 100%; white-space: normal; text-wrap: balance; }
}
@media (max-width: 520px) {
  .kodos-expert { margin-bottom: 42px; padding: 22px 20px 23px; border-radius: 14px; }
  .kodos-expert__masthead { align-items: flex-start; }
  .kodos-expert__brand-copy small { max-width: 126px; }
  .kodos-expert__copy h2 { font-size: 27px; }
}
.related { border-top: 1px solid var(--line); }
.preview-banner { display: flex; justify-content: center; gap: 12px 24px; padding: 14px 24px; border-bottom: 1px solid #e2b542; background: #fff7d6; color: #4d3a00; font-size: 13px; line-height: 1.45; }
.preview-banner span { color: #705a13; }

.site-footer { background: var(--dark); color: #bbb; padding: 48px 0; }
.footer-inner { display: flex; justify-content: space-between; gap: 30px; align-items: start; font-size: 13px; }
.site-footer strong { color: white; text-transform: uppercase; letter-spacing: .08em; }
.site-footer p { margin: 8px 0 0; }
.site-footer a { color: white; font-weight: 600; text-decoration: none; }
.cookie-banner { position: fixed; z-index: 20; right: 22px; bottom: 22px; width: min(480px,calc(100% - 44px)); padding: 22px; background: #202020; color: white; border-radius: var(--radius); box-shadow: 0 20px 70px rgba(0,0,0,.25); }
.cookie-banner p { margin: 0 0 17px; font-size: 13px; line-height: 1.55; color: #d4dcdf; }
.cookie-banner strong, .cookie-banner a { color: white; }
.cookie-banner > div { display: flex; justify-content: end; gap: 8px; }
.cookie-banner .button { padding: 11px 15px; font-size: 12px; }
.footer-links { display: flex; align-items: center; gap: 18px; }
.footer-links button { padding: 0; border: 0; background: transparent; color: inherit; font: inherit; text-decoration: underline; cursor: pointer; }
.button-muted { background: #555; }
.button-small { padding: 9px 12px; font-size: 12px; }
.admin-page { min-height: 70vh; padding: 60px 0 100px; }
.admin-login { max-width: 520px; margin: 40px auto; padding: 36px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.admin-login h1, .admin-head h1 { margin: 0 0 14px; font-size: clamp(36px,5vw,56px); }
.admin-login > p:not(.eyebrow), .admin-head p:not(.eyebrow) { color: var(--muted); line-height: 1.6; }
.admin-form { display: grid; gap: 12px; margin-top: 24px; }
.admin-form label { font-size: 12px; color: var(--muted); font-weight: 700; }
.admin-form input, .admin-form textarea { width: 100%; border: 1px solid #cfcfcf; border-radius: 7px; padding: 13px 14px; background: white; }
.admin-form textarea { resize: vertical; min-height: 150px; }
.admin-head { display: flex; justify-content: space-between; align-items: start; gap: 30px; margin-bottom: 35px; }
.admin-card { margin: 24px 0; padding: 28px; border: 1px solid var(--line); border-radius: var(--radius); background: white; }
.admin-card h2 { margin: 0; font-size: 28px; }
.admin-notice { margin: 18px 0; padding: 14px 16px; border-left: 4px solid var(--orange); background: var(--orange-soft); color: #4a271c; }
.admin-notice-error { border-left-color: #b42318; background: #fff0ef; }
.admin-table-wrap { overflow-x: auto; margin-top: 24px; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.admin-table th, .admin-table td { padding: 14px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.admin-table th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.admin-table code { overflow-wrap: anywhere; }
.admin-table td small { display: block; margin-top: 5px; color: var(--muted); line-height: 1.4; }
.admin-error-text { color: #991b1b; overflow-wrap: anywhere; }
.status { display: inline-block; padding: 4px 8px; border-radius: 999px; background: var(--paper); font-size: 11px; font-weight: 700; }
.status-queued { color: #8a5a00; background: #fff5d6; }.status-published { color: #166534; background: #eaf8ef; }.status-rejected, .status-error { color: #991b1b; background: #fff0ef; }
.status-active { color: #166534; background: #eaf8ef; }.status-expired, .status-revoked { color: #6b7280; background: #eef0f3; }
.temporary-token-card { border-color: #d8b13f; background: #fffaf0; }
.temporary-token-card > p { color: var(--muted); line-height: 1.55; }
.token-copy-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; margin-top: 18px; }
.token-copy-row input { min-width: 0; border: 1px solid #cfcfcf; border-radius: 7px; padding: 13px 14px; background: white; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.admin-help { font-size: 13px; }
.button-danger { color: #991b1b; border-color: #e9b6b1; background: #fff0ef; }
.button-danger:hover { color: white; background: #991b1b; }
[hidden] { display: none !important; }

@media (max-width: 1100px) {
  .site-header nav { gap: 17px; }
  .category-grid { grid-template-columns: repeat(2,1fr); }
  .materials-grid { grid-template-columns: repeat(2,1fr); }
  .article-layout { grid-template-columns: minmax(0,1fr) 340px; gap: 36px; }
}
@media (max-width: 960px) {
  .hero-grid, .article-layout { grid-template-columns: 1fr; }
  .hero-note { display: none; }
  .fragments-panel { position: static; }
  .fragments-panel > summary { display: flex; justify-content: space-between; padding: 20px 22px; color: var(--orange); font-weight: 700; cursor: pointer; }
  .fragments-panel > summary::after { content: "+"; }
  .fragments-panel[open] > summary::after { content: "−"; }
  .fragments { max-height: none; border-top: 1px solid var(--line); }
}
@media (max-width: 720px) {
  .shell { width: min(100% - 30px,1280px); }
  .brand-strip .shell { justify-content: center; }.brand-strip span:last-child { display: none; }
  .header-inner { min-height: 78px; gap: 16px; }.brand img { width: 142px; }
  .site-header nav { overflow-x: auto; order: 3; width: 100%; padding-bottom: 13px; margin: 0; }
  .header-inner { flex-wrap: wrap; }.header-search { margin-left: auto; }
  .hero { padding: 54px 0 62px; }.hero h1 { font-size: 43px; }.hero-copy { font-size: 17px; }
  .search-bar { display: grid; }.search-bar button { width: 100%; }
  .section-block { padding: 56px 0; }.section-heading { display: block; }.section-heading > p { margin-top: 16px; }
  .catalog-all-button { display: inline-flex; margin-top: 18px; }
  .category-grid, .materials-grid, .glossary { grid-template-columns: 1fr; }
  .category-card { min-height: 220px; }.card-body p { min-height: auto; }
  .article-hero { padding-top: 38px; }.article-hero h1 { font-size: clamp(34px, 9vw, 40px); }
  .article-hero-copy { text-align: left; }.article-hero-copy h1, .article-hero-copy > p { margin-left: 0; margin-right: 0; }.article-hero-copy .article-meta { justify-content: flex-start; }
  .article-layout { padding-top: 38px; }.article-copy h2, .fragments-head h2 { font-size: 29px; }.article-copy p { font-size: 17px; }
  .quick-answer, .takeaways, .source-box { padding: 23px; }.fragment-explanation { padding-left: 0; }
  .footer-inner { display: grid; }.cookie-banner > div { display: grid; }
  .admin-head { display: grid; }.admin-card, .admin-login { padding: 22px; }.token-copy-row { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* SEC.RU visual system: calm documentation portal with navy hero and yellow action. */
:root {
  --ink: #101a3d;
  --muted: #5d6677;
  --paper: #f4f6f9;
  --white: #fff;
  --line: #dfe4ec;
  --orange: #c58b00;
  --orange-dark: #9b6d00;
  --orange-soft: #fff8df;
  --dark: #101a3d;
  --navy: #0b1549;
  --yellow: #ffd65a;
  --radius: 8px;
}

body { background: var(--paper); color: var(--ink); }
.shell { width: min(1168px, calc(100% - 40px)); }
.brand-strip { display: none; }
.site-header { position: sticky; top: 0; z-index: 100; padding: 12px 0; background: var(--white); border-bottom: 1px solid #e5e7eb; font-family: -apple-system, system-ui, "Segoe UI", Roboto, sans-serif; }
.header-container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.site-header .container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.header-inner { min-height: 36px; display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.sec-brand { display: flex; align-items: center; color: #01103e; }
.sec-brand img { display: block; width: auto; height: 36px; }
.brand-text { gap: 0; }
.brand-text .brand-mark { display: none; }
.brand-text strong { color: var(--navy); font-size: 24px; letter-spacing: -.055em; }
.brand-text small { display: none; }
.site-header nav { gap: 36px; flex-wrap: wrap; }
.site-header nav a { margin-bottom: -10px; padding: 0 0 6px; border-bottom: 4px solid transparent; color: #1f2937; font-size: 16px; font-weight: 400; line-height: 1.6; }
.site-header nav a:hover, .site-header nav a[aria-current="page"] { color: #01103e; }
.site-header nav a[aria-current="page"] { border-bottom-color: var(--yellow); font-weight: 700; }
.header-search { width: 36px; height: 36px; border-radius: 50%; background: var(--paper); color: var(--navy); }
.auth-state { display: flex; align-items: center; gap: 10px; font-size: 14px; white-space: nowrap; }
.auth-state form { margin: 0; }
.auth-state__identity { max-width: 180px; overflow: hidden; color: var(--muted); text-overflow: ellipsis; }
.auth-state__action { margin-bottom: -10px; padding: 0 0 6px; border: 0; border-bottom: 4px solid transparent; border-radius: 0; background: transparent; color: #1f2937; font: inherit; font-size: 16px; font-weight: 400; line-height: 1.6; cursor: pointer; }
.auth-state__action:hover { color: var(--navy); }
.header-search-form { display: flex; align-items: center; gap: 16px; flex: 1 0 100%; margin: -6px 0 0; }
.header-search-form label { flex: 0 0 auto; color: var(--navy); font-size: 14px; font-weight: 800; }
.header-search-form__fields { display: flex; flex: 1 1 auto; min-width: 0; max-width: 760px; border: 1px solid #b8c3d4; border-radius: 7px; overflow: hidden; background: var(--white); }
.header-search-form input { flex: 1 1 auto; min-width: 0; padding: 10px 14px; border: 0; background: transparent; color: var(--navy); font: inherit; font-size: 15px; }
.header-search-form button { flex: 0 0 auto; padding: 10px 20px; border: 0; background: var(--yellow); color: var(--navy); font: inherit; font-weight: 800; cursor: pointer; }
.header-search-form button:hover { background: #ffe184; }
.header-search-form input:focus-visible, .header-search-form button:focus-visible { outline: 2px solid var(--navy); outline-offset: -2px; }

.hero { padding: 28px 0 32px; background: transparent; border: 0; }
.hero-grid { display: grid; grid-template-columns: 1fr; gap: 0; max-width: 1168px; padding: 42px 52px 34px; border-radius: 9px; background: linear-gradient(135deg, #0a1548 0%, #1b2b68 100%); color: white; }
.hero .eyebrow { color: var(--yellow); }
.hero h1 { max-width: 960px; color: white; font-size: clamp(40px, 4.4vw, 56px); line-height: 1.08; }
.hero-tagline { color: #f9df87; margin: 12px 0 16px; }
.hero-copy { max-width: 880px; color: #e8edf8; margin: 0 0 22px; font-size: 17px; line-height: 1.5; }
.hero-note { display: flex; gap: 64px; align-items: baseline; margin-top: 24px; padding: 20px 0 0; border: 0; border-top: 1px solid rgba(255,255,255,.28); background: transparent; box-shadow: none; }
.hero-note strong { margin: 0; color: white; font-size: 34px; }
.hero-note p { color: #e8edf8; font-size: 15px; }
.search-bar { max-width: 640px; padding: 0; border: 0; box-shadow: none; border-radius: 8px; overflow: hidden; }
.search-bar input { padding: 12px 16px; background: white; }
.search-bar button, .button { border-radius: 0; background: var(--yellow); color: var(--navy); padding: 12px 24px; }
.search-bar button:hover, .button:hover { background: #ffe184; color: var(--navy); }

.section-block { padding: 48px 0; }
.hero + .section-block { padding-top: 30px; }
.section-block.alt { background: transparent; }
.section-heading { margin-bottom: 28px; }
.section-heading h2 { color: var(--navy); font-size: clamp(32px, 4vw, 44px); }
.catalog-all-button { flex: 0 0 auto; }
.catalog-all-footer { display: flex; justify-content: center; margin-top: 32px; }
.catalog-all-cta { display: flex; justify-content: center; padding-top: 8px; padding-bottom: 56px; }
.eyebrow { color: var(--orange); }
.materials-grid { gap: 18px; }
.material-card { border-radius: 8px; border-color: var(--line); box-shadow: 0 2px 7px rgba(10,21,72,.04); }
.material-card:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(10,21,72,.1); }
.card-cover { background: #dfe4ee; }
.card-cover > span { background: var(--navy); }
.card-body { padding: 20px; }
.category-link, .card-meta span:first-child { color: var(--orange); }
.pagination { display: grid; grid-template-columns: auto minmax(0,auto) auto; align-items: center; justify-content: center; gap: 12px 18px; margin: 38px 0 8px; }
.pagination__pages { display: flex; align-items: center; justify-content: center; gap: 6px; }
.pagination__page, .pagination__ellipsis { display: grid; place-items: center; min-width: 42px; height: 42px; padding: 0 10px; border: 1px solid var(--line); border-radius: 6px; color: var(--navy); background: var(--white); font-size: 14px; font-weight: 700; text-decoration: none; }
.pagination__page:hover { border-color: var(--yellow); background: #fff8d8; }
.pagination__page.is-current { border-color: var(--yellow); background: var(--yellow); color: var(--navy); }
.pagination__ellipsis { min-width: 28px; padding: 0; border-color: transparent; background: transparent; }
.pagination__summary { grid-column: 1 / -1; text-align: center; color: var(--muted); font-size: 13px; font-weight: 600; }
.pagination__direction.is-disabled { opacity: .42; pointer-events: none; }
.pagination-archive { max-width: 760px; margin: 10px auto 40px; color: var(--muted); font-size: 14px; }
.pagination-archive summary { width: fit-content; margin: 0 auto; cursor: pointer; }
.pagination-archive__pages { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 14px; }
.pagination-archive__pages a { display: grid; place-items: center; min-width: 36px; min-height: 36px; padding: 0 8px; border: 1px solid var(--line); border-radius: 6px; color: var(--navy); text-decoration: none; }
.pagination-archive__pages a:hover, .pagination-archive__pages a:focus-visible { border-color: var(--yellow); background: #fff8d8; }
.card-body h3 { color: var(--navy); }
.card-meta { border-color: var(--line); }

.listing-page { padding-top: 40px; }
.listing-head h1, .search-page h1 { color: var(--navy); }
.article-hero { width: min(1168px, calc(100% - 40px)); margin: 32px auto 0; padding: 30px 40px 36px; border: 0; border-radius: 9px; background: linear-gradient(135deg, #0a1548 0%, #1b2b68 100%); color: white; }
.article-hero .breadcrumbs { margin-bottom: 24px; color: #d9e1f2; }
.article-hero .breadcrumbs a:hover { color: var(--yellow); }
.article-hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(240px, 320px); gap: 30px; align-items: center; }
.article-hero-copy { max-width: none; text-align: left; }
.article-hero-copy .category-link { color: var(--yellow); }
.article-hero-copy h1 { max-width: none; margin: 10px 0 16px; color: white; font-size: clamp(32px, 3.2vw, 48px); line-height: 1.08; }
.article-hero-copy > p { max-width: 680px; margin: 0; color: #e8edf8; font-size: 16px; line-height: 1.5; }
.article-hero-copy .article-meta { justify-content: flex-start; margin-top: 18px; }
.article-poster { width: min(100%, 320px); margin: 0 0 0 auto; }
.article-meta { color: #d5dcef; }
.article-layout { padding-top: 52px; }
.quick-answer { border: 0; border-left: 4px solid var(--yellow); background: var(--orange-soft); }
.article-toc { background: #e8edf5; }
.source-box { background: var(--navy); border-radius: 8px; }
.fragments-panel { border-color: var(--line); border-radius: 8px; }
.timecode, .plus { color: var(--orange); }
.site-footer { background: var(--white); border-top: 1px solid var(--line); color: var(--muted); padding: 34px 0; }
.site-footer strong, .site-footer a { color: var(--navy); }
.project-status { color: #7a5b00; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }

@media (max-width: 960px) {
  .article-hero-grid { grid-template-columns: 1fr; }
  .article-poster { width: min(100%, 420px); margin-inline: auto; }
}

@media (max-width: 720px) {
  .shell { width: min(100% - 30px, 1168px); }
  .header-inner { min-height: 0; gap: 24px; flex-wrap: wrap; }
  .sec-brand img { height: 30px; }
  .site-header nav { order: initial; width: auto; margin-left: auto; padding-bottom: 0; overflow: visible; gap: 24px; }
  .header-search-form { flex-wrap: wrap; gap: 7px; margin-top: 0; }
  .header-search-form label { flex-basis: 100%; }
  .header-search-form__fields { max-width: none; }
  .header-search-form input { padding: 10px 11px; font-size: 14px; }
  .header-search-form button { padding: 10px 14px; }
  .auth-state__identity { display: none; }
  .auth-state__action { font-size: 16px; }
  .hero { padding: 16px 0 22px; }
  .hero-grid { padding: 30px 24px 26px; }
  .hero h1 { font-size: 36px; }
  .hero-copy { font-size: 16px; }
  .hero-note { gap: 18px; margin-top: 20px; padding-top: 18px; }
  .hero-note strong { font-size: 28px; }
  .hero-note p { font-size: 13px; }
  .article-hero { width: min(100% - 30px, 1168px); margin-top: 16px; padding: 24px 20px 28px; }
  .article-hero .breadcrumbs { margin-bottom: 20px; }
  .article-hero-grid { gap: 24px; }
  .article-hero-copy h1 { font-size: clamp(30px, 8.5vw, 38px); }
  .article-poster { width: 100%; margin: 0; }
  .article-layout { padding-top: 34px; }
  .kodos-banner { width: calc(100% - 30px); margin-top: 10px; margin-bottom: 10px; border-radius: 6px; }
  .pagination { grid-template-columns: 1fr 1fr; width: 100%; gap: 12px; }
  .pagination__pages { grid-column: 1 / -1; grid-row: 1; justify-content: flex-start; overflow-x: auto; padding: 3px; scrollbar-width: thin; }
  .pagination__direction { grid-row: 2; text-align: center; }
  .pagination__summary { grid-row: 3; }
  .catalog-sort { display: grid; align-items: stretch; }
  .catalog-sort select, .catalog-sort .button { width: 100%; }
  .catalog-controls { grid-template-columns: 1fr; }
  .catalog-rubric-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .kodos-banner__slide { transition: none; }
}

/* Admin workspace: isolated from the public catalogue and legacy queue screen. */
.admin-workspace { --admin-accent: var(--yellow); }
.admin-workspace-head { display: flex; min-height: 52px; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 10px; }
.admin-workspace-head h1 { margin: 0; color: var(--navy); font-size: 30px; line-height: 1; }
.admin-list-total { margin: 8px 0 14px; color: var(--muted); font-size: 14px; }
.admin-workspace-nav { display: flex; gap: 4px; margin-bottom: 18px; padding: 4px; overflow-x: auto; border: 1px solid var(--line); border-radius: 9px; background: var(--white); scrollbar-width: thin; }
.admin-workspace-nav a { flex: 0 0 auto; padding: 9px 13px; border-radius: 6px; color: var(--muted); font-size: 13px; font-weight: 600; text-decoration: none; }
.admin-workspace-nav a:hover { color: var(--navy); background: var(--paper); }
.admin-workspace-nav a[aria-current="page"] { color: var(--navy); background: var(--admin-accent); }
.admin-workspace .admin-card { box-shadow: 0 2px 8px rgba(10, 21, 72, .035); }
.admin-workspace .admin-card h2 { color: var(--navy); }
.admin-workspace .button-muted { background: #e8edf5; color: var(--navy); }
.admin-workspace .button-muted:hover { background: #d9e1ef; color: var(--navy); }
.admin-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; margin-bottom: 20px; }
.admin-card-head .eyebrow { margin-bottom: 8px; }
.admin-card-head > span:not(.status) { color: var(--muted); font-size: 13px; }
.admin-workspace textarea,
.admin-workspace input:not([type="checkbox"]):not([type="hidden"]),
.admin-workspace select { width: 100%; border: 1px solid #c9d0dc; border-radius: 7px; padding: 12px 13px; background: var(--white); color: var(--ink); font: inherit; }
.admin-workspace textarea { min-height: 110px; resize: vertical; line-height: 1.55; }
.admin-workspace input[readonly] { background: var(--paper); color: var(--muted); }
.admin-workspace textarea:focus-visible,
.admin-workspace select:focus-visible { outline: 3px solid rgba(255, 214, 90, .55); outline-offset: 2px; border-color: var(--orange); }
.admin-search-panel { padding: 24px; }
.admin-search-form { display: grid; gap: 10px; }
.admin-external-search-form { display: grid; grid-template-columns: 1fr; gap: 18px; }
.admin-external-search-form > label { display: grid; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.admin-search-constraints { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.admin-search-constraints label { display: grid; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.admin-form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.admin-form-actions .admin-help { max-width: 640px; margin: 0; color: var(--muted); line-height: 1.45; }
.admin-search-form > label,
.admin-filter-form label,
.admin-editor-form label { color: var(--muted); font-size: 12px; font-weight: 700; }
.admin-search-row { display: grid; grid-template-columns: minmax(0, 1fr) 190px auto; gap: 10px; }
.admin-result-list { display: grid; gap: 0; }
.admin-result-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 28px; padding: 24px 0; border-top: 1px solid var(--line); }
.admin-result-item:first-child { border-top: 0; padding-top: 4px; }
.admin-result-main h3 { margin: 10px 0 8px; color: var(--navy); font-size: 22px; }
.admin-result-main > p { max-width: 780px; margin: 0; color: var(--muted); line-height: 1.55; }
.admin-result-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; color: var(--muted); font-size: 12px; }
.admin-result-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
.admin-result-actions > a:not(.button),
.admin-inline-actions > a:not(.button) { color: var(--navy); font-size: 12px; font-weight: 700; }
.admin-match-list { display: grid; gap: 8px; margin: 16px 0 0; padding: 0; list-style: none; color: #394156; font-size: 13px; }
.admin-match-list li { padding: 10px 12px; border-left: 3px solid var(--admin-accent); background: var(--paper); }
.admin-match-list strong { margin-right: 8px; color: var(--orange); }
.admin-filter-form { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(160px, 240px) auto; gap: 12px; align-items: end; }
.admin-filter-form label { display: grid; gap: 7px; }
.admin-filter-card { padding: 20px 24px; }
.admin-content-table td:first-child { min-width: 320px; }
.admin-content-table td:first-child strong { display: block; color: var(--navy); font-size: 14px; line-height: 1.4; }
.admin-content-table td:first-child small { display: block; max-width: 540px; margin-top: 7px; color: var(--muted); line-height: 1.45; }
.admin-candidate-table td:nth-child(2) { min-width: 320px; }
.admin-candidate-table td:nth-child(2) > a { color: var(--navy); text-decoration: none; line-height: 1.4; }
.admin-candidate-table td:nth-child(2) small,
.admin-version-table td:first-child small { display: block; margin-top: 7px; color: var(--muted); font-size: 11px; line-height: 1.4; }
.admin-candidate-table td:nth-child(3) span { display: block; min-width: 130px; margin-bottom: 5px; color: var(--muted); font-size: 11px; }
.admin-candidate-table td:nth-child(3) b { color: var(--navy); }
.admin-version-table td:first-child { min-width: 260px; }
.admin-version-table form { margin: 0; }
.admin-inline-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.admin-editor-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; align-items: start; }
.admin-editor-form { min-width: 0; }
.admin-editor-form > .admin-card:first-of-type { margin-top: 0; }
.admin-editor-form textarea { width: 100%; margin-top: 7px; }
.admin-field-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.admin-field-grid label { display: grid; gap: 7px; }
.admin-field-wide { grid-column: 1 / -1; }
.admin-editor-label { display: grid; gap: 7px; margin-top: 18px; }
.admin-editor-form label small { display: block; margin-top: 3px; color: var(--muted); font-weight: 400; }
.admin-editor-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.admin-fragment-editor { display: grid; gap: 16px; }
.admin-fragment-editor fieldset { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 0; padding: 18px; border: 1px solid var(--line); border-radius: 7px; }
.admin-fragment-editor legend { padding: 0 7px; color: var(--navy); font-size: 12px; font-weight: 700; }
.admin-fragment-editor label { display: grid; gap: 6px; }
.admin-fragment-editor .admin-checkbox { grid-column: 1 / -1; display: flex; }
.admin-checkbox { display: flex; align-items: flex-start; gap: 8px; color: var(--ink); font-size: 13px; line-height: 1.4; }
.admin-checkbox input { flex: 0 0 auto; width: 17px; height: 17px; margin: 1px 0 0; accent-color: var(--navy); }
.admin-checkbox-group { display: grid; gap: 10px; margin: 20px 0; padding: 16px; border: 1px solid var(--line); border-radius: 7px; }
.admin-checkbox-group legend { padding-inline: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.admin-sticky-actions { position: sticky; z-index: 4; bottom: 12px; display: flex; justify-content: flex-end; align-items: center; gap: 18px; margin: 18px 0 30px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; background: rgba(255, 255, 255, .96); box-shadow: 0 10px 32px rgba(10, 21, 72, .12); backdrop-filter: blur(8px); }
.admin-sticky-actions > a { color: var(--navy); font-size: 13px; font-weight: 700; }
.admin-editor-aside { position: sticky; top: 20px; }
.admin-editor-aside .admin-card { margin-top: 0; }
.admin-editor-aside .admin-card > p:not(.eyebrow) { color: var(--muted); line-height: 1.55; }
.admin-revision-list { display: grid; gap: 10px; margin: 14px 0 0; padding: 0; list-style: none; }
.admin-revision-list li { display: grid; gap: 3px; padding-top: 10px; border-top: 1px solid var(--line); }
.admin-revision-list a { display: grid; gap: 3px; color: inherit; text-decoration: none; }
.admin-revision-list a:hover strong { color: var(--orange); }
.admin-revision-list strong { overflow-wrap: anywhere; font-size: .9rem; line-height: 1.35; }
.admin-revision-list span { color: var(--muted); font-size: .78rem; line-height: 1.45; }
.admin-revision-diff { display: grid; gap: 22px; margin-top: 24px; }
.admin-revision-diff-row { padding-top: 20px; border-top: 1px solid var(--line); }
.admin-revision-diff-row h3 { margin: 0 0 12px; font-size: 18px; }
.admin-revision-diff-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.admin-revision-diff-columns > div { min-width: 0; padding: 14px; border-radius: 7px; background: var(--paper); }
.admin-revision-diff-columns strong { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .04em; }
.admin-revision-diff-columns pre { margin: 10px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--ink); font: inherit; font-size: 13px; line-height: 1.55; }
.admin-revision-snapshot > p:not(.eyebrow) { color: var(--muted); line-height: 1.65; }
.admin-revision-snapshot > section { margin-top: 28px; }
.admin-revision-snapshot h3 { margin-bottom: 10px; }
.admin-revision-fragments { display: grid; gap: 14px; padding-left: 22px; }
.admin-revision-fragments li { padding: 14px; border: 1px solid var(--line); border-radius: 7px; }
.admin-revision-fragments li > span { margin-left: 8px; color: var(--muted); font-size: 11px; }
.admin-revision-fragments p { margin: 9px 0; line-height: 1.55; }
.admin-revision-fragments small { display: block; color: var(--muted); line-height: 1.5; }
.admin-restore-bar { position: sticky; z-index: 4; bottom: 12px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 16px 18px; border: 1px solid var(--line); border-radius: 8px; background: rgba(255, 255, 255, .97); box-shadow: 0 10px 32px rgba(10, 21, 72, .12); }
.admin-restore-bar p { display: grid; gap: 3px; margin: 0; }
.admin-restore-bar span { color: var(--muted); font-size: 12px; }
.admin-facts { display: grid; gap: 0; margin: 20px 0; }
.admin-facts div { display: grid; grid-template-columns: minmax(110px, 1fr) minmax(0, 1.3fr); gap: 14px; padding: 10px 0; border-top: 1px solid var(--line); }
.admin-facts dt { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .035em; }
.admin-facts dd { margin: 0; overflow-wrap: anywhere; font-size: 13px; font-weight: 600; }
.admin-facts-horizontal { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.admin-facts-horizontal div { display: block; border-top: 0; }
.admin-facts-horizontal dd { margin-top: 7px; }
.admin-settings-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(280px, .55fr); gap: 24px; align-items: start; }
.admin-settings-layout > .admin-card { margin-top: 0; }
.admin-keyword-list { display: grid; gap: 10px; margin-top: 20px; }
.admin-keyword-list div { padding: 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--paper); }
.admin-keyword-list strong { display: block; color: var(--navy); }
.admin-keyword-list span { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.4; }
.admin-technical-terms { display: grid; gap: 7px; margin: 16px 0 22px; padding: 0; list-style: none; }
.admin-technical-terms li { display: grid; gap: 3px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--paper); }
.admin-technical-terms strong { color: var(--navy); font-size: 13px; }
.admin-technical-terms span { color: var(--muted); font-size: 11px; }
.admin-source-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.admin-source-grid .admin-card { margin: 0; }
.admin-source-card > p { min-height: 48px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.admin-source-last-run { margin-top: 18px; padding: 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); }
.admin-source-last-run .admin-card-head { align-items: center; }
.admin-source-last-run .admin-card-head strong { font-size: 13px; }
.admin-source-last-run > p { margin: 10px 0 0; min-height: 0; color: var(--muted); font-size: 12px; }
.admin-source-last-run .admin-facts { margin-bottom: 0; }
.admin-source-settings { display: grid; gap: 12px; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }
.admin-source-settings .button { justify-self: start; }
.admin-source-create { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: end; }
.admin-source-create label:not(.admin-checkbox) { display: grid; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.admin-source-create .button { justify-self: start; }
.admin-run-toolbar { display: flex; justify-content: space-between; align-items: end; gap: 20px; padding: 20px 24px; }
.admin-run-toolbar .admin-filter-form { flex: 1; grid-template-columns: repeat(2, minmax(150px, 220px)) auto auto; }
.admin-run-toolbar .admin-filter-form > a { align-self: center; color: var(--navy); font-size: 13px; font-weight: 700; }
.admin-run-toolbar button:disabled { cursor: not-allowed; opacity: .5; }
.admin-run-list { border-top: 1px solid var(--line); }
.admin-run { border-bottom: 1px solid var(--line); }
.admin-run > summary { display: grid; grid-template-columns: minmax(180px, .8fr) minmax(240px, 1fr) auto; gap: 20px; align-items: center; padding: 18px 4px; cursor: pointer; list-style: none; }
.admin-run > summary::-webkit-details-marker { display: none; }
.admin-run > summary > span:first-child { display: grid; gap: 5px; }
.admin-run > summary small { color: var(--muted); font-size: 11px; }
.admin-run-counts { color: var(--muted); font-size: 12px; }
.admin-run-counts b { color: var(--navy); }
.admin-run-body { padding: 4px 4px 24px; }
.admin-log { display: grid; gap: 8px; margin: 18px 0 0; padding: 0; list-style: none; }
.admin-log li { display: grid; grid-template-columns: 150px minmax(100px, .35fr) 100px minmax(0, 1fr); gap: 12px; padding: 10px 12px; border-left: 3px solid #a5adba; background: var(--paper); font-size: 12px; }
.admin-log li.admin-log-error { border-left-color: #b42318; background: #fff0ef; }
.admin-log li.admin-log-published,
.admin-log li.admin-log-success { border-left-color: #16803d; background: #effaf3; }
.admin-log time,
.admin-log li > span { color: var(--muted); }
.admin-log p { margin: 0; overflow-wrap: anywhere; line-height: 1.4; }
.status-running,
.status-processing { color: #1d4ed8; background: #eaf1ff; }
.status-completed { color: #166534; background: #eaf8ef; }
.status-trashed,
.status-purging { color: #8a1c13; background: #ffebe9; }
.status-valid { color: #166534; background: #eaf8ef; }
.admin-ingest summary { display: flex; justify-content: space-between; align-items: center; gap: 20px; cursor: pointer; list-style: none; }
.admin-ingest summary::-webkit-details-marker { display: none; }
.admin-ingest summary > span:first-child { display: grid; gap: 5px; }
.admin-ingest summary small { color: var(--muted); font-size: 12px; font-weight: 400; }
.admin-ingest[open] summary { margin-bottom: 22px; }
.admin-video-filters { display: grid; grid-template-columns: repeat(5, minmax(135px, 1fr)); gap: 14px; align-items: end; }
.admin-video-filters label { display: grid; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.admin-video-filters .admin-field-wide { grid-column: span 2; }
.admin-bulk-form { padding: 0; overflow: hidden; }
.admin-bulk-toolbar { display: grid; grid-template-columns: auto minmax(190px, .5fr) minmax(240px, 1fr) auto; gap: 14px; align-items: end; padding: 18px 22px; border-bottom: 1px solid var(--line); background: var(--paper); }
.admin-bulk-toolbar > label:not(.admin-checkbox) { display: grid; gap: 6px; color: var(--muted); font-size: 12px; font-weight: 700; }
.admin-video-table { margin: 0; }
.admin-video-table td { vertical-align: middle; }
.admin-video-table td:first-child { width: 34px; }
.admin-video-table td:nth-child(2) { min-width: 420px; }
.admin-video-table td small { display: block; margin-top: 5px; color: var(--muted); line-height: 1.4; }
.admin-video-title { display: grid; grid-template-columns: 120px minmax(260px, 1fr); gap: 14px; align-items: start; }
.admin-video-title img { width: 120px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 6px; background: var(--paper); }
.admin-video-title strong { display: block; color: var(--navy); line-height: 1.35; }
.admin-video-title small { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.admin-editor-tabs { position: sticky; z-index: 5; top: 0; display: flex; gap: 8px; margin: -10px 0 22px; padding: 10px 0; overflow-x: auto; background: var(--paper); }
.admin-editor-tabs a { flex: 0 0 auto; padding: 9px 13px; border-radius: 999px; background: var(--white); color: var(--navy); font-size: 12px; font-weight: 700; text-decoration: none; }
.admin-poster-preview { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; margin: 12px 0 16px; border-radius: 7px; background: var(--paper); }
.admin-editor-aside form { display: grid; gap: 12px; }
.admin-editor-aside label { display: grid; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.admin-danger-zone { border-color: #efb7b1; }
.admin-danger-zone hr { width: 100%; margin: 22px 0; border: 0; border-top: 1px solid #efb7b1; }

@media (max-width: 1050px) {
  .admin-editor-layout { grid-template-columns: 1fr; }
  .admin-editor-aside { position: static; }
  .admin-source-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-run-toolbar { align-items: stretch; flex-direction: column; }
}

@media (max-width: 900px) {
  .admin-video-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-video-filters .admin-field-wide { grid-column: 1 / -1; }
  .admin-bulk-toolbar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .admin-workspace-head { min-height: 46px; }
  .admin-workspace-head h1 { font-size: 26px; }
  .admin-workspace-nav { margin-inline: -15px; padding-inline: 15px; border-right: 0; border-left: 0; border-radius: 0; }
  .admin-search-row,
  .admin-search-constraints,
  .admin-filter-form,
  .admin-run-toolbar .admin-filter-form,
  .admin-field-grid,
  .admin-editor-columns,
  .admin-settings-layout,
  .admin-source-grid,
  .admin-source-create,
  .admin-facts-horizontal { grid-template-columns: 1fr; }
  .admin-result-item { grid-template-columns: 1fr; }
  .admin-result-actions { align-items: flex-start; }
  .admin-content-table td:first-child { min-width: 250px; }
  .admin-fragment-editor fieldset { grid-template-columns: 1fr; padding: 14px; }
  .admin-fragment-editor .admin-checkbox { grid-column: 1; }
  .admin-sticky-actions { flex-wrap: wrap; justify-content: flex-start; }
  .admin-sticky-actions .button { width: 100%; }
  .preview-banner { display: grid; }
  .admin-revision-diff-columns { grid-template-columns: 1fr; }
  .admin-restore-bar { align-items: stretch; flex-direction: column; }
  .admin-restore-bar .button { width: 100%; }
  .admin-run > summary { grid-template-columns: 1fr auto; gap: 10px; }
  .admin-run-counts { grid-column: 1 / -1; grid-row: 2; }
  .admin-log li { grid-template-columns: 1fr 1fr; }
  .admin-log p { grid-column: 1 / -1; }
  .admin-video-filters,
  .admin-bulk-toolbar { grid-template-columns: 1fr; }
  .admin-video-filters .admin-field-wide { grid-column: 1; }
  .admin-video-table td:nth-child(2) { min-width: 300px; }
  .admin-video-title { grid-template-columns: 88px minmax(210px, 1fr); }
  .admin-video-title img { width: 88px; }
  .admin-workspace .button-small { min-height: 44px; }
}

/* E13: two clear publication rubrics without duplicating article URLs. */
.rubric-switcher { display: flex; gap: 8px; align-items: center; padding-top: 24px; overflow-x: auto; }
.rubric-switcher a { flex: 0 0 auto; padding: 10px 15px; border: 1px solid var(--line); border-radius: 999px; background: var(--white); color: var(--navy); font-size: 13px; font-weight: 700; text-decoration: none; }
.rubric-switcher a:hover, .rubric-switcher a.is-active { border-color: var(--yellow); background: var(--yellow); }
.rubric-switcher-listing { width: 100%; padding: 0 0 24px; }
.rubric-home-block { padding-top: 64px; padding-bottom: 64px; }
.rubric-home-block + .rubric-home-block { border-top: 1px solid var(--line); }
.section-heading > a { flex: 0 0 auto; color: var(--navy); font-size: 14px; font-weight: 800; text-decoration-color: var(--yellow); text-decoration-thickness: 3px; text-underline-offset: 5px; }
.search-bar-with-filter { max-width: 920px; }
.search-bar-with-filter select { min-width: 190px; border: 0; border-left: 1px solid var(--line); background: var(--white); padding: 0 14px; color: var(--navy); font: inherit; }

@media (max-width: 720px) {
  .rubric-switcher { width: calc(100% - 30px); }
  .rubric-switcher-listing { width: 100%; }
  .rubric-home-block { padding-top: 48px; padding-bottom: 48px; }
  .section-heading > a { display: inline-block; margin-top: 14px; }
  .search-bar-with-filter select { min-height: 48px; border-top: 1px solid var(--line); border-left: 0; }
}

/* E14: minimal publication homepage. */
.kodos-banner.shell { width: min(1168px, calc(100% - 40px)); }
.hero-minimal { padding: 24px 0 28px; }
.hero-minimal .hero-minimal__inner {
  display: block;
  padding: 30px 44px 32px;
  background: var(--navy);
}
.hero-brand-label {
  margin: 0 0 18px;
  color: var(--yellow);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.hero-meta-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  margin-top: 20px;
}
.hero-project-status {
  margin: 0 0 0 auto;
  color: #d9e1f2;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-align: right;
  text-transform: uppercase;
}
.hero-minimal h1 {
  max-width: 1080px;
  margin: 0;
  font-size: clamp(34px, 3.8vw, 52px);
  line-height: 1.06;
  overflow-wrap: anywhere;
}
.hero-title__line { display: block; }
.hero-minimal .search-bar {
  max-width: 600px;
  margin-top: 24px;
}
.hero-minimal .search-bar input { padding: 10px 14px; font-size: 15px; }
.hero-minimal .search-bar button { padding: 10px 20px; }
.hero-article-count {
  margin: 0;
  color: var(--white);
  font-size: clamp(22px, 2.5vw, 30px);
  font-weight: 800;
  line-height: 1.2;
}
.rubric-home-block { padding-top: 52px; padding-bottom: 52px; }
.rubric-home-block + .rubric-home-block { border-top: 1px solid var(--line); }
.rubric-home-heading { display: block; margin-bottom: 24px; }
.rubric-home-heading h2 { max-width: 900px; }
.rubric-home-actions { display: flex; justify-content: flex-start; margin-top: 28px; }
.rubric-home-button { display: inline-flex; align-items: center; justify-content: center; max-width: 100%; padding: 12px 18px; }

@media (max-width: 720px) {
  .hero-minimal { padding: 16px 0 20px; }
  .hero-minimal .hero-minimal__inner { padding: 20px 18px 22px; }
  .hero-brand-label { margin-bottom: 12px; font-size: 11px; }
  .hero-minimal h1 { font-size: clamp(28px, 7.8vw, 32px); line-height: 1.04; }
  .hero-minimal .search-bar { margin-top: 16px; }
  .hero-meta-row { gap: 14px; margin-top: 14px; }
  .hero-article-count { font-size: 21px; }
  .hero-project-status { max-width: 150px; font-size: 9px; line-height: 1.35; }
  .rubric-home-block { padding-top: 42px; padding-bottom: 42px; }
  .rubric-home-actions { margin-top: 22px; }
  .rubric-home-button { width: 100%; text-align: center; }
}

/* E15: compact directory for six independent publication rubrics. */
.rubric-directory { padding: 48px 0 52px; }
.rubric-directory__heading { margin-bottom: 22px; }
.rubric-directory__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.rubric-directory__card {
  display: flex;
  min-height: 128px;
  flex-direction: column;
  justify-content: space-between;
  gap: 22px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--white);
  color: var(--navy);
  text-decoration: none;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.rubric-directory__card:hover,
.rubric-directory__card:focus-visible {
  border-color: var(--yellow);
  box-shadow: 0 12px 28px rgba(10, 25, 79, .08);
  transform: translateY(-2px);
}
.rubric-directory__card strong { font-size: 20px; line-height: 1.18; }
.rubric-directory__card span { color: var(--orange); font-size: 13px; font-weight: 800; }
.fresh-feed { padding-top: 52px; }
.discipline-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: -20px 0 28px;
}
.discipline-filter a {
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  color: var(--navy);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}
.discipline-filter a:hover,
.discipline-filter a.is-active {
  border-color: var(--yellow);
  background: var(--yellow);
}

@media (max-width: 960px) {
  .rubric-directory__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 620px) {
  .rubric-directory { padding: 38px 0 42px; }
  .rubric-directory__grid { grid-template-columns: 1fr; gap: 10px; }
  .rubric-directory__card { min-height: 104px; padding: 18px; }
  .rubric-directory__card strong { font-size: 18px; }
  .rubric-switcher-listing { gap: 6px; }
  .rubric-switcher-listing a { padding: 8px 12px; }
}

.article-formats { display: flex; flex-wrap: wrap; gap: 24px; margin-top: 20px; margin-bottom: 24px; border-bottom: 1px solid var(--line); }
.article-formats a { display: inline-flex; align-items: center; min-height: 44px; padding: 10px 0; border-bottom: 3px solid transparent; color: #334155; font-size: 16px; font-weight: 600; text-decoration: none; }
.article-formats a:hover { color: #01103e; border-bottom-color: #cbd5e1; }
.article-formats a[aria-current] { color: #01103e; border-bottom-color: var(--yellow); }
.article-formats a:focus-visible { outline: 2px solid #01103e; outline-offset: 4px; }
