/* catalogue.css */
.aviapochta,
.balagan,
.celoe,
.celoe_1997,
.chmuzyka1,
.chmuzyka2,
.chmuzyka3,
.deja,
.drugaja,
.esli,
.eto,
.fauxpas,
.gorod,
.izbran1,
.izbran2,
.kovcheg1,
.kovcheg2,
.minsk1,
.minsk2,
.minsk3,
.minsk4,
.once,
.peshkom,
.podrugim,
.pomotivam,
.predpolo,
.raycentr,
.shanson,
.vishnevo,
.vozdvig,
.xopobod,
.zaklinan {
	display: inline-block;
	width: 24px;
	height: 24px;
	vertical-align: -5px;
}
.disc { display: inline-block; width: 17px; height: 18px; background: url('/Images/schsprite.png') 0 0 no-repeat no-repeat; vertical-align: -2px; }
.bk13 { display: inline-block; width: 16px; height: 18px; background: url('/Images/schsprite.png') 0 -19px no-repeat; vertical-align: -2px; }
.bkdz { display: inline-block; width: 14px; height: 20px; background: url('/Images/schsprite.png') -16px -18px no-repeat; vertical-align: -2px; }
.bkkn { display: inline-block; width: 17px; height: 20px; background: url('/Images/schsprite.png') -39px -18px no-repeat; vertical-align: -2px; }
/* Пегас: внешние публикации песни, в т. ч. в периодике (публикации ещё не перенесены, иконка пока не используется) */
.bknb { display: inline-block; width: 15px; height: 19px; background: url('/Images/schsprite.png') -56px -18px no-repeat; vertical-align: -2px; }
.bkny { display: inline-block; width: 13px; height: 19px; background: url('/Images/schsprite.png') -71px -18px no-repeat; vertical-align: -2px; }
.bkvv { display: inline-block; width: 13px; height: 18px; background: url('/Images/schsprite.png') -189px -18px no-repeat; vertical-align: -2px; }
.bkp1 { display: inline-block; width: 20px; height: 20px; background: url('/Images/schsprite.png') -202px -18px no-repeat; vertical-align: -2px; }
.bkp2 { display: inline-block; width: 20px; height: 20px; background: url('/Images/schsprite.png') -222px -18px no-repeat; vertical-align: -2px; }
.bkp3 { display: inline-block; width: 20px; height: 20px; background: url('/Images/schsprite.png') -242px -18px no-repeat; vertical-align: -2px; }
.bkp4 { display: inline-block; width: 20px; height: 20px; background: url('/Images/schsprite.png') -262px -18px no-repeat; vertical-align: -2px; }
.new {  display: inline-block; width: 20px; height: 18px; background: url('/Images/schsprite.png') -296px -18px no-repeat; vertical-align: -2px; margin-right: .15em; }
.bktp { display: inline-block; width: 20px; height: 20px; background: url('/Images/schsprite.png') -262px -38px no-repeat; vertical-align: -2px; }
/* Ключ: старый значок-ссылка на комментарии в Словаре; противоречит концепции разделения витрины и фан-клуба, не использовать */
.key3 { display: inline-block; width: 8px; height: 20px; background: url('/Images/schsprite.png') -30px -18px no-repeat; vertical-align: -2px; }
.chrd { display: inline-block; width: 10px; height: 18px; background: url('/Images/schsprite.png') -83px -18px no-repeat; vertical-align: -2px; }
.upd {  display: inline-block; width: 20px; height: 18px; background: url('/Images/schsprite.png') -296px -18px no-repeat; vertical-align: -2px; }
.eng {  display: inline-block; width: 14px; height: 20px; background: url('/Images/schsprite.png') -332px -18px no-repeat; vertical-align: -2px; }
.deu {  display: inline-block; width: 14px; height: 20px; background: url('/Images/schsprite.png') -346px -18px no-repeat; vertical-align: -2px; }
.eso {  display: inline-block; width: 14px; height: 20px; background: url('/Images/schsprite.png') -360px -18px no-repeat; vertical-align: -2px; }
.heb {  display: inline-block; width: 14px; height: 20px; background: url('/Images/schsprite.png') -374px -18px no-repeat; vertical-align: -2px; }
.ukr {  display: inline-block; width: 14px; height: 20px; background: url('/Images/schsprite.png') -388px -18px no-repeat; vertical-align: -2px; }
.fra {  display: inline-block; width: 14px; height: 20px; background: url('/Images/schsprite.png') -402px -18px no-repeat; vertical-align: -2px; }
.tape1 { display: inline-block; width: 12px; height: 18px; background: url('/Images/schsprite.png') -93px -18px no-repeat; vertical-align: -2px; }
.tape2 { display: inline-block; width: 12px; height: 18px; background: url('/Images/schsprite.png') -105px -18px no-repeat; vertical-align: -2px; }
.tape3 { display: inline-block; width: 12px; height: 18px; background: url('/Images/schsprite.png') -117px -18px no-repeat; vertical-align: -2px; }
.tape4 { display: inline-block; width: 12px; height: 18px; background: url('/Images/schsprite.png') -129px -18px no-repeat; vertical-align: -2px; }
.tape5 { display: inline-block; width: 12px; height: 18px; background: url('/Images/schsprite.png') -141px -18px no-repeat; vertical-align: -2px; }
.tape6 { display: inline-block; width: 12px; height: 18px; background: url('/Images/schsprite.png') -153px -18px no-repeat; vertical-align: -2px; }
.tape7 { display: inline-block; width: 12px; height: 18px; background: url('/Images/schsprite.png') -165px -18px no-repeat; vertical-align: -2px; }
.tape8 { display: inline-block; width: 12px; height: 18px; background: url('/Images/schsprite.png') -177px -18px no-repeat; vertical-align: -2px; }





main > div {
        width: 100%;
        margin: 0;
}
h2 {
        font: italic normal 1.2em serif;
        margin-top: 0;
}
main,nav {
        background-color: var(--cell-bg);
}
main > div > div.wrapper > div {
        border-width: 1px;
        border-color: var(--cell-border);
        border-style: solid;
        padding: 5px;
}
nav > div {
        text-align: center;
        }
div.wrapper ul, div.wrapper ol {
        display: block;
        margin-block-start: 1.5em;
        margin-block-end: 1.5em;
        margin-inline-start: 0px;
        margin-inline-end: 0px;
        padding-inline-start: 40px;
        font: normal 1em/1.5em serif;
}

.opus-begin {
        color: var(--muted);
}

/* первые слова песни — в кавычках; кавычки не в тексте, а в CSS, чтобы при сортировке
   «по первым словам» (name и begin меняются местами) они оставались у первых слов */
.incipit::before { content: "«"; }
.incipit::after { content: "»"; }

.year, .poem-tag {
	font-size: .85em;
	color: var(--muted);
	display: inline-block;
	margin-left: .5em;
}

.albums, .books {
	display: inline-block;
	margin-left: .5em;
}

.books {
	font-size: .8em;
	color: var(--muted);
}

/* Balloon tooltip styles */
[data-balloon] {
	position: relative;
}

a [data-balloon] {
	cursor: pointer;
}

.new[data-balloon] {
	cursor: default;
}

[data-balloon]:before,
[data-balloon]:after {
	position: absolute;
	opacity: 0;
	pointer-events: none;
}
/* Невидимые подсказки не строятся вовсе, пока на значок не навели: иначе при каждой сортировке каталога
   браузер заново раскладывает тысячи скрытых блоков с текстом (замер 2026-10-08: щелчок ~200 мс → ~120 мс).
   content-visibility: auto у строк дал бы ~40 мс, но обрезает подсказки, выходящие за строку (paint containment). */
[data-balloon]:not(:hover):before,
[data-balloon]:not(:hover):after {
	display: none;
}

[data-balloon]:after {
	content: attr(data-balloon);
	padding: 0.5em 1em;
	background: rgba(255, 255, 255, 0.9);
	color: black;
	font-size: 0.85em;
	white-space: nowrap;
	line-height: 1.3; /* своя: у ссылок на значки альбомов line-height: 0 */
	border-radius: 3px;
	z-index: 10;
}

[data-balloon-break]:after {
	white-space: pre;
	text-align: left;
}

[data-balloon]:before {
	content: "";
	width: 0;
	height: 0;
	border: 5px solid transparent;
	z-index: 10;
}

[data-balloon]:hover:before,
[data-balloon]:hover:after {
	opacity: 1;
}

/* Position: up */
[data-balloon-pos="up"]:after {
	bottom: 100%;
	left: 50%;
	transform: translate(-50%, -10px);
	margin-bottom: 5px;
}

[data-balloon-pos="up"]:before {
	bottom: 100%;
	left: 50%;
	transform: translate(-50%, 0);
	border-top-color: rgba(255, 255, 255, 0.9);
}

[data-balloon-pos="up"]:hover:after {
	transform: translate(-50%, 0);
}
.search {
        display: block;
}
/* поле фильтра и кнопки сортировки — каталога песен (id) и каталога переводов (button[data-sort], translations.html) */
#search, #chronological, #alphabetical, #alphabetname, .search button[data-sort] {
  margin: 0.5rem auto 1.2rem;
}

#search,#clear-search,#chronological,#alphabetical,#alphabetname,.search button[data-sort] {
        height: 3em;
        padding: .5em;
        box-sizing: border-box;
        color: var(--control-text);
        border-color: var(--control-border);
        border-style: solid;
}
/* поле поиска в фокусе и кнопка активной сортировки (aria-pressed="true" ставит скрипт каталога) — жирная обводка */
#search:focus,
#alphabetname[aria-pressed="true"], #alphabetical[aria-pressed="true"], #chronological[aria-pressed="true"] {
        border: 3px solid var(--control-border);
}

/* кнопки сортировки каталога песен — рамка в 1px, как в каталоге переводов; у выбранной — толстая (выше) */
#alphabetname, #alphabetical, #chronological {
        border-width: 1px;
}
/* узкий экран: кнопки сортировки — одной группой (без промежутков, с общими границами), иначе не помещаются в ряд;
   выбранная (толстая рамка) — поверх соседних. Шире — раздельные (с 23.5em — та же точка, где даты в меню встают
   в строку, common.css; раздельные помещаются в ряд с ~21.25em). :is() с id — та же сила, что у общего правила
   отступов кнопок (решения владельца 2026-10-16) */
@media only screen and (width < 23.5em) {
        .sort-buttons > :is(#alphabetname, #alphabetical, #chronological, button[data-sort]) {
                margin-left: 0;
                margin-right: 0;
                padding-left: .4em;
                padding-right: .4em;
                position: relative;
        }
        .sort-buttons > :is(#alphabetname, #alphabetical, #chronological, button[data-sort]) + button {
                margin-left: -1px;
        }
        .sort-buttons > button[aria-pressed="true"] {
                z-index: 1;
        }
}
/* кнопка сброса фильтра: на компьютере — «сброс» рядом с полем, в мобильной версии — «✕» внутри поля (ниже) */
#clear-search {
        margin-left: .3em;
}
.clear-icon {
        display: none;
}

.hidden {
        display: none !important ;
}

#artlist li, #album-matches li {
        padding: .25em ;
	text-align: left;
}

.js-only { display: none ; }


@media (min-width: 100em) { #artlist { column-count: 2;} }
@media (min-width: 150em) { #artlist { column-count: 3;} }
@media (min-width: 200em) { #artlist { column-count: 4;} }
@media (min-width: 250em) { #artlist { column-count: 5;} }
@media (min-width: 300em) { #artlist { column-count: 6;} }
@media (min-width: 350em) { #artlist { column-count: 7;} }
@media (min-width: 400em) { #artlist { column-count: 8;} }
@media (min-width: 450em) { #artlist { column-count: 9;} }
@media (min-width: 500em) { #artlist { column-count: 10;} }

@media only screen and (width <= 70em) {

      body {
                font-size: 1em;
                line-height: 1.2;
      }
        /* nav / nav > div padding, margin, column-gap are all shared defaults now —
           see assets/css/common.css, don't redeclare them per page. */
        main > div > div.wrapper > div {
                display: block;
                padding: 1.5em;
                margin: 0 5px;
        }
        ul.mob-link-block > li > a {
                display:block;
                border: 1px solid var(--cell-border);
                margin-block-start: .5em;
                margin-block-end: .5em;
                padding: 1em 2em;
        }
        div.wrapper ul, ul.mob-link-block {
                list-style-type: none;
                padding-inline-start: 0;
        }
        div.wrapper ol {
                padding-inline-start: 1.5em;
        }
        .ch, .txt {
                display: flow;
        }
        /* блок фильтра и сортировки компактнее: поле во всю ширину ячейки, «✕» сброса — внутри поля справа
           (текст прокручивается, не переносится), кнопки сортировки — группой с переносом (решение владельца 2026-10-16) */
        main > div > div.wrapper > div {
                padding: 1em;
        }
        .search-field {
                position: relative;
                display: block;
                margin: .4em 0 1em;
        }
        #search {
                display: block;
                width: 100%;
                margin: 0;
                padding-right: 2.6em;
        }
        #clear-search {
                position: absolute;
                right: .35em;
                top: 50%;
                transform: translateY(-50%);
                width: 2.2em;
                height: 2.2em;
                margin: 0;
                padding: 0;
                border: none;
                background: transparent;
                font-size: 1em;
                line-height: 1;
                cursor: pointer;
        }
        .clear-text, .search-sep {
                display: none;
        }
        .clear-icon {
                display: inline;
        }
        .sort-label {
                display: block;
                margin-bottom: .4em;
        }
        .sort-buttons {
                display: flex;
                flex-wrap: wrap;
                justify-content: center;
                gap: .4em;
        }
        /* без auto по бокам (общее правило): во флекс-ряду auto делит всё свободное место — кнопки разъезжаются */
        .sort-buttons > :is(#alphabetname, #alphabetical, #chronological, button[data-sort]) {
                margin: 0;
        }

}
@media only screen and (width > 70em) {
        body {
                font-size: 16px;
        }
        header {
                margin-bottom: 5px;
        }

        nav, main > div {
                display: table;
                border-spacing: 5px;
                margin-top: 0;
                margin-bottom: 0;
        }
        nav > div, main > div > div.wrapper > div {
                display: table-cell;
                vertical-align: middle;
        }
        main > div > div.wrapper {
                display: table-row;
        }
        div.wrapper ul {
                list-style-type: square;
                font: normal 1em/1.5em serif;

        }
        .ch, .txt {
                display: inline;
        }
}

/* Значки альбомов (SVG из assets/svg/cd, ширина и картинка — из cd-icons.css):
   колонка постоянной ширины слева от названия, значки прижаты к названию; на телефоне — под названием */
.cd-icon {
	display: inline-block;
	height: 20px;
	vertical-align: middle;
}
#artlist {
	list-style: none;
}
#artlist > li {
	display: grid;
	grid-template-columns: calc(7 * 20px + 6 * 4px) 1fr;
	column-gap: .75em;
	align-items: center;
	break-inside: avoid;
}
#artlist > li[hidden] {
	display: none;
}
#artlist .albums {
	display: flex;
	justify-content: flex-end;
	gap: 4px;
	margin-left: 0;
}
#artlist .albums a {
	line-height: 0;
}
@media (max-width: 35em) {
	#artlist > li {
		grid-template-columns: 1fr;
		row-gap: 2px;
	}
	#artlist .albums {
		order: 2;
		justify-content: flex-start;
	}
}
/* узкий экран: кнопки сортировки одной группой — промежутков нет (после мобильного правила с gap) */
@media only screen and (width < 23.5em) {
        .sort-buttons {
                gap: 0;
        }
}
