/* ============================================================
   ІРОНМедУ (repo.odmu.edu.ua) — оформление в фирменном стиле ОНМедУ, версия 3.
   Тема ONMUIR живёт на ВМ 6.28 без доступа: этот файл и repo.js подмешивает nginx
   на site8 (dspace.conf, sub_filter перед </head>). Файлы: /sites/dspace/onmu-assets/.
   Палитра — официальная палитра университета (как на onmedu.edu.ua до редизайна):
   графит #35404f, синий #2773a6, золото #bba368. Шрифт — Fira Sans, как у сайта вуза.
   v3: шапка с фото университета (hero-N.jpg) и лого-корпусом как на onmedu.edu.ua,
   серая подложка и белые блоки с тенью — чтобы страница не выглядела плоской.
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Fira+Sans:ital,wght@0,400;0,500;0,600;1,400&display=swap');

:root {
	--u-slate: #35404f;
	--u-slate-2: #2a333f;
	--u-blue: #2773a6;
	--u-blue-dark: #1d5a83;
	--u-gold: #bba368;
	--u-ink: #1f2933;
	--u-text: #3a4552;
	--u-muted: #6b7682;
	--u-line: #dfe3e8;
	--u-soft: #f4f6f8;
	--u-page: #eaeef2;
	--u-wrap: 120rem;
	--u-card-shadow: 0 1px 2px rgba(23, 35, 50, .06), 0 8px 24px -6px rgba(23, 35, 50, .12);
	--u-lift-shadow: 0 2px 4px rgba(23, 35, 50, .08), 0 14px 30px -8px rgba(23, 35, 50, .22);
}

/* ---------- База (только страницы DSpace: CSS попадает и в HTML проверки Anubis) ---------- */
html:has(#ds-main) { font-size: 62.5%; }
body:has(#ds-main) {
	background: var(--u-page) !important;
	color: var(--u-text);
	font-family: 'Fira Sans', Arial, sans-serif !important;
	font-size: 1.6rem !important;
	line-height: 1.55;
	-webkit-text-size-adjust: 100%;
}
#ds-main a { color: var(--u-blue); text-decoration: none; }
#ds-main a:hover { color: var(--u-blue-dark); text-decoration: underline; }
#ds-main h1, #ds-main h2, #ds-main h3 { font-family: 'Fira Sans', Arial, sans-serif; color: var(--u-ink); font-weight: 600; letter-spacing: 0; }
/* В теме многое выровнено по ширине — на узкой колонке дыры между словами */
#ds-main p, #ds-main li, #ds-main div, #ds-main h1, #ds-main h2 { text-align: left !important; }

/* Сетка вместо фиксированных 1300px */
#ds-header-wrapper, #ds-trail-wrapper, #ds-content-wrapper, #ds-footer-wrapper { min-width: 0 !important; }
.u-wrap, #ds-trail, #ds-content, #no-js-warning {
	width: auto !important;
	max-width: var(--u-wrap);
	margin: 0 auto !important;
	padding: 0 2.4rem;
	box-sizing: border-box;
}

/* Пока repo.js собирает шапку — старую не показываем (страховка: через 2,5 с покажется сама) */
.rp-js:not(.rp-ready) #ds-header-wrapper { visibility: hidden; animation: u-show 0s 2.5s forwards; }
@keyframes u-show { to { visibility: visible; } }

/* ---------- Шапка ---------- */
#ds-header-wrapper { background: #fff !important; color: var(--u-ink); border: 0; }
#ds-header-wrapper.u-built #ds-header { display: none; }

.u-topbar { background: var(--u-slate); color: #d5dbe1; font-size: 1.35rem; }
.u-topbar .u-wrap { display: flex; align-items: center; justify-content: space-between; gap: 1.6rem; min-height: 3.6rem; }
.u-topbar a { color: #fff !important; }
.u-topbar__uni { color: #d5dbe1 !important; }
.u-topbar__right { display: flex; align-items: center; gap: 1.8rem; }
.u-topbar #ds-user-box, .u-topbar #ds-language-selection { position: static !important; color: #fff; }
.u-topbar #ds-user-box p { margin: 0; }
.u-topbar #ds-language-selection a { margin-left: .2rem; padding: 0 .4rem; text-transform: uppercase; font-size: 1.25rem; letter-spacing: .04em; }
.u-topbar #ds-language-selection a + a { border-left: 1px solid rgba(255, 255, 255, .35); padding-left: .8rem; }
.u-topbar #ds-language-selection a.u-current { color: var(--u-gold) !important; }

/* Шапка с фото: картинку ставит repo.js в --u-hero (одно из трёх фото ОНМедУ),
   поверх — затемнение в цветах университета, чтобы белый текст читался на любом кадре */
.u-mast { position: relative; isolation: isolate; overflow: hidden; background: var(--u-slate-2); color: #fff; }
.u-mast::before {
	content: ''; position: absolute; inset: 0; z-index: -2;
	background: var(--u-hero, none) center 45% / cover no-repeat;
}
.u-mast::after {
	content: ''; position: absolute; inset: 0; z-index: -1;
	background:
		linear-gradient(100deg, rgba(30, 40, 54, .9) 0%, rgba(33, 52, 74, .74) 45%, rgba(29, 90, 131, .38) 100%),
		linear-gradient(to top, rgba(20, 28, 38, .45), transparent 45%);
}
.u-mast .u-wrap { display: flex; align-items: center; gap: 3.2rem; padding-top: 3.2rem; padding-bottom: 3.2rem; }
.u-brand { display: flex; align-items: center; gap: 2rem; color: #fff !important; text-decoration: none !important; flex: 1 1 auto; min-width: 0; }
/* Лого — фото корпуса, как на onmedu.edu.ua: фон с зумом 118% срезает светлые края исходника */
.u-logo {
	flex: none; width: 14.6rem; height: 12rem; border-radius: 1.6rem;
	background: #dfe5ec url('logo-building.png') no-repeat center / 118%;
	box-shadow: 0 10px 26px rgba(0, 0, 0, .35);
}
.u-brand__title { display: block; font-size: 3rem; font-weight: 600; line-height: 1.12; color: #fff; text-shadow: 0 1px 12px rgba(0, 0, 0, .25); }
.u-brand__sub { display: block; font-size: 1.45rem; color: #d3dce6; margin-top: .5rem; }
.u-brand__sub::before { content: ''; display: block; width: 3.2rem; height: 2px; background: var(--u-gold); margin-bottom: .7rem; }
/* Главная: высокая шапка с фото главного корпуса — как у СумДУ/ВНУ/КПІ */
.u-mast--home { min-height: 52rem; display: flex; align-items: stretch; }
.u-mast--home::before { background-position: center 40%; }
.u-mast--home::after {
	background:
		linear-gradient(90deg, rgba(27, 37, 51, .92) 0%, rgba(30, 46, 66, .8) 40%, rgba(29, 70, 104, .35) 75%, rgba(29, 90, 131, .15) 100%),
		linear-gradient(to top, rgba(20, 28, 38, .55), transparent 40%);
}
.u-mast--home .u-wrap { flex: 1 1 auto; flex-direction: column; align-items: flex-start; justify-content: center; gap: 0; padding-top: 5.6rem; padding-bottom: 5.6rem; }
.u-mast--home .u-brand { flex: none; }
.u-mast--home .u-brand__title { font-size: 3.8rem; }
.u-hero-body { max-width: 76rem; width: 100%; margin-top: 2.6rem; }
.u-hero-lead { max-width: 64rem; margin: 0; font-size: 1.75rem; line-height: 1.55; color: #e6ecf2; }
.u-hero-facts { display: flex; flex-wrap: wrap; gap: 1rem 4rem; margin: 2.6rem 0 0; }
.u-hero-facts:empty { display: none; }
.u-hero-facts .u-fact { padding: 0; background: none; border: 0; border-radius: 0; }
.u-hero-facts .u-fact b { color: #fff; font-size: 3.2rem; text-shadow: 0 2px 14px rgba(0, 0, 0, .3); }
.u-hero-facts .u-fact span { color: var(--u-gold); font-size: 1.35rem; text-transform: uppercase; letter-spacing: .08em; }
.u-hero-links { list-style: none; margin: 2.6rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: .8rem 2.8rem; }
.u-hero-links:empty { display: none; }
.u-hero-links a { color: #fff !important; font-size: 1.5rem; font-weight: 500; text-decoration: none !important; border-bottom: 1px solid rgba(187, 163, 104, .7); padding-bottom: .2rem; }
.u-hero-links a:hover { border-bottom-color: #fff; }
.u-search--wide { margin-top: 3.2rem; max-width: 72rem; }
.u-search--wide input[type="text"], .u-search--wide button { height: 5.6rem; font-size: 1.65rem; }
.u-search--wide button { padding: 0 2.8rem; }

.u-search { flex: 0 1 44rem; }
.u-search form { display: flex; border-radius: 4px; box-shadow: 0 10px 28px rgba(0, 0, 0, .3); }
.u-search input[type="text"] {
	flex: 1 1 auto; min-width: 0;
	height: 4.8rem; box-sizing: border-box;
	border: 0; border-radius: 4px 0 0 4px;
	padding: 0 1.4rem; font: inherit; font-size: 1.55rem; color: var(--u-ink); background: #fff;
}
.u-search input[type="text"]:focus { outline: 2px solid var(--u-gold); outline-offset: -2px; }
.u-search button {
	height: 4.8rem; border: 0; border-radius: 0 4px 4px 0;
	background: var(--u-gold); color: var(--u-ink); font: inherit; font-weight: 600; font-size: 1.5rem;
	padding: 0 2rem; cursor: pointer; transition: background .15s;
}
.u-search button:hover { background: #cdb67c; }
.u-search__more { display: inline-block; font-size: 1.3rem; margin-top: .7rem; color: #d3dce6 !important; }
.u-search__more:hover { color: #fff !important; }

/* Меню прилипает к верху при прокрутке и отбрасывает тень на страницу
   (repo.js ставит его прямо в #ds-main, иначе sticky ограничен шапкой) */
.u-nav { background: linear-gradient(#2c7cb2, var(--u-blue)); position: sticky; top: 0; z-index: 40; box-shadow: 0 3px 10px rgba(23, 35, 50, .18); }
.u-nav ul { list-style: none; margin: 0; padding: 0; display: flex; overflow-x: auto; scrollbar-width: none; }
.u-nav ul::-webkit-scrollbar { display: none; }
.u-nav li { flex: none; }
.u-nav a {
	display: block; color: #fff !important; font-size: 1.5rem; font-weight: 500;
	padding: 1.2rem 1.6rem 1rem; border-bottom: 3px solid transparent; text-decoration: none !important;
}
.u-nav li:first-child a { padding-left: 0; }
.u-nav a:hover { background: var(--u-blue-dark); }
.u-nav li:first-child a:hover { background: none; }
.u-nav a.u-active { border-bottom-color: var(--u-gold); }

/* Хлебные крошки */
#ds-trail-wrapper { background: none !important; border: 0 !important; }
#ds-trail { padding-top: 1.4rem !important; padding-bottom: 0 !important; font-size: 1.35rem; line-height: 1.5; }
#ds-trail li { color: var(--u-muted) !important; margin-right: .2rem; }
#ds-trail a { color: var(--u-blue) !important; }

/* ---------- Контент: основная колонка + правая колонка ---------- */
#ds-content {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 30rem;
	gap: 2.4rem;
	align-items: start;
	padding-top: 1.4rem !important;
	padding-bottom: 5.6rem !important;
}
#ds-content-wrapper { background: none !important; }
#ds-content::before, #ds-content::after { display: none !important; }
/* Основная колонка и правая колонка — белые листы на серой подложке */
#ds-body, #ds-options-wrapper {
	float: none !important; width: auto !important; min-width: 0;
	background: #fff; border-radius: 6px; box-shadow: var(--u-card-shadow); box-sizing: border-box;
}
#ds-body { padding: 3.2rem 3.6rem 4rem !important; grid-column: 1; grid-row: 1; }
#ds-options-wrapper { padding: 2.6rem 2.4rem .4rem !important; grid-column: 2; grid-row: 1; font-size: 1.45rem; border-top: 3px solid var(--u-gold); }

/* Поиск в колонке не нужен — он в шапке */
#ds-search-option-head, #ds-search-option { display: none !important; }
/* RSS — блок в колонке прячем, сами ленты работают (ссылки rel=alternate в <head> для читалок) */
#ds-feed-option-head, #ds-feed-option { display: none !important; }

/* Заголовки блоков колонки: строчные капители + короткая золотая черта */
h1.ds-option-set-head {
	background: none !important; border: 0 !important;
	margin: 0 0 1rem !important; padding: 0 0 .8rem !important;
	font-size: 1.3rem !important; font-weight: 600 !important;
	text-transform: uppercase; letter-spacing: .08em; color: var(--u-slate) !important;
	position: relative;
}
h1.ds-option-set-head::after { content: ''; position: absolute; left: 0; bottom: 0; width: 2.8rem; height: 2px; background: var(--u-gold); }
div.ds-option-set { border: 0 !important; padding: 0 !important; margin: 0 0 3.2rem; background: none; }
div.ds-option-set ul { margin: 0 !important; padding: 0 !important; list-style: none; }
div.ds-option-set ul ul { margin: .2rem 0 .8rem !important; }
div.ds-option-set li { padding: .35rem 0; border-bottom: 1px solid #eef0f3; }
div.ds-option-set ul ul li:last-child { border-bottom: 0; }
div.ds-option-set h2.ds-sublist-head { font-size: 1.45rem !important; font-weight: 600 !important; color: var(--u-ink) !important; margin: 1.4rem 0 .4rem !important; }
div.ds-option-set li > h2.ds-sublist-head:first-child { margin-top: .4rem !important; }
#ds-feed-option a { background-position: 0 50% !important; padding-left: 2.2rem; }
.u-facet-n { color: var(--u-muted); font-variant-numeric: tabular-nums; float: right; margin-left: 1rem; }

/* Блок «Авторам» в правой колонке главной (переносится из вступления) */
.u-aside { margin: 0 0 3.2rem; }
.u-aside h2 {
	font-size: 1.3rem !important; font-weight: 600 !important; text-transform: uppercase; letter-spacing: .08em;
	color: var(--u-slate) !important; margin: 0 0 1rem !important; padding-bottom: .8rem; position: relative;
}
.u-aside h2::after { content: ''; position: absolute; left: 0; bottom: 0; width: 2.8rem; height: 2px; background: var(--u-gold); }
.u-aside ul { list-style: none; margin: 0; padding: 0; }
.u-aside li { padding: .55rem 0; border-bottom: 1px solid #eef0f3; line-height: 1.4; }
.u-aside p { margin: .4rem 0; font-size: 1.4rem; color: var(--u-text); }

/* ---------- Типографика основной колонки ---------- */
#ds-body h1 { font-size: 2.8rem !important; line-height: 1.2; margin: 0 0 1.6rem !important; color: var(--u-slate) !important; }
#ds-body h2 { font-size: 2rem !important; margin: 3.6rem 0 1.4rem !important; color: var(--u-slate) !important; }
#ds-body h3 { font-size: 1.6rem !important; }

/* ---------- Главная ---------- */
.u-lead { font-size: 1.8rem; line-height: 1.55; color: var(--u-ink); margin: 0 0 1.6rem; max-width: 68rem; }
.u-lead--mobile { display: none; }
.u-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 1.4rem; margin: 0 0 1.2rem; }
.u-fact {
	padding: 1.6rem 1.8rem; border-radius: 5px;
	background: linear-gradient(160deg, #f8fafc, #eef2f6); border: 1px solid #e1e6ec; border-top: 3px solid var(--u-gold);
}
.u-fact b { display: block; font-size: 2.6rem; font-weight: 600; color: var(--u-slate); line-height: 1.2; font-variant-numeric: tabular-nums; }
.u-fact span { font-size: 1.35rem; color: var(--u-muted); }
#file_news_div_news.u-moved { display: none; }

/* Зібрання — таблица в две колонки: название слева, число справа */
#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser > p.ds-paragraph { display: none; }
/* Зібрання — плитки: ссылка растянута на всю плитку, при наведении плитка приподнимается */
#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser > ul {
	list-style: none; margin: 0; padding: 0;
	display: grid; grid-template-columns: repeat(auto-fill, minmax(26rem, 1fr)); gap: 1.2rem;
}
#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser > ul > li { margin: 0; }
#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser > ul > li > .artifact-description { height: 100%; }
#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser .artifact-title {
	position: relative; height: 100%; box-sizing: border-box;
	display: flex; align-items: baseline; justify-content: space-between; gap: 1.6rem;
	padding: 1.4rem 1.6rem; color: var(--u-muted);
	background: #fff; border: 1px solid #e1e6ec; border-left: 3px solid var(--u-blue); border-radius: 5px;
	box-shadow: 0 1px 2px rgba(23, 35, 50, .05);
	transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser .artifact-title:hover {
	transform: translateY(-2px); box-shadow: var(--u-lift-shadow); border-left-color: var(--u-gold);
}
#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser .artifact-title a { font-weight: 500; font-size: 1.6rem; line-height: 1.35; }
#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser .artifact-title a::after { content: ''; position: absolute; inset: 0; }
#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser .artifact-title a:hover { text-decoration: none; }
.u-count { color: var(--u-muted); font-size: 1.4rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
ul.ds-referenceSet-list .u-count { margin-left: .8rem; }

/* Списки записей (нові надходження, пошук, перегляд) */
#ds-body ul.ds-artifact-list { list-style: none; margin: 0 -1.2rem; padding: 0; border-top: 1px solid var(--u-line); }
/* В «Перегляд за автором/темою» внутри списка таблица, а не записи — без выноса за край */
#ds-body ul.ds-artifact-list:has(> table) { margin: 0; border-top: 0; }
#ds-body ul.ds-artifact-list > li.ds-artifact-item {
	background: none !important; padding: 1.6rem 1.2rem; margin: 0; border-bottom: 1px solid var(--u-line);
	border-radius: 4px; transition: background .15s;
}
#ds-body ul.ds-artifact-list > li.ds-artifact-item:hover { background: #f5f8fb !important; }
#ds-body .ds-artifact-item .artifact-title a { font-weight: 500; font-size: 1.7rem; line-height: 1.35; }
#ds-body .ds-artifact-item .artifact-info { color: var(--u-muted); font-size: 1.4rem; margin-top: .3rem; }
#ds-body .ds-artifact-item .artifact-abstract {
	color: var(--u-text); font-size: 1.45rem; margin-top: .6rem;
	display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
#aspect_discovery_SiteRecentSubmissions_div_site-recent-submission > p,
#aspect_discovery_SiteRecentSubmissions_div_site-recent-submission .ds-paragraph { margin-top: 1.4rem; }

/* ---------- Страница записи ---------- */
.item-summary-view-metadata > h1 { font-size: 2.8rem !important; line-height: 1.25 !important; }
.simple-item-view-authors { font-size: 1.6rem; color: var(--u-ink); margin: 0 0 2rem; padding-bottom: 1.6rem; border-bottom: 1px solid var(--u-line); }
.simple-item-view-other { display: grid; grid-template-columns: 14rem minmax(0, 1fr); gap: 1.6rem; padding: .7rem 0; border-bottom: 1px solid #eef0f3; overflow-wrap: anywhere; }
.simple-item-view-other .bold { color: var(--u-muted); font-weight: 400; }
.simple-item-view-description { margin-top: 2.4rem; }
.simple-item-view-description h3 { font-size: 1.3rem !important; text-transform: uppercase; letter-spacing: .08em; color: var(--u-slate) !important; margin: 0 0 .8rem !important; }
.simple-item-view-description > div { font-size: 1.6rem; line-height: 1.65; color: var(--u-ink); max-width: 72rem; }
.item-view-toggle { margin-top: 2rem; font-size: 1.45rem; }

/* Файли — строка с кнопкой загрузки */
.file-list { border-top: 1px solid var(--u-line); }
.file-wrapper { display: flex; align-items: center; gap: 1.6rem; flex-wrap: wrap; padding: 1.4rem 0; border-bottom: 1px solid var(--u-line); }
.file-wrapper::before, .file-wrapper::after { display: none !important; }
.file-wrapper .thumbnail-wrapper { float: none !important; width: auto !important; flex: none; }
.file-wrapper .thumbnail-wrapper img { height: 4.8rem !important; width: auto; }
.file-wrapper .thumbnail-wrapper img.u-thumb { height: auto !important; width: 12rem; }

/* Превью первой страницы (делаем сами: ~/repo-protect/thumbs → onmu-assets/thumbs/) */
.u-thumb { display: block; background: #fff; border: 1px solid #dde3ea; border-radius: 2px; box-shadow: 0 1px 2px rgba(23, 35, 50, .08), 0 6px 14px -6px rgba(23, 35, 50, .25); }
#ds-body li.u-has-thumb { display: grid; grid-template-columns: 7.6rem minmax(0, 1fr); column-gap: 1.8rem; align-items: start; }
#ds-body li.u-has-thumb > * { grid-column: 2; }
#ds-body li.u-has-thumb > .u-thumb-link { grid-column: 1; grid-row: 1 / span 9; }
#ds-body li.u-has-thumb > .thumbnail-wrapper { float: none !important; width: auto !important; margin: 0 !important; }
#ds-body li.u-has-thumb > .thumbnail-wrapper img { width: 100%; height: auto !important; }
#ds-body li.u-has-thumb::before, #ds-body li.u-has-thumb::after { display: none !important; }
.u-thumb-link .u-thumb { width: 100%; height: auto; transition: transform .18s ease; }
.u-thumb-link:hover .u-thumb { transform: translateY(-2px); }
.file-wrapper .file-metadata { float: none !important; height: auto !important; width: auto !important; flex: 1 1 24rem; min-width: 0; font-size: 1.45rem; overflow-wrap: anywhere; }
.file-wrapper .file-metadata > div { display: inline; margin-right: 1.6rem; }
.file-wrapper .file-metadata .bold { color: var(--u-muted); font-weight: 400; }
.file-wrapper .file-link { float: none !important; height: auto !important; width: auto !important; flex: none; }
.file-wrapper .file-link a {
	display: inline-block; background: var(--u-blue); color: #fff !important;
	padding: .9rem 1.8rem; border-radius: 4px; font-weight: 500; text-decoration: none !important;
	box-shadow: 0 2px 0 var(--u-blue-dark), 0 6px 14px -4px rgba(29, 90, 131, .5);
}
.file-wrapper .file-link a:hover { background: var(--u-blue-dark); }
ul.ds-referenceSet-list { padding-left: 1.8rem; }

/* Таблицы (полный опис, статистика, адмінка) */
#ds-body table { width: 100%; border-collapse: collapse; font-size: 1.45rem; border-top: 2px solid var(--u-slate); }
#ds-body table td, #ds-body table th { border-bottom: 1px solid var(--u-line); padding: .8rem 1rem .8rem 0; text-align: left; vertical-align: top; overflow-wrap: anywhere; background: none !important; }
#ds-body table tr { background: none !important; }
/* «Повний опис»: поле — без разрывов посреди слова (переносы только после точки, их ставит repo.js),
   язык значения — узкая серая колонка, строки через одну чуть подсвечены вместо бирюзы темы */
#ds-body table.detailtable tr.odd { background: #f7f9fb !important; }
#ds-body table.detailtable { background: #fff !important; }
#ds-body table.detailtable td, #ds-body table.detailtable th { padding-left: 1rem; border: 0 !important; border-bottom: 1px solid var(--u-line) !important; }
#ds-body table.detailtable td.label-cell { width: 22rem; overflow-wrap: normal; word-break: normal; color: var(--u-muted); font-size: 1.35rem; }
#ds-body table.detailtable td.label-cell.u-field { color: var(--u-slate); font-size: 1.45rem; font-weight: 500; }
#ds-body table.detailtable td:last-child:not(.label-cell) { width: 5rem; white-space: nowrap; overflow-wrap: normal; color: var(--u-muted); font-size: 1.25rem; }
#ds-body table th { color: var(--u-slate); font-weight: 600; }

/* Кнопки и поля форм DSpace (пошук, вхід, подання) */
#ds-main .ds-button-field, #ds-main input[type="submit"] {
	background: var(--u-blue) !important; color: #fff !important; border: 0 !important;
	border-radius: 2px !important; padding: .8rem 1.6rem !important; height: auto;
	font-family: inherit; font-weight: 500; font-size: 1.45rem; cursor: pointer;
}
#ds-main .ds-button-field:hover, #ds-main input[type="submit"]:hover { background: var(--u-blue-dark) !important; }
#ds-main input.ds-text-field, #ds-main select, #ds-main textarea {
	font: inherit; font-size: 1.5rem; border: 1px solid #b9c2cb; border-radius: 2px;
	padding: .6rem 1rem; box-sizing: border-box; max-width: 100%; height: auto; min-height: 3.8rem;
}

/* ---------- Подвал ---------- */
#ds-footer-wrapper { background: var(--u-slate) !important; color: #c9d1d9; border: 0; margin: 0; border-top: 3px solid var(--u-gold) !important; }
#ds-footer-wrapper.u-built #ds-footer { display: none; }
.u-foot { padding: 3.6rem 0 2.4rem; font-size: 1.4rem; line-height: 1.6; }
.u-foot .u-wrap { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 3.2rem; }
.u-foot h3 { color: #fff !important; font-size: 1.3rem !important; text-transform: uppercase; letter-spacing: .08em; margin: 0 0 1rem !important; }
.u-foot p { margin: 0 0 .6rem; }
.u-foot ul { list-style: none; margin: 0; padding: 0; }
.u-foot li { margin: 0 0 .5rem; }
.u-foot a { color: #fff !important; }
.u-foot a:hover { color: var(--u-gold) !important; }
.u-foot__brand { display: flex; gap: 1.4rem; align-items: flex-start; }
.u-foot__brand { gap: 2rem; }
.u-foot__brand .u-logo { width: 11rem; height: 9rem; border-radius: 1.3rem; box-shadow: 0 6px 18px rgba(0, 0, 0, .3); }
.u-copy { border-top: 1px solid rgba(255, 255, 255, .12); padding: 1.4rem 0; font-size: 1.3rem; color: #9aa6b2; }

/* ---------- Планшет ---------- */
@media (max-width: 980px) {
	#ds-content { grid-template-columns: minmax(0, 1fr); gap: 3.2rem; }
	#ds-body { grid-row: 1; }
	#ds-options-wrapper { grid-column: 1; grid-row: 2; }
	.u-mast .u-wrap { flex-wrap: wrap; gap: 2rem; }
	.u-search { flex: 1 1 100%; }
	.u-foot .u-wrap { grid-template-columns: 1fr 1fr; }
	.u-foot__about { grid-column: 1 / -1; }
}

/* ---------- Телефон ---------- */
@media (max-width: 640px) {
	.u-wrap, #ds-trail, #ds-content, #no-js-warning { padding: 0 1.6rem; }
	.u-topbar__uni { display: none; }
	.u-topbar .u-wrap { justify-content: flex-end; }
	.u-mast .u-wrap, .u-mast--home .u-wrap { padding-top: 2rem; padding-bottom: 2rem; gap: 1.6rem; }
	.u-brand { gap: 1.4rem; align-items: flex-start; }
	.u-logo { width: 9.4rem; height: 7.7rem; border-radius: 1.2rem; }
	.u-foot__brand .u-logo { width: 9.4rem; height: 7.7rem; }
	.u-brand__title { font-size: 2.1rem; }
	.u-brand__sub { font-size: 1.25rem; }
	.u-brand__sub::before { margin-bottom: .5rem; }
	.u-mast--home { min-height: 0; }
	.u-mast--home .u-brand__title { font-size: 2.3rem; }
	.u-hero-body { margin-top: 1.6rem; }
	.u-hero-lead { display: none; }
	.u-lead--mobile { display: block; }
	.u-hero-facts { margin-top: 0; gap: .6rem 2.4rem; }
	.u-hero-facts .u-fact b { font-size: 2.3rem; }
	.u-hero-facts .u-fact span { font-size: 1.15rem; }
	.u-hero-links { margin-top: 1.6rem; flex-direction: column; gap: .7rem; }
	.u-hero-links a { font-size: 1.45rem; }
	.u-search--wide { margin-top: 2rem; }
	.u-search--wide input[type="text"], .u-search--wide button { height: 4.8rem; font-size: 1.5rem; }
	.u-search--wide button { padding: 0 1.8rem; }
	.u-search input[type="text"], .u-search button { height: 4.4rem; }
	.u-search__more { display: none; }
	.u-nav a { padding: 1.1rem 1.2rem .9rem; font-size: 1.45rem; }
	#ds-content { padding: 1rem .8rem 3.2rem !important; gap: 1.2rem; }
	#ds-trail { padding-left: 1.6rem !important; padding-right: 1.6rem !important; }
	#ds-body { padding: 2.2rem 1.8rem 2.8rem !important; }
	#ds-options-wrapper { padding: 2.2rem 1.8rem .2rem !important; }
	#ds-body h1, .item-summary-view-metadata > h1 { font-size: 2.3rem !important; }
	.u-lead { font-size: 1.65rem; }
	.u-facts { grid-template-columns: 1fr 1fr; gap: 1rem; }
	.u-fact { padding: 1.2rem 1.4rem; }
	.u-fact:last-child:nth-child(odd) { grid-column: 1 / -1; }
	.u-fact b { font-size: 2.1rem; }
	#aspect_artifactbrowser_CommunityBrowser_div_comunity-browser > ul { grid-template-columns: minmax(0, 1fr); }
	.simple-item-view-other { grid-template-columns: minmax(0, 1fr); gap: .2rem; }
	.u-foot .u-wrap { grid-template-columns: minmax(0, 1fr); gap: 2.4rem; }
	#ds-body table { display: block; overflow-x: auto; }
	#ds-body table.detailtable td.label-cell { width: auto; min-width: 12rem; }
	#ds-body li.u-has-thumb { grid-template-columns: 5.6rem minmax(0, 1fr); column-gap: 1.2rem; }
}

/* ---------- Сторінка «Пошук» (discover) ---------- */
/* У темы кнопки — иконки с отступом текста; наш стиль иконку перекрыл, поэтому возвращаем текст */
#ds-main input.u-btn-text { text-indent: 0 !important; background-image: none !important; width: auto !important; min-width: 4rem; line-height: 1.2; }
#ds-main input.filter-add.u-btn-text, #ds-main input.filter-remove.u-btn-text { width: 3.8rem !important; height: 3.8rem !important; padding: 0 !important; font-size: 2rem !important; font-weight: 400; }
#ds-main input.filter-remove.u-btn-text { background: #fff !important; color: var(--u-muted) !important; border: 1px solid #c9d1da !important; }
#ds-main input.filter-remove.u-btn-text:hover { color: #b3261e !important; border-color: #b3261e !important; }
#aspect_discovery_SimpleSearch_div_search fieldset, #aspect_discovery_SimpleSearch_div_search .ds-form-list,
#aspect_discovery_SimpleSearch_div_discovery-filters-wrapper, #aspect_discovery_SimpleSearch_div_search-filters {
	border: 0 !important; background: none !important; padding: 0 !important; margin: 0 !important; box-shadow: none !important;
}
#aspect_discovery_SimpleSearch_div_search { background: var(--u-soft); border: 1px solid #e1e6ec; border-radius: 6px; padding: 2rem 2.2rem !important; margin: 0 0 2.4rem; }
#aspect_discovery_SimpleSearch_div_search .ds-form-label { font-weight: 500; color: var(--u-slate); }
#aspect_discovery_SimpleSearch_field_query.ds-text-field { min-width: 0; }
#aspect_discovery_SimpleSearch_div_search h2.ds-div-head { font-size: 1.7rem !important; margin: 2.2rem 0 .4rem !important; }
#aspect_discovery_SimpleSearch_div_search p.ds-paragraph { color: var(--u-muted); margin: 0 0 1rem; font-size: 1.4rem; }
#ds-body table.discovery-filters { border-top: 0; font-size: 1.45rem; }
#ds-body table.discovery-filters th { font-size: 1.3rem; text-transform: uppercase; letter-spacing: .06em; color: var(--u-muted); font-weight: 600; padding: 1.2rem 0 .4rem; border-bottom: 0 !important; }
#ds-body table.discovery-filters td { border-bottom: 0 !important; padding: .4rem .8rem .4rem 0; vertical-align: middle; }
#ds-body table.discovery-filters tr.apply-filter td { padding-top: 1.4rem; }
#ds-body table.discovery-filters select, #ds-body table.discovery-filters input.ds-text-field { width: 100%; background: #fff; }
#aspect_discovery_SimpleSearch_div_discovery-search-box { border: 0 !important; background: none !important; padding: 0 !important; }
#ds-body table.discovery-filters tr { border: 0 !important; }
#ds-body table.discovery-filters td.selection { width: 17rem; }
#ds-body table.discovery-filters td.filter-controls { width: 8.4rem; white-space: nowrap; }
#ds-body table.discovery-filters td.filter-controls input { display: inline-block; margin: 0 .4rem 0 0; vertical-align: middle; }
#ds-main input#aspect_discovery_SimpleSearch_field_submit_apply_filter { width: auto !important; padding: .9rem 2.4rem !important; }
#ds-body .pagination-masked { border: 0 !important; background: none !important; padding: .4rem 0 !important; }
/* «Наявність файлів» в колонці фільтрів не потрібна (узел лишається — з нього рахуються цифри на головній) */
#ds-options li.u-hide-facet { display: none !important; }

/* Время поиска «(0.05 с)» — служебное, не показываем */
#ds-body .searchTime { display: none !important; }
