.facility-topbar {
  position: relative;
  z-index: 60;
  width: 100%;
  height: 48px;
  flex: none;
  border-bottom: 1px solid #e5e5e5;
  background: rgba(255, 255, 255, .86);
  color: #212121;
  backdrop-filter: blur(12px);
}

.dark .facility-topbar {
  border-color: #525252 !important;
  background: rgba(58, 58, 58, .88) !important;
  color: #fafafa;
}

.facility-header-inner {
  width: 100%;
  height: 100%;
  margin: 0 auto;
  padding: 0 12px;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: minmax(270px, 1fr) auto minmax(270px, 1fr);
  align-items: center;
  gap: 16px;
}

.facility-header-left,
.facility-header-center,
.facility-header-actions {
  min-width: 0;
  display: flex;
  align-items: center;
}

.facility-header-left {
  justify-self: start;
  gap: 8px;
}

.facility-header-left .en-product-menu {
  transform: translateY(3px);
}

.facility-header-center {
  justify-self: center;
}

.facility-header-actions {
  justify-self: end;
  gap: 3px;
}

.facility-view-nav {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px;
  border: 1px solid #e2e2e2;
  border-radius: 7px;
  background: #f1f1f1;
}

.facility-view-nav button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 74px;
  height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: 5px;
  color: #606060;
  background: transparent;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  transition: color .15s ease, background-color .15s ease, box-shadow .15s ease;
}

.facility-view-nav-icon {
  width: 16px;
  height: 16px;
  flex: none;
}

.facility-view-nav button:hover,
.facility-view-nav button.is-active {
  color: #202020;
  background: #fff;
}

.facility-view-nav button.is-active {
  box-shadow: 0 1px 2px rgba(32, 32, 32, .08);
}

.dark .facility-view-nav {
  border-color: #3f3f46;
  background: #27272a;
}

.dark .facility-view-nav button {
  color: #a1a1aa;
}

.dark .facility-view-nav button:hover,
.dark .facility-view-nav button.is-active {
  color: #fafafa;
  background: #3f3f46;
}

.en-product-menu {
  position: relative;
  min-width: 0;
  height: auto;
  margin: 0;
  flex: none;
  color: var(--ink, #212121);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.en-product-menu > summary { list-style: none; }
.en-product-menu > summary::-webkit-details-marker { display: none; }

.en-product-trigger,
.en-product-trigger:hover,
.en-product-trigger:active {
  min-width: 0;
  margin: 0;
  padding: 0;
  display: inline-flex;
  align-items: center;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.en-product-trigger:focus-visible {
  outline: 2px solid rgba(247, 169, 23, .55);
  outline-offset: 3px;
}

.en-product-trigger img {
  width: 20px;
  height: 27px;
  margin-right: 10px;
  object-fit: contain;
}

.en-product-brand {
  color: inherit;
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
}

.en-product-name {
  margin-left: 9px;
  padding-left: 9px;
  overflow: hidden;
  border-left: 1px solid rgba(33, 33, 33, .12);
  color: var(--muted, #737373);
  font-size: 13px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.en-product-popover {
  position: absolute;
  top: calc(100% + 15px);
  left: 0;
  z-index: 100;
  width: 225px;
  padding: 7px;
  border: 1px solid var(--line, #e5e5e5);
  border-radius: 8px;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 16px 38px rgba(32, 32, 32, .14);
  color: var(--ink, #212121);
  backdrop-filter: blur(12px);
}

.en-popover-label {
  display: block;
  padding: 6px 9px 5px;
  color: var(--muted, #737373);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
}

.en-product-popover a,
.en-popover-current {
  min-height: 36px;
  padding: 7px 9px;
  display: flex;
  align-items: center;
  gap: 9px;
  border-radius: 5px;
  color: inherit;
  font-size: 13px;
  line-height: 1.2;
  text-decoration: none;
}

.en-product-popover a:hover {
  background: var(--surface-muted, #f1f1f1);
  text-decoration: none;
}

.en-product-popover svg {
  width: 18px;
  height: 18px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.en-popover-current {
  color: var(--muted, #6f6f6f);
  background: var(--surface-muted, #f1f1f1);
}

.en-current-mark {
  margin-left: auto;
  color: #14805e;
  font-size: 10px;
  font-weight: 700;
}

.dark .en-product-menu { color: #fafafa; }
.dark .en-product-name {
  border-left-color: rgba(255, 255, 255, .16);
  color: #d4d4d4;
}
.dark .en-product-popover {
  border-color: var(--line, #525252);
  background: rgba(39, 39, 42, .98);
  box-shadow: 0 18px 42px rgba(0, 0, 0, .35);
  color: #fafafa;
}
.dark .en-product-popover a:hover,
.dark .en-popover-current { background: var(--surface-muted, #3f3f46); }

@media (max-width: 920px) {
  .en-product-brand { display: none; }
  .en-product-name {
    margin-left: 0;
    padding-left: 0;
    border-left: 0;
    color: inherit;
    font-size: 14px;
    font-weight: 650;
  }
  .en-product-trigger img { width: 17px; height: 24px; margin-right: 7px; }
}

@media (max-width: 860px) {
  .facility-header-inner {
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 8px;
  }
}

@media (max-width: 680px) {
  .facility-view-nav button {
    min-width: 0;
    width: 34px;
    padding: 0;
  }

  .facility-view-nav button span {
    display: none;
  }
}

@media (max-width: 520px) {
  .en-product-name { display: none; }
  .en-product-trigger img { margin-right: 0; }
}
