/* Společné responzivní opravy hlavičky, menu, úvodů a paty webu. */
.top-bar__shortcuts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 34px;
  min-height: 48px;
  align-items: center;
  justify-content: flex-start;
}

.top-bar__shortcut {
  display: flex;
  gap: 9px;
  min-width: 0;
  align-items: center;
  padding: 7px 0;
  color: rgba(255,255,255,.88);
  font-weight: 700;
  text-decoration: none;
  transition: color .2s ease, opacity .2s ease;
}

.top-bar__shortcut:hover,
.top-bar__shortcut:focus { color: #fff; text-decoration: none; opacity: .82; }
.top-bar__shortcut .icon-header {
  display: inline-flex;
  width: 31px;
  height: 31px;
  flex: 0 0 31px;
  align-items: center;
  justify-content: center;
  margin: 0;
  border-radius: 50%;
  color: #fff;
}

.mobile-submenu-toggle {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: inherit;
  text-align: left;
  pointer-events: none;
}

.mobile-submenu-toggle::after { display: none; }

/* Přímé odkazy vypadají stejně jako rozbalovací položky, ale nemají šipku. */
.navbar-nav > .nav-item > .nav-link.nav-link-direct span {
  display: inline-block;
  font-weight: 600;
  line-height: 1rem;
}

.navbar-nav > .nav-item > .nav-link.nav-link-direct:not(.active) span {
  color: #000;
}

/* Přihlášení je vlevo na stejné úrovni jako vycentrovaný copyright. */
.footer-bg-img > .copyright .footer-copyright-row {
  position: relative;
  display: flex;
  min-height: 54px;
  align-items: center;
  justify-content: center;
}

.footer-login-link {
  position: absolute;
  left: 12px;
  display: inline-flex;
  gap: 9px;
  align-items: center;
  color: rgba(255,255,255,.9);
  font-weight: 700;
  text-transform: uppercase;
}

.footer-login-link:hover,
.footer-login-link:focus { color: #f0c24b; text-decoration: none; }
.footer-login-link i { color: #f0c24b; }
.footer-privacy-link {
  position: absolute;
  /* Volné místo vpravo ponechává odstup od plovoucí šipky nahoru. */
  right: 88px;
  display: inline-flex;
  gap: 9px;
  align-items: center;
  color: rgba(255,255,255,.9);
  font-weight: 700;
  text-transform: uppercase;
}
.footer-privacy-link:hover,
.footer-privacy-link:focus { color: #f0c24b; text-decoration: none; }
.footer-privacy-link i { color: #f0c24b; }
.footer-copyright-center { width: 100%; text-align: center; }
.footer-copyright-center .copyright-text { margin: 0; text-align: center !important; }

@media (min-width: 768px) and (max-width: 1199.98px) {
  .top-bar .container { max-width: 100%; padding-inline: 14px; }
  .top-bar__shortcuts { gap: 6px 22px; }
  .top-bar__shortcut { gap: 7px; font-size: 12px; }
  .top-bar .icon-header { width: 27px; height: 27px; min-width: 27px; margin: 0 !important; }

  /* Pátá a šestá bublina mají na tabletu stejnou polovinu řádku. */
  section.pt-9.pb-6.py-md-7 > .container > .row > div:nth-child(5) { width: 50%; }
}

@media (max-width: 767.98px) {
  /* Při přetažení stránky za footer telefon ukáže barvu kořene dokumentu. */
  html { background-color: #041319; }

  .top-bar .container { padding-inline: 0; }
  .top-bar__shortcuts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; padding: 4px 13px; }
  .top-bar__shortcut { justify-content: flex-start; padding: 7px 0; font-size: 12px; }
  .top-bar__shortcut .icon-header { width: 27px; height: 27px; min-width: 27px; }

  .footer-bg-img > .copyright .footer-copyright-row {
    min-height: 0;
    flex-direction: column;
    gap: 9px;
    padding: 14px 0;
  }
  .footer-login-link,
  .footer-privacy-link { position: static; }

  .navbar-nav > .nav-item > .nav-link:not([data-bs-toggle="dropdown"])::after { display: none !important; }

  .mega-dropdown > .dropdown-menu {
    padding: 0 12px 12px;
  }
  .mega-dropdown > .dropdown-menu > [class*="col-"] {
    padding: 0;
  }
  .mega-dropdown > .dropdown-menu > [class*="col-"] > ul {
    margin: 4px 0;
    border: 1px solid rgba(255,255,255,.28);
    border-radius: 8px;
    overflow: hidden;
  }
  .mega-dropdown > .dropdown-menu > [class*="col-"] > ul > li:first-child {
    margin: 0;
    padding: 0;
  }
  .mobile-submenu-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    cursor: pointer;
    pointer-events: auto;
  }
  .mobile-submenu-toggle::after {
    display: block;
    width: 8px;
    height: 8px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    content: "";
    transform: rotate(45deg);
    transition: transform .2s ease;
  }
  .mobile-submenu-open .mobile-submenu-toggle::after { transform: rotate(225deg); }
  .mega-dropdown > .dropdown-menu > [class*="col-"] > ul > li:not(:first-child) { display: none; }
  .mega-dropdown > .dropdown-menu > [class*="col-"] > ul.mobile-submenu-open > li:not(:first-child) { display: block; }
  .mega-dropdown .dropdown-item { white-space: normal; }

  .footer-bg-img .pt-8.pb-7 .row > [class*="col-"] {
    width: 100%;
    text-align: center;
  }
  .footer-bg-img .pt-8.pb-7 .row > div:first-child img { width: 37.5% !important; max-width: 170px; }
  .footer-bg-img .pt-8.pb-7 .row > div:first-child a { margin-bottom: 28px !important; }
  .footer-bg-img .pt-8.pb-7 .row > div:nth-child(2),
  .footer-bg-img .pt-8.pb-7 .row > div:nth-child(3) { margin-bottom: 34px; }
  .footer-bg-img .hz-latest-compact {
    width: min(100%, 330px);
    margin-right: auto;
    margin-left: auto;
    text-align: left;
  }
  .footer-bg-img .hz-latest-item { text-align: left; }
  .footer-bg-img .copyright-text { text-align: center; }

  .contacts-people-section .section-title,
  .open-day-intro__copy,
  .enrollment-intro__copy,
  .krouzky-intro,
  .dining-intro-copy,
  .parliament-team .section-title { text-align: center !important; }

  .contacts-people-section .section-title,
  .parliament-team .section-title { justify-content: center !important; }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-submenu-toggle::after { transition: none; }
}

