/* Canonical nav visual identity. Owned by the landing design language;
   linked by both the static marketing pages and the /app Expo export
   (via app/+html.tsx). Positioning (sticky vs fixed) is intentionally NOT
   set here: each surface provides its own outer .topbar position wrapper. */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 30px;
  background: rgba(249,244,238,.9);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  box-shadow: 0 6px 24px rgba(26,20,15,.12);
}
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; flex-shrink: 0; }
.topbar__logo { height: 48px; width: auto; display: block; }
.wordmark { font-weight: 900; font-size: 22px; letter-spacing: -0.5px; color: var(--primary-dark); text-decoration: none; }
.nav { display: flex; align-items: center; gap: 26px; flex: 1; margin-left: 32px; }
.nav__link { font-weight: 800; font-size: 15px; color: var(--primary); text-decoration: none; }
.nav__link:hover { color: var(--primary-dark); }
.nav__cta { font-weight: 800; font-size: 15px; color: var(--primary); text-decoration: none; margin-left: auto; }
.nav__cta:hover { color: var(--primary-dark); }
.nav-toggle { display: none; }
.nav-burger { display: none; }

/* Account chip (shown when signed in; markup added by nav-session.js on the
   landing and by WebTopbar in the app). */
.account-chip {
  display: flex; align-items: center; gap: 8px;
  background: var(--surface, #fff);
  border: 1px solid var(--border, #e8ddd3);
  border-radius: 999px;
  padding: 5px 14px 5px 6px;
  font-weight: 700; font-size: 13px; color: var(--text-secondary, #6b6257);
  white-space: nowrap; cursor: pointer; margin-left: auto; flex-shrink: 0;
}
.account-chip:hover { background: var(--border-light, #f2ece5); }
.account-chip .avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 12px;
}

@media (max-width: 640px) {
  .topbar { padding: 12px 18px; }
  .wordmark { font-size: 18px; }
  .topbar__logo { height: 38px; }
  .nav-burger {
    display: inline-flex; flex-direction: column; justify-content: center; align-items: center;
    gap: 5px; width: 44px; height: 44px; cursor: pointer; flex-shrink: 0;
  }
  .nav-burger span { display: block; width: 24px; height: 2.5px; background: var(--primary); border-radius: 2px; transition: transform .25s ease, opacity .2s ease; }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0; margin-left: 0;
    background: rgba(249,244,238,.98);
    backdrop-filter: saturate(160%) blur(14px);
    -webkit-backdrop-filter: saturate(160%) blur(14px);
    box-shadow: 0 10px 24px rgba(26,20,15,.16);
    border-top: 1px solid rgba(232,221,211,.6);
    padding: 6px 0; display: none;
  }
  .nav-toggle:checked ~ .nav { display: flex; }
  .nav__link, .nav__cta { padding: 15px 22px; margin-left: 0; font-size: 16px; }
  .nav-toggle:checked ~ .nav-burger span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  .nav-toggle:checked ~ .nav-burger span:nth-child(2) { opacity: 0; }
  .nav-toggle:checked ~ .nav-burger span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
}
