.topbar {
  position: sticky;
  top: 18px;
  z-index: 50;
  width: min(1320px, calc(100% - 64px));
  height: 70px;
  margin: 18px auto 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 18px 0 22px;
  border: 1px solid rgba(142, 157, 168, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 16px 54px rgba(39, 58, 71, 0.1);
  backdrop-filter: blur(24px);
  color: #23323d;
  transition: background 220ms ease, border-color 220ms ease, box-shadow 220ms ease, color 220ms ease;
}

.topbar--sub {
  position: fixed;
  left: 50%;
  margin: 0;
  transform: translateX(-50%);
}

.brand {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 230px;
}

.brand img {
  width: 112px;
  height: 44px;
  object-fit: contain;
  transition: filter 220ms ease;
}

.brand strong {
  display: block;
  font-size: 18px;
  font-weight: 850;
  letter-spacing: 0;
  color: inherit;
}

.nav-links {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
  color: #334451;
  font-size: 14px;
  font-weight: 400;
}

.topbar > .btn {
  position: relative;
  z-index: 2;
  margin-left: auto;
}

.topbar > .btn.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-height: 46px;
  padding: 0 22px;
  border: 1px solid rgba(16, 24, 32, 0.08);
  border-radius: 999px;
  color: #fff;
  background: #101820;
  box-shadow: 0 16px 34px rgba(16, 24, 32, 0.16);
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

.nav-links a,
.nav-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  color: inherit;
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
  font-weight: inherit;
  transition: color 180ms ease, background 180ms ease;
}

.nav-links a:hover,
.nav-item:hover .nav-trigger {
  color: #1B6DE1;
  background: rgba(27, 109, 225, 0.08);
}

/* 当前页选中态 */
.nav-links a.is-active,
.nav-item.is-active .nav-trigger {
  color: #1B6DE1;
  background: rgba(27, 109, 225, 0.10);
  font-weight: 500;
}
.topbar.is-dark .nav-links a.is-active,
.topbar.is-dark .nav-item.is-active .nav-trigger {
  color: #00FFC2;
  background: rgba(0, 255, 194, 0.14);
}
.mobile-nav-drawer a.is-active {
  color: #1B6DE1;
  background: rgba(27, 109, 225, 0.08);
}
body.shared-nav-dark .mobile-nav-drawer a.is-active {
  color: #00FFC2;
  background: rgba(0, 255, 194, 0.12);
}

/* 首页顶栏 CTA 随 Ruov(深色)屏切换：默认招聘，深色态显示进入若影 */
.topbar > .btn.nav-cta-ruov { display: none; }
.topbar.is-dark > .btn.nav-cta-ruov { display: inline-flex; }
.topbar.is-dark > .btn[data-open-consult] { display: none; }

.nav-item {
  position: relative;
}

.nav-menu {
  position: absolute;
  left: 50%;
  top: calc(100% + 10px);
  width: 320px;
  padding: 12px;
  border: 1px solid rgba(68, 88, 103, 0.12);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 24px 60px rgba(39, 58, 71, 0.14);
  backdrop-filter: blur(22px);
  transform: translateX(-50%) translateY(8px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease, visibility 180ms ease;
}

.nav-item:hover .nav-menu,
.nav-item:focus-within .nav-menu {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.nav-menu a,
.nav-menu span {
  display: grid;
  gap: 4px;
  min-height: auto;
  padding: 12px;
  border-radius: 14px;
  color: #1e2f38;
  font-size: 14px;
  font-weight: 400;
  background: transparent;
}

.nav-menu a:hover {
  background: rgba(27, 109, 225, 0.08);
}

.nav-menu small {
  color: #65717a;
  font-size: 12px;
  line-height: 1.45;
  font-weight: 400;
}

.topbar.is-dark {
  color: rgba(247, 251, 255, 0.94);
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(5, 8, 12, 0.78);
  box-shadow: 0 18px 58px rgba(0, 0, 0, 0.28);
}

.topbar.is-dark .nav-links {
  color: rgba(247, 251, 255, 0.88);
}

.topbar.is-dark .brand img {
  filter: brightness(0) invert(1);
}

.topbar.is-dark .nav-links a:hover,
.topbar.is-dark .nav-item:hover .nav-trigger {
  color: #00FFC2;
  background: rgba(0, 255, 194, 0.12);
}

.topbar.is-dark > .btn.btn-primary {
  border-color: rgba(0, 255, 194, 0.64);
  color: #031110;
  background: #00FFC2;
  box-shadow: 0 16px 40px rgba(0, 255, 194, 0.2);
}

.topbar.is-dark .nav-menu {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(8, 12, 18, 0.92);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.34);
}

.topbar.is-dark .nav-menu a,
.topbar.is-dark .nav-menu span {
  color: rgba(247, 251, 255, 0.92);
}

.topbar.is-dark .nav-menu a:hover {
  background: rgba(0, 255, 194, 0.12);
}

.topbar.is-dark .nav-menu small {
  color: rgba(216, 228, 238, 0.62);
}

.mobile-menu-toggle,
.mobile-nav-backdrop,
.mobile-nav-drawer {
  display: none;
}

.mobile-menu-toggle {
  position: relative;
  z-index: 3;
  align-content: center;
  justify-items: center;
  row-gap: 5px;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid rgba(16, 24, 32, 0.08);
  border-radius: 999px;
  color: #101820;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(246, 249, 251, 0.78));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92), 0 10px 24px rgba(16, 24, 32, 0.08);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: border-color 180ms ease, background 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.mobile-menu-toggle span {
  display: block;
  width: 17px;
  height: 1.5px;
  border-radius: 999px;
  background: currentColor;
  transition: transform 180ms ease, opacity 180ms ease;
}

.mobile-menu-toggle span:nth-child(2) {
  width: 20px;
}

.mobile-menu-toggle:hover {
  border-color: rgba(16, 24, 32, 0.14);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.96), 0 12px 28px rgba(16, 24, 32, 0.1);
}

.mobile-menu-toggle:active {
  transform: scale(0.98);
}

.mobile-menu-toggle:focus-visible {
  outline: 2px solid rgba(27, 109, 225, 0.24);
  outline-offset: 3px;
}

.mobile-nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1;
  background: rgba(8, 12, 18, 0.34);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.mobile-nav-drawer {
  position: fixed;
  top: 96px;
  right: 14px;
  z-index: 4;
  width: min(360px, calc(100vw - 28px));
  padding: 12px;
  border: 1px solid rgba(68, 88, 103, 0.14);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 28px 80px rgba(16, 24, 32, 0.2);
  backdrop-filter: blur(24px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-8px);
  transition: opacity 180ms ease, transform 180ms ease, visibility 180ms ease;
}

.mobile-nav-drawer a,
.mobile-nav-drawer summary,
.mobile-nav-drawer .is-muted-link {
  display: grid;
  gap: 4px;
  min-height: 48px;
  padding: 14px;
  border-radius: 16px;
  color: #1e2f38;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.2;
  text-decoration: none;
}

.mobile-nav-drawer a:hover,
.mobile-nav-drawer summary:hover {
  color: #1B6DE1;
  background: rgba(27, 109, 225, 0.08);
}

.mobile-nav-drawer small {
  color: #65717a;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.45;
}

.mobile-nav-group {
  margin: 0;
}

.mobile-nav-group summary {
  cursor: pointer;
  list-style: none;
}

.mobile-nav-group summary::-webkit-details-marker {
  display: none;
}

.mobile-nav-group summary::after {
  content: "";
  position: absolute;
  right: 18px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-62%) rotate(45deg);
  transition: transform 180ms ease;
}

.mobile-nav-group summary {
  position: relative;
}

.mobile-nav-group[open] summary::after {
  transform: translateY(-35%) rotate(225deg);
}

.mobile-nav-group a,
.mobile-nav-group .is-muted-link {
  margin-left: 10px;
}

.mobile-nav-drawer > .btn.btn-primary {
  display: none;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 48px;
  margin-top: 10px;
  border: 1px solid rgba(16, 24, 32, 0.08);
  border-radius: 999px;
  color: #ffffff;
  background: #101820;
  box-shadow: 0 16px 34px rgba(16, 24, 32, 0.16);
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.topbar.is-mobile-open .mobile-menu-toggle span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}

.topbar.is-mobile-open .mobile-menu-toggle span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0.4);
}

.topbar.is-mobile-open .mobile-menu-toggle span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

body.mobile-nav-open .mobile-nav-backdrop {
  opacity: 1;
  pointer-events: auto;
}

body.mobile-nav-open .mobile-nav-drawer {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.topbar.is-dark .mobile-menu-toggle {
  border-color: rgba(255, 255, 255, 0.18);
  color: rgba(247, 251, 255, 0.94);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.055));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 12px 28px rgba(0, 0, 0, 0.22);
}

body.shared-nav-dark .mobile-nav-backdrop {
  background: rgba(0, 0, 0, 0.56);
}

body.shared-nav-dark .mobile-nav-drawer {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(8, 12, 18, 0.94);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.38);
}

body.shared-nav-dark .mobile-nav-drawer a,
body.shared-nav-dark .mobile-nav-drawer summary,
body.shared-nav-dark .mobile-nav-drawer .is-muted-link {
  color: rgba(247, 251, 255, 0.92);
}

body.shared-nav-dark .mobile-nav-drawer a:hover,
body.shared-nav-dark .mobile-nav-drawer summary:hover {
  color: #00FFC2;
  background: rgba(0, 255, 194, 0.12);
}

body.shared-nav-dark .mobile-nav-drawer small {
  color: rgba(216, 228, 238, 0.62);
}

body.shared-nav-dark .mobile-nav-drawer > .btn.btn-primary {
  border-color: rgba(0, 255, 194, 0.64);
  color: #031110;
  background: #00FFC2;
  box-shadow: 0 16px 40px rgba(0, 255, 194, 0.2);
}

.is-muted-link {
  opacity: 0.62;
  cursor: default;
}

.shared-consult-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: none;
  place-items: center;
  padding: 24px;
}

.shared-consult-modal.is-open {
  display: grid;
}

.shared-consult-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 12, 18, 0.46);
  backdrop-filter: blur(12px);
}

.shared-consult-dialog {
  position: relative;
  z-index: 1;
  width: min(520px, 100%);
  padding: 30px;
  border: 1px solid rgba(68, 88, 103, 0.16);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 28px 90px rgba(16, 24, 32, 0.22);
}

.shared-consult-close {
  position: absolute;
  right: 18px;
  top: 18px;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(68, 88, 103, 0.12);
  border-radius: 999px;
  color: #42525c;
  background: #ffffff;
  cursor: pointer;
}

.shared-consult-dialog h3 {
  margin: 0;
  color: #111a22;
  font-size: 28px;
  line-height: 1.2;
}

.shared-consult-dialog > p {
  margin: 12px 0 0;
  color: #65717a;
  line-height: 1.7;
}

.shared-consult-form {
  display: grid;
  gap: 14px;
  margin-top: 22px;
}

.shared-consult-field {
  display: grid;
  gap: 8px;
}

.shared-consult-field label {
  color: #26343d;
  font-size: 13px;
  font-weight: 850;
}

.shared-consult-field input,
.shared-consult-field textarea {
  width: 100%;
  border: 1px solid rgba(68, 88, 103, 0.16);
  border-radius: 14px;
  color: #101820;
  background: rgba(247, 250, 251, 0.92);
  outline: none;
}

.shared-consult-field input {
  height: 46px;
  padding: 0 14px;
}

.shared-consult-field textarea {
  min-height: 108px;
  padding: 13px 14px;
  line-height: 1.6;
  resize: vertical;
}

.shared-consult-form .btn {
  width: 100%;
  min-height: 46px;
  border-color: rgba(16, 24, 32, 0.08);
  color: #ffffff;
  background: #101820;
}

.shared-consult-message {
  min-height: 22px;
  margin: 0;
  color: #1B6DE1;
  font-size: 13px;
}

body.modal-open {
  overflow: hidden;
}

@media (max-width: 1024px) {
  .topbar {
    width: calc(100% - 28px);
    height: 64px;
    top: 12px;
    margin-top: 12px;
    padding: 0 10px 0 14px;
    gap: 10px;
  }

  .topbar.topbar--sub {
    left: 14px;
    right: 14px;
    width: auto;
    transform: none;
  }

  .nav-links {
    display: none;
  }

  .brand {
    min-width: 0;
    flex: 1 1 auto;
    gap: 10px;
    overflow: hidden;
  }

  .brand img {
    width: 104px;
    height: 40px;
    flex: 0 0 auto;
  }

  .brand strong {
    overflow: hidden;
    font-size: 16px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .topbar > .btn.btn-primary {
    min-height: 42px;
    padding: 0 15px;
    font-size: 13px;
  }

  .mobile-menu-toggle {
    display: grid;
    flex: 0 0 auto;
  }

  .mobile-nav-backdrop,
  .mobile-nav-drawer {
    display: block;
  }
}

@media (max-width: 520px) {
  .topbar {
    width: calc(100% - 20px);
    height: 58px;
    top: 10px;
    margin-top: 10px;
    padding: 0 8px 0 12px;
  }

  .topbar.topbar--sub {
    left: 10px;
    right: 10px;
  }

  .brand img {
    width: 92px;
    height: 36px;
  }

  .brand strong {
    display: none;
  }

  .topbar > .btn.btn-primary {
    min-height: 38px;
    padding: 0 12px;
    font-size: 12px;
  }

  .mobile-menu-toggle {
    width: 40px;
    height: 40px;
  }

  .mobile-nav-drawer {
    top: 86px;
    right: 10px;
    width: calc(100vw - 20px);
    border-radius: 22px;
  }
}

@media (max-width: 380px) {
  .topbar > .btn.btn-primary {
    display: none;
  }

  .mobile-nav-drawer > .btn.btn-primary {
    display: inline-flex;
  }
}

body.mobile-nav-open {
  overflow: hidden;
}
