/* =========================================================================
   WordPress-сумісність для conference.css.

   conference.css — це копія prototype/shared/style.css БЕЗ ЗМІН, щоб прототип
   лишався єдиним джерелом істини. Усе, що потрібне саме всередині WordPress,
   лежить тут. Перезаливати після кожної правки прототипу: tools/sync-assets.sh
   ========================================================================= */

/* ---------- Адмінбар: липке меню не має ховатися під ним ---------- */
body.admin-bar .nav { top: 32px; }

@media screen and (max-width: 782px) {
  body.admin-bar .nav { top: 46px; }
  body.admin-bar .menu { top: 116px; }
}

/* ---------- Повернення на сайт кафедри ----------
   У прототипі цього посилання немає (він автономний) — воно потрібне тільки
   тоді, коли конференція живе всередині сайту кафедри. Тому стилі тут. */
.conf-back { white-space: nowrap; }
.conf-back__arrow { display: inline-block; margin-right: 7px; transition: transform .15s; }
.conf-back:hover .conf-back__arrow { transform: translateX(-3px); }

.topbar .conf-back { font-weight: 600; }
.topbar .conf-back__sep { opacity: .45; margin: 0 4px; }

.footer__back { margin-top: 16px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.12); }

/* ---------- Головний контейнер контенту ---------- */
.conf-main { display: block; }
.conf-main > .section:first-child,
.conf-main > .hero:first-child { margin-top: 0; }

/* ---------- Посилання «до контенту» ---------- */
.conf-skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--accent); color: #fff; padding: 10px 18px; border-radius: 0 0 8px 0;
}
.conf-skip:focus { left: 0; }

/* ---------- Медіа з бібліотеки WordPress ---------- */
.conf-main img,
.conf-main iframe,
.conf-main video { max-width: 100%; height: auto; }

.conf-main figure { margin: 0 0 1rem; }
.conf-main figcaption { color: var(--muted); font-size: .88rem; }

/* Класи вирівнювання ядра WordPress — щоб редактор не «розʼїжджався». */
.conf-main .alignwide,
.conf-main .alignfull { max-width: none; }
.conf-main .aligncenter { margin-left: auto; margin-right: auto; display: block; }
.conf-main .alignleft { float: left; margin: 0 1.5rem 1rem 0; }
.conf-main .alignright { float: right; margin: 0 0 1rem 1.5rem; }
.conf-main .screen-reader-text {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); white-space: nowrap;
}

/* Блоки ядра, які редактор може лишити в контенті без обгортки .container. */
.conf-main > p,
.conf-main > h1, .conf-main > h2, .conf-main > h3, .conf-main > h4,
.conf-main > ul, .conf-main > ol, .conf-main > figure, .conf-main > table {
  max-width: var(--maxw);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* ---------- TranslatePress ----------
   Сторінки конференції англомовні й української версії не мають, тому
   плаваючий перемикач мов на них ховаємо. Клас conf-no-translate ставиться
   тільки коли в конфігурації увімкнено 'no_translate'.
   Селектори покривають і нове іменування (TranslatePress 3.2+), і старе. */
body.conf-no-translate .trp-floating-switcher,
body.conf-no-translate #trp-floater-ls,
body.conf-no-translate .trp-floater-ls,
body.conf-no-translate .trp-floater-ls-shortcode { display: none !important; }

/* Якщо перемикач усе ж вирішать лишити — щоб він виглядав доречно у смужці. */
.topbar .trp-language-switcher-container,
.topbar .trp_language_switcher_shortcode { display: inline-block; vertical-align: middle; }
.topbar .trp-language-switcher-container a { color: #fff; }

/* ---------- Друк ---------- */
@media print {
  .topbar, .nav, .footer, .conf-skip, #wpadminbar { display: none !important; }
  .hero { background: none !important; color: var(--ink) !important; padding: 0 0 24px; }
  .hero h1, .hero .lead { color: var(--ink) !important; }
  .section { padding: 18px 0; }
}
