/**
 * Homepage + global sticky quick-actions bar (bottom).
 * Uses body.cp-sticky-quickbar (all pages) or body.cp-home-sticky-quickbar (legacy).
 */

.mobile-sticky-menu {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  box-sizing: border-box;
  z-index: 65;
  display: flex;
  gap: 0.35rem;
  background: rgba(255, 253, 248, 0.98);
  border-top: 2px solid rgba(20, 18, 42, 0.08);
  box-shadow: 0 -8px 24px rgba(20, 18, 42, 0.12);
  padding: 0.55rem 0.65rem calc(0.55rem + env(safe-area-inset-bottom, 0px));
}

.mobile-sticky-menu a {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.28rem;
  text-decoration: none;
  text-align: center;
  font-size: clamp(0.56rem, 2.65vw, 0.72rem);
  font-weight: 700;
  color: var(--ink-muted);
  border-radius: 12px;
  padding: 0.5rem 0.22rem;
}

/* Keep each label on a single line (no wrapping under icons on narrow phones). */
.mobile-sticky-menu a > span {
  white-space: nowrap;
  line-height: 1.15;
  max-width: 100%;
}

.mobile-sticky-menu a .icon {
  width: 18px;
  height: 18px;
}

.mobile-sticky-menu a:hover {
  background: rgba(20, 18, 42, 0.06);
}

.mobile-sticky-menu .center {
  background: var(--accent-primary);
  color: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(108, 92, 231, 0.32);
  transition: background 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.mobile-sticky-menu .center:hover {
  background: var(--accent-primary-dark, #5a4bd1);
  color: #fff;
  box-shadow: 0 10px 26px rgba(108, 92, 231, 0.46);
  transform: translateY(-1px);
}

body.cp-home-sticky-quickbar,
body.cp-sticky-quickbar {
  padding-bottom: 100px;
}

@media (min-width: 992px) {
  .mobile-sticky-menu {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: min(980px, calc(100vw - 2.5rem));
    gap: 0.6rem;
    padding: 0.75rem 1rem;
    border: 1px solid rgba(20, 18, 42, 0.14);
    border-radius: 16px 16px 0 0;
    background: rgba(255, 253, 248, 0.98);
    backdrop-filter: blur(6px);
    box-shadow: 0 -10px 34px rgba(20, 18, 42, 0.2);
  }

  .mobile-sticky-menu a {
    flex: 1 1 auto;
    flex-direction: row;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.88rem;
    line-height: 1.15;
    padding: 0.78rem 0.7rem;
    border: 1px solid rgba(20, 18, 42, 0.08);
    background: rgba(255, 255, 255, 0.75);
  }

  .mobile-sticky-menu a .icon {
    width: 20px;
    height: 20px;
  }

  .mobile-sticky-menu a:hover {
    background: rgba(20, 18, 42, 0.08);
    border-color: rgba(20, 18, 42, 0.16);
  }

  .mobile-sticky-menu .center {
    border-color: transparent;
    box-shadow: 0 10px 22px rgba(108, 92, 231, 0.34);
  }

  .mobile-sticky-menu .center:hover {
    background: var(--accent-primary-dark, #5a4bd1);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 12px 28px rgba(108, 92, 231, 0.5);
    transform: translateY(-1px);
  }

  body.cp-home-sticky-quickbar,
  body.cp-sticky-quickbar {
    padding-bottom: 132px;
  }
}
