:root {
    color-scheme: light;
    --ink: #25231f;
    --muted: #625f59;
    --paper: #fcfbf9;
    --surface: #fff;
    --stage: #f1efeb;
    --line: #e4dfd8;
    --focus: #775716;
    --gutter: clamp(16px, 4vw, 56px);
    font: 400 14px/1.55 "PingFang SC", "Microsoft YaHei UI", "Noto Sans CJK SC", system-ui, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--paper); -webkit-font-smoothing: antialiased; }
h1, h2, h3, p { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
.bk-sr { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.bk-wrap { width: min(1328px, calc(100% - 2 * var(--gutter))); margin-inline: auto; }
.bk-top { border-bottom: 1px solid var(--line); background: var(--paper); }
.bk-top-inner { min-height: 68px; display: flex; align-items: center; gap: clamp(14px, 3vw, 44px); }
.bk-brand { display: inline-flex; align-items: center; flex: none; gap: 9px; font-size: 17px; font-weight: 700; }
.bk-brand img { display: block; width: 55px; height: auto; }
.bk-top-nav { display: flex; flex-wrap: wrap; gap: 0 clamp(12px, 2vw, 28px); color: var(--muted); }
.bk-top-nav a, .bk-community { display: inline-flex; align-items: center; min-height: 44px; }
.bk-top-nav a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 5px; }
.bk-community { flex: none; justify-content: center; min-width: 88px; padding-inline: 10px; border: 1px solid var(--line); border-radius: 5px; }
.bk-community:hover, #bk-clear:hover { background: var(--stage); }
.bk-preview { background: var(--stage); padding: 8px 12px; text-align: center; color: var(--muted); }
.bk-preview a { margin-left: 10px; text-decoration: underline; }
.bk-search {
    display: flex; align-items: center; margin-left: auto; width: min(276px, 27vw); min-width: 130px;
    border: 1px solid var(--line); border-radius: 5px; background: var(--surface);
}
.bk-search:focus-within { border-color: var(--focus); }
.bk-search input { order: 1; width: 100%; min-width: 0; min-height: 42px; padding: 4px 10px 4px 0; border: 0; outline: none; background: transparent; color: var(--ink); }
.bk-search input::placeholder { color: var(--muted); }
.bk-search button { display: grid; place-items: center; flex: 0 0 44px; min-height: 42px; padding: 0; color: var(--muted); background: transparent; border: 0; }
.bk-search button:focus-visible { outline-offset: -4px; }
.bk-search button:hover { color: var(--ink); }
.bk-search-icon { width: 13px; height: 13px; border: 1.5px solid currentColor; border-radius: 50%; position: relative; }
.bk-search-icon::after { content: ''; position: absolute; width: 6px; height: 1.5px; background: currentColor; rotate: 45deg; right: -5px; bottom: -2px; }

.bk-featured { background: var(--stage); padding-block: 14px 27px; border-bottom: 1px solid var(--line); }
.bk-featured-inner { max-width: 1184px; }
.bk-section-head { display: flex; justify-content: space-between; align-items: center; gap: 8px 16px; }
.bk-featured .bk-section-head { margin-bottom: 9px; min-height: 44px; }
.bk-featured h2 { font-size: 16px; font-weight: 600; }
.bk-featured-controls { display: flex; align-items: center; justify-content: flex-end; }
.bk-featured-controls button { display: grid; place-items: center; flex: none; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 5px; color: var(--muted); background: transparent; }
.bk-featured-controls button:hover { background: #e6e1d9; color: var(--ink); }
.bk-chevron { width: 8px; height: 8px; border: solid currentColor; border-width: 1.5px 1.5px 0 0; rotate: 45deg; }
[data-featured-step="-1"] .bk-chevron { rotate: -135deg; }
.bk-rotation-icon { width: 8px; height: 10px; border-inline: 2px solid currentColor; }
[data-featured-pause][data-paused] .bk-rotation-icon { width: 0; height: 0; border: 5px solid transparent; border-left: 8px solid currentColor; border-right: 0; }
.bk-featured-pagination { display: flex; align-items: center; flex-wrap: wrap; justify-content: center; gap: 5px; max-width: 92px; }
.bk-featured-pagination i { width: 5px; height: 5px; border-radius: 4px; background: #a29b90; }
.bk-featured-pagination .is-current { width: 14px; background: var(--ink); }
.bk-featured-track {
    --card-gap: clamp(8px, 1.6vw, 22px);
    --card-width: min(540px, 79%, max(320px, calc(50% - var(--card-gap))));
    --edge-fade: 15%;
    position: relative; overflow: hidden; touch-action: pan-y pinch-zoom;
}
.bk-featured-track.is-carousel { mask-image: linear-gradient(to right, transparent, #000 var(--edge-fade), #000 calc(100% - var(--edge-fade)), transparent); }
.bk-featured-slide, .bk-featured-peek {
    display: block; width: var(--card-width); aspect-ratio: 1800 / 766;
    border: 0; border-radius: 7px; overflow: hidden; background: var(--surface);
    box-shadow: inset 0 0 0 1px rgb(37 35 31 / 10%);
}
.bk-featured-slide { position: relative; margin-inline: auto; }
.bk-featured-slide:focus-visible, .bk-featured-peek:focus-visible { outline-offset: -4px; }
.bk-featured-peek { position: absolute; top: 0; padding: 0; text-align: left; color: inherit; }
.bk-featured-peek.is-incoming, .bk-featured-peek > * { pointer-events: none; }
.bk-featured-peek > * { opacity: .62; transition: opacity .18s ease; }
.bk-featured-peek:hover > *, .bk-featured-peek:focus-visible > * { opacity: 1; }
.bk-featured-peek-prev { right: calc(50% + var(--card-width) / 2 + var(--card-gap)); }
.bk-featured-peek-next { left: calc(50% + var(--card-width) / 2 + var(--card-gap)); }
.bk-featured-peek-prev.is-incoming { right: calc(50% + var(--card-width) * 1.5 + var(--card-gap) * 2); }
.bk-featured-peek-next.is-incoming { left: calc(50% + var(--card-width) * 1.5 + var(--card-gap) * 2); }
.bk-featured-image { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: contain; }
.bk-featured-copy { position: absolute; inset: 0; display: grid; align-content: safe center; justify-items: start; gap: 4px; overflow: auto; padding: clamp(10px, 2.5vw, 28px); overflow-wrap: anywhere; }
.bk-featured-copy strong { font-size: clamp(16px, 2.2vw, 24px); line-height: 1.35; }
.bk-featured-copy > span { font-size: 13px; line-height: 1.45; color: var(--muted); }
.bk-featured-slide:hover strong { text-decoration: underline; text-underline-offset: 4px; }

.bk-catalog { padding-block: clamp(23px, 3vw, 44px) 24px; }
.bk-catalog h1 { font-size: clamp(22px, 2.1vw, 30px); font-weight: 700; line-height: 1.35; }
.bk-section-head p { margin-top: 4px; color: var(--muted); font-size: 13px; overflow-wrap: anywhere; }
.bk-section-head p:empty { display: none; }
#bk-clear { flex: none; min-height: 44px; padding: 5px 12px; color: var(--muted); background: var(--surface); border: 1px solid var(--line); border-radius: 5px; }
.bk-catalog, .bk-catalog-group { scroll-margin-top: 16px; }
.bk-catalog-group { margin-top: clamp(16px, 2vw, 24px); padding-top: clamp(15px, 2vw, 24px); border-top: 1px solid var(--line); }
.bk-catalog-heading { font-size: 17px; font-weight: 700; margin-bottom: 12px; overflow-wrap: anywhere; }
.bk-empty { margin-top: 14px; color: var(--muted); }
.bk-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(10px, 1.4vw, 20px); align-items: stretch; }
.bk-card {
    display: flex; align-items: center; min-width: 0; gap: 12px; padding: clamp(12px, 1.4vw, 20px);
    border: 1px solid var(--line); border-radius: 7px; background: var(--surface);
    transition: border-color .18s ease, background-color .18s ease;
}
.bk-card:hover { border-color: #a59a8b; }
.bk-card:hover h3 { text-decoration: underline; text-underline-offset: 4px; }
.bk-card-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.bk-card h3 { font-size: 16px; font-weight: 700; line-height: 1.45; overflow-wrap: anywhere; }
.bk-card p { color: var(--muted); font-size: 13px; line-height: 1.55; overflow-wrap: anywhere; }
.bk-label { margin-top: 3px; color: var(--muted); font-size: 12px; line-height: 1.4; overflow-wrap: anywhere; }
.bk-label-tool-default { display: none; }
.bk-icon { display: grid; place-items: center; width: 34px; height: 34px; flex: 0 0 34px; color: #524936; background: #f2eee6; border-radius: 5px; }
/* Tool pictograms */
.bk-icon i { position: relative; display: block; width: 16px; height: 14px; }
.bk-icon i::before, .bk-icon i::after { content: ''; position: absolute; }
.bk-icon-grid i, .bk-icon-book i { border: 1.5px solid currentColor; border-radius: 2px; }
.bk-icon-grid i::before, .bk-icon-book i::before { inset: 0 5.75px; border-left: 1.5px solid currentColor; }
.bk-icon-grid i::after { inset: 4.5px 0 auto; border-top: 1.5px solid currentColor; }
.bk-icon-score i { border-bottom: 1.5px solid currentColor; }
.bk-icon-score i::before { width: 2px; height: 6px; bottom: 2px; left: 2px; background: currentColor; }
.bk-icon-score i::after { width: 2px; height: 9px; bottom: 2px; left: 7px; background: currentColor; box-shadow: 5px -2px currentColor; }
.bk-icon-draw i { border: 1.5px solid currentColor; border-radius: 3px; width: 15px; height: 15px; }
.bk-icon-draw i::before { width: 2px; height: 2px; top: 2px; left: 2px; border-radius: 50%; background: currentColor; box-shadow: 3px 3px currentColor, 6px 6px currentColor; }
.bk-icon-sound i::before { width: 2px; height: 14px; left: 7px; border-radius: 1px; background: currentColor; }
.bk-icon-sound i::after { width: 2px; height: 8px; top: 3px; left: 3px; border-radius: 1px; background: currentColor; box-shadow: 8px 0 currentColor; }
#catalog-course .bk-card:not(.bk-card-with-cover) { background: #f7f4ef; }
#catalog-resource .bk-card:not(.bk-card-with-cover) { background: transparent; }
#catalog-resource .bk-card:not(.bk-card-with-cover):hover { background: var(--surface); }
.bk-card.bk-card-with-cover { align-self: start; display: block; padding: 0; overflow: hidden; border: 0; background: transparent; }
.bk-card-with-cover:hover { outline: 1px solid #a59a8b; outline-offset: 2px; }
.bk-card-with-cover:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
.bk-cover { display: block; width: 100%; height: auto; aspect-ratio: auto 1800 / 766; }

@media (min-width: 941px) {
    #catalog-software .bk-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1100px) {
    .bk-catalog-group { display: grid; grid-template-columns: 126px minmax(0, 1fr); gap: clamp(16px, 2.1vw, 30px); }
    .bk-catalog-heading { margin: 0; padding-top: 2px; }
}
@media (max-width: 760px) {
    .bk-top-inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; gap: 4px 12px; min-height: 0; padding-block: 8px 0; }
    .bk-top-nav { grid-row: 2; grid-column: 1 / -1; gap: 0 18px; }
    .bk-top-nav:empty { display: none; }
    .bk-search { grid-area: 1 / 2; width: 100%; min-width: 0; }
    .bk-community { grid-area: 1 / 3; }
    .bk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .bk-card h3 { font-size: 15px; }
    .bk-featured { padding-block: 6px 20px; }
    .bk-featured .bk-section-head { margin-bottom: 5px; }
    .bk-featured-track { --edge-fade: 9%; }
}
@media (max-width: 540px) {
    .bk-top-inner { grid-template-columns: minmax(0, 1fr) auto; }
    .bk-community { grid-area: 1 / 2; min-width: 0; border: 0; padding-inline: 4px; }
    .bk-search { grid-area: 2 / 1 / 3 / -1; }
    .bk-top-nav { grid-row: 3; }
    .bk-featured-track { --edge-fade: 6%; --card-width: 79%; }
    .bk-featured-slide, .bk-featured-peek { border-radius: 5px; }
    .bk-card { align-items: flex-start; }
    .bk-icon { width: 26px; height: 26px; flex-basis: 26px; }
    #catalog-tool .bk-card:not(.bk-card-with-cover) { gap: 7px; padding-inline: 9px; }
}
@media (max-width: 350px) {
    :root { --gutter: 12px; }
    #catalog-course .bk-grid, #catalog-resource .bk-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) { .bk-card, .bk-featured-peek > * { transition: none; } }
