/* ===============================
   CandyCloud – Top Navigation Bar
================================ */

.cc-topbar {
  /* Match CandyCloud "dark glass" header language (with fallbacks) */
  background: var(--accent-gradient, linear-gradient(135deg, #FF2F92 0%, #C77DFF 100%));
  color: #ffffff;
  font-size: 13px;
  line-height: 1;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: var(--shadow-sm, 0 2px 8px rgba(0, 0, 0, 0.3));
  position: relative;
  z-index: 99999; /* keep above custom sticky header if it overlaps */
}
  
  .cc-topbar__inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg, 24px);
    min-height: 44px; /* matches your nav system token */
  
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--spacing-md, 16px);
  }
  
  .cc-topbar__link {
    color: rgba(255, 255, 255, 0.92);
    text-decoration: none;
    font-weight: 500;
    opacity: 0.95;
    white-space: nowrap;
    letter-spacing: 0.2px;
    padding: 6px 12px;
    border-radius: 8px;
    transition: var(--transition-base, 0.3s cubic-bezier(0.4, 0, 0.2, 1));
  }
  
  .cc-topbar__link:hover {
    opacity: 1;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
    box-shadow:
      inset 0 0 0 1px rgba(255, 255, 255, 0.18),
      0 6px 16px rgba(0, 0, 0, 0.18);
    transform: translateY(-1px);
  }

  .cc-topbar__link:focus-visible {
    outline: 2px solid var(--accent-primary, #FF2F92);
    outline-offset: 3px;
  }

  .cc-topbar__link:active {
    transform: translateY(0);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
  }
  
  .cc-topbar__left,
  .cc-topbar__right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
  }
  
  .cc-topbar__sep {
    color: rgba(255, 255, 255, 0.75);
    opacity: 0.75;
    padding: 0 2px;
    user-select: none;
  }

  /* Subtle separators between right-side links (no extra HTML needed) */
  .cc-topbar__right .cc-topbar__link {
    /* Keep the same hit-area/hover pill as other links */
    padding: 6px 12px;
    position: relative;
  }

  .cc-topbar__right .cc-topbar__link:not(:first-child)::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 14px;
    background: rgba(255, 255, 255, 0.35);
  }
  
  /* Mobile */
  @media (max-width: 768px) {
    /* Hide the topbar on phones (move these links into hamburger menu instead) */
    .cc-topbar {
      display: none;
    }

    .cc-topbar__inner {
      flex-direction: column;
      gap: 8px;
      text-align: center;
      padding: 8px var(--spacing-sm, 8px);
    }

    .cc-topbar__left,
    .cc-topbar__right {
      justify-content: center;
    }
  }

  @media (prefers-reduced-motion: reduce) {
    .cc-topbar__link {
      transition-duration: 0.01ms !important;
    }
  }
