/* ===========================================================================
   Domov Lienka — Visual polish
   Loaded after nicepage.css and per-page CSS.
   Pure additive CSS — no overrides that would break existing layout.
   =========================================================================== */

/* (5) Smooth anchor scrolling site-wide */
html {
  scroll-behavior: smooth;
}

/* (1) Sticky header — subtle backdrop blur + soft shadow */
header.u-header.u-sticky,
.u-header.u-sticky {
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  background-color: rgba(255, 255, 255, 0.85) !important;
  box-shadow: 0 1px 10px rgba(31, 58, 95, 0.07);
  transition: box-shadow 0.3s ease, background-color 0.3s ease;
}

/* (2) Buttons — hover lift + soft shadow.
   Targets only .u-btn (real buttons), not nav links / accordion / hamburger. */
.u-btn {
  transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1),
              box-shadow 0.2s ease,
              background-color 0.2s ease,
              border-color 0.2s ease,
              color 0.2s ease;
}
.u-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(31, 58, 95, 0.18);
}
.u-btn:active {
  transform: translateY(0);
  box-shadow: 0 3px 10px rgba(31, 58, 95, 0.15);
}

/* (3) FAQ accordion — soft card with hover shadow + smooth transitions */
.u-accordion-item {
  border-radius: 10px;
  margin-bottom: 12px;
  box-shadow: 0 2px 8px rgba(31, 58, 95, 0.06);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
  overflow: hidden;
}
.u-accordion-item:hover {
  box-shadow: 0 6px 18px rgba(31, 58, 95, 0.12);
  transform: translateY(-1px);
}
.u-accordion-link {
  transition: background-color 0.2s ease, color 0.2s ease;
}
.u-accordion-pane {
  transition: opacity 0.3s ease;
}

/* (4) Image hover zoom — for gallery / list / repeater photos.
   Excludes the logo. */
.u-list .u-image:not(.u-logo),
.u-repeater .u-image:not(.u-logo),
.u-list-item .u-image:not(.u-logo) {
  overflow: hidden;
}
.u-list .u-image:not(.u-logo) img,
.u-repeater .u-image:not(.u-logo) img,
.u-list-item .u-image:not(.u-logo) img {
  transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
  display: block;
}
.u-list .u-image:not(.u-logo):hover img,
.u-repeater .u-image:not(.u-logo):hover img,
.u-list-item .u-image:not(.u-logo):hover img {
  transform: scale(1.05);
}

/* Bonus: keyboard focus rings (a11y) */
:focus-visible {
  outline: 2px solid #478ac9;
  outline-offset: 3px;
  border-radius: 2px;
}
.u-btn:focus-visible {
  outline-offset: 5px;
}

/* Bonus: respect users who prefer reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .u-btn:hover,
  .u-accordion-item:hover {
    transform: none !important;
  }
  .u-list .u-image:hover img,
  .u-repeater .u-image:hover img {
    transform: none !important;
  }
}

/* ===========================================================================
   Branch quick-nav — floating bottom-right pill bar
   Appears only on branch pages (Levice / Záhonok). Branch-specific links
   so users can jump between Úvod / Dokumenty / Kontakt of the same branch.
   =========================================================================== */
.dl-quicknav {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 9990;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-family: 'Montserrat', sans-serif;
}
.dl-qn-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  background-color: #478ac9;
  color: #ffffff !important;
  text-decoration: none !important;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.2px;
  box-shadow: 0 4px 14px rgba(31, 58, 95, 0.25);
  transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1),
              background-color 0.2s ease,
              box-shadow 0.2s ease;
  white-space: nowrap;
}
.dl-qn-btn:hover {
  background-color: #3a72a8;
  color: #ffffff !important;
  transform: translateX(-4px);
  box-shadow: 0 8px 20px rgba(31, 58, 95, 0.32);
}
.dl-qn-btn:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 2px;
}
.dl-qn-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  fill: currentColor;
}

@media (max-width: 600px) {
  .dl-quicknav {
    right: 12px;
    bottom: 12px;
    gap: 6px;
  }
  .dl-qn-btn {
    padding: 0;
    width: 46px;
    height: 46px;
    justify-content: center;
    border-radius: 50%;
  }
  .dl-qn-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
  .dl-qn-icon {
    width: 18px;
    height: 18px;
  }
}

@media print {
  .dl-quicknav {
    display: none;
  }
}

/* ===========================================================================
   Mobile menu polish — branch contact card + nicer item styling
   =========================================================================== */

/* Full-screen mobile menu — covers the whole viewport so nothing is hidden.
   IMPORTANT: only when menu is `.open` — otherwise the fixed full-screen
   overlay would block clicks on the hamburger button itself. */
@media (max-width: 1199px) {
  .u-menu.open .u-nav-container-collapse {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    z-index: 9999 !important;
  }
  /* When menu is closed, the container must not intercept any clicks */
  .u-menu:not(.open) .u-nav-container-collapse {
    pointer-events: none;
  }
  .u-menu.open .u-nav-container-collapse .u-menu-active-mask,
  .u-menu.open .u-nav-container-collapse .u-menu-overlay {
    height: 100vh !important;
    height: 100dvh !important;
  }
  .u-menu.open .u-nav-container-collapse .u-sidenav,
  .u-nav-container-collapse .u-sidenav {
    width: 100vw !important;
    max-width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    border-radius: 0 !important;
  }
  .u-nav-container-collapse .u-sidenav-overflow,
  .u-sidenav .u-inner-container-layout {
    width: 100% !important;
    height: 100vh !important;
    height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 16px 12px 20px 12px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }
  /* Close button — clearly visible top right */
  .u-menu-close.u-menu-close-1 {
    position: absolute !important;
    top: 14px !important;
    right: 14px !important;
    z-index: 10;
  }
}

/* Logo at the top center of the mobile menu */
.dl-mobile-logo {
  text-align: center;
  padding: 4px 12px 14px 12px;
  margin: 0;
}
.dl-mobile-logo img {
  display: inline-block;
  max-width: 180px;
  width: 60vw;
  height: auto;
  background-color: #ffffff;
  padding: 8px 14px;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

/* Branch contact card at the top of the hamburger menu — compact */
.dl-mobile-branch {
  margin: 4px 10px 10px 10px;
  padding: 10px 12px;
  background: linear-gradient(135deg, #478ac9 0%, #3a72a8 100%);
  border-radius: 10px;
  color: #ffffff;
  text-align: left;
  box-shadow: 0 4px 12px rgba(31, 58, 95, 0.18);
  font-family: 'Montserrat', sans-serif;
}
.dl-mobile-branch-eyebrow {
  display: none;
}
.dl-mobile-branch-name {
  font-size: 0.85rem;
  font-weight: 700;
  margin: 0 0 8px 0;
  line-height: 1.2;
  text-align: center;
}
.dl-mobile-branch-actions {
  display: flex;
  flex-direction: row;
  gap: 6px;
}
.dl-mobile-branch-action {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #ffffff !important;
  text-decoration: none !important;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 7px 6px;
  background-color: rgba(255, 255, 255, 0.16);
  border-radius: 6px;
  transition: background-color 0.2s ease;
  min-width: 0;
}
.dl-mobile-branch-action:hover,
.dl-mobile-branch-action:focus-visible {
  background-color: rgba(255, 255, 255, 0.28);
  color: #ffffff !important;
}
.dl-mobile-branch-action span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.dl-mobile-branch-action svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
  flex-shrink: 0;
}

/* Tighter mobile menu items — fits more on screen, still tap-friendly */
.u-popupmenu-items {
  padding: 0 8px !important;
}
.u-popupmenu-items > .u-nav-item > .u-nav-link {
  display: block !important;
  text-align: center !important;
  padding: 9px 14px !important;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.1px;
  transition: background-color 0.2s ease;
}
.u-popupmenu-items > .u-nav-item > .u-nav-link:hover,
.u-popupmenu-items > .u-nav-item > .u-nav-link:focus-visible {
  background-color: rgba(255, 255, 255, 0.14);
}
.u-popupmenu-items .u-nav-popup .u-nav-link {
  display: block !important;
  text-align: center !important;
  padding: 6px 14px !important;
  border-radius: 6px;
  font-size: 0.84rem;
  opacity: 0.88;
  transition: background-color 0.2s ease, opacity 0.2s ease;
}
.u-popupmenu-items .u-nav-popup .u-nav-link:hover,
.u-popupmenu-items .u-nav-popup .u-nav-link:focus-visible {
  background-color: rgba(255, 255, 255, 0.12);
  opacity: 1;
}

/* Force submenu always visible in mobile menu so all items are tappable.
   Without this, nicepage JS toggles them and tapping the parent hides them. */
@media (max-width: 1199px) {
  .u-popupmenu-items .u-nav-popup,
  .u-popupmenu-items .u-nav-popup.fake,
  .u-popupmenu-items .u-nav-popup .u-nav {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    position: static !important;
    transform: none !important;
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
    background: transparent !important;
    box-shadow: none !important;
    margin: 4px 0 8px 0 !important;
  }
  /* Make the parent (Levice / Záhonok) header stand out a touch */
  .u-popupmenu-items > .u-nav-item > .u-nav-link[aria-haspopup="true"] {
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    opacity: 0.85;
    pointer-events: none; /* parent label is not a link, just a section header */
    cursor: default;
  }
}
