.desktop-header-host {
  display: none;
}

/* Desktop navigation shared across pages */
.desktop-topbar {
  display: none;
}

@media (min-width: 641px) {
  .desktop-header-host {
    display: block;
    min-height: 50px;
  }

  .desktop-topbar {
    height: 50px;
    display: grid;
    grid-template-columns: 310px 1fr 156px;
    align-items: center;
    padding: 0 16px;
    background: linear-gradient(180deg, #4d8fd8 0%, #3f81ca 62%, #3878c2 100%);
    color: #fff;
    box-shadow: 0 3px 10px rgba(31, 67, 111, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.24);
    gap: 8px;
    position: sticky;
    top: 0;
    z-index: 120;
  }

  .desktop-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
  }

  .desktop-brand-mark {
    width: 26px;
    height: 34px;
    display: grid;
    place-items: center;
    font-size: 26px;
    line-height: 1;
    filter: drop-shadow(0 2px 6px rgba(255, 255, 255, 0.18));
  }

  .desktop-brand strong {
    font-size: 16px;
    line-height: 1;
    font-weight: 830;
    letter-spacing: 0.1px;
    white-space: nowrap;
  }

  .desktop-menu {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
  }

  .desktop-menu a {
    height: 30px;
    display: flex;
    align-items: center;
    gap: 6px;
    color: #eef4ff;
    text-decoration: none;
    font-size: 13px;
    font-weight: 760;
    white-space: nowrap;
    padding: 0 9px;
    border-radius: 8px;
    border: 1px solid transparent;
    transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease;
  }

  .desktop-menu a:hover {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
  }

  .desktop-menu a.active {
    background: rgba(255, 255, 255, 0.22);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.28);
  }

  .desktop-menu .ico {
    font-size: 15px;
    line-height: 1;
    opacity: 0.96;
  }

  .desktop-tools {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
  }

  .desktop-top-ico {
    font-size: 20px;
    line-height: 1;
    position: relative;
    opacity: 0.94;
    color: #fff;
    text-decoration: none;
  }

  .desktop-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #fff;
    color: #2e6fb8;
    display: grid;
    place-items: center;
    font-size: 12px;
    font-weight: 950;
    box-shadow: 0 4px 12px rgba(18, 42, 77, 0.22);
  }

  .desktop-logout-btn {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    cursor: pointer;
    transition: background 0.16s ease, border-color 0.16s ease, transform 0.16s ease;
  }

  .desktop-logout-btn:hover {
    background: rgba(255, 255, 255, 0.26);
    border-color: rgba(255, 255, 255, 0.42);
  }

  .desktop-logout-btn:active {
    transform: scale(0.96);
  }

  .desktop-logout-btn svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    stroke-width: 2.3;
  }

  .bottom-nav {
    display: none !important;
  }

  body.log-cardio-theme {
    padding: 0 0 24px !important;
  }

  body.log-cardio-theme .log-page {
    padding: 10px 16px 24px;
  }

  body.app-cardio-theme .header,
  body.log-cardio-theme .log-header,
  body.admin-cardio-theme .admin-header {
    display: none !important;
  }
}
