/*
 * Blog pages (post, class hub, listing). Sits on top of the Sandbox theme and its
 * yellow colour file; uses the theme's variables so it follows the site palette.
 * Not purged: this file is only loaded by templates/blog/*.
 */

:root {
  --lk-ink: #273142;          /* body text: darker than the theme grey, for long Bangla reading */
  --lk-muted: #6b7686;
  --lk-line: #e7eaf0;
  --lk-soft: #f7f8fb;
  --lk-accent: var(--bs-primary, #fab758);
  --lk-accent-ink: #9a5b00;   /* readable text on white in the accent's family */
  --lk-accent-soft: rgba(250, 183, 88, .12);
  --lk-radius: .8rem;
}

/* ---- Type --------------------------------------------------------------- */

.lk-blog, .lk-blog p, .lk-blog li, .lk-blog td, .lk-blog th, .lk-blog summary {
  font-family: 'Noto Sans Bengali', 'Hind Siliguri', 'Inter', sans-serif;
}
.lk-blog h1, .lk-blog h2, .lk-blog h3, .lk-blog h4, .lk-blog .btn, .lk-blog .nav-link {
  font-family: 'Hind Siliguri', 'Noto Sans Bengali', sans-serif;
}
.lk-article { color: var(--lk-ink); font-size: .86rem; line-height: 1.8; }   /* ~17px; the theme's root is 20px */
.lk-article p { margin-bottom: 1.1rem; }
.lk-article h2 {
  font-size: 1.2rem; font-weight: 700; margin: 2.2rem 0 .9rem; padding-top: .3rem;
  scroll-margin-top: 90px;
}
.lk-article h2::after {
  content: ''; display: block; width: 56px; height: 3px; margin-top: .55rem;
  background: var(--lk-accent); border-radius: 3px;
}
.lk-article h3 { font-size: 1rem; font-weight: 700; }
.lk-article ul li, .lk-article ol li { margin-bottom: .35rem; }
.lk-article a { color: var(--lk-accent-ink); text-decoration: underline; text-underline-offset: 3px; }
.lk-article img { max-width: 100%; height: auto; border-radius: .5rem; }

/* Sandbox sizes .btn-sm for Latin text; Bangla at that size is hard to read. */
.lk-blog .btn { font-size: .8rem; font-weight: 600; letter-spacing: 0; }
.lk-blog .btn-sm { font-size: .75rem; padding: .4rem .9rem; }

/* ---- Hero ---------------------------------------------------------------- */

.lk-hero { background: linear-gradient(180deg, #fff8ec 0%, #fffdf8 100%); border-bottom: 1px solid var(--lk-line); }
.lk-hero .breadcrumb { font-size: .75rem; margin-bottom: .8rem; }
.lk-hero .breadcrumb a { color: var(--lk-muted); }
.lk-chip {
  display: inline-flex; align-items: center; gap: .35rem; padding: .28rem .75rem;
  border-radius: 999px; font-size: .7rem; font-weight: 600; line-height: 1.3;
  background: #fff; border: 1px solid var(--lk-line); color: var(--lk-ink);
}
.lk-chip--accent { background: var(--lk-accent-soft); border-color: transparent; color: var(--lk-accent-ink); }
.lk-hero h1 { font-size: clamp(1.3rem, 2.6vw, 1.95rem); line-height: 1.4; font-weight: 700; color: var(--lk-ink); }
.lk-hero .lk-subtitle { font-size: .9rem; color: var(--lk-muted); font-family: 'Inter', 'Hind Siliguri', sans-serif; }
.lk-meta { display: flex; flex-wrap: wrap; gap: .5rem 1.4rem; color: var(--lk-muted); font-size: .75rem; }
.lk-meta i { color: var(--lk-accent-ink); margin-right: .25rem; }
.lk-meta .lk-reviewed { color: #1d7a4c; font-weight: 600; }
.lk-meta .lk-reviewed i { color: #1d7a4c; }
.lk-cover {
  border-radius: 1rem; overflow: hidden; box-shadow: 0 18px 40px -18px rgba(39, 49, 66, .35);
  aspect-ratio: 16 / 9; background: var(--lk-soft);
}
.lk-cover img { width: 100%; height: 100%; object-fit: cover; object-position: left center; display: block; }

/* ---- Layout: article + sticky side panel ------------------------------------ */

.lk-body { padding: 3rem 0 4rem; }
.lk-side { position: sticky; top: 96px; }
.lk-panel {
  background: #fff; border: 1px solid var(--lk-line); border-radius: var(--lk-radius);
  padding: 1.2rem 1.25rem; margin-bottom: 1rem;
}
.lk-panel-title { font-size: .68rem; font-weight: 700; letter-spacing: .04em; color: var(--lk-muted); margin-bottom: .7rem; }
.lk-toc { list-style: none; padding: 0; margin: 0; }
.lk-toc li { margin: 0; }
.lk-toc a {
  display: block; padding: .38rem .6rem; border-radius: .45rem; color: var(--lk-ink);
  font-size: .78rem; line-height: 1.45; border-left: 2px solid transparent;
}
.lk-toc a:hover, .lk-toc a.is-current { background: var(--lk-soft); border-left-color: var(--lk-accent); }
.lk-qjump-label { font-size: .66rem; font-weight: 700; color: var(--lk-muted); margin: .9rem 0 .35rem; }
.lk-qjump { display: grid; grid-template-columns: repeat(6, 1fr); gap: .4rem; }
.lk-qjump a {
  display: flex; align-items: center; justify-content: center; height: 2.1rem; border-radius: .45rem;
  border: 1px solid var(--lk-line); font-weight: 600; font-size: .75rem; color: var(--lk-ink);
}
.lk-qjump a:hover { background: var(--lk-accent-soft); border-color: var(--lk-accent); }
.lk-cta { background: #273142; color: #fff; border: 0; }
.lk-cta .lk-panel-title { color: rgba(255, 255, 255, .6); }
.lk-cta p { color: rgba(255, 255, 255, .85); font-size: .8rem; }
.lk-mobile-toc { border: 1px solid var(--lk-line); border-radius: var(--lk-radius); margin-bottom: 1.5rem; background: #fff; }
.lk-mobile-toc summary { padding: .8rem 1rem; font-weight: 700; cursor: pointer; }
.lk-mobile-toc .lk-toc { padding: 0 .6rem .8rem; }

/* ---- Question cards (rendered by apps/blog/content.py) ---------------------- */

/* Several full sets on one page, as tabs. */
.lk-sets { scroll-margin-top: 90px; }
.lk-set-tabs {
  display: flex; gap: .4rem; flex-wrap: wrap; padding: .35rem; margin: 0 0 1.4rem;
  background: var(--lk-soft); border: 1px solid var(--lk-line); border-radius: 999px; width: fit-content; max-width: 100%;
}
.lk-article .lk-set-tab {
  padding: .4rem 1.1rem; font-size: .8rem; border-radius: 999px; font-weight: 700; color: var(--lk-ink);
  text-decoration: none; font-family: 'Hind Siliguri', sans-serif;
}
.lk-article .lk-set-tab:hover { background: #fff; }
.lk-article .lk-set-tab.is-active { background: #273142; color: #fff; }
.lk-sets.js-tabs .lk-set:not(.is-active) { display: none; }
.lk-set { scroll-margin-top: 90px; }
.lk-qjump a[hidden] { display: none; }

/* Written-paper questions (Bangla 2nd paper, English): marks at the right of the title. */
.q-card.written { position: relative; }
.q-card.written .q-total {
  position: absolute; top: 1.3rem; right: 1.4rem; min-width: 1.6rem; height: 1.6rem; padding: 0 .45rem;
  border-radius: 999px; display: inline-flex; align-items: center; justify-content: center;
  font-size: .7rem; font-weight: 700; background: #273142; color: #fff;
}
.q-card.written .q-body > :last-child { margin-bottom: 0; }
/* Paper sections ("ক-বিভাগ: গদ্য") between questions. */
.lk-set > h4, .lk-article > h4 {
  text-align: center; font-size: .9rem; font-weight: 700; margin: 1.4rem 0 .9rem; color: var(--lk-accent-ink);
}

/* The paper header: how the set looks at the top of a printed board paper. */
.paper-head {
  text-align: center; border: 1px solid var(--lk-line); border-top: 4px solid var(--lk-accent);
  border-radius: var(--lk-radius); padding: 1.4rem 1.2rem 1rem; margin: 0 0 1.6rem; background: #fff;
}
.paper-title { font-family: 'Hind Siliguri', sans-serif; font-size: 1.1rem; font-weight: 700; color: var(--lk-ink); }
.paper-part { font-weight: 600; color: var(--lk-accent-ink); margin-top: .15rem; }
.paper-meta {
  display: flex; justify-content: space-between; gap: 1rem; margin: 1rem 0 .6rem; padding: .5rem 0;
  border-top: 1px dashed var(--lk-line); border-bottom: 1px dashed var(--lk-line); font-weight: 600;
}
.lk-article .paper-instr { font-size: .78rem; color: var(--lk-muted); margin: 0; }
/* The passage two MCQs share: plain text under the board's instruction line. */
.mcq-shared { margin: .4rem 0 .9rem; }
.lk-article .mcq-shared-label { color: var(--lk-accent-ink); font-weight: 700; margin-bottom: .35rem; }

.q-card {
  background: #fff; border: 1px solid var(--lk-line); border-radius: var(--lk-radius);
  padding: 1.4rem 1.5rem 1.1rem; margin: 0 0 1.4rem; scroll-margin-top: 90px;
  box-shadow: 0 1px 2px rgba(39, 49, 66, .04);
}
.lk-article .q-card .q-title {
  display: inline-block; font-size: .78rem; font-weight: 700; margin: 0 0 .8rem;
  padding: .25rem .8rem; border-radius: 999px; background: var(--lk-accent-soft); color: var(--lk-accent-ink);
}
.q-stimulus { margin-bottom: .6rem; }   /* plain text above the parts, like a printed paper */
.q-stimulus-label { font-size: .8rem; font-weight: 700; color: var(--lk-muted); margin-bottom: .35rem; }
.q-parts { list-style: none; padding: 0; margin: 0 0 .8rem; }
.lk-article .q-parts li {
  display: grid; grid-template-columns: 1.8rem 1fr auto; gap: .5rem; align-items: start;
  padding: .55rem 0; border-bottom: 1px dashed var(--lk-line); margin: 0;
}
.q-parts li:last-child { border-bottom: 0; }
.q-label { font-weight: 700; color: var(--lk-accent-ink); }
.q-marks {
  min-width: 1.45rem; height: 1.45rem; border-radius: 50%; display: inline-flex; align-items: center;
  justify-content: center; font-size: .68rem; font-weight: 700; background: #273142; color: #fff;
}
.q-answer { border-top: 1px solid var(--lk-line); margin-top: .4rem; padding-top: .6rem; }
.q-answer > summary {
  list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: .45rem;
  font-weight: 700; color: #1d7a4c; padding: .35rem .9rem; border-radius: 999px; background: #eaf7f0;
}
.q-answer > summary::-webkit-details-marker { display: none; }
.q-answer > summary::before { content: '+'; font-weight: 700; }
.q-answer[open] > summary::before { content: '\2212'; }
.q-answer[open] > summary { margin-bottom: .9rem; }
.q-answer p strong:first-child { color: var(--lk-accent-ink); }
.q-label .on-paper { display: none; }

.mcq-card {
  background: #fff; border: 1px solid var(--lk-line); border-radius: var(--lk-radius);
  padding: 1rem 1.2rem .6rem; margin-bottom: .9rem; scroll-margin-top: 90px;
}
.mcq-stem p { white-space: pre-line; margin-bottom: .6rem; }
.mcq-num {
  display: inline-flex; align-items: center; justify-content: center; min-width: 1.55rem; height: 1.55rem;
  border-radius: .4rem; margin-right: .45rem; font-weight: 700; font-size: .74rem;
  background: var(--lk-accent-soft); color: var(--lk-accent-ink);
}
.mcq-options { list-style: none; padding: 0; margin: 0 0 .4rem; display: grid; grid-template-columns: 1fr 1fr; gap: .45rem .9rem; }
.lk-article .mcq-options li {
  margin: 0; padding: .45rem .7rem; border: 1px solid var(--lk-line); border-radius: .5rem; background: var(--lk-soft);
}
.mcq-letter { font-weight: 700; color: var(--lk-accent-ink); margin-right: .35rem; }
.mcq-options.wide { grid-template-columns: 1fr; }             /* long options: one per row */
.lk-article .mcq-options code { white-space: nowrap; font-size: .85em; }   /* never break inside a tag */
.mcq-letter::before { content: '('; } .mcq-letter::after { content: ')'; }

.lk-article .table-container { overflow-x: auto; margin: 0 0 1.4rem; border-radius: .6rem; border: 1px solid var(--lk-line); }
.lk-article .table { margin: 0; font-size: .8rem; }
.lk-article .table thead th { background: var(--lk-soft); font-weight: 700; border-bottom: 1px solid var(--lk-line); }
.lk-article .table td, .lk-article .table th { padding: .5rem .75rem; border-color: var(--lk-line); }
.lk-article > .table-container .table td:last-child { white-space: nowrap; }   /* "১ থেকে ৫" in the syllabus table */

/* Tables inside a question (truth tables, data tables): as wide as their content,
   like a printed paper, not stretched across the card. */
.lk-article .q-card .table-container, .lk-article .mcq-card .table-container, .lk-article .mcq-shared .table-container {
  display: inline-block; max-width: 100%; margin: .2rem 0 1rem;
}
.lk-article .q-card .table, .lk-article .mcq-card .table, .lk-article .mcq-shared .table { width: auto; font-size: .78rem; }
.lk-article .q-card .table td, .lk-article .q-card .table th,
.lk-article .mcq-card .table td, .lk-article .mcq-card .table th,
.lk-article .mcq-shared .table td, .lk-article .mcq-shared .table th {
  padding: .3rem .9rem; text-align: center; line-height: 1.5;
}

/* Older posts keep their questions inside <pre>; make that readable too. */
.lk-article pre, .lk-article .markdown-rendered {
  background: var(--lk-soft); border: 1px solid var(--lk-line); border-radius: var(--lk-radius);
  padding: 1.2rem 1.4rem; white-space: pre-wrap;
}

/* Code in questions (C, HTML, SQL): light, like a printed page, with Pygments highlighting
   (apps/blog/content.py renders fenced code with the codehilite extension). */
.lk-article pre, .lk-article .codehilite pre {
  background: #f6f8fa; color: #24292f; border: 1px solid var(--lk-line); border-radius: .6rem;
  padding: .8rem 1rem; font-size: .74rem; line-height: 1.6; white-space: pre; overflow-x: auto; margin: .6rem 0 1rem;
}
.lk-article .codehilite { background: none; margin: 0; }
.lk-article pre code { background: none; color: inherit; font-size: inherit; padding: 0; }
.lk-article :not(pre) > code {
  font-size: .9em; color: #b4235a; background: #f3f4f8; padding: .1em .4em; border-radius: .3em;
}
.lk-article pre:has(> code.language-plaintext) { white-space: pre-wrap; background: var(--lk-soft); }
.lk-article pre > code.language-plaintext { color: var(--lk-ink); font-family: inherit; font-size: .86rem; }
.lk-article .codehilite .c { color: #3D7B7B; font-style: italic } /* Comment */
.lk-article .codehilite .err { border: 1px solid #F00 } /* Error */
.lk-article .codehilite .k { color: #008000; font-weight: bold } /* Keyword */
.lk-article .codehilite .o { color: #666 } /* Operator */
.lk-article .codehilite .ch { color: #3D7B7B; font-style: italic } /* Comment.Hashbang */
.lk-article .codehilite .cm { color: #3D7B7B; font-style: italic } /* Comment.Multiline */
.lk-article .codehilite .cp { color: #9C6500 } /* Comment.Preproc */
.lk-article .codehilite .cpf { color: #3D7B7B; font-style: italic } /* Comment.PreprocFile */
.lk-article .codehilite .c1 { color: #3D7B7B; font-style: italic } /* Comment.Single */
.lk-article .codehilite .cs { color: #3D7B7B; font-style: italic } /* Comment.Special */
.lk-article .codehilite .gd { color: #A00000 } /* Generic.Deleted */
.lk-article .codehilite .ge { font-style: italic } /* Generic.Emph */
.lk-article .codehilite .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */
.lk-article .codehilite .gr { color: #E40000 } /* Generic.Error */
.lk-article .codehilite .gh { color: #000080; font-weight: bold } /* Generic.Heading */
.lk-article .codehilite .gi { color: #008400 } /* Generic.Inserted */
.lk-article .codehilite .go { color: #717171 } /* Generic.Output */
.lk-article .codehilite .gp { color: #000080; font-weight: bold } /* Generic.Prompt */
.lk-article .codehilite .gs { font-weight: bold } /* Generic.Strong */
.lk-article .codehilite .gu { color: #800080; font-weight: bold } /* Generic.Subheading */
.lk-article .codehilite .gt { color: #04D } /* Generic.Traceback */
.lk-article .codehilite .kc { color: #008000; font-weight: bold } /* Keyword.Constant */
.lk-article .codehilite .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */
.lk-article .codehilite .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */
.lk-article .codehilite .kp { color: #008000 } /* Keyword.Pseudo */
.lk-article .codehilite .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */
.lk-article .codehilite .kt { color: #B00040 } /* Keyword.Type */
.lk-article .codehilite .m { color: #666 } /* Literal.Number */
.lk-article .codehilite .s { color: #BA2121 } /* Literal.String */
.lk-article .codehilite .na { color: #687822 } /* Name.Attribute */
.lk-article .codehilite .nb { color: #008000 } /* Name.Builtin */
.lk-article .codehilite .nc { color: #00F; font-weight: bold } /* Name.Class */
.lk-article .codehilite .no { color: #800 } /* Name.Constant */
.lk-article .codehilite .nd { color: #A2F } /* Name.Decorator */
.lk-article .codehilite .ni { color: #717171; font-weight: bold } /* Name.Entity */
.lk-article .codehilite .ne { color: #CB3F38; font-weight: bold } /* Name.Exception */
.lk-article .codehilite .nf { color: #00F } /* Name.Function */
.lk-article .codehilite .nl { color: #767600 } /* Name.Label */
.lk-article .codehilite .nn { color: #00F; font-weight: bold } /* Name.Namespace */
.lk-article .codehilite .nt { color: #008000; font-weight: bold } /* Name.Tag */
.lk-article .codehilite .nv { color: #19177C } /* Name.Variable */
.lk-article .codehilite .ow { color: #A2F; font-weight: bold } /* Operator.Word */
.lk-article .codehilite .w { color: #BBB } /* Text.Whitespace */
.lk-article .codehilite .mb { color: #666 } /* Literal.Number.Bin */
.lk-article .codehilite .mf { color: #666 } /* Literal.Number.Float */
.lk-article .codehilite .mh { color: #666 } /* Literal.Number.Hex */
.lk-article .codehilite .mi { color: #666 } /* Literal.Number.Integer */
.lk-article .codehilite .mo { color: #666 } /* Literal.Number.Oct */
.lk-article .codehilite .sa { color: #BA2121 } /* Literal.String.Affix */
.lk-article .codehilite .sb { color: #BA2121 } /* Literal.String.Backtick */
.lk-article .codehilite .sc { color: #BA2121 } /* Literal.String.Char */
.lk-article .codehilite .dl { color: #BA2121 } /* Literal.String.Delimiter */
.lk-article .codehilite .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */
.lk-article .codehilite .s2 { color: #BA2121 } /* Literal.String.Double */
.lk-article .codehilite .se { color: #AA5D1F; font-weight: bold } /* Literal.String.Escape */
.lk-article .codehilite .sh { color: #BA2121 } /* Literal.String.Heredoc */
.lk-article .codehilite .si { color: #A45A77; font-weight: bold } /* Literal.String.Interpol */
.lk-article .codehilite .sx { color: #008000 } /* Literal.String.Other */
.lk-article .codehilite .sr { color: #A45A77 } /* Literal.String.Regex */
.lk-article .codehilite .s1 { color: #BA2121 } /* Literal.String.Single */
.lk-article .codehilite .ss { color: #19177C } /* Literal.String.Symbol */
.lk-article .codehilite .bp { color: #008000 } /* Name.Builtin.Pseudo */
.lk-article .codehilite .fm { color: #00F } /* Name.Function.Magic */
.lk-article .codehilite .vc { color: #19177C } /* Name.Variable.Class */
.lk-article .codehilite .vg { color: #19177C } /* Name.Variable.Global */
.lk-article .codehilite .vi { color: #19177C } /* Name.Variable.Instance */
.lk-article .codehilite .vm { color: #19177C } /* Name.Variable.Magic */
.lk-article .codehilite .il { color: #666 } /* Literal.Number.Integer.Long */

/* ---- After the article ------------------------------------------------------ */

.lk-sibling {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  background: var(--lk-accent-soft); border-radius: var(--lk-radius); padding: 1.1rem 1.3rem; margin: 2rem 0;
  color: var(--lk-ink); text-decoration: none !important;
}
.lk-sibling small { display: block; color: var(--lk-muted); }
.lk-sibling strong { font-size: .88rem; }
.lk-reviewer { display: flex; gap: 1rem; align-items: center; border: 1px solid var(--lk-line); border-radius: var(--lk-radius); padding: 1rem 1.2rem; }
.lk-reviewer .lk-badge {
  width: 2.8rem; height: 2.8rem; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: #eaf7f0; color: #1d7a4c; font-size: 1.1rem; flex: none;
}
.lk-related-card {
  display: block; height: 100%; border: 1px solid var(--lk-line); border-radius: var(--lk-radius);
  overflow: hidden; background: #fff; color: var(--lk-ink); transition: transform .15s, box-shadow .15s;
}
.lk-related-card:hover { transform: translateY(-2px); box-shadow: 0 12px 28px -16px rgba(39, 49, 66, .35); }
.lk-related-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: left center; }
.lk-related-card .p { padding: .9rem 1rem 1rem; font-weight: 600; line-height: 1.5; }

/* Class page: one card per subject. */
.lk-subject-card {
  display: flex; flex-direction: column; border: 1px solid var(--lk-line); border-radius: var(--lk-radius);
  overflow: hidden; background: #fff; transition: box-shadow .15s, transform .15s;
}
.lk-subject-card:hover { box-shadow: 0 12px 28px -16px rgba(39, 49, 66, .35); transform: translateY(-2px); }
.lk-subject-card img { width: 100%; aspect-ratio: 16 / 7; object-fit: cover; object-position: left center; display: block; }

/* ---- Small screens ---------------------------------------------------------- */

@media (max-width: 991.98px) {
  .lk-side { position: static; }
  .lk-body { padding-top: 1.8rem; }
}
@media (max-width: 575.98px) {
  .lk-article { font-size: .8rem; line-height: 1.75; }   /* ~16px on phones */
  .lk-article h2 { font-size: 1.05rem; }
  .q-card { padding: 1.1rem 1rem .9rem; }
  /* Short options stay two per row on a phone, like a printed paper; long ones stack. */
  .mcq-options { grid-template-columns: 1fr 1fr; gap: .4rem; }
  .mcq-options.long, .mcq-options.wide { grid-template-columns: 1fr; }
  .mcq-card { padding: .8rem .8rem .5rem; }
  .lk-article .mcq-options li { padding: .4rem .6rem; }
  .lk-qjump { grid-template-columns: repeat(5, 1fr); }
}

/* ---- Print ("PDF / প্রিন্ট"): the open set as a board question paper --------------- */
/*
 * Only the question paper prints: the paper header and the questions of the set
 * that is open (inactive tabs are already display:none). Everything else on the
 * page -- site header, hero, introduction, syllabus table, tips, side panel,
 * comments -- is hidden. CQs print like a board paper (numbered, stimulus as a
 * paragraph, (ক)-(ঘ) with marks at the right); MCQs print in two columns, with
 * the answer key on its own page for the teacher.
 */
@media print {
  @page { size: A4; margin: 13mm 14mm; }
  html, body { background: #fff !important; }
  body.lk-blog { font-size: 11.5pt; color: #000; }

  header, footer, nav, .navbar, .progress-wrap, .lk-hero, aside, .lk-side, .lk-after,
  .lk-mobile-toc, .d-print-none, #comments, .lk-set-tabs, .content-wrapper > section:not(.lk-body) { display: none !important; }
  .lk-body, .lk-body .container, .lk-body .row, .lk-body .col-lg-8 {
    padding: 0 !important; margin: 0 !important; max-width: 100% !important; width: 100% !important; flex: 0 0 100% !important;
  }

  /* Only the paper: drop introduction, syllabus table, headings and tips around it. */
  .lk-article > :not(.lk-sets):not(.paper-head):not(.q-card):not(.mcq-card):not(.mcq-shared):not(.answer-key):not([id^="answer-key"]) {
    display: none !important;
  }
  .lk-article, .lk-article p, .lk-article li, .lk-article td { color: #000 !important; font-size: 11.5pt; line-height: 1.55; }
  .lk-article p { margin: 0 0 1.2mm; text-align: justify; }
  a { color: inherit !important; text-decoration: none !important; }

  /* Paper header, like the top of a board paper. */
  .paper-head { border: 0 !important; border-radius: 0; padding: 0 0 2mm; margin: 0 0 4mm; text-align: center; background: none; }
  .paper-title { font-size: 15pt; }
  .paper-part { color: #000 !important; font-size: 12pt; }
  .paper-meta { border-top: 0; border-bottom: 1px solid #000; margin: 2mm 0 1.5mm; padding: 0 0 1mm; font-size: 11pt; }
  .lk-article .paper-instr { color: #000 !important; font-size: 9.5pt; font-style: italic; border-bottom: 1px solid #000; padding-bottom: 1.5mm; }

  /* CQ: "১।" at the left, the stimulus as a paragraph, parts with marks at the right. */
  .lk-set, .lk-article { counter-reset: cq; }
  .q-card {
    border: 0 !important; box-shadow: none !important; border-radius: 0; background: none;
    padding: 0 0 0 8mm !important; margin: 0 0 4.5mm !important; position: relative;
    counter-increment: cq;
  }
  /* A long question may run onto the next page, but never splits its ক-ঘ parts or a table
     from its question, so no half-empty pages. */
  .q-parts, .q-card .table-container, .q-card pre { break-inside: avoid; }
  .q-stimulus { break-after: avoid; }
  .q-card::before { content: counter(cq, bengali) "।"; position: absolute; left: 0; top: 0; font-weight: 700; }
  .lk-article .q-card .q-title { display: none !important; }
  .q-stimulus { margin: 0 0 1mm; }
  .lk-article .q-parts li { grid-template-columns: 7mm 1fr 6mm; gap: 0; padding: .4mm 0; border: 0 !important; }
  .q-label { color: #000 !important; font-weight: 400; }
  .q-label .on-screen { display: none; }
  .q-label .on-paper { display: inline; }
  .q-marks { background: none !important; color: #000 !important; min-width: 0; height: auto; border-radius: 0; font-weight: 400; font-size: 11pt; justify-self: end; }
  .q-answer { display: none !important; }
  .q-card.written .q-total { position: absolute; top: 0; right: 0; background: none !important; color: #000 !important; font-weight: 400; font-size: 11pt; height: auto; padding: 0; }
  .q-card.written { padding-right: 8mm !important; }
  .lk-set > h4, .lk-article > h4 { color: #000 !important; font-size: 11.5pt; margin: 3mm 0 2mm; break-after: avoid; }

  /* MCQ: two columns like a question bank page; the key on its own page. */
  .lk-set:has(.mcq-card), .lk-article:has(> .mcq-card) { column-count: 2; column-gap: 8mm; column-rule: .5px solid #999; }
  .paper-head, .answer-key, [id^="answer-key"] { column-span: all; }
  [id^="answer-key"] { break-before: page; font-size: 13pt; text-align: center; margin: 0 0 3mm; color: #000 !important; }
  [id^="answer-key"]::after { display: none; }
  .mcq-card { border: 0 !important; border-radius: 0; background: none; padding: 0 !important; margin: 0 0 3mm !important; break-inside: avoid; }
  .mcq-stem p { margin: 0 0 .8mm; }
  .mcq-num { background: none !important; color: #000 !important; min-width: 0; height: auto; margin-right: 1mm; font-size: 11.5pt; }
  .mcq-num::after { content: "।"; }
  .mcq-options { grid-template-columns: 1fr 1fr; gap: .3mm 3mm; margin: 0; }
  .lk-article .mcq-options li { border: 0 !important; background: none !important; padding: 0 !important; }
  .mcq-letter { color: #000 !important; font-weight: 400; }
  .mcq-shared { break-inside: avoid; margin: 1mm 0 1.5mm; }
  .lk-article .mcq-shared-label { color: #000 !important; font-style: italic; }

  /* Code and tables in black and white. */
  .lk-article pre, .lk-article .codehilite pre { background: #fff !important; border: .5px solid #666; border-radius: 0; padding: 1.5mm 3mm; font-size: 9.5pt; white-space: pre-wrap; }
  .lk-article .codehilite * { color: #000 !important; font-weight: 400 !important; font-style: normal !important; }
  .lk-article :not(pre) > code { background: none; color: #000; padding: 0; }
  .lk-article .table-container { border: 0; border-radius: 0; margin: 1mm 0 2mm !important; }
  .lk-article .table td, .lk-article .table th,
  .lk-article .q-card .table td, .lk-article .q-card .table th,
  .lk-article .mcq-card .table td, .lk-article .mcq-card .table th,
  .lk-article .mcq-shared .table td, .lk-article .mcq-shared .table th {
    border: .5px solid #000 !important; padding: .4mm 3mm !important; background: none !important;
    font-size: 10.5pt !important; line-height: 1.35 !important; color: #000 !important;
  }
}
